diff --git a/CMakeLists.txt b/CMakeLists.txt index 9dfa69fbd..b297bca7c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -12,6 +12,7 @@ include_directories("${PROJECT_SOURCE_DIR}/src") set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PROJECT_SOURCE_DIR}/resources/cmake/") +include(ExternalProject) ############################################################# ## ## CMake options of StoRM @@ -181,6 +182,7 @@ message(STATUS "StoRM - Using Compiler Configuration: ${STORM_COMPILED_BY}") ############################################################# +add_subdirectory(resources/3rdparty) # Add the version of GMM in the repository to the include pathes set(GMMXX_INCLUDE_DIR "${PROJECT_SOURCE_DIR}/resources/3rdparty/gmm-5.0/include") include_directories(${GMMXX_INCLUDE_DIR}) @@ -433,19 +435,10 @@ endif() ## CUDD ## ############################################################# -add_subdirectory("${PROJECT_SOURCE_DIR}/resources/3rdparty/cudd-2.5.0") -include_directories("${PROJECT_SOURCE_DIR}/resources/3rdparty/cudd-2.5.0/src/cudd") -include_directories("${PROJECT_SOURCE_DIR}/resources/3rdparty/cudd-2.5.0/src/epd") -include_directories("${PROJECT_SOURCE_DIR}/resources/3rdparty/cudd-2.5.0/src/mtr") -include_directories("${PROJECT_SOURCE_DIR}/resources/3rdparty/cudd-2.5.0/src/nanotrav") -include_directories("${PROJECT_SOURCE_DIR}/resources/3rdparty/cudd-2.5.0/src/obj") -include_directories("${PROJECT_SOURCE_DIR}/resources/3rdparty/cudd-2.5.0/src/st") -include_directories("${PROJECT_SOURCE_DIR}/resources/3rdparty/cudd-2.5.0/src/util") -list(APPEND STORM_LINK_LIBRARIES cudd) - - - +message("${CUDD3_INCLUDE_DIR}") +include_directories(${CUDD3_INCLUDE_DIR}) +list(APPEND STORM_LINK_LIBRARIES ${CUDD3_SHARED_LIBRARIES}) ############################################################# ## @@ -543,7 +536,7 @@ endif() ## Sylvan ## ############################################################# -include(ExternalProject) + set(STORM_SYLVAN_ROOT "${PROJECT_SOURCE_DIR}/resources/3rdparty/sylvan") ExternalProject_Add( sylvan @@ -728,7 +721,6 @@ set(STORM_GENERATED_SOURCES "${PROJECT_BINARY_DIR}/src/utility/storm-version.cpp # Add the binary dir include directory for storm-config.h include_directories("${PROJECT_BINARY_DIR}/include") -add_subdirectory(resources/3rdparty) add_subdirectory(src) add_subdirectory(test) diff --git a/resources/3rdparty/CMakeLists.txt b/resources/3rdparty/CMakeLists.txt index 090c8ff15..fadcbd3f6 100644 --- a/resources/3rdparty/CMakeLists.txt +++ b/resources/3rdparty/CMakeLists.txt @@ -1,6 +1,7 @@ add_custom_target(resources) add_custom_target(test-resources) + if(STORM_SUPPORT_XML_INPUT_FORMATS) ExternalProject_Add( xercesc @@ -32,6 +33,24 @@ ExternalProject_Add( add_dependencies(resources glpk) +ExternalProject_Add( + cudd3 + DOWNLOAD_COMMAND "" + SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/cudd-3.0.0 + PREFIX ${CMAKE_CURRENT_BINARY_DIR}/cudd-3.0.0 + CONFIGURE_COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/cudd-3.0.0/configure --enable-shared --enable-obj --prefix=${CMAKE_CURRENT_BINARY_DIR}/cudd-3.0.0 --libdir=${CMAKE_CURRENT_BINARY_DIR}/cudd-3.0.0/lib CC=${CMAKE_C_COMPILER} CXX=${CMAKE_CXX_COMPILER} + BUILD_COMMAND make "CFLAGS=-O2 -w" + INSTALL_COMMAND make install + BUILD_IN_SOURCE 0 +) +add_dependencies(resources cudd3) + +ExternalProject_Get_Property(cudd3 binary_dir) +set(CUDD3_INCLUDE_DIR ${CMAKE_CURRENT_BINARY_DIR}/cudd-3.0.0/include PARENT_SCOPE) + +set(CUDD3_SHARED_LIBRARIES ${CMAKE_CURRENT_BINARY_DIR}/cudd-3.0.0/lib/libcudd${DYNAMIC_EXT} PARENT_SCOPE) +set(CUDD3_STATIC_LIBRARIES ${CMAKE_CURRENT_BINARY_DIR}/cudd-3.0.0/liblibcudd${STATIC_EXT} PARENT_SCOPE) + ExternalProject_Add( googletest #For downloads (may be useful later!) diff --git a/resources/3rdparty/cudd-2.5.0/CMakeLists.txt b/resources/3rdparty/cudd-2.5.0/CMakeLists.txt deleted file mode 100644 index 27bff3ed9..000000000 --- a/resources/3rdparty/cudd-2.5.0/CMakeLists.txt +++ /dev/null @@ -1,42 +0,0 @@ -cmake_minimum_required (VERSION 2.8.6) - -# Set project name -project (cudd C CXX) - -# Main Sources -file(GLOB_RECURSE CUDD_HEADERS ${PROJECT_SOURCE_DIR}/src/*.h) -file(GLOB_RECURSE CUDD_HEADERS_CXX ${PROJECT_SOURCE_DIR}/src/*.hh) -file(GLOB_RECURSE CUDD_SOURCES ${PROJECT_SOURCE_DIR}/src/*.c) -file(GLOB_RECURSE CUDD_SOURCES_CXX ${PROJECT_SOURCE_DIR}/src/*.cc) - - -# Add base folder for better inclusion paths -include_directories("${PROJECT_SOURCE_DIR}/src") -include_directories("${PROJECT_SOURCE_DIR}/src/cudd") -include_directories("${PROJECT_SOURCE_DIR}/src/dddmp") -include_directories("${PROJECT_SOURCE_DIR}/src/epd") -include_directories("${PROJECT_SOURCE_DIR}/src/mtr") -include_directories("${PROJECT_SOURCE_DIR}/src/nanotrav") -include_directories("${PROJECT_SOURCE_DIR}/src/st") -include_directories("${PROJECT_SOURCE_DIR}/src/util") - -if(CMAKE_COMPILER_IS_GNUCC) - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-variable -Wno-unused-but-set-variable -Wno-unused-function") -elseif(MSVC) - # required for GMM to compile, ugly error directive in their code - add_definitions(/D_SCL_SECURE_NO_DEPRECATE /D_CRT_SECURE_NO_WARNINGS) -else(CLANG) - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-newline-eof -Wno-unneeded-internal-declaration -Wno-unused-variable -Wno-unused-const-variable -Wno-parentheses-equality") -endif() - -# Since we do not target Alphas, this symbol is always set -add_definitions(-DHAVE_IEEE_754) - -if(CMAKE_SIZEOF_VOID_P EQUAL 8) - message(STATUS "CUDD: Targeting 64bit architecture") - add_definitions(-DSIZEOF_VOID_P=8) - add_definitions(-DSIZEOF_LONG=8) -endif() - -# Add the library -add_library(cudd STATIC ${CUDD_SOURCES} ${CUDD_HEADERS} ${CUDD_HEADERS_CXX} ${CUDD_SOURCES_CXX}) \ No newline at end of file diff --git a/resources/3rdparty/cudd-2.5.0/Makefile b/resources/3rdparty/cudd-2.5.0/Makefile deleted file mode 100644 index 95a0a47d5..000000000 --- a/resources/3rdparty/cudd-2.5.0/Makefile +++ /dev/null @@ -1,323 +0,0 @@ -# $Id$ -# -# Makefile for the CUDD distribution kit -#--------------------------------------------------------------------------- - -# Beginning of the configuration section. These symbol definitions can -# be overridden from the command line. - -# C++ compiler -#CXX = g++ -#CXX = icpc -#CXX = ecpc -#CXX = CC -#CXX = /usr/local/opt/SUNWspro/bin/CC -#CXX = cxx -CXX = clang++ - -# Specific options for compilation of C++ files. -CXXFLAGS = -std=c++11 -stdlib=libc++ -# Stricter standard conformance for g++. -#CXXFLAGS = -std=c++98 -# For Sun CC version 5, this invokes compatibility mode. -#CXXFLAGS = -compat -# On some versions of UP-UX, it is necessary to pass the option +a1 -# to CC for the C++ test program to compile successfully. -#CXXFLAGS = +a1 - -# C compiler used for all targets except optimize_dec, which always uses cc. -#CC = cc -#CC = /usr/local/opt/SUNWspro/bin/cc -#CC = gcc -#CC = icc -#CC = ecc -#CC = /usr/ucb/cc -#CC = c89 -#CC = $(CXX) -CC = clang - -# On some machines ranlib is either non-existent or redundant. -# Use the following definition if your machine has ranlib and you think -# it is needed. -RANLIB = ranlib -# Use the following definition if your machine either does not have -# ranlib (e.g., SUN running solaris) or can do without it (e.g., DEC Alpha). -#RANLIB = : - -# Use ICFLAGS to specify machine-independent compilation flags. -# These three are typical settings for cc. -#ICFLAGS = -g -#ICFLAGS = -O -#ICFLAGS = -# These two are typical settings for optimized code with gcc. -#ICFLAGS = -g -O3 -Wall -ICFLAGS = -O4 - -# Use XCFLAGS to specify machine-dependent compilation flags. -# For some platforms no special flags are needed. -#XCFLAGS = -DHAVE_IEEE_754 -DBSD -# -#========================== -# Linux -# -# Gcc 4.2.4 or higher on i686. -XCFLAGS = -arch x86_64 -DHAVE_IEEE_754 -DBSD -DSIZEOF_VOID_P=8 -DSIZEOF_LONG=8 -# Gcc 3.2.2 or higher on i686. -#XCFLAGS = -mtune=pentium4 -malign-double -DHAVE_IEEE_754 -DBSD -# Gcc 2.8.1 on i686. -#XCFLAGS = -mcpu=pentiumpro -malign-double -DHAVE_IEEE_754 -DBSD -# Gcc 4.2.4 or higher on x86_64 (64-bit compilation) -#XCFLAGS = -mtune=native -DHAVE_IEEE_754 -DBSD -DSIZEOF_VOID_P=8 -DSIZEOF_LONG=8 -# Gcc 4.2.4 or higher on x86_64 (32-bit compilation) -#XCFLAGS = -m32 -mtune=native -malign-double -DHAVE_IEEE_754 -DBSD -# Icc on i686 (older versions may not support -xHost). -#XCFLAGS = -ansi -xHost -align -ip -DHAVE_IEEE_754 -DBSD -# Icc on x86_64 (64-bit compilation). -#XCFLAGS = -ansi -xHost -align -ip -DHAVE_IEEE_754 -DBSD -DSIZEOF_VOID_P=8 -DSIZEOF_LONG=8 -# Gcc on ia64. -#XCFLAGS = -DHAVE_IEEE_754 -DBSD -DSIZEOF_VOID_P=8 -DSIZEOF_LONG=8 -# Icc/ecc on ia64. -#XCFLAGS = -ansi -DBSD -DHAVE_IEEE_754 -DSIZEOF_VOID_P=8 -DSIZEOF_LONG=8 -# -#========================== -# Solaris -# -# For Solaris, BSD should not be replaced by UNIX100. -#XCFLAGS = -DHAVE_IEEE_754 -DUNIX100 -DEPD_BIG_ENDIAN -# Gcc 2.8.1 or higher on Ultrasparc. -#XCFLAGS = -mcpu=ultrasparc -DHAVE_IEEE_754 -DUNIX100 -DEPD_BIG_ENDIAN -# For Solaris 2.5 and higher, optimized code with /usr/bin/cc or CC. -#XCFLAGS = -DHAVE_IEEE_754 -DUNIX100 -xO5 -native -dalign -DEPD_BIG_ENDIAN -# On IA platforms, -dalign is not supported and causes warnings. -#XCFLAGS = -DHAVE_IEEE_754 -DUNIX100 -xO5 -native -# Recent Sun compilers won't let you use -native on old Ultras. -#XCFLAGS = -DHAVE_IEEE_754 -DUNIX100 -xO5 -dalign -xlibmil -DEPD_BIG_ENDIAN -# For Solaris 2.4, optimized code with /usr/bin/cc. -#XCFLAGS = -DHAVE_IEEE_754 -DUNIX100 -xO4 -dalign -DEPD_BIG_ENDIAN -# For Solaris 2.5 and higher, optimized code with /usr/ucb/cc. -#XCFLAGS = -DHAVE_IEEE_754 -DBSD -xO5 -native -dalign -DEPD_BIG_ENDIAN -#XCFLAGS = -DHAVE_IEEE_754 -DBSD -xO5 -dalign -xlibmil -DEPD_BIG_ENDIAN -# For Solaris 2.4, optimized code with /usr/ucb/cc. -#XCFLAGS = -DHAVE_IEEE_754 -DBSD -xO4 -dalign -DEPD_BIG_ENDIAN -# -#========================== -# DEC Alphas running Digital Unix -# -# For DEC Alphas either -ieee_with_inexact or -ieee_with_no_inexact is -# needed. If you use only BDDs, -ieee_with_no_inexact is enough. -# In the following, we consider three different compilers: -# - the old native compiler (the one of MIPS ancestry that produces u-code); -# - the new native compiler; -# - gcc -# On the Alphas, gcc (as of release 2.7.2) does not support 32-bit pointers -# and IEEE 754 floating point arithmetic. Therefore, for this architecture -# only, the native compilers provide a substatial advantage. -# With the native compilers, specify -xtaso for 32-bit pointers. -# Do not use -xtaso_short because explicit reference to stdout and stderr -# does not work with this option. (Among other things.) -# Notice that -taso must be included in LDFLAGS for -xtaso to work. -# Given the number of possible choices, only some typical configurations -# are proposed here. -# -# Old native compiler for the Alphas; 64-bit pointers. -#XCFLAGS = -DBSD -DHAVE_IEEE_754 -ieee_with_no_inexact -tune host -DSIZEOF_VOID_P=8 -DSIZEOF_LONG=8 -# Old native compiler for the Alphas; 32-bit pointers. -#XCFLAGS = -DBSD -DHAVE_IEEE_754 -ieee_with_no_inexact -tune host -xtaso -DSIZEOF_LONG=8 -# New native compiler for the Alphas; 64-bit pointers. -#XCFLAGS = -g3 -O4 -std -DBSD -DHAVE_IEEE_754 -ieee_with_no_inexact -tune host -DSIZEOF_VOID_P=8 -DSIZEOF_LONG=8 -# New native compiler for the Alphas; 32-bit pointers. -#XCFLAGS = -g3 -O4 -std -DBSD -DHAVE_IEEE_754 -ieee_with_no_inexact -tune host -xtaso -DSIZEOF_LONG=8 -# gcc for the Alphas: compile without HAVE_IEEE_754. -#XCFLAGS = -DBSD -DSIZEOF_VOID_P=8 -DSIZEOF_LONG=8 -# -#========================== -# -# IBM RS6000 -# -# For the IBM RS6000 -qstrict is necessary when specifying -O3 with cc. -#XCFLAGS = -DBSD -DHAVE_IEEE_754 -DEPD_BIG_ENDIAN -O3 -qstrict -# -#========================== -# -# HP-UX -# -# I haven't figured out how to enable IEEE 754 on the HPs I've tried... -# For HP-UX using gcc. -#XCFLAGS = -DUNIX100 -DEPD_BIG_ENDIAN -# For HP-UX using c89. -#XCFLAGS = +O3 -DUNIX100 -DEPD_BIG_ENDIAN -# -#========================== -# -# Windows 95/98/NT/XP/Vista/7 with Cygwin tools -# -# The value of RLIMIT_DATA_DEFAULT should reflect the amount of -# available memory (expressed in bytes). -# Recent versions of cygwin have getrlimit, but the datasize limit -# cannot be set. -#XCFLAGS = -mtune=native -malign-double -DHAVE_IEEE_754 -DHAVE_GETRLIMIT=0 -DRLIMIT_DATA_DEFAULT=268435456 - - -# Define the level of self-checking and verbosity of the CUDD package. -#DDDEBUG = -DDD_DEBUG -DDD_VERBOSE -DDD_STATS -DDD_CACHE_PROFILE -DDD_UNIQUE_PROFILE -DDD_COUNT -DDDEBUG = - -# Define the level of self-checking and verbosity of the MTR package. -#MTRDEBUG = -DMTR_DEBUG -MTRDEBUG = - -# Loader options. -LDFLAGS = -# This may produce faster code on the DECstations. -#LDFLAGS = -jmpopt -Olimit 1000 -# This may be necessary under some old versions of Linux. -#LDFLAGS = -static -# This normally makes the program faster on the DEC Alphas. -#LDFLAGS = -non_shared -om -# This is for 32-bit pointers on the DEC Alphas. -#LDFLAGS = -non_shared -om -taso -#LDFLAGS = -non_shared -taso - -# Define PURE as purify to link with purify. -# Define PURE as quantify to link with quantify. -# Remember to compile with -g if you want line-by-line info with quantify. -PURE = -#PURE = purify -#PURE = quantify - -# Define EXE as .exe for MS-DOS and derivatives. Not required by recent -# versions of cygwin. -EXE = -#EXE = .exe - -# End of the configuration section. -#--------------------------------------------------------------------------- - -MFLAG = -DMNEMOSYNE -MNEMLIB = ../mnemosyne/libmnem.a - -DDWDIR = . -IDIR = $(DDWDIR)/include -INCLUDE = -I$(IDIR) - -BDIRS = cudd dddmp mtr st util epd obj -DIRS = $(BDIRS) - -#------------------------------------------------------------------------ - -.PHONY : build -.PHONY : nanotrav -.PHONY : check_leaks -.PHONY : optimize_dec -.PHONY : testcudd -.PHONY : libobj -.PHONY : testobj -.PHONY : testdddmp -.PHONY : testmtr -.PHONY : lint -.PHONY : all -.PHONY : clean -.PHONY : distclean - - -build: - sh ./setup.sh - @for dir in $(DIRS); do \ - (cd $$dir; \ - echo Making $$dir ...; \ - make CC=$(CC) RANLIB=$(RANLIB) MFLAG= MNEMLIB= ICFLAGS="$(ICFLAGS)" XCFLAGS="$(XCFLAGS)" DDDEBUG="$(DDDEBUG)" MTRDEBUG="$(MTRDEBUG)" LDFLAGS="$(LDFLAGS)" PURE="$(PURE)" EXE="$(EXE)" )\ - done - -nanotrav: build - -check_leaks: - sh ./setup.sh - @for dir in mnemosyne $(DIRS); do \ - (cd $$dir; \ - echo Making $$dir ...; \ - make CC=$(CC) RANLIB=$(RANLIB) MFLAG=$(MFLAG) MNEMLIB=$(MNEMLIB) ICFLAGS="$(ICFLAGS)" XCFLAGS="$(XCFLAGS)" DDDEBUG="$(DDDEBUG)" MTRDEBUG="$(MTRDEBUG)" LDFLAGS="$(LDFLAGS)" EXE="$(EXE)" )\ - done - -optimize_dec: - sh ./setup.sh - @for dir in $(DIRS); do \ - (cd $$dir; \ - echo Making $$dir ...; \ - make CC=$(CC) RANLIB=$(RANLIB) XCFLAGS="$(XCFLAGS)" LDFLAGS="$(LDFLAGS)" optimize_dec )\ - done - -lint: - sh ./setup.sh - @for dir in $(DIRS) obj; do \ - (cd $$dir; \ - echo Making lint in $$dir ...; \ - make CC=$(CC) lint )\ - done - -tags: - sh ./setup.sh - @for dir in $(DIRS) obj; do \ - (cd $$dir; \ - echo Making tags in $$dir ...; \ - make CC=$(CC) tags )\ - done - -all: - sh ./setup.sh - @for dir in $(DIRS); do \ - (cd $$dir; \ - echo Making all in $$dir ...; \ - make CC=$(CC) RANLIB=$(RANLIB) MFLAG= MNEMLIB= ICFLAGS="$(ICFLAGS)" XCFLAGS="$(XCFLAGS)" DDDEBUG="$(DDDEBUG)" MTRDEBUG="$(MTRDEBUG)" LDFLAGS="$(LDFLAGS)" PURE="$(PURE)" EXE="$(EXE)" all )\ - done - -testcudd: - sh ./setup.sh - @for dir in util st mtr epd; do \ - (cd $$dir; \ - echo Making $$dir ...; \ - make CC=$(CC) RANLIB=$(RANLIB) MFLAG= MNEMLIB= ICFLAGS="$(ICFLAGS)" XCFLAGS="$(XCFLAGS)" DDDEBUG="$(DDDEBUG)" MTRDEBUG="$(MTRDEBUG)" LDFLAGS="$(LDFLAGS)" PURE="$(PURE)" EXE="$(EXE)" )\ - done - @(cd cudd; \ - echo Making testcudd ...; \ - make CC=$(CC) RANLIB=$(RANLIB) MFLAG= MNEMLIB= ICFLAGS="$(ICFLAGS)" XCFLAGS="$(XCFLAGS)" DDDEBUG="$(DDDEBUG)" MTRDEBUG="$(MTRDEBUG)" LDFLAGS="$(LDFLAGS)" PURE="$(PURE)" EXE="$(EXE)" testcudd$(EXE) ) - -objlib: - sh ./setup.sh - @for dir in $(BDIRS); do \ - (cd $$dir; \ - echo Making $$dir ...; \ - make CC=$(CC) RANLIB=$(RANLIB) MFLAG= MNEMLIB= ICFLAGS="$(ICFLAGS)" XCFLAGS="$(XCFLAGS)" DDDEBUG="$(DDDEBUG)" MTRDEBUG="$(MTRDEBUG)" LDFLAGS="$(LDFLAGS)" PURE="$(PURE)" EXE="$(EXE)" )\ - done - @(cd obj; \ - echo Making obj ...; \ - make CXX=$(CXX) CXXFLAGS=$(CXXFLAGS) RANLIB=$(RANLIB) MFLAG= MNEMLIB= ICFLAGS="$(ICFLAGS)" XCFLAGS="$(XCFLAGS)" DDDEBUG="$(DDDEBUG)" MTRDEBUG="$(MTRDEBUG)" LDFLAGS="$(LDFLAGS)" PURE="$(PURE)" EXE="$(EXE)" ) - -testobj: objlib - @(cd obj; \ - echo Making testobj ...; \ - make CXX=$(CXX) CXXFLAGS=$(CXXFLAGS) RANLIB=$(RANLIB) MFLAG= MNEMLIB= ICFLAGS="$(ICFLAGS)" XCFLAGS="$(XCFLAGS)" DDDEBUG="$(DDDEBUG)" MTRDEBUG="$(MTRDEBUG)" LDFLAGS="$(LDFLAGS)" PURE="$(PURE)" EXE="$(EXE)" testobj$(EXE) ) - -testdddmp: build - @(cd dddmp; \ - echo Making testdddmp ...; \ - make CC=$(CC) RANLIB=$(RANLIB) MFLAG= MNEMLIB= ICFLAGS="$(ICFLAGS)" XCFLAGS="$(XCFLAGS)" DDDEBUG="$(DDDEBUG)" MTRDEBUG="$(MTRDEBUG)" LDFLAGS="$(LDFLAGS)" PURE="$(PURE)" EXE="$(EXE)" testdddmp$(EXE) ) - -testmtr: build - @(cd mtr; \ - echo Making testmtr ...; \ - make CC=$(CC) RANLIB=$(RANLIB) MFLAG= MNEMLIB= ICFLAGS="$(ICFLAGS)" XCFLAGS="$(XCFLAGS)" DDDEBUG="$(DDDEBUG)" MTRDEBUG="$(MTRDEBUG)" LDFLAGS="$(LDFLAGS)" PURE="$(PURE)" EXE="$(EXE)" testmtr$(EXE) ) - -clean: - @for dir in mnemosyne $(DIRS) obj; do \ - (cd $$dir; \ - echo Cleaning $$dir ...; \ - make -s clean ) \ - done - -distclean: - @for dir in mnemosyne $(DIRS) obj; do \ - (cd $$dir; \ - echo Cleaning $$dir ...; \ - make -s EXE="$(EXE)" distclean ) \ - done - sh ./shutdown.sh diff --git a/resources/3rdparty/cudd-2.5.0/README b/resources/3rdparty/cudd-2.5.0/README deleted file mode 100644 index 864a416f9..000000000 --- a/resources/3rdparty/cudd-2.5.0/README +++ /dev/null @@ -1,177 +0,0 @@ -$Id$ - -This directory contains a set of packages that allow you to build a toy -application based on the CUDD package. - -The CUDD package is a package written in C for the manipulation of -decision diagrams. It supports binary decision diagrams (BDDs), -algebraic decision diagrams (ADDs), and Zero-Suppressed BDDs (ZDDs). - -The toy application provided in this kit is called nanotrav and is a -simple-minded FSM traversal program. (See the README file and the man -page nanotrav.1 in the nanotrav directory for the details.) It is -included so that you can run a sanity check on your installation. - -INSTALLATION - -Before you build the libraries and programs, you need to check the -Makefile in the top directory. Go through the definitions contained in the -configuration section, and select the desired compiler and compilation -flags. Instructions are provided in the comments of the Makefile. - -You can always specify the options on the command line. For instance, -on some machines you can build a "fast" version of the program by typing: - - make DDDEBUG= MTRDEBUG= ICFLAGS=-O2 - -The Makefile supports several targets: - - make: - Creates a "plain" version of the program. - - make testdddmp: - Builds a test program (testdddmp) for BDD loading from and - storing to disk. See file README.test in the dddmp directory for - how to run the program. - - make testobj: - Builds a test program for the C++ interface. Requires a C++ - compiler. To run the program, run obj/testobj. - - make testcudd: - Builds a test program for CUDD. To run the program, go to the - cudd directory and type "./testcudd -p 2 r7x8.1.mat". The result - can be compared to r7x7.1.out. - - make testmtr: - Builds a test program for the mtr package. To run the program, - go to the mtr directory and type "./testmtr -p 1 test.groups". - - make clean: - Cleans directories, but leaves libraries and programs. - - make distclean: - Cleans thoroughly, returning the directories to their pristine - state. - -The following targets are more or less obsolete and may disappear or -change in the future. - - make check_leaks: - Creates a version of the program with the mnemosyne library - linked to it. It also builds the mnemalyse program, which - helps in finding memory leaks. This target does not work on the - IBM RS6000. The makefile also supports purify. To use purify, - set the PURE variable in the Makefile, and use the standard - target. - - make optimize_dec: - Builds a version of the program using the u-code compiler - available on DEC machines (DECstations and Alphas). The newer - native compiler on the Alphas does not use u-code, though. - Therefore the standard target should be used with it. - - make lint: - Runs lint on all subdirectories except mnemosyne. Creates lint - libraries for all object libraries. - - make tags: - Builds ctags-style tag files for all subdirectories except - mnemosyne. - - make all: - Makes all of the above, except check_leaks, which is - incompatible with a plain "make." - -All targets, except clean and distclean, will create the include -directory if it does not already exist. - -The Makefile does not compile the SIS interface (cuddBddPort.c and -cuddPwPt.c found in subdirectory sis). To compile the interface, you -also need array.h and var_set.h, which are not part of this -distribution, but come with SIS. Detailed instructions on how to -integrate the CUDD package in SIS can be found in the documentation -(cudd/doc). - -PLATFORMS - -This kit has been successfully built on the following configurations: - - PC (ia32 and ia64) running Ubuntu with gcc - PC (ia32 and ia64) running Ubuntu with g++ - PC (ia32 and ia64) running Linux RedHat with gcc - PC (ia32 and ia64) running Linux RedHat with g++ - PC (ia64) running Cygwin on Windows 7 and Vista with gcc - PC (ia64) running Cygwin on Windows 7 and Vista with g++ - -Platforms to which I have no longer access and therefore are no longer -supported. - - PC (ia32) running Linux RedHat with icc - PC (ia32) running Linux RedHat with icpc - PC (ia64) running Linux RedHat with ecc - PC (ia64) running Linux RedHat with ecpc - SUN running Solaris 2.8 with cc - SUN running Solaris 2.8 with CC - SUN running Solaris 2.8 with gcc - SUN running Solaris 2.8 with g++ - DECstation running Ultrix with cc - DECstation running Ultrix with gcc - IBM RS6000 running AIX 3.2.4 with cc (**) - IBM RS6000 running AIX 3.2.4 with gcc - IBM RS6000 running AIX 3.2.4 with g++ - SUN running SunOS with gcc - DEC Alpha running Digital Unix with cc - DEC Alpha running Digital Unix with cxx - DEC Alpha running Digital Unix with gcc - HP 9000/770 running HP-UX with c89 - HP 9000/770 running HP-UX with CC - HP 9000/770 running HP-UX with gcc - HP 9000/770 running HP-UX with g++ (*) - SUN running Solaris 2.8 with /usr/ucb/cc - PC running Solaris 2.8 with /usr/bin/cc - PC running Solaris 2.8 with /usr/ucb/cc - PC running Solaris 2.8 with CC - PC running Solaris 2.8 with gcc - PC running Solaris 2.8 with g++ - -NOTES - (*) C programs were compiled with g++, but linked with gcc. - - (**) Some old versions of the AIX cc compiler have buggy optimizers: - Try compiling with -O2 instead of -O3 if the program crashes. - -Running lint and compiling with gcc -Wall still produces warnings. -Running `purify' under Solaris 2.8 generates no messages. - -SANITY CHECK - -The directory `nanotrav' contains a very simple application based on the -CUDD package. The `nanotrav' directory contains a man page that -describes the options nanotrav supports. The files *.blif are sample -input files for nanotrav. - -If you have built the mnemosyne library (make check_leaks), you can do - cd mnemosyne - make runmtest -This does not work on machines running SunOS, but the version of -nanotrav that uses mnemosyne may work. - -DOCUMENTATION - -Directory cudd-2.5.0/cudd/doc contains HTML documentation for the CUDD -package. The recommended starting point is cuddIntro.html. Documentation -in both postscript(tm) format and plain text format is also provided. -Documentation for the auxiliary libraries (except for the util library) -is in the doc subdirectories. - -FEEDBACK: - -Send feedback to: - -Fabio Somenzi -University of Colorado at Boulder -ECE Dept. -Boulder, CO 80309-0425 -Fabio@Colorado.EDU -http://vlsi.colorado.edu/~fabio diff --git a/resources/3rdparty/cudd-2.5.0/RELEASE.NOTES b/resources/3rdparty/cudd-2.5.0/RELEASE.NOTES deleted file mode 100644 index 22867e568..000000000 --- a/resources/3rdparty/cudd-2.5.0/RELEASE.NOTES +++ /dev/null @@ -1,131 +0,0 @@ -Release 2.5.0 of Cudd introduces the ability to set timeouts. The -function that is interrupted returns NULL (which the application must -be prepared to handle,) but the BDDs are uncorrupted and the invoking -program can continue to use the manager. - -In addition, reordering is now aware of timeouts, so that it gives up -when a timeout is approaching to give the invoking program a chance to -obtain some results. - -The response time to the timeout is not immediate, though most of the time -it is well below one second. Checking for timeouts has a small overhead. -In experiments, less than 1% has been observed on average. - -Creation of BDD managers with many variables (e.g., tens or hundreds -of thousands) is now much more efficient. Computing small supports of -BDDs when there are many variables is also much more efficient, but -this has been at the cost of separating the function for BDDs and ADDs -(Cudd_Support) from that for ZDDs (Cudd_zddSupport). - -The C++ interface has undergone a major upgrade. - -The handling of variable gruops in reordering has been much improved. -(Thanks to Arie Gurfinkel for a very detailed bug report!) A handful -of other bugs have been fixed as well. - - -New Functions: - -unsigned long Cudd_ReadStartTime(DdManager *unique); - -unsigned long Cudd_ReadElapsedTime(DdManager *unique); - -void Cudd_SetStartTime(DdManager *unique, unsigned long st); - -void Cudd_ResetStartTime(DdManager *unique); - -unsigned long Cudd_ReadTimeLimit(DdManager *unique); - -void Cudd_SetTimeLimit(DdManager *unique, unsigned long tl); - -void Cudd_UpdateTimeLimit(DdManager * unique); - -void Cudd_IncreaseTimeLimit(DdManager * unique, unsigned long increase); - -void Cudd_UnsetTimeLimit(DdManager *unique); - -int Cudd_TimeLimited(DdManager *unique); - -unsigned int Cudd_ReadMaxReorderings (DdManager *dd); - -void Cudd_SetMaxReorderings (DdManager *dd, unsigned int mr); - -unsigned int Cudd_ReadOrderRandomization(DdManager * dd); - -void Cudd_SetOrderRandomization(DdManager * dd, unsigned int factor); - -int Cudd_PrintGroupedOrder(DdManager * dd, const char *str, void *data); - -int Cudd_EnableOrderingMonitoring(DdManager *dd); - -int Cudd_DisableOrderingMonitoring(DdManager *dd); - -int Cudd_OrderingMonitoring(DdManager *dd); - -DdNode * Cudd_bddExistAbstractLimit(DdManager * manager, DdNode * f, DdNode * cube, unsigned int limit); - -DdNode * Cudd_bddIteLimit (DdManager *dd, DdNode *f, DdNode *g, DdNode *h, unsigned int limit); - -DdNode * Cudd_bddOrLimit (DdManager *dd, DdNode *f, DdNode *g, unsigned int limit); - -DdNode * Cudd_bddXnorLimit (DdManager *dd, DdNode *f, DdNode *g, unsigned int limit); - -int Cudd_CheckCube (DdManager *dd, DdNode *g); - -DdNode * Cudd_bddMaximallyExpand(DdManager *dd, DdNode *lb, DdNode *ub, DdNode *f); - -DdNode * Cudd_bddLargestPrimeUnate(DdManager *dd , DdNode *f, DdNode *phaseBdd); - -int Cudd_Reserve(DdManager *manager, int amount); - -int Cudd_SupportIndices(DdManager * dd, DdNode * f, int **indices); - -int Cudd_VectorSupportIndices(DdManager * dd, DdNode ** F, int n, int **indices); - -DdNode * Cudd_zddSupport(DdManager * dd, DdNode * f); - - -Changed prototypes: - -unsigned int Cudd_ReadReorderings (DdManager *dd); - ----------------------------------------------------------------------- - -Release 2.4.2 of Cudd features several bug fixes. The most important -are those that prevented Cudd from making full use of up to 4 GB of -memory when using 32-bit pointers. A handful of bugs were discovered by -Coverity. (Thanks to Christian Stangier!) - -This release can be compiled with either 64-bit pointers or 32-bit -pointers on x86_64 platforms if sizeof(long) = sizeof(void *) = 8 and -sizeof(int) = 4. This is known as the LP64 model. For 32-bit pointers, -one usually needs supplementary libraries. On Ubuntu and Debian Linux, -one needs g++-multilib, which can be installed with -"apt-get install g++-multilib." - -Added functions - -DdNode *Cudd_Inequality (DdManager * dd, int N, int c, DdNode ** x, -DdNode ** y); - -DdNode * Cudd_Disequality (DdManager * dd, int N, int c, DdNode ** x, -DdNode ** y); - -DdNode * Cudd_bddInterval (DdManager * dd, int N, DdNode ** x, -unsigned int lowerB, unsigned int upperB); - -Changed prototypes: - -int Cudd_DumpBlif (DdManager *dd, int n, DdNode **f, char -**inames, char **onames, char *mname, FILE *fp, int mv); - -int Cudd_DumpBlifBody (DdManager *dd, int n, DdNode **f, char -**inames, char **onames, FILE *fp, int mv); - -The additional parameter allows the caller to choose between plain blif -and blif-MV. - ----------------------------------------------------------------------- - -Release 2.4.1 of Cudd features one major change with respect to previous -releases. The licensing terms are now explicitly stated. diff --git a/resources/3rdparty/cudd-2.5.0/setup.sh b/resources/3rdparty/cudd-2.5.0/setup.sh deleted file mode 100755 index cb4003236..000000000 --- a/resources/3rdparty/cudd-2.5.0/setup.sh +++ /dev/null @@ -1,18 +0,0 @@ -#! /bin/sh -CREATE="ln -s" -if test -d include - then - : - else - mkdir include - cd include - $CREATE ../cudd/cudd.h . - $CREATE ../cudd/cuddInt.h . - $CREATE ../epd/epd.h . - $CREATE ../dddmp/dddmp.h . - $CREATE ../mtr/mtr.h . - $CREATE ../obj/cuddObj.hh . - $CREATE ../st/st.h . - $CREATE ../util/util.h . - $CREATE ../mnemosyne/mnemosyne.h . -fi diff --git a/resources/3rdparty/cudd-2.5.0/shutdown.sh b/resources/3rdparty/cudd-2.5.0/shutdown.sh deleted file mode 100755 index 724917d7c..000000000 --- a/resources/3rdparty/cudd-2.5.0/shutdown.sh +++ /dev/null @@ -1,2 +0,0 @@ -#! /bin/sh -rm -rf include *.bak *~ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/Makefile b/resources/3rdparty/cudd-2.5.0/src/cudd/Makefile deleted file mode 100644 index d76954746..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/Makefile +++ /dev/null @@ -1,124 +0,0 @@ -# $Id$ -# -# Cudd - DD package -#--------------------------- -.SUFFIXES: .o .c .u - -CC = gcc -RANLIB = ranlib -PURE = -# Define EXE as .exe for MS-DOS and derivatives. -EXE = -#EXE = .exe - -MFLAG = -ICFLAGS = -g -XCFLAGS = -DDD_STATS -CFLAGS = $(ICFLAGS) $(MFLAG) $(XCFLAGS) -#DDDEBUG = -DDD_DEBUG -DDD_CACHE_PROFILE -DDD_VERBOSE -DDD_UNIQUE_PROFILE -DDDEBUG = - -LINTFLAGS = -u -n -DDD_STATS -DDD_CACHE_PROFILE -DDD_VERBOSE -DDD_DEBUG -DDD_UNIQUE_PROFILE - -# this is to create the lint library -LINTSWITCH = -o - -WHERE = .. - -INCLUDE = $(WHERE)/include - -LIBS = ./libcudd.a $(WHERE)/mtr/libmtr.a \ - $(WHERE)/st/libst.a $(WHERE)/util/libutil.a $(WHERE)/epd/libepd.a - -MNEMLIB = - -BLIBS = -kL. -klcudd -kL$(WHERE)/mtr -klmtr \ - -kL$(WHERE)/st -klst -kL$(WHERE)/util -klutil -kL$(WHERE)/epd -klepd - -LINTLIBS = ./llib-lcudd.ln $(WHERE)/mtr/llib-lmtr.ln \ - $(WHERE)/st/llib-lst.ln $(WHERE)/util/llib-lutil.ln \ - $(WHERE)/epd/llib-lepd.ln - -LDFLAGS = - -# files for the package -P = cudd -PSRC = cuddAPI.c cuddAddAbs.c cuddAddApply.c cuddAddFind.c cuddAddIte.c \ - cuddAddInv.c cuddAddNeg.c cuddAddWalsh.c cuddAndAbs.c \ - cuddAnneal.c cuddApa.c cuddApprox.c cuddBddAbs.c cuddBddCorr.c \ - cuddBddIte.c cuddBridge.c cuddCache.c cuddCheck.c cuddClip.c \ - cuddCof.c cuddCompose.c cuddDecomp.c cuddEssent.c \ - cuddExact.c cuddExport.c cuddGenCof.c cuddGenetic.c \ - cuddGroup.c cuddHarwell.c cuddInit.c cuddInteract.c \ - cuddLCache.c cuddLevelQ.c \ - cuddLinear.c cuddLiteral.c cuddMatMult.c cuddPriority.c \ - cuddRead.c cuddRef.c cuddReorder.c cuddSat.c cuddSign.c \ - cuddSolve.c cuddSplit.c cuddSubsetHB.c cuddSubsetSP.c cuddSymmetry.c \ - cuddTable.c cuddUtil.c cuddWindow.c cuddZddCount.c cuddZddFuncs.c \ - cuddZddGroup.c cuddZddIsop.c cuddZddLin.c cuddZddMisc.c \ - cuddZddPort.c cuddZddReord.c cuddZddSetop.c cuddZddSymm.c \ - cuddZddUtil.c -PHDR = cudd.h cuddInt.h -POBJ = $(PSRC:.c=.o) -PUBJ = $(PSRC:.c=.u) -TARGET = test$(P)$(EXE) -TARGETu = test$(P)-u - -# files for the test program -SRC = test$(P).c -OBJ = $(SRC:.c=.o) -UBJ = $(SRC:.c=.u) - -#------------------------------------------------------ - -lib$(P).a: $(POBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.o: $(PSRC) $(PHDR) - $(CC) -c $< -I$(INCLUDE) $(CFLAGS) $(DDDEBUG) - -optimize_dec: lib$(P).b - -lib$(P).b: $(PUBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.u: $(PSRC) $(PHDR) - cc -j $< -I$(INCLUDE) $(XCFLAGS) - -# if the header files change, recompile -$(POBJ): $(PHDR) -$(PUBJ): $(PHDR) -$(OBJ): $(PHDR) -$(UBJ): $(PHDR) - -$(TARGET): $(SRC) $(OBJ) $(HDR) $(LIBS) $(MNEMLIB) - $(PURE) $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJ) $(LIBS) $(MNEMLIB) -lm - -# optimize (DECstations and Alphas only: uses u-code) -$(TARGETu): $(SRC) $(UBJ) $(HDR) $(LIBS:.a=.b) - $(CC) -O3 -Olimit 1000 $(XCFLAGS) $(LDFLAGS) -o $@ $(UBJ) $(BLIBS) -lm - -lint: llib-l$(P).ln - -llib-l$(P).ln: $(PSRC) $(PHDR) - lint $(LINTFLAGS) $(LINTSWITCH)$(P) -I$(INCLUDE) $(PSRC) - -lintpgm: lint - lint $(LINTFLAGS) -I$(INCLUDE) $(SRC) $(LINTLIBS) - -tags: $(PSRC) $(PHDR) - ctags $(PSRC) $(PHDR) - -all: lib$(P).a lib$(P).b llib-l$(P).ln tags - -programs: $(TARGET) $(TARGETu) lintpgm - -clean: - rm -f *.o *.u mon.out gmon.out *.pixie *.Addrs *.Counts mnem.* \ - .pure core *.warnings - -distclean: clean - rm -f $(TARGET) $(TARGETu) lib*.a lib$(P).b llib-l$(P).ln \ - *.bak *~ tags .gdb_history *.qv *.qx diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cudd.h b/resources/3rdparty/cudd-2.5.0/src/cudd/cudd.h deleted file mode 100644 index bba6713d2..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cudd.h +++ /dev/null @@ -1,1090 +0,0 @@ -/**CHeaderFile***************************************************************** - - FileName [cudd.h] - - PackageName [cudd] - - Synopsis [The University of Colorado decision diagram package.] - - Description [External functions and data strucures of the CUDD package. - <ul> - <li> To turn on the gathering of statistics, define DD_STATS. - <li> To link with mis, define DD_MIS. - </ul> - Modified by Abelardo Pardo to interface it to VIS. - ] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado - - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - - Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - - Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - - Neither the name of the University of Colorado nor the names of its - contributors may be used to endorse or promote products derived from - this software without specific prior written permission. - - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, - BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] - - Revision [$Id: cudd.h,v 1.180 2012/02/05 01:07:18 fabio Exp $] - -******************************************************************************/ - -#ifndef _CUDD -#define _CUDD - -/*---------------------------------------------------------------------------*/ -/* Nested includes */ -/*---------------------------------------------------------------------------*/ - -#include "mtr.h" -#include "epd.h" - -#ifdef __cplusplus -extern "C" { -#endif - -/*---------------------------------------------------------------------------*/ -/* Constant declarations */ -/*---------------------------------------------------------------------------*/ - -#define CUDD_VERSION "2.5.0" - -#ifndef SIZEOF_VOID_P -#define SIZEOF_VOID_P 4 -#endif -#ifndef SIZEOF_INT -#define SIZEOF_INT 4 -#endif -#ifndef SIZEOF_LONG -#define SIZEOF_LONG 4 -#endif - -#define CUDD_TRUE 1 -#define CUDD_FALSE 0 - -#define CUDD_VALUE_TYPE double -#define CUDD_OUT_OF_MEM -1 -/* The sizes of the subtables and the cache must be powers of two. */ -#define CUDD_UNIQUE_SLOTS 256 /* initial size of subtables */ -#define CUDD_CACHE_SLOTS 262144 /* default size of the cache */ - -/* Constants for residue functions. */ -#define CUDD_RESIDUE_DEFAULT 0 -#define CUDD_RESIDUE_MSB 1 -#define CUDD_RESIDUE_TC 2 - -/* CUDD_MAXINDEX is defined in such a way that on 32-bit and 64-bit -** machines one can cast an index to (int) without generating a negative -** number. -*/ -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 -#define CUDD_MAXINDEX (((DdHalfWord) ~0) >> 1) -#else -#define CUDD_MAXINDEX ((DdHalfWord) ~0) -#endif - -/* CUDD_CONST_INDEX is the index of constant nodes. Currently this -** is a synonim for CUDD_MAXINDEX. */ -#define CUDD_CONST_INDEX CUDD_MAXINDEX - -/* These constants define the digits used in the representation of -** arbitrary precision integers. The configurations tested use 8, 16, -** and 32 bits for each digit. The typedefs should be in agreement -** with these definitions. -*/ -#if SIZEOF_LONG == 8 -#define DD_APA_BITS 32 -#define DD_APA_BASE (1L << DD_APA_BITS) -#define DD_APA_HEXPRINT "%08x" -#else -#define DD_APA_BITS 16 -#define DD_APA_BASE (1 << DD_APA_BITS) -#define DD_APA_HEXPRINT "%04x" -#endif -#define DD_APA_MASK (DD_APA_BASE - 1) - -/*---------------------------------------------------------------------------*/ -/* Stucture declarations */ -/*---------------------------------------------------------------------------*/ - - -/*---------------------------------------------------------------------------*/ -/* Type declarations */ -/*---------------------------------------------------------------------------*/ - -/**Enum************************************************************************ - - Synopsis [Type of reordering algorithm.] - - Description [Type of reordering algorithm.] - -******************************************************************************/ -typedef enum { - CUDD_REORDER_SAME, - CUDD_REORDER_NONE, - CUDD_REORDER_RANDOM, - CUDD_REORDER_RANDOM_PIVOT, - CUDD_REORDER_SIFT, - CUDD_REORDER_SIFT_CONVERGE, - CUDD_REORDER_SYMM_SIFT, - CUDD_REORDER_SYMM_SIFT_CONV, - CUDD_REORDER_WINDOW2, - CUDD_REORDER_WINDOW3, - CUDD_REORDER_WINDOW4, - CUDD_REORDER_WINDOW2_CONV, - CUDD_REORDER_WINDOW3_CONV, - CUDD_REORDER_WINDOW4_CONV, - CUDD_REORDER_GROUP_SIFT, - CUDD_REORDER_GROUP_SIFT_CONV, - CUDD_REORDER_ANNEALING, - CUDD_REORDER_GENETIC, - CUDD_REORDER_LINEAR, - CUDD_REORDER_LINEAR_CONVERGE, - CUDD_REORDER_LAZY_SIFT, - CUDD_REORDER_EXACT -} Cudd_ReorderingType; - - -/**Enum************************************************************************ - - Synopsis [Type of aggregation methods.] - - Description [Type of aggregation methods.] - -******************************************************************************/ -typedef enum { - CUDD_NO_CHECK, - CUDD_GROUP_CHECK, - CUDD_GROUP_CHECK2, - CUDD_GROUP_CHECK3, - CUDD_GROUP_CHECK4, - CUDD_GROUP_CHECK5, - CUDD_GROUP_CHECK6, - CUDD_GROUP_CHECK7, - CUDD_GROUP_CHECK8, - CUDD_GROUP_CHECK9 -} Cudd_AggregationType; - - -/**Enum************************************************************************ - - Synopsis [Type of hooks.] - - Description [Type of hooks.] - -******************************************************************************/ -typedef enum { - CUDD_PRE_GC_HOOK, - CUDD_POST_GC_HOOK, - CUDD_PRE_REORDERING_HOOK, - CUDD_POST_REORDERING_HOOK -} Cudd_HookType; - - -/**Enum************************************************************************ - - Synopsis [Type of error codes.] - - Description [Type of error codes.] - -******************************************************************************/ -typedef enum { - CUDD_NO_ERROR, - CUDD_MEMORY_OUT, - CUDD_TOO_MANY_NODES, - CUDD_MAX_MEM_EXCEEDED, - CUDD_TIMEOUT_EXPIRED, - CUDD_INVALID_ARG, - CUDD_INTERNAL_ERROR -} Cudd_ErrorType; - - -/**Enum************************************************************************ - - Synopsis [Group type for lazy sifting.] - - Description [Group type for lazy sifting.] - -******************************************************************************/ -typedef enum { - CUDD_LAZY_NONE, - CUDD_LAZY_SOFT_GROUP, - CUDD_LAZY_HARD_GROUP, - CUDD_LAZY_UNGROUP -} Cudd_LazyGroupType; - - -/**Enum************************************************************************ - - Synopsis [Variable type.] - - Description [Variable type. Currently used only in lazy sifting.] - -******************************************************************************/ -typedef enum { - CUDD_VAR_PRIMARY_INPUT, - CUDD_VAR_PRESENT_STATE, - CUDD_VAR_NEXT_STATE -} Cudd_VariableType; - - -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 -typedef unsigned int DdHalfWord; -#else -typedef unsigned short DdHalfWord; -#endif - -typedef struct DdNode DdNode; - -typedef struct DdChildren { - struct DdNode *T; - struct DdNode *E; -} DdChildren; - -/* The DdNode structure is the only one exported out of the package */ -struct DdNode { - DdHalfWord index; - DdHalfWord ref; /* reference count */ - DdNode *next; /* next pointer for unique table */ - union { - CUDD_VALUE_TYPE value; /* for constant nodes */ - DdChildren kids; /* for internal nodes */ - } type; -}; - -typedef struct DdManager DdManager; - -typedef struct DdGen DdGen; - -/* These typedefs for arbitrary precision arithmetic should agree with -** the corresponding constant definitions above. */ -#if SIZEOF_LONG == 8 -typedef unsigned int DdApaDigit; -typedef unsigned long int DdApaDoubleDigit; -#else -typedef unsigned short int DdApaDigit; -typedef unsigned int DdApaDoubleDigit; -#endif -typedef DdApaDigit * DdApaNumber; - -/* Return type for function computing two-literal clauses. */ -typedef struct DdTlcInfo DdTlcInfo; - -/* Type of hook function. */ -typedef int (*DD_HFP)(DdManager *, const char *, void *); -/* Type of priority function */ -typedef DdNode * (*DD_PRFP)(DdManager * , int, DdNode **, DdNode **, - DdNode **); -/* Type of apply operator. */ -typedef DdNode * (*DD_AOP)(DdManager *, DdNode **, DdNode **); -/* Type of monadic apply operator. */ -typedef DdNode * (*DD_MAOP)(DdManager *, DdNode *); -/* Types of cache tag functions. */ -typedef DdNode * (*DD_CTFP)(DdManager *, DdNode *, DdNode *); -typedef DdNode * (*DD_CTFP1)(DdManager *, DdNode *); -/* Type of memory-out function. */ -typedef void (*DD_OOMFP)(long); -/* Type of comparison function for cudd__qsort. */ -typedef int (*DD_QSFP)(const void *, const void *); - -/*---------------------------------------------------------------------------*/ -/* Variable declarations */ -/*---------------------------------------------------------------------------*/ - - -/*---------------------------------------------------------------------------*/ -/* Macro declarations */ -/*---------------------------------------------------------------------------*/ - - -/**Macro*********************************************************************** - - Synopsis [Returns 1 if the node is a constant node.] - - Description [Returns 1 if the node is a constant node (rather than an - internal node). All constant nodes have the same index - (CUDD_CONST_INDEX). The pointer passed to Cudd_IsConstant may be either - regular or complemented.] - - SideEffects [none] - - SeeAlso [] - -******************************************************************************/ -#define Cudd_IsConstant(node) ((Cudd_Regular(node))->index == CUDD_CONST_INDEX) - - -/**Macro*********************************************************************** - - Synopsis [Complements a DD.] - - Description [Complements a DD by flipping the complement attribute of - the pointer (the least significant bit).] - - SideEffects [none] - - SeeAlso [Cudd_NotCond] - -******************************************************************************/ -#define Cudd_Not(node) ((DdNode *)((long)(node) ^ 01)) - - -/**Macro*********************************************************************** - - Synopsis [Complements a DD if a condition is true.] - - Description [Complements a DD if condition c is true; c should be - either 0 or 1, because it is used directly (for efficiency). If in - doubt on the values c may take, use "(c) ? Cudd_Not(node) : node".] - - SideEffects [none] - - SeeAlso [Cudd_Not] - -******************************************************************************/ -#define Cudd_NotCond(node,c) ((DdNode *)((long)(node) ^ (c))) - - -/**Macro*********************************************************************** - - Synopsis [Returns the regular version of a pointer.] - - Description [] - - SideEffects [none] - - SeeAlso [Cudd_Complement Cudd_IsComplement] - -******************************************************************************/ -#define Cudd_Regular(node) ((DdNode *)((unsigned long)(node) & ~01)) - - -/**Macro*********************************************************************** - - Synopsis [Returns the complemented version of a pointer.] - - Description [] - - SideEffects [none] - - SeeAlso [Cudd_Regular Cudd_IsComplement] - -******************************************************************************/ -#define Cudd_Complement(node) ((DdNode *)((unsigned long)(node) | 01)) - - -/**Macro*********************************************************************** - - Synopsis [Returns 1 if a pointer is complemented.] - - Description [] - - SideEffects [none] - - SeeAlso [Cudd_Regular Cudd_Complement] - -******************************************************************************/ -#define Cudd_IsComplement(node) ((int) ((long) (node) & 01)) - - -/**Macro*********************************************************************** - - Synopsis [Returns the then child of an internal node.] - - Description [Returns the then child of an internal node. If - <code>node</code> is a constant node, the result is unpredictable.] - - SideEffects [none] - - SeeAlso [Cudd_E Cudd_V] - -******************************************************************************/ -#define Cudd_T(node) ((Cudd_Regular(node))->type.kids.T) - - -/**Macro*********************************************************************** - - Synopsis [Returns the else child of an internal node.] - - Description [Returns the else child of an internal node. If - <code>node</code> is a constant node, the result is unpredictable.] - - SideEffects [none] - - SeeAlso [Cudd_T Cudd_V] - -******************************************************************************/ -#define Cudd_E(node) ((Cudd_Regular(node))->type.kids.E) - - -/**Macro*********************************************************************** - - Synopsis [Returns the value of a constant node.] - - Description [Returns the value of a constant node. If - <code>node</code> is an internal node, the result is unpredictable.] - - SideEffects [none] - - SeeAlso [Cudd_T Cudd_E] - -******************************************************************************/ -#define Cudd_V(node) ((Cudd_Regular(node))->type.value) - - -/**Macro*********************************************************************** - - Synopsis [Returns the current position in the order of variable - index.] - - Description [Returns the current position in the order of variable - index. This macro is obsolete and is kept for compatibility. New - applications should use Cudd_ReadPerm instead.] - - SideEffects [none] - - SeeAlso [Cudd_ReadPerm] - -******************************************************************************/ -#define Cudd_ReadIndex(dd,index) (Cudd_ReadPerm(dd,index)) - - -/**Macro*********************************************************************** - - Synopsis [Iterates over the cubes of a decision diagram.] - - Description [Iterates over the cubes of a decision diagram f. - <ul> - <li> DdManager *manager; - <li> DdNode *f; - <li> DdGen *gen; - <li> int *cube; - <li> CUDD_VALUE_TYPE value; - </ul> - Cudd_ForeachCube allocates and frees the generator. Therefore the - application should not try to do that. Also, the cube is freed at the - end of Cudd_ForeachCube and hence is not available outside of the loop.<p> - CAUTION: It is assumed that dynamic reordering will not occur while - there are open generators. It is the user's responsibility to make sure - that dynamic reordering does not occur. As long as new nodes are not created - during generation, and dynamic reordering is not called explicitly, - dynamic reordering will not occur. Alternatively, it is sufficient to - disable dynamic reordering. It is a mistake to dispose of a diagram - on which generation is ongoing.] - - SideEffects [none] - - SeeAlso [Cudd_ForeachNode Cudd_FirstCube Cudd_NextCube Cudd_GenFree - Cudd_IsGenEmpty Cudd_AutodynDisable] - -******************************************************************************/ -#define Cudd_ForeachCube(manager, f, gen, cube, value)\ - for((gen) = Cudd_FirstCube(manager, f, &cube, &value);\ - Cudd_IsGenEmpty(gen) ? Cudd_GenFree(gen) : CUDD_TRUE;\ - (void) Cudd_NextCube(gen, &cube, &value)) - - -/**Macro*********************************************************************** - - Synopsis [Iterates over the primes of a Boolean function.] - - Description [Iterates over the primes of a Boolean function producing - a prime and irredundant cover. - <ul> - <li> DdManager *manager; - <li> DdNode *l; - <li> DdNode *u; - <li> DdGen *gen; - <li> int *cube; - </ul> - The Boolean function is described by an upper bound and a lower bound. If - the function is completely specified, the two bounds coincide. - Cudd_ForeachPrime allocates and frees the generator. Therefore the - application should not try to do that. Also, the cube is freed at the - end of Cudd_ForeachPrime and hence is not available outside of the loop.<p> - CAUTION: It is a mistake to change a diagram on which generation is ongoing.] - - SideEffects [none] - - SeeAlso [Cudd_ForeachCube Cudd_FirstPrime Cudd_NextPrime Cudd_GenFree - Cudd_IsGenEmpty] - -******************************************************************************/ -#define Cudd_ForeachPrime(manager, l, u, gen, cube)\ - for((gen) = Cudd_FirstPrime(manager, l, u, &cube);\ - Cudd_IsGenEmpty(gen) ? Cudd_GenFree(gen) : CUDD_TRUE;\ - (void) Cudd_NextPrime(gen, &cube)) - - -/**Macro*********************************************************************** - - Synopsis [Iterates over the nodes of a decision diagram.] - - Description [Iterates over the nodes of a decision diagram f. - <ul> - <li> DdManager *manager; - <li> DdNode *f; - <li> DdGen *gen; - <li> DdNode *node; - </ul> - The nodes are returned in a seemingly random order. - Cudd_ForeachNode allocates and frees the generator. Therefore the - application should not try to do that.<p> - CAUTION: It is assumed that dynamic reordering will not occur while - there are open generators. It is the user's responsibility to make sure - that dynamic reordering does not occur. As long as new nodes are not created - during generation, and dynamic reordering is not called explicitly, - dynamic reordering will not occur. Alternatively, it is sufficient to - disable dynamic reordering. It is a mistake to dispose of a diagram - on which generation is ongoing.] - - SideEffects [none] - - SeeAlso [Cudd_ForeachCube Cudd_FirstNode Cudd_NextNode Cudd_GenFree - Cudd_IsGenEmpty Cudd_AutodynDisable] - -******************************************************************************/ -#define Cudd_ForeachNode(manager, f, gen, node)\ - for((gen) = Cudd_FirstNode(manager, f, &node);\ - Cudd_IsGenEmpty(gen) ? Cudd_GenFree(gen) : CUDD_TRUE;\ - (void) Cudd_NextNode(gen, &node)) - - -/**Macro*********************************************************************** - - Synopsis [Iterates over the paths of a ZDD.] - - Description [Iterates over the paths of a ZDD f. - <ul> - <li> DdManager *manager; - <li> DdNode *f; - <li> DdGen *gen; - <li> int *path; - </ul> - Cudd_zddForeachPath allocates and frees the generator. Therefore the - application should not try to do that. Also, the path is freed at the - end of Cudd_zddForeachPath and hence is not available outside of the loop.<p> - CAUTION: It is assumed that dynamic reordering will not occur while - there are open generators. It is the user's responsibility to make sure - that dynamic reordering does not occur. As long as new nodes are not created - during generation, and dynamic reordering is not called explicitly, - dynamic reordering will not occur. Alternatively, it is sufficient to - disable dynamic reordering. It is a mistake to dispose of a diagram - on which generation is ongoing.] - - SideEffects [none] - - SeeAlso [Cudd_zddFirstPath Cudd_zddNextPath Cudd_GenFree - Cudd_IsGenEmpty Cudd_AutodynDisable] - -******************************************************************************/ -#define Cudd_zddForeachPath(manager, f, gen, path)\ - for((gen) = Cudd_zddFirstPath(manager, f, &path);\ - Cudd_IsGenEmpty(gen) ? Cudd_GenFree(gen) : CUDD_TRUE;\ - (void) Cudd_zddNextPath(gen, &path)) - - - -/**AutomaticStart*************************************************************/ - -/*---------------------------------------------------------------------------*/ -/* Function prototypes */ -/*---------------------------------------------------------------------------*/ - -extern DdNode * Cudd_addNewVar (DdManager *dd); -extern DdNode * Cudd_addNewVarAtLevel (DdManager *dd, int level); -extern DdNode * Cudd_bddNewVar (DdManager *dd); -extern DdNode * Cudd_bddNewVarAtLevel (DdManager *dd, int level); -extern DdNode * Cudd_addIthVar (DdManager *dd, int i); -extern DdNode * Cudd_bddIthVar (DdManager *dd, int i); -extern DdNode * Cudd_zddIthVar (DdManager *dd, int i); -extern int Cudd_zddVarsFromBddVars (DdManager *dd, int multiplicity); -extern DdNode * Cudd_addConst (DdManager *dd, CUDD_VALUE_TYPE c); -extern int Cudd_IsNonConstant (DdNode *f); -extern unsigned long Cudd_ReadStartTime(DdManager *unique); -extern unsigned long Cudd_ReadElapsedTime(DdManager *unique); -extern void Cudd_SetStartTime(DdManager *unique, unsigned long st); -extern void Cudd_ResetStartTime(DdManager *unique); -extern unsigned long Cudd_ReadTimeLimit(DdManager *unique); -extern void Cudd_SetTimeLimit(DdManager *unique, unsigned long tl); -extern void Cudd_UpdateTimeLimit(DdManager * unique); -extern void Cudd_IncreaseTimeLimit(DdManager * unique, unsigned long increase); -extern void Cudd_UnsetTimeLimit(DdManager *unique); -extern int Cudd_TimeLimited(DdManager *unique); -extern void Cudd_AutodynEnable (DdManager *unique, Cudd_ReorderingType method); -extern void Cudd_AutodynDisable (DdManager *unique); -extern int Cudd_ReorderingStatus (DdManager *unique, Cudd_ReorderingType *method); -extern void Cudd_AutodynEnableZdd (DdManager *unique, Cudd_ReorderingType method); -extern void Cudd_AutodynDisableZdd (DdManager *unique); -extern int Cudd_ReorderingStatusZdd (DdManager *unique, Cudd_ReorderingType *method); -extern int Cudd_zddRealignmentEnabled (DdManager *unique); -extern void Cudd_zddRealignEnable (DdManager *unique); -extern void Cudd_zddRealignDisable (DdManager *unique); -extern int Cudd_bddRealignmentEnabled (DdManager *unique); -extern void Cudd_bddRealignEnable (DdManager *unique); -extern void Cudd_bddRealignDisable (DdManager *unique); -extern DdNode * Cudd_ReadOne (DdManager *dd); -extern DdNode * Cudd_ReadZddOne (DdManager *dd, int i); -extern DdNode * Cudd_ReadZero (DdManager *dd); -extern DdNode * Cudd_ReadLogicZero (DdManager *dd); -extern DdNode * Cudd_ReadPlusInfinity (DdManager *dd); -extern DdNode * Cudd_ReadMinusInfinity (DdManager *dd); -extern DdNode * Cudd_ReadBackground (DdManager *dd); -extern void Cudd_SetBackground (DdManager *dd, DdNode *bck); -extern unsigned int Cudd_ReadCacheSlots (DdManager *dd); -extern double Cudd_ReadCacheUsedSlots (DdManager * dd); -extern double Cudd_ReadCacheLookUps (DdManager *dd); -extern double Cudd_ReadCacheHits (DdManager *dd); -extern double Cudd_ReadRecursiveCalls (DdManager * dd); -extern unsigned int Cudd_ReadMinHit (DdManager *dd); -extern void Cudd_SetMinHit (DdManager *dd, unsigned int hr); -extern unsigned int Cudd_ReadLooseUpTo (DdManager *dd); -extern void Cudd_SetLooseUpTo (DdManager *dd, unsigned int lut); -extern unsigned int Cudd_ReadMaxCache (DdManager *dd); -extern unsigned int Cudd_ReadMaxCacheHard (DdManager *dd); -extern void Cudd_SetMaxCacheHard (DdManager *dd, unsigned int mc); -extern int Cudd_ReadSize (DdManager *dd); -extern int Cudd_ReadZddSize (DdManager *dd); -extern unsigned int Cudd_ReadSlots (DdManager *dd); -extern double Cudd_ReadUsedSlots (DdManager * dd); -extern double Cudd_ExpectedUsedSlots (DdManager * dd); -extern unsigned int Cudd_ReadKeys (DdManager *dd); -extern unsigned int Cudd_ReadDead (DdManager *dd); -extern unsigned int Cudd_ReadMinDead (DdManager *dd); -extern unsigned int Cudd_ReadReorderings (DdManager *dd); -extern unsigned int Cudd_ReadMaxReorderings (DdManager *dd); -extern void Cudd_SetMaxReorderings (DdManager *dd, unsigned int mr); -extern long Cudd_ReadReorderingTime (DdManager * dd); -extern int Cudd_ReadGarbageCollections (DdManager * dd); -extern long Cudd_ReadGarbageCollectionTime (DdManager * dd); -extern double Cudd_ReadNodesFreed (DdManager * dd); -extern double Cudd_ReadNodesDropped (DdManager * dd); -extern double Cudd_ReadUniqueLookUps (DdManager * dd); -extern double Cudd_ReadUniqueLinks (DdManager * dd); -extern int Cudd_ReadSiftMaxVar (DdManager *dd); -extern void Cudd_SetSiftMaxVar (DdManager *dd, int smv); -extern int Cudd_ReadSiftMaxSwap (DdManager *dd); -extern void Cudd_SetSiftMaxSwap (DdManager *dd, int sms); -extern double Cudd_ReadMaxGrowth (DdManager *dd); -extern void Cudd_SetMaxGrowth (DdManager *dd, double mg); -extern double Cudd_ReadMaxGrowthAlternate (DdManager * dd); -extern void Cudd_SetMaxGrowthAlternate (DdManager * dd, double mg); -extern int Cudd_ReadReorderingCycle (DdManager * dd); -extern void Cudd_SetReorderingCycle (DdManager * dd, int cycle); -extern MtrNode * Cudd_ReadTree (DdManager *dd); -extern void Cudd_SetTree (DdManager *dd, MtrNode *tree); -extern void Cudd_FreeTree (DdManager *dd); -extern MtrNode * Cudd_ReadZddTree (DdManager *dd); -extern void Cudd_SetZddTree (DdManager *dd, MtrNode *tree); -extern void Cudd_FreeZddTree (DdManager *dd); -extern unsigned int Cudd_NodeReadIndex (DdNode *node); -extern int Cudd_ReadPerm (DdManager *dd, int i); -extern int Cudd_ReadPermZdd (DdManager *dd, int i); -extern int Cudd_ReadInvPerm (DdManager *dd, int i); -extern int Cudd_ReadInvPermZdd (DdManager *dd, int i); -extern DdNode * Cudd_ReadVars (DdManager *dd, int i); -extern CUDD_VALUE_TYPE Cudd_ReadEpsilon (DdManager *dd); -extern void Cudd_SetEpsilon (DdManager *dd, CUDD_VALUE_TYPE ep); -extern Cudd_AggregationType Cudd_ReadGroupcheck (DdManager *dd); -extern void Cudd_SetGroupcheck (DdManager *dd, Cudd_AggregationType gc); -extern int Cudd_GarbageCollectionEnabled (DdManager *dd); -extern void Cudd_EnableGarbageCollection (DdManager *dd); -extern void Cudd_DisableGarbageCollection (DdManager *dd); -extern int Cudd_DeadAreCounted (DdManager *dd); -extern void Cudd_TurnOnCountDead (DdManager *dd); -extern void Cudd_TurnOffCountDead (DdManager *dd); -extern int Cudd_ReadRecomb (DdManager *dd); -extern void Cudd_SetRecomb (DdManager *dd, int recomb); -extern int Cudd_ReadSymmviolation (DdManager *dd); -extern void Cudd_SetSymmviolation (DdManager *dd, int symmviolation); -extern int Cudd_ReadArcviolation (DdManager *dd); -extern void Cudd_SetArcviolation (DdManager *dd, int arcviolation); -extern int Cudd_ReadPopulationSize (DdManager *dd); -extern void Cudd_SetPopulationSize (DdManager *dd, int populationSize); -extern int Cudd_ReadNumberXovers (DdManager *dd); -extern void Cudd_SetNumberXovers (DdManager *dd, int numberXovers); -extern unsigned int Cudd_ReadOrderRandomization(DdManager * dd); -extern void Cudd_SetOrderRandomization(DdManager * dd, unsigned int factor); -extern unsigned long Cudd_ReadMemoryInUse (DdManager *dd); -extern int Cudd_PrintInfo (DdManager *dd, FILE *fp); -extern long Cudd_ReadPeakNodeCount (DdManager *dd); -extern int Cudd_ReadPeakLiveNodeCount (DdManager * dd); -extern long Cudd_ReadNodeCount (DdManager *dd); -extern long Cudd_zddReadNodeCount (DdManager *dd); -extern int Cudd_AddHook (DdManager *dd, DD_HFP f, Cudd_HookType where); -extern int Cudd_RemoveHook (DdManager *dd, DD_HFP f, Cudd_HookType where); -extern int Cudd_IsInHook (DdManager * dd, DD_HFP f, Cudd_HookType where); -extern int Cudd_StdPreReordHook (DdManager *dd, const char *str, void *data); -extern int Cudd_StdPostReordHook (DdManager *dd, const char *str, void *data); -extern int Cudd_EnableReorderingReporting (DdManager *dd); -extern int Cudd_DisableReorderingReporting (DdManager *dd); -extern int Cudd_ReorderingReporting (DdManager *dd); -extern int Cudd_PrintGroupedOrder(DdManager * dd, const char *str, void *data); -extern int Cudd_EnableOrderingMonitoring(DdManager *dd); -extern int Cudd_DisableOrderingMonitoring(DdManager *dd); -extern int Cudd_OrderingMonitoring(DdManager *dd); -extern Cudd_ErrorType Cudd_ReadErrorCode (DdManager *dd); -extern void Cudd_ClearErrorCode (DdManager *dd); -extern FILE * Cudd_ReadStdout (DdManager *dd); -extern void Cudd_SetStdout (DdManager *dd, FILE *fp); -extern FILE * Cudd_ReadStderr (DdManager *dd); -extern void Cudd_SetStderr (DdManager *dd, FILE *fp); -extern unsigned int Cudd_ReadNextReordering (DdManager *dd); -extern void Cudd_SetNextReordering (DdManager *dd, unsigned int next); -extern double Cudd_ReadSwapSteps (DdManager *dd); -extern unsigned int Cudd_ReadMaxLive (DdManager *dd); -extern void Cudd_SetMaxLive (DdManager *dd, unsigned int maxLive); -extern unsigned long Cudd_ReadMaxMemory (DdManager *dd); -extern void Cudd_SetMaxMemory (DdManager *dd, unsigned long maxMemory); -extern int Cudd_bddBindVar (DdManager *dd, int index); -extern int Cudd_bddUnbindVar (DdManager *dd, int index); -extern int Cudd_bddVarIsBound (DdManager *dd, int index); -extern DdNode * Cudd_addExistAbstract (DdManager *manager, DdNode *f, DdNode *cube); -extern DdNode * Cudd_addUnivAbstract (DdManager *manager, DdNode *f, DdNode *cube); -extern DdNode * Cudd_addOrAbstract (DdManager *manager, DdNode *f, DdNode *cube); -extern DdNode * Cudd_addMinAbstract(DdManager * manager, DdNode * f, DdNode * cube); -extern DdNode * Cudd_addMaxAbstract(DdManager * manager, DdNode * f, DdNode * cube); -extern DdNode * Cudd_addApply (DdManager *dd, DdNode * (*)(DdManager *, DdNode **, DdNode **), DdNode *f, DdNode *g); -extern DdNode * Cudd_addPlus (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addTimes (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addThreshold (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addSetNZ (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addDivide (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addMinus (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addMinimum (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addMaximum (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addOneZeroMaximum (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addDiff (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addAgreement (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addOr (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addNand (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addNor (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addXor (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addXnor (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addEquals (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addNotEquals (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addGreaterThan (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addGreaterThanEquals (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addLessThan (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addLessThanEquals (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addPow (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addMod (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addLogXY (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addMonadicApply (DdManager * dd, DdNode * (*op)(DdManager *, DdNode *), DdNode * f); -extern DdNode * Cudd_addLog (DdManager * dd, DdNode * f); -extern DdNode * Cudd_addFloor (DdManager * dd, DdNode * f); -extern DdNode * Cudd_addCeil (DdManager * dd, DdNode * f); -extern DdNode * Cudd_addEquals (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addNotEquals (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addGreaterThan (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addGreaterThanEquals (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addLessThan (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addLessThanEquals (DdManager *dd, DdNode **f, DdNode **g); -extern DdNode * Cudd_addFindMax (DdManager *dd, DdNode *f); -extern DdNode * Cudd_addFindMin (DdManager *dd, DdNode *f); -extern DdNode * Cudd_addIthBit (DdManager *dd, DdNode *f, int bit); -extern DdNode * Cudd_addScalarInverse (DdManager *dd, DdNode *f, DdNode *epsilon); -extern DdNode * Cudd_addIte (DdManager *dd, DdNode *f, DdNode *g, DdNode *h); -extern DdNode * Cudd_addIteConstant (DdManager *dd, DdNode *f, DdNode *g, DdNode *h); -extern DdNode * Cudd_addEvalConst (DdManager *dd, DdNode *f, DdNode *g); -extern int Cudd_addLeq (DdManager * dd, DdNode * f, DdNode * g); -extern DdNode * Cudd_addCmpl (DdManager *dd, DdNode *f); -extern DdNode * Cudd_addNegate (DdManager *dd, DdNode *f); -extern DdNode * Cudd_addRoundOff (DdManager *dd, DdNode *f, int N); -extern DdNode * Cudd_addWalsh (DdManager *dd, DdNode **x, DdNode **y, int n); -extern DdNode * Cudd_addResidue (DdManager *dd, int n, int m, int options, int top); -extern DdNode * Cudd_bddAndAbstract (DdManager *manager, DdNode *f, DdNode *g, DdNode *cube); -extern DdNode * Cudd_bddAndAbstractLimit (DdManager *manager, DdNode *f, DdNode *g, DdNode *cube, unsigned int limit); -extern int Cudd_ApaNumberOfDigits (int binaryDigits); -extern DdApaNumber Cudd_NewApaNumber (int digits); -extern void Cudd_ApaCopy (int digits, DdApaNumber source, DdApaNumber dest); -extern DdApaDigit Cudd_ApaAdd (int digits, DdApaNumber a, DdApaNumber b, DdApaNumber sum); -extern DdApaDigit Cudd_ApaSubtract (int digits, DdApaNumber a, DdApaNumber b, DdApaNumber diff); -extern DdApaDigit Cudd_ApaShortDivision (int digits, DdApaNumber dividend, DdApaDigit divisor, DdApaNumber quotient); -extern unsigned int Cudd_ApaIntDivision (int digits, DdApaNumber dividend, unsigned int divisor, DdApaNumber quotient); -extern void Cudd_ApaShiftRight (int digits, DdApaDigit in, DdApaNumber a, DdApaNumber b); -extern void Cudd_ApaSetToLiteral (int digits, DdApaNumber number, DdApaDigit literal); -extern void Cudd_ApaPowerOfTwo (int digits, DdApaNumber number, int power); -extern int Cudd_ApaCompare (int digitsFirst, DdApaNumber first, int digitsSecond, DdApaNumber second); -extern int Cudd_ApaCompareRatios (int digitsFirst, DdApaNumber firstNum, unsigned int firstDen, int digitsSecond, DdApaNumber secondNum, unsigned int secondDen); -extern int Cudd_ApaPrintHex (FILE *fp, int digits, DdApaNumber number); -extern int Cudd_ApaPrintDecimal (FILE *fp, int digits, DdApaNumber number); -extern int Cudd_ApaPrintExponential (FILE * fp, int digits, DdApaNumber number, int precision); -extern DdApaNumber Cudd_ApaCountMinterm (DdManager *manager, DdNode *node, int nvars, int *digits); -extern int Cudd_ApaPrintMinterm (FILE *fp, DdManager *dd, DdNode *node, int nvars); -extern int Cudd_ApaPrintMintermExp (FILE * fp, DdManager * dd, DdNode * node, int nvars, int precision); -extern int Cudd_ApaPrintDensity (FILE * fp, DdManager * dd, DdNode * node, int nvars); -extern DdNode * Cudd_UnderApprox (DdManager *dd, DdNode *f, int numVars, int threshold, int safe, double quality); -extern DdNode * Cudd_OverApprox (DdManager *dd, DdNode *f, int numVars, int threshold, int safe, double quality); -extern DdNode * Cudd_RemapUnderApprox (DdManager *dd, DdNode *f, int numVars, int threshold, double quality); -extern DdNode * Cudd_RemapOverApprox (DdManager *dd, DdNode *f, int numVars, int threshold, double quality); -extern DdNode * Cudd_BiasedUnderApprox (DdManager *dd, DdNode *f, DdNode *b, int numVars, int threshold, double quality1, double quality0); -extern DdNode * Cudd_BiasedOverApprox (DdManager *dd, DdNode *f, DdNode *b, int numVars, int threshold, double quality1, double quality0); -extern DdNode * Cudd_bddExistAbstract (DdManager *manager, DdNode *f, DdNode *cube); -extern DdNode * Cudd_bddExistAbstractLimit(DdManager * manager, DdNode * f, DdNode * cube, unsigned int limit); -extern DdNode * Cudd_bddXorExistAbstract (DdManager *manager, DdNode *f, DdNode *g, DdNode *cube); -extern DdNode * Cudd_bddUnivAbstract (DdManager *manager, DdNode *f, DdNode *cube); -extern DdNode * Cudd_bddBooleanDiff (DdManager *manager, DdNode *f, int x); -extern int Cudd_bddVarIsDependent (DdManager *dd, DdNode *f, DdNode *var); -extern double Cudd_bddCorrelation (DdManager *manager, DdNode *f, DdNode *g); -extern double Cudd_bddCorrelationWeights (DdManager *manager, DdNode *f, DdNode *g, double *prob); -extern DdNode * Cudd_bddIte (DdManager *dd, DdNode *f, DdNode *g, DdNode *h); - extern DdNode * Cudd_bddIteLimit (DdManager *dd, DdNode *f, DdNode *g, DdNode *h, unsigned int limit); -extern DdNode * Cudd_bddIteConstant (DdManager *dd, DdNode *f, DdNode *g, DdNode *h); -extern DdNode * Cudd_bddIntersect (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_bddAnd (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_bddAndLimit (DdManager *dd, DdNode *f, DdNode *g, unsigned int limit); -extern DdNode * Cudd_bddOr (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_bddOrLimit (DdManager *dd, DdNode *f, DdNode *g, unsigned int limit); -extern DdNode * Cudd_bddNand (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_bddNor (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_bddXor (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_bddXnor (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_bddXnorLimit (DdManager *dd, DdNode *f, DdNode *g, unsigned int limit); -extern int Cudd_bddLeq (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_addBddThreshold (DdManager *dd, DdNode *f, CUDD_VALUE_TYPE value); -extern DdNode * Cudd_addBddStrictThreshold (DdManager *dd, DdNode *f, CUDD_VALUE_TYPE value); -extern DdNode * Cudd_addBddInterval (DdManager *dd, DdNode *f, CUDD_VALUE_TYPE lower, CUDD_VALUE_TYPE upper); -extern DdNode * Cudd_addBddIthBit (DdManager *dd, DdNode *f, int bit); -extern DdNode * Cudd_BddToAdd (DdManager *dd, DdNode *B); -extern DdNode * Cudd_addBddPattern (DdManager *dd, DdNode *f); -extern DdNode * Cudd_bddTransfer (DdManager *ddSource, DdManager *ddDestination, DdNode *f); -extern int Cudd_DebugCheck (DdManager *table); -extern int Cudd_CheckKeys (DdManager *table); -extern DdNode * Cudd_bddClippingAnd (DdManager *dd, DdNode *f, DdNode *g, int maxDepth, int direction); -extern DdNode * Cudd_bddClippingAndAbstract (DdManager *dd, DdNode *f, DdNode *g, DdNode *cube, int maxDepth, int direction); -extern DdNode * Cudd_Cofactor (DdManager *dd, DdNode *f, DdNode *g); -extern int Cudd_CheckCube (DdManager *dd, DdNode *g); -extern DdNode * Cudd_bddCompose (DdManager *dd, DdNode *f, DdNode *g, int v); -extern DdNode * Cudd_addCompose (DdManager *dd, DdNode *f, DdNode *g, int v); -extern DdNode * Cudd_addPermute (DdManager *manager, DdNode *node, int *permut); -extern DdNode * Cudd_addSwapVariables (DdManager *dd, DdNode *f, DdNode **x, DdNode **y, int n); -extern DdNode * Cudd_bddPermute (DdManager *manager, DdNode *node, int *permut); -extern DdNode * Cudd_bddVarMap (DdManager *manager, DdNode *f); -extern int Cudd_SetVarMap (DdManager *manager, DdNode **x, DdNode **y, int n); -extern DdNode * Cudd_bddSwapVariables (DdManager *dd, DdNode *f, DdNode **x, DdNode **y, int n); -extern DdNode * Cudd_bddAdjPermuteX (DdManager *dd, DdNode *B, DdNode **x, int n); -extern DdNode * Cudd_addVectorCompose (DdManager *dd, DdNode *f, DdNode **vector); -extern DdNode * Cudd_addGeneralVectorCompose (DdManager *dd, DdNode *f, DdNode **vectorOn, DdNode **vectorOff); -extern DdNode * Cudd_addNonSimCompose (DdManager *dd, DdNode *f, DdNode **vector); -extern DdNode * Cudd_bddVectorCompose (DdManager *dd, DdNode *f, DdNode **vector); -extern int Cudd_bddApproxConjDecomp (DdManager *dd, DdNode *f, DdNode ***conjuncts); -extern int Cudd_bddApproxDisjDecomp (DdManager *dd, DdNode *f, DdNode ***disjuncts); -extern int Cudd_bddIterConjDecomp (DdManager *dd, DdNode *f, DdNode ***conjuncts); -extern int Cudd_bddIterDisjDecomp (DdManager *dd, DdNode *f, DdNode ***disjuncts); -extern int Cudd_bddGenConjDecomp (DdManager *dd, DdNode *f, DdNode ***conjuncts); -extern int Cudd_bddGenDisjDecomp (DdManager *dd, DdNode *f, DdNode ***disjuncts); -extern int Cudd_bddVarConjDecomp (DdManager *dd, DdNode * f, DdNode ***conjuncts); -extern int Cudd_bddVarDisjDecomp (DdManager *dd, DdNode * f, DdNode ***disjuncts); -extern DdNode * Cudd_FindEssential (DdManager *dd, DdNode *f); -extern int Cudd_bddIsVarEssential (DdManager *manager, DdNode *f, int id, int phase); -extern DdTlcInfo * Cudd_FindTwoLiteralClauses (DdManager * dd, DdNode * f); -extern int Cudd_PrintTwoLiteralClauses (DdManager * dd, DdNode * f, char **names, FILE *fp); -extern int Cudd_ReadIthClause (DdTlcInfo * tlc, int i, DdHalfWord *var1, DdHalfWord *var2, int *phase1, int *phase2); -extern void Cudd_tlcInfoFree (DdTlcInfo * t); -extern int Cudd_DumpBlif (DdManager *dd, int n, DdNode **f, char **inames, char **onames, char *mname, FILE *fp, int mv); -extern int Cudd_DumpBlifBody (DdManager *dd, int n, DdNode **f, char **inames, char **onames, FILE *fp, int mv); -extern int Cudd_DumpDot (DdManager *dd, int n, DdNode **f, char **inames, char **onames, FILE *fp); -extern int Cudd_DumpDaVinci (DdManager *dd, int n, DdNode **f, char **inames, char **onames, FILE *fp); -extern int Cudd_DumpDDcal (DdManager *dd, int n, DdNode **f, char **inames, char **onames, FILE *fp); -extern int Cudd_DumpFactoredForm (DdManager *dd, int n, DdNode **f, char **inames, char **onames, FILE *fp); -extern DdNode * Cudd_bddConstrain (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode * Cudd_bddRestrict (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode * Cudd_bddNPAnd (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode * Cudd_addConstrain (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode ** Cudd_bddConstrainDecomp (DdManager *dd, DdNode *f); -extern DdNode * Cudd_addRestrict (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode ** Cudd_bddCharToVect (DdManager *dd, DdNode *f); -extern DdNode * Cudd_bddLICompaction (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode * Cudd_bddSqueeze (DdManager *dd, DdNode *l, DdNode *u); -extern DdNode * Cudd_bddMinimize (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode * Cudd_SubsetCompress (DdManager *dd, DdNode *f, int nvars, int threshold); -extern DdNode * Cudd_SupersetCompress (DdManager *dd, DdNode *f, int nvars, int threshold); -extern MtrNode * Cudd_MakeTreeNode (DdManager *dd, unsigned int low, unsigned int size, unsigned int type); -extern int Cudd_addHarwell (FILE *fp, DdManager *dd, DdNode **E, DdNode ***x, DdNode ***y, DdNode ***xn, DdNode ***yn_, int *nx, int *ny, int *m, int *n, int bx, int sx, int by, int sy, int pr); -extern DdManager * Cudd_Init (unsigned int numVars, unsigned int numVarsZ, unsigned int numSlots, unsigned int cacheSize, unsigned long maxMemory); -extern void Cudd_Quit (DdManager *unique); -extern int Cudd_PrintLinear (DdManager *table); -extern int Cudd_ReadLinear (DdManager *table, int x, int y); -extern DdNode * Cudd_bddLiteralSetIntersection (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_addMatrixMultiply (DdManager *dd, DdNode *A, DdNode *B, DdNode **z, int nz); -extern DdNode * Cudd_addTimesPlus (DdManager *dd, DdNode *A, DdNode *B, DdNode **z, int nz); -extern DdNode * Cudd_addTriangle (DdManager *dd, DdNode *f, DdNode *g, DdNode **z, int nz); -extern DdNode * Cudd_addOuterSum (DdManager *dd, DdNode *M, DdNode *r, DdNode *c); -extern DdNode * Cudd_PrioritySelect (DdManager *dd, DdNode *R, DdNode **x, DdNode **y, DdNode **z, DdNode *Pi, int n, DdNode * (*)(DdManager *, int, DdNode **, DdNode **, DdNode **)); -extern DdNode * Cudd_Xgty (DdManager *dd, int N, DdNode **z, DdNode **x, DdNode **y); -extern DdNode * Cudd_Xeqy (DdManager *dd, int N, DdNode **x, DdNode **y); -extern DdNode * Cudd_addXeqy (DdManager *dd, int N, DdNode **x, DdNode **y); -extern DdNode * Cudd_Dxygtdxz (DdManager *dd, int N, DdNode **x, DdNode **y, DdNode **z); -extern DdNode * Cudd_Dxygtdyz (DdManager *dd, int N, DdNode **x, DdNode **y, DdNode **z); -extern DdNode * Cudd_Inequality (DdManager * dd, int N, int c, DdNode ** x, DdNode ** y); -extern DdNode * Cudd_Disequality (DdManager * dd, int N, int c, DdNode ** x, DdNode ** y); -extern DdNode * Cudd_bddInterval (DdManager * dd, int N, DdNode ** x, unsigned int lowerB, unsigned int upperB); -extern DdNode * Cudd_CProjection (DdManager *dd, DdNode *R, DdNode *Y); -extern DdNode * Cudd_addHamming (DdManager *dd, DdNode **xVars, DdNode **yVars, int nVars); -extern int Cudd_MinHammingDist (DdManager *dd, DdNode *f, int *minterm, int upperBound); -extern DdNode * Cudd_bddClosestCube (DdManager *dd, DdNode * f, DdNode *g, int *distance); -extern int Cudd_addRead (FILE *fp, DdManager *dd, DdNode **E, DdNode ***x, DdNode ***y, DdNode ***xn, DdNode ***yn_, int *nx, int *ny, int *m, int *n, int bx, int sx, int by, int sy); -extern int Cudd_bddRead (FILE *fp, DdManager *dd, DdNode **E, DdNode ***x, DdNode ***y, int *nx, int *ny, int *m, int *n, int bx, int sx, int by, int sy); -extern void Cudd_Ref (DdNode *n); -extern void Cudd_RecursiveDeref (DdManager *table, DdNode *n); -extern void Cudd_IterDerefBdd (DdManager *table, DdNode *n); -extern void Cudd_DelayedDerefBdd (DdManager * table, DdNode * n); -extern void Cudd_RecursiveDerefZdd (DdManager *table, DdNode *n); -extern void Cudd_Deref (DdNode *node); -extern int Cudd_CheckZeroRef (DdManager *manager); -extern int Cudd_ReduceHeap (DdManager *table, Cudd_ReorderingType heuristic, int minsize); -extern int Cudd_ShuffleHeap (DdManager *table, int *permutation); -extern DdNode * Cudd_Eval (DdManager *dd, DdNode *f, int *inputs); -extern DdNode * Cudd_ShortestPath (DdManager *manager, DdNode *f, int *weight, int *support, int *length); -extern DdNode * Cudd_LargestCube (DdManager *manager, DdNode *f, int *length); -extern int Cudd_ShortestLength (DdManager *manager, DdNode *f, int *weight); -extern DdNode * Cudd_Decreasing (DdManager *dd, DdNode *f, int i); -extern DdNode * Cudd_Increasing (DdManager *dd, DdNode *f, int i); -extern int Cudd_EquivDC (DdManager *dd, DdNode *F, DdNode *G, DdNode *D); -extern int Cudd_bddLeqUnless (DdManager *dd, DdNode *f, DdNode *g, DdNode *D); -extern int Cudd_EqualSupNorm (DdManager *dd, DdNode *f, DdNode *g, CUDD_VALUE_TYPE tolerance, int pr); -extern int Cudd_EqualSupNormRel (DdManager *dd, DdNode *f, DdNode *g, CUDD_VALUE_TYPE tolerance, int pr); -extern DdNode * Cudd_bddMakePrime (DdManager *dd, DdNode *cube, DdNode *f); -extern DdNode * Cudd_bddMaximallyExpand(DdManager *dd, DdNode *lb, DdNode *ub, DdNode *f); -extern DdNode * Cudd_bddLargestPrimeUnate(DdManager *dd , DdNode *f, DdNode *phaseBdd); -extern double * Cudd_CofMinterm (DdManager *dd, DdNode *node); -extern DdNode * Cudd_SolveEqn (DdManager * bdd, DdNode *F, DdNode *Y, DdNode **G, int **yIndex, int n); -extern DdNode * Cudd_VerifySol (DdManager * bdd, DdNode *F, DdNode **G, int *yIndex, int n); -extern DdNode * Cudd_SplitSet (DdManager *manager, DdNode *S, DdNode **xVars, int n, double m); -extern DdNode * Cudd_SubsetHeavyBranch (DdManager *dd, DdNode *f, int numVars, int threshold); -extern DdNode * Cudd_SupersetHeavyBranch (DdManager *dd, DdNode *f, int numVars, int threshold); -extern DdNode * Cudd_SubsetShortPaths (DdManager *dd, DdNode *f, int numVars, int threshold, int hardlimit); -extern DdNode * Cudd_SupersetShortPaths (DdManager *dd, DdNode *f, int numVars, int threshold, int hardlimit); -extern void Cudd_SymmProfile (DdManager *table, int lower, int upper); -extern unsigned int Cudd_Prime (unsigned int p); -extern int Cudd_Reserve(DdManager *manager, int amount); -extern int Cudd_PrintMinterm (DdManager *manager, DdNode *node); -extern int Cudd_bddPrintCover (DdManager *dd, DdNode *l, DdNode *u); -extern int Cudd_PrintDebug (DdManager *dd, DdNode *f, int n, int pr); -extern int Cudd_DagSize (DdNode *node); -extern int Cudd_EstimateCofactor (DdManager *dd, DdNode * node, int i, int phase); -extern int Cudd_EstimateCofactorSimple (DdNode * node, int i); -extern int Cudd_SharingSize (DdNode **nodeArray, int n); -extern double Cudd_CountMinterm (DdManager *manager, DdNode *node, int nvars); -extern int Cudd_EpdCountMinterm (DdManager *manager, DdNode *node, int nvars, EpDouble *epd); -extern double Cudd_CountPath (DdNode *node); -extern double Cudd_CountPathsToNonZero (DdNode *node); -extern int Cudd_SupportIndices(DdManager * dd, DdNode * f, int **indices); -extern DdNode * Cudd_Support (DdManager *dd, DdNode *f); -extern int * Cudd_SupportIndex (DdManager *dd, DdNode *f); -extern int Cudd_SupportSize (DdManager *dd, DdNode *f); -extern int Cudd_VectorSupportIndices(DdManager * dd, DdNode ** F, int n, int **indices); -extern DdNode * Cudd_VectorSupport (DdManager *dd, DdNode **F, int n); -extern int * Cudd_VectorSupportIndex (DdManager *dd, DdNode **F, int n); -extern int Cudd_VectorSupportSize (DdManager *dd, DdNode **F, int n); -extern int Cudd_ClassifySupport (DdManager *dd, DdNode *f, DdNode *g, DdNode **common, DdNode **onlyF, DdNode **onlyG); -extern int Cudd_CountLeaves (DdNode *node); -extern int Cudd_bddPickOneCube (DdManager *ddm, DdNode *node, char *string); -extern DdNode * Cudd_bddPickOneMinterm (DdManager *dd, DdNode *f, DdNode **vars, int n); -extern DdNode ** Cudd_bddPickArbitraryMinterms (DdManager *dd, DdNode *f, DdNode **vars, int n, int k); -extern DdNode * Cudd_SubsetWithMaskVars (DdManager *dd, DdNode *f, DdNode **vars, int nvars, DdNode **maskVars, int mvars); -extern DdGen * Cudd_FirstCube (DdManager *dd, DdNode *f, int **cube, CUDD_VALUE_TYPE *value); -extern int Cudd_NextCube (DdGen *gen, int **cube, CUDD_VALUE_TYPE *value); -extern DdGen * Cudd_FirstPrime(DdManager *dd, DdNode *l, DdNode *u, int **cube); -extern int Cudd_NextPrime(DdGen *gen, int **cube); -extern DdNode * Cudd_bddComputeCube (DdManager *dd, DdNode **vars, int *phase, int n); -extern DdNode * Cudd_addComputeCube (DdManager *dd, DdNode **vars, int *phase, int n); -extern DdNode * Cudd_CubeArrayToBdd (DdManager *dd, int *array); -extern int Cudd_BddToCubeArray (DdManager *dd, DdNode *cube, int *array); -extern DdGen * Cudd_FirstNode (DdManager *dd, DdNode *f, DdNode **node); -extern int Cudd_NextNode (DdGen *gen, DdNode **node); -extern int Cudd_GenFree (DdGen *gen); -extern int Cudd_IsGenEmpty (DdGen *gen); -extern DdNode * Cudd_IndicesToCube (DdManager *dd, int *array, int n); -extern void Cudd_PrintVersion (FILE *fp); -extern double Cudd_AverageDistance (DdManager *dd); -extern long Cudd_Random (void); -extern void Cudd_Srandom (long seed); -extern double Cudd_Density (DdManager *dd, DdNode *f, int nvars); -extern void Cudd_OutOfMem (long size); -extern int Cudd_zddCount (DdManager *zdd, DdNode *P); -extern double Cudd_zddCountDouble (DdManager *zdd, DdNode *P); -extern DdNode * Cudd_zddProduct (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_zddUnateProduct (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_zddWeakDiv (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_zddDivide (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_zddWeakDivF (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_zddDivideF (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * Cudd_zddComplement (DdManager *dd, DdNode *node); -extern MtrNode * Cudd_MakeZddTreeNode (DdManager *dd, unsigned int low, unsigned int size, unsigned int type); -extern DdNode * Cudd_zddIsop (DdManager *dd, DdNode *L, DdNode *U, DdNode **zdd_I); -extern DdNode * Cudd_bddIsop (DdManager *dd, DdNode *L, DdNode *U); -extern DdNode * Cudd_MakeBddFromZddCover (DdManager *dd, DdNode *node); -extern int Cudd_zddDagSize (DdNode *p_node); -extern double Cudd_zddCountMinterm (DdManager *zdd, DdNode *node, int path); -extern void Cudd_zddPrintSubtable (DdManager *table); -extern DdNode * Cudd_zddPortFromBdd (DdManager *dd, DdNode *B); -extern DdNode * Cudd_zddPortToBdd (DdManager *dd, DdNode *f); -extern int Cudd_zddReduceHeap (DdManager *table, Cudd_ReorderingType heuristic, int minsize); -extern int Cudd_zddShuffleHeap (DdManager *table, int *permutation); -extern DdNode * Cudd_zddIte (DdManager *dd, DdNode *f, DdNode *g, DdNode *h); -extern DdNode * Cudd_zddUnion (DdManager *dd, DdNode *P, DdNode *Q); -extern DdNode * Cudd_zddIntersect (DdManager *dd, DdNode *P, DdNode *Q); -extern DdNode * Cudd_zddDiff (DdManager *dd, DdNode *P, DdNode *Q); -extern DdNode * Cudd_zddDiffConst (DdManager *zdd, DdNode *P, DdNode *Q); -extern DdNode * Cudd_zddSubset1 (DdManager *dd, DdNode *P, int var); -extern DdNode * Cudd_zddSubset0 (DdManager *dd, DdNode *P, int var); -extern DdNode * Cudd_zddChange (DdManager *dd, DdNode *P, int var); -extern void Cudd_zddSymmProfile (DdManager *table, int lower, int upper); -extern int Cudd_zddPrintMinterm (DdManager *zdd, DdNode *node); -extern int Cudd_zddPrintCover (DdManager *zdd, DdNode *node); -extern int Cudd_zddPrintDebug (DdManager *zdd, DdNode *f, int n, int pr); -extern DdGen * Cudd_zddFirstPath (DdManager *zdd, DdNode *f, int **path); -extern int Cudd_zddNextPath (DdGen *gen, int **path); -extern char * Cudd_zddCoverPathToString (DdManager *zdd, int *path, char *str); -extern DdNode * Cudd_zddSupport(DdManager * dd, DdNode * f); -extern int Cudd_zddDumpDot (DdManager *dd, int n, DdNode **f, char **inames, char **onames, FILE *fp); -extern int Cudd_bddSetPiVar (DdManager *dd, int index); -extern int Cudd_bddSetPsVar (DdManager *dd, int index); -extern int Cudd_bddSetNsVar (DdManager *dd, int index); -extern int Cudd_bddIsPiVar (DdManager *dd, int index); -extern int Cudd_bddIsPsVar (DdManager *dd, int index); -extern int Cudd_bddIsNsVar (DdManager *dd, int index); -extern int Cudd_bddSetPairIndex (DdManager *dd, int index, int pairIndex); -extern int Cudd_bddReadPairIndex (DdManager *dd, int index); -extern int Cudd_bddSetVarToBeGrouped (DdManager *dd, int index); -extern int Cudd_bddSetVarHardGroup (DdManager *dd, int index); -extern int Cudd_bddResetVarToBeGrouped (DdManager *dd, int index); -extern int Cudd_bddIsVarToBeGrouped (DdManager *dd, int index); -extern int Cudd_bddSetVarToBeUngrouped (DdManager *dd, int index); -extern int Cudd_bddIsVarToBeUngrouped (DdManager *dd, int index); -extern int Cudd_bddIsVarHardGroup (DdManager *dd, int index); - -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} /* end of extern "C" */ -#endif - -#endif /* _CUDD */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAPI.c b/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAPI.c deleted file mode 100644 index 0985cf13d..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAPI.c +++ /dev/null @@ -1,4893 +0,0 @@ -/**CFile*********************************************************************** - - FileName [cuddAPI.c] - - PackageName [cudd] - - Synopsis [Application interface functions.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_addNewVar() - <li> Cudd_addNewVarAtLevel() - <li> Cudd_bddNewVar() - <li> Cudd_bddNewVarAtLevel() - <li> Cudd_addIthVar() - <li> Cudd_bddIthVar() - <li> Cudd_zddIthVar() - <li> Cudd_zddVarsFromBddVars() - <li> Cudd_addConst() - <li> Cudd_IsNonConstant() - <li> Cudd_ReadStartTime() - <li> Cudd_ReadElapsedTime() - <li> Cudd_SetStartTime() - <li> Cudd_ResetStartTime() - <li> Cudd_ReadTimeLimit() - <li> Cudd_SetTimeLimit() - <li> Cudd_UpdateTimeLimit() - <li> Cudd_IncreaseTimeLimit() - <li> Cudd_UnsetTimeLimit() - <li> Cudd_TimeLimited() - <li> Cudd_AutodynEnable() - <li> Cudd_AutodynDisable() - <li> Cudd_ReorderingStatus() - <li> Cudd_AutodynEnableZdd() - <li> Cudd_AutodynDisableZdd() - <li> Cudd_ReorderingStatusZdd() - <li> Cudd_zddRealignmentEnabled() - <li> Cudd_zddRealignEnable() - <li> Cudd_zddRealignDisable() - <li> Cudd_bddRealignmentEnabled() - <li> Cudd_bddRealignEnable() - <li> Cudd_bddRealignDisable() - <li> Cudd_ReadOne() - <li> Cudd_ReadZddOne() - <li> Cudd_ReadZero() - <li> Cudd_ReadLogicZero() - <li> Cudd_ReadPlusInfinity() - <li> Cudd_ReadMinusInfinity() - <li> Cudd_ReadBackground() - <li> Cudd_SetBackground() - <li> Cudd_ReadCacheSlots() - <li> Cudd_ReadCacheUsedSlots() - <li> Cudd_ReadCacheLookUps() - <li> Cudd_ReadCacheHits() - <li> Cudd_ReadMinHit() - <li> Cudd_SetMinHit() - <li> Cudd_ReadLooseUpTo() - <li> Cudd_SetLooseUpTo() - <li> Cudd_ReadMaxCache() - <li> Cudd_ReadMaxCacheHard() - <li> Cudd_SetMaxCacheHard() - <li> Cudd_ReadSize() - <li> Cudd_ReadSlots() - <li> Cudd_ReadUsedSlots() - <li> Cudd_ExpectedUsedSlots() - <li> Cudd_ReadKeys() - <li> Cudd_ReadDead() - <li> Cudd_ReadMinDead() - <li> Cudd_ReadReorderings() - <li> Cudd_ReadMaxReorderings() - <li> Cudd_SetMaxReorderings() - <li> Cudd_ReadReorderingTime() - <li> Cudd_ReadGarbageCollections() - <li> Cudd_ReadGarbageCollectionTime() - <li> Cudd_ReadNodesFreed() - <li> Cudd_ReadNodesDropped() - <li> Cudd_ReadUniqueLookUps() - <li> Cudd_ReadUniqueLinks() - <li> Cudd_ReadSiftMaxVar() - <li> Cudd_SetSiftMaxVar() - <li> Cudd_ReadMaxGrowth() - <li> Cudd_SetMaxGrowth() - <li> Cudd_ReadMaxGrowthAlternate() - <li> Cudd_SetMaxGrowthAlternate() - <li> Cudd_ReadReorderingCycle() - <li> Cudd_SetReorderingCycle() - <li> Cudd_ReadTree() - <li> Cudd_SetTree() - <li> Cudd_FreeTree() - <li> Cudd_ReadZddTree() - <li> Cudd_SetZddTree() - <li> Cudd_FreeZddTree() - <li> Cudd_NodeReadIndex() - <li> Cudd_ReadPerm() - <li> Cudd_ReadInvPerm() - <li> Cudd_ReadVars() - <li> Cudd_ReadEpsilon() - <li> Cudd_SetEpsilon() - <li> Cudd_ReadGroupCheck() - <li> Cudd_SetGroupcheck() - <li> Cudd_GarbageCollectionEnabled() - <li> Cudd_EnableGarbageCollection() - <li> Cudd_DisableGarbageCollection() - <li> Cudd_DeadAreCounted() - <li> Cudd_TurnOnCountDead() - <li> Cudd_TurnOffCountDead() - <li> Cudd_ReadRecomb() - <li> Cudd_SetRecomb() - <li> Cudd_ReadSymmviolation() - <li> Cudd_SetSymmviolation() - <li> Cudd_ReadArcviolation() - <li> Cudd_SetArcviolation() - <li> Cudd_ReadPopulationSize() - <li> Cudd_SetPopulationSize() - <li> Cudd_ReadNumberXovers() - <li> Cudd_SetNumberXovers() - <li> Cudd_ReadOrderRandomization() - <li> Cudd_SetOrderRandomization() - <li> Cudd_ReadMemoryInUse() - <li> Cudd_PrintInfo() - <li> Cudd_ReadPeakNodeCount() - <li> Cudd_ReadPeakLiveNodeCount() - <li> Cudd_ReadNodeCount() - <li> Cudd_zddReadNodeCount() - <li> Cudd_AddHook() - <li> Cudd_RemoveHook() - <li> Cudd_IsInHook() - <li> Cudd_StdPreReordHook() - <li> Cudd_StdPostReordHook() - <li> Cudd_EnableReorderingReporting() - <li> Cudd_DisableReorderingReporting() - <li> Cudd_ReorderingReporting() - <li> Cudd_PrintGroupedOrder() - <li> Cudd_EnableOrderingMonitoring() - <li> Cudd_DisableOrderingMonitoring() - <li> Cudd_OrderingMonitoring() - <li> Cudd_ReadErrorCode() - <li> Cudd_ClearErrorCode() - <li> Cudd_ReadStdout() - <li> Cudd_SetStdout() - <li> Cudd_ReadStderr() - <li> Cudd_SetStderr() - <li> Cudd_ReadNextReordering() - <li> Cudd_SetNextReordering() - <li> Cudd_ReadSwapSteps() - <li> Cudd_ReadMaxLive() - <li> Cudd_SetMaxLive() - <li> Cudd_ReadMaxMemory() - <li> Cudd_SetMaxMemory() - <li> Cudd_bddBindVar() - <li> Cudd_bddUnbindVar() - <li> Cudd_bddVarIsBound() - <li> Cudd_bddSetPiVar() - <li> Cudd_bddSetPsVar() - <li> Cudd_bddSetNsVar() - <li> Cudd_bddIsPiVar() - <li> Cudd_bddIsPsVar() - <li> Cudd_bddIsNsVar() - <li> Cudd_bddSetPairIndex() - <li> Cudd_bddReadPairIndex() - <li> Cudd_bddSetVarToBeGrouped() - <li> Cudd_bddSetVarHardGroup() - <li> Cudd_bddResetVarToBeGrouped() - <li> Cudd_bddIsVarToBeGrouped() - <li> Cudd_bddSetVarToBeUngrouped() - <li> Cudd_bddIsVarToBeUngrouped() - <li> Cudd_bddIsVarHardGroup() - </ul> - Static procedures included in this module: - <ul> - <li> fixVarTree() - </ul>] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado - - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - - Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - - Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - - Neither the name of the University of Colorado nor the names of its - contributors may be used to endorse or promote products derived from - this software without specific prior written permission. - - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, - BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] - -******************************************************************************/ - -#include "util.h" -#include "cuddInt.h" - -/*---------------------------------------------------------------------------*/ -/* Constant declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Stucture declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Type declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Variable declarations */ -/*---------------------------------------------------------------------------*/ - -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddAPI.c,v 1.64 2012/02/05 01:07:18 fabio Exp $"; -#endif - -/*---------------------------------------------------------------------------*/ -/* Macro declarations */ -/*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ - -/*---------------------------------------------------------------------------*/ -/* Static function prototypes */ -/*---------------------------------------------------------------------------*/ - -static void fixVarTree (MtrNode *treenode, int *perm, int size); -static int addMultiplicityGroups (DdManager *dd, MtrNode *treenode, int multiplicity, char *vmask, char *lmask); - -/**AutomaticEnd***************************************************************/ - - -/*---------------------------------------------------------------------------*/ -/* Definition of exported functions */ -/*---------------------------------------------------------------------------*/ - - -/**Function******************************************************************** - - Synopsis [Returns a new ADD variable.] - - Description [Creates a new ADD variable. The new variable has an - index equal to the largest previous index plus 1. Returns a - pointer to the new variable if successful; NULL otherwise. - An ADD variable differs from a BDD variable because it points to the - arithmetic zero, instead of having a complement pointer to 1. ] - - SideEffects [None] - - SeeAlso [Cudd_bddNewVar Cudd_addIthVar Cudd_addConst - Cudd_addNewVarAtLevel] - -******************************************************************************/ -DdNode * -Cudd_addNewVar( - DdManager * dd) -{ - DdNode *res; - - if ((unsigned int) dd->size >= CUDD_MAXINDEX - 1) return(NULL); - do { - dd->reordered = 0; - res = cuddUniqueInter(dd,dd->size,DD_ONE(dd),DD_ZERO(dd)); - } while (dd->reordered == 1); - - return(res); - -} /* end of Cudd_addNewVar */ - - -/**Function******************************************************************** - - Synopsis [Returns a new ADD variable at a specified level.] - - Description [Creates a new ADD variable. The new variable has an - index equal to the largest previous index plus 1 and is positioned at - the specified level in the order. Returns a pointer to the new - variable if successful; NULL otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_addNewVar Cudd_addIthVar Cudd_bddNewVarAtLevel] - -******************************************************************************/ -DdNode * -Cudd_addNewVarAtLevel( - DdManager * dd, - int level) -{ - DdNode *res; - - if ((unsigned int) dd->size >= CUDD_MAXINDEX - 1) return(NULL); - if (level >= dd->size) return(Cudd_addIthVar(dd,level)); - if (!cuddInsertSubtables(dd,1,level)) return(NULL); - do { - dd->reordered = 0; - res = cuddUniqueInter(dd,dd->size - 1,DD_ONE(dd),DD_ZERO(dd)); - } while (dd->reordered == 1); - - return(res); - -} /* end of Cudd_addNewVarAtLevel */ - - -/**Function******************************************************************** - - Synopsis [Returns a new BDD variable.] - - Description [Creates a new BDD variable. The new variable has an - index equal to the largest previous index plus 1. Returns a - pointer to the new variable if successful; NULL otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_addNewVar Cudd_bddIthVar Cudd_bddNewVarAtLevel] - -******************************************************************************/ -DdNode * -Cudd_bddNewVar( - DdManager * dd) -{ - DdNode *res; - - if ((unsigned int) dd->size >= CUDD_MAXINDEX - 1) return(NULL); - res = cuddUniqueInter(dd,dd->size,dd->one,Cudd_Not(dd->one)); - - return(res); - -} /* end of Cudd_bddNewVar */ - - -/**Function******************************************************************** - - Synopsis [Returns a new BDD variable at a specified level.] - - Description [Creates a new BDD variable. The new variable has an - index equal to the largest previous index plus 1 and is positioned at - the specified level in the order. Returns a pointer to the new - variable if successful; NULL otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_bddNewVar Cudd_bddIthVar Cudd_addNewVarAtLevel] - -******************************************************************************/ -DdNode * -Cudd_bddNewVarAtLevel( - DdManager * dd, - int level) -{ - DdNode *res; - - if ((unsigned int) dd->size >= CUDD_MAXINDEX - 1) return(NULL); - if (level >= dd->size) return(Cudd_bddIthVar(dd,level)); - if (!cuddInsertSubtables(dd,1,level)) return(NULL); - res = dd->vars[dd->size - 1]; - - return(res); - -} /* end of Cudd_bddNewVarAtLevel */ - - -/**Function******************************************************************** - - Synopsis [Returns the ADD variable with index i.] - - Description [Retrieves the ADD variable with index i if it already - exists, or creates a new ADD variable. Returns a pointer to the - variable if successful; NULL otherwise. An ADD variable differs from - a BDD variable because it points to the arithmetic zero, instead of - having a complement pointer to 1. ] - - SideEffects [None] - - SeeAlso [Cudd_addNewVar Cudd_bddIthVar Cudd_addConst - Cudd_addNewVarAtLevel] - -******************************************************************************/ -DdNode * -Cudd_addIthVar( - DdManager * dd, - int i) -{ - DdNode *res; - - if ((unsigned int) i >= CUDD_MAXINDEX - 1) return(NULL); - do { - dd->reordered = 0; - res = cuddUniqueInter(dd,i,DD_ONE(dd),DD_ZERO(dd)); - } while (dd->reordered == 1); - - return(res); - -} /* end of Cudd_addIthVar */ - - -/**Function******************************************************************** - - Synopsis [Returns the BDD variable with index i.] - - Description [Retrieves the BDD variable with index i if it already - exists, or creates a new BDD variable. Returns a pointer to the - variable if successful; NULL otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_bddNewVar Cudd_addIthVar Cudd_bddNewVarAtLevel - Cudd_ReadVars] - -******************************************************************************/ -DdNode * -Cudd_bddIthVar( - DdManager * dd, - int i) -{ - DdNode *res; - - if ((unsigned int) i >= CUDD_MAXINDEX - 1) return(NULL); - if (i < dd->size) { - res = dd->vars[i]; - } else { - res = cuddUniqueInter(dd,i,dd->one,Cudd_Not(dd->one)); - } - - return(res); - -} /* end of Cudd_bddIthVar */ - - -/**Function******************************************************************** - - Synopsis [Returns the ZDD variable with index i.] - - Description [Retrieves the ZDD variable with index i if it already - exists, or creates a new ZDD variable. Returns a pointer to the - variable if successful; NULL otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_bddIthVar Cudd_addIthVar] - -******************************************************************************/ -DdNode * -Cudd_zddIthVar( - DdManager * dd, - int i) -{ - DdNode *res; - DdNode *zvar; - DdNode *lower; - int j; - - if ((unsigned int) i >= CUDD_MAXINDEX - 1) return(NULL); - - /* The i-th variable function has the following structure: - ** at the level corresponding to index i there is a node whose "then" - ** child points to the universe, and whose "else" child points to zero. - ** Above that level there are nodes with identical children. - */ - - /* First we build the node at the level of index i. */ - lower = (i < dd->sizeZ - 1) ? dd->univ[dd->permZ[i]+1] : DD_ONE(dd); - do { - dd->reordered = 0; - zvar = cuddUniqueInterZdd(dd, i, lower, DD_ZERO(dd)); - } while (dd->reordered == 1); - - if (zvar == NULL) - return(NULL); - cuddRef(zvar); - - /* Now we add the "filler" nodes above the level of index i. */ - for (j = dd->permZ[i] - 1; j >= 0; j--) { - do { - dd->reordered = 0; - res = cuddUniqueInterZdd(dd, dd->invpermZ[j], zvar, zvar); - } while (dd->reordered == 1); - if (res == NULL) { - Cudd_RecursiveDerefZdd(dd,zvar); - return(NULL); - } - cuddRef(res); - Cudd_RecursiveDerefZdd(dd,zvar); - zvar = res; - } - cuddDeref(zvar); - return(zvar); - -} /* end of Cudd_zddIthVar */ - - -/**Function******************************************************************** - - Synopsis [Creates one or more ZDD variables for each BDD variable.] - - Description [Creates one or more ZDD variables for each BDD - variable. If some ZDD variables already exist, only the missing - variables are created. Parameter multiplicity allows the caller to - control how many variables are created for each BDD variable in - existence. For instance, if ZDDs are used to represent covers, two - ZDD variables are required for each BDD variable. The order of the - BDD variables is transferred to the ZDD variables. If a variable - group tree exists for the BDD variables, a corresponding ZDD - variable group tree is created by expanding the BDD variable - tree. In any case, the ZDD variables derived from the same BDD - variable are merged in a ZDD variable group. If a ZDD variable group - tree exists, it is freed. Returns 1 if successful; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_bddNewVar Cudd_bddIthVar Cudd_bddNewVarAtLevel] - -******************************************************************************/ -int -Cudd_zddVarsFromBddVars( - DdManager * dd /* DD manager */, - int multiplicity /* how many ZDD variables are created for each BDD variable */) -{ - int res; - int i, j; - int allnew; - int *permutation; - - if (multiplicity < 1) return(0); - allnew = dd->sizeZ == 0; - if (dd->size * multiplicity > dd->sizeZ) { - res = cuddResizeTableZdd(dd,dd->size * multiplicity - 1); - if (res == 0) return(0); - } - /* Impose the order of the BDD variables to the ZDD variables. */ - if (allnew) { - for (i = 0; i < dd->size; i++) { - for (j = 0; j < multiplicity; j++) { - dd->permZ[i * multiplicity + j] = - dd->perm[i] * multiplicity + j; - dd->invpermZ[dd->permZ[i * multiplicity + j]] = - i * multiplicity + j; - } - } - for (i = 0; i < dd->sizeZ; i++) { - dd->univ[i]->index = dd->invpermZ[i]; - } - } else { - permutation = ALLOC(int,dd->sizeZ); - if (permutation == NULL) { - dd->errorCode = CUDD_MEMORY_OUT; - return(0); - } - for (i = 0; i < dd->size; i++) { - for (j = 0; j < multiplicity; j++) { - permutation[i * multiplicity + j] = - dd->invperm[i] * multiplicity + j; - } - } - for (i = dd->size * multiplicity; i < dd->sizeZ; i++) { - permutation[i] = i; - } - res = Cudd_zddShuffleHeap(dd, permutation); - FREE(permutation); - if (res == 0) return(0); - } - /* Copy and expand the variable group tree if it exists. */ - if (dd->treeZ != NULL) { - Cudd_FreeZddTree(dd); - } - if (dd->tree != NULL) { - dd->treeZ = Mtr_CopyTree(dd->tree, multiplicity); - if (dd->treeZ == NULL) return(0); - } else if (multiplicity > 1) { - dd->treeZ = Mtr_InitGroupTree(0, dd->sizeZ); - if (dd->treeZ == NULL) return(0); - dd->treeZ->index = dd->invpermZ[0]; - } - /* Create groups for the ZDD variables derived from the same BDD variable. - */ - if (multiplicity > 1) { - char *vmask, *lmask; - - vmask = ALLOC(char, dd->size); - if (vmask == NULL) { - dd->errorCode = CUDD_MEMORY_OUT; - return(0); - } - lmask = ALLOC(char, dd->size); - if (lmask == NULL) { - dd->errorCode = CUDD_MEMORY_OUT; - return(0); - } - for (i = 0; i < dd->size; i++) { - vmask[i] = lmask[i] = 0; - } - res = addMultiplicityGroups(dd,dd->treeZ,multiplicity,vmask,lmask); - FREE(vmask); - FREE(lmask); - if (res == 0) return(0); - } - return(1); - -} /* end of Cudd_zddVarsFromBddVars */ - - -/**Function******************************************************************** - - Synopsis [Returns the ADD for constant c.] - - Description [Retrieves the ADD for constant c if it already - exists, or creates a new ADD. Returns a pointer to the - ADD if successful; NULL otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_addNewVar Cudd_addIthVar] - -******************************************************************************/ -DdNode * -Cudd_addConst( - DdManager * dd, - CUDD_VALUE_TYPE c) -{ - return(cuddUniqueConst(dd,c)); - -} /* end of Cudd_addConst */ - - -/**Function******************************************************************** - - Synopsis [Returns 1 if a DD node is not constant.] - - Description [Returns 1 if a DD node is not constant. This function is - useful to test the results of Cudd_bddIteConstant, Cudd_addIteConstant, - Cudd_addEvalConst. These results may be a special value signifying - non-constant. In the other cases the macro Cudd_IsConstant can be used.] - - SideEffects [None] - - SeeAlso [Cudd_IsConstant Cudd_bddIteConstant Cudd_addIteConstant - Cudd_addEvalConst] - -******************************************************************************/ -int -Cudd_IsNonConstant( - DdNode *f) -{ - return(f == DD_NON_CONSTANT || !Cudd_IsConstant(f)); - -} /* end of Cudd_IsNonConstant */ - - -/**Function******************************************************************** - - Synopsis [Returns the start time of the manager.] - - Description [Returns the start time of the manager. This is initially set - to the number of milliseconds since the program started, but may be reset by - the application.] - - SideEffects [None] - - SeeAlso [Cudd_SetStartTime Cudd_ResetStartTime Cudd_ReadTimeLimit] - -******************************************************************************/ -unsigned long -Cudd_ReadStartTime( - DdManager * unique) -{ - return unique->startTime; - -} /* end of Cudd_ReadStartTime */ - - -/**Function******************************************************************** - - Synopsis [Returns the time elapsed since the start time of the manager.] - - Description [Returns the time elapsed since the start time of the manager.] - - SideEffects [None] - - SeeAlso [Cudd_ReadStartTime Cudd_SetStartTime] - -******************************************************************************/ -unsigned long -Cudd_ReadElapsedTime( - DdManager * unique) -{ - return util_cpu_time() - unique->startTime; - -} /* end of Cudd_ReadElapsedTime */ - - -/**Function******************************************************************** - - Synopsis [Sets the start time of the manager.] - - Description [Sets the start time of the manager.] - - SideEffects [None] - - SeeAlso [Cudd_ReadStartTime Cudd_ResetStartTime Cudd_ReadElapsedTime - Cudd_SetTimeLimit] - -******************************************************************************/ -void -Cudd_SetStartTime( - DdManager * unique, - unsigned long st) -{ - unique->startTime = st; - -} /* end of Cudd_SetStartTime */ - - -/**Function******************************************************************** - - Synopsis [Resets the start time of the manager.] - - Description [Resets the start time of the manager.] - - SideEffects [None] - - SeeAlso [Cudd_ReadStartTime Cudd_SetStartTime Cudd_SetTimeLimit] - -******************************************************************************/ -void -Cudd_ResetStartTime( - DdManager * unique) -{ - unique->startTime = util_cpu_time(); - -} /* end of Cudd_ResetStartTime */ - - -/**Function******************************************************************** - - Synopsis [Returns the time limit for the manager.] - - Description [Returns the time limit for the manager. This is initially set - to a very large number, but may be reset by the application.] - - SideEffects [None] - - SeeAlso [Cudd_SetTimeLimit Cudd_UpdateTimeLimit Cudd_UnsetTimeLimit - Cudd_IncreaseTimeLimit Cudd_TimeLimited Cudd_ReadStartTime] - -******************************************************************************/ -unsigned long -Cudd_ReadTimeLimit( - DdManager * unique) -{ - return unique->timeLimit; - -} /* end of Cudd_ReadTimeLimit */ - - -/**Function******************************************************************** - - Synopsis [Sets the time limit for the manager.] - - Description [Sets the time limit for the manager.] - - SideEffects [None] - - SeeAlso [Cudd_ReadTimeLimit Cudd_UnsetTimeLimit Cudd_UpdateTimeLimit - Cudd_IncreaseTimeLimit Cudd_TimeLimited Cudd_SetStartTime] - -******************************************************************************/ -void -Cudd_SetTimeLimit( - DdManager * unique, - unsigned long tl) -{ - unique->timeLimit = tl; - -} /* end of Cudd_SetTimeLimit */ - - -/**Function******************************************************************** - - Synopsis [Updates the time limit for the manager.] - - Description [Updates the time limit for the manager by subtracting the - elapsed time from it.] - - SideEffects [None] - - SeeAlso [Cudd_ReadTimeLimit Cudd_SetTimeLimit Cudd_UnsetTimeLimit - Cudd_IncreaseTimeLimit Cudd_TimeLimited Cudd_SetStartTime] - -******************************************************************************/ -void -Cudd_UpdateTimeLimit( - DdManager * unique) -{ - unsigned long elapsed; - if (unique->timeLimit == ~0UL) - return; - elapsed = util_cpu_time() - unique->startTime; - if (unique->timeLimit >= elapsed) { - unique->timeLimit -= elapsed; - } else { - unique->timeLimit = 0; - } - -} /* end of Cudd_UpdateTimeLimit */ - - -/**Function******************************************************************** - - Synopsis [Increases the time limit for the manager.] - - Description [Increases the time limit for the manager.] - - SideEffects [None] - - SeeAlso [Cudd_ReadTimeLimit Cudd_SetTimeLimit Cudd_UnsetTimeLimit - Cudd_UpdateTimeLimit Cudd_TimeLimited Cudd_SetStartTime] - -******************************************************************************/ -void -Cudd_IncreaseTimeLimit( - DdManager * unique, - unsigned long increase) -{ - if (unique->timeLimit == ~0UL) - unique->timeLimit = increase; - else - unique->timeLimit += increase; - -} /* end of Cudd_IncreaseTimeLimit */ - - -/**Function******************************************************************** - - Synopsis [Unsets the time limit for the manager.] - - Description [Unsets the time limit for the manager. Actually, sets it to - a very large value.] - - SideEffects [None] - - SeeAlso [Cudd_ReadTimeLimit Cudd_SetTimeLimit Cudd_UpdateTimeLimit - Cudd_IncreaseTimeLimit Cudd_TimeLimited Cudd_SetStartTime] - -******************************************************************************/ -void -Cudd_UnsetTimeLimit( - DdManager * unique) -{ - unique->timeLimit = ~0UL; - -} /* end of Cudd_UnsetTimeLimit */ - - -/**Function******************************************************************** - - Synopsis [Returns true if the time limit for the manager is set.] - - Description [Returns true if the time limit for the manager is set.] - - SideEffects [None] - - SeeAlso [Cudd_ReadTimeLimit Cudd_SetTimeLimit Cudd_UpdateTimeLimit - Cudd_UnsetTimeLimit Cudd_IncreaseTimeLimit] - -******************************************************************************/ -int -Cudd_TimeLimited( - DdManager * unique) -{ - return unique->timeLimit != ~0UL; - -} /* end of Cudd_TimeLimited */ - - -/**Function******************************************************************** - - Synopsis [Enables automatic dynamic reordering of BDDs and ADDs.] - - Description [Enables automatic dynamic reordering of BDDs and - ADDs. Parameter method is used to determine the method used for - reordering. If CUDD_REORDER_SAME is passed, the method is - unchanged.] - - SideEffects [None] - - SeeAlso [Cudd_AutodynDisable Cudd_ReorderingStatus - Cudd_AutodynEnableZdd] - -******************************************************************************/ -void -Cudd_AutodynEnable( - DdManager * unique, - Cudd_ReorderingType method) -{ - unique->autoDyn = 1; - if (method != CUDD_REORDER_SAME) { - unique->autoMethod = method; - } -#ifndef DD_NO_DEATH_ROW - /* If reordering is enabled, using the death row causes too many - ** invocations. Hence, we shrink the death row to just one entry. - */ - cuddClearDeathRow(unique); - unique->deathRowDepth = 1; - unique->deadMask = unique->deathRowDepth - 1; - if ((unsigned) unique->nextDead > unique->deadMask) { - unique->nextDead = 0; - } - unique->deathRow = REALLOC(DdNodePtr, unique->deathRow, - unique->deathRowDepth); -#endif - return; - -} /* end of Cudd_AutodynEnable */ - - -/**Function******************************************************************** - - Synopsis [Disables automatic dynamic reordering.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_AutodynEnable Cudd_ReorderingStatus - Cudd_AutodynDisableZdd] - -******************************************************************************/ -void -Cudd_AutodynDisable( - DdManager * unique) -{ - unique->autoDyn = 0; - return; - -} /* end of Cudd_AutodynDisable */ - - -/**Function******************************************************************** - - Synopsis [Reports the status of automatic dynamic reordering of BDDs - and ADDs.] - - Description [Reports the status of automatic dynamic reordering of - BDDs and ADDs. Parameter method is set to the reordering method - currently selected. Returns 1 if automatic reordering is enabled; 0 - otherwise.] - - SideEffects [Parameter method is set to the reordering method currently - selected.] - - SeeAlso [Cudd_AutodynEnable Cudd_AutodynDisable - Cudd_ReorderingStatusZdd] - -******************************************************************************/ -int -Cudd_ReorderingStatus( - DdManager * unique, - Cudd_ReorderingType * method) -{ - *method = unique->autoMethod; - return(unique->autoDyn); - -} /* end of Cudd_ReorderingStatus */ - - -/**Function******************************************************************** - - Synopsis [Enables automatic dynamic reordering of ZDDs.] - - Description [Enables automatic dynamic reordering of ZDDs. Parameter - method is used to determine the method used for reordering ZDDs. If - CUDD_REORDER_SAME is passed, the method is unchanged.] - - SideEffects [None] - - SeeAlso [Cudd_AutodynDisableZdd Cudd_ReorderingStatusZdd - Cudd_AutodynEnable] - -******************************************************************************/ -void -Cudd_AutodynEnableZdd( - DdManager * unique, - Cudd_ReorderingType method) -{ - unique->autoDynZ = 1; - if (method != CUDD_REORDER_SAME) { - unique->autoMethodZ = method; - } - return; - -} /* end of Cudd_AutodynEnableZdd */ - - -/**Function******************************************************************** - - Synopsis [Disables automatic dynamic reordering of ZDDs.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_AutodynEnableZdd Cudd_ReorderingStatusZdd - Cudd_AutodynDisable] - -******************************************************************************/ -void -Cudd_AutodynDisableZdd( - DdManager * unique) -{ - unique->autoDynZ = 0; - return; - -} /* end of Cudd_AutodynDisableZdd */ - - -/**Function******************************************************************** - - Synopsis [Reports the status of automatic dynamic reordering of ZDDs.] - - Description [Reports the status of automatic dynamic reordering of - ZDDs. Parameter method is set to the ZDD reordering method currently - selected. Returns 1 if automatic reordering is enabled; 0 - otherwise.] - - SideEffects [Parameter method is set to the ZDD reordering method currently - selected.] - - SeeAlso [Cudd_AutodynEnableZdd Cudd_AutodynDisableZdd - Cudd_ReorderingStatus] - -******************************************************************************/ -int -Cudd_ReorderingStatusZdd( - DdManager * unique, - Cudd_ReorderingType * method) -{ - *method = unique->autoMethodZ; - return(unique->autoDynZ); - -} /* end of Cudd_ReorderingStatusZdd */ - - -/**Function******************************************************************** - - Synopsis [Tells whether the realignment of ZDD order to BDD order is - enabled.] - - Description [Returns 1 if the realignment of ZDD order to BDD order is - enabled; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_zddRealignEnable Cudd_zddRealignDisable - Cudd_bddRealignEnable Cudd_bddRealignDisable] - -******************************************************************************/ -int -Cudd_zddRealignmentEnabled( - DdManager * unique) -{ - return(unique->realign); - -} /* end of Cudd_zddRealignmentEnabled */ - - -/**Function******************************************************************** - - Synopsis [Enables realignment of ZDD order to BDD order.] - - Description [Enables realignment of the ZDD variable order to the - BDD variable order after the BDDs and ADDs have been reordered. The - number of ZDD variables must be a multiple of the number of BDD - variables for realignment to make sense. If this condition is not met, - Cudd_ReduceHeap will return 0. Let <code>M</code> be the - ratio of the two numbers. For the purpose of realignment, the ZDD - variables from <code>M*i</code> to <code>(M+1)*i-1</code> are - reagarded as corresponding to BDD variable <code>i</code>. Realignment - is initially disabled.] - - SideEffects [None] - - SeeAlso [Cudd_ReduceHeap Cudd_zddRealignDisable - Cudd_zddRealignmentEnabled Cudd_bddRealignDisable - Cudd_bddRealignmentEnabled] - -******************************************************************************/ -void -Cudd_zddRealignEnable( - DdManager * unique) -{ - unique->realign = 1; - return; - -} /* end of Cudd_zddRealignEnable */ - - -/**Function******************************************************************** - - Synopsis [Disables realignment of ZDD order to BDD order.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_zddRealignEnable Cudd_zddRealignmentEnabled - Cudd_bddRealignEnable Cudd_bddRealignmentEnabled] - -******************************************************************************/ -void -Cudd_zddRealignDisable( - DdManager * unique) -{ - unique->realign = 0; - return; - -} /* end of Cudd_zddRealignDisable */ - - -/**Function******************************************************************** - - Synopsis [Tells whether the realignment of BDD order to ZDD order is - enabled.] - - Description [Returns 1 if the realignment of BDD order to ZDD order is - enabled; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_bddRealignEnable Cudd_bddRealignDisable - Cudd_zddRealignEnable Cudd_zddRealignDisable] - -******************************************************************************/ -int -Cudd_bddRealignmentEnabled( - DdManager * unique) -{ - return(unique->realignZ); - -} /* end of Cudd_bddRealignmentEnabled */ - - -/**Function******************************************************************** - - Synopsis [Enables realignment of BDD order to ZDD order.] - - Description [Enables realignment of the BDD variable order to the - ZDD variable order after the ZDDs have been reordered. The - number of ZDD variables must be a multiple of the number of BDD - variables for realignment to make sense. If this condition is not met, - Cudd_zddReduceHeap will return 0. Let <code>M</code> be the - ratio of the two numbers. For the purpose of realignment, the ZDD - variables from <code>M*i</code> to <code>(M+1)*i-1</code> are - reagarded as corresponding to BDD variable <code>i</code>. Realignment - is initially disabled.] - - SideEffects [None] - - SeeAlso [Cudd_zddReduceHeap Cudd_bddRealignDisable - Cudd_bddRealignmentEnabled Cudd_zddRealignDisable - Cudd_zddRealignmentEnabled] - -******************************************************************************/ -void -Cudd_bddRealignEnable( - DdManager * unique) -{ - unique->realignZ = 1; - return; - -} /* end of Cudd_bddRealignEnable */ - - -/**Function******************************************************************** - - Synopsis [Disables realignment of ZDD order to BDD order.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_bddRealignEnable Cudd_bddRealignmentEnabled - Cudd_zddRealignEnable Cudd_zddRealignmentEnabled] - -******************************************************************************/ -void -Cudd_bddRealignDisable( - DdManager * unique) -{ - unique->realignZ = 0; - return; - -} /* end of Cudd_bddRealignDisable */ - - -/**Function******************************************************************** - - Synopsis [Returns the one constant of the manager.] - - Description [Returns the one constant of the manager. The one - constant is common to ADDs and BDDs.] - - SideEffects [None] - - SeeAlso [Cudd_ReadZero Cudd_ReadLogicZero Cudd_ReadZddOne] - -******************************************************************************/ -DdNode * -Cudd_ReadOne( - DdManager * dd) -{ - return(dd->one); - -} /* end of Cudd_ReadOne */ - - -/**Function******************************************************************** - - Synopsis [Returns the ZDD for the constant 1 function.] - - Description [Returns the ZDD for the constant 1 function. - The representation of the constant 1 function as a ZDD depends on - how many variables it (nominally) depends on. The index of the - topmost variable in the support is given as argument <code>i</code>.] - - SideEffects [None] - - SeeAlso [Cudd_ReadOne] - -******************************************************************************/ -DdNode * -Cudd_ReadZddOne( - DdManager * dd, - int i) -{ - if (i < 0) - return(NULL); - return(i < dd->sizeZ ? dd->univ[i] : DD_ONE(dd)); - -} /* end of Cudd_ReadZddOne */ - - - -/**Function******************************************************************** - - Synopsis [Returns the zero constant of the manager.] - - Description [Returns the zero constant of the manager. The zero - constant is the arithmetic zero, rather than the logic zero. The - latter is the complement of the one constant.] - - SideEffects [None] - - SeeAlso [Cudd_ReadOne Cudd_ReadLogicZero] - -******************************************************************************/ -DdNode * -Cudd_ReadZero( - DdManager * dd) -{ - return(DD_ZERO(dd)); - -} /* end of Cudd_ReadZero */ - - -/**Function******************************************************************** - - Synopsis [Returns the logic zero constant of the manager.] - - Description [Returns the zero constant of the manager. The logic zero - constant is the complement of the one constant, and is distinct from - the arithmetic zero.] - - SideEffects [None] - - SeeAlso [Cudd_ReadOne Cudd_ReadZero] - -******************************************************************************/ -DdNode * -Cudd_ReadLogicZero( - DdManager * dd) -{ - return(Cudd_Not(DD_ONE(dd))); - -} /* end of Cudd_ReadLogicZero */ - - -/**Function******************************************************************** - - Synopsis [Reads the plus-infinity constant from the manager.] - - Description [] - - SideEffects [None] - -******************************************************************************/ -DdNode * -Cudd_ReadPlusInfinity( - DdManager * dd) -{ - return(dd->plusinfinity); - -} /* end of Cudd_ReadPlusInfinity */ - - -/**Function******************************************************************** - - Synopsis [Reads the minus-infinity constant from the manager.] - - Description [] - - SideEffects [None] - -******************************************************************************/ -DdNode * -Cudd_ReadMinusInfinity( - DdManager * dd) -{ - return(dd->minusinfinity); - -} /* end of Cudd_ReadMinusInfinity */ - - -/**Function******************************************************************** - - Synopsis [Reads the background constant of the manager.] - - Description [] - - SideEffects [None] - -******************************************************************************/ -DdNode * -Cudd_ReadBackground( - DdManager * dd) -{ - return(dd->background); - -} /* end of Cudd_ReadBackground */ - - -/**Function******************************************************************** - - Synopsis [Sets the background constant of the manager.] - - Description [Sets the background constant of the manager. It assumes - that the DdNode pointer bck is already referenced.] - - SideEffects [None] - -******************************************************************************/ -void -Cudd_SetBackground( - DdManager * dd, - DdNode * bck) -{ - dd->background = bck; - -} /* end of Cudd_SetBackground */ - - -/**Function******************************************************************** - - Synopsis [Reads the number of slots in the cache.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_ReadCacheUsedSlots] - -******************************************************************************/ -unsigned int -Cudd_ReadCacheSlots( - DdManager * dd) -{ - return(dd->cacheSlots); - -} /* end of Cudd_ReadCacheSlots */ - - -/**Function******************************************************************** - - Synopsis [Reads the fraction of used slots in the cache.] - - Description [Reads the fraction of used slots in the cache. The unused - slots are those in which no valid data is stored. Garbage collection, - variable reordering, and cache resizing may cause used slots to become - unused.] - - SideEffects [None] - - SeeAlso [Cudd_ReadCacheSlots] - -******************************************************************************/ -double -Cudd_ReadCacheUsedSlots( - DdManager * dd) -{ - unsigned long used = 0; - int slots = dd->cacheSlots; - DdCache *cache = dd->cache; - int i; - - for (i = 0; i < slots; i++) { - used += cache[i].h != 0; - } - - return((double)used / (double) dd->cacheSlots); - -} /* end of Cudd_ReadCacheUsedSlots */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of cache look-ups.] - - Description [Returns the number of cache look-ups.] - - SideEffects [None] - - SeeAlso [Cudd_ReadCacheHits] - -******************************************************************************/ -double -Cudd_ReadCacheLookUps( - DdManager * dd) -{ - return(dd->cacheHits + dd->cacheMisses + - dd->totCachehits + dd->totCacheMisses); - -} /* end of Cudd_ReadCacheLookUps */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of cache hits.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_ReadCacheLookUps] - -******************************************************************************/ -double -Cudd_ReadCacheHits( - DdManager * dd) -{ - return(dd->cacheHits + dd->totCachehits); - -} /* end of Cudd_ReadCacheHits */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of recursive calls.] - - Description [Returns the number of recursive calls if the package is - compiled with DD_COUNT defined.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -double -Cudd_ReadRecursiveCalls( - DdManager * dd) -{ -#ifdef DD_COUNT - return(dd->recursiveCalls); -#else - return(-1.0); -#endif - -} /* end of Cudd_ReadRecursiveCalls */ - - - -/**Function******************************************************************** - - Synopsis [Reads the hit rate that causes resizinig of the computed - table.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_SetMinHit] - -******************************************************************************/ -unsigned int -Cudd_ReadMinHit( - DdManager * dd) -{ - /* Internally, the package manipulates the ratio of hits to - ** misses instead of the ratio of hits to accesses. */ - return((unsigned int) (0.5 + 100 * dd->minHit / (1 + dd->minHit))); - -} /* end of Cudd_ReadMinHit */ - - -/**Function******************************************************************** - - Synopsis [Sets the hit rate that causes resizinig of the computed - table.] - - Description [Sets the minHit parameter of the manager. This - parameter controls the resizing of the computed table. If the hit - rate is larger than the specified value, and the cache is not - already too large, then its size is doubled.] - - SideEffects [None] - - SeeAlso [Cudd_ReadMinHit] - -******************************************************************************/ -void -Cudd_SetMinHit( - DdManager * dd, - unsigned int hr) -{ - /* Internally, the package manipulates the ratio of hits to - ** misses instead of the ratio of hits to accesses. */ - dd->minHit = (double) hr / (100.0 - (double) hr); - -} /* end of Cudd_SetMinHit */ - - -/**Function******************************************************************** - - Synopsis [Reads the looseUpTo parameter of the manager.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_SetLooseUpTo Cudd_ReadMinHit Cudd_ReadMinDead] - -******************************************************************************/ -unsigned int -Cudd_ReadLooseUpTo( - DdManager * dd) -{ - return(dd->looseUpTo); - -} /* end of Cudd_ReadLooseUpTo */ - - -/**Function******************************************************************** - - Synopsis [Sets the looseUpTo parameter of the manager.] - - Description [Sets the looseUpTo parameter of the manager. This - parameter of the manager controls the threshold beyond which no fast - growth of the unique table is allowed. The threshold is given as a - number of slots. If the value passed to this function is 0, the - function determines a suitable value based on the available memory.] - - SideEffects [None] - - SeeAlso [Cudd_ReadLooseUpTo Cudd_SetMinHit] - -******************************************************************************/ -void -Cudd_SetLooseUpTo( - DdManager * dd, - unsigned int lut) -{ - if (lut == 0) { - unsigned long datalimit = getSoftDataLimit(); - lut = (unsigned int) (datalimit / (sizeof(DdNode) * - DD_MAX_LOOSE_FRACTION)); - } - dd->looseUpTo = lut; - -} /* end of Cudd_SetLooseUpTo */ - - -/**Function******************************************************************** - - Synopsis [Returns the soft limit for the cache size.] - - Description [Returns the soft limit for the cache size.] - - SideEffects [None] - - SeeAlso [Cudd_ReadMaxCacheHard] - -******************************************************************************/ -unsigned int -Cudd_ReadMaxCache( - DdManager * dd) -{ - return(2 * dd->cacheSlots + dd->cacheSlack); - -} /* end of Cudd_ReadMaxCache */ - - -/**Function******************************************************************** - - Synopsis [Reads the maxCacheHard parameter of the manager.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_SetMaxCacheHard Cudd_ReadMaxCache] - -******************************************************************************/ -unsigned int -Cudd_ReadMaxCacheHard( - DdManager * dd) -{ - return(dd->maxCacheHard); - -} /* end of Cudd_ReadMaxCache */ - - -/**Function******************************************************************** - - Synopsis [Sets the maxCacheHard parameter of the manager.] - - Description [Sets the maxCacheHard parameter of the manager. The - cache cannot grow larger than maxCacheHard entries. This parameter - allows an application to control the trade-off of memory versus - speed. If the value passed to this function is 0, the function - determines a suitable maximum cache size based on the available memory.] - - SideEffects [None] - - SeeAlso [Cudd_ReadMaxCacheHard Cudd_SetMaxCache] - -******************************************************************************/ -void -Cudd_SetMaxCacheHard( - DdManager * dd, - unsigned int mc) -{ - if (mc == 0) { - unsigned long datalimit = getSoftDataLimit(); - mc = (unsigned int) (datalimit / (sizeof(DdCache) * - DD_MAX_CACHE_FRACTION)); - } - dd->maxCacheHard = mc; - -} /* end of Cudd_SetMaxCacheHard */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of BDD variables in existance.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_ReadZddSize] - -******************************************************************************/ -int -Cudd_ReadSize( - DdManager * dd) -{ - return(dd->size); - -} /* end of Cudd_ReadSize */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of ZDD variables in existance.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_ReadSize] - -******************************************************************************/ -int -Cudd_ReadZddSize( - DdManager * dd) -{ - return(dd->sizeZ); - -} /* end of Cudd_ReadZddSize */ - - -/**Function******************************************************************** - - Synopsis [Returns the total number of slots of the unique table.] - - Description [Returns the total number of slots of the unique table. - This number ismainly for diagnostic purposes.] - - SideEffects [None] - -******************************************************************************/ -unsigned int -Cudd_ReadSlots( - DdManager * dd) -{ - return(dd->slots); - -} /* end of Cudd_ReadSlots */ - - -/**Function******************************************************************** - - Synopsis [Reads the fraction of used slots in the unique table.] - - Description [Reads the fraction of used slots in the unique - table. The unused slots are those in which no valid data is - stored. Garbage collection, variable reordering, and subtable - resizing may cause used slots to become unused.] - - SideEffects [None] - - SeeAlso [Cudd_ReadSlots] - -******************************************************************************/ -double -Cudd_ReadUsedSlots( - DdManager * dd) -{ - unsigned long used = 0; - int i, j; - int size = dd->size; - DdNodePtr *nodelist; - DdSubtable *subtable; - DdNode *node; - DdNode *sentinel = &(dd->sentinel); - - /* Scan each BDD/ADD subtable. */ - for (i = 0; i < size; i++) { - subtable = &(dd->subtables[i]); - nodelist = subtable->nodelist; - for (j = 0; (unsigned) j < subtable->slots; j++) { - node = nodelist[j]; - if (node != sentinel) { - used++; - } - } - } - - /* Scan the ZDD subtables. */ - size = dd->sizeZ; - - for (i = 0; i < size; i++) { - subtable = &(dd->subtableZ[i]); - nodelist = subtable->nodelist; - for (j = 0; (unsigned) j < subtable->slots; j++) { - node = nodelist[j]; - if (node != NULL) { - used++; - } - } - } - - /* Constant table. */ - subtable = &(dd->constants); - nodelist = subtable->nodelist; - for (j = 0; (unsigned) j < subtable->slots; j++) { - node = nodelist[j]; - if (node != NULL) { - used++; - } - } - - return((double)used / (double) dd->slots); - -} /* end of Cudd_ReadUsedSlots */ - - -/**Function******************************************************************** - - Synopsis [Computes the expected fraction of used slots in the unique - table.] - - Description [Computes the fraction of slots in the unique table that - should be in use. This expected value is based on the assumption - that the hash function distributes the keys randomly; it can be - compared with the result of Cudd_ReadUsedSlots to monitor the - performance of the unique table hash function.] - - SideEffects [None] - - SeeAlso [Cudd_ReadSlots Cudd_ReadUsedSlots] - -******************************************************************************/ -double -Cudd_ExpectedUsedSlots( - DdManager * dd) -{ - int i; - int size = dd->size; - DdSubtable *subtable; - double empty = 0.0; - - /* To each subtable we apply the corollary to Theorem 8.5 (occupancy - ** distribution) from Sedgewick and Flajolet's Analysis of Algorithms. - ** The corollary says that for a table with M buckets and a load ratio - ** of r, the expected number of empty buckets is asymptotically given - ** by M * exp(-r). - */ - - /* Scan each BDD/ADD subtable. */ - for (i = 0; i < size; i++) { - subtable = &(dd->subtables[i]); - empty += (double) subtable->slots * - exp(-(double) subtable->keys / (double) subtable->slots); - } - - /* Scan the ZDD subtables. */ - size = dd->sizeZ; - - for (i = 0; i < size; i++) { - subtable = &(dd->subtableZ[i]); - empty += (double) subtable->slots * - exp(-(double) subtable->keys / (double) subtable->slots); - } - - /* Constant table. */ - subtable = &(dd->constants); - empty += (double) subtable->slots * - exp(-(double) subtable->keys / (double) subtable->slots); - - return(1.0 - empty / (double) dd->slots); - -} /* end of Cudd_ExpectedUsedSlots */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of nodes in the unique table.] - - Description [Returns the total number of nodes currently in the unique - table, including the dead nodes.] - - SideEffects [None] - - SeeAlso [Cudd_ReadDead] - -******************************************************************************/ -unsigned int -Cudd_ReadKeys( - DdManager * dd) -{ - return(dd->keys); - -} /* end of Cudd_ReadKeys */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of dead nodes in the unique table.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_ReadKeys] - -******************************************************************************/ -unsigned int -Cudd_ReadDead( - DdManager * dd) -{ - return(dd->dead); - -} /* end of Cudd_ReadDead */ - - -/**Function******************************************************************** - - Synopsis [Reads the minDead parameter of the manager.] - - Description [Reads the minDead parameter of the manager. The minDead - parameter is used by the package to decide whether to collect garbage - or resize a subtable of the unique table when the subtable becomes - too full. The application can indirectly control the value of minDead - by setting the looseUpTo parameter.] - - SideEffects [None] - - SeeAlso [Cudd_ReadDead Cudd_ReadLooseUpTo Cudd_SetLooseUpTo] - -******************************************************************************/ -unsigned int -Cudd_ReadMinDead( - DdManager * dd) -{ - return(dd->minDead); - -} /* end of Cudd_ReadMinDead */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of times reordering has occurred.] - - Description [Returns the number of times reordering has occurred in the - manager. The number includes both the calls to Cudd_ReduceHeap from - the application program and those automatically performed by the - package. However, calls that do not even initiate reordering are not - counted. A call may not initiate reordering if there are fewer than - minsize live nodes in the manager, or if CUDD_REORDER_NONE is specified - as reordering method. The calls to Cudd_ShuffleHeap are not counted.] - - SideEffects [None] - - SeeAlso [Cudd_ReduceHeap Cudd_ReadReorderingTime] - -******************************************************************************/ -unsigned int -Cudd_ReadReorderings( - DdManager * dd) -{ - return(dd->reorderings); - -} /* end of Cudd_ReadReorderings */ - - -/**Function******************************************************************** - - Synopsis [Returns the maximum number of times reordering may be invoked.] - - Description [Returns the maximum number of times reordering may be invoked in - this manager.] - - SideEffects [None] - - SeeAlso [Cudd_ReadReorderings Cudd_SetMaxReorderings Cudd_ReduceHeap] - -******************************************************************************/ -unsigned int -Cudd_ReadMaxReorderings( - DdManager * dd) -{ - return(dd->maxReorderings); - -} /* end of Cudd_ReadMaxReorderings */ - - -/**Function******************************************************************** - - Synopsis [Sets the maximum number of times reordering may be invoked.] - - Description [Sets the maximum number of times reordering may be invoked in - this manager. The default value is (practically) infinite.] - - SideEffects [None] - - SeeAlso [Cudd_ReadReorderings Cudd_ReadMaxReorderings Cudd_ReduceHeap] - -******************************************************************************/ -void -Cudd_SetMaxReorderings( - DdManager * dd, unsigned int mr) -{ - dd->maxReorderings = mr; - -} /* end of Cudd_SetMaxReorderings */ - - -/**Function******************************************************************** - - Synopsis [Returns the time spent in reordering.] - - Description [Returns the number of milliseconds spent reordering - variables since the manager was initialized. The time spent in collecting - garbage before reordering is included.] - - SideEffects [None] - - SeeAlso [Cudd_ReadReorderings] - -******************************************************************************/ -long -Cudd_ReadReorderingTime( - DdManager * dd) -{ - return(dd->reordTime); - -} /* end of Cudd_ReadReorderingTime */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of times garbage collection has occurred.] - - Description [Returns the number of times garbage collection has - occurred in the manager. The number includes both the calls from - reordering procedures and those caused by requests to create new - nodes.] - - SideEffects [None] - - SeeAlso [Cudd_ReadGarbageCollectionTime] - -******************************************************************************/ -int -Cudd_ReadGarbageCollections( - DdManager * dd) -{ - return(dd->garbageCollections); - -} /* end of Cudd_ReadGarbageCollections */ - - -/**Function******************************************************************** - - Synopsis [Returns the time spent in garbage collection.] - - Description [Returns the number of milliseconds spent doing garbage - collection since the manager was initialized.] - - SideEffects [None] - - SeeAlso [Cudd_ReadGarbageCollections] - -******************************************************************************/ -long -Cudd_ReadGarbageCollectionTime( - DdManager * dd) -{ - return(dd->GCTime); - -} /* end of Cudd_ReadGarbageCollectionTime */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of nodes freed.] - - Description [Returns the number of nodes returned to the free list if the - keeping of this statistic is enabled; -1 otherwise. This statistic is - enabled only if the package is compiled with DD_STATS defined.] - - SideEffects [None] - - SeeAlso [Cudd_ReadNodesDropped] - -******************************************************************************/ -double -Cudd_ReadNodesFreed( - DdManager * dd) -{ -#ifdef DD_STATS - return(dd->nodesFreed); -#else - return(-1.0); -#endif - -} /* end of Cudd_ReadNodesFreed */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of nodes dropped.] - - Description [Returns the number of nodes killed by dereferencing if the - keeping of this statistic is enabled; -1 otherwise. This statistic is - enabled only if the package is compiled with DD_STATS defined.] - - SideEffects [None] - - SeeAlso [Cudd_ReadNodesFreed] - -******************************************************************************/ -double -Cudd_ReadNodesDropped( - DdManager * dd) -{ -#ifdef DD_STATS - return(dd->nodesDropped); -#else - return(-1.0); -#endif - -} /* end of Cudd_ReadNodesDropped */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of look-ups in the unique table.] - - Description [Returns the number of look-ups in the unique table if the - keeping of this statistic is enabled; -1 otherwise. This statistic is - enabled only if the package is compiled with DD_UNIQUE_PROFILE defined.] - - SideEffects [None] - - SeeAlso [Cudd_ReadUniqueLinks] - -******************************************************************************/ -double -Cudd_ReadUniqueLookUps( - DdManager * dd) -{ -#ifdef DD_UNIQUE_PROFILE - return(dd->uniqueLookUps); -#else - return(-1.0); -#endif - -} /* end of Cudd_ReadUniqueLookUps */ - - -/**Function******************************************************************** - - Synopsis [Returns the number of links followed in the unique table.] - - Description [Returns the number of links followed during look-ups in the - unique table if the keeping of this statistic is enabled; -1 otherwise. - If an item is found in the first position of its collision list, the - number of links followed is taken to be 0. If it is in second position, - the number of links is 1, and so on. This statistic is enabled only if - the package is compiled with DD_UNIQUE_PROFILE defined.] - - SideEffects [None] - - SeeAlso [Cudd_ReadUniqueLookUps] - -******************************************************************************/ -double -Cudd_ReadUniqueLinks( - DdManager * dd) -{ -#ifdef DD_UNIQUE_PROFILE - return(dd->uniqueLinks); -#else - return(-1.0); -#endif - -} /* end of Cudd_ReadUniqueLinks */ - - -/**Function******************************************************************** - - Synopsis [Reads the siftMaxVar parameter of the manager.] - - Description [Reads the siftMaxVar parameter of the manager. This - parameter gives the maximum number of variables that will be sifted - for each invocation of sifting.] - - SideEffects [None] - - SeeAlso [Cudd_ReadSiftMaxSwap Cudd_SetSiftMaxVar] - -******************************************************************************/ -int -Cudd_ReadSiftMaxVar( - DdManager * dd) -{ - return(dd->siftMaxVar); - -} /* end of Cudd_ReadSiftMaxVar */ - - -/**Function******************************************************************** - - Synopsis [Sets the siftMaxVar parameter of the manager.] - - Description [Sets the siftMaxVar parameter of the manager. This - parameter gives the maximum number of variables that will be sifted - for each invocation of sifting.] - - SideEffects [None] - - SeeAlso [Cudd_SetSiftMaxSwap Cudd_ReadSiftMaxVar] - -******************************************************************************/ -void -Cudd_SetSiftMaxVar( - DdManager * dd, - int smv) -{ - dd->siftMaxVar = smv; - -} /* end of Cudd_SetSiftMaxVar */ - - -/**Function******************************************************************** - - Synopsis [Reads the siftMaxSwap parameter of the manager.] - - Description [Reads the siftMaxSwap parameter of the manager. This - parameter gives the maximum number of swaps that will be attempted - for each invocation of sifting. The real number of swaps may exceed - the set limit because the package will always complete the sifting - of the variable that causes the limit to be reached.] - - SideEffects [None] - - SeeAlso [Cudd_ReadSiftMaxVar Cudd_SetSiftMaxSwap] - -******************************************************************************/ -int -Cudd_ReadSiftMaxSwap( - DdManager * dd) -{ - return(dd->siftMaxSwap); - -} /* end of Cudd_ReadSiftMaxSwap */ - - -/**Function******************************************************************** - - Synopsis [Sets the siftMaxSwap parameter of the manager.] - - Description [Sets the siftMaxSwap parameter of the manager. This - parameter gives the maximum number of swaps that will be attempted - for each invocation of sifting. The real number of swaps may exceed - the set limit because the package will always complete the sifting - of the variable that causes the limit to be reached.] - - SideEffects [None] - - SeeAlso [Cudd_SetSiftMaxVar Cudd_ReadSiftMaxSwap] - -******************************************************************************/ -void -Cudd_SetSiftMaxSwap( - DdManager * dd, - int sms) -{ - dd->siftMaxSwap = sms; - -} /* end of Cudd_SetSiftMaxSwap */ - - -/**Function******************************************************************** - - Synopsis [Reads the maxGrowth parameter of the manager.] - - Description [Reads the maxGrowth parameter of the manager. This - parameter determines how much the number of nodes can grow during - sifting of a variable. Overall, sifting never increases the size of - the decision diagrams. This parameter only refers to intermediate - results. A lower value will speed up sifting, possibly at the - expense of quality.] - - SideEffects [None] - - SeeAlso [Cudd_SetMaxGrowth Cudd_ReadMaxGrowthAlternate] - -******************************************************************************/ -double -Cudd_ReadMaxGrowth( - DdManager * dd) -{ - return(dd->maxGrowth); - -} /* end of Cudd_ReadMaxGrowth */ - - -/**Function******************************************************************** - - Synopsis [Sets the maxGrowth parameter of the manager.] - - Description [Sets the maxGrowth parameter of the manager. This - parameter determines how much the number of nodes can grow during - sifting of a variable. Overall, sifting never increases the size of - the decision diagrams. This parameter only refers to intermediate - results. A lower value will speed up sifting, possibly at the - expense of quality.] - - SideEffects [None] - - SeeAlso [Cudd_ReadMaxGrowth Cudd_SetMaxGrowthAlternate] - -******************************************************************************/ -void -Cudd_SetMaxGrowth( - DdManager * dd, - double mg) -{ - dd->maxGrowth = mg; - -} /* end of Cudd_SetMaxGrowth */ - - -/**Function******************************************************************** - - Synopsis [Reads the maxGrowthAlt parameter of the manager.] - - Description [Reads the maxGrowthAlt parameter of the manager. This - parameter is analogous to the maxGrowth paramter, and is used every - given number of reorderings instead of maxGrowth. The number of - reorderings is set with Cudd_SetReorderingCycle. If the number of - reorderings is 0 (default) maxGrowthAlt is never used.] - - SideEffects [None] - - SeeAlso [Cudd_ReadMaxGrowth Cudd_SetMaxGrowthAlternate - Cudd_SetReorderingCycle Cudd_ReadReorderingCycle] - -******************************************************************************/ -double -Cudd_ReadMaxGrowthAlternate( - DdManager * dd) -{ - return(dd->maxGrowthAlt); - -} /* end of Cudd_ReadMaxGrowthAlternate */ - - -/**Function******************************************************************** - - Synopsis [Sets the maxGrowthAlt parameter of the manager.] - - Description [Sets the maxGrowthAlt parameter of the manager. This - parameter is analogous to the maxGrowth paramter, and is used every - given number of reorderings instead of maxGrowth. The number of - reorderings is set with Cudd_SetReorderingCycle. If the number of - reorderings is 0 (default) maxGrowthAlt is never used.] - - SideEffects [None] - - SeeAlso [Cudd_ReadMaxGrowthAlternate Cudd_SetMaxGrowth - Cudd_SetReorderingCycle Cudd_ReadReorderingCycle] - -******************************************************************************/ -void -Cudd_SetMaxGrowthAlternate( - DdManager * dd, - double mg) -{ - dd->maxGrowthAlt = mg; - -} /* end of Cudd_SetMaxGrowthAlternate */ - - -/**Function******************************************************************** - - Synopsis [Reads the reordCycle parameter of the manager.] - - Description [Reads the reordCycle parameter of the manager. This - parameter determines how often the alternate threshold on maximum - growth is used in reordering.] - - SideEffects [None] - - SeeAlso [Cudd_ReadMaxGrowthAlternate Cudd_SetMaxGrowthAlternate - Cudd_SetReorderingCycle] - -******************************************************************************/ -int -Cudd_ReadReorderingCycle( - DdManager * dd) -{ - return(dd->reordCycle); - -} /* end of Cudd_ReadReorderingCycle */ - - -/**Function******************************************************************** - - Synopsis [Sets the reordCycle parameter of the manager.] - - Description [Sets the reordCycle parameter of the manager. This - parameter determines how often the alternate threshold on maximum - growth is used in reordering.] - - SideEffects [None] - - SeeAlso [Cudd_ReadMaxGrowthAlternate Cudd_SetMaxGrowthAlternate - Cudd_ReadReorderingCycle] - -******************************************************************************/ -void -Cudd_SetReorderingCycle( - DdManager * dd, - int cycle) -{ - dd->reordCycle = cycle; - -} /* end of Cudd_SetReorderingCycle */ - - -/**Function******************************************************************** - - Synopsis [Returns the variable group tree of the manager.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_SetTree Cudd_FreeTree Cudd_ReadZddTree] - -******************************************************************************/ -MtrNode * -Cudd_ReadTree( - DdManager * dd) -{ - return(dd->tree); - -} /* end of Cudd_ReadTree */ - - -/**Function******************************************************************** - - Synopsis [Sets the variable group tree of the manager.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_FreeTree Cudd_ReadTree Cudd_SetZddTree] - -******************************************************************************/ -void -Cudd_SetTree( - DdManager * dd, - MtrNode * tree) -{ - if (dd->tree != NULL) { - Mtr_FreeTree(dd->tree); - } - dd->tree = tree; - if (tree == NULL) return; - - fixVarTree(tree, dd->perm, dd->size); - return; - -} /* end of Cudd_SetTree */ - - -/**Function******************************************************************** - - Synopsis [Frees the variable group tree of the manager.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_SetTree Cudd_ReadTree Cudd_FreeZddTree] - -******************************************************************************/ -void -Cudd_FreeTree( - DdManager * dd) -{ - if (dd->tree != NULL) { - Mtr_FreeTree(dd->tree); - dd->tree = NULL; - } - return; - -} /* end of Cudd_FreeTree */ - - -/**Function******************************************************************** - - Synopsis [Returns the variable group tree of the manager.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_SetZddTree Cudd_FreeZddTree Cudd_ReadTree] - -******************************************************************************/ -MtrNode * -Cudd_ReadZddTree( - DdManager * dd) -{ - return(dd->treeZ); - -} /* end of Cudd_ReadZddTree */ - - -/**Function******************************************************************** - - Synopsis [Sets the ZDD variable group tree of the manager.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_FreeZddTree Cudd_ReadZddTree Cudd_SetTree] - -******************************************************************************/ -void -Cudd_SetZddTree( - DdManager * dd, - MtrNode * tree) -{ - if (dd->treeZ != NULL) { - Mtr_FreeTree(dd->treeZ); - } - dd->treeZ = tree; - if (tree == NULL) return; - - fixVarTree(tree, dd->permZ, dd->sizeZ); - return; - -} /* end of Cudd_SetZddTree */ - - -/**Function******************************************************************** - - Synopsis [Frees the variable group tree of the manager.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_SetZddTree Cudd_ReadZddTree Cudd_FreeTree] - -******************************************************************************/ -void -Cudd_FreeZddTree( - DdManager * dd) -{ - if (dd->treeZ != NULL) { - Mtr_FreeTree(dd->treeZ); - dd->treeZ = NULL; - } - return; - -} /* end of Cudd_FreeZddTree */ - - -/**Function******************************************************************** - - Synopsis [Returns the index of the node.] - - Description [Returns the index of the node. The node pointer can be - either regular or complemented.] - - SideEffects [None] - - SeeAlso [Cudd_ReadIndex] - -******************************************************************************/ -unsigned int -Cudd_NodeReadIndex( - DdNode * node) -{ - return((unsigned int) Cudd_Regular(node)->index); - -} /* end of Cudd_NodeReadIndex */ - - -/**Function******************************************************************** - - Synopsis [Returns the current position of the i-th variable in the - order.] - - Description [Returns the current position of the i-th variable in - the order. If the index is CUDD_CONST_INDEX, returns - CUDD_CONST_INDEX; otherwise, if the index is out of bounds returns - -1.] - - SideEffects [None] - - SeeAlso [Cudd_ReadInvPerm Cudd_ReadPermZdd] - -******************************************************************************/ -int -Cudd_ReadPerm( - DdManager * dd, - int i) -{ - if (i == CUDD_CONST_INDEX) return(CUDD_CONST_INDEX); - if (i < 0 || i >= dd->size) return(-1); - return(dd->perm[i]); - -} /* end of Cudd_ReadPerm */ - - -/**Function******************************************************************** - - Synopsis [Returns the current position of the i-th ZDD variable in the - order.] - - Description [Returns the current position of the i-th ZDD variable - in the order. If the index is CUDD_CONST_INDEX, returns - CUDD_CONST_INDEX; otherwise, if the index is out of bounds returns - -1.] - - SideEffects [None] - - SeeAlso [Cudd_ReadInvPermZdd Cudd_ReadPerm] - -******************************************************************************/ -int -Cudd_ReadPermZdd( - DdManager * dd, - int i) -{ - if (i == CUDD_CONST_INDEX) return(CUDD_CONST_INDEX); - if (i < 0 || i >= dd->sizeZ) return(-1); - return(dd->permZ[i]); - -} /* end of Cudd_ReadPermZdd */ - - -/**Function******************************************************************** - - Synopsis [Returns the index of the variable currently in the i-th - position of the order.] - - Description [Returns the index of the variable currently in the i-th - position of the order. If the index is CUDD_CONST_INDEX, returns - CUDD_CONST_INDEX; otherwise, if the index is out of bounds returns -1.] - - SideEffects [None] - - SeeAlso [Cudd_ReadPerm Cudd_ReadInvPermZdd] - -******************************************************************************/ -int -Cudd_ReadInvPerm( - DdManager * dd, - int i) -{ - if (i == CUDD_CONST_INDEX) return(CUDD_CONST_INDEX); - if (i < 0 || i >= dd->size) return(-1); - return(dd->invperm[i]); - -} /* end of Cudd_ReadInvPerm */ - - -/**Function******************************************************************** - - Synopsis [Returns the index of the ZDD variable currently in the i-th - position of the order.] - - Description [Returns the index of the ZDD variable currently in the - i-th position of the order. If the index is CUDD_CONST_INDEX, returns - CUDD_CONST_INDEX; otherwise, if the index is out of bounds returns -1.] - - SideEffects [None] - - SeeAlso [Cudd_ReadPerm Cudd_ReadInvPermZdd] - -******************************************************************************/ -int -Cudd_ReadInvPermZdd( - DdManager * dd, - int i) -{ - if (i == CUDD_CONST_INDEX) return(CUDD_CONST_INDEX); - if (i < 0 || i >= dd->sizeZ) return(-1); - return(dd->invpermZ[i]); - -} /* end of Cudd_ReadInvPermZdd */ - - -/**Function******************************************************************** - - Synopsis [Returns the i-th element of the vars array.] - - Description [Returns the i-th element of the vars array if it falls - within the array bounds; NULL otherwise. If i is the index of an - existing variable, this function produces the same result as - Cudd_bddIthVar. However, if the i-th var does not exist yet, - Cudd_bddIthVar will create it, whereas Cudd_ReadVars will not.] - - SideEffects [None] - - SeeAlso [Cudd_bddIthVar] - -******************************************************************************/ -DdNode * -Cudd_ReadVars( - DdManager * dd, - int i) -{ - if (i < 0 || i > dd->size) return(NULL); - return(dd->vars[i]); - -} /* end of Cudd_ReadVars */ - - -/**Function******************************************************************** - - Synopsis [Reads the epsilon parameter of the manager.] - - Description [Reads the epsilon parameter of the manager. The epsilon - parameter control the comparison between floating point numbers.] - - SideEffects [None] - - SeeAlso [Cudd_SetEpsilon] - -******************************************************************************/ -CUDD_VALUE_TYPE -Cudd_ReadEpsilon( - DdManager * dd) -{ - return(dd->epsilon); - -} /* end of Cudd_ReadEpsilon */ - - -/**Function******************************************************************** - - Synopsis [Sets the epsilon parameter of the manager to ep.] - - Description [Sets the epsilon parameter of the manager to ep. The epsilon - parameter control the comparison between floating point numbers.] - - SideEffects [None] - - SeeAlso [Cudd_ReadEpsilon] - -******************************************************************************/ -void -Cudd_SetEpsilon( - DdManager * dd, - CUDD_VALUE_TYPE ep) -{ - dd->epsilon = ep; - -} /* end of Cudd_SetEpsilon */ - - -/**Function******************************************************************** - - Synopsis [Reads the groupcheck parameter of the manager.] - - Description [Reads the groupcheck parameter of the manager. The - groupcheck parameter determines the aggregation criterion in group - sifting.] - - SideEffects [None] - - SeeAlso [Cudd_SetGroupcheck] - -******************************************************************************/ -Cudd_AggregationType -Cudd_ReadGroupcheck( - DdManager * dd) -{ - return(dd->groupcheck); - -} /* end of Cudd_ReadGroupCheck */ - - -/**Function******************************************************************** - - Synopsis [Sets the parameter groupcheck of the manager to gc.] - - Description [Sets the parameter groupcheck of the manager to gc. The - groupcheck parameter determines the aggregation criterion in group - sifting.] - - SideEffects [None] - - SeeAlso [Cudd_ReadGroupCheck] - -******************************************************************************/ -void -Cudd_SetGroupcheck( - DdManager * dd, - Cudd_AggregationType gc) -{ - dd->groupcheck = gc; - -} /* end of Cudd_SetGroupcheck */ - - -/**Function******************************************************************** - - Synopsis [Tells whether garbage collection is enabled.] - - Description [Returns 1 if garbage collection is enabled; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_EnableGarbageCollection Cudd_DisableGarbageCollection] - -******************************************************************************/ -int -Cudd_GarbageCollectionEnabled( - DdManager * dd) -{ - return(dd->gcEnabled); - -} /* end of Cudd_GarbageCollectionEnabled */ - - -/**Function******************************************************************** - - Synopsis [Enables garbage collection.] - - Description [Enables garbage collection. Garbage collection is - initially enabled. Therefore it is necessary to call this function - only if garbage collection has been explicitly disabled.] - - SideEffects [None] - - SeeAlso [Cudd_DisableGarbageCollection Cudd_GarbageCollectionEnabled] - -******************************************************************************/ -void -Cudd_EnableGarbageCollection( - DdManager * dd) -{ - dd->gcEnabled = 1; - -} /* end of Cudd_EnableGarbageCollection */ - - -/**Function******************************************************************** - - Synopsis [Disables garbage collection.] - - Description [Disables garbage collection. Garbage collection is - initially enabled. This function may be called to disable it. - However, garbage collection will still occur when a new node must be - created and no memory is left, or when garbage collection is required - for correctness. (E.g., before reordering.)] - - SideEffects [None] - - SeeAlso [Cudd_EnableGarbageCollection Cudd_GarbageCollectionEnabled] - -******************************************************************************/ -void -Cudd_DisableGarbageCollection( - DdManager * dd) -{ - dd->gcEnabled = 0; - -} /* end of Cudd_DisableGarbageCollection */ - - -/**Function******************************************************************** - - Synopsis [Tells whether dead nodes are counted towards triggering - reordering.] - - Description [Tells whether dead nodes are counted towards triggering - reordering. Returns 1 if dead nodes are counted; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_TurnOnCountDead Cudd_TurnOffCountDead] - -******************************************************************************/ -int -Cudd_DeadAreCounted( - DdManager * dd) -{ - return(dd->countDead == 0 ? 1 : 0); - -} /* end of Cudd_DeadAreCounted */ - - -/**Function******************************************************************** - - Synopsis [Causes the dead nodes to be counted towards triggering - reordering.] - - Description [Causes the dead nodes to be counted towards triggering - reordering. This causes more frequent reorderings. By default dead - nodes are not counted.] - - SideEffects [Changes the manager.] - - SeeAlso [Cudd_TurnOffCountDead Cudd_DeadAreCounted] - -******************************************************************************/ -void -Cudd_TurnOnCountDead( - DdManager * dd) -{ - dd->countDead = 0; - -} /* end of Cudd_TurnOnCountDead */ - - -/**Function******************************************************************** - - Synopsis [Causes the dead nodes not to be counted towards triggering - reordering.] - - Description [Causes the dead nodes not to be counted towards - triggering reordering. This causes less frequent reorderings. By - default dead nodes are not counted. Therefore there is no need to - call this function unless Cudd_TurnOnCountDead has been previously - called.] - - SideEffects [Changes the manager.] - - SeeAlso [Cudd_TurnOnCountDead Cudd_DeadAreCounted] - -******************************************************************************/ -void -Cudd_TurnOffCountDead( - DdManager * dd) -{ - dd->countDead = ~0; - -} /* end of Cudd_TurnOffCountDead */ - - -/**Function******************************************************************** - - Synopsis [Returns the current value of the recombination parameter used - in group sifting.] - - Description [Returns the current value of the recombination - parameter used in group sifting. A larger (positive) value makes the - aggregation of variables due to the second difference criterion more - likely. A smaller (negative) value makes aggregation less likely.] - - SideEffects [None] - - SeeAlso [Cudd_SetRecomb] - -******************************************************************************/ -int -Cudd_ReadRecomb( - DdManager * dd) -{ - return(dd->recomb); - -} /* end of Cudd_ReadRecomb */ - - -/**Function******************************************************************** - - Synopsis [Sets the value of the recombination parameter used in group - sifting.] - - Description [Sets the value of the recombination parameter used in - group sifting. A larger (positive) value makes the aggregation of - variables due to the second difference criterion more likely. A - smaller (negative) value makes aggregation less likely. The default - value is 0.] - - SideEffects [Changes the manager.] - - SeeAlso [Cudd_ReadRecomb] - -******************************************************************************/ -void -Cudd_SetRecomb( - DdManager * dd, - int recomb) -{ - dd->recomb = recomb; - -} /* end of Cudd_SetRecomb */ - - -/**Function******************************************************************** - - Synopsis [Returns the current value of the symmviolation parameter used - in group sifting.] - - Description [Returns the current value of the symmviolation - parameter. This parameter is used in group sifting to decide how - many violations to the symmetry conditions <code>f10 = f01</code> or - <code>f11 = f00</code> are tolerable when checking for aggregation - due to extended symmetry. The value should be between 0 and 100. A - small value causes fewer variables to be aggregated. The default - value is 0.] - - SideEffects [None] - - SeeAlso [Cudd_SetSymmviolation] - -******************************************************************************/ -int -Cudd_ReadSymmviolation( - DdManager * dd) -{ - return(dd->symmviolation); - -} /* end of Cudd_ReadSymmviolation */ - - -/**Function******************************************************************** - - Synopsis [Sets the value of the symmviolation parameter used - in group sifting.] - - Description [Sets the value of the symmviolation - parameter. This parameter is used in group sifting to decide how - many violations to the symmetry conditions <code>f10 = f01</code> or - <code>f11 = f00</code> are tolerable when checking for aggregation - due to extended symmetry. The value should be between 0 and 100. A - small value causes fewer variables to be aggregated. The default - value is 0.] - - SideEffects [Changes the manager.] - - SeeAlso [Cudd_ReadSymmviolation] - -******************************************************************************/ -void -Cudd_SetSymmviolation( - DdManager * dd, - int symmviolation) -{ - dd->symmviolation = symmviolation; - -} /* end of Cudd_SetSymmviolation */ - - -/**Function******************************************************************** - - Synopsis [Returns the current value of the arcviolation parameter used - in group sifting.] - - Description [Returns the current value of the arcviolation - parameter. This parameter is used in group sifting to decide how - many arcs into <code>y</code> not coming from <code>x</code> are - tolerable when checking for aggregation due to extended - symmetry. The value should be between 0 and 100. A small value - causes fewer variables to be aggregated. The default value is 0.] - - SideEffects [None] - - SeeAlso [Cudd_SetArcviolation] - -******************************************************************************/ -int -Cudd_ReadArcviolation( - DdManager * dd) -{ - return(dd->arcviolation); - -} /* end of Cudd_ReadArcviolation */ - - -/**Function******************************************************************** - - Synopsis [Sets the value of the arcviolation parameter used - in group sifting.] - - Description [Sets the value of the arcviolation - parameter. This parameter is used in group sifting to decide how - many arcs into <code>y</code> not coming from <code>x</code> are - tolerable when checking for aggregation due to extended - symmetry. The value should be between 0 and 100. A small value - causes fewer variables to be aggregated. The default value is 0.] - - SideEffects [None] - - SeeAlso [Cudd_ReadArcviolation] - -******************************************************************************/ -void -Cudd_SetArcviolation( - DdManager * dd, - int arcviolation) -{ - dd->arcviolation = arcviolation; - -} /* end of Cudd_SetArcviolation */ - - -/**Function******************************************************************** - - Synopsis [Reads the current size of the population used by the - genetic algorithm for reordering.] - - Description [Reads the current size of the population used by the - genetic algorithm for variable reordering. A larger population size will - cause the genetic algorithm to take more time, but will generally - produce better results. The default value is 0, in which case the - package uses three times the number of variables as population size, - with a maximum of 120.] - - SideEffects [None] - - SeeAlso [Cudd_SetPopulationSize] - -******************************************************************************/ -int -Cudd_ReadPopulationSize( - DdManager * dd) -{ - return(dd->populationSize); - -} /* end of Cudd_ReadPopulationSize */ - - -/**Function******************************************************************** - - Synopsis [Sets the size of the population used by the - genetic algorithm for reordering.] - - Description [Sets the size of the population used by the - genetic algorithm for variable reordering. A larger population size will - cause the genetic algorithm to take more time, but will generally - produce better results. The default value is 0, in which case the - package uses three times the number of variables as population size, - with a maximum of 120.] - - SideEffects [Changes the manager.] - - SeeAlso [Cudd_ReadPopulationSize] - -******************************************************************************/ -void -Cudd_SetPopulationSize( - DdManager * dd, - int populationSize) -{ - dd->populationSize = populationSize; - -} /* end of Cudd_SetPopulationSize */ - - -/**Function******************************************************************** - - Synopsis [Reads the current number of crossovers used by the - genetic algorithm for reordering.] - - Description [Reads the current number of crossovers used by the - genetic algorithm for variable reordering. A larger number of crossovers will - cause the genetic algorithm to take more time, but will generally - produce better results. The default value is 0, in which case the - package uses three times the number of variables as number of crossovers, - with a maximum of 60.] - - SideEffects [None] - - SeeAlso [Cudd_SetNumberXovers] - -******************************************************************************/ -int -Cudd_ReadNumberXovers( - DdManager * dd) -{ - return(dd->numberXovers); - -} /* end of Cudd_ReadNumberXovers */ - - -/**Function******************************************************************** - - Synopsis [Sets the number of crossovers used by the - genetic algorithm for reordering.] - - Description [Sets the number of crossovers used by the genetic - algorithm for variable reordering. A larger number of crossovers - will cause the genetic algorithm to take more time, but will - generally produce better results. The default value is 0, in which - case the package uses three times the number of variables as number - of crossovers, with a maximum of 60.] - - SideEffects [None] - - SeeAlso [Cudd_ReadNumberXovers] - -******************************************************************************/ -void -Cudd_SetNumberXovers( - DdManager * dd, - int numberXovers) -{ - dd->numberXovers = numberXovers; - -} /* end of Cudd_SetNumberXovers */ - - -/**Function******************************************************************** - - Synopsis [Returns the order randomization factor.] - - Description [Returns the order randomization factor. If non-zero this - factor is used to determine a perturbation of the next reordering threshold. - Larger factors cause larger perturbations.] - - SideEffects [None] - - SeeAlso [Cudd_SetOrderRandomization] - -******************************************************************************/ -unsigned int -Cudd_ReadOrderRandomization( - DdManager * dd) -{ - return(dd->randomizeOrder); - -} /* end of Cudd_ReadOrderRandomization */ - - -/**Function******************************************************************** - - Synopsis [Sets the order randomization factor.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_ReadOrderRandomization] - -******************************************************************************/ -void -Cudd_SetOrderRandomization( - DdManager * dd, - unsigned int factor) -{ - dd->randomizeOrder = factor; - -} /* end of Cudd_SetOrderRandomization */ - - -/**Function******************************************************************** - - Synopsis [Returns the memory in use by the manager measured in bytes.] - - Description [] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -unsigned long -Cudd_ReadMemoryInUse( - DdManager * dd) -{ - return(dd->memused); - -} /* end of Cudd_ReadMemoryInUse */ - - -/**Function******************************************************************** - - Synopsis [Prints out statistics and settings for a CUDD manager.] - - Description [Prints out statistics and settings for a CUDD manager. - Returns 1 if successful; 0 otherwise.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -int -Cudd_PrintInfo( - DdManager * dd, - FILE * fp) -{ - int retval; - Cudd_ReorderingType autoMethod, autoMethodZ; - - /* Modifiable parameters. */ - retval = fprintf(fp,"**** CUDD modifiable parameters ****\n"); - if (retval == EOF) return(0); - retval = fprintf(fp,"Hard limit for cache size: %u\n", - Cudd_ReadMaxCacheHard(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Cache hit threshold for resizing: %u%%\n", - Cudd_ReadMinHit(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Garbage collection enabled: %s\n", - Cudd_GarbageCollectionEnabled(dd) ? "yes" : "no"); - if (retval == EOF) return(0); - retval = fprintf(fp,"Limit for fast unique table growth: %u\n", - Cudd_ReadLooseUpTo(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp, - "Maximum number of variables sifted per reordering: %d\n", - Cudd_ReadSiftMaxVar(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp, - "Maximum number of variable swaps per reordering: %d\n", - Cudd_ReadSiftMaxSwap(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Maximum growth while sifting a variable: %g\n", - Cudd_ReadMaxGrowth(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Dynamic reordering of BDDs enabled: %s\n", - Cudd_ReorderingStatus(dd,&autoMethod) ? "yes" : "no"); - if (retval == EOF) return(0); - retval = fprintf(fp,"Default BDD reordering method: %d\n", - (int) autoMethod); - if (retval == EOF) return(0); - retval = fprintf(fp,"Dynamic reordering of ZDDs enabled: %s\n", - Cudd_ReorderingStatusZdd(dd,&autoMethodZ) ? "yes" : "no"); - if (retval == EOF) return(0); - retval = fprintf(fp,"Default ZDD reordering method: %d\n", - (int) autoMethodZ); - if (retval == EOF) return(0); - retval = fprintf(fp,"Realignment of ZDDs to BDDs enabled: %s\n", - Cudd_zddRealignmentEnabled(dd) ? "yes" : "no"); - if (retval == EOF) return(0); - retval = fprintf(fp,"Realignment of BDDs to ZDDs enabled: %s\n", - Cudd_bddRealignmentEnabled(dd) ? "yes" : "no"); - if (retval == EOF) return(0); - retval = fprintf(fp,"Dead nodes counted in triggering reordering: %s\n", - Cudd_DeadAreCounted(dd) ? "yes" : "no"); - if (retval == EOF) return(0); - retval = fprintf(fp,"Group checking criterion: %d\n", - (int) Cudd_ReadGroupcheck(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Recombination threshold: %d\n", Cudd_ReadRecomb(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Symmetry violation threshold: %d\n", - Cudd_ReadSymmviolation(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Arc violation threshold: %d\n", - Cudd_ReadArcviolation(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"GA population size: %d\n", - Cudd_ReadPopulationSize(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of crossovers for GA: %d\n", - Cudd_ReadNumberXovers(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Next reordering threshold: %u\n", - Cudd_ReadNextReordering(dd)); - if (retval == EOF) return(0); - - /* Non-modifiable parameters. */ - retval = fprintf(fp,"**** CUDD non-modifiable parameters ****\n"); - if (retval == EOF) return(0); - retval = fprintf(fp,"Memory in use: %lu\n", Cudd_ReadMemoryInUse(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Peak number of nodes: %ld\n", - Cudd_ReadPeakNodeCount(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Peak number of live nodes: %d\n", - Cudd_ReadPeakLiveNodeCount(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of BDD variables: %d\n", dd->size); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of ZDD variables: %d\n", dd->sizeZ); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of cache entries: %u\n", dd->cacheSlots); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of cache look-ups: %.0f\n", - Cudd_ReadCacheLookUps(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of cache hits: %.0f\n", - Cudd_ReadCacheHits(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of cache insertions: %.0f\n", - dd->cacheinserts); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of cache collisions: %.0f\n", - dd->cachecollisions); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of cache deletions: %.0f\n", - dd->cachedeletions); - if (retval == EOF) return(0); - retval = cuddCacheProfile(dd,fp); - if (retval == 0) return(0); - retval = fprintf(fp,"Soft limit for cache size: %u\n", - Cudd_ReadMaxCache(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of buckets in unique table: %u\n", dd->slots); - if (retval == EOF) return(0); - retval = fprintf(fp,"Used buckets in unique table: %.2f%% (expected %.2f%%)\n", - 100.0 * Cudd_ReadUsedSlots(dd), - 100.0 * Cudd_ExpectedUsedSlots(dd)); - if (retval == EOF) return(0); -#ifdef DD_UNIQUE_PROFILE - retval = fprintf(fp,"Unique lookups: %.0f\n", dd->uniqueLookUps); - if (retval == EOF) return(0); - retval = fprintf(fp,"Unique links: %.0f (%g per lookup)\n", - dd->uniqueLinks, dd->uniqueLinks / dd->uniqueLookUps); - if (retval == EOF) return(0); -#endif - retval = fprintf(fp,"Number of BDD and ADD nodes: %u\n", dd->keys); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of ZDD nodes: %u\n", dd->keysZ); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of dead BDD and ADD nodes: %u\n", dd->dead); - if (retval == EOF) return(0); - retval = fprintf(fp,"Number of dead ZDD nodes: %u\n", dd->deadZ); - if (retval == EOF) return(0); - retval = fprintf(fp,"Total number of nodes allocated: %.0f\n", - dd->allocated); - if (retval == EOF) return(0); - retval = fprintf(fp,"Total number of nodes reclaimed: %.0f\n", - dd->reclaimed); - if (retval == EOF) return(0); -#ifdef DD_STATS - retval = fprintf(fp,"Nodes freed: %.0f\n", dd->nodesFreed); - if (retval == EOF) return(0); - retval = fprintf(fp,"Nodes dropped: %.0f\n", dd->nodesDropped); - if (retval == EOF) return(0); -#endif -#ifdef DD_COUNT - retval = fprintf(fp,"Number of recursive calls: %.0f\n", - Cudd_ReadRecursiveCalls(dd)); - if (retval == EOF) return(0); -#endif - retval = fprintf(fp,"Garbage collections so far: %d\n", - Cudd_ReadGarbageCollections(dd)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Time for garbage collection: %.2f sec\n", - ((double)Cudd_ReadGarbageCollectionTime(dd)/1000.0)); - if (retval == EOF) return(0); - retval = fprintf(fp,"Reorderings so far: %d\n", dd->reorderings); - if (retval == EOF) return(0); - retval = fprintf(fp,"Time for reordering: %.2f sec\n", - ((double)Cudd_ReadReorderingTime(dd)/1000.0)); - if (retval == EOF) return(0); -#ifdef DD_COUNT - retval = fprintf(fp,"Node swaps in reordering: %.0f\n", - Cudd_ReadSwapSteps(dd)); - if (retval == EOF) return(0); -#endif - - return(1); - -} /* end of Cudd_PrintInfo */ - - -/**Function******************************************************************** - - Synopsis [Reports the peak number of nodes.] - - Description [Reports the peak number of nodes. This number includes - node on the free list. At the peak, the number of nodes on the free - list is guaranteed to be less than DD_MEM_CHUNK.] - - SideEffects [None] - - SeeAlso [Cudd_ReadNodeCount Cudd_PrintInfo] - -******************************************************************************/ -long -Cudd_ReadPeakNodeCount( - DdManager * dd) -{ - long count = 0; - DdNodePtr *scan = dd->memoryList; - - while (scan != NULL) { - count += DD_MEM_CHUNK; - scan = (DdNodePtr *) *scan; - } - return(count); - -} /* end of Cudd_ReadPeakNodeCount */ - - -/**Function******************************************************************** - - Synopsis [Reports the peak number of live nodes.] - - Description [Reports the peak number of live nodes.] - - SideEffects [None] - - SeeAlso [Cudd_ReadNodeCount Cudd_PrintInfo Cudd_ReadPeakNodeCount] - -******************************************************************************/ -int -Cudd_ReadPeakLiveNodeCount( - DdManager * dd) -{ - unsigned int live = dd->keys - dd->dead; - - if (live > dd->peakLiveNodes) { - dd->peakLiveNodes = live; - } - return((int)dd->peakLiveNodes); - -} /* end of Cudd_ReadPeakLiveNodeCount */ - - -/**Function******************************************************************** - - Synopsis [Reports the number of nodes in BDDs and ADDs.] - - Description [Reports the number of live nodes in BDDs and ADDs. This - number does not include the isolated projection functions and the - unused constants. These nodes that are not counted are not part of - the DDs manipulated by the application.] - - SideEffects [None] - - SeeAlso [Cudd_ReadPeakNodeCount Cudd_zddReadNodeCount] - -******************************************************************************/ -long -Cudd_ReadNodeCount( - DdManager * dd) -{ - long count; - int i; - -#ifndef DD_NO_DEATH_ROW - cuddClearDeathRow(dd); -#endif - - count = (long) (dd->keys - dd->dead); - - /* Count isolated projection functions. Their number is subtracted - ** from the node count because they are not part of the BDDs. - */ - for (i=0; i < dd->size; i++) { - if (dd->vars[i]->ref == 1) count--; - } - /* Subtract from the count the unused constants. */ - if (DD_ZERO(dd)->ref == 1) count--; - if (DD_PLUS_INFINITY(dd)->ref == 1) count--; - if (DD_MINUS_INFINITY(dd)->ref == 1) count--; - - return(count); - -} /* end of Cudd_ReadNodeCount */ - - - -/**Function******************************************************************** - - Synopsis [Reports the number of nodes in ZDDs.] - - Description [Reports the number of nodes in ZDDs. This - number always includes the two constants 1 and 0.] - - SideEffects [None] - - SeeAlso [Cudd_ReadPeakNodeCount Cudd_ReadNodeCount] - -******************************************************************************/ -long -Cudd_zddReadNodeCount( - DdManager * dd) -{ - return((long)(dd->keysZ - dd->deadZ + 2)); - -} /* end of Cudd_zddReadNodeCount */ - - -/**Function******************************************************************** - - Synopsis [Adds a function to a hook.] - - Description [Adds a function to a hook. A hook is a list of - application-provided functions called on certain occasions by the - package. Returns 1 if the function is successfully added; 2 if the - function was already in the list; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_RemoveHook] - -******************************************************************************/ -int -Cudd_AddHook( - DdManager * dd, - DD_HFP f, - Cudd_HookType where) -{ - DdHook **hook, *nextHook, *newHook; - - switch (where) { - case CUDD_PRE_GC_HOOK: - hook = &(dd->preGCHook); - break; - case CUDD_POST_GC_HOOK: - hook = &(dd->postGCHook); - break; - case CUDD_PRE_REORDERING_HOOK: - hook = &(dd->preReorderingHook); - break; - case CUDD_POST_REORDERING_HOOK: - hook = &(dd->postReorderingHook); - break; - default: - return(0); - } - /* Scan the list and find whether the function is already there. - ** If so, just return. */ - nextHook = *hook; - while (nextHook != NULL) { - if (nextHook->f == f) { - return(2); - } - hook = &(nextHook->next); - nextHook = nextHook->next; - } - /* The function was not in the list. Create a new item and append it - ** to the end of the list. */ - newHook = ALLOC(DdHook,1); - if (newHook == NULL) { - dd->errorCode = CUDD_MEMORY_OUT; - return(0); - } - newHook->next = NULL; - newHook->f = f; - *hook = newHook; - return(1); - -} /* end of Cudd_AddHook */ - - -/**Function******************************************************************** - - Synopsis [Removes a function from a hook.] - - Description [Removes a function from a hook. A hook is a list of - application-provided functions called on certain occasions by the - package. Returns 1 if successful; 0 the function was not in the list.] - - SideEffects [None] - - SeeAlso [Cudd_AddHook] - -******************************************************************************/ -int -Cudd_RemoveHook( - DdManager * dd, - DD_HFP f, - Cudd_HookType where) -{ - DdHook **hook, *nextHook; - - switch (where) { - case CUDD_PRE_GC_HOOK: - hook = &(dd->preGCHook); - break; - case CUDD_POST_GC_HOOK: - hook = &(dd->postGCHook); - break; - case CUDD_PRE_REORDERING_HOOK: - hook = &(dd->preReorderingHook); - break; - case CUDD_POST_REORDERING_HOOK: - hook = &(dd->postReorderingHook); - break; - default: - return(0); - } - nextHook = *hook; - while (nextHook != NULL) { - if (nextHook->f == f) { - *hook = nextHook->next; - FREE(nextHook); - return(1); - } - hook = &(nextHook->next); - nextHook = nextHook->next; - } - - return(0); - -} /* end of Cudd_RemoveHook */ - - -/**Function******************************************************************** - - Synopsis [Checks whether a function is in a hook.] - - Description [Checks whether a function is in a hook. A hook is a list of - application-provided functions called on certain occasions by the - package. Returns 1 if the function is found; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_AddHook Cudd_RemoveHook] - -******************************************************************************/ -int -Cudd_IsInHook( - DdManager * dd, - DD_HFP f, - Cudd_HookType where) -{ - DdHook *hook; - - switch (where) { - case CUDD_PRE_GC_HOOK: - hook = dd->preGCHook; - break; - case CUDD_POST_GC_HOOK: - hook = dd->postGCHook; - break; - case CUDD_PRE_REORDERING_HOOK: - hook = dd->preReorderingHook; - break; - case CUDD_POST_REORDERING_HOOK: - hook = dd->postReorderingHook; - break; - default: - return(0); - } - /* Scan the list and find whether the function is already there. */ - while (hook != NULL) { - if (hook->f == f) { - return(1); - } - hook = hook->next; - } - return(0); - -} /* end of Cudd_IsInHook */ - - -/**Function******************************************************************** - - Synopsis [Sample hook function to call before reordering.] - - Description [Sample hook function to call before reordering. - Prints on the manager's stdout reordering method and initial size. - Returns 1 if successful; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_StdPostReordHook] - -******************************************************************************/ -int -Cudd_StdPreReordHook( - DdManager *dd, - const char *str, - void *data) -{ - Cudd_ReorderingType method = (Cudd_ReorderingType) (ptruint) data; - int retval; - - retval = fprintf(dd->out,"%s reordering with ", str); - if (retval == EOF) return(0); - switch (method) { - case CUDD_REORDER_SIFT_CONVERGE: - case CUDD_REORDER_SYMM_SIFT_CONV: - case CUDD_REORDER_GROUP_SIFT_CONV: - case CUDD_REORDER_WINDOW2_CONV: - case CUDD_REORDER_WINDOW3_CONV: - case CUDD_REORDER_WINDOW4_CONV: - case CUDD_REORDER_LINEAR_CONVERGE: - retval = fprintf(dd->out,"converging "); - if (retval == EOF) return(0); - break; - default: - break; - } - switch (method) { - case CUDD_REORDER_RANDOM: - case CUDD_REORDER_RANDOM_PIVOT: - retval = fprintf(dd->out,"random"); - break; - case CUDD_REORDER_SIFT: - case CUDD_REORDER_SIFT_CONVERGE: - retval = fprintf(dd->out,"sifting"); - break; - case CUDD_REORDER_SYMM_SIFT: - case CUDD_REORDER_SYMM_SIFT_CONV: - retval = fprintf(dd->out,"symmetric sifting"); - break; - case CUDD_REORDER_LAZY_SIFT: - retval = fprintf(dd->out,"lazy sifting"); - break; - case CUDD_REORDER_GROUP_SIFT: - case CUDD_REORDER_GROUP_SIFT_CONV: - retval = fprintf(dd->out,"group sifting"); - break; - case CUDD_REORDER_WINDOW2: - case CUDD_REORDER_WINDOW3: - case CUDD_REORDER_WINDOW4: - case CUDD_REORDER_WINDOW2_CONV: - case CUDD_REORDER_WINDOW3_CONV: - case CUDD_REORDER_WINDOW4_CONV: - retval = fprintf(dd->out,"window"); - break; - case CUDD_REORDER_ANNEALING: - retval = fprintf(dd->out,"annealing"); - break; - case CUDD_REORDER_GENETIC: - retval = fprintf(dd->out,"genetic"); - break; - case CUDD_REORDER_LINEAR: - case CUDD_REORDER_LINEAR_CONVERGE: - retval = fprintf(dd->out,"linear sifting"); - break; - case CUDD_REORDER_EXACT: - retval = fprintf(dd->out,"exact"); - break; - default: - return(0); - } - if (retval == EOF) return(0); - - retval = fprintf(dd->out,": from %ld to ... ", strcmp(str, "BDD") == 0 ? - Cudd_ReadNodeCount(dd) : Cudd_zddReadNodeCount(dd)); - if (retval == EOF) return(0); - fflush(dd->out); - return(1); - -} /* end of Cudd_StdPreReordHook */ - - -/**Function******************************************************************** - - Synopsis [Sample hook function to call after reordering.] - - Description [Sample hook function to call after reordering. - Prints on the manager's stdout final size and reordering time. - Returns 1 if successful; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_StdPreReordHook] - -******************************************************************************/ -int -Cudd_StdPostReordHook( - DdManager *dd, - const char *str, - void *data) -{ - unsigned long initialTime = (long) data; - int retval; - unsigned long finalTime = util_cpu_time(); - double totalTimeSec = (double)(finalTime - initialTime) / 1000.0; - - retval = fprintf(dd->out,"%ld nodes in %g sec\n", strcmp(str, "BDD") == 0 ? - Cudd_ReadNodeCount(dd) : Cudd_zddReadNodeCount(dd), - totalTimeSec); - if (retval == EOF) return(0); - retval = fflush(dd->out); - if (retval == EOF) return(0); - return(1); - -} /* end of Cudd_StdPostReordHook */ - - -/**Function******************************************************************** - - Synopsis [Enables reporting of reordering stats.] - - Description [Enables reporting of reordering stats. - Returns 1 if successful; 0 otherwise.] - - SideEffects [Installs functions in the pre-reordering and post-reordering - hooks.] - - SeeAlso [Cudd_DisableReorderingReporting Cudd_ReorderingReporting] - -******************************************************************************/ -int -Cudd_EnableReorderingReporting( - DdManager *dd) -{ - if (!Cudd_AddHook(dd, Cudd_StdPreReordHook, CUDD_PRE_REORDERING_HOOK)) { - return(0); - } - if (!Cudd_AddHook(dd, Cudd_StdPostReordHook, CUDD_POST_REORDERING_HOOK)) { - return(0); - } - return(1); - -} /* end of Cudd_EnableReorderingReporting */ - - -/**Function******************************************************************** - - Synopsis [Disables reporting of reordering stats.] - - Description [Disables reporting of reordering stats. - Returns 1 if successful; 0 otherwise.] - - SideEffects [Removes functions from the pre-reordering and post-reordering - hooks.] - - SeeAlso [Cudd_EnableReorderingReporting Cudd_ReorderingReporting] - -******************************************************************************/ -int -Cudd_DisableReorderingReporting( - DdManager *dd) -{ - if (!Cudd_RemoveHook(dd, Cudd_StdPreReordHook, CUDD_PRE_REORDERING_HOOK)) { - return(0); - } - if (!Cudd_RemoveHook(dd, Cudd_StdPostReordHook, CUDD_POST_REORDERING_HOOK)) { - return(0); - } - return(1); - -} /* end of Cudd_DisableReorderingReporting */ - - -/**Function******************************************************************** - - Synopsis [Returns 1 if reporting of reordering stats is enabled.] - - Description [Returns 1 if reporting of reordering stats is enabled; - 0 otherwise.] - - SideEffects [none] - - SeeAlso [Cudd_EnableReorderingReporting Cudd_DisableReorderingReporting] - -******************************************************************************/ -int -Cudd_ReorderingReporting( - DdManager *dd) -{ - return(Cudd_IsInHook(dd, Cudd_StdPreReordHook, CUDD_PRE_REORDERING_HOOK)); - -} /* end of Cudd_ReorderingReporting */ - - -/**Function******************************************************************** - - Synopsis [Hook function to print the current variable order.] - - Description [Hook function to print the current variable order. It may be - called before or after reordering. Prints on the manager's stdout a - parenthesized list that describes the variable groups. - Returns 1 if successful; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_StdPreReordHook] - -******************************************************************************/ -int -Cudd_PrintGroupedOrder( - DdManager * dd, - const char *str, - void *data) -{ - int isBdd = strcmp(str, "ZDD"); - MtrNode *tree = isBdd ? dd->tree : dd->treeZ; - int *invperm = isBdd ? dd->invperm : dd->invpermZ; - int size = isBdd ? dd->size : dd->sizeZ; - if (tree == NULL) { - int i, retval; - for (i=0; i < size; i++) { - retval = fprintf(dd->out, "%c%d", i==0 ? '(' : ',', invperm[i]); - if (retval == EOF) return(0); - } - retval = fprintf(dd->out,")\n"); - return (retval != EOF); - } else { - return Mtr_PrintGroupedOrder(tree,invperm,dd->out); - } - -} /* end of Cudd_PrintGroupedOrder */ - - -/**Function******************************************************************** - - Synopsis [Enables monitoring of ordering.] - - Description [Enables monitoring of ordering. - Returns 1 if successful; 0 otherwise.] - - SideEffects [Installs functions in the pre-reordering and post-reordering - hooks.] - - SeeAlso [Cudd_EnableReorderingReporting] - -******************************************************************************/ -int -Cudd_EnableOrderingMonitoring( - DdManager *dd) -{ - if (!Cudd_AddHook(dd, Cudd_PrintGroupedOrder, CUDD_PRE_REORDERING_HOOK)) { - return(0); - } - if (!Cudd_AddHook(dd, Cudd_StdPreReordHook, CUDD_PRE_REORDERING_HOOK)) { - return(0); - } - if (!Cudd_AddHook(dd, Cudd_StdPostReordHook, CUDD_POST_REORDERING_HOOK)) { - return(0); - } - if (!Cudd_AddHook(dd, Cudd_PrintGroupedOrder, CUDD_POST_REORDERING_HOOK)) { - return(0); - } - return(1); - -} /* end of Cudd_EnableOrderingMonitoring */ - - -/**Function******************************************************************** - - Synopsis [Disables monitoring of ordering.] - - Description [Disables monitoring of ordering. - Returns 1 if successful; 0 otherwise.] - - SideEffects [Removes functions from the pre-reordering and post-reordering - hooks.] - - SeeAlso [Cudd_EnableOrderingMonitoring] - -******************************************************************************/ -int -Cudd_DisableOrderingMonitoring( - DdManager *dd) -{ - if (!Cudd_RemoveHook(dd, Cudd_StdPreReordHook, CUDD_PRE_REORDERING_HOOK)) { - return(0); - } - if (!Cudd_RemoveHook(dd, Cudd_PrintGroupedOrder, CUDD_PRE_REORDERING_HOOK)) { - return(0); - } - if (!Cudd_RemoveHook(dd, Cudd_PrintGroupedOrder, CUDD_POST_REORDERING_HOOK)) { - return(0); - } - if (!Cudd_RemoveHook(dd, Cudd_StdPostReordHook, CUDD_POST_REORDERING_HOOK)) { - return(0); - } - return(1); - -} /* end of Cudd_DisableOrderingMonitoring */ - - -/**Function******************************************************************** - - Synopsis [Returns 1 if monitoring of ordering is enabled.] - - Description [Returns 1 if monitoring of ordering is enabled; - 0 otherwise.] - - SideEffects [none] - - SeeAlso [Cudd_EnableOrderingMonitoring Cudd_DisableOrderingMonitoring] - -******************************************************************************/ -int -Cudd_OrderingMonitoring( - DdManager *dd) -{ - return(Cudd_IsInHook(dd, Cudd_PrintGroupedOrder, CUDD_PRE_REORDERING_HOOK)); - -} /* end of Cudd_OrderingMonitoring */ - - -/**Function******************************************************************** - - Synopsis [Returns the code of the last error.] - - Description [Returns the code of the last error. The error codes are - defined in cudd.h.] - - SideEffects [None] - - SeeAlso [Cudd_ClearErrorCode] - -******************************************************************************/ -Cudd_ErrorType -Cudd_ReadErrorCode( - DdManager *dd) -{ - return(dd->errorCode); - -} /* end of Cudd_ReadErrorCode */ - - -/**Function******************************************************************** - - Synopsis [Clear the error code of a manager.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_ReadErrorCode] - -******************************************************************************/ -void -Cudd_ClearErrorCode( - DdManager *dd) -{ - dd->errorCode = CUDD_NO_ERROR; - -} /* end of Cudd_ClearErrorCode */ - - -/**Function******************************************************************** - - Synopsis [Reads the stdout of a manager.] - - Description [Reads the stdout of a manager. This is the file pointer to - which messages normally going to stdout are written. It is initialized - to stdout. Cudd_SetStdout allows the application to redirect it.] - - SideEffects [None] - - SeeAlso [Cudd_SetStdout Cudd_ReadStderr] - -******************************************************************************/ -FILE * -Cudd_ReadStdout( - DdManager *dd) -{ - return(dd->out); - -} /* end of Cudd_ReadStdout */ - - -/**Function******************************************************************** - - Synopsis [Sets the stdout of a manager.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_ReadStdout Cudd_SetStderr] - -******************************************************************************/ -void -Cudd_SetStdout( - DdManager *dd, - FILE *fp) -{ - dd->out = fp; - -} /* end of Cudd_SetStdout */ - - -/**Function******************************************************************** - - Synopsis [Reads the stderr of a manager.] - - Description [Reads the stderr of a manager. This is the file pointer to - which messages normally going to stderr are written. It is initialized - to stderr. Cudd_SetStderr allows the application to redirect it.] - - SideEffects [None] - - SeeAlso [Cudd_SetStderr Cudd_ReadStdout] - -******************************************************************************/ -FILE * -Cudd_ReadStderr( - DdManager *dd) -{ - return(dd->err); - -} /* end of Cudd_ReadStderr */ - - -/**Function******************************************************************** - - Synopsis [Sets the stderr of a manager.] - - Description [] - - SideEffects [None] - - SeeAlso [Cudd_ReadStderr Cudd_SetStdout] - -******************************************************************************/ -void -Cudd_SetStderr( - DdManager *dd, - FILE *fp) -{ - dd->err = fp; - -} /* end of Cudd_SetStderr */ - - -/**Function******************************************************************** - - Synopsis [Returns the threshold for the next dynamic reordering.] - - Description [Returns the threshold for the next dynamic reordering. - The threshold is in terms of number of nodes and is in effect only - if reordering is enabled. The count does not include the dead nodes, - unless the countDead parameter of the manager has been changed from - its default setting.] - - SideEffects [None] - - SeeAlso [Cudd_SetNextReordering] - -******************************************************************************/ -unsigned int -Cudd_ReadNextReordering( - DdManager *dd) -{ - return(dd->nextDyn); - -} /* end of Cudd_ReadNextReordering */ - - -/**Function******************************************************************** - - Synopsis [Sets the threshold for the next dynamic reordering.] - - Description [Sets the threshold for the next dynamic reordering. - The threshold is in terms of number of nodes and is in effect only - if reordering is enabled. The count does not include the dead nodes, - unless the countDead parameter of the manager has been changed from - its default setting.] - - SideEffects [None] - - SeeAlso [Cudd_ReadNextReordering] - -******************************************************************************/ -void -Cudd_SetNextReordering( - DdManager *dd, - unsigned int next) -{ - dd->nextDyn = next; - -} /* end of Cudd_SetNextReordering */ - - -/**Function******************************************************************** - - Synopsis [Reads the number of elementary reordering steps.] - - Description [] - - SideEffects [none] - - SeeAlso [] - -******************************************************************************/ -double -Cudd_ReadSwapSteps( - DdManager *dd) -{ -#ifdef DD_COUNT - return(dd->swapSteps); -#else - return(-1); -#endif - -} /* end of Cudd_ReadSwapSteps */ - - -/**Function******************************************************************** - - Synopsis [Reads the maximum allowed number of live nodes.] - - Description [Reads the maximum allowed number of live nodes. When this - number is exceeded, the package returns NULL.] - - SideEffects [none] - - SeeAlso [Cudd_SetMaxLive] - -******************************************************************************/ -unsigned int -Cudd_ReadMaxLive( - DdManager *dd) -{ - return(dd->maxLive); - -} /* end of Cudd_ReadMaxLive */ - - -/**Function******************************************************************** - - Synopsis [Sets the maximum allowed number of live nodes.] - - Description [Sets the maximum allowed number of live nodes. When this - number is exceeded, the package returns NULL.] - - SideEffects [none] - - SeeAlso [Cudd_ReadMaxLive] - -******************************************************************************/ -void -Cudd_SetMaxLive( - DdManager *dd, - unsigned int maxLive) -{ - dd->maxLive = maxLive; - -} /* end of Cudd_SetMaxLive */ - - -/**Function******************************************************************** - - Synopsis [Reads the maximum allowed memory.] - - Description [Reads the maximum allowed memory. When this - number is exceeded, the package returns NULL.] - - SideEffects [none] - - SeeAlso [Cudd_SetMaxMemory] - -******************************************************************************/ -unsigned long -Cudd_ReadMaxMemory( - DdManager *dd) -{ - return(dd->maxmemhard); - -} /* end of Cudd_ReadMaxMemory */ - - -/**Function******************************************************************** - - Synopsis [Sets the maximum allowed memory.] - - Description [Sets the maximum allowed memory. When this - number is exceeded, the package returns NULL.] - - SideEffects [none] - - SeeAlso [Cudd_ReadMaxMemory] - -******************************************************************************/ -void -Cudd_SetMaxMemory( - DdManager *dd, - unsigned long maxMemory) -{ - dd->maxmemhard = maxMemory; - -} /* end of Cudd_SetMaxMemory */ - - -/**Function******************************************************************** - - Synopsis [Prevents sifting of a variable.] - - Description [This function sets a flag to prevent sifting of a - variable. Returns 1 if successful; 0 otherwise (i.e., invalid - variable index).] - - SideEffects [Changes the "bindVar" flag in DdSubtable.] - - SeeAlso [Cudd_bddUnbindVar] - -******************************************************************************/ -int -Cudd_bddBindVar( - DdManager *dd /* manager */, - int index /* variable index */) -{ - if (index >= dd->size || index < 0) return(0); - dd->subtables[dd->perm[index]].bindVar = 1; - return(1); - -} /* end of Cudd_bddBindVar */ - - -/**Function******************************************************************** - - Synopsis [Allows the sifting of a variable.] - - Description [This function resets the flag that prevents the sifting - of a variable. In successive variable reorderings, the variable will - NOT be skipped, that is, sifted. Initially all variables can be - sifted. It is necessary to call this function only to re-enable - sifting after a call to Cudd_bddBindVar. Returns 1 if successful; 0 - otherwise (i.e., invalid variable index).] - - SideEffects [Changes the "bindVar" flag in DdSubtable.] - - SeeAlso [Cudd_bddBindVar] - -******************************************************************************/ -int -Cudd_bddUnbindVar( - DdManager *dd /* manager */, - int index /* variable index */) -{ - if (index >= dd->size || index < 0) return(0); - dd->subtables[dd->perm[index]].bindVar = 0; - return(1); - -} /* end of Cudd_bddUnbindVar */ - - -/**Function******************************************************************** - - Synopsis [Tells whether a variable can be sifted.] - - Description [This function returns 1 if a variable is enabled for - sifting. Initially all variables can be sifted. This function returns - 0 only if there has been a previous call to Cudd_bddBindVar for that - variable not followed by a call to Cudd_bddUnbindVar. The function returns - 0 also in the case in which the index of the variable is out of bounds.] - - SideEffects [none] - - SeeAlso [Cudd_bddBindVar Cudd_bddUnbindVar] - -******************************************************************************/ -int -Cudd_bddVarIsBound( - DdManager *dd /* manager */, - int index /* variable index */) -{ - if (index >= dd->size || index < 0) return(0); - return(dd->subtables[dd->perm[index]].bindVar); - -} /* end of Cudd_bddVarIsBound */ - - -/**Function******************************************************************** - - Synopsis [Sets a variable type to primary input.] - - Description [Sets a variable type to primary input. The variable type is - used by lazy sifting. Returns 1 if successful; 0 otherwise.] - - SideEffects [modifies the manager] - - SeeAlso [Cudd_bddSetPsVar Cudd_bddSetNsVar Cudd_bddIsPiVar] - -******************************************************************************/ -int -Cudd_bddSetPiVar( - DdManager *dd /* manager */, - int index /* variable index */) -{ - if (index >= dd->size || index < 0) return (0); - dd->subtables[dd->perm[index]].varType = CUDD_VAR_PRIMARY_INPUT; - return(1); - -} /* end of Cudd_bddSetPiVar */ - - -/**Function******************************************************************** - - Synopsis [Sets a variable type to present state.] - - Description [Sets a variable type to present state. The variable type is - used by lazy sifting. Returns 1 if successful; 0 otherwise.] - - SideEffects [modifies the manager] - - SeeAlso [Cudd_bddSetPiVar Cudd_bddSetNsVar Cudd_bddIsPsVar] - -******************************************************************************/ -int -Cudd_bddSetPsVar( - DdManager *dd /* manager */, - int index /* variable index */) -{ - if (index >= dd->size || index < 0) return (0); - dd->subtables[dd->perm[index]].varType = CUDD_VAR_PRESENT_STATE; - return(1); - -} /* end of Cudd_bddSetPsVar */ - - -/**Function******************************************************************** - - Synopsis [Sets a variable type to next state.] - - Description [Sets a variable type to next state. The variable type is - used by lazy sifting. Returns 1 if successful; 0 otherwise.] - - SideEffects [modifies the manager] - - SeeAlso [Cudd_bddSetPiVar Cudd_bddSetPsVar Cudd_bddIsNsVar] - -******************************************************************************/ -int -Cudd_bddSetNsVar( - DdManager *dd /* manager */, - int index /* variable index */) -{ - if (index >= dd->size || index < 0) return (0); - dd->subtables[dd->perm[index]].varType = CUDD_VAR_NEXT_STATE; - return(1); - -} /* end of Cudd_bddSetNsVar */ - - -/**Function******************************************************************** - - Synopsis [Checks whether a variable is primary input.] - - Description [Checks whether a variable is primary input. Returns 1 if - the variable's type is primary input; 0 if the variable exists but is - not a primary input; -1 if the variable does not exist.] - - SideEffects [none] - - SeeAlso [Cudd_bddSetPiVar Cudd_bddIsPsVar Cudd_bddIsNsVar] - -******************************************************************************/ -int -Cudd_bddIsPiVar( - DdManager *dd /* manager */, - int index /* variable index */) -{ - if (index >= dd->size || index < 0) return -1; - return (dd->subtables[dd->perm[index]].varType == CUDD_VAR_PRIMARY_INPUT); - -} /* end of Cudd_bddIsPiVar */ - - -/**Function******************************************************************** - - Synopsis [Checks whether a variable is present state.] - - Description [Checks whether a variable is present state. Returns 1 if - the variable's type is present state; 0 if the variable exists but is - not a present state; -1 if the variable does not exist.] - - SideEffects [none] - - SeeAlso [Cudd_bddSetPsVar Cudd_bddIsPiVar Cudd_bddIsNsVar] - -******************************************************************************/ -int -Cudd_bddIsPsVar( - DdManager *dd, - int index) -{ - if (index >= dd->size || index < 0) return -1; - return (dd->subtables[dd->perm[index]].varType == CUDD_VAR_PRESENT_STATE); - -} /* end of Cudd_bddIsPsVar */ - - -/**Function******************************************************************** - - Synopsis [Checks whether a variable is next state.] - - Description [Checks whether a variable is next state. Returns 1 if - the variable's type is present state; 0 if the variable exists but is - not a present state; -1 if the variable does not exist.] - - SideEffects [none] - - SeeAlso [Cudd_bddSetNsVar Cudd_bddIsPiVar Cudd_bddIsPsVar] - -******************************************************************************/ -int -Cudd_bddIsNsVar( - DdManager *dd, - int index) -{ - if (index >= dd->size || index < 0) return -1; - return (dd->subtables[dd->perm[index]].varType == CUDD_VAR_NEXT_STATE); - -} /* end of Cudd_bddIsNsVar */ - - -/**Function******************************************************************** - - Synopsis [Sets a corresponding pair index for a given index.] - - Description [Sets a corresponding pair index for a given index. - These pair indices are present and next state variable. Returns 1 if - successful; 0 otherwise.] - - SideEffects [modifies the manager] - - SeeAlso [Cudd_bddReadPairIndex] - -******************************************************************************/ -int -Cudd_bddSetPairIndex( - DdManager *dd /* manager */, - int index /* variable index */, - int pairIndex /* corresponding variable index */) -{ - if (index >= dd->size || index < 0) return(0); - dd->subtables[dd->perm[index]].pairIndex = pairIndex; - return(1); - -} /* end of Cudd_bddSetPairIndex */ - - -/**Function******************************************************************** - - Synopsis [Reads a corresponding pair index for a given index.] - - Description [Reads a corresponding pair index for a given index. - These pair indices are present and next state variable. Returns the - corresponding variable index if the variable exists; -1 otherwise.] - - SideEffects [modifies the manager] - - SeeAlso [Cudd_bddSetPairIndex] - -******************************************************************************/ -int -Cudd_bddReadPairIndex( - DdManager *dd, - int index) -{ - if (index >= dd->size || index < 0) return -1; - return dd->subtables[dd->perm[index]].pairIndex; - -} /* end of Cudd_bddReadPairIndex */ - - -/**Function******************************************************************** - - Synopsis [Sets a variable to be grouped.] - - Description [Sets a variable to be grouped. This function is used for - lazy sifting. Returns 1 if successful; 0 otherwise.] - - SideEffects [modifies the manager] - - SeeAlso [Cudd_bddSetVarHardGroup Cudd_bddResetVarToBeGrouped] - -******************************************************************************/ -int -Cudd_bddSetVarToBeGrouped( - DdManager *dd, - int index) -{ - if (index >= dd->size || index < 0) return(0); - if (dd->subtables[dd->perm[index]].varToBeGrouped <= CUDD_LAZY_SOFT_GROUP) { - dd->subtables[dd->perm[index]].varToBeGrouped = CUDD_LAZY_SOFT_GROUP; - } - return(1); - -} /* end of Cudd_bddSetVarToBeGrouped */ - - -/**Function******************************************************************** - - Synopsis [Sets a variable to be a hard group.] - - Description [Sets a variable to be a hard group. This function is used - for lazy sifting. Returns 1 if successful; 0 otherwise.] - - SideEffects [modifies the manager] - - SeeAlso [Cudd_bddSetVarToBeGrouped Cudd_bddResetVarToBeGrouped - Cudd_bddIsVarHardGroup] - -******************************************************************************/ -int -Cudd_bddSetVarHardGroup( - DdManager *dd, - int index) -{ - if (index >= dd->size || index < 0) return(0); - dd->subtables[dd->perm[index]].varToBeGrouped = CUDD_LAZY_HARD_GROUP; - return(1); - -} /* end of Cudd_bddSetVarHardGrouped */ - - -/**Function******************************************************************** - - Synopsis [Resets a variable not to be grouped.] - - Description [Resets a variable not to be grouped. This function is - used for lazy sifting. Returns 1 if successful; 0 otherwise.] - - SideEffects [modifies the manager] - - SeeAlso [Cudd_bddSetVarToBeGrouped Cudd_bddSetVarHardGroup] - -******************************************************************************/ -int -Cudd_bddResetVarToBeGrouped( - DdManager *dd, - int index) -{ - if (index >= dd->size || index < 0) return(0); - if (dd->subtables[dd->perm[index]].varToBeGrouped <= - CUDD_LAZY_SOFT_GROUP) { - dd->subtables[dd->perm[index]].varToBeGrouped = CUDD_LAZY_NONE; - } - return(1); - -} /* end of Cudd_bddResetVarToBeGrouped */ - - -/**Function******************************************************************** - - Synopsis [Checks whether a variable is set to be grouped.] - - Description [Checks whether a variable is set to be grouped. This - function is used for lazy sifting.] - - SideEffects [none] - - SeeAlso [] - -******************************************************************************/ -int -Cudd_bddIsVarToBeGrouped( - DdManager *dd, - int index) -{ - if (index >= dd->size || index < 0) return(-1); - if (dd->subtables[dd->perm[index]].varToBeGrouped == CUDD_LAZY_UNGROUP) - return(0); - else - return(dd->subtables[dd->perm[index]].varToBeGrouped); - -} /* end of Cudd_bddIsVarToBeGrouped */ - - -/**Function******************************************************************** - - Synopsis [Sets a variable to be ungrouped.] - - Description [Sets a variable to be ungrouped. This function is used - for lazy sifting. Returns 1 if successful; 0 otherwise.] - - SideEffects [modifies the manager] - - SeeAlso [Cudd_bddIsVarToBeUngrouped] - -******************************************************************************/ -int -Cudd_bddSetVarToBeUngrouped( - DdManager *dd, - int index) -{ - if (index >= dd->size || index < 0) return(0); - dd->subtables[dd->perm[index]].varToBeGrouped = CUDD_LAZY_UNGROUP; - return(1); - -} /* end of Cudd_bddSetVarToBeGrouped */ - - -/**Function******************************************************************** - - Synopsis [Checks whether a variable is set to be ungrouped.] - - Description [Checks whether a variable is set to be ungrouped. This - function is used for lazy sifting. Returns 1 if the variable is marked - to be ungrouped; 0 if the variable exists, but it is not marked to be - ungrouped; -1 if the variable does not exist.] - - SideEffects [none] - - SeeAlso [Cudd_bddSetVarToBeUngrouped] - -******************************************************************************/ -int -Cudd_bddIsVarToBeUngrouped( - DdManager *dd, - int index) -{ - if (index >= dd->size || index < 0) return(-1); - return dd->subtables[dd->perm[index]].varToBeGrouped == CUDD_LAZY_UNGROUP; - -} /* end of Cudd_bddIsVarToBeGrouped */ - - -/**Function******************************************************************** - - Synopsis [Checks whether a variable is set to be in a hard group.] - - Description [Checks whether a variable is set to be in a hard group. This - function is used for lazy sifting. Returns 1 if the variable is marked - to be in a hard group; 0 if the variable exists, but it is not marked to be - in a hard group; -1 if the variable does not exist.] - - SideEffects [none] - - SeeAlso [Cudd_bddSetVarHardGroup] - -******************************************************************************/ -int -Cudd_bddIsVarHardGroup( - DdManager *dd, - int index) -{ - if (index >= dd->size || index < 0) return(-1); - if (dd->subtables[dd->perm[index]].varToBeGrouped == CUDD_LAZY_HARD_GROUP) - return(1); - return(0); - -} /* end of Cudd_bddIsVarToBeGrouped */ - - -/*---------------------------------------------------------------------------*/ -/* Definition of internal functions */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Definition of static functions */ -/*---------------------------------------------------------------------------*/ - - -/**Function******************************************************************** - - Synopsis [Fixes a variable group tree.] - - Description [] - - SideEffects [Changes the variable group tree.] - - SeeAlso [] - -******************************************************************************/ -static void -fixVarTree( - MtrNode * treenode, - int * perm, - int size) -{ - treenode->index = treenode->low; - treenode->low = ((int) treenode->index < size) ? - perm[treenode->index] : treenode->index; - if (treenode->child != NULL) - fixVarTree(treenode->child, perm, size); - if (treenode->younger != NULL) - fixVarTree(treenode->younger, perm, size); - return; - -} /* end of fixVarTree */ - - -/**Function******************************************************************** - - Synopsis [Adds multiplicity groups to a ZDD variable group tree.] - - Description [Adds multiplicity groups to a ZDD variable group tree. - Returns 1 if successful; 0 otherwise. This function creates the groups - for set of ZDD variables (whose cardinality is given by parameter - multiplicity) that are created for each BDD variable in - Cudd_zddVarsFromBddVars. The crux of the matter is to determine the index - each new group. (The index of the first variable in the group.) - We first build all the groups for the children of a node, and then deal - with the ZDD variables that are directly attached to the node. The problem - for these is that the tree itself does not provide information on their - position inside the group. While we deal with the children of the node, - therefore, we keep track of all the positions they occupy. The remaining - positions in the tree can be freely used. Also, we keep track of all the - variables placed in the children. All the remaining variables are directly - attached to the group. We can then place any pair of variables not yet - grouped in any pair of available positions in the node.] - - SideEffects [Changes the variable group tree.] - - SeeAlso [Cudd_zddVarsFromBddVars] - -******************************************************************************/ -static int -addMultiplicityGroups( - DdManager *dd /* manager */, - MtrNode *treenode /* current tree node */, - int multiplicity /* how many ZDD vars per BDD var */, - char *vmask /* variable pairs for which a group has been already built */, - char *lmask /* levels for which a group has already been built*/) -{ - int startV, stopV, startL; - int i, j; - MtrNode *auxnode = treenode; - - while (auxnode != NULL) { - if (auxnode->child != NULL) { - addMultiplicityGroups(dd,auxnode->child,multiplicity,vmask,lmask); - } - /* Build remaining groups. */ - startV = dd->permZ[auxnode->index] / multiplicity; - startL = auxnode->low / multiplicity; - stopV = startV + auxnode->size / multiplicity; - /* Walk down vmask starting at startV and build missing groups. */ - for (i = startV, j = startL; i < stopV; i++) { - if (vmask[i] == 0) { - MtrNode *node; - while (lmask[j] == 1) j++; - node = Mtr_MakeGroup(auxnode, j * multiplicity, multiplicity, - MTR_FIXED); - if (node == NULL) { - return(0); - } - node->index = dd->invpermZ[i * multiplicity]; - vmask[i] = 1; - lmask[j] = 1; - } - } - auxnode = auxnode->younger; - } - return(1); - -} /* end of addMultiplicityGroups */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddGenetic.c b/resources/3rdparty/cudd-2.5.0/src/cudd/cuddGenetic.c deleted file mode 100644 index 8b259fe70..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddGenetic.c +++ /dev/null @@ -1,960 +0,0 @@ -/**CFile*********************************************************************** - - FileName [cuddGenetic.c] - - PackageName [cudd] - - Synopsis [Genetic algorithm for variable reordering.] - - Description [Internal procedures included in this file: - <ul> - <li> cuddGa() - </ul> - Static procedures included in this module: - <ul> - <li> make_random() - <li> sift_up() - <li> build_dd() - <li> largest() - <li> rand_int() - <li> array_hash() - <li> array_compare() - <li> find_best() - <li> find_average_fitness() - <li> PMX() - <li> roulette() - </ul> - - The genetic algorithm implemented here is as follows. We start with - the current DD order. We sift this order and use this as the - reference DD. We only keep 1 DD around for the entire process and - simply rearrange the order of this DD, storing the various orders - and their corresponding DD sizes. We generate more random orders to - build an initial population. This initial population is 3 times the - number of variables, with a maximum of 120. Each random order is - built (from the reference DD) and its size stored. Each random - order is also sifted to keep the DD sizes fairly small. Then a - crossover is performed between two orders (picked randomly) and the - two resulting DDs are built and sifted. For each new order, if its - size is smaller than any DD in the population, it is inserted into - the population and the DD with the largest number of nodes is thrown - out. The crossover process happens up to 50 times, and at this point - the DD in the population with the smallest size is chosen as the - result. This DD must then be built from the reference DD.] - - SeeAlso [] - - Author [Curt Musfeldt, Alan Shuler, Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado - - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - - Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - - Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - - Neither the name of the University of Colorado nor the names of its - contributors may be used to endorse or promote products derived from - this software without specific prior written permission. - - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, - BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] - -******************************************************************************/ - -#include "util.h" -#include "cuddInt.h" - -/*---------------------------------------------------------------------------*/ -/* Constant declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Stucture declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Type declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Variable declarations */ -/*---------------------------------------------------------------------------*/ - -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddGenetic.c,v 1.30 2012/02/05 01:07:18 fabio Exp $"; -#endif - -static int popsize; /* the size of the population */ -static int numvars; /* the number of input variables in the ckt. */ -/* storedd stores the population orders and sizes. This table has two -** extra rows and one extras column. The two extra rows are used for the -** offspring produced by a crossover. Each row stores one order and its -** size. The order is stored by storing the indices of variables in the -** order in which they appear in the order. The table is in reality a -** one-dimensional array which is accessed via a macro to give the illusion -** it is a two-dimensional structure. -*/ -static int *storedd; -static st_table *computed; /* hash table to identify existing orders */ -static int *repeat; /* how many times an order is present */ -static int large; /* stores the index of the population with - ** the largest number of nodes in the DD */ -static int result; -static int cross; /* the number of crossovers to perform */ - -/*---------------------------------------------------------------------------*/ -/* Macro declarations */ -/*---------------------------------------------------------------------------*/ - -/* macro used to access the population table as if it were a -** two-dimensional structure. -*/ -#define STOREDD(i,j) storedd[(i)*(numvars+1)+(j)] - -#ifdef __cplusplus -extern "C" { -#endif - -/**AutomaticStart*************************************************************/ - -/*---------------------------------------------------------------------------*/ -/* Static function prototypes */ -/*---------------------------------------------------------------------------*/ - -static int make_random (DdManager *table, int lower); -static int sift_up (DdManager *table, int x, int x_low); -static int build_dd (DdManager *table, int num, int lower, int upper); -static int largest (void); -static int rand_int (int a); -static int array_hash (char *array, int modulus); -static int array_compare (const char *array1, const char *array2); -static int find_best (void); -#ifdef DD_STATS -static double find_average_fitness (void); -#endif -static int PMX (int maxvar); -static int roulette (int *p1, int *p2); - -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} -#endif - -/*---------------------------------------------------------------------------*/ -/* Definition of exported functions */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Definition of internal functions */ -/*---------------------------------------------------------------------------*/ - - -/**Function******************************************************************** - - Synopsis [Genetic algorithm for DD reordering.] - - Description [Genetic algorithm for DD reordering. - The two children of a crossover will be stored in - storedd[popsize] and storedd[popsize+1] --- the last two slots in the - storedd array. (This will make comparisons and replacement easy.) - Returns 1 in case of success; 0 otherwise.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -int -cuddGa( - DdManager * table /* manager */, - int lower /* lowest level to be reordered */, - int upper /* highest level to be reorderded */) -{ - int i,n,m; /* dummy/loop vars */ - int index; -#ifdef DD_STATS - double average_fitness; -#endif - int small; /* index of smallest DD in population */ - - /* Do an initial sifting to produce at least one reasonable individual. */ - if (!cuddSifting(table,lower,upper)) return(0); - - /* Get the initial values. */ - numvars = upper - lower + 1; /* number of variables to be reordered */ - if (table->populationSize == 0) { - popsize = 3 * numvars; /* population size is 3 times # of vars */ - if (popsize > 120) { - popsize = 120; /* Maximum population size is 120 */ - } - } else { - popsize = table->populationSize; /* user specified value */ - } - if (popsize < 4) popsize = 4; /* enforce minimum population size */ - - /* Allocate population table. */ - storedd = ALLOC(int,(popsize+2)*(numvars+1)); - if (storedd == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - return(0); - } - - /* Initialize the computed table. This table is made up of two data - ** structures: A hash table with the key given by the order, which says - ** if a given order is present in the population; and the repeat - ** vector, which says how many copies of a given order are stored in - ** the population table. If there are multiple copies of an order, only - ** one has a repeat count greater than 1. This copy is the one pointed - ** by the computed table. - */ - repeat = ALLOC(int,popsize); - if (repeat == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - FREE(storedd); - return(0); - } - for (i = 0; i < popsize; i++) { - repeat[i] = 0; - } - computed = st_init_table(array_compare,array_hash); - if (computed == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - FREE(storedd); - FREE(repeat); - return(0); - } - - /* Copy the current DD and its size to the population table. */ - for (i = 0; i < numvars; i++) { - STOREDD(0,i) = table->invperm[i+lower]; /* order of initial DD */ - } - STOREDD(0,numvars) = table->keys - table->isolated; /* size of initial DD */ - - /* Store the initial order in the computed table. */ - if (st_insert(computed,(char *)storedd,(char *) 0) == ST_OUT_OF_MEM) { - FREE(storedd); - FREE(repeat); - st_free_table(computed); - return(0); - } - repeat[0]++; - - /* Insert the reverse order as second element of the population. */ - for (i = 0; i < numvars; i++) { - STOREDD(1,numvars-1-i) = table->invperm[i+lower]; /* reverse order */ - } - - /* Now create the random orders. make_random fills the population - ** table with random permutations. The successive loop builds and sifts - ** the DDs for the reverse order and each random permutation, and stores - ** the results in the computed table. - */ - if (!make_random(table,lower)) { - table->errorCode = CUDD_MEMORY_OUT; - FREE(storedd); - FREE(repeat); - st_free_table(computed); - return(0); - } - for (i = 1; i < popsize; i++) { - result = build_dd(table,i,lower,upper); /* build and sift order */ - if (!result) { - FREE(storedd); - FREE(repeat); - st_free_table(computed); - return(0); - } - if (st_lookup_int(computed,(char *)&STOREDD(i,0),&index)) { - repeat[index]++; - } else { - if (st_insert(computed,(char *)&STOREDD(i,0),(char *)(long)i) == - ST_OUT_OF_MEM) { - FREE(storedd); - FREE(repeat); - st_free_table(computed); - return(0); - } - repeat[i]++; - } - } - -#if 0 -#ifdef DD_STATS - /* Print the initial population. */ - (void) fprintf(table->out,"Initial population after sifting\n"); - for (m = 0; m < popsize; m++) { - for (i = 0; i < numvars; i++) { - (void) fprintf(table->out," %2d",STOREDD(m,i)); - } - (void) fprintf(table->out," : %3d (%d)\n", - STOREDD(m,numvars),repeat[m]); - } -#endif -#endif - - small = find_best(); -#ifdef DD_STATS - average_fitness = find_average_fitness(); - (void) fprintf(table->out,"\nInitial population: best fitness = %d, average fitness %8.3f",STOREDD(small,numvars),average_fitness); -#endif - - /* Decide how many crossovers should be tried. */ - if (table->numberXovers == 0) { - cross = 3*numvars; - if (cross > 60) { /* do a maximum of 50 crossovers */ - cross = 60; - } - } else { - cross = table->numberXovers; /* use user specified value */ - } - if (cross >= popsize) { - cross = popsize; - } - - /* Perform the crossovers to get the best order. */ - for (m = 0; m < cross; m++) { - if (!PMX(table->size)) { /* perform one crossover */ - table->errorCode = CUDD_MEMORY_OUT; - FREE(storedd); - FREE(repeat); - st_free_table(computed); - return(0); - } - /* The offsprings are left in the last two entries of the - ** population table. These are now considered in turn. - */ - for (i = popsize; i <= popsize+1; i++) { - result = build_dd(table,i,lower,upper); /* build and sift child */ - if (!result) { - FREE(storedd); - FREE(repeat); - st_free_table(computed); - return(0); - } - large = largest(); /* find the largest DD in population */ - - /* If the new child is smaller than the largest DD in the current - ** population, enter it into the population in place of the - ** largest DD. - */ - if (STOREDD(i,numvars) < STOREDD(large,numvars)) { - /* Look up the largest DD in the computed table. - ** Decrease its repetition count. If the repetition count - ** goes to 0, remove the largest DD from the computed table. - */ - result = st_lookup_int(computed,(char *)&STOREDD(large,0), - &index); - if (!result) { - FREE(storedd); - FREE(repeat); - st_free_table(computed); - return(0); - } - repeat[index]--; - if (repeat[index] == 0) { - int *pointer = &STOREDD(index,0); - result = st_delete(computed, &pointer, NULL); - if (!result) { - FREE(storedd); - FREE(repeat); - st_free_table(computed); - return(0); - } - } - /* Copy the new individual to the entry of the - ** population table just made available and update the - ** computed table. - */ - for (n = 0; n <= numvars; n++) { - STOREDD(large,n) = STOREDD(i,n); - } - if (st_lookup_int(computed,(char *)&STOREDD(large,0), - &index)) { - repeat[index]++; - } else { - if (st_insert(computed,(char *)&STOREDD(large,0), - (char *)(long)large) == ST_OUT_OF_MEM) { - FREE(storedd); - FREE(repeat); - st_free_table(computed); - return(0); - } - repeat[large]++; - } - } - } - } - - /* Find the smallest DD in the population and build it; - ** that will be the result. - */ - small = find_best(); - - /* Print stats on the final population. */ -#ifdef DD_STATS - average_fitness = find_average_fitness(); - (void) fprintf(table->out,"\nFinal population: best fitness = %d, average fitness %8.3f",STOREDD(small,numvars),average_fitness); -#endif - - /* Clean up, build the result DD, and return. */ - st_free_table(computed); - computed = NULL; - result = build_dd(table,small,lower,upper); - FREE(storedd); - FREE(repeat); - return(result); - -} /* end of cuddGa */ - - -/*---------------------------------------------------------------------------*/ -/* Definition of static functions */ -/*---------------------------------------------------------------------------*/ - -/**Function******************************************************************** - - Synopsis [Generates the random sequences for the initial population.] - - Description [Generates the random sequences for the initial population. - The sequences are permutations of the indices between lower and - upper in the current order.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -static int -make_random( - DdManager * table, - int lower) -{ - int i,j; /* loop variables */ - int *used; /* is a number already in a permutation */ - int next; /* next random number without repetitions */ - - used = ALLOC(int,numvars); - if (used == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - return(0); - } -#if 0 -#ifdef DD_STATS - (void) fprintf(table->out,"Initial population before sifting\n"); - for (i = 0; i < 2; i++) { - for (j = 0; j < numvars; j++) { - (void) fprintf(table->out," %2d",STOREDD(i,j)); - } - (void) fprintf(table->out,"\n"); - } -#endif -#endif - for (i = 2; i < popsize; i++) { - for (j = 0; j < numvars; j++) { - used[j] = 0; - } - /* Generate a permutation of {0...numvars-1} and use it to - ** permute the variables in the layesr from lower to upper. - */ - for (j = 0; j < numvars; j++) { - do { - next = rand_int(numvars-1); - } while (used[next] != 0); - used[next] = 1; - STOREDD(i,j) = table->invperm[next+lower]; - } -#if 0 -#ifdef DD_STATS - /* Print the order just generated. */ - for (j = 0; j < numvars; j++) { - (void) fprintf(table->out," %2d",STOREDD(i,j)); - } - (void) fprintf(table->out,"\n"); -#endif -#endif - } - FREE(used); - return(1); - -} /* end of make_random */ - - -/**Function******************************************************************** - - Synopsis [Moves one variable up.] - - Description [Takes a variable from position x and sifts it up to - position x_low; x_low should be less than x. Returns 1 if successful; - 0 otherwise] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -static int -sift_up( - DdManager * table, - int x, - int x_low) -{ - int y; - int size; - - y = cuddNextLow(table,x); - while (y >= x_low) { - size = cuddSwapInPlace(table,y,x); - if (size == 0) { - return(0); - } - x = y; - y = cuddNextLow(table,x); - } - return(1); - -} /* end of sift_up */ - - -/**Function******************************************************************** - - Synopsis [Builds a DD from a given order.] - - Description [Builds a DD from a given order. This procedure also - sifts the final order and inserts into the array the size in nodes - of the result. Returns 1 if successful; 0 otherwise.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -static int -build_dd( - DdManager * table, - int num /* the index of the individual to be built */, - int lower, - int upper) -{ - int i,j; /* loop vars */ - int position; - int index; - int limit; /* how large the DD for this order can grow */ - int size; - - /* Check the computed table. If the order already exists, it - ** suffices to copy the size from the existing entry. - */ - if (computed && st_lookup_int(computed,(char *)&STOREDD(num,0),&index)) { - STOREDD(num,numvars) = STOREDD(index,numvars); -#ifdef DD_STATS - (void) fprintf(table->out,"\nCache hit for index %d", index); -#endif - return(1); - } - - /* Stop if the DD grows 20 times larges than the reference size. */ - limit = 20 * STOREDD(0,numvars); - - /* Sift up the variables so as to build the desired permutation. - ** First the variable that has to be on top is sifted to the top. - ** Then the variable that has to occupy the secon position is sifted - ** up to the second position, and so on. - */ - for (j = 0; j < numvars; j++) { - i = STOREDD(num,j); - position = table->perm[i]; - result = sift_up(table,position,j+lower); - if (!result) return(0); - size = table->keys - table->isolated; - if (size > limit) break; - } - - /* Sift the DD just built. */ -#ifdef DD_STATS - (void) fprintf(table->out,"\n"); -#endif - result = cuddSifting(table,lower,upper); - if (!result) return(0); - - /* Copy order and size to table. */ - for (j = 0; j < numvars; j++) { - STOREDD(num,j) = table->invperm[lower+j]; - } - STOREDD(num,numvars) = table->keys - table->isolated; /* size of new DD */ - return(1); - -} /* end of build_dd */ - - -/**Function******************************************************************** - - Synopsis [Finds the largest DD in the population.] - - Description [Finds the largest DD in the population. If an order is - repeated, it avoids choosing the copy that is in the computed table - (it has repeat[i] > 1).] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -static int -largest(void) -{ - int i; /* loop var */ - int big; /* temporary holder to return result */ - - big = 0; - while (repeat[big] > 1) big++; - for (i = big + 1; i < popsize; i++) { - if (STOREDD(i,numvars) >= STOREDD(big,numvars) && repeat[i] <= 1) { - big = i; - } - } - return(big); - -} /* end of largest */ - - -/**Function******************************************************************** - - Synopsis [Generates a random number between 0 and the integer a.] - - Description [] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -static int -rand_int( - int a) -{ - return(Cudd_Random() % (a+1)); - -} /* end of rand_int */ - - -/**Function******************************************************************** - - Synopsis [Hash function for the computed table.] - - Description [Hash function for the computed table. Returns the bucket - number.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -static int -array_hash( - char * array, - int modulus) -{ - int val = 0; - int i; - int *intarray; - - intarray = (int *) array; - - for (i = 0; i < numvars; i++) { - val = val * 997 + intarray[i]; - } - - return ((val < 0) ? -val : val) % modulus; - -} /* end of array_hash */ - - -/**Function******************************************************************** - - Synopsis [Comparison function for the computed table.] - - Description [Comparison function for the computed table. Returns 0 if - the two arrays are equal; 1 otherwise.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -static int -array_compare( - const char * array1, - const char * array2) -{ - int i; - int *intarray1, *intarray2; - - intarray1 = (int *) array1; - intarray2 = (int *) array2; - - for (i = 0; i < numvars; i++) { - if (intarray1[i] != intarray2[i]) return(1); - } - return(0); - -} /* end of array_compare */ - - -/**Function******************************************************************** - - Synopsis [Returns the index of the fittest individual.] - - Description [] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -static int -find_best(void) -{ - int i,small; - - small = 0; - for (i = 1; i < popsize; i++) { - if (STOREDD(i,numvars) < STOREDD(small,numvars)) { - small = i; - } - } - return(small); - -} /* end of find_best */ - - -/**Function******************************************************************** - - Synopsis [Returns the average fitness of the population.] - - Description [] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -#ifdef DD_STATS -static double -find_average_fitness(void) -{ - int i; - int total_fitness = 0; - double average_fitness; - - for (i = 0; i < popsize; i++) { - total_fitness += STOREDD(i,numvars); - } - average_fitness = (double) total_fitness / (double) popsize; - return(average_fitness); - -} /* end of find_average_fitness */ -#endif - - -/**Function******************************************************************** - - Synopsis [Performs the crossover between two parents.] - - Description [Performs the crossover between two randomly chosen - parents, and creates two children, x1 and x2. Uses the Partially - Matched Crossover operator.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -static int -PMX( - int maxvar) -{ - int cut1,cut2; /* the two cut positions (random) */ - int mom,dad; /* the two randomly chosen parents */ - int *inv1; /* inverse permutations for repair algo */ - int *inv2; - int i; /* loop vars */ - int u,v; /* aux vars */ - - inv1 = ALLOC(int,maxvar); - if (inv1 == NULL) { - return(0); - } - inv2 = ALLOC(int,maxvar); - if (inv2 == NULL) { - FREE(inv1); - return(0); - } - - /* Choose two orders from the population using roulette wheel. */ - if (!roulette(&mom,&dad)) { - FREE(inv1); - FREE(inv2); - return(0); - } - - /* Choose two random cut positions. A cut in position i means that - ** the cut immediately precedes position i. If cut1 < cut2, we - ** exchange the middle of the two orderings; otherwise, we - ** exchange the beginnings and the ends. - */ - cut1 = rand_int(numvars-1); - do { - cut2 = rand_int(numvars-1); - } while (cut1 == cut2); - -#if 0 - /* Print out the parents. */ - (void) fprintf(table->out, - "Crossover of %d (mom) and %d (dad) between %d and %d\n", - mom,dad,cut1,cut2); - for (i = 0; i < numvars; i++) { - if (i == cut1 || i == cut2) (void) fprintf(table->out,"|"); - (void) fprintf(table->out,"%2d ",STOREDD(mom,i)); - } - (void) fprintf(table->out,"\n"); - for (i = 0; i < numvars; i++) { - if (i == cut1 || i == cut2) (void) fprintf(table->out,"|"); - (void) fprintf(table->out,"%2d ",STOREDD(dad,i)); - } - (void) fprintf(table->out,"\n"); -#endif - - /* Initialize the inverse permutations: -1 means yet undetermined. */ - for (i = 0; i < maxvar; i++) { - inv1[i] = -1; - inv2[i] = -1; - } - - /* Copy the portions whithin the cuts. */ - for (i = cut1; i != cut2; i = (i == numvars-1) ? 0 : i+1) { - STOREDD(popsize,i) = STOREDD(dad,i); - inv1[STOREDD(popsize,i)] = i; - STOREDD(popsize+1,i) = STOREDD(mom,i); - inv2[STOREDD(popsize+1,i)] = i; - } - - /* Now apply the repair algorithm outside the cuts. */ - for (i = cut2; i != cut1; i = (i == numvars-1 ) ? 0 : i+1) { - v = i; - do { - u = STOREDD(mom,v); - v = inv1[u]; - } while (v != -1); - STOREDD(popsize,i) = u; - inv1[u] = i; - v = i; - do { - u = STOREDD(dad,v); - v = inv2[u]; - } while (v != -1); - STOREDD(popsize+1,i) = u; - inv2[u] = i; - } - -#if 0 - /* Print the results of crossover. */ - for (i = 0; i < numvars; i++) { - if (i == cut1 || i == cut2) (void) fprintf(table->out,"|"); - (void) fprintf(table->out,"%2d ",STOREDD(popsize,i)); - } - (void) fprintf(table->out,"\n"); - for (i = 0; i < numvars; i++) { - if (i == cut1 || i == cut2) (void) fprintf(table->out,"|"); - (void) fprintf(table->out,"%2d ",STOREDD(popsize+1,i)); - } - (void) fprintf(table->out,"\n"); -#endif - - FREE(inv1); - FREE(inv2); - return(1); - -} /* end of PMX */ - - -/**Function******************************************************************** - - Synopsis [Selects two parents with the roulette wheel method.] - - Description [Selects two distinct parents with the roulette wheel method.] - - SideEffects [The indices of the selected parents are returned as side - effects.] - - SeeAlso [] - -******************************************************************************/ -static int -roulette( - int * p1, - int * p2) -{ - double *wheel; - double spin; - int i; - - wheel = ALLOC(double,popsize); - if (wheel == NULL) { - return(0); - } - - /* The fitness of an individual is the reciprocal of its size. */ - wheel[0] = 1.0 / (double) STOREDD(0,numvars); - - for (i = 1; i < popsize; i++) { - wheel[i] = wheel[i-1] + 1.0 / (double) STOREDD(i,numvars); - } - - /* Get a random number between 0 and wheel[popsize-1] (that is, - ** the sum of all fitness values. 2147483561 is the largest number - ** returned by Cudd_Random. - */ - spin = wheel[numvars-1] * (double) Cudd_Random() / 2147483561.0; - - /* Find the lucky element by scanning the wheel. */ - for (i = 0; i < popsize; i++) { - if (spin <= wheel[i]) break; - } - *p1 = i; - - /* Repeat the process for the second parent, making sure it is - ** distinct from the first. - */ - do { - spin = wheel[popsize-1] * (double) Cudd_Random() / 2147483561.0; - for (i = 0; i < popsize; i++) { - if (spin <= wheel[i]) break; - } - } while (i == *p1); - *p2 = i; - - FREE(wheel); - return(1); - -} /* end of roulette */ - diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddInt.h b/resources/3rdparty/cudd-2.5.0/src/cudd/cuddInt.h deleted file mode 100644 index 313a56586..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddInt.h +++ /dev/null @@ -1,1190 +0,0 @@ -/**CHeaderFile***************************************************************** - - FileName [cuddInt.h] - - PackageName [cudd] - - Synopsis [Internal data structures of the CUDD package.] - - Description [] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado - - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - - Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - - Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - - Neither the name of the University of Colorado nor the names of its - contributors may be used to endorse or promote products derived from - this software without specific prior written permission. - - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, - BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] - - Revision [$Id: cuddInt.h,v 1.142 2012/02/05 01:07:19 fabio Exp $] - -******************************************************************************/ - -#ifndef _CUDDINT -#define _CUDDINT - - -/*---------------------------------------------------------------------------*/ -/* Nested includes */ -/*---------------------------------------------------------------------------*/ - -#ifdef DD_MIS -#include "array.h" -#include "list.h" -#include "st.h" -#include "espresso.h" -#include "node.h" -#ifdef SIS -#include "graph.h" -#include "astg.h" -#endif -#include "network.h" -#endif - -#include <math.h> -#include "cudd.h" -#include "st.h" - -#ifdef __cplusplus -extern "C" { -#endif - -#if defined(__GNUC__) -# define DD_INLINE __inline__ -# if (__GNUC__ >2 || __GNUC_MINOR__ >=7) -# define DD_UNUSED __attribute__ ((__unused__)) -# else -# define DD_UNUSED -# endif -#else -# if defined(__cplusplus) -# define DD_INLINE inline -# else -# define DD_INLINE -# endif -# define DD_UNUSED -#endif - - -/*---------------------------------------------------------------------------*/ -/* Constant declarations */ -/*---------------------------------------------------------------------------*/ - -#define DD_MAXREF ((DdHalfWord) ~0) - -#define DD_DEFAULT_RESIZE 10 /* how many extra variables */ - /* should be added when resizing */ -#define DD_MEM_CHUNK 1022 - -/* These definitions work for CUDD_VALUE_TYPE == double */ -#define DD_ONE_VAL (1.0) -#define DD_ZERO_VAL (0.0) -#define DD_EPSILON (1.0e-12) - -/* The definitions of +/- infinity in terms of HUGE_VAL work on -** the DECstations and on many other combinations of OS/compiler. -*/ -#ifdef HAVE_IEEE_754 -# define DD_PLUS_INF_VAL (HUGE_VAL) -#else -# define DD_PLUS_INF_VAL (10e301) -# define DD_CRI_HI_MARK (10e150) -# define DD_CRI_LO_MARK (-(DD_CRI_HI_MARK)) -#endif -#define DD_MINUS_INF_VAL (-(DD_PLUS_INF_VAL)) - -#define DD_NON_CONSTANT ((DdNode *) 1) /* for Cudd_bddIteConstant */ - -/* Unique table and cache management constants. */ -#define DD_MAX_SUBTABLE_DENSITY 4 /* tells when to resize a subtable */ -/* gc when this percent are dead (measured w.r.t. slots, not keys) -** The first limit (LO) applies normally. The second limit applies when -** the package believes more space for the unique table (i.e., more dead -** nodes) would improve performance, and the unique table is not already -** too large. The third limit applies when memory is low. -*/ -#define DD_GC_FRAC_LO DD_MAX_SUBTABLE_DENSITY * 0.25 -#define DD_GC_FRAC_HI DD_MAX_SUBTABLE_DENSITY * 1.0 -#define DD_GC_FRAC_MIN 0.2 -#define DD_MIN_HIT 30 /* resize cache when hit ratio - above this percentage (default) */ -#define DD_MAX_LOOSE_FRACTION 5 /* 1 / (max fraction of memory used for - unique table in fast growth mode) */ -#define DD_MAX_CACHE_FRACTION 3 /* 1 / (max fraction of memory used for - computed table if resizing enabled) */ -#define DD_STASH_FRACTION 64 /* 1 / (fraction of memory set - aside for emergencies) */ -#define DD_MAX_CACHE_TO_SLOTS_RATIO 4 /* used to limit the cache size */ - -/* Variable ordering default parameter values. */ -#define DD_SIFT_MAX_VAR 1000 -#define DD_SIFT_MAX_SWAPS 2000000 -#define DD_DEFAULT_RECOMB 0 -#define DD_MAX_REORDER_GROWTH 1.2 -#define DD_FIRST_REORDER 4004 /* 4 for the constants */ -#define DD_DYN_RATIO 2 /* when to dynamically reorder */ - -/* Primes for cache hash functions. */ -#define DD_P1 12582917 -#define DD_P2 4256249 -#define DD_P3 741457 -#define DD_P4 1618033999 - -/* Cache tags for 3-operand operators. These tags are stored in the -** least significant bits of the cache operand pointers according to -** the following scheme. The tag consists of two hex digits. Both digits -** must be even, so that they do not interfere with complementation bits. -** The least significant one is stored in Bits 3:1 of the f operand in the -** cache entry. Bit 1 is always 1, so that we can differentiate -** three-operand operations from one- and two-operand operations. -** Therefore, the least significant digit is one of {2,6,a,e}. The most -** significant digit occupies Bits 3:1 of the g operand in the cache -** entry. It can by any even digit between 0 and e. This gives a total -** of 5 bits for the tag proper, which means a maximum of 32 three-operand -** operations. */ -#define DD_ADD_ITE_TAG 0x02 -#define DD_BDD_AND_ABSTRACT_TAG 0x06 -#define DD_BDD_XOR_EXIST_ABSTRACT_TAG 0x0a -#define DD_BDD_ITE_TAG 0x0e -#define DD_ADD_BDD_DO_INTERVAL_TAG 0x22 -#define DD_BDD_CLIPPING_AND_ABSTRACT_UP_TAG 0x26 -#define DD_BDD_CLIPPING_AND_ABSTRACT_DOWN_TAG 0x2a -#define DD_BDD_COMPOSE_RECUR_TAG 0x2e -#define DD_ADD_COMPOSE_RECUR_TAG 0x42 -#define DD_ADD_NON_SIM_COMPOSE_TAG 0x46 -#define DD_EQUIV_DC_TAG 0x4a -#define DD_ZDD_ITE_TAG 0x4e -#define DD_ADD_ITE_CONSTANT_TAG 0x62 -#define DD_ADD_EVAL_CONST_TAG 0x66 -#define DD_BDD_ITE_CONSTANT_TAG 0x6a -#define DD_ADD_OUT_SUM_TAG 0x6e -#define DD_BDD_LEQ_UNLESS_TAG 0x82 -#define DD_ADD_TRIANGLE_TAG 0x86 -#define DD_BDD_MAX_EXP_TAG 0x8a - -/* Generator constants. */ -#define CUDD_GEN_CUBES 0 -#define CUDD_GEN_PRIMES 1 -#define CUDD_GEN_NODES 2 -#define CUDD_GEN_ZDD_PATHS 3 -#define CUDD_GEN_EMPTY 0 -#define CUDD_GEN_NONEMPTY 1 - - -/*---------------------------------------------------------------------------*/ -/* Stucture declarations */ -/*---------------------------------------------------------------------------*/ - -struct DdGen { - DdManager *manager; - int type; - int status; - union { - struct { - int *cube; - CUDD_VALUE_TYPE value; - } cubes; - struct { - int *cube; - DdNode *ub; - } primes; - struct { - int size; - } nodes; - } gen; - struct { - int sp; - DdNode **stack; - } stack; - DdNode *node; -}; - - -/*---------------------------------------------------------------------------*/ -/* Type declarations */ -/*---------------------------------------------------------------------------*/ - -/* Hooks in CUDD are functions that the application registers with the -** manager so that they are called at appropriate times. The functions -** are passed the manager as argument; they should return 1 if -** successful and 0 otherwise. -*/ -typedef struct DdHook { /* hook list element */ - DD_HFP f; /* function to be called */ - struct DdHook *next; /* next element in the list */ -} DdHook; - -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 -typedef long ptrint; -typedef unsigned long ptruint; -#else -typedef int ptrint; -typedef unsigned int ptruint; -#endif - -typedef DdNode *DdNodePtr; - -/* Generic local cache item. */ -typedef struct DdLocalCacheItem { - DdNode *value; -#ifdef DD_CACHE_PROFILE - ptrint count; -#endif - DdNode *key[1]; -} DdLocalCacheItem; - -/* Local cache. */ -typedef struct DdLocalCache { - DdLocalCacheItem *item; - unsigned int itemsize; - unsigned int keysize; - unsigned int slots; - int shift; - double lookUps; - double minHit; - double hits; - unsigned int maxslots; - DdManager *manager; - struct DdLocalCache *next; -} DdLocalCache; - -/* Generic hash item. */ -typedef struct DdHashItem { - struct DdHashItem *next; - ptrint count; - DdNode *value; - DdNode *key[1]; -} DdHashItem; - -/* Local hash table */ -typedef struct DdHashTable { - unsigned int keysize; - unsigned int itemsize; - DdHashItem **bucket; - DdHashItem *nextFree; - DdHashItem **memoryList; - unsigned int numBuckets; - int shift; - unsigned int size; - unsigned int maxsize; - DdManager *manager; -} DdHashTable; - -typedef struct DdCache { - DdNode *f,*g; /* DDs */ - ptruint h; /* either operator or DD */ - DdNode *data; /* already constructed DD */ -#ifdef DD_CACHE_PROFILE - ptrint count; -#endif -} DdCache; - -typedef struct DdSubtable { /* subtable for one index */ - DdNode **nodelist; /* hash table */ - int shift; /* shift for hash function */ - unsigned int slots; /* size of the hash table */ - unsigned int keys; /* number of nodes stored in this table */ - unsigned int maxKeys; /* slots * DD_MAX_SUBTABLE_DENSITY */ - unsigned int dead; /* number of dead nodes in this table */ - unsigned int next; /* index of next variable in group */ - int bindVar; /* flag to bind this variable to its level */ - /* Fields for lazy sifting. */ - Cudd_VariableType varType; /* variable type (ps, ns, pi) */ - int pairIndex; /* corresponding variable index (ps <-> ns) */ - int varHandled; /* flag: 1 means variable is already handled */ - Cudd_LazyGroupType varToBeGrouped; /* tells what grouping to apply */ -} DdSubtable; - -struct DdManager { /* specialized DD symbol table */ - /* Constants */ - DdNode sentinel; /* for collision lists */ - DdNode *one; /* constant 1 */ - DdNode *zero; /* constant 0 */ - DdNode *plusinfinity; /* plus infinity */ - DdNode *minusinfinity; /* minus infinity */ - DdNode *background; /* background value */ - /* Computed Table */ - DdCache *acache; /* address of allocated memory for cache */ - DdCache *cache; /* the cache-based computed table */ - unsigned int cacheSlots; /* total number of cache entries */ - int cacheShift; /* shift value for cache hash function */ - double cacheMisses; /* number of cache misses (since resizing) */ - double cacheHits; /* number of cache hits (since resizing) */ - double minHit; /* hit percentage above which to resize */ - int cacheSlack; /* slots still available for resizing */ - unsigned int maxCacheHard; /* hard limit for cache size */ - /* Unique Table */ - int size; /* number of unique subtables */ - int sizeZ; /* for ZDD */ - int maxSize; /* max number of subtables before resizing */ - int maxSizeZ; /* for ZDD */ - DdSubtable *subtables; /* array of unique subtables */ - DdSubtable *subtableZ; /* for ZDD */ - DdSubtable constants; /* unique subtable for the constants */ - unsigned int slots; /* total number of hash buckets */ - unsigned int keys; /* total number of BDD and ADD nodes */ - unsigned int keysZ; /* total number of ZDD nodes */ - unsigned int dead; /* total number of dead BDD and ADD nodes */ - unsigned int deadZ; /* total number of dead ZDD nodes */ - unsigned int maxLive; /* maximum number of live nodes */ - unsigned int minDead; /* do not GC if fewer than these dead */ - double gcFrac; /* gc when this fraction is dead */ - int gcEnabled; /* gc is enabled */ - unsigned int looseUpTo; /* slow growth beyond this limit */ - /* (measured w.r.t. slots, not keys) */ - unsigned int initSlots; /* initial size of a subtable */ - DdNode **stack; /* stack for iterative procedures */ - double allocated; /* number of nodes allocated */ - /* (not during reordering) */ - double reclaimed; /* number of nodes brought back from the dead */ - int isolated; /* isolated projection functions */ - int *perm; /* current variable perm. (index to level) */ - int *permZ; /* for ZDD */ - int *invperm; /* current inv. var. perm. (level to index) */ - int *invpermZ; /* for ZDD */ - DdNode **vars; /* projection functions */ - int *map; /* variable map for fast swap */ - DdNode **univ; /* ZDD 1 for each variable */ - int linearSize; /* number of rows and columns of linear */ - long *interact; /* interacting variable matrix */ - long *linear; /* linear transform matrix */ - /* Memory Management */ - DdNode **memoryList; /* memory manager for symbol table */ - DdNode *nextFree; /* list of free nodes */ - char *stash; /* memory reserve */ -#ifndef DD_NO_DEATH_ROW - DdNode **deathRow; /* queue for dereferencing */ - int deathRowDepth; /* number of slots in the queue */ - int nextDead; /* index in the queue */ - unsigned deadMask; /* mask for circular index update */ -#endif - /* General Parameters */ - CUDD_VALUE_TYPE epsilon; /* tolerance on comparisons */ - /* Dynamic Reordering Parameters */ - int reordered; /* flag set at the end of reordering */ - unsigned int reorderings; /* number of calls to Cudd_ReduceHeap */ - unsigned int maxReorderings;/* maximum number of calls to Cudd_ReduceHeap */ - int siftMaxVar; /* maximum number of vars sifted */ - int siftMaxSwap; /* maximum number of swaps per sifting */ - double maxGrowth; /* maximum growth during reordering */ - double maxGrowthAlt; /* alternate maximum growth for reordering */ - int reordCycle; /* how often to apply alternate threshold */ - int autoDyn; /* automatic dynamic reordering flag (BDD) */ - int autoDynZ; /* automatic dynamic reordering flag (ZDD) */ - Cudd_ReorderingType autoMethod; /* default reordering method */ - Cudd_ReorderingType autoMethodZ; /* default reordering method (ZDD) */ - int realign; /* realign ZDD order after BDD reordering */ - int realignZ; /* realign BDD order after ZDD reordering */ - unsigned int nextDyn; /* reorder if this size is reached */ - unsigned int countDead; /* if 0, count deads to trigger reordering */ - MtrNode *tree; /* variable group tree (BDD) */ - MtrNode *treeZ; /* variable group tree (ZDD) */ - Cudd_AggregationType groupcheck; /* used during group sifting */ - int recomb; /* used during group sifting */ - int symmviolation; /* used during group sifting */ - int arcviolation; /* used during group sifting */ - int populationSize; /* population size for GA */ - int numberXovers; /* number of crossovers for GA */ - unsigned int randomizeOrder; /* perturb the next reordering threshold */ - DdLocalCache *localCaches; /* local caches currently in existence */ - char *hooks; /* application-specific field (used by vis) */ - DdHook *preGCHook; /* hooks to be called before GC */ - DdHook *postGCHook; /* hooks to be called after GC */ - DdHook *preReorderingHook; /* hooks to be called before reordering */ - DdHook *postReorderingHook; /* hooks to be called after reordering */ - FILE *out; /* stdout for this manager */ - FILE *err; /* stderr for this manager */ - Cudd_ErrorType errorCode; /* info on last error */ - unsigned long startTime; /* start time in milliseconds */ - unsigned long timeLimit; /* CPU time limit */ - /* Statistical counters. */ - unsigned long memused; /* total memory allocated for the manager */ - unsigned long maxmem; /* target maximum memory */ - unsigned long maxmemhard; /* hard limit for maximum memory */ - int garbageCollections; /* number of garbage collections */ - unsigned long GCTime; /* total time spent in garbage collection */ - unsigned long reordTime; /* total time spent in reordering */ - double totCachehits; /* total number of cache hits */ - double totCacheMisses; /* total number of cache misses */ - double cachecollisions; /* number of cache collisions */ - double cacheinserts; /* number of cache insertions */ - double cacheLastInserts; /* insertions at the last cache resizing */ - double cachedeletions; /* number of deletions during garbage coll. */ -#ifdef DD_STATS - double nodesFreed; /* number of nodes returned to the free list */ - double nodesDropped; /* number of nodes killed by dereferencing */ -#endif - unsigned int peakLiveNodes; /* maximum number of live nodes */ -#ifdef DD_UNIQUE_PROFILE - double uniqueLookUps; /* number of unique table lookups */ - double uniqueLinks; /* total distance traveled in coll. chains */ -#endif -#ifdef DD_COUNT - double recursiveCalls; /* number of recursive calls */ -#ifdef DD_STATS - double nextSample; /* when to write next line of stats */ -#endif - double swapSteps; /* number of elementary reordering steps */ -#endif -#ifdef DD_MIS - /* mis/verif compatibility fields */ - array_t *iton; /* maps ids in ddNode to node_t */ - array_t *order; /* copy of order_list */ - lsHandle handle; /* where it is in network BDD list */ - network_t *network; - st_table *local_order; /* for local BDDs */ - int nvars; /* variables used so far */ - int threshold; /* for pseudo var threshold value*/ -#endif -}; - -typedef struct Move { - DdHalfWord x; - DdHalfWord y; - unsigned int flags; - int size; - struct Move *next; -} Move; - -/* Generic level queue item. */ -typedef struct DdQueueItem { - struct DdQueueItem *next; - struct DdQueueItem *cnext; - void *key; -} DdQueueItem; - -/* Level queue. */ -typedef struct DdLevelQueue { - void *first; - DdQueueItem **last; - DdQueueItem *freelist; - DdQueueItem **buckets; - int levels; - int itemsize; - int size; - int maxsize; - int numBuckets; - int shift; -} DdLevelQueue; - -/*---------------------------------------------------------------------------*/ -/* Variable declarations */ -/*---------------------------------------------------------------------------*/ - - -/*---------------------------------------------------------------------------*/ -/* Macro declarations */ -/*---------------------------------------------------------------------------*/ - -/**Macro*********************************************************************** - - Synopsis [Adds node to the head of the free list.] - - Description [Adds node to the head of the free list. Does not - deallocate memory chunks that become free. This function is also - used by the dynamic reordering functions.] - - SideEffects [None] - - SeeAlso [cuddAllocNode cuddDynamicAllocNode cuddDeallocMove] - -******************************************************************************/ -#define cuddDeallocNode(unique,node) \ - (node)->next = (unique)->nextFree; \ - (unique)->nextFree = node; - -/**Macro*********************************************************************** - - Synopsis [Adds node to the head of the free list.] - - Description [Adds node to the head of the free list. Does not - deallocate memory chunks that become free. This function is also - used by the dynamic reordering functions.] - - SideEffects [None] - - SeeAlso [cuddDeallocNode cuddDynamicAllocNode] - -******************************************************************************/ -#define cuddDeallocMove(unique,node) \ - ((DdNode *)(node))->ref = 0; \ - ((DdNode *)(node))->next = (unique)->nextFree; \ - (unique)->nextFree = (DdNode *)(node); - - -/**Macro*********************************************************************** - - Synopsis [Increases the reference count of a node, if it is not - saturated.] - - Description [Increases the reference count of a node, if it is not - saturated. This being a macro, it is faster than Cudd_Ref, but it - cannot be used in constructs like cuddRef(a = b()).] - - SideEffects [none] - - SeeAlso [Cudd_Ref] - -******************************************************************************/ -#define cuddRef(n) cuddSatInc(Cudd_Regular(n)->ref) - - -/**Macro*********************************************************************** - - Synopsis [Decreases the reference count of a node, if it is not - saturated.] - - Description [Decreases the reference count of node. It is primarily - used in recursive procedures to decrease the ref count of a result - node before returning it. This accomplishes the goal of removing the - protection applied by a previous cuddRef. This being a macro, it is - faster than Cudd_Deref, but it cannot be used in constructs like - cuddDeref(a = b()).] - - SideEffects [none] - - SeeAlso [Cudd_Deref] - -******************************************************************************/ -#define cuddDeref(n) cuddSatDec(Cudd_Regular(n)->ref) - - -/**Macro*********************************************************************** - - Synopsis [Returns 1 if the node is a constant node.] - - Description [Returns 1 if the node is a constant node (rather than an - internal node). All constant nodes have the same index - (CUDD_CONST_INDEX). The pointer passed to cuddIsConstant must be regular.] - - SideEffects [none] - - SeeAlso [Cudd_IsConstant] - -******************************************************************************/ -#define cuddIsConstant(node) ((node)->index == CUDD_CONST_INDEX) - - -/**Macro*********************************************************************** - - Synopsis [Returns the then child of an internal node.] - - Description [Returns the then child of an internal node. If - <code>node</code> is a constant node, the result is unpredictable. - The pointer passed to cuddT must be regular.] - - SideEffects [none] - - SeeAlso [Cudd_T] - -******************************************************************************/ -#define cuddT(node) ((node)->type.kids.T) - - -/**Macro*********************************************************************** - - Synopsis [Returns the else child of an internal node.] - - Description [Returns the else child of an internal node. If - <code>node</code> is a constant node, the result is unpredictable. - The pointer passed to cuddE must be regular.] - - SideEffects [none] - - SeeAlso [Cudd_E] - -******************************************************************************/ -#define cuddE(node) ((node)->type.kids.E) - - -/**Macro*********************************************************************** - - Synopsis [Returns the value of a constant node.] - - Description [Returns the value of a constant node. If - <code>node</code> is an internal node, the result is unpredictable. - The pointer passed to cuddV must be regular.] - - SideEffects [none] - - SeeAlso [Cudd_V] - -******************************************************************************/ -#define cuddV(node) ((node)->type.value) - - -/**Macro*********************************************************************** - - Synopsis [Finds the current position of variable index in the - order.] - - Description [Finds the current position of variable index in the - order. This macro duplicates the functionality of Cudd_ReadPerm, - but it does not check for out-of-bounds indices and it is more - efficient.] - - SideEffects [none] - - SeeAlso [Cudd_ReadPerm] - -******************************************************************************/ -#define cuddI(dd,index) (((index)==CUDD_CONST_INDEX)?(int)(index):(dd)->perm[(index)]) - - -/**Macro*********************************************************************** - - Synopsis [Finds the current position of ZDD variable index in the - order.] - - Description [Finds the current position of ZDD variable index in the - order. This macro duplicates the functionality of Cudd_ReadPermZdd, - but it does not check for out-of-bounds indices and it is more - efficient.] - - SideEffects [none] - - SeeAlso [Cudd_ReadPermZdd] - -******************************************************************************/ -#define cuddIZ(dd,index) (((index)==CUDD_CONST_INDEX)?(int)(index):(dd)->permZ[(index)]) - - -/**Macro*********************************************************************** - - Synopsis [Hash function for the unique table.] - - Description [] - - SideEffects [none] - - SeeAlso [ddCHash ddCHash2] - -******************************************************************************/ -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 -#define ddHash(f,g,s) \ -((((unsigned)(ptruint)(f) * DD_P1 + \ - (unsigned)(ptruint)(g)) * DD_P2) >> (s)) -#else -#define ddHash(f,g,s) \ -((((unsigned)(f) * DD_P1 + (unsigned)(g)) * DD_P2) >> (s)) -#endif - - -/**Macro*********************************************************************** - - Synopsis [Hash function for the cache.] - - Description [] - - SideEffects [none] - - SeeAlso [ddHash ddCHash2] - -******************************************************************************/ -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 -#define ddCHash(o,f,g,h,s) \ -((((((unsigned)(ptruint)(f) + (unsigned)(ptruint)(o)) * DD_P1 + \ - (unsigned)(ptruint)(g)) * DD_P2 + \ - (unsigned)(ptruint)(h)) * DD_P3) >> (s)) -#else -#define ddCHash(o,f,g,h,s) \ -((((((unsigned)(f) + (unsigned)(o)) * DD_P1 + (unsigned)(g)) * DD_P2 + \ - (unsigned)(h)) * DD_P3) >> (s)) -#endif - - -/**Macro*********************************************************************** - - Synopsis [Hash function for the cache for functions with two - operands.] - - Description [] - - SideEffects [none] - - SeeAlso [ddHash ddCHash] - -******************************************************************************/ -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 -#define ddCHash2(o,f,g,s) \ -(((((unsigned)(ptruint)(f) + (unsigned)(ptruint)(o)) * DD_P1 + \ - (unsigned)(ptruint)(g)) * DD_P2) >> (s)) -#else -#define ddCHash2(o,f,g,s) \ -(((((unsigned)(f) + (unsigned)(o)) * DD_P1 + (unsigned)(g)) * DD_P2) >> (s)) -#endif - - -/**Macro*********************************************************************** - - Synopsis [Clears the 4 least significant bits of a pointer.] - - Description [] - - SideEffects [none] - - SeeAlso [] - -******************************************************************************/ -#define cuddClean(p) ((DdNode *)((ptruint)(p) & ~0xf)) - - -/**Macro*********************************************************************** - - Synopsis [Computes the minimum of two numbers.] - - Description [] - - SideEffects [none] - - SeeAlso [ddMax] - -******************************************************************************/ -#define ddMin(x,y) (((y) < (x)) ? (y) : (x)) - - -/**Macro*********************************************************************** - - Synopsis [Computes the maximum of two numbers.] - - Description [] - - SideEffects [none] - - SeeAlso [ddMin] - -******************************************************************************/ -#define ddMax(x,y) (((y) > (x)) ? (y) : (x)) - - -/**Macro*********************************************************************** - - Synopsis [Computes the absolute value of a number.] - - Description [] - - SideEffects [none] - - SeeAlso [] - -******************************************************************************/ -#define ddAbs(x) (((x)<0) ? -(x) : (x)) - - -/**Macro*********************************************************************** - - Synopsis [Returns 1 if the absolute value of the difference of the two - arguments x and y is less than e.] - - Description [] - - SideEffects [none] - - SeeAlso [] - -******************************************************************************/ -#define ddEqualVal(x,y,e) (ddAbs((x)-(y))<(e)) - - -/**Macro*********************************************************************** - - Synopsis [Saturating increment operator.] - - Description [] - - SideEffects [none] - - SeeAlso [cuddSatDec] - -******************************************************************************/ -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 -#define cuddSatInc(x) ((x)++) -#else -#define cuddSatInc(x) ((x) += (x) != (DdHalfWord)DD_MAXREF) -#endif - - -/**Macro*********************************************************************** - - Synopsis [Saturating decrement operator.] - - Description [] - - SideEffects [none] - - SeeAlso [cuddSatInc] - -******************************************************************************/ -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 -#define cuddSatDec(x) ((x)--) -#else -#define cuddSatDec(x) ((x) -= (x) != (DdHalfWord)DD_MAXREF) -#endif - - -/**Macro*********************************************************************** - - Synopsis [Returns the constant 1 node.] - - Description [] - - SideEffects [none] - - SeeAlso [DD_ZERO DD_PLUS_INFINITY DD_MINUS_INFINITY] - -******************************************************************************/ -#define DD_ONE(dd) ((dd)->one) - - -/**Macro*********************************************************************** - - Synopsis [Returns the arithmetic 0 constant node.] - - Description [Returns the arithmetic 0 constant node. This is different - from the logical zero. The latter is obtained by - Cudd_Not(DD_ONE(dd)).] - - SideEffects [none] - - SeeAlso [DD_ONE Cudd_Not DD_PLUS_INFINITY DD_MINUS_INFINITY] - -******************************************************************************/ -#define DD_ZERO(dd) ((dd)->zero) - - -/**Macro*********************************************************************** - - Synopsis [Returns the plus infinity constant node.] - - Description [] - - SideEffects [none] - - SeeAlso [DD_ONE DD_ZERO DD_MINUS_INFINITY] - -******************************************************************************/ -#define DD_PLUS_INFINITY(dd) ((dd)->plusinfinity) - - -/**Macro*********************************************************************** - - Synopsis [Returns the minus infinity constant node.] - - Description [] - - SideEffects [none] - - SeeAlso [DD_ONE DD_ZERO DD_PLUS_INFINITY] - -******************************************************************************/ -#define DD_MINUS_INFINITY(dd) ((dd)->minusinfinity) - - -/**Macro*********************************************************************** - - Synopsis [Enforces DD_MINUS_INF_VAL <= x <= DD_PLUS_INF_VAL.] - - Description [Enforces DD_MINUS_INF_VAL <= x <= DD_PLUS_INF_VAL. - Furthermore, if x <= DD_MINUS_INF_VAL/2, x is set to - DD_MINUS_INF_VAL. Similarly, if DD_PLUS_INF_VAL/2 <= x, x is set to - DD_PLUS_INF_VAL. Normally this macro is a NOOP. However, if - HAVE_IEEE_754 is not defined, it makes sure that a value does not - get larger than infinity in absolute value, and once it gets to - infinity, stays there. If the value overflows before this macro is - applied, no recovery is possible.] - - SideEffects [none] - - SeeAlso [] - -******************************************************************************/ -#ifdef HAVE_IEEE_754 -#define cuddAdjust(x) -#else -#define cuddAdjust(x) ((x) = ((x) >= DD_CRI_HI_MARK) ? DD_PLUS_INF_VAL : (((x) <= DD_CRI_LO_MARK) ? DD_MINUS_INF_VAL : (x))) -#endif - - -/**Macro*********************************************************************** - - Synopsis [Extract the least significant digit of a double digit.] - - Description [Extract the least significant digit of a double digit. Used - in the manipulation of arbitrary precision integers.] - - SideEffects [None] - - SeeAlso [DD_MSDIGIT] - -******************************************************************************/ -#define DD_LSDIGIT(x) ((x) & DD_APA_MASK) - - -/**Macro*********************************************************************** - - Synopsis [Extract the most significant digit of a double digit.] - - Description [Extract the most significant digit of a double digit. Used - in the manipulation of arbitrary precision integers.] - - SideEffects [None] - - SeeAlso [DD_LSDIGIT] - -******************************************************************************/ -#define DD_MSDIGIT(x) ((x) >> DD_APA_BITS) - - -/**Macro*********************************************************************** - - Synopsis [Outputs a line of stats.] - - Description [Outputs a line of stats if DD_COUNT and DD_STATS are - defined. Increments the number of recursive calls if DD_COUNT is - defined.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -#ifdef DD_COUNT -#ifdef DD_STATS -#define statLine(dd) dd->recursiveCalls++; \ -if (dd->recursiveCalls == dd->nextSample) {(void) fprintf(dd->err, \ -"@%.0f: %u nodes %u live %.0f dropped %.0f reclaimed\n", dd->recursiveCalls, \ -dd->keys, dd->keys - dd->dead, dd->nodesDropped, dd->reclaimed); \ -dd->nextSample += 250000;} -#else -#define statLine(dd) dd->recursiveCalls++; -#endif -#else -#define statLine(dd) -#endif - - -/**AutomaticStart*************************************************************/ - -/*---------------------------------------------------------------------------*/ -/* Function prototypes */ -/*---------------------------------------------------------------------------*/ - -extern DdNode * cuddAddExistAbstractRecur (DdManager *manager, DdNode *f, DdNode *cube); -extern DdNode * cuddAddUnivAbstractRecur (DdManager *manager, DdNode *f, DdNode *cube); -extern DdNode * cuddAddOrAbstractRecur (DdManager *manager, DdNode *f, DdNode *cube); -extern DdNode * cuddAddMinAbstractRecur (DdManager *manager, DdNode *f, DdNode *cube); -extern DdNode * cuddAddMaxAbstractRecur (DdManager *manager, DdNode *f, DdNode *cube); -extern DdNode * cuddAddApplyRecur (DdManager *dd, DdNode * (*)(DdManager *, DdNode **, DdNode **), DdNode *f, DdNode *g); -extern DdNode * cuddAddMonadicApplyRecur (DdManager * dd, DdNode * (*op)(DdManager *, DdNode *), DdNode * f); -extern DdNode * cuddAddScalarInverseRecur (DdManager *dd, DdNode *f, DdNode *epsilon); -extern DdNode * cuddAddIteRecur (DdManager *dd, DdNode *f, DdNode *g, DdNode *h); -extern DdNode * cuddAddCmplRecur (DdManager *dd, DdNode *f); -extern DdNode * cuddAddNegateRecur (DdManager *dd, DdNode *f); -extern DdNode * cuddAddRoundOffRecur (DdManager *dd, DdNode *f, double trunc); -extern DdNode * cuddUnderApprox (DdManager *dd, DdNode *f, int numVars, int threshold, int safe, double quality); -extern DdNode * cuddRemapUnderApprox (DdManager *dd, DdNode *f, int numVars, int threshold, double quality); -extern DdNode * cuddBiasedUnderApprox (DdManager *dd, DdNode *f, DdNode *b, int numVars, int threshold, double quality1, double quality0); -extern DdNode * cuddBddAndAbstractRecur (DdManager *manager, DdNode *f, DdNode *g, DdNode *cube); -extern int cuddAnnealing (DdManager *table, int lower, int upper); -extern DdNode * cuddBddExistAbstractRecur (DdManager *manager, DdNode *f, DdNode *cube); -extern DdNode * cuddBddXorExistAbstractRecur (DdManager *manager, DdNode *f, DdNode *g, DdNode *cube); -extern DdNode * cuddBddBooleanDiffRecur (DdManager *manager, DdNode *f, DdNode *var); -extern DdNode * cuddBddIteRecur (DdManager *dd, DdNode *f, DdNode *g, DdNode *h); -extern DdNode * cuddBddIntersectRecur (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * cuddBddAndRecur (DdManager *manager, DdNode *f, DdNode *g); -extern DdNode * cuddBddXorRecur (DdManager *manager, DdNode *f, DdNode *g); -extern DdNode * cuddBddTransfer (DdManager *ddS, DdManager *ddD, DdNode *f); -extern DdNode * cuddAddBddDoPattern (DdManager *dd, DdNode *f); -extern int cuddInitCache (DdManager *unique, unsigned int cacheSize, unsigned int maxCacheSize); -extern void cuddCacheInsert (DdManager *table, ptruint op, DdNode *f, DdNode *g, DdNode *h, DdNode *data); -extern void cuddCacheInsert2 (DdManager *table, DdNode * (*)(DdManager *, DdNode *, DdNode *), DdNode *f, DdNode *g, DdNode *data); -extern void cuddCacheInsert1 (DdManager *table, DdNode * (*)(DdManager *, DdNode *), DdNode *f, DdNode *data); -extern DdNode * cuddCacheLookup (DdManager *table, ptruint op, DdNode *f, DdNode *g, DdNode *h); -extern DdNode * cuddCacheLookupZdd (DdManager *table, ptruint op, DdNode *f, DdNode *g, DdNode *h); -extern DdNode * cuddCacheLookup2 (DdManager *table, DdNode * (*)(DdManager *, DdNode *, DdNode *), DdNode *f, DdNode *g); -extern DdNode * cuddCacheLookup1 (DdManager *table, DdNode * (*)(DdManager *, DdNode *), DdNode *f); -extern DdNode * cuddCacheLookup2Zdd (DdManager *table, DdNode * (*)(DdManager *, DdNode *, DdNode *), DdNode *f, DdNode *g); -extern DdNode * cuddCacheLookup1Zdd (DdManager *table, DdNode * (*)(DdManager *, DdNode *), DdNode *f); -extern DdNode * cuddConstantLookup (DdManager *table, ptruint op, DdNode *f, DdNode *g, DdNode *h); -extern int cuddCacheProfile (DdManager *table, FILE *fp); -extern void cuddCacheResize (DdManager *table); -extern void cuddCacheFlush (DdManager *table); -extern int cuddComputeFloorLog2 (unsigned int value); -extern int cuddHeapProfile (DdManager *dd); -extern void cuddPrintNode (DdNode *f, FILE *fp); -extern void cuddPrintVarGroups (DdManager * dd, MtrNode * root, int zdd, int silent); -extern DdNode * cuddBddClippingAnd (DdManager *dd, DdNode *f, DdNode *g, int maxDepth, int direction); -extern DdNode * cuddBddClippingAndAbstract (DdManager *dd, DdNode *f, DdNode *g, DdNode *cube, int maxDepth, int direction); -extern void cuddGetBranches (DdNode *g, DdNode **g1, DdNode **g0); -extern DdNode * cuddCofactorRecur (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * cuddBddComposeRecur (DdManager *dd, DdNode *f, DdNode *g, DdNode *proj); -extern DdNode * cuddAddComposeRecur (DdManager *dd, DdNode *f, DdNode *g, DdNode *proj); -extern int cuddExact (DdManager *table, int lower, int upper); -extern DdNode * cuddBddConstrainRecur (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode * cuddBddRestrictRecur (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode * cuddBddNPAndRecur (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode * cuddAddConstrainRecur (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode * cuddAddRestrictRecur (DdManager *dd, DdNode *f, DdNode *c); -extern DdNode * cuddBddLICompaction (DdManager *dd, DdNode *f, DdNode *c); -extern int cuddGa (DdManager *table, int lower, int upper); -extern int cuddTreeSifting (DdManager *table, Cudd_ReorderingType method); -extern int cuddZddInitUniv (DdManager *zdd); -extern void cuddZddFreeUniv (DdManager *zdd); -extern void cuddSetInteract (DdManager *table, int x, int y); -extern int cuddTestInteract (DdManager *table, int x, int y); -extern int cuddInitInteract (DdManager *table); -extern DdLocalCache * cuddLocalCacheInit (DdManager *manager, unsigned int keySize, unsigned int cacheSize, unsigned int maxCacheSize); -extern void cuddLocalCacheQuit (DdLocalCache *cache); -extern void cuddLocalCacheInsert (DdLocalCache *cache, DdNodePtr *key, DdNode *value); -extern DdNode * cuddLocalCacheLookup (DdLocalCache *cache, DdNodePtr *key); -extern void cuddLocalCacheClearDead (DdManager *manager); -extern int cuddIsInDeathRow (DdManager *dd, DdNode *f); -extern int cuddTimesInDeathRow (DdManager *dd, DdNode *f); -extern void cuddLocalCacheClearAll (DdManager *manager); -#ifdef DD_CACHE_PROFILE -extern int cuddLocalCacheProfile (DdLocalCache *cache); -#endif -extern DdHashTable * cuddHashTableInit (DdManager *manager, unsigned int keySize, unsigned int initSize); -extern void cuddHashTableQuit (DdHashTable *hash); -extern void cuddHashTableGenericQuit (DdHashTable *hash); -extern int cuddHashTableInsert (DdHashTable *hash, DdNodePtr *key, DdNode *value, ptrint count); -extern DdNode * cuddHashTableLookup (DdHashTable *hash, DdNodePtr *key); -extern int cuddHashTableInsert1 (DdHashTable *hash, DdNode *f, DdNode *value, ptrint count); -extern DdNode * cuddHashTableLookup1 (DdHashTable *hash, DdNode *f); -extern int cuddHashTableInsert2 (DdHashTable *hash, DdNode *f, DdNode *g, DdNode *value, ptrint count); -extern DdNode * cuddHashTableLookup2 (DdHashTable *hash, DdNode *f, DdNode *g); -extern int cuddHashTableInsert3 (DdHashTable *hash, DdNode *f, DdNode *g, DdNode *h, DdNode *value, ptrint count); -extern DdNode * cuddHashTableLookup3 (DdHashTable *hash, DdNode *f, DdNode *g, DdNode *h); -extern int cuddHashTableGenericInsert(DdHashTable * hash, DdNode * f, void * value); -extern void * cuddHashTableGenericLookup(DdHashTable * hash, DdNode * f); -extern DdLevelQueue * cuddLevelQueueInit (int levels, int itemSize, int numBuckets); -extern void cuddLevelQueueQuit (DdLevelQueue *queue); -extern void * cuddLevelQueueFirst(DdLevelQueue * queue, void * key, int level); -extern void * cuddLevelQueueEnqueue (DdLevelQueue *queue, void *key, int level); -extern void cuddLevelQueueDequeue (DdLevelQueue *queue, int level); -extern int cuddLinearAndSifting (DdManager *table, int lower, int upper); -extern int cuddLinearInPlace (DdManager * table, int x, int y); -extern void cuddUpdateInteractionMatrix (DdManager * table, int xindex, int yindex); -extern int cuddInitLinear (DdManager *table); -extern int cuddResizeLinear (DdManager *table); -extern DdNode * cuddBddLiteralSetIntersectionRecur (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * cuddCProjectionRecur (DdManager *dd, DdNode *R, DdNode *Y, DdNode *Ysupp); -extern DdNode * cuddBddClosestCube (DdManager *dd, DdNode *f, DdNode *g, CUDD_VALUE_TYPE bound); -extern void cuddReclaim (DdManager *table, DdNode *n); -extern void cuddReclaimZdd (DdManager *table, DdNode *n); -extern void cuddClearDeathRow (DdManager *table); -extern void cuddShrinkDeathRow (DdManager *table); -extern DdNode * cuddDynamicAllocNode (DdManager *table); -extern int cuddSifting (DdManager *table, int lower, int upper); -extern int cuddSwapping (DdManager *table, int lower, int upper, Cudd_ReorderingType heuristic); -extern int cuddNextHigh (DdManager *table, int x); -extern int cuddNextLow (DdManager *table, int x); -extern int cuddSwapInPlace (DdManager *table, int x, int y); -extern int cuddBddAlignToZdd (DdManager *table); -extern DdNode * cuddBddMakePrime (DdManager *dd, DdNode *cube, DdNode *f); -extern DdNode * cuddSolveEqnRecur (DdManager *bdd, DdNode *F, DdNode *Y, DdNode **G, int n, int *yIndex, int i); -extern DdNode * cuddVerifySol (DdManager *bdd, DdNode *F, DdNode **G, int *yIndex, int n); -#ifdef ST_INCLUDED -extern DdNode* cuddSplitSetRecur (DdManager *manager, st_table *mtable, int *varSeen, DdNode *p, double n, double max, int index); -#endif -extern DdNode * cuddSubsetHeavyBranch (DdManager *dd, DdNode *f, int numVars, int threshold); -extern DdNode * cuddSubsetShortPaths (DdManager *dd, DdNode *f, int numVars, int threshold, int hardlimit); -extern int cuddSymmCheck (DdManager *table, int x, int y); -extern int cuddSymmSifting (DdManager *table, int lower, int upper); -extern int cuddSymmSiftingConv (DdManager *table, int lower, int upper); -extern DdNode * cuddAllocNode (DdManager *unique); -extern DdManager * cuddInitTable (unsigned int numVars, unsigned int numVarsZ, unsigned int numSlots, unsigned int looseUpTo); -extern void cuddFreeTable (DdManager *unique); -extern int cuddGarbageCollect (DdManager *unique, int clearCache); -extern DdNode * cuddZddGetNode (DdManager *zdd, int id, DdNode *T, DdNode *E); -extern DdNode * cuddZddGetNodeIVO (DdManager *dd, int index, DdNode *g, DdNode *h); -extern DdNode * cuddUniqueInter (DdManager *unique, int index, DdNode *T, DdNode *E); -extern DdNode * cuddUniqueInterIVO (DdManager *unique, int index, DdNode *T, DdNode *E); -extern DdNode * cuddUniqueInterZdd (DdManager *unique, int index, DdNode *T, DdNode *E); -extern DdNode * cuddUniqueConst (DdManager *unique, CUDD_VALUE_TYPE value); -extern void cuddRehash (DdManager *unique, int i); -extern void cuddShrinkSubtable (DdManager *unique, int i); -extern int cuddInsertSubtables (DdManager *unique, int n, int level); -extern int cuddDestroySubtables (DdManager *unique, int n); -extern int cuddResizeTableZdd (DdManager *unique, int index); -extern void cuddSlowTableGrowth (DdManager *unique); -extern int cuddP (DdManager *dd, DdNode *f); -#ifdef ST_INCLUDED -extern enum st_retval cuddStCountfree (char *key, char *value, char *arg); -extern int cuddCollectNodes (DdNode *f, st_table *visited); -#endif -extern DdNodePtr * cuddNodeArray (DdNode *f, int *n); -extern int cuddWindowReorder (DdManager *table, int low, int high, Cudd_ReorderingType submethod); -extern DdNode * cuddZddProduct (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * cuddZddUnateProduct (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * cuddZddWeakDiv (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * cuddZddWeakDivF (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * cuddZddDivide (DdManager *dd, DdNode *f, DdNode *g); -extern DdNode * cuddZddDivideF (DdManager *dd, DdNode *f, DdNode *g); -extern int cuddZddGetCofactors3 (DdManager *dd, DdNode *f, int v, DdNode **f1, DdNode **f0, DdNode **fd); -extern int cuddZddGetCofactors2 (DdManager *dd, DdNode *f, int v, DdNode **f1, DdNode **f0); -extern DdNode * cuddZddComplement (DdManager *dd, DdNode *node); -extern int cuddZddGetPosVarIndex(DdManager * dd, int index); -extern int cuddZddGetNegVarIndex(DdManager * dd, int index); -extern int cuddZddGetPosVarLevel(DdManager * dd, int index); -extern int cuddZddGetNegVarLevel(DdManager * dd, int index); -extern int cuddZddTreeSifting (DdManager *table, Cudd_ReorderingType method); -extern DdNode * cuddZddIsop (DdManager *dd, DdNode *L, DdNode *U, DdNode **zdd_I); -extern DdNode * cuddBddIsop (DdManager *dd, DdNode *L, DdNode *U); -extern DdNode * cuddMakeBddFromZddCover (DdManager *dd, DdNode *node); -extern int cuddZddLinearSifting (DdManager *table, int lower, int upper); -extern int cuddZddAlignToBdd (DdManager *table); -extern int cuddZddNextHigh (DdManager *table, int x); -extern int cuddZddNextLow (DdManager *table, int x); -extern int cuddZddUniqueCompare (int *ptr_x, int *ptr_y); -extern int cuddZddSwapInPlace (DdManager *table, int x, int y); -extern int cuddZddSwapping (DdManager *table, int lower, int upper, Cudd_ReorderingType heuristic); -extern int cuddZddSifting (DdManager *table, int lower, int upper); -extern DdNode * cuddZddIte (DdManager *dd, DdNode *f, DdNode *g, DdNode *h); -extern DdNode * cuddZddUnion (DdManager *zdd, DdNode *P, DdNode *Q); -extern DdNode * cuddZddIntersect (DdManager *zdd, DdNode *P, DdNode *Q); -extern DdNode * cuddZddDiff (DdManager *zdd, DdNode *P, DdNode *Q); -extern DdNode * cuddZddChangeAux (DdManager *zdd, DdNode *P, DdNode *zvar); -extern DdNode * cuddZddSubset1 (DdManager *dd, DdNode *P, int var); -extern DdNode * cuddZddSubset0 (DdManager *dd, DdNode *P, int var); -extern DdNode * cuddZddChange (DdManager *dd, DdNode *P, int var); -extern int cuddZddSymmCheck (DdManager *table, int x, int y); -extern int cuddZddSymmSifting (DdManager *table, int lower, int upper); -extern int cuddZddSymmSiftingConv (DdManager *table, int lower, int upper); -extern int cuddZddP (DdManager *zdd, DdNode *f); - -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} /* end of extern "C" */ -#endif - -#endif /* _CUDDINT */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSubsetHB.c b/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSubsetHB.c deleted file mode 100644 index bb0f847b2..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSubsetHB.c +++ /dev/null @@ -1,1331 +0,0 @@ -/**CFile*********************************************************************** - - FileName [cuddSubsetHB.c] - - PackageName [cudd] - - Synopsis [Procedure to subset the given BDD by choosing the heavier - branches.] - - - Description [External procedures provided by this module: - <ul> - <li> Cudd_SubsetHeavyBranch() - <li> Cudd_SupersetHeavyBranch() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddSubsetHeavyBranch() - </ul> - Static procedures included in this module: - <ul> - <li> ResizeCountMintermPages(); - <li> ResizeNodeDataPages() - <li> ResizeCountNodePages() - <li> SubsetCountMintermAux() - <li> SubsetCountMinterm() - <li> SubsetCountNodesAux() - <li> SubsetCountNodes() - <li> BuildSubsetBdd() - </ul> - ] - - SeeAlso [cuddSubsetSP.c] - - Author [Kavita Ravi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado - - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - - Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - - Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - - Neither the name of the University of Colorado nor the names of its - contributors may be used to endorse or promote products derived from - this software without specific prior written permission. - - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, - BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] - -******************************************************************************/ - -#ifdef __STDC__ -#include <float.h> -#else -#define DBL_MAX_EXP 1024 -#endif -#include "util.h" -#include "cuddInt.h" - -/*---------------------------------------------------------------------------*/ -/* Constant declarations */ -/*---------------------------------------------------------------------------*/ - -#define DEFAULT_PAGE_SIZE 2048 -#define DEFAULT_NODE_DATA_PAGE_SIZE 1024 -#define INITIAL_PAGES 128 - - -/*---------------------------------------------------------------------------*/ -/* Stucture declarations */ -/*---------------------------------------------------------------------------*/ - -/* data structure to store the information on each node. It keeps - * the number of minterms represented by the DAG rooted at this node - * in terms of the number of variables specified by the user, number - * of nodes in this DAG and the number of nodes of its child with - * lesser number of minterms that are not shared by the child with - * more minterms - */ -struct NodeData { - double *mintermPointer; - int *nodesPointer; - int *lightChildNodesPointer; -}; - -/*---------------------------------------------------------------------------*/ -/* Type declarations */ -/*---------------------------------------------------------------------------*/ - -typedef struct NodeData NodeData_t; - -/*---------------------------------------------------------------------------*/ -/* Variable declarations */ -/*---------------------------------------------------------------------------*/ - -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddSubsetHB.c,v 1.39 2012/02/05 01:07:19 fabio Exp $"; -#endif - -static int memOut; -#ifdef DEBUG -static int num_calls; -#endif - -static DdNode *zero, *one; /* constant functions */ -static double **mintermPages; /* pointers to the pages */ -static int **nodePages; /* pointers to the pages */ -static int **lightNodePages; /* pointers to the pages */ -static double *currentMintermPage; /* pointer to the current - page */ -static double max; /* to store the 2^n value of the number - * of variables */ - -static int *currentNodePage; /* pointer to the current - page */ -static int *currentLightNodePage; /* pointer to the - * current page */ -static int pageIndex; /* index to next element */ -static int page; /* index to current page */ -static int pageSize = DEFAULT_PAGE_SIZE; /* page size */ -static int maxPages; /* number of page pointers */ - -static NodeData_t *currentNodeDataPage; /* pointer to the current - page */ -static int nodeDataPage; /* index to next element */ -static int nodeDataPageIndex; /* index to next element */ -static NodeData_t **nodeDataPages; /* index to current page */ -static int nodeDataPageSize = DEFAULT_NODE_DATA_PAGE_SIZE; - /* page size */ -static int maxNodeDataPages; /* number of page pointers */ - - -/*---------------------------------------------------------------------------*/ -/* Macro declarations */ -/*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ - -/*---------------------------------------------------------------------------*/ -/* Static function prototypes */ -/*---------------------------------------------------------------------------*/ - -static void ResizeNodeDataPages (void); -static void ResizeCountMintermPages (void); -static void ResizeCountNodePages (void); -static double SubsetCountMintermAux (DdNode *node, double max, st_table *table); -static st_table * SubsetCountMinterm (DdNode *node, int nvars); -static int SubsetCountNodesAux (DdNode *node, st_table *table, double max); -static int SubsetCountNodes (DdNode *node, st_table *table, int nvars); -static void StoreNodes (st_table *storeTable, DdManager *dd, DdNode *node); -static DdNode * BuildSubsetBdd (DdManager *dd, DdNode *node, int *size, st_table *visitedTable, int threshold, st_table *storeTable, st_table *approxTable); - -/**AutomaticEnd***************************************************************/ - - -/*---------------------------------------------------------------------------*/ -/* Definition of exported functions */ -/*---------------------------------------------------------------------------*/ - -/**Function******************************************************************** - - Synopsis [Extracts a dense subset from a BDD with the heavy branch - heuristic.] - - Description [Extracts a dense subset from a BDD. This procedure - builds a subset by throwing away one of the children of each node, - starting from the root, until the result is small enough. The child - that is eliminated from the result is the one that contributes the - fewer minterms. Returns a pointer to the BDD of the subset if - successful. NULL if the procedure runs out of memory. The parameter - numVars is the maximum number of variables to be used in minterm - calculation and node count calculation. The optimal number should - be as close as possible to the size of the support of f. However, - it is safe to pass the value returned by Cudd_ReadSize for numVars - when the number of variables is under 1023. If numVars is larger - than 1023, it will overflow. If a 0 parameter is passed then the - procedure will compute a value which will avoid overflow but will - cause underflow with 2046 variables or more.] - - SideEffects [None] - - SeeAlso [Cudd_SubsetShortPaths Cudd_SupersetHeavyBranch Cudd_ReadSize] - -******************************************************************************/ -DdNode * -Cudd_SubsetHeavyBranch( - DdManager * dd /* manager */, - DdNode * f /* function to be subset */, - int numVars /* number of variables in the support of f */, - int threshold /* maximum number of nodes in the subset */) -{ - DdNode *subset; - - memOut = 0; - do { - dd->reordered = 0; - subset = cuddSubsetHeavyBranch(dd, f, numVars, threshold); - } while ((dd->reordered == 1) && (!memOut)); - - return(subset); - -} /* end of Cudd_SubsetHeavyBranch */ - - -/**Function******************************************************************** - - Synopsis [Extracts a dense superset from a BDD with the heavy branch - heuristic.] - - Description [Extracts a dense superset from a BDD. The procedure is - identical to the subset procedure except for the fact that it - receives the complement of the given function. Extracting the subset - of the complement function is equivalent to extracting the superset - of the function. This procedure builds a superset by throwing away - one of the children of each node starting from the root of the - complement function, until the result is small enough. The child - that is eliminated from the result is the one that contributes the - fewer minterms. - Returns a pointer to the BDD of the superset if successful. NULL if - intermediate result causes the procedure to run out of memory. The - parameter numVars is the maximum number of variables to be used in - minterm calculation and node count calculation. The optimal number - should be as close as possible to the size of the support of f. - However, it is safe to pass the value returned by Cudd_ReadSize for - numVars when the number of variables is under 1023. If numVars is - larger than 1023, it will overflow. If a 0 parameter is passed then - the procedure will compute a value which will avoid overflow but - will cause underflow with 2046 variables or more.] - - SideEffects [None] - - SeeAlso [Cudd_SubsetHeavyBranch Cudd_SupersetShortPaths Cudd_ReadSize] - -******************************************************************************/ -DdNode * -Cudd_SupersetHeavyBranch( - DdManager * dd /* manager */, - DdNode * f /* function to be superset */, - int numVars /* number of variables in the support of f */, - int threshold /* maximum number of nodes in the superset */) -{ - DdNode *subset, *g; - - g = Cudd_Not(f); - memOut = 0; - do { - dd->reordered = 0; - subset = cuddSubsetHeavyBranch(dd, g, numVars, threshold); - } while ((dd->reordered == 1) && (!memOut)); - - return(Cudd_NotCond(subset, (subset != NULL))); - -} /* end of Cudd_SupersetHeavyBranch */ - - -/*---------------------------------------------------------------------------*/ -/* Definition of internal functions */ -/*---------------------------------------------------------------------------*/ - - -/**Function******************************************************************** - - Synopsis [The main procedure that returns a subset by choosing the heavier - branch in the BDD.] - - Description [Here a subset BDD is built by throwing away one of the - children. Starting at root, annotate each node with the number of - minterms (in terms of the total number of variables specified - - numVars), number of nodes taken by the DAG rooted at this node and - number of additional nodes taken by the child that has the lesser - minterms. The child with the lower number of minterms is thrown away - and a dyanmic count of the nodes of the subset is kept. Once the - threshold is reached the subset is returned to the calling - procedure.] - - SideEffects [None] - - SeeAlso [Cudd_SubsetHeavyBranch] - -******************************************************************************/ -DdNode * -cuddSubsetHeavyBranch( - DdManager * dd /* DD manager */, - DdNode * f /* current DD */, - int numVars /* maximum number of variables */, - int threshold /* threshold size for the subset */) -{ - - int i, *size; - st_table *visitedTable; - int numNodes; - NodeData_t *currNodeQual; - DdNode *subset; - st_table *storeTable, *approxTable; - DdNode *key, *value; - st_generator *stGen; - - if (f == NULL) { - fprintf(dd->err, "Cannot subset, nil object\n"); - dd->errorCode = CUDD_INVALID_ARG; - return(NULL); - } - - one = Cudd_ReadOne(dd); - zero = Cudd_Not(one); - - /* If user does not know numVars value, set it to the maximum - * exponent that the pow function can take. The -1 is due to the - * discrepancy in the value that pow takes and the value that - * log gives. - */ - if (numVars == 0) { - /* set default value */ - numVars = DBL_MAX_EXP - 1; - } - - if (Cudd_IsConstant(f)) { - return(f); - } - - max = pow(2.0, (double)numVars); - - /* Create visited table where structures for node data are allocated and - stored in a st_table */ - visitedTable = SubsetCountMinterm(f, numVars); - if ((visitedTable == NULL) || memOut) { - (void) fprintf(dd->err, "Out-of-memory; Cannot subset\n"); - dd->errorCode = CUDD_MEMORY_OUT; - return(0); - } - numNodes = SubsetCountNodes(f, visitedTable, numVars); - if (memOut) { - (void) fprintf(dd->err, "Out-of-memory; Cannot subset\n"); - dd->errorCode = CUDD_MEMORY_OUT; - return(0); - } - - if (st_lookup(visitedTable, f, &currNodeQual) == 0) { - fprintf(dd->err, - "Something is wrong, ought to be node quality table\n"); - dd->errorCode = CUDD_INTERNAL_ERROR; - } - - size = ALLOC(int, 1); - if (size == NULL) { - dd->errorCode = CUDD_MEMORY_OUT; - return(NULL); - } - *size = numNodes; - -#ifdef DEBUG - num_calls = 0; -#endif - /* table to store nodes being created. */ - storeTable = st_init_table(st_ptrcmp, st_ptrhash); - /* insert the constant */ - cuddRef(one); - if (st_insert(storeTable, Cudd_ReadOne(dd), NULL) == - ST_OUT_OF_MEM) { - fprintf(dd->out, "Something wrong, st_table insert failed\n"); - } - /* table to store approximations of nodes */ - approxTable = st_init_table(st_ptrcmp, st_ptrhash); - subset = (DdNode *)BuildSubsetBdd(dd, f, size, visitedTable, threshold, - storeTable, approxTable); - if (subset != NULL) { - cuddRef(subset); - } - - stGen = st_init_gen(approxTable); - if (stGen == NULL) { - st_free_table(approxTable); - return(NULL); - } - while(st_gen(stGen, &key, &value)) { - Cudd_RecursiveDeref(dd, value); - } - st_free_gen(stGen); stGen = NULL; - st_free_table(approxTable); - - stGen = st_init_gen(storeTable); - if (stGen == NULL) { - st_free_table(storeTable); - return(NULL); - } - while(st_gen(stGen, &key, &value)) { - Cudd_RecursiveDeref(dd, key); - } - st_free_gen(stGen); stGen = NULL; - st_free_table(storeTable); - - for (i = 0; i <= page; i++) { - FREE(mintermPages[i]); - } - FREE(mintermPages); - for (i = 0; i <= page; i++) { - FREE(nodePages[i]); - } - FREE(nodePages); - for (i = 0; i <= page; i++) { - FREE(lightNodePages[i]); - } - FREE(lightNodePages); - for (i = 0; i <= nodeDataPage; i++) { - FREE(nodeDataPages[i]); - } - FREE(nodeDataPages); - st_free_table(visitedTable); - FREE(size); -#if 0 - (void) Cudd_DebugCheck(dd); - (void) Cudd_CheckKeys(dd); -#endif - - if (subset != NULL) { -#ifdef DD_DEBUG - if (!Cudd_bddLeq(dd, subset, f)) { - fprintf(dd->err, "Wrong subset\n"); - dd->errorCode = CUDD_INTERNAL_ERROR; - return(NULL); - } -#endif - cuddDeref(subset); - return(subset); - } else { - return(NULL); - } -} /* end of cuddSubsetHeavyBranch */ - - -/*---------------------------------------------------------------------------*/ -/* Definition of static functions */ -/*---------------------------------------------------------------------------*/ - - -/**Function******************************************************************** - - Synopsis [Resize the number of pages allocated to store the node data.] - - Description [Resize the number of pages allocated to store the node data - The procedure moves the counter to the next page when the end of - the page is reached and allocates new pages when necessary.] - - SideEffects [Changes the size of pages, page, page index, maximum - number of pages freeing stuff in case of memory out. ] - - SeeAlso [] - -******************************************************************************/ -static void -ResizeNodeDataPages(void) -{ - int i; - NodeData_t **newNodeDataPages; - - nodeDataPage++; - /* If the current page index is larger than the number of pages - * allocated, allocate a new page array. Page numbers are incremented by - * INITIAL_PAGES - */ - if (nodeDataPage == maxNodeDataPages) { - newNodeDataPages = ALLOC(NodeData_t *,maxNodeDataPages + INITIAL_PAGES); - if (newNodeDataPages == NULL) { - for (i = 0; i < nodeDataPage; i++) FREE(nodeDataPages[i]); - FREE(nodeDataPages); - memOut = 1; - return; - } else { - for (i = 0; i < maxNodeDataPages; i++) { - newNodeDataPages[i] = nodeDataPages[i]; - } - /* Increase total page count */ - maxNodeDataPages += INITIAL_PAGES; - FREE(nodeDataPages); - nodeDataPages = newNodeDataPages; - } - } - /* Allocate a new page */ - currentNodeDataPage = nodeDataPages[nodeDataPage] = - ALLOC(NodeData_t ,nodeDataPageSize); - if (currentNodeDataPage == NULL) { - for (i = 0; i < nodeDataPage; i++) FREE(nodeDataPages[i]); - FREE(nodeDataPages); - memOut = 1; - return; - } - /* reset page index */ - nodeDataPageIndex = 0; - return; - -} /* end of ResizeNodeDataPages */ - - -/**Function******************************************************************** - - Synopsis [Resize the number of pages allocated to store the minterm - counts. ] - - Description [Resize the number of pages allocated to store the minterm - counts. The procedure moves the counter to the next page when the - end of the page is reached and allocates new pages when necessary.] - - SideEffects [Changes the size of minterm pages, page, page index, maximum - number of pages freeing stuff in case of memory out. ] - - SeeAlso [] - -******************************************************************************/ -static void -ResizeCountMintermPages(void) -{ - int i; - double **newMintermPages; - - page++; - /* If the current page index is larger than the number of pages - * allocated, allocate a new page array. Page numbers are incremented by - * INITIAL_PAGES - */ - if (page == maxPages) { - newMintermPages = ALLOC(double *,maxPages + INITIAL_PAGES); - if (newMintermPages == NULL) { - for (i = 0; i < page; i++) FREE(mintermPages[i]); - FREE(mintermPages); - memOut = 1; - return; - } else { - for (i = 0; i < maxPages; i++) { - newMintermPages[i] = mintermPages[i]; - } - /* Increase total page count */ - maxPages += INITIAL_PAGES; - FREE(mintermPages); - mintermPages = newMintermPages; - } - } - /* Allocate a new page */ - currentMintermPage = mintermPages[page] = ALLOC(double,pageSize); - if (currentMintermPage == NULL) { - for (i = 0; i < page; i++) FREE(mintermPages[i]); - FREE(mintermPages); - memOut = 1; - return; - } - /* reset page index */ - pageIndex = 0; - return; - -} /* end of ResizeCountMintermPages */ - - -/**Function******************************************************************** - - Synopsis [Resize the number of pages allocated to store the node counts.] - - Description [Resize the number of pages allocated to store the node counts. - The procedure moves the counter to the next page when the end of - the page is reached and allocates new pages when necessary.] - - SideEffects [Changes the size of pages, page, page index, maximum - number of pages freeing stuff in case of memory out.] - - SeeAlso [] - -******************************************************************************/ -static void -ResizeCountNodePages(void) -{ - int i; - int **newNodePages; - - page++; - - /* If the current page index is larger than the number of pages - * allocated, allocate a new page array. The number of pages is incremented - * by INITIAL_PAGES. - */ - if (page == maxPages) { - newNodePages = ALLOC(int *,maxPages + INITIAL_PAGES); - if (newNodePages == NULL) { - for (i = 0; i < page; i++) FREE(nodePages[i]); - FREE(nodePages); - for (i = 0; i < page; i++) FREE(lightNodePages[i]); - FREE(lightNodePages); - memOut = 1; - return; - } else { - for (i = 0; i < maxPages; i++) { - newNodePages[i] = nodePages[i]; - } - FREE(nodePages); - nodePages = newNodePages; - } - - newNodePages = ALLOC(int *,maxPages + INITIAL_PAGES); - if (newNodePages == NULL) { - for (i = 0; i < page; i++) FREE(nodePages[i]); - FREE(nodePages); - for (i = 0; i < page; i++) FREE(lightNodePages[i]); - FREE(lightNodePages); - memOut = 1; - return; - } else { - for (i = 0; i < maxPages; i++) { - newNodePages[i] = lightNodePages[i]; - } - FREE(lightNodePages); - lightNodePages = newNodePages; - } - /* Increase total page count */ - maxPages += INITIAL_PAGES; - } - /* Allocate a new page */ - currentNodePage = nodePages[page] = ALLOC(int,pageSize); - if (currentNodePage == NULL) { - for (i = 0; i < page; i++) FREE(nodePages[i]); - FREE(nodePages); - for (i = 0; i < page; i++) FREE(lightNodePages[i]); - FREE(lightNodePages); - memOut = 1; - return; - } - /* Allocate a new page */ - currentLightNodePage = lightNodePages[page] = ALLOC(int,pageSize); - if (currentLightNodePage == NULL) { - for (i = 0; i <= page; i++) FREE(nodePages[i]); - FREE(nodePages); - for (i = 0; i < page; i++) FREE(lightNodePages[i]); - FREE(lightNodePages); - memOut = 1; - return; - } - /* reset page index */ - pageIndex = 0; - return; - -} /* end of ResizeCountNodePages */ - - -/**Function******************************************************************** - - Synopsis [Recursively counts minterms of each node in the DAG.] - - Description [Recursively counts minterms of each node in the DAG. - Similar to the cuddCountMintermAux which recursively counts the - number of minterms for the dag rooted at each node in terms of the - total number of variables (max). This procedure creates the node - data structure and stores the minterm count as part of the node - data structure. ] - - SideEffects [Creates structures of type node quality and fills the st_table] - - SeeAlso [SubsetCountMinterm] - -******************************************************************************/ -static double -SubsetCountMintermAux( - DdNode * node /* function to analyze */, - double max /* number of minterms of constant 1 */, - st_table * table /* visitedTable table */) -{ - - DdNode *N,*Nv,*Nnv; /* nodes to store cofactors */ - double min,*pmin; /* minterm count */ - double min1, min2; /* minterm count */ - NodeData_t *dummy; - NodeData_t *newEntry; - int i; - -#ifdef DEBUG - num_calls++; -#endif - - /* Constant case */ - if (Cudd_IsConstant(node)) { - if (node == zero) { - return(0.0); - } else { - return(max); - } - } else { - - /* check if entry for this node exists */ - if (st_lookup(table, node, &dummy)) { - min = *(dummy->mintermPointer); - return(min); - } - - /* Make the node regular to extract cofactors */ - N = Cudd_Regular(node); - - /* store the cofactors */ - Nv = Cudd_T(N); - Nnv = Cudd_E(N); - - Nv = Cudd_NotCond(Nv, Cudd_IsComplement(node)); - Nnv = Cudd_NotCond(Nnv, Cudd_IsComplement(node)); - - min1 = SubsetCountMintermAux(Nv, max,table)/2.0; - if (memOut) return(0.0); - min2 = SubsetCountMintermAux(Nnv,max,table)/2.0; - if (memOut) return(0.0); - min = (min1+min2); - - /* if page index is at the bottom, then create a new page */ - if (pageIndex == pageSize) ResizeCountMintermPages(); - if (memOut) { - for (i = 0; i <= nodeDataPage; i++) FREE(nodeDataPages[i]); - FREE(nodeDataPages); - st_free_table(table); - return(0.0); - } - - /* point to the correct location in the page */ - pmin = currentMintermPage+pageIndex; - pageIndex++; - - /* store the minterm count of this node in the page */ - *pmin = min; - - /* Note I allocate the struct here. Freeing taken care of later */ - if (nodeDataPageIndex == nodeDataPageSize) ResizeNodeDataPages(); - if (memOut) { - for (i = 0; i <= page; i++) FREE(mintermPages[i]); - FREE(mintermPages); - st_free_table(table); - return(0.0); - } - - newEntry = currentNodeDataPage + nodeDataPageIndex; - nodeDataPageIndex++; - - /* points to the correct location in the page */ - newEntry->mintermPointer = pmin; - /* initialize this field of the Node Quality structure */ - newEntry->nodesPointer = NULL; - - /* insert entry for the node in the table */ - if (st_insert(table,node, newEntry) == ST_OUT_OF_MEM) { - memOut = 1; - for (i = 0; i <= page; i++) FREE(mintermPages[i]); - FREE(mintermPages); - for (i = 0; i <= nodeDataPage; i++) FREE(nodeDataPages[i]); - FREE(nodeDataPages); - st_free_table(table); - return(0.0); - } - return(min); - } - -} /* end of SubsetCountMintermAux */ - - -/**Function******************************************************************** - - Synopsis [Counts minterms of each node in the DAG] - - Description [Counts minterms of each node in the DAG. Similar to the - Cudd_CountMinterm procedure except this returns the minterm count for - all the nodes in the bdd in an st_table.] - - SideEffects [none] - - SeeAlso [SubsetCountMintermAux] - -******************************************************************************/ -static st_table * -SubsetCountMinterm( - DdNode * node /* function to be analyzed */, - int nvars /* number of variables node depends on */) -{ - st_table *table; - int i; - - -#ifdef DEBUG - num_calls = 0; -#endif - - max = pow(2.0,(double) nvars); - table = st_init_table(st_ptrcmp,st_ptrhash); - if (table == NULL) goto OUT_OF_MEM; - maxPages = INITIAL_PAGES; - mintermPages = ALLOC(double *,maxPages); - if (mintermPages == NULL) { - st_free_table(table); - goto OUT_OF_MEM; - } - page = 0; - currentMintermPage = ALLOC(double,pageSize); - mintermPages[page] = currentMintermPage; - if (currentMintermPage == NULL) { - FREE(mintermPages); - st_free_table(table); - goto OUT_OF_MEM; - } - pageIndex = 0; - maxNodeDataPages = INITIAL_PAGES; - nodeDataPages = ALLOC(NodeData_t *, maxNodeDataPages); - if (nodeDataPages == NULL) { - for (i = 0; i <= page ; i++) FREE(mintermPages[i]); - FREE(mintermPages); - st_free_table(table); - goto OUT_OF_MEM; - } - nodeDataPage = 0; - currentNodeDataPage = ALLOC(NodeData_t ,nodeDataPageSize); - nodeDataPages[nodeDataPage] = currentNodeDataPage; - if (currentNodeDataPage == NULL) { - for (i = 0; i <= page ; i++) FREE(mintermPages[i]); - FREE(mintermPages); - FREE(nodeDataPages); - st_free_table(table); - goto OUT_OF_MEM; - } - nodeDataPageIndex = 0; - - (void) SubsetCountMintermAux(node,max,table); - if (memOut) goto OUT_OF_MEM; - return(table); - -OUT_OF_MEM: - memOut = 1; - return(NULL); - -} /* end of SubsetCountMinterm */ - - -/**Function******************************************************************** - - Synopsis [Recursively counts the number of nodes under the dag. - Also counts the number of nodes under the lighter child of - this node.] - - Description [Recursively counts the number of nodes under the dag. - Also counts the number of nodes under the lighter child of - this node. . Note that the same dag may be the lighter child of two - different nodes and have different counts. As with the minterm counts, - the node counts are stored in pages to be space efficient and the - address for these node counts are stored in an st_table associated - to each node. ] - - SideEffects [Updates the node data table with node counts] - - SeeAlso [SubsetCountNodes] - -******************************************************************************/ -static int -SubsetCountNodesAux( - DdNode * node /* current node */, - st_table * table /* table to update node count, also serves as visited table. */, - double max /* maximum number of variables */) -{ - int tval, eval, i; - DdNode *N, *Nv, *Nnv; - double minNv, minNnv; - NodeData_t *dummyN, *dummyNv, *dummyNnv, *dummyNBar; - int *pmin, *pminBar, *val; - - if ((node == NULL) || Cudd_IsConstant(node)) - return(0); - - /* if this node has been processed do nothing */ - if (st_lookup(table, node, &dummyN) == 1) { - val = dummyN->nodesPointer; - if (val != NULL) - return(0); - } else { - return(0); - } - - N = Cudd_Regular(node); - Nv = Cudd_T(N); - Nnv = Cudd_E(N); - - Nv = Cudd_NotCond(Nv, Cudd_IsComplement(node)); - Nnv = Cudd_NotCond(Nnv, Cudd_IsComplement(node)); - - /* find the minterm counts for the THEN and ELSE branches */ - if (Cudd_IsConstant(Nv)) { - if (Nv == zero) { - minNv = 0.0; - } else { - minNv = max; - } - } else { - if (st_lookup(table, Nv, &dummyNv) == 1) - minNv = *(dummyNv->mintermPointer); - else { - return(0); - } - } - if (Cudd_IsConstant(Nnv)) { - if (Nnv == zero) { - minNnv = 0.0; - } else { - minNnv = max; - } - } else { - if (st_lookup(table, Nnv, &dummyNnv) == 1) { - minNnv = *(dummyNnv->mintermPointer); - } - else { - return(0); - } - } - - - /* recur based on which has larger minterm, */ - if (minNv >= minNnv) { - tval = SubsetCountNodesAux(Nv, table, max); - if (memOut) return(0); - eval = SubsetCountNodesAux(Nnv, table, max); - if (memOut) return(0); - - /* store the node count of the lighter child. */ - if (pageIndex == pageSize) ResizeCountNodePages(); - if (memOut) { - for (i = 0; i <= page; i++) FREE(mintermPages[i]); - FREE(mintermPages); - for (i = 0; i <= nodeDataPage; i++) FREE(nodeDataPages[i]); - FREE(nodeDataPages); - st_free_table(table); - return(0); - } - pmin = currentLightNodePage + pageIndex; - *pmin = eval; /* Here the ELSE child is lighter */ - dummyN->lightChildNodesPointer = pmin; - - } else { - eval = SubsetCountNodesAux(Nnv, table, max); - if (memOut) return(0); - tval = SubsetCountNodesAux(Nv, table, max); - if (memOut) return(0); - - /* store the node count of the lighter child. */ - if (pageIndex == pageSize) ResizeCountNodePages(); - if (memOut) { - for (i = 0; i <= page; i++) FREE(mintermPages[i]); - FREE(mintermPages); - for (i = 0; i <= nodeDataPage; i++) FREE(nodeDataPages[i]); - FREE(nodeDataPages); - st_free_table(table); - return(0); - } - pmin = currentLightNodePage + pageIndex; - *pmin = tval; /* Here the THEN child is lighter */ - dummyN->lightChildNodesPointer = pmin; - - } - /* updating the page index for node count storage. */ - pmin = currentNodePage + pageIndex; - *pmin = tval + eval + 1; - dummyN->nodesPointer = pmin; - - /* pageIndex is parallel page index for count_nodes and count_lightNodes */ - pageIndex++; - - /* if this node has been reached first, it belongs to a heavier - branch. Its complement will be reached later on a lighter branch. - Hence the complement has zero node count. */ - - if (st_lookup(table, Cudd_Not(node), &dummyNBar) == 1) { - if (pageIndex == pageSize) ResizeCountNodePages(); - if (memOut) { - for (i = 0; i < page; i++) FREE(mintermPages[i]); - FREE(mintermPages); - for (i = 0; i < nodeDataPage; i++) FREE(nodeDataPages[i]); - FREE(nodeDataPages); - st_free_table(table); - return(0); - } - pminBar = currentLightNodePage + pageIndex; - *pminBar = 0; - dummyNBar->lightChildNodesPointer = pminBar; - /* The lighter child has less nodes than the parent. - * So if parent 0 then lighter child zero - */ - if (pageIndex == pageSize) ResizeCountNodePages(); - if (memOut) { - for (i = 0; i < page; i++) FREE(mintermPages[i]); - FREE(mintermPages); - for (i = 0; i < nodeDataPage; i++) FREE(nodeDataPages[i]); - FREE(nodeDataPages); - st_free_table(table); - return(0); - } - pminBar = currentNodePage + pageIndex; - *pminBar = 0; - dummyNBar->nodesPointer = pminBar ; /* maybe should point to zero */ - - pageIndex++; - } - return(*pmin); -} /*end of SubsetCountNodesAux */ - - -/**Function******************************************************************** - - Synopsis [Counts the nodes under the current node and its lighter child] - - Description [Counts the nodes under the current node and its lighter - child. Calls a recursive procedure to count the number of nodes of - a DAG rooted at a particular node and the number of nodes taken by its - lighter child.] - - SideEffects [None] - - SeeAlso [SubsetCountNodesAux] - -******************************************************************************/ -static int -SubsetCountNodes( - DdNode * node /* function to be analyzed */, - st_table * table /* node quality table */, - int nvars /* number of variables node depends on */) -{ - int num; - int i; - -#ifdef DEBUG - num_calls = 0; -#endif - - max = pow(2.0,(double) nvars); - maxPages = INITIAL_PAGES; - nodePages = ALLOC(int *,maxPages); - if (nodePages == NULL) { - goto OUT_OF_MEM; - } - - lightNodePages = ALLOC(int *,maxPages); - if (lightNodePages == NULL) { - for (i = 0; i <= page; i++) FREE(mintermPages[i]); - FREE(mintermPages); - for (i = 0; i <= nodeDataPage; i++) FREE(nodeDataPages[i]); - FREE(nodeDataPages); - FREE(nodePages); - goto OUT_OF_MEM; - } - - page = 0; - currentNodePage = nodePages[page] = ALLOC(int,pageSize); - if (currentNodePage == NULL) { - for (i = 0; i <= page; i++) FREE(mintermPages[i]); - FREE(mintermPages); - for (i = 0; i <= nodeDataPage; i++) FREE(nodeDataPages[i]); - FREE(nodeDataPages); - FREE(lightNodePages); - FREE(nodePages); - goto OUT_OF_MEM; - } - - currentLightNodePage = lightNodePages[page] = ALLOC(int,pageSize); - if (currentLightNodePage == NULL) { - for (i = 0; i <= page; i++) FREE(mintermPages[i]); - FREE(mintermPages); - for (i = 0; i <= nodeDataPage; i++) FREE(nodeDataPages[i]); - FREE(nodeDataPages); - FREE(currentNodePage); - FREE(lightNodePages); - FREE(nodePages); - goto OUT_OF_MEM; - } - - pageIndex = 0; - num = SubsetCountNodesAux(node,table,max); - if (memOut) goto OUT_OF_MEM; - return(num); - -OUT_OF_MEM: - memOut = 1; - return(0); - -} /* end of SubsetCountNodes */ - - -/**Function******************************************************************** - - Synopsis [Procedure to recursively store nodes that are retained in the subset.] - - Description [rocedure to recursively store nodes that are retained in the subset.] - - SideEffects [None] - - SeeAlso [StoreNodes] - -******************************************************************************/ -static void -StoreNodes( - st_table * storeTable, - DdManager * dd, - DdNode * node) -{ - DdNode *N, *Nt, *Ne; - if (Cudd_IsConstant(dd)) { - return; - } - N = Cudd_Regular(node); - if (st_lookup(storeTable, N, NULL)) { - return; - } - cuddRef(N); - if (st_insert(storeTable, N, NULL) == ST_OUT_OF_MEM) { - fprintf(dd->err,"Something wrong, st_table insert failed\n"); - } - - Nt = Cudd_T(N); - Ne = Cudd_E(N); - - StoreNodes(storeTable, dd, Nt); - StoreNodes(storeTable, dd, Ne); - return; - -} - - -/**Function******************************************************************** - - Synopsis [Builds the subset BDD using the heavy branch method.] - - Description [The procedure carries out the building of the subset BDD - starting at the root. Using the three different counts labelling each node, - the procedure chooses the heavier branch starting from the root and keeps - track of the number of nodes it discards at each step, thus keeping count - of the size of the subset BDD dynamically. Once the threshold is satisfied, - the procedure then calls ITE to build the BDD.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -static DdNode * -BuildSubsetBdd( - DdManager * dd /* DD manager */, - DdNode * node /* current node */, - int * size /* current size of the subset */, - st_table * visitedTable /* visited table storing all node data */, - int threshold, - st_table * storeTable, - st_table * approxTable) -{ - - DdNode *Nv, *Nnv, *N, *topv, *neW; - double minNv, minNnv; - NodeData_t *currNodeQual; - NodeData_t *currNodeQualT; - NodeData_t *currNodeQualE; - DdNode *ThenBranch, *ElseBranch; - unsigned int topid; - char *dummy; - -#ifdef DEBUG - num_calls++; -#endif - /*If the size of the subset is below the threshold, dont do - anything. */ - if ((*size) <= threshold) { - /* store nodes below this, so we can recombine if possible */ - StoreNodes(storeTable, dd, node); - return(node); - } - - if (Cudd_IsConstant(node)) - return(node); - - /* Look up minterm count for this node. */ - if (!st_lookup(visitedTable, node, &currNodeQual)) { - fprintf(dd->err, - "Something is wrong, ought to be in node quality table\n"); - } - - /* Get children. */ - N = Cudd_Regular(node); - Nv = Cudd_T(N); - Nnv = Cudd_E(N); - - /* complement if necessary */ - Nv = Cudd_NotCond(Nv, Cudd_IsComplement(node)); - Nnv = Cudd_NotCond(Nnv, Cudd_IsComplement(node)); - - if (!Cudd_IsConstant(Nv)) { - /* find out minterms and nodes contributed by then child */ - if (!st_lookup(visitedTable, Nv, &currNodeQualT)) { - fprintf(dd->out,"Something wrong, couldnt find nodes in node quality table\n"); - dd->errorCode = CUDD_INTERNAL_ERROR; - return(NULL); - } - else { - minNv = *(((NodeData_t *)currNodeQualT)->mintermPointer); - } - } else { - if (Nv == zero) { - minNv = 0; - } else { - minNv = max; - } - } - if (!Cudd_IsConstant(Nnv)) { - /* find out minterms and nodes contributed by else child */ - if (!st_lookup(visitedTable, Nnv, &currNodeQualE)) { - fprintf(dd->out,"Something wrong, couldnt find nodes in node quality table\n"); - dd->errorCode = CUDD_INTERNAL_ERROR; - return(NULL); - } else { - minNnv = *(((NodeData_t *)currNodeQualE)->mintermPointer); - } - } else { - if (Nnv == zero) { - minNnv = 0; - } else { - minNnv = max; - } - } - - /* keep track of size of subset by subtracting the number of - * differential nodes contributed by lighter child - */ - *size = (*(size)) - (int)*(currNodeQual->lightChildNodesPointer); - if (minNv >= minNnv) { /*SubsetCountNodesAux procedure takes - the Then branch in case of a tie */ - - /* recur with the Then branch */ - ThenBranch = (DdNode *)BuildSubsetBdd(dd, Nv, size, - visitedTable, threshold, storeTable, approxTable); - if (ThenBranch == NULL) { - return(NULL); - } - cuddRef(ThenBranch); - /* The Else branch is either a node that already exists in the - * subset, or one whose approximation has been computed, or - * Zero. - */ - if (st_lookup(storeTable, Cudd_Regular(Nnv), &dummy)) { - ElseBranch = Nnv; - cuddRef(ElseBranch); - } else { - if (st_lookup(approxTable, Nnv, &dummy)) { - ElseBranch = (DdNode *)dummy; - cuddRef(ElseBranch); - } else { - ElseBranch = zero; - cuddRef(ElseBranch); - } - } - - } - else { - /* recur with the Else branch */ - ElseBranch = (DdNode *)BuildSubsetBdd(dd, Nnv, size, - visitedTable, threshold, storeTable, approxTable); - if (ElseBranch == NULL) { - return(NULL); - } - cuddRef(ElseBranch); - /* The Then branch is either a node that already exists in the - * subset, or one whose approximation has been computed, or - * Zero. - */ - if (st_lookup(storeTable, Cudd_Regular(Nv), &dummy)) { - ThenBranch = Nv; - cuddRef(ThenBranch); - } else { - if (st_lookup(approxTable, Nv, &dummy)) { - ThenBranch = (DdNode *)dummy; - cuddRef(ThenBranch); - } else { - ThenBranch = zero; - cuddRef(ThenBranch); - } - } - } - - /* construct the Bdd with the top variable and the two children */ - topid = Cudd_NodeReadIndex(N); - topv = Cudd_ReadVars(dd, topid); - cuddRef(topv); - neW = cuddBddIteRecur(dd, topv, ThenBranch, ElseBranch); - if (neW != NULL) { - cuddRef(neW); - } - Cudd_RecursiveDeref(dd, topv); - Cudd_RecursiveDeref(dd, ThenBranch); - Cudd_RecursiveDeref(dd, ElseBranch); - - - if (neW == NULL) - return(NULL); - else { - /* store this node in the store table */ - if (!st_lookup(storeTable, Cudd_Regular(neW), &dummy)) { - cuddRef(neW); - if (st_insert(storeTable, Cudd_Regular(neW), NULL) == - ST_OUT_OF_MEM) - return (NULL); - } - /* store the approximation for this node */ - if (N != Cudd_Regular(neW)) { - if (st_lookup(approxTable, node, &dummy)) { - fprintf(dd->err, "This node should not be in the approximated table\n"); - } else { - cuddRef(neW); - if (st_insert(approxTable, node, neW) == - ST_OUT_OF_MEM) - return(NULL); - } - } - cuddDeref(neW); - return(neW); - } -} /* end of BuildSubsetBdd */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cudd.doc b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cudd.doc deleted file mode 100644 index 7a9169b19..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cudd.doc +++ /dev/null @@ -1,6776 +0,0 @@ -The cudd package - -The University of Colorado decision diagram package. - -Fabio Somenzi - -********************************************************************** - -Cudd_AddHook() Adds a function to a hook. - -Cudd_ApaAdd() Adds two arbitrary precision integers. - -Cudd_ApaCompareRatios() Compares the ratios of two arbitrary precision - integers to two unsigned ints. - -Cudd_ApaCompare() Compares two arbitrary precision integers. - -Cudd_ApaCopy() Makes a copy of an arbitrary precision integer. - -Cudd_ApaCountMinterm() Counts the number of minterms of a DD. - -Cudd_ApaIntDivision() Divides an arbitrary precision integer by an - integer. - -Cudd_ApaNumberOfDigits() Finds the number of digits for an arbitrary - precision integer. - -Cudd_ApaPowerOfTwo() Sets an arbitrary precision integer to a power - of two. - -Cudd_ApaPrintDecimal() Prints an arbitrary precision integer in - decimal format. - -Cudd_ApaPrintDensity() Prints the density of a BDD or ADD using - arbitrary precision arithmetic. - -Cudd_ApaPrintExponential() Prints an arbitrary precision integer in - exponential format. - -Cudd_ApaPrintHex() Prints an arbitrary precision integer in - hexadecimal format. - -Cudd_ApaPrintMintermExp() Prints the number of minterms of a BDD or ADD - in exponential format using arbitrary - precision arithmetic. - -Cudd_ApaPrintMinterm() Prints the number of minterms of a BDD or ADD - using arbitrary precision arithmetic. - -Cudd_ApaSetToLiteral() Sets an arbitrary precision integer to a one- - digit literal. - -Cudd_ApaShiftRight() Shifts right an arbitrary precision integer by - one binary place. - -Cudd_ApaShortDivision() Divides an arbitrary precision integer by a - digit. - -Cudd_ApaSubtract() Subtracts two arbitrary precision integers. - -Cudd_AutodynDisableZdd() Disables automatic dynamic reordering of ZDDs. - -Cudd_AutodynDisable() Disables automatic dynamic reordering. - -Cudd_AutodynEnableZdd() Enables automatic dynamic reordering of ZDDs. - -Cudd_AutodynEnable() Enables automatic dynamic reordering of BDDs - and ADDs. - -Cudd_AverageDistance() Computes the average distance between adjacent - nodes. - -Cudd_BddToAdd() Converts a BDD to a 0-1 ADD. - -Cudd_BddToCubeArray() Builds a positional array from the BDD of a - cube. - -Cudd_BiasedOverApprox() Extracts a dense superset from a BDD with the - biased underapproximation method. - -Cudd_BiasedUnderApprox() Extracts a dense subset from a BDD with the - biased underapproximation method. - -Cudd_CProjection() Computes the compatible projection of R w.r.t. - cube Y. - -Cudd_CheckCube() Checks whether g is the BDD of a cube. - -Cudd_CheckKeys() Checks for several conditions that should not - occur. - -Cudd_CheckZeroRef() Checks the unique table for nodes with non-zero - reference counts. - -Cudd_ClassifySupport() Classifies the variables in the support of two - DDs. - -Cudd_ClearErrorCode() Clear the error code of a manager. - -Cudd_CofMinterm() Computes the fraction of minterms in the on-set - of all the positive cofactors of a BDD or - ADD. - -Cudd_Cofactor() Computes the cofactor of f with respect to g. - -Cudd_CountLeaves() Counts the number of leaves in a DD. - -Cudd_CountMinterm() Counts the number of minterms of a DD. - -Cudd_CountPathsToNonZero() Counts the number of paths to a non-zero - terminal of a DD. - -Cudd_CountPath() Counts the number of paths of a DD. - -Cudd_CubeArrayToBdd() Builds the BDD of a cube from a positional - array. - -Cudd_DagSize() Counts the number of nodes in a DD. - -Cudd_DeadAreCounted() Tells whether dead nodes are counted towards - triggering reordering. - -Cudd_DebugCheck() Checks for inconsistencies in the DD heap. - -Cudd_Decreasing() Determines whether a BDD is negative unate in a - variable. - -Cudd_DelayedDerefBdd() Decreases the reference count of BDD node n. - -Cudd_Density() Computes the density of a BDD or ADD. - -Cudd_Deref() Decreases the reference count of node. - -Cudd_DisableGarbageCollection() - Disables garbage collection. - -Cudd_DisableOrderingMonitoring() - Disables monitoring of ordering. - -Cudd_DisableReorderingReporting() - Disables reporting of reordering stats. - -Cudd_Disequality() Generates a BDD for the function x - y != c. - -Cudd_DumpBlifBody() Writes a blif body representing the argument - BDDs. - -Cudd_DumpBlif() Writes a blif file representing the argument - BDDs. - -Cudd_DumpDDcal() Writes a DDcal file representing the argument - BDDs. - -Cudd_DumpDaVinci() Writes a daVinci file representing the argument - BDDs. - -Cudd_DumpDot() Writes a dot file representing the argument - DDs. - -Cudd_DumpFactoredForm() Writes factored forms representing the argument - BDDs. - -Cudd_Dxygtdxz() Generates a BDD for the function d(x,y) > - d(x,z). - -Cudd_Dxygtdyz() Generates a BDD for the function d(x,y) > - d(y,z). - -Cudd_EnableGarbageCollection() Enables garbage collection. - -Cudd_EnableOrderingMonitoring() - Enables monitoring of ordering. - -Cudd_EnableReorderingReporting() - Enables reporting of reordering stats. - -Cudd_EpdCountMinterm() Counts the number of minterms of a DD with - extended precision. - -Cudd_EqualSupNorm() Compares two ADDs for equality within - tolerance. - -Cudd_EquivDC() Tells whether F and G are identical wherever D - is 0. - -Cudd_EstimateCofactorSimple() Estimates the number of nodes in a cofactor of - a DD. - -Cudd_EstimateCofactor() Estimates the number of nodes in a cofactor of - a DD. - -Cudd_Eval() Returns the value of a DD for a given variable - assignment. - -Cudd_ExpectedUsedSlots() Computes the expected fraction of used slots in - the unique table. - -Cudd_FindEssential() Finds the essential variables of a DD. - -Cudd_FindTwoLiteralClauses() Finds the two literal clauses of a DD. - -Cudd_FirstCube() Finds the first cube of a decision diagram. - -Cudd_FirstNode() Finds the first node of a decision diagram. - -Cudd_FirstPrime() Finds the first prime of a Boolean function. - -Cudd_FreeTree() Frees the variable group tree of the manager. - -Cudd_FreeZddTree() Frees the variable group tree of the manager. - -Cudd_GarbageCollectionEnabled() - Tells whether garbage collection is enabled. - -Cudd_GenFree() Frees a CUDD generator. - -Cudd_IncreaseTimeLimit() Increases the time limit for the manager. - -Cudd_Increasing() Determines whether a BDD is positive unate in a - variable. - -Cudd_IndicesToCube() Builds a cube of BDD variables from an array of - indices. - -Cudd_Inequality() Generates a BDD for the function x - y ≥ c. - -Cudd_Init() Creates a new DD manager. - -Cudd_IsGenEmpty() Queries the status of a generator. - -Cudd_IsInHook() Checks whether a function is in a hook. - -Cudd_IsNonConstant() Returns 1 if a DD node is not constant. - -Cudd_IterDerefBdd() Decreases the reference count of BDD node n. - -Cudd_LargestCube() Finds a largest cube in a DD. - -Cudd_MakeBddFromZddCover() Converts a ZDD cover to a BDD. - -Cudd_MakeTreeNode() Creates a new variable group. - -Cudd_MakeZddTreeNode() Creates a new ZDD variable group. - -Cudd_MinHammingDist() Returns the minimum Hamming distance between f - and minterm. - -Cudd_NewApaNumber() Allocates memory for an arbitrary precision - integer. - -Cudd_NextCube() Generates the next cube of a decision diagram - onset. - -Cudd_NextNode() Finds the next node of a decision diagram. - -Cudd_NextPrime() Generates the next prime of a Boolean function. - -Cudd_NodeReadIndex() Returns the index of the node. - -Cudd_OrderingMonitoring() Returns 1 if monitoring of ordering is enabled. - -Cudd_OutOfMem() Warns that a memory allocation failed. - -Cudd_OverApprox() Extracts a dense superset from a BDD with - Shiple's underapproximation method. - -Cudd_Prime() Returns the next prime >= p. - -Cudd_PrintDebug() Prints to the standard output a DD and its - statistics. - -Cudd_PrintGroupedOrder() Hook function to print the current variable - order. - -Cudd_PrintInfo() Prints out statistics and settings for a CUDD - manager. - -Cudd_PrintLinear() Prints the linear transform matrix. - -Cudd_PrintMinterm() Prints a disjoint sum of products. - -Cudd_PrintTwoLiteralClauses() Prints the two literal clauses of a DD. - -Cudd_PrintVersion() Prints the package version number. - -Cudd_PrioritySelect() Selects pairs from R using a priority function. - -Cudd_Quit() Deletes resources associated with a DD manager. - -Cudd_Random() Portable random number generator. - -Cudd_ReadArcviolation() Returns the current value of the arcviolation - parameter used in group sifting. - -Cudd_ReadBackground() Reads the background constant of the manager. - -Cudd_ReadCacheHits() Returns the number of cache hits. - -Cudd_ReadCacheLookUps() Returns the number of cache look-ups. - -Cudd_ReadCacheSlots() Reads the number of slots in the cache. - -Cudd_ReadCacheUsedSlots() Reads the fraction of used slots in the cache. - -Cudd_ReadDead() Returns the number of dead nodes in the unique - table. - -Cudd_ReadElapsedTime() Returns the time elapsed since the start time - of the manager. - -Cudd_ReadEpsilon() Reads the epsilon parameter of the manager. - -Cudd_ReadErrorCode() Returns the code of the last error. - -Cudd_ReadGarbageCollectionTime() - Returns the time spent in garbage collection. - -Cudd_ReadGarbageCollections() Returns the number of times garbage collection - has occurred. - -Cudd_ReadGroupcheck() Reads the groupcheck parameter of the manager. - -Cudd_ReadInvPermZdd() Returns the index of the ZDD variable currently - in the i-th position of the order. - -Cudd_ReadInvPerm() Returns the index of the variable currently in - the i-th position of the order. - -Cudd_ReadIthClause() Accesses the i-th clause of a DD. - -Cudd_ReadKeys() Returns the number of nodes in the unique - table. - -Cudd_ReadLinear() Reads an entry of the linear transform matrix. - -Cudd_ReadLogicZero() Returns the logic zero constant of the manager. - -Cudd_ReadLooseUpTo() Reads the looseUpTo parameter of the manager. - -Cudd_ReadMaxCacheHard() Reads the maxCacheHard parameter of the - manager. - -Cudd_ReadMaxCache() Returns the soft limit for the cache size. - -Cudd_ReadMaxGrowthAlternate() Reads the maxGrowthAlt parameter of the - manager. - -Cudd_ReadMaxGrowth() Reads the maxGrowth parameter of the manager. - -Cudd_ReadMaxLive() Reads the maximum allowed number of live nodes. - -Cudd_ReadMaxMemory() Reads the maximum allowed memory. - -Cudd_ReadMaxReorderings() Returns the maximum number of times reordering - may be invoked. - -Cudd_ReadMemoryInUse() Returns the memory in use by the manager - measured in bytes. - -Cudd_ReadMinDead() Reads the minDead parameter of the manager. - -Cudd_ReadMinHit() Reads the hit rate that causes resizinig of the - computed table. - -Cudd_ReadMinusInfinity() Reads the minus-infinity constant from the - manager. - -Cudd_ReadNextReordering() Returns the threshold for the next dynamic - reordering. - -Cudd_ReadNodeCount() Reports the number of nodes in BDDs and ADDs. - -Cudd_ReadNodesDropped() Returns the number of nodes dropped. - -Cudd_ReadNodesFreed() Returns the number of nodes freed. - -Cudd_ReadNumberXovers() Reads the current number of crossovers used by - the genetic algorithm for reordering. - -Cudd_ReadOne() Returns the one constant of the manager. - -Cudd_ReadOrderRandomization() Returns the order randomization factor. - -Cudd_ReadPeakLiveNodeCount() Reports the peak number of live nodes. - -Cudd_ReadPeakNodeCount() Reports the peak number of nodes. - -Cudd_ReadPermZdd() Returns the current position of the i-th ZDD - variable in the order. - -Cudd_ReadPerm() Returns the current position of the i-th - variable in the order. - -Cudd_ReadPlusInfinity() Reads the plus-infinity constant from the - manager. - -Cudd_ReadPopulationSize() Reads the current size of the population used - by the genetic algorithm for reordering. - -Cudd_ReadRecomb() Returns the current value of the recombination - parameter used in group sifting. - -Cudd_ReadRecursiveCalls() Returns the number of recursive calls. - -Cudd_ReadReorderingCycle() Reads the reordCycle parameter of the manager. - -Cudd_ReadReorderingTime() Returns the time spent in reordering. - -Cudd_ReadReorderings() Returns the number of times reordering has - occurred. - -Cudd_ReadSiftMaxSwap() Reads the siftMaxSwap parameter of the manager. - -Cudd_ReadSiftMaxVar() Reads the siftMaxVar parameter of the manager. - -Cudd_ReadSize() Returns the number of BDD variables in - existance. - -Cudd_ReadSlots() Returns the total number of slots of the unique - table. - -Cudd_ReadStartTime() Returns the start time of the manager. - -Cudd_ReadStderr() Reads the stderr of a manager. - -Cudd_ReadStdout() Reads the stdout of a manager. - -Cudd_ReadSwapSteps() Reads the number of elementary reordering - steps. - -Cudd_ReadSymmviolation() Returns the current value of the symmviolation - parameter used in group sifting. - -Cudd_ReadTimeLimit() Returns the time limit for the manager. - -Cudd_ReadTree() Returns the variable group tree of the manager. - -Cudd_ReadUniqueLinks() Returns the number of links followed in the - unique table. - -Cudd_ReadUniqueLookUps() Returns the number of look-ups in the unique - table. - -Cudd_ReadUsedSlots() Reads the fraction of used slots in the unique - table. - -Cudd_ReadVars() Returns the i-th element of the vars array. - -Cudd_ReadZddOne() Returns the ZDD for the constant 1 function. - -Cudd_ReadZddSize() Returns the number of ZDD variables in - existance. - -Cudd_ReadZddTree() Returns the variable group tree of the manager. - -Cudd_ReadZero() Returns the zero constant of the manager. - -Cudd_RecursiveDerefZdd() Decreases the reference count of ZDD node n. - -Cudd_RecursiveDeref() Decreases the reference count of node n. - -Cudd_ReduceHeap() Main dynamic reordering routine. - -Cudd_Ref() Increases the reference count of a node, if it - is not saturated. - -Cudd_RemapOverApprox() Extracts a dense superset from a BDD with the - remapping underapproximation method. - -Cudd_RemapUnderApprox() Extracts a dense subset from a BDD with the - remapping underapproximation method. - -Cudd_RemoveHook() Removes a function from a hook. - -Cudd_ReorderingReporting() Returns 1 if reporting of reordering stats is - enabled. - -Cudd_ReorderingStatusZdd() Reports the status of automatic dynamic - reordering of ZDDs. - -Cudd_ReorderingStatus() Reports the status of automatic dynamic - reordering of BDDs and ADDs. - -Cudd_Reserve() Expand manager without creating variables. - -Cudd_ResetStartTime() Resets the start time of the manager. - -Cudd_SetArcviolation() Sets the value of the arcviolation parameter - used in group sifting. - -Cudd_SetBackground() Sets the background constant of the manager. - -Cudd_SetEpsilon() Sets the epsilon parameter of the manager to - ep. - -Cudd_SetGroupcheck() Sets the parameter groupcheck of the manager to - gc. - -Cudd_SetLooseUpTo() Sets the looseUpTo parameter of the manager. - -Cudd_SetMaxCacheHard() Sets the maxCacheHard parameter of the manager. - -Cudd_SetMaxGrowthAlternate() Sets the maxGrowthAlt parameter of the manager. - -Cudd_SetMaxGrowth() Sets the maxGrowth parameter of the manager. - -Cudd_SetMaxLive() Sets the maximum allowed number of live nodes. - -Cudd_SetMaxMemory() Sets the maximum allowed memory. - -Cudd_SetMaxReorderings() Sets the maximum number of times reordering may - be invoked. - -Cudd_SetMinHit() Sets the hit rate that causes resizinig of the - computed table. - -Cudd_SetNextReordering() Sets the threshold for the next dynamic - reordering. - -Cudd_SetNumberXovers() Sets the number of crossovers used by the - genetic algorithm for reordering. - -Cudd_SetOrderRandomization() Sets the order randomization factor. - -Cudd_SetPopulationSize() Sets the size of the population used by the - genetic algorithm for reordering. - -Cudd_SetRecomb() Sets the value of the recombination parameter - used in group sifting. - -Cudd_SetReorderingCycle() Sets the reordCycle parameter of the manager. - -Cudd_SetSiftMaxSwap() Sets the siftMaxSwap parameter of the manager. - -Cudd_SetSiftMaxVar() Sets the siftMaxVar parameter of the manager. - -Cudd_SetStartTime() Sets the start time of the manager. - -Cudd_SetStderr() Sets the stderr of a manager. - -Cudd_SetStdout() Sets the stdout of a manager. - -Cudd_SetSymmviolation() Sets the value of the symmviolation parameter - used in group sifting. - -Cudd_SetTimeLimit() Sets the time limit for the manager. - -Cudd_SetTree() Sets the variable group tree of the manager. - -Cudd_SetVarMap() Registers a variable mapping with the manager. - -Cudd_SetZddTree() Sets the ZDD variable group tree of the - manager. - -Cudd_SharingSize() Counts the number of nodes in an array of DDs. - -Cudd_ShortestLength() Find the length of the shortest path(s) in a - DD. - -Cudd_ShortestPath() Finds a shortest path in a DD. - -Cudd_ShuffleHeap() Reorders variables according to given - permutation. - -Cudd_SolveEqn() Implements the solution of F(x,y) = 0. - -Cudd_SplitSet() Returns m minterms from a BDD. - -Cudd_Srandom() Initializer for the portable random number - generator. - -Cudd_StdPostReordHook() Sample hook function to call after reordering. - -Cudd_StdPreReordHook() Sample hook function to call before reordering. - -Cudd_SubsetCompress() Find a dense subset of BDD f. - -Cudd_SubsetHeavyBranch() Extracts a dense subset from a BDD with the - heavy branch heuristic. - -Cudd_SubsetShortPaths() Extracts a dense subset from a BDD with the - shortest paths heuristic. - -Cudd_SubsetWithMaskVars() Extracts a subset from a BDD. - -Cudd_SupersetCompress() Find a dense superset of BDD f. - -Cudd_SupersetHeavyBranch() Extracts a dense superset from a BDD with the - heavy branch heuristic. - -Cudd_SupersetShortPaths() Extracts a dense superset from a BDD with the - shortest paths heuristic. - -Cudd_SupportIndex() Finds the variables on which a DD depends. - -Cudd_SupportIndices() Finds the variables on which a DD depends. - -Cudd_SupportSize() Counts the variables on which a DD depends. - -Cudd_Support() Finds the variables on which a DD depends. - -Cudd_SymmProfile() Prints statistics on symmetric variables. - -Cudd_TimeLimited() Returns true if the time limit for the manager - is set. - -Cudd_TurnOffCountDead() Causes the dead nodes not to be counted towards - triggering reordering. - -Cudd_TurnOnCountDead() Causes the dead nodes to be counted towards - triggering reordering. - -Cudd_UnderApprox() Extracts a dense subset from a BDD with - Shiple's underapproximation method. - -Cudd_UnsetTimeLimit() Unsets the time limit for the manager. - -Cudd_UpdateTimeLimit() Updates the time limit for the manager. - -Cudd_VectorSupportIndex() Finds the variables on which a set of DDs - depends. - -Cudd_VectorSupportIndices() Finds the variables on which a set of DDs - depends. - -Cudd_VectorSupportSize() Counts the variables on which a set of DDs - depends. - -Cudd_VectorSupport() Finds the variables on which a set of DDs - depends. - -Cudd_VerifySol() Checks the solution of F(x,y) = 0. - -Cudd_Xeqy() Generates a BDD for the function x==y. - -Cudd_Xgty() Generates a BDD for the function x > y. - -Cudd_addAgreement() f if f==g; background if f!=g. - -Cudd_addApply() Applies op to the corresponding discriminants - of f and g. - -Cudd_addBddInterval() Converts an ADD to a BDD. - -Cudd_addBddIthBit() Converts an ADD to a BDD by extracting the i-th - bit from the leaves. - -Cudd_addBddPattern() Converts an ADD to a BDD. - -Cudd_addBddStrictThreshold() Converts an ADD to a BDD. - -Cudd_addBddThreshold() Converts an ADD to a BDD. - -Cudd_addCmpl() Computes the complement of an ADD a la C - language. - -Cudd_addCompose() Substitutes g for x_v in the ADD for f. - -Cudd_addComputeCube() Computes the cube of an array of ADD variables. - -Cudd_addConstrain() Computes f constrain c for ADDs. - -Cudd_addConst() Returns the ADD for constant c. - -Cudd_addDiff() Returns plusinfinity if f=g; returns min(f,g) - if f!=g. - -Cudd_addDivide() Integer and floating point division. - -Cudd_addEvalConst() Checks whether ADD g is constant whenever ADD f - is 1. - -Cudd_addExistAbstract() Existentially Abstracts all the variables in - cube from f. - -Cudd_addFindMax() Finds the maximum discriminant of f. - -Cudd_addFindMin() Finds the minimum discriminant of f. - -Cudd_addGeneralVectorCompose() Composes an ADD with a vector of ADDs. - -Cudd_addHamming() Computes the Hamming distance ADD. - -Cudd_addHarwell() Reads in a matrix in the format of the Harwell- - Boeing benchmark suite. - -Cudd_addIteConstant() Implements ITEconstant for ADDs. - -Cudd_addIte() Implements ITE(f,g,h). - -Cudd_addIthBit() Extracts the i-th bit from an ADD. - -Cudd_addIthVar() Returns the ADD variable with index i. - -Cudd_addLeq() Determines whether f is less than or equal to - g. - -Cudd_addLog() Natural logarithm of an ADD. - -Cudd_addMatrixMultiply() Calculates the product of two matrices - represented as ADDs. - -Cudd_addMaximum() Integer and floating point max. - -Cudd_addMinimum() Integer and floating point min. - -Cudd_addMinus() Integer and floating point subtraction. - -Cudd_addMonadicApply() Applies op to the discriminants of f. - -Cudd_addNand() NAND of two 0-1 ADDs. - -Cudd_addNegate() Computes the additive inverse of an ADD. - -Cudd_addNewVarAtLevel() Returns a new ADD variable at a specified - level. - -Cudd_addNewVar() Returns a new ADD variable. - -Cudd_addNonSimCompose() Composes an ADD with a vector of 0-1 ADDs. - -Cudd_addNor() NOR of two 0-1 ADDs. - -Cudd_addOneZeroMaximum() Returns 1 if f > g and 0 otherwise. - -Cudd_addOrAbstract() Disjunctively abstracts all the variables in - cube from the 0-1 ADD f. - -Cudd_addOr() Disjunction of two 0-1 ADDs. - -Cudd_addOuterSum() Takes the minimum of a matrix and the outer sum - of two vectors. - -Cudd_addPermute() Permutes the variables of an ADD. - -Cudd_addPlus() Integer and floating point addition. - -Cudd_addRead() Reads in a sparse matrix. - -Cudd_addResidue() Builds an ADD for the residue modulo m of an n- - bit number. - -Cudd_addRestrict() ADD restrict according to Coudert and Madre's - algorithm (ICCAD90). - -Cudd_addRoundOff() Rounds off the discriminants of an ADD. - -Cudd_addScalarInverse() Computes the scalar inverse of an ADD. - -Cudd_addSetNZ() This operator sets f to the value of g wherever - g != 0. - -Cudd_addSwapVariables() Swaps two sets of variables of the same size (x - and y) in the ADD f. - -Cudd_addThreshold() f if f>=g; 0 if f<g. - -Cudd_addTimesPlus() Calculates the product of two matrices - represented as ADDs. - -Cudd_addTimes() Integer and floating point multiplication. - -Cudd_addTriangle() Performs the triangulation step for the - shortest path computation. - -Cudd_addUnivAbstract() Universally Abstracts all the variables in cube - from f. - -Cudd_addVectorCompose() Composes an ADD with a vector of 0-1 ADDs. - -Cudd_addWalsh() Generates a Walsh matrix in ADD form. - -Cudd_addXeqy() Generates an ADD for the function x==y. - -Cudd_addXnor() XNOR of two 0-1 ADDs. - -Cudd_addXor() XOR of two 0-1 ADDs. - -Cudd_bddAdjPermuteX() Rearranges a set of variables in the BDD B. - -Cudd_bddAndAbstractLimit() Takes the AND of two BDDs and simultaneously - abstracts the variables in cube. Returns - NULL if too many nodes are required. - -Cudd_bddAndAbstract() Takes the AND of two BDDs and simultaneously - abstracts the variables in cube. - -Cudd_bddAndLimit() Computes the conjunction of two BDDs f and g. - Returns NULL if too many nodes are required. - -Cudd_bddAnd() Computes the conjunction of two BDDs f and g. - -Cudd_bddApproxConjDecomp() Performs two-way conjunctive decomposition of a - BDD. - -Cudd_bddApproxDisjDecomp() Performs two-way disjunctive decomposition of a - BDD. - -Cudd_bddBindVar() Prevents sifting of a variable. - -Cudd_bddBooleanDiff() Computes the boolean difference of f with - respect to x. - -Cudd_bddCharToVect() Computes a vector whose image equals a non-zero - function. - -Cudd_bddClippingAndAbstract() Approximates the conjunction of two BDDs f and - g and simultaneously abstracts the variables - in cube. - -Cudd_bddClippingAnd() Approximates the conjunction of two BDDs f and - g. - -Cudd_bddClosestCube() Finds a cube of f at minimum Hamming distance - from g. - -Cudd_bddCompose() Substitutes g for x_v in the BDD for f. - -Cudd_bddComputeCube() Computes the cube of an array of BDD variables. - -Cudd_bddConstrainDecomp() BDD conjunctive decomposition as in McMillan's - CAV96 paper. - -Cudd_bddConstrain() Computes f constrain c. - -Cudd_bddCorrelationWeights() Computes the correlation of f and g for given - input probabilities. - -Cudd_bddCorrelation() Computes the correlation of f and g. - -Cudd_bddExistAbstractLimit() Existentially abstracts all the variables in - cube from f. - -Cudd_bddExistAbstract() Existentially abstracts all the variables in - cube from f. - -Cudd_bddGenConjDecomp() Performs two-way conjunctive decomposition of a - BDD. - -Cudd_bddGenDisjDecomp() Performs two-way disjunctive decomposition of a - BDD. - -Cudd_bddIntersect() Returns a function included in the intersection - of f and g. - -Cudd_bddInterval() Generates a BDD for the function lowerB ≤ x - ≤ upperB. - -Cudd_bddIsNsVar() Checks whether a variable is next state. - -Cudd_bddIsPiVar() Checks whether a variable is primary input. - -Cudd_bddIsPsVar() Checks whether a variable is present state. - -Cudd_bddIsVarEssential() Determines whether a given variable is - essential with a given phase in a BDD. - -Cudd_bddIsVarHardGroup() Checks whether a variable is set to be in a - hard group. - -Cudd_bddIsVarToBeGrouped() Checks whether a variable is set to be grouped. - -Cudd_bddIsVarToBeUngrouped() Checks whether a variable is set to be - ungrouped. - -Cudd_bddIsop() Computes a BDD in the interval between L and U - with a simple sum-of-product cover. - -Cudd_bddIteConstant() Implements ITEconstant(f,g,h). - -Cudd_bddIteLimit() Implements ITE(f,g,h). Returns NULL if too - many nodes are required. - -Cudd_bddIterConjDecomp() Performs two-way conjunctive decomposition of a - BDD. - -Cudd_bddIterDisjDecomp() Performs two-way disjunctive decomposition of a - BDD. - -Cudd_bddIte() Implements ITE(f,g,h). - -Cudd_bddIthVar() Returns the BDD variable with index i. - -Cudd_bddLICompaction() Performs safe minimization of a BDD. - -Cudd_bddLargestPrimeUnate() Find a largest prime of a unate function. - -Cudd_bddLeqUnless() Tells whether f is less than of equal to G - unless D is 1. - -Cudd_bddLeq() Determines whether f is less than or equal to - g. - -Cudd_bddLiteralSetIntersection() - Computes the intesection of two sets of - literals represented as BDDs. - -Cudd_bddMakePrime() Expands cube to a prime implicant of f. - -Cudd_bddMaximallyExpand() Expands lb to prime implicants of (f and ub). - -Cudd_bddMinimize() Finds a small BDD that agrees with - f over c. - -Cudd_bddNPAnd() Computes f non-polluting-and g. - -Cudd_bddNand() Computes the NAND of two BDDs f and g. - -Cudd_bddNewVarAtLevel() Returns a new BDD variable at a specified - level. - -Cudd_bddNewVar() Returns a new BDD variable. - -Cudd_bddNor() Computes the NOR of two BDDs f and g. - -Cudd_bddOrLimit() Computes the disjunction of two BDDs f and g. - Returns NULL if too many nodes are required. - -Cudd_bddOr() Computes the disjunction of two BDDs f and g. - -Cudd_bddPermute() Permutes the variables of a BDD. - -Cudd_bddPickArbitraryMinterms() - Picks k on-set minterms evenly distributed from - given DD. - -Cudd_bddPickOneCube() Picks one on-set cube randomly from the given - DD. - -Cudd_bddPickOneMinterm() Picks one on-set minterm randomly from the - given DD. - -Cudd_bddPrintCover() Prints a sum of prime implicants of a BDD. - -Cudd_bddReadPairIndex() Reads a corresponding pair index for a given - index. - -Cudd_bddRead() Reads in a graph (without labels) given as a - list of arcs. - -Cudd_bddRealignDisable() Disables realignment of ZDD order to BDD order. - -Cudd_bddRealignEnable() Enables realignment of BDD order to ZDD order. - -Cudd_bddRealignmentEnabled() Tells whether the realignment of BDD order to - ZDD order is enabled. - -Cudd_bddResetVarToBeGrouped() Resets a variable not to be grouped. - -Cudd_bddRestrict() BDD restrict according to Coudert and Madre's - algorithm (ICCAD90). - -Cudd_bddSetNsVar() Sets a variable type to next state. - -Cudd_bddSetPairIndex() Sets a corresponding pair index for a given - index. - -Cudd_bddSetPiVar() Sets a variable type to primary input. - -Cudd_bddSetPsVar() Sets a variable type to present state. - -Cudd_bddSetVarHardGroup() Sets a variable to be a hard group. - -Cudd_bddSetVarToBeGrouped() Sets a variable to be grouped. - -Cudd_bddSetVarToBeUngrouped() Sets a variable to be ungrouped. - -Cudd_bddSqueeze() Finds a small BDD in a function interval. - -Cudd_bddSwapVariables() Swaps two sets of variables of the same size (x - and y) in the BDD f. - -Cudd_bddTransfer() Convert a BDD from a manager to another one. - -Cudd_bddUnbindVar() Allows the sifting of a variable. - -Cudd_bddUnivAbstract() Universally abstracts all the variables in cube - from f. - -Cudd_bddVarConjDecomp() Performs two-way conjunctive decomposition of a - BDD. - -Cudd_bddVarDisjDecomp() Performs two-way disjunctive decomposition of a - BDD. - -Cudd_bddVarIsBound() Tells whether a variable can be sifted. - -Cudd_bddVarIsDependent() Checks whether a variable is dependent on - others in a function. - -Cudd_bddVarMap() Remaps the variables of a BDD using the default - variable map. - -Cudd_bddVectorCompose() Composes a BDD with a vector of BDDs. - -Cudd_bddXnorLimit() Computes the exclusive NOR of two BDDs f and g. - Returns NULL if too many nodes are required. - -Cudd_bddXnor() Computes the exclusive NOR of two BDDs f and g. - -Cudd_bddXorExistAbstract() Takes the exclusive OR of two BDDs and - simultaneously abstracts the variables in - cube. - -Cudd_bddXor() Computes the exclusive OR of two BDDs f and g. - -Cudd_tlcInfoFree() Frees a DdTlcInfo Structure. - -Cudd_zddChange() Substitutes a variable with its complement in a - ZDD. - -Cudd_zddComplement() Computes a complement cover for a ZDD node. - -Cudd_zddCountDouble() Counts the number of minterms of a ZDD. - -Cudd_zddCountMinterm() Counts the number of minterms of a ZDD. - -Cudd_zddCount() Counts the number of minterms in a ZDD. - -Cudd_zddCoverPathToString() Converts a path of a ZDD representing a cover - to a string. - -Cudd_zddDagSize() Counts the number of nodes in a ZDD. - -Cudd_zddDiffConst() Performs the inclusion test for ZDDs (P implies - Q). - -Cudd_zddDiff() Computes the difference of two ZDDs. - -Cudd_zddDivideF() Modified version of Cudd_zddDivide. - -Cudd_zddDivide() Computes the quotient of two unate covers. - -Cudd_zddDumpDot() Writes a dot file representing the argument - ZDDs. - -Cudd_zddFirstPath() Finds the first path of a ZDD. - -Cudd_zddIntersect() Computes the intersection of two ZDDs. - -Cudd_zddIsop() Computes an ISOP in ZDD form from BDDs. - -Cudd_zddIte() Computes the ITE of three ZDDs. - -Cudd_zddIthVar() Returns the ZDD variable with index i. - -Cudd_zddNextPath() Generates the next path of a ZDD. - -Cudd_zddPortFromBdd() Converts a BDD into a ZDD. - -Cudd_zddPortToBdd() Converts a ZDD into a BDD. - -Cudd_zddPrintCover() Prints a sum of products from a ZDD - representing a cover. - -Cudd_zddPrintDebug() Prints to the standard output a ZDD and its - statistics. - -Cudd_zddPrintMinterm() Prints a disjoint sum of product form for a - ZDD. - -Cudd_zddPrintSubtable() Prints the ZDD table. - -Cudd_zddProduct() Computes the product of two covers represented - by ZDDs. - -Cudd_zddReadNodeCount() Reports the number of nodes in ZDDs. - -Cudd_zddRealignDisable() Disables realignment of ZDD order to BDD order. - -Cudd_zddRealignEnable() Enables realignment of ZDD order to BDD order. - -Cudd_zddRealignmentEnabled() Tells whether the realignment of ZDD order to - BDD order is enabled. - -Cudd_zddReduceHeap() Main dynamic reordering routine for ZDDs. - -Cudd_zddShuffleHeap() Reorders ZDD variables according to given - permutation. - -Cudd_zddSubset0() Computes the negative cofactor of a ZDD w.r.t. - a variable. - -Cudd_zddSubset1() Computes the positive cofactor of a ZDD w.r.t. - a variable. - -Cudd_zddSupport() Finds the variables on which a ZDD depends. - -Cudd_zddSymmProfile() Prints statistics on symmetric ZDD variables. - -Cudd_zddUnateProduct() Computes the product of two unate covers. - -Cudd_zddUnion() Computes the union of two ZDDs. - -Cudd_zddVarsFromBddVars() Creates one or more ZDD variables for each BDD - variable. - -Cudd_zddWeakDivF() Modified version of Cudd_zddWeakDiv. - -Cudd_zddWeakDiv() Applies weak division to two covers. - -********************************************************************** - -External functions and data strucures of the CUDD package. To -turn on the gathering of statistics, define DD_STATS. To link with -mis, define DD_MIS. Modified by Abelardo Pardo to interface it to -VIS. - -int -Cudd_AddHook( - DdManager * dd, - DD_HFP f, - Cudd_HookType where -) - Adds a function to a hook. A hook is a list of application-provided - functions called on certain occasions by the package. Returns 1 if the - function is successfully added; 2 if the function was already in the list; 0 - otherwise. - - Side Effects: None - -DdApaDigit -Cudd_ApaAdd( - int digits, - DdApaNumber a, - DdApaNumber b, - DdApaNumber sum -) - Adds two arbitrary precision integers. Returns the carry out of the most - significant digit. - - Side Effects: The result of the sum is stored in parameter sum. - -int -Cudd_ApaCompareRatios( - int digitsFirst, - DdApaNumber firstNum, - unsigned int firstDen, - int digitsSecond, - DdApaNumber secondNum, - unsigned int secondDen -) - Compares the ratios of two arbitrary precision integers to two unsigned - ints. Returns 1 if the first number is larger; 0 if they are equal; -1 if - the second number is larger. - - Side Effects: None - -int -Cudd_ApaCompare( - int digitsFirst, - DdApaNumber first, - int digitsSecond, - DdApaNumber second -) - Compares two arbitrary precision integers. Returns 1 if the first number is - larger; 0 if they are equal; -1 if the second number is larger. - - Side Effects: None - -void -Cudd_ApaCopy( - int digits, - DdApaNumber source, - DdApaNumber dest -) - Makes a copy of an arbitrary precision integer. - - Side Effects: Changes parameter dest. - -DdApaNumber -Cudd_ApaCountMinterm( - DdManager * manager, - DdNode * node, - int nvars, - int * digits -) - Counts the number of minterms of a DD. The function is assumed to depend on - nvars variables. The minterm count is represented as an arbitrary precision - unsigned integer, to allow for any number of variables CUDD supports. - Returns a pointer to the array representing the number of minterms of the - function rooted at node if successful; NULL otherwise. - - Side Effects: The number of digits of the result is returned in parameter - digits. - -unsigned int -Cudd_ApaIntDivision( - int digits, - DdApaNumber dividend, - unsigned int divisor, - DdApaNumber quotient -) - Divides an arbitrary precision integer by a 32-bit unsigned integer. Returns - the remainder of the division. This procedure relies on the assumption that - the number of bits of a DdApaDigit plus the number of bits of an unsigned - int is less the number of bits of the mantissa of a double. This guarantees - that the product of a DdApaDigit and an unsigned int can be represented - without loss of precision by a double. On machines where this assumption is - not satisfied, this procedure will malfunction. - - Side Effects: The quotient is returned in parameter quotient. - -int -Cudd_ApaNumberOfDigits( - int binaryDigits -) - Finds the number of digits for an arbitrary precision integer given the - maximum number of binary digits. The number of binary digits should be - positive. Returns the number of digits if successful; 0 otherwise. - - Side Effects: None - -void -Cudd_ApaPowerOfTwo( - int digits, - DdApaNumber number, - int power -) - Sets an arbitrary precision integer to a power of two. If the power of two - is too large to be represented, the number is set to 0. - - Side Effects: The result is returned in parameter number. - -int -Cudd_ApaPrintDecimal( - FILE * fp, - int digits, - DdApaNumber number -) - Prints an arbitrary precision integer in decimal format. Returns 1 if - successful; 0 otherwise. - - Side Effects: None - -int -Cudd_ApaPrintDensity( - FILE * fp, - DdManager * dd, - DdNode * node, - int nvars -) - Prints the density of a BDD or ADD using arbitrary precision arithmetic. - Returns 1 if successful; 0 otherwise. - - Side Effects: None - -int -Cudd_ApaPrintExponential( - FILE * fp, - int digits, - DdApaNumber number, - int precision -) - Prints an arbitrary precision integer in exponential format. Returns 1 if - successful; 0 otherwise. - - Side Effects: None - -int -Cudd_ApaPrintHex( - FILE * fp, - int digits, - DdApaNumber number -) - Prints an arbitrary precision integer in hexadecimal format. Returns 1 if - successful; 0 otherwise. - - Side Effects: None - -int -Cudd_ApaPrintMintermExp( - FILE * fp, - DdManager * dd, - DdNode * node, - int nvars, - int precision -) - Prints the number of minterms of a BDD or ADD in exponential format using - arbitrary precision arithmetic. Parameter precision controls the number of - signficant digits printed. Returns 1 if successful; 0 otherwise. - - Side Effects: None - -int -Cudd_ApaPrintMinterm( - FILE * fp, - DdManager * dd, - DdNode * node, - int nvars -) - Prints the number of minterms of a BDD or ADD using arbitrary precision - arithmetic. Returns 1 if successful; 0 otherwise. - - Side Effects: None - -void -Cudd_ApaSetToLiteral( - int digits, - DdApaNumber number, - DdApaDigit literal -) - Sets an arbitrary precision integer to a one-digit literal. - - Side Effects: The result is returned in parameter number. - -void -Cudd_ApaShiftRight( - int digits, - DdApaDigit in, - DdApaNumber a, - DdApaNumber b -) - Shifts right an arbitrary precision integer by one binary place. The most - significant binary digit of the result is taken from parameter - in. - - Side Effects: The result is returned in parameter b. - -DdApaDigit -Cudd_ApaShortDivision( - int digits, - DdApaNumber dividend, - DdApaDigit divisor, - DdApaNumber quotient -) - Divides an arbitrary precision integer by a digit. - - Side Effects: The quotient is returned in parameter quotient. - -DdApaDigit -Cudd_ApaSubtract( - int digits, - DdApaNumber a, - DdApaNumber b, - DdApaNumber diff -) - Subtracts two arbitrary precision integers. Returns the borrow out of the - most significant digit. - - Side Effects: The result of the subtraction is stored in parameter - diff. - -void -Cudd_AutodynDisableZdd( - DdManager * unique -) - Disables automatic dynamic reordering of ZDDs. - - Side Effects: None - -void -Cudd_AutodynDisable( - DdManager * unique -) - Disables automatic dynamic reordering. - - Side Effects: None - -void -Cudd_AutodynEnableZdd( - DdManager * unique, - Cudd_ReorderingTy method -) - Enables automatic dynamic reordering of ZDDs. Parameter method is used to - determine the method used for reordering ZDDs. If CUDD_REORDER_SAME is - passed, the method is unchanged. - - Side Effects: None - -void -Cudd_AutodynEnable( - DdManager * unique, - Cudd_ReorderingTy method -) - Enables automatic dynamic reordering of BDDs and ADDs. Parameter method is - used to determine the method used for reordering. If CUDD_REORDER_SAME is - passed, the method is unchanged. - - Side Effects: None - -double -Cudd_AverageDistance( - DdManager * dd -) - Computes the average distance between adjacent nodes in the manager. - Adjacent nodes are node pairs such that the second node is the then child, - else child, or next node in the collision list. - - Side Effects: None - -DdNode * -Cudd_BddToAdd( - DdManager * dd, - DdNode * B -) - Converts a BDD to a 0-1 ADD. Returns a pointer to the resulting ADD if - successful; NULL otherwise. - - Side Effects: None - -int -Cudd_BddToCubeArray( - DdManager * dd, - DdNode * cube, - int * array -) - Builds a positional array from the BDD of a cube. Array must have one entry - for each BDD variable. The positional array has 1 in i-th position if the - variable of index i appears in true form in the cube; it has 0 in i-th - position if the variable of index i appears in complemented form in the - cube; finally, it has 2 in i-th position if the variable of index i does not - appear in the cube. Returns 1 if successful (the BDD is indeed a cube); 0 - otherwise. - - Side Effects: The result is in the array passed by reference. - -DdNode * -Cudd_BiasedOverApprox( - DdManager * dd, manager - DdNode * f, function to be superset - DdNode * b, bias function - int numVars, number of variables in the support of f - int threshold, when to stop approximation - double quality1, minimum improvement for accepted changes - when b=1 - double quality0 minimum improvement for accepted changes - when b=0 -) - Extracts a dense superset from a BDD. The procedure is identical to the - underapproximation procedure except for the fact that it works on the - complement of the given function. Extracting the subset of the complement - function is equivalent to extracting the superset of the function. Returns a - pointer to the BDD of the superset if successful. NULL if intermediate - result causes the procedure to run out of memory. The parameter numVars is - the maximum number of variables to be used in minterm calculation. The - optimal number should be as close as possible to the size of the support of - f. However, it is safe to pass the value returned by Cudd_ReadSize for - numVars when the number of variables is under 1023. If numVars is larger - than 1023, it will overflow. If a 0 parameter is passed then the procedure - will compute a value which will avoid overflow but will cause underflow with - 2046 variables or more. - - Side Effects: None - -DdNode * -Cudd_BiasedUnderApprox( - DdManager * dd, manager - DdNode * f, function to be subset - DdNode * b, bias function - int numVars, number of variables in the support of f - int threshold, when to stop approximation - double quality1, minimum improvement for accepted changes - when b=1 - double quality0 minimum improvement for accepted changes - when b=0 -) - Extracts a dense subset from a BDD. This procedure uses a biased remapping - technique and density as the cost function. The bias is a function. This - procedure tries to approximate where the bias is 0 and preserve the given - function where the bias is 1. Returns a pointer to the BDD of the subset if - successful. NULL if the procedure runs out of memory. The parameter numVars - is the maximum number of variables to be used in minterm calculation. The - optimal number should be as close as possible to the size of the support of - f. However, it is safe to pass the value returned by Cudd_ReadSize for - numVars when the number of variables is under 1023. If numVars is larger - than 1023, it will cause overflow. If a 0 parameter is passed then the - procedure will compute a value which will avoid overflow but will cause - underflow with 2046 variables or more. - - Side Effects: None - -DdNode * -Cudd_CProjection( - DdManager * dd, - DdNode * R, - DdNode * Y -) - Computes the compatible projection of relation R with respect to cube Y. - Returns a pointer to the c-projection if successful; NULL otherwise. For a - comparison between Cudd_CProjection and Cudd_PrioritySelect, see the - documentation of the latter. - - Side Effects: None - -int -Cudd_CheckCube( - DdManager * dd, - DdNode * g -) - Checks whether g is the BDD of a cube. Returns 1 in case of success; 0 - otherwise. The constant 1 is a valid cube, but all other constant functions - cause cuddCheckCube to return 0. - - Side Effects: None - -int -Cudd_CheckKeys( - DdManager * table -) - Checks for the following conditions: Wrong sizes of subtables. - Wrong number of keys found in unique subtable. Wrong number of dead - found in unique subtable. Wrong number of keys found in the constant - table Wrong number of dead found in the constant table Wrong number - of total slots found Wrong number of maximum keys found Wrong number - of total dead found Reports the average length of non-empty lists. - Returns the number of subtables for which the number of keys is wrong. - - Side Effects: None - -int -Cudd_CheckZeroRef( - DdManager * manager -) - Checks the unique table for nodes with non-zero reference counts. It is - normally called before Cudd_Quit to make sure that there are no memory leaks - due to missing Cudd_RecursiveDeref's. Takes into account that reference - counts may saturate and that the basic constants and the projection - functions are referenced by the manager. Returns the number of nodes with - non-zero reference count. (Except for the cases mentioned above.) - - Side Effects: None - -int -Cudd_ClassifySupport( - DdManager * dd, manager - DdNode * f, first DD - DdNode * g, second DD - DdNode ** common, cube of shared variables - DdNode ** onlyF, cube of variables only in f - DdNode ** onlyG cube of variables only in g -) - Classifies the variables in the support of two DDs f and - g, depending on whther they appear in both DDs, only in - f, or only in g. Returns 1 if successful; 0 - otherwise. - - Side Effects: The cubes of the three classes of variables are returned as - side effects. - -void -Cudd_ClearErrorCode( - DdManager * dd -) - Clear the error code of a manager. - - Side Effects: None - -double * -Cudd_CofMinterm( - DdManager * dd, - DdNode * node -) - Computes the fraction of minterms in the on-set of all the positive - cofactors of DD. Returns the pointer to an array of doubles if successful; - NULL otherwise. The array has as many positions as there are BDD variables - in the manager plus one. The last position of the array contains the - fraction of the minterms in the ON-set of the function represented by the - BDD or ADD. The other positions of the array hold the variable signatures. - - Side Effects: None - -DdNode * -Cudd_Cofactor( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes the cofactor of f with respect to g; g must be the BDD or the ADD - of a cube. Returns a pointer to the cofactor if successful; NULL otherwise. - - Side Effects: None - -int -Cudd_CountLeaves( - DdNode * node -) - Counts the number of leaves in a DD. Returns the number of leaves in the DD - rooted at node if successful; CUDD_OUT_OF_MEM otherwise. - - Side Effects: None - -double -Cudd_CountMinterm( - DdManager * manager, - DdNode * node, - int nvars -) - Counts the number of minterms of a DD. The function is assumed to depend on - nvars variables. The minterm count is represented as a double, to allow for - a larger number of variables. Returns the number of minterms of the function - rooted at node if successful; (double) CUDD_OUT_OF_MEM otherwise. - - Side Effects: None - -double -Cudd_CountPathsToNonZero( - DdNode * node -) - Counts the number of paths to a non-zero terminal of a DD. The path count is - represented as a double, to allow for a larger number of variables. Returns - the number of paths of the function rooted at node. - - Side Effects: None - -double -Cudd_CountPath( - DdNode * node -) - Counts the number of paths of a DD. Paths to all terminal nodes are counted. - The path count is represented as a double, to allow for a larger number of - variables. Returns the number of paths of the function rooted at node if - successful; (double) CUDD_OUT_OF_MEM otherwise. - - Side Effects: None - -DdNode * -Cudd_CubeArrayToBdd( - DdManager * dd, - int * array -) - Builds a cube from a positional array. The array must have one integer entry - for each BDD variable. If the i-th entry is 1, the variable of index i - appears in true form in the cube; If the i-th entry is 0, the variable of - index i appears complemented in the cube; otherwise the variable does not - appear in the cube. Returns a pointer to the BDD for the cube if successful; - NULL otherwise. - - Side Effects: None - -int -Cudd_DagSize( - DdNode * node -) - Counts the number of nodes in a DD. Returns the number of nodes in the graph - rooted at node. - - Side Effects: None - -int -Cudd_DeadAreCounted( - DdManager * dd -) - Tells whether dead nodes are counted towards triggering reordering. Returns - 1 if dead nodes are counted; 0 otherwise. - - Side Effects: None - -int -Cudd_DebugCheck( - DdManager * table -) - Checks for inconsistencies in the DD heap: node has illegal index - live node has dead children node has illegal Then or Else pointers - BDD/ADD node has identical children ZDD node has zero then child - wrong number of total nodes wrong number of dead nodes ref - count error at node Returns 0 if no inconsistencies are found; - DD_OUT_OF_MEM if there is not enough memory; 1 otherwise. - - Side Effects: None - -DdNode * -Cudd_Decreasing( - DdManager * dd, - DdNode * f, - int i -) - Determines whether the function represented by BDD f is negative unate - (monotonic decreasing) in variable i. Returns the constant one is f is unate - and the (logical) constant zero if it is not. This function does not - generate any new nodes. - - Side Effects: None - -void -Cudd_DelayedDerefBdd( - DdManager * table, - DdNode * n -) - Enqueues node n for later dereferencing. If the queue is full decreases the - reference count of the oldest node N to make room for n. If N dies, - recursively decreases the reference counts of its children. It is used to - dispose of a BDD that is currently not needed, but may be useful again in - the near future. The dereferencing proper is done as in Cudd_IterDerefBdd. - - Side Effects: None - -double -Cudd_Density( - DdManager * dd, manager - DdNode * f, function whose density is sought - int nvars size of the support of f -) - Computes the density of a BDD or ADD. The density is the ratio of the number - of minterms to the number of nodes. If 0 is passed as number of variables, - the number of variables existing in the manager is used. Returns the density - if successful; (double) CUDD_OUT_OF_MEM otherwise. - - Side Effects: None - -void -Cudd_Deref( - DdNode * node -) - Decreases the reference count of node. It is primarily used in recursive - procedures to decrease the ref count of a result node before returning it. - This accomplishes the goal of removing the protection applied by a previous - Cudd_Ref. - - Side Effects: None - -void -Cudd_DisableGarbageCollection( - DdManager * dd -) - Disables garbage collection. Garbage collection is initially enabled. This - function may be called to disable it. However, garbage collection will still - occur when a new node must be created and no memory is left, or when garbage - collection is required for correctness. (E.g., before reordering.) - - Side Effects: None - -int -Cudd_DisableOrderingMonitoring( - DdManager * dd -) - Disables monitoring of ordering. Returns 1 if successful; 0 otherwise. - - Side Effects: Removes functions from the pre-reordering and post-reordering - hooks. - -int -Cudd_DisableReorderingReporting( - DdManager * dd -) - Disables reporting of reordering stats. Returns 1 if successful; 0 - otherwise. - - Side Effects: Removes functions from the pre-reordering and post-reordering - hooks. - -DdNode * -Cudd_Disequality( - DdManager * dd, DD manager - int N, number of x and y variables - int c, right-hand side constant - DdNode ** x, array of x variables - DdNode ** y array of y variables -) - This function generates a BDD for the function x -y != c. Both x and y are - N-bit numbers, x[0] x[1] ... x[N-1] and y[0] y[1] ... y[N-1], with 0 the - most significant bit. The BDD is built bottom-up. It has a linear number of - nodes if the variables are ordered as follows: x[0] y[0] x[1] y[1] ... x[N- - 1] y[N-1]. - - Side Effects: None - -int -Cudd_DumpBlifBody( - DdManager * dd, manager - int n, number of output nodes to be dumped - DdNode ** f, array of output nodes to be dumped - char ** inames, array of input names (or NULL) - char ** onames, array of output names (or NULL) - FILE * fp, pointer to the dump file - int mv 0: blif, 1: blif-MV -) - Writes a blif body representing the argument BDDs as a network of - multiplexers. No header (.model, .inputs, and .outputs) and footer (.end) - are produced by this function. One multiplexer is written for each BDD node. - It returns 1 in case of success; 0 otherwise (e.g., out-of-memory, file - system full, or an ADD with constants different from 0 and 1). - Cudd_DumpBlifBody does not close the file: This is the caller - responsibility. Cudd_DumpBlifBody uses a minimal unique subset of the - hexadecimal address of a node as name for it. If the argument inames is non- - null, it is assumed to hold the pointers to the names of the inputs. - Similarly for onames. This function prints out only .names part. - - Side Effects: None - -int -Cudd_DumpBlif( - DdManager * dd, manager - int n, number of output nodes to be dumped - DdNode ** f, array of output nodes to be dumped - char ** inames, array of input names (or NULL) - char ** onames, array of output names (or NULL) - char * mname, model name (or NULL) - FILE * fp, pointer to the dump file - int mv 0: blif, 1: blif-MV -) - Writes a blif file representing the argument BDDs as a network of - multiplexers. One multiplexer is written for each BDD node. It returns 1 in - case of success; 0 otherwise (e.g., out-of-memory, file system full, or an - ADD with constants different from 0 and 1). Cudd_DumpBlif does not close the - file: This is the caller responsibility. Cudd_DumpBlif uses a minimal unique - subset of the hexadecimal address of a node as name for it. If the argument - inames is non-null, it is assumed to hold the pointers to the names of the - inputs. Similarly for onames. - - Side Effects: None - -int -Cudd_DumpDDcal( - DdManager * dd, manager - int n, number of output nodes to be dumped - DdNode ** f, array of output nodes to be dumped - char ** inames, array of input names (or NULL) - char ** onames, array of output names (or NULL) - FILE * fp pointer to the dump file -) - Writes a DDcal file representing the argument BDDs. It returns 1 in case of - success; 0 otherwise (e.g., out-of-memory or file system full). - Cudd_DumpDDcal does not close the file: This is the caller responsibility. - Cudd_DumpDDcal uses a minimal unique subset of the hexadecimal address of a - node as name for it. If the argument inames is non-null, it is assumed to - hold the pointers to the names of the inputs. Similarly for onames. - - Side Effects: None - -int -Cudd_DumpDaVinci( - DdManager * dd, manager - int n, number of output nodes to be dumped - DdNode ** f, array of output nodes to be dumped - char ** inames, array of input names (or NULL) - char ** onames, array of output names (or NULL) - FILE * fp pointer to the dump file -) - Writes a daVinci file representing the argument BDDs. It returns 1 in case - of success; 0 otherwise (e.g., out-of-memory or file system full). - Cudd_DumpDaVinci does not close the file: This is the caller responsibility. - Cudd_DumpDaVinci uses a minimal unique subset of the hexadecimal address of - a node as name for it. If the argument inames is non-null, it is assumed to - hold the pointers to the names of the inputs. Similarly for onames. - - Side Effects: None - -int -Cudd_DumpDot( - DdManager * dd, manager - int n, number of output nodes to be dumped - DdNode ** f, array of output nodes to be dumped - char ** inames, array of input names (or NULL) - char ** onames, array of output names (or NULL) - FILE * fp pointer to the dump file -) - Writes a file representing the argument DDs in a format suitable for the - graph drawing program dot. It returns 1 in case of success; 0 otherwise - (e.g., out-of-memory, file system full). Cudd_DumpDot does not close the - file: This is the caller responsibility. Cudd_DumpDot uses a minimal unique - subset of the hexadecimal address of a node as name for it. If the argument - inames is non-null, it is assumed to hold the pointers to the names of the - inputs. Similarly for onames. Cudd_DumpDot uses the following convention to - draw arcs: solid line: THEN arcs; dotted line: complement - arcs; dashed line: regular ELSE arcs. The dot options are chosen - so that the drawing fits on a letter-size sheet. - - Side Effects: None - -int -Cudd_DumpFactoredForm( - DdManager * dd, manager - int n, number of output nodes to be dumped - DdNode ** f, array of output nodes to be dumped - char ** inames, array of input names (or NULL) - char ** onames, array of output names (or NULL) - FILE * fp pointer to the dump file -) - Writes factored forms representing the argument BDDs. The format of the - factored form is the one used in the genlib files for technology mapping in - sis. It returns 1 in case of success; 0 otherwise (e.g., file system full). - Cudd_DumpFactoredForm does not close the file: This is the caller - responsibility. Caution must be exercised because a factored form may be - exponentially larger than the argument BDD. If the argument inames is non- - null, it is assumed to hold the pointers to the names of the inputs. - Similarly for onames. - - Side Effects: None - -DdNode * -Cudd_Dxygtdxz( - DdManager * dd, DD manager - int N, number of x, y, and z variables - DdNode ** x, array of x variables - DdNode ** y, array of y variables - DdNode ** z array of z variables -) - This function generates a BDD for the function d(x,y) > d(x,z); x, y, and - z are N-bit numbers, x[0] x[1] ... x[N-1], y[0] y[1] ... y[N-1], and z[0] - z[1] ... z[N-1], with 0 the most significant bit. The distance d(x,y) is - defined as: sum_{i=0}^{N-1}(|x_i - y_i| cdot 2^{N-i-1}). The BDD is built - bottom-up. It has 7*N-3 internal nodes, if the variables are ordered as - follows: x[0] y[0] z[0] x[1] y[1] z[1] ... x[N-1] y[N-1] z[N-1]. - - Side Effects: None - -DdNode * -Cudd_Dxygtdyz( - DdManager * dd, DD manager - int N, number of x, y, and z variables - DdNode ** x, array of x variables - DdNode ** y, array of y variables - DdNode ** z array of z variables -) - This function generates a BDD for the function d(x,y) > d(y,z); x, y, and - z are N-bit numbers, x[0] x[1] ... x[N-1], y[0] y[1] ... y[N-1], and z[0] - z[1] ... z[N-1], with 0 the most significant bit. The distance d(x,y) is - defined as: sum_{i=0}^{N-1}(|x_i - y_i| cdot 2^{N-i-1}). The BDD is built - bottom-up. It has 7*N-3 internal nodes, if the variables are ordered as - follows: x[0] y[0] z[0] x[1] y[1] z[1] ... x[N-1] y[N-1] z[N-1]. - - Side Effects: None - -void -Cudd_EnableGarbageCollection( - DdManager * dd -) - Enables garbage collection. Garbage collection is initially enabled. - Therefore it is necessary to call this function only if garbage collection - has been explicitly disabled. - - Side Effects: None - -int -Cudd_EnableOrderingMonitoring( - DdManager * dd -) - Enables monitoring of ordering. Returns 1 if successful; 0 otherwise. - - Side Effects: Installs functions in the pre-reordering and post-reordering - hooks. - -int -Cudd_EnableReorderingReporting( - DdManager * dd -) - Enables reporting of reordering stats. Returns 1 if successful; 0 otherwise. - - Side Effects: Installs functions in the pre-reordering and post-reordering - hooks. - -int -Cudd_EpdCountMinterm( - DdManager * manager, - DdNode * node, - int nvars, - EpDouble * epd -) - Counts the number of minterms of a DD with extended precision. The function - is assumed to depend on nvars variables. The minterm count is represented as - an EpDouble, to allow any number of variables. Returns 0 if successful; - CUDD_OUT_OF_MEM otherwise. - - Side Effects: None - -int -Cudd_EqualSupNorm( - DdManager * dd, manager - DdNode * f, first ADD - DdNode * g, second ADD - CUDD_VALUE_TYPE tolerance, maximum allowed difference - int pr verbosity level -) - Compares two ADDs for equality within tolerance. Two ADDs are reported to be - equal if the maximum difference between them (the sup norm of their - difference) is less than or equal to the tolerance parameter. Returns 1 if - the two ADDs are equal (within tolerance); 0 otherwise. If parameter - pr is positive the first failure is reported to the standard - output. - - Side Effects: None - -int -Cudd_EquivDC( - DdManager * dd, - DdNode * F, - DdNode * G, - DdNode * D -) - Tells whether F and G are identical wherever D is 0. F and G are either two - ADDs or two BDDs. D is either a 0-1 ADD or a BDD. The function returns 1 if - F and G are equivalent, and 0 otherwise. No new nodes are created. - - Side Effects: None - -int -Cudd_EstimateCofactorSimple( - DdNode * node, - int i -) - Estimates the number of nodes in a cofactor of a DD. Returns an estimate of - the number of nodes in the positive cofactor of the graph rooted at node - with respect to the variable whose index is i. This procedure implements - with minor changes the algorithm of Cabodi et al. (ICCAD96). It does not - allocate any memory, it does not change the state of the manager, and it is - fast. However, it has been observed to overestimate the size of the cofactor - by as much as a factor of 2. - - Side Effects: None - -int -Cudd_EstimateCofactor( - DdManager * dd, manager - DdNode * f, function - int i, index of variable - int phase 1: positive; 0: negative -) - Estimates the number of nodes in a cofactor of a DD. Returns an estimate of - the number of nodes in a cofactor of the graph rooted at node with respect - to the variable whose index is i. In case of failure, returns - CUDD_OUT_OF_MEM. This function uses a refinement of the algorithm of Cabodi - et al. (ICCAD96). The refinement allows the procedure to account for part of - the recombination that may occur in the part of the cofactor above the - cofactoring variable. This procedure does not create any new node. It does - keep a small table of results; therefore it may run out of memory. If this - is a concern, one should use Cudd_EstimateCofactorSimple, which is faster, - does not allocate any memory, but is less accurate. - - Side Effects: None - -DdNode * -Cudd_Eval( - DdManager * dd, - DdNode * f, - int * inputs -) - Finds the value of a DD for a given variable assignment. The variable - assignment is passed in an array of int's, that should specify a zero or a - one for each variable in the support of the function. Returns a pointer to a - constant node. No new nodes are produced. - - Side Effects: None - -double -Cudd_ExpectedUsedSlots( - DdManager * dd -) - Computes the fraction of slots in the unique table that should be in use. - This expected value is based on the assumption that the hash function - distributes the keys randomly; it can be compared with the result of - Cudd_ReadUsedSlots to monitor the performance of the unique table hash - function. - - Side Effects: None - -DdNode * -Cudd_FindEssential( - DdManager * dd, - DdNode * f -) - Returns the cube of the essential variables. A positive literal means that - the variable must be set to 1 for the function to be 1. A negative literal - means that the variable must be set to 0 for the function to be 1. Returns a - pointer to the cube BDD if successful; NULL otherwise. - - Side Effects: None - -DdTlcInfo * -Cudd_FindTwoLiteralClauses( - DdManager * dd, - DdNode * f -) - Returns the one- and two-literal clauses of a DD. Returns a pointer to the - structure holding the clauses if successful; NULL otherwise. For a constant - DD, the empty set of clauses is returned. This is obviously correct for a - non-zero constant. For the constant zero, it is based on the assumption that - only those clauses containing variables in the support of the function are - considered. Since the support of a constant function is empty, no clauses - are returned. - - Side Effects: None - -DdGen * -Cudd_FirstCube( - DdManager * dd, - DdNode * f, - int ** cube, - CUDD_VALUE_TYPE * value -) - Defines an iterator on the onset of a decision diagram and finds its first - cube. Returns a generator that contains the information necessary to - continue the enumeration if successful; NULL otherwise. A cube is - represented as an array of literals, which are integers in {0, 1, 2}; 0 - represents a complemented literal, 1 represents an uncomplemented literal, - and 2 stands for don't care. The enumeration produces a disjoint cover of - the function associated with the diagram. The size of the array equals the - number of variables in the manager at the time Cudd_FirstCube is called. - For each cube, a value is also returned. This value is always 1 for a BDD, - while it may be different from 1 for an ADD. For BDDs, the offset is the set - of cubes whose value is the logical zero. For ADDs, the offset is the set of - cubes whose value is the background value. The cubes of the offset are not - enumerated. - - Side Effects: The first cube and its value are returned as side effects. - -DdGen * -Cudd_FirstNode( - DdManager * dd, - DdNode * f, - DdNode ** node -) - Defines an iterator on the nodes of a decision diagram and finds its first - node. Returns a generator that contains the information necessary to - continue the enumeration if successful; NULL otherwise. The nodes are - enumerated in a reverse topological order, so that a node is always preceded - in the enumeration by its descendants. - - Side Effects: The first node is returned as a side effect. - -DdGen * -Cudd_FirstPrime( - DdManager * dd, - DdNode * l, - DdNode * u, - int ** cube -) - Defines an iterator on a pair of BDDs describing a (possibly incompletely - specified) Boolean functions and finds the first cube of a cover of the - function. Returns a generator that contains the information necessary to - continue the enumeration if successful; NULL otherwise. The two argument - BDDs are the lower and upper bounds of an interval. It is a mistake to call - this function with a lower bound that is not less than or equal to the upper - bound. A cube is represented as an array of literals, which are integers - in {0, 1, 2}; 0 represents a complemented literal, 1 represents an - uncomplemented literal, and 2 stands for don't care. The enumeration - produces a prime and irredundant cover of the function associated with the - two BDDs. The size of the array equals the number of variables in the - manager at the time Cudd_FirstCube is called. This iterator can only be - used on BDDs. - - Side Effects: The first cube is returned as side effect. - -void -Cudd_FreeTree( - DdManager * dd -) - Frees the variable group tree of the manager. - - Side Effects: None - -void -Cudd_FreeZddTree( - DdManager * dd -) - Frees the variable group tree of the manager. - - Side Effects: None - -int -Cudd_GarbageCollectionEnabled( - DdManager * dd -) - Returns 1 if garbage collection is enabled; 0 otherwise. - - Side Effects: None - -int -Cudd_GenFree( - DdGen * gen -) - Frees a CUDD generator. Always returns 0, so that it can be used in mis-like - foreach constructs. - - Side Effects: None - -void -Cudd_IncreaseTimeLimit( - DdManager * unique, - unsigned long increase -) - Increases the time limit for the manager. - - Side Effects: None - -DdNode * -Cudd_Increasing( - DdManager * dd, - DdNode * f, - int i -) - Determines whether the function represented by BDD f is positive unate - (monotonic increasing) in variable i. It is based on Cudd_Decreasing and the - fact that f is monotonic increasing in i if and only if its complement is - monotonic decreasing in i. - - Side Effects: None - -DdNode * -Cudd_IndicesToCube( - DdManager * dd, - int * array, - int n -) - Builds a cube of BDD variables from an array of indices. Returns a pointer - to the result if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_Inequality( - DdManager * dd, DD manager - int N, number of x and y variables - int c, right-hand side constant - DdNode ** x, array of x variables - DdNode ** y array of y variables -) - This function generates a BDD for the function x -y ≥ c. Both x and y are - N-bit numbers, x[0] x[1] ... x[N-1] and y[0] y[1] ... y[N-1], with 0 the - most significant bit. The BDD is built bottom-up. It has a linear number of - nodes if the variables are ordered as follows: x[0] y[0] x[1] y[1] ... x[N- - 1] y[N-1]. - - Side Effects: None - -DdManager * -Cudd_Init( - unsigned int numVars, initial number of BDD variables (i.e., - subtables) - unsigned int numVarsZ, initial number of ZDD variables (i.e., - subtables) - unsigned int numSlots, initial size of the unique tables - unsigned int cacheSize, initial size of the cache - unsigned long maxMemory target maximum memory occupation -) - Creates a new DD manager, initializes the table, the basic constants and the - projection functions. If maxMemory is 0, Cudd_Init decides suitable values - for the maximum size of the cache and for the limit for fast unique table - growth based on the available memory. Returns a pointer to the manager if - successful; NULL otherwise. - - Side Effects: None - -int -Cudd_IsGenEmpty( - DdGen * gen -) - Queries the status of a generator. Returns 1 if the generator is empty or - NULL; 0 otherswise. - - Side Effects: None - -int -Cudd_IsInHook( - DdManager * dd, - DD_HFP f, - Cudd_HookType where -) - Checks whether a function is in a hook. A hook is a list of application- - provided functions called on certain occasions by the package. Returns 1 if - the function is found; 0 otherwise. - - Side Effects: None - -int -Cudd_IsNonConstant( - DdNode * f -) - Returns 1 if a DD node is not constant. This function is useful to test the - results of Cudd_bddIteConstant, Cudd_addIteConstant, Cudd_addEvalConst. - These results may be a special value signifying non-constant. In the other - cases the macro Cudd_IsConstant can be used. - - Side Effects: None - -void -Cudd_IterDerefBdd( - DdManager * table, - DdNode * n -) - Decreases the reference count of node n. If n dies, recursively decreases - the reference counts of its children. It is used to dispose of a BDD that is - no longer needed. It is more efficient than Cudd_RecursiveDeref, but it - cannot be used on ADDs. The greater efficiency comes from being able to - assume that no constant node will ever die as a result of a call to this - procedure. - - Side Effects: None - -DdNode * -Cudd_LargestCube( - DdManager * manager, - DdNode * f, - int * length -) - Finds a largest cube in a DD. f is the DD we want to get the largest cube - for. The problem is translated into the one of finding a shortest path in f, - when both THEN and ELSE arcs are assumed to have unit length. This yields a - largest cube in the disjoint cover corresponding to the DD. Therefore, it is - not necessarily the largest implicant of f. Returns the largest cube as a - BDD. - - Side Effects: The number of literals of the cube is returned in the location - pointed by length if it is non-null. - -DdNode * -Cudd_MakeBddFromZddCover( - DdManager * dd, - DdNode * node -) - Converts a ZDD cover to a BDD for the function represented by the cover. If - successful, it returns a BDD node, otherwise it returns NULL. - - -MtrNode * -Cudd_MakeTreeNode( - DdManager * dd, manager - unsigned int low, index of the first group variable - unsigned int size, number of variables in the group - unsigned int type MTR_DEFAULT or MTR_FIXED -) - Creates a new variable group. The group starts at variable low and contains - size variables. The parameter low is the index of the first variable. If the - variable already exists, its current position in the order is known to the - manager. If the variable does not exist yet, the position is assumed to be - the same as the index. The group tree is created if it does not exist yet. - Returns a pointer to the group if successful; NULL otherwise. - - Side Effects: The variable tree is changed. - -MtrNode * -Cudd_MakeZddTreeNode( - DdManager * dd, manager - unsigned int low, index of the first group variable - unsigned int size, number of variables in the group - unsigned int type MTR_DEFAULT or MTR_FIXED -) - Creates a new ZDD variable group. The group starts at variable and contains - size variables. The parameter low is the index of the first variable. If the - variable already exists, its current position in the order is known to the - manager. If the variable does not exist yet, the position is assumed to be - the same as the index. The group tree is created if it does not exist yet. - Returns a pointer to the group if successful; NULL otherwise. - - Side Effects: The ZDD variable tree is changed. - -int -Cudd_MinHammingDist( - DdManager * dd, DD manager - DdNode * f, function to examine - int * minterm, reference minterm - int upperBound distance above which an approximate - answer is OK -) - Returns the minimum Hamming distance between the minterms of a function f - and a reference minterm. The function is given as a BDD; the minterm is - given as an array of integers, one for each variable in the manager. Returns - the minimum distance if it is less than the upper bound; the upper bound if - the minimum distance is at least as large; CUDD_OUT_OF_MEM in case of - failure. - - Side Effects: None - -DdApaNumber -Cudd_NewApaNumber( - int digits -) - Allocates memory for an arbitrary precision integer. Returns a pointer to - the allocated memory if successful; NULL otherwise. - - Side Effects: None - -int -Cudd_NextCube( - DdGen * gen, - int ** cube, - CUDD_VALUE_TYPE * value -) - Generates the next cube of a decision diagram onset, using generator gen. - Returns 0 if the enumeration is completed; 1 otherwise. - - Side Effects: The cube and its value are returned as side effects. The - generator is modified. - -int -Cudd_NextNode( - DdGen * gen, - DdNode ** node -) - Finds the node of a decision diagram, using generator gen. Returns 0 if the - enumeration is completed; 1 otherwise. - - Side Effects: The next node is returned as a side effect. - -int -Cudd_NextPrime( - DdGen * gen, - int ** cube -) - Generates the next cube of a Boolean function, using generator gen. Returns - 0 if the enumeration is completed; 1 otherwise. - - Side Effects: The cube and is returned as side effects. The generator is - modified. - -unsigned int -Cudd_NodeReadIndex( - DdNode * node -) - Returns the index of the node. The node pointer can be either regular or - complemented. - - Side Effects: None - -int -Cudd_OrderingMonitoring( - DdManager * dd -) - Returns 1 if monitoring of ordering is enabled; 0 otherwise. - - Side Effects: none - -void -Cudd_OutOfMem( - long size size of the allocation that failed -) - Warns that a memory allocation failed. This function can be used as - replacement of MMout_of_memory to prevent the safe_mem functions of the util - package from exiting when malloc returns NULL. One possible use is in case - of discretionary allocations; for instance, the allocation of memory to - enlarge the computed table. - - Side Effects: None - -DdNode * -Cudd_OverApprox( - DdManager * dd, manager - DdNode * f, function to be superset - int numVars, number of variables in the support of f - int threshold, when to stop approximation - int safe, enforce safe approximation - double quality minimum improvement for accepted changes -) - Extracts a dense superset from a BDD. The procedure is identical to the - underapproximation procedure except for the fact that it works on the - complement of the given function. Extracting the subset of the complement - function is equivalent to extracting the superset of the function. Returns a - pointer to the BDD of the superset if successful. NULL if intermediate - result causes the procedure to run out of memory. The parameter numVars is - the maximum number of variables to be used in minterm calculation. The - optimal number should be as close as possible to the size of the support of - f. However, it is safe to pass the value returned by Cudd_ReadSize for - numVars when the number of variables is under 1023. If numVars is larger - than 1023, it will overflow. If a 0 parameter is passed then the procedure - will compute a value which will avoid overflow but will cause underflow with - 2046 variables or more. - - Side Effects: None - -unsigned int -Cudd_Prime( - unsigned int p -) - Returns the next prime >= p. - - Side Effects: None - -int -Cudd_PrintDebug( - DdManager * dd, - DdNode * f, - int n, - int pr -) - Prints to the standard output a DD and its statistics. The statistics - include the number of nodes, the number of leaves, and the number of - minterms. (The number of minterms is the number of assignments to the - variables that cause the function to be different from the logical zero (for - BDDs) and from the background value (for ADDs.) The statistics are printed - if pr > 0. Specifically: pr = 0 : prints nothing pr = 1 : - prints counts of nodes and minterms pr = 2 : prints counts + disjoint - sum of product pr = 3 : prints counts + list of nodes pr > 3 : - prints counts + disjoint sum of product + list of nodes For the - purpose of counting the number of minterms, the function is supposed to - depend on n variables. Returns 1 if successful; 0 otherwise. - - Side Effects: None - -int -Cudd_PrintGroupedOrder( - DdManager * dd, - const char * str, - void * data -) - Hook function to print the current variable order. It may be called before - or after reordering. Prints on the manager's stdout a parenthesized list - that describes the variable groups. Returns 1 if successful; 0 otherwise. - - Side Effects: None - -int -Cudd_PrintInfo( - DdManager * dd, - FILE * fp -) - Prints out statistics and settings for a CUDD manager. Returns 1 if - successful; 0 otherwise. - - Side Effects: None - -int -Cudd_PrintLinear( - DdManager * table -) - Prints the linear transform matrix. Returns 1 in case of success; 0 - otherwise. - - Side Effects: none - -int -Cudd_PrintMinterm( - DdManager * manager, - DdNode * node -) - Prints a disjoint sum of product cover for the function rooted at node. Each - product corresponds to a path from node to a leaf node different from the - logical zero, and different from the background value. Uses the package - default output file. Returns 1 if successful; 0 otherwise. - - Side Effects: None - -int -Cudd_PrintTwoLiteralClauses( - DdManager * dd, - DdNode * f, - char ** names, - FILE * fp -) - Prints the one- and two-literal clauses. Returns 1 if successful; 0 - otherwise. The argument "names" can be NULL, in which case the variable - indices are printed. - - Side Effects: None - -void -Cudd_PrintVersion( - FILE * fp -) - Prints the package version number. - - Side Effects: None - -DdNode * -Cudd_PrioritySelect( - DdManager * dd, manager - DdNode * R, BDD of the relation - DdNode ** x, array of x variables - DdNode ** y, array of y variables - DdNode ** z, array of z variables (optional: may be - NULL) - DdNode * Pi, BDD of the priority function (optional: - may be NULL) - int n, size of x, y, and z - DD_PRFP Pifunc function used to build Pi if it is NULL -) - Selects pairs from a relation R(x,y) (given as a BDD) in such a way that a - given x appears in one pair only. Uses a priority function to determine - which y should be paired to a given x. Cudd_PrioritySelect returns a pointer - to the selected function if successful; NULL otherwise. Three of the - arguments--x, y, and z--are vectors of BDD variables. The first two are the - variables on which R depends. The third vector is a vector of auxiliary - variables, used during the computation. This vector is optional. If a NULL - value is passed instead, Cudd_PrioritySelect will create the working - variables on the fly. The sizes of x and y (and z if it is not NULL) should - equal n. The priority function Pi can be passed as a BDD, or can be built by - Cudd_PrioritySelect. If NULL is passed instead of a DdNode *, parameter - Pifunc is used by Cudd_PrioritySelect to build a BDD for the priority - function. (Pifunc is a pointer to a C function.) If Pi is not NULL, then - Pifunc is ignored. Pifunc should have the same interface as the standard - priority functions (e.g., Cudd_Dxygtdxz). Cudd_PrioritySelect and - Cudd_CProjection can sometimes be used interchangeably. Specifically, - calling Cudd_PrioritySelect with Cudd_Xgty as Pifunc produces the same - result as calling Cudd_CProjection with the all-zero minterm as reference - minterm. However, depending on the application, one or the other may be - preferable: When extracting representatives from an equivalence - relation, Cudd_CProjection has the advantage of nor requiring the auxiliary - variables. When computing matchings in general bipartite graphs, - Cudd_PrioritySelect normally obtains better results because it can use more - powerful matching schemes (e.g., Cudd_Dxygtdxz). - - Side Effects: If called with z == NULL, will create new variables in the - manager. - -void -Cudd_Quit( - DdManager * unique -) - Deletes resources associated with a DD manager and resets the global - statistical counters. (Otherwise, another manaqger subsequently created - would inherit the stats of this one.) - - Side Effects: None - -long -Cudd_Random( - -) - Portable number generator based on ran2 from "Numerical Recipes in C." It is - a long period (> 2 * 10^18) random number generator of L'Ecuyer with Bays- - Durham shuffle. Returns a long integer uniformly distributed between 0 and - 2147483561 (inclusive of the endpoint values). The random generator can be - explicitly initialized by calling Cudd_Srandom. If no explicit - initialization is performed, then the seed 1 is assumed. - - Side Effects: None - -int -Cudd_ReadArcviolation( - DdManager * dd -) - Returns the current value of the arcviolation parameter. This parameter is - used in group sifting to decide how many arcs into y not coming - from x are tolerable when checking for aggregation due to - extended symmetry. The value should be between 0 and 100. A small value - causes fewer variables to be aggregated. The default value is 0. - - Side Effects: None - -DdNode * -Cudd_ReadBackground( - DdManager * dd -) - Reads the background constant of the manager. - - Side Effects: None - -double -Cudd_ReadCacheHits( - DdManager * dd -) - Returns the number of cache hits. - - Side Effects: None - -double -Cudd_ReadCacheLookUps( - DdManager * dd -) - Returns the number of cache look-ups. - - Side Effects: None - -unsigned int -Cudd_ReadCacheSlots( - DdManager * dd -) - Reads the number of slots in the cache. - - Side Effects: None - -double -Cudd_ReadCacheUsedSlots( - DdManager * dd -) - Reads the fraction of used slots in the cache. The unused slots are those in - which no valid data is stored. Garbage collection, variable reordering, and - cache resizing may cause used slots to become unused. - - Side Effects: None - -unsigned int -Cudd_ReadDead( - DdManager * dd -) - Returns the number of dead nodes in the unique table. - - Side Effects: None - -unsigned long -Cudd_ReadElapsedTime( - DdManager * unique -) - Returns the time elapsed since the start time of the manager. - - Side Effects: None - -CUDD_VALUE_TYPE -Cudd_ReadEpsilon( - DdManager * dd -) - Reads the epsilon parameter of the manager. The epsilon parameter control - the comparison between floating point numbers. - - Side Effects: None - -Cudd_ErrorType -Cudd_ReadErrorCode( - DdManager * dd -) - Returns the code of the last error. The error codes are defined in cudd.h. - - Side Effects: None - -long -Cudd_ReadGarbageCollectionTime( - DdManager * dd -) - Returns the number of milliseconds spent doing garbage collection since the - manager was initialized. - - Side Effects: None - -int -Cudd_ReadGarbageCollections( - DdManager * dd -) - Returns the number of times garbage collection has occurred in the manager. - The number includes both the calls from reordering procedures and those - caused by requests to create new nodes. - - Side Effects: None - -Cudd_AggregationType -Cudd_ReadGroupcheck( - DdManager * dd -) - Reads the groupcheck parameter of the manager. The groupcheck parameter - determines the aggregation criterion in group sifting. - - Side Effects: None - -int -Cudd_ReadInvPermZdd( - DdManager * dd, - int i -) - Returns the index of the ZDD variable currently in the i-th position of the - order. If the index is CUDD_CONST_INDEX, returns CUDD_CONST_INDEX; - otherwise, if the index is out of bounds returns -1. - - Side Effects: None - -int -Cudd_ReadInvPerm( - DdManager * dd, - int i -) - Returns the index of the variable currently in the i-th position of the - order. If the index is CUDD_CONST_INDEX, returns CUDD_CONST_INDEX; - otherwise, if the index is out of bounds returns -1. - - Side Effects: None - -int -Cudd_ReadIthClause( - DdTlcInfo * tlc, - int i, - DdHalfWord * var1, - DdHalfWord * var2, - int * phase1, - int * phase2 -) - Accesses the i-th clause of a DD given the clause set which must be already - computed. Returns 1 if successful; 0 if i is out of range, or in case of - error. - - Side Effects: the four components of a clause are returned as side effects. - -unsigned int -Cudd_ReadKeys( - DdManager * dd -) - Returns the total number of nodes currently in the unique table, including - the dead nodes. - - Side Effects: None - -int -Cudd_ReadLinear( - DdManager * table, CUDD manager - int x, row index - int y column index -) - Reads an entry of the linear transform matrix. - - Side Effects: none - -DdNode * -Cudd_ReadLogicZero( - DdManager * dd -) - Returns the zero constant of the manager. The logic zero constant is the - complement of the one constant, and is distinct from the arithmetic zero. - - Side Effects: None - -unsigned int -Cudd_ReadLooseUpTo( - DdManager * dd -) - Reads the looseUpTo parameter of the manager. - - Side Effects: None - -unsigned int -Cudd_ReadMaxCacheHard( - DdManager * dd -) - Reads the maxCacheHard parameter of the manager. - - Side Effects: None - -unsigned int -Cudd_ReadMaxCache( - DdManager * dd -) - Returns the soft limit for the cache size. - - Side Effects: None - -double -Cudd_ReadMaxGrowthAlternate( - DdManager * dd -) - Reads the maxGrowthAlt parameter of the manager. This parameter is analogous - to the maxGrowth paramter, and is used every given number of reorderings - instead of maxGrowth. The number of reorderings is set with - Cudd_SetReorderingCycle. If the number of reorderings is 0 (default) - maxGrowthAlt is never used. - - Side Effects: None - -double -Cudd_ReadMaxGrowth( - DdManager * dd -) - Reads the maxGrowth parameter of the manager. This parameter determines how - much the number of nodes can grow during sifting of a variable. Overall, - sifting never increases the size of the decision diagrams. This parameter - only refers to intermediate results. A lower value will speed up sifting, - possibly at the expense of quality. - - Side Effects: None - -unsigned int -Cudd_ReadMaxLive( - DdManager * dd -) - Reads the maximum allowed number of live nodes. When this number is - exceeded, the package returns NULL. - - Side Effects: none - -unsigned long -Cudd_ReadMaxMemory( - DdManager * dd -) - Reads the maximum allowed memory. When this number is exceeded, the package - returns NULL. - - Side Effects: none - -unsigned int -Cudd_ReadMaxReorderings( - DdManager * dd -) - Returns the maximum number of times reordering may be invoked in this - manager. - - Side Effects: None - -unsigned long -Cudd_ReadMemoryInUse( - DdManager * dd -) - Returns the memory in use by the manager measured in bytes. - - Side Effects: None - -unsigned int -Cudd_ReadMinDead( - DdManager * dd -) - Reads the minDead parameter of the manager. The minDead parameter is used by - the package to decide whether to collect garbage or resize a subtable of the - unique table when the subtable becomes too full. The application can - indirectly control the value of minDead by setting the looseUpTo parameter. - - Side Effects: None - -unsigned int -Cudd_ReadMinHit( - DdManager * dd -) - Reads the hit rate that causes resizinig of the computed table. - - Side Effects: None - -DdNode * -Cudd_ReadMinusInfinity( - DdManager * dd -) - Reads the minus-infinity constant from the manager. - - Side Effects: None - -unsigned int -Cudd_ReadNextReordering( - DdManager * dd -) - Returns the threshold for the next dynamic reordering. The threshold is in - terms of number of nodes and is in effect only if reordering is enabled. The - count does not include the dead nodes, unless the countDead parameter of the - manager has been changed from its default setting. - - Side Effects: None - -long -Cudd_ReadNodeCount( - DdManager * dd -) - Reports the number of live nodes in BDDs and ADDs. This number does not - include the isolated projection functions and the unused constants. These - nodes that are not counted are not part of the DDs manipulated by the - application. - - Side Effects: None - -double -Cudd_ReadNodesDropped( - DdManager * dd -) - Returns the number of nodes killed by dereferencing if the keeping of this - statistic is enabled; -1 otherwise. This statistic is enabled only if the - package is compiled with DD_STATS defined. - - Side Effects: None - -double -Cudd_ReadNodesFreed( - DdManager * dd -) - Returns the number of nodes returned to the free list if the keeping of this - statistic is enabled; -1 otherwise. This statistic is enabled only if the - package is compiled with DD_STATS defined. - - Side Effects: None - -int -Cudd_ReadNumberXovers( - DdManager * dd -) - Reads the current number of crossovers used by the genetic algorithm for - variable reordering. A larger number of crossovers will cause the genetic - algorithm to take more time, but will generally produce better results. The - default value is 0, in which case the package uses three times the number of - variables as number of crossovers, with a maximum of 60. - - Side Effects: None - -DdNode * -Cudd_ReadOne( - DdManager * dd -) - Returns the one constant of the manager. The one constant is common to ADDs - and BDDs. - - Side Effects: None - -unsigned int -Cudd_ReadOrderRandomization( - DdManager * dd -) - Returns the order randomization factor. If non-zero this factor is used to - determine a perturbation of the next reordering threshold. Larger factors - cause larger perturbations. - - Side Effects: None - -int -Cudd_ReadPeakLiveNodeCount( - DdManager * dd -) - Reports the peak number of live nodes. - - Side Effects: None - -long -Cudd_ReadPeakNodeCount( - DdManager * dd -) - Reports the peak number of nodes. This number includes node on the free - list. At the peak, the number of nodes on the free list is guaranteed to be - less than DD_MEM_CHUNK. - - Side Effects: None - -int -Cudd_ReadPermZdd( - DdManager * dd, - int i -) - Returns the current position of the i-th ZDD variable in the order. If the - index is CUDD_CONST_INDEX, returns CUDD_CONST_INDEX; otherwise, if the index - is out of bounds returns -1. - - Side Effects: None - -int -Cudd_ReadPerm( - DdManager * dd, - int i -) - Returns the current position of the i-th variable in the order. If the index - is CUDD_CONST_INDEX, returns CUDD_CONST_INDEX; otherwise, if the index is - out of bounds returns -1. - - Side Effects: None - -DdNode * -Cudd_ReadPlusInfinity( - DdManager * dd -) - Reads the plus-infinity constant from the manager. - - Side Effects: None - -int -Cudd_ReadPopulationSize( - DdManager * dd -) - Reads the current size of the population used by the genetic algorithm for - variable reordering. A larger population size will cause the genetic - algorithm to take more time, but will generally produce better results. The - default value is 0, in which case the package uses three times the number of - variables as population size, with a maximum of 120. - - Side Effects: None - -int -Cudd_ReadRecomb( - DdManager * dd -) - Returns the current value of the recombination parameter used in group - sifting. A larger (positive) value makes the aggregation of variables due to - the second difference criterion more likely. A smaller (negative) value - makes aggregation less likely. - - Side Effects: None - -double -Cudd_ReadRecursiveCalls( - DdManager * dd -) - Returns the number of recursive calls if the package is compiled with - DD_COUNT defined. - - Side Effects: None - -int -Cudd_ReadReorderingCycle( - DdManager * dd -) - Reads the reordCycle parameter of the manager. This parameter determines how - often the alternate threshold on maximum growth is used in reordering. - - Side Effects: None - -long -Cudd_ReadReorderingTime( - DdManager * dd -) - Returns the number of milliseconds spent reordering variables since the - manager was initialized. The time spent in collecting garbage before - reordering is included. - - Side Effects: None - -unsigned int -Cudd_ReadReorderings( - DdManager * dd -) - Returns the number of times reordering has occurred in the manager. The - number includes both the calls to Cudd_ReduceHeap from the application - program and those automatically performed by the package. However, calls - that do not even initiate reordering are not counted. A call may not - initiate reordering if there are fewer than minsize live nodes in the - manager, or if CUDD_REORDER_NONE is specified as reordering method. The - calls to Cudd_ShuffleHeap are not counted. - - Side Effects: None - -int -Cudd_ReadSiftMaxSwap( - DdManager * dd -) - Reads the siftMaxSwap parameter of the manager. This parameter gives the - maximum number of swaps that will be attempted for each invocation of - sifting. The real number of swaps may exceed the set limit because the - package will always complete the sifting of the variable that causes the - limit to be reached. - - Side Effects: None - -int -Cudd_ReadSiftMaxVar( - DdManager * dd -) - Reads the siftMaxVar parameter of the manager. This parameter gives the - maximum number of variables that will be sifted for each invocation of - sifting. - - Side Effects: None - -int -Cudd_ReadSize( - DdManager * dd -) - Returns the number of BDD variables in existance. - - Side Effects: None - -unsigned int -Cudd_ReadSlots( - DdManager * dd -) - Returns the total number of slots of the unique table. This number ismainly - for diagnostic purposes. - - Side Effects: None - -unsigned long -Cudd_ReadStartTime( - DdManager * unique -) - Returns the start time of the manager. This is initially set to the number - of milliseconds since the program started, but may be reset by the - application. - - Side Effects: None - -FILE * -Cudd_ReadStderr( - DdManager * dd -) - Reads the stderr of a manager. This is the file pointer to which messages - normally going to stderr are written. It is initialized to stderr. - Cudd_SetStderr allows the application to redirect it. - - Side Effects: None - -FILE * -Cudd_ReadStdout( - DdManager * dd -) - Reads the stdout of a manager. This is the file pointer to which messages - normally going to stdout are written. It is initialized to stdout. - Cudd_SetStdout allows the application to redirect it. - - Side Effects: None - -double -Cudd_ReadSwapSteps( - DdManager * dd -) - Reads the number of elementary reordering steps. - - Side Effects: none - -int -Cudd_ReadSymmviolation( - DdManager * dd -) - Returns the current value of the symmviolation parameter. This parameter is - used in group sifting to decide how many violations to the symmetry - conditions f10 = f01 or f11 = f00 are tolerable - when checking for aggregation due to extended symmetry. The value should be - between 0 and 100. A small value causes fewer variables to be aggregated. - The default value is 0. - - Side Effects: None - -unsigned long -Cudd_ReadTimeLimit( - DdManager * unique -) - Returns the time limit for the manager. This is initially set to a very - large number, but may be reset by the application. - - Side Effects: None - -MtrNode * -Cudd_ReadTree( - DdManager * dd -) - Returns the variable group tree of the manager. - - Side Effects: None - -double -Cudd_ReadUniqueLinks( - DdManager * dd -) - Returns the number of links followed during look-ups in the unique table if - the keeping of this statistic is enabled; -1 otherwise. If an item is found - in the first position of its collision list, the number of links followed is - taken to be 0. If it is in second position, the number of links is 1, and so - on. This statistic is enabled only if the package is compiled with - DD_UNIQUE_PROFILE defined. - - Side Effects: None - -double -Cudd_ReadUniqueLookUps( - DdManager * dd -) - Returns the number of look-ups in the unique table if the keeping of this - statistic is enabled; -1 otherwise. This statistic is enabled only if the - package is compiled with DD_UNIQUE_PROFILE defined. - - Side Effects: None - -double -Cudd_ReadUsedSlots( - DdManager * dd -) - Reads the fraction of used slots in the unique table. The unused slots are - those in which no valid data is stored. Garbage collection, variable - reordering, and subtable resizing may cause used slots to become unused. - - Side Effects: None - -DdNode * -Cudd_ReadVars( - DdManager * dd, - int i -) - Returns the i-th element of the vars array if it falls within the array - bounds; NULL otherwise. If i is the index of an existing variable, this - function produces the same result as Cudd_bddIthVar. However, if the i-th - var does not exist yet, Cudd_bddIthVar will create it, whereas Cudd_ReadVars - will not. - - Side Effects: None - -DdNode * -Cudd_ReadZddOne( - DdManager * dd, - int i -) - Returns the ZDD for the constant 1 function. The representation of the - constant 1 function as a ZDD depends on how many variables it (nominally) - depends on. The index of the topmost variable in the support is given as - argument i. - - Side Effects: None - -int -Cudd_ReadZddSize( - DdManager * dd -) - Returns the number of ZDD variables in existance. - - Side Effects: None - -MtrNode * -Cudd_ReadZddTree( - DdManager * dd -) - Returns the variable group tree of the manager. - - Side Effects: None - -DdNode * -Cudd_ReadZero( - DdManager * dd -) - Returns the zero constant of the manager. The zero constant is the - arithmetic zero, rather than the logic zero. The latter is the complement of - the one constant. - - Side Effects: None - -void -Cudd_RecursiveDerefZdd( - DdManager * table, - DdNode * n -) - Decreases the reference count of ZDD node n. If n dies, recursively - decreases the reference counts of its children. It is used to dispose of a - ZDD that is no longer needed. - - Side Effects: None - -void -Cudd_RecursiveDeref( - DdManager * table, - DdNode * n -) - Decreases the reference count of node n. If n dies, recursively decreases - the reference counts of its children. It is used to dispose of a DD that is - no longer needed. - - Side Effects: None - -int -Cudd_ReduceHeap( - DdManager * table, DD manager - Cudd_ReorderingTy heuristic, method used for reordering - int minsize bound below which no reordering occurs -) - Main dynamic reordering routine. Calls one of the possible reordering - procedures: Swapping Sifting Symmetric Sifting Group - Sifting Window Permutation Simulated Annealing Genetic Algorithm - Dynamic Programming (exact) For sifting, symmetric sifting, group - sifting, and window permutation it is possible to request reordering to - convergence. The core of all methods is the reordering procedure - cuddSwapInPlace() which swaps two adjacent variables and is based on - Rudell's paper. Returns 1 in case of success; 0 otherwise. In the case of - symmetric sifting (with and without convergence) returns 1 plus the number - of symmetric variables, in case of success. - - Side Effects: Changes the variable order for all diagrams and clears the - cache. - -void -Cudd_Ref( - DdNode * n -) - Increases the reference count of a node, if it is not saturated. - - Side Effects: None - -DdNode * -Cudd_RemapOverApprox( - DdManager * dd, manager - DdNode * f, function to be superset - int numVars, number of variables in the support of f - int threshold, when to stop approximation - double quality minimum improvement for accepted changes -) - Extracts a dense superset from a BDD. The procedure is identical to the - underapproximation procedure except for the fact that it works on the - complement of the given function. Extracting the subset of the complement - function is equivalent to extracting the superset of the function. Returns a - pointer to the BDD of the superset if successful. NULL if intermediate - result causes the procedure to run out of memory. The parameter numVars is - the maximum number of variables to be used in minterm calculation. The - optimal number should be as close as possible to the size of the support of - f. However, it is safe to pass the value returned by Cudd_ReadSize for - numVars when the number of variables is under 1023. If numVars is larger - than 1023, it will overflow. If a 0 parameter is passed then the procedure - will compute a value which will avoid overflow but will cause underflow with - 2046 variables or more. - - Side Effects: None - -DdNode * -Cudd_RemapUnderApprox( - DdManager * dd, manager - DdNode * f, function to be subset - int numVars, number of variables in the support of f - int threshold, when to stop approximation - double quality minimum improvement for accepted changes -) - Extracts a dense subset from a BDD. This procedure uses a remapping - technique and density as the cost function. Returns a pointer to the BDD of - the subset if successful. NULL if the procedure runs out of memory. The - parameter numVars is the maximum number of variables to be used in minterm - calculation. The optimal number should be as close as possible to the size - of the support of f. However, it is safe to pass the value returned by - Cudd_ReadSize for numVars when the number of variables is under 1023. If - numVars is larger than 1023, it will cause overflow. If a 0 parameter is - passed then the procedure will compute a value which will avoid overflow but - will cause underflow with 2046 variables or more. - - Side Effects: None - -int -Cudd_RemoveHook( - DdManager * dd, - DD_HFP f, - Cudd_HookType where -) - Removes a function from a hook. A hook is a list of application-provided - functions called on certain occasions by the package. Returns 1 if - successful; 0 the function was not in the list. - - Side Effects: None - -int -Cudd_ReorderingReporting( - DdManager * dd -) - Returns 1 if reporting of reordering stats is enabled; 0 otherwise. - - Side Effects: none - -int -Cudd_ReorderingStatusZdd( - DdManager * unique, - Cudd_ReorderingTy method -) - Reports the status of automatic dynamic reordering of ZDDs. Parameter method - is set to the ZDD reordering method currently selected. Returns 1 if - automatic reordering is enabled; 0 otherwise. - - Side Effects: Parameter method is set to the ZDD reordering method currently - selected. - -int -Cudd_ReorderingStatus( - DdManager * unique, - Cudd_ReorderingTy method -) - Reports the status of automatic dynamic reordering of BDDs and ADDs. - Parameter method is set to the reordering method currently selected. Returns - 1 if automatic reordering is enabled; 0 otherwise. - - Side Effects: Parameter method is set to the reordering method currently - selected. - -int -Cudd_Reserve( - DdManager * manager, - int amount -) - Expand a manager by a specified number of subtables without actually - creating new variables. This function can be used to reduce the frequency of - resizing when an estimate of the number of variables is available. One would - call this function instead of passing the number of variables to Cudd_Init - if variables should not be created right away of if the estimate on their - number became available only after the manager has been created. Returns 1 - if successful; 0 otherwise. - - Side Effects: None - -void -Cudd_ResetStartTime( - DdManager * unique -) - Resets the start time of the manager. - - Side Effects: None - -void -Cudd_SetArcviolation( - DdManager * dd, - int arcviolation -) - Sets the value of the arcviolation parameter. This parameter is used in - group sifting to decide how many arcs into y not coming from - x are tolerable when checking for aggregation due to extended - symmetry. The value should be between 0 and 100. A small value causes fewer - variables to be aggregated. The default value is 0. - - Side Effects: None - -void -Cudd_SetBackground( - DdManager * dd, - DdNode * bck -) - Sets the background constant of the manager. It assumes that the DdNode - pointer bck is already referenced. - - Side Effects: None - -void -Cudd_SetEpsilon( - DdManager * dd, - CUDD_VALUE_TYPE ep -) - Sets the epsilon parameter of the manager to ep. The epsilon parameter - control the comparison between floating point numbers. - - Side Effects: None - -void -Cudd_SetGroupcheck( - DdManager * dd, - Cudd_AggregationT gc -) - Sets the parameter groupcheck of the manager to gc. The groupcheck parameter - determines the aggregation criterion in group sifting. - - Side Effects: None - -void -Cudd_SetLooseUpTo( - DdManager * dd, - unsigned int lut -) - Sets the looseUpTo parameter of the manager. This parameter of the manager - controls the threshold beyond which no fast growth of the unique table is - allowed. The threshold is given as a number of slots. If the value passed to - this function is 0, the function determines a suitable value based on the - available memory. - - Side Effects: None - -void -Cudd_SetMaxCacheHard( - DdManager * dd, - unsigned int mc -) - Sets the maxCacheHard parameter of the manager. The cache cannot grow larger - than maxCacheHard entries. This parameter allows an application to control - the trade-off of memory versus speed. If the value passed to this function - is 0, the function determines a suitable maximum cache size based on the - available memory. - - Side Effects: None - -void -Cudd_SetMaxGrowthAlternate( - DdManager * dd, - double mg -) - Sets the maxGrowthAlt parameter of the manager. This parameter is analogous - to the maxGrowth paramter, and is used every given number of reorderings - instead of maxGrowth. The number of reorderings is set with - Cudd_SetReorderingCycle. If the number of reorderings is 0 (default) - maxGrowthAlt is never used. - - Side Effects: None - -void -Cudd_SetMaxGrowth( - DdManager * dd, - double mg -) - Sets the maxGrowth parameter of the manager. This parameter determines how - much the number of nodes can grow during sifting of a variable. Overall, - sifting never increases the size of the decision diagrams. This parameter - only refers to intermediate results. A lower value will speed up sifting, - possibly at the expense of quality. - - Side Effects: None - -void -Cudd_SetMaxLive( - DdManager * dd, - unsigned int maxLive -) - Sets the maximum allowed number of live nodes. When this number is exceeded, - the package returns NULL. - - Side Effects: none - -void -Cudd_SetMaxMemory( - DdManager * dd, - unsigned long maxMemory -) - Sets the maximum allowed memory. When this number is exceeded, the package - returns NULL. - - Side Effects: none - -void -Cudd_SetMaxReorderings( - DdManager * dd, - unsigned int mr -) - Sets the maximum number of times reordering may be invoked in this manager. - The default value is (practically) infinite. - - Side Effects: None - -void -Cudd_SetMinHit( - DdManager * dd, - unsigned int hr -) - Sets the minHit parameter of the manager. This parameter controls the - resizing of the computed table. If the hit rate is larger than the specified - value, and the cache is not already too large, then its size is doubled. - - Side Effects: None - -void -Cudd_SetNextReordering( - DdManager * dd, - unsigned int next -) - Sets the threshold for the next dynamic reordering. The threshold is in - terms of number of nodes and is in effect only if reordering is enabled. The - count does not include the dead nodes, unless the countDead parameter of the - manager has been changed from its default setting. - - Side Effects: None - -void -Cudd_SetNumberXovers( - DdManager * dd, - int numberXovers -) - Sets the number of crossovers used by the genetic algorithm for variable - reordering. A larger number of crossovers will cause the genetic algorithm - to take more time, but will generally produce better results. The default - value is 0, in which case the package uses three times the number of - variables as number of crossovers, with a maximum of 60. - - Side Effects: None - -void -Cudd_SetOrderRandomization( - DdManager * dd, - unsigned int factor -) - Sets the order randomization factor. - - Side Effects: None - -void -Cudd_SetPopulationSize( - DdManager * dd, - int populationSize -) - Sets the size of the population used by the genetic algorithm for variable - reordering. A larger population size will cause the genetic algorithm to - take more time, but will generally produce better results. The default value - is 0, in which case the package uses three times the number of variables as - population size, with a maximum of 120. - - Side Effects: Changes the manager. - -void -Cudd_SetRecomb( - DdManager * dd, - int recomb -) - Sets the value of the recombination parameter used in group sifting. A - larger (positive) value makes the aggregation of variables due to the second - difference criterion more likely. A smaller (negative) value makes - aggregation less likely. The default value is 0. - - Side Effects: Changes the manager. - -void -Cudd_SetReorderingCycle( - DdManager * dd, - int cycle -) - Sets the reordCycle parameter of the manager. This parameter determines how - often the alternate threshold on maximum growth is used in reordering. - - Side Effects: None - -void -Cudd_SetSiftMaxSwap( - DdManager * dd, - int sms -) - Sets the siftMaxSwap parameter of the manager. This parameter gives the - maximum number of swaps that will be attempted for each invocation of - sifting. The real number of swaps may exceed the set limit because the - package will always complete the sifting of the variable that causes the - limit to be reached. - - Side Effects: None - -void -Cudd_SetSiftMaxVar( - DdManager * dd, - int smv -) - Sets the siftMaxVar parameter of the manager. This parameter gives the - maximum number of variables that will be sifted for each invocation of - sifting. - - Side Effects: None - -void -Cudd_SetStartTime( - DdManager * unique, - unsigned long st -) - Sets the start time of the manager. - - Side Effects: None - -void -Cudd_SetStderr( - DdManager * dd, - FILE * fp -) - Sets the stderr of a manager. - - Side Effects: None - -void -Cudd_SetStdout( - DdManager * dd, - FILE * fp -) - Sets the stdout of a manager. - - Side Effects: None - -void -Cudd_SetSymmviolation( - DdManager * dd, - int symmviolation -) - Sets the value of the symmviolation parameter. This parameter is used in - group sifting to decide how many violations to the symmetry conditions - f10 = f01 or f11 = f00 are tolerable when checking - for aggregation due to extended symmetry. The value should be between 0 and - 100. A small value causes fewer variables to be aggregated. The default - value is 0. - - Side Effects: Changes the manager. - -void -Cudd_SetTimeLimit( - DdManager * unique, - unsigned long tl -) - Sets the time limit for the manager. - - Side Effects: None - -void -Cudd_SetTree( - DdManager * dd, - MtrNode * tree -) - Sets the variable group tree of the manager. - - Side Effects: None - -int -Cudd_SetVarMap( - DdManager * manager, DD manager - DdNode ** x, first array of variables - DdNode ** y, second array of variables - int n length of both arrays -) - Registers with the manager a variable mapping described by two sets of - variables. This variable mapping is then used by functions like - Cudd_bddVarMap. This function is convenient for those applications that - perform the same mapping several times. However, if several different - permutations are used, it may be more efficient not to rely on the - registered mapping, because changing mapping causes the cache to be cleared. - (The initial setting, however, does not clear the cache.) The two sets of - variables (x and y) must have the same size (x and y). The size is given by - n. The two sets of variables are normally disjoint, but this restriction is - not imposeded by the function. When new variables are created, the map is - automatically extended (each new variable maps to itself). The typical use, - however, is to wait until all variables are created, and then create the - map. Returns 1 if the mapping is successfully registered with the manager; 0 - otherwise. - - Side Effects: Modifies the manager. May clear the cache. - -void -Cudd_SetZddTree( - DdManager * dd, - MtrNode * tree -) - Sets the ZDD variable group tree of the manager. - - Side Effects: None - -int -Cudd_SharingSize( - DdNode ** nodeArray, - int n -) - Counts the number of nodes in an array of DDs. Shared nodes are counted only - once. Returns the total number of nodes. - - Side Effects: None - -int -Cudd_ShortestLength( - DdManager * manager, - DdNode * f, - int * weight -) - Find the length of the shortest path(s) in a DD. f is the DD we want to get - the shortest path for; weight[i] is the weight of the THEN edge coming from - the node whose index is i. All ELSE edges have 0 weight. Returns the length - of the shortest path(s) if such a path is found; a large number if the - function is identically 0, and CUDD_OUT_OF_MEM in case of failure. - - Side Effects: None - -DdNode * -Cudd_ShortestPath( - DdManager * manager, - DdNode * f, - int * weight, - int * support, - int * length -) - Finds a shortest path in a DD. f is the DD we want to get the shortest path - for; weight[i] is the weight of the THEN arc coming from the node whose - index is i. If weight is NULL, then unit weights are assumed for all THEN - arcs. All ELSE arcs have 0 weight. If non-NULL, both weight and support - should point to arrays with at least as many entries as there are variables - in the manager. Returns the shortest path as the BDD of a cube. - - Side Effects: support contains on return the true support of f. If support - is NULL on entry, then Cudd_ShortestPath does not compute the true support - info. length contains the length of the path. - -int -Cudd_ShuffleHeap( - DdManager * table, DD manager - int * permutation required variable permutation -) - Reorders variables according to given permutation. The i-th entry of the - permutation array contains the index of the variable that should be brought - to the i-th level. The size of the array should be equal or greater to the - number of variables currently in use. Returns 1 in case of success; 0 - otherwise. - - Side Effects: Changes the variable order for all diagrams and clears the - cache. - -DdNode * -Cudd_SolveEqn( - DdManager * bdd, - DdNode * F, the left-hand side of the equation - DdNode * Y, the cube of the y variables - DdNode ** G, the array of solutions (return parameter) - int ** yIndex, index of y variables - int n numbers of unknowns -) - Implements the solution for F(x,y) = 0. The return value is the consistency - condition. The y variables are the unknowns and the remaining variables are - the parameters. Returns the consistency condition if successful; NULL - otherwise. Cudd_SolveEqn allocates an array and fills it with the indices of - the unknowns. This array is used by Cudd_VerifySol. - - Side Effects: The solution is returned in G; the indices of the y variables - are returned in yIndex. - -DdNode * -Cudd_SplitSet( - DdManager * manager, - DdNode * S, - DdNode ** xVars, - int n, - double m -) - Returns m minterms from a BDD whose support has n - variables at most. The procedure tries to create as few extra nodes as - possible. The function represented by S depends on at most - n of the variables in xVars. Returns a BDD with - m minterms of the on-set of S if successful; NULL otherwise. - - Side Effects: None - -void -Cudd_Srandom( - long seed -) - Initializer for the portable number generator based on ran2 in "Numerical - Recipes in C." The input is the seed for the generator. If it is negative, - its absolute value is taken as seed. If it is 0, then 1 is taken as seed. - The initialized sets up the two recurrences used to generate a long-period - stream, and sets up the shuffle table. - - Side Effects: None - -int -Cudd_StdPostReordHook( - DdManager * dd, - const char * str, - void * data -) - Sample hook function to call after reordering. Prints on the manager's - stdout final size and reordering time. Returns 1 if successful; 0 otherwise. - - Side Effects: None - -int -Cudd_StdPreReordHook( - DdManager * dd, - const char * str, - void * data -) - Sample hook function to call before reordering. Prints on the manager's - stdout reordering method and initial size. Returns 1 if successful; 0 - otherwise. - - Side Effects: None - -DdNode * -Cudd_SubsetCompress( - DdManager * dd, manager - DdNode * f, BDD whose subset is sought - int nvars, number of variables in the support of f - int threshold maximum number of nodes in the subset -) - Finds a dense subset of BDD f. Density is the ratio of number - of minterms to number of nodes. Uses several techniques in series. It is - more expensive than other subsetting procedures, but often produces better - results. See Cudd_SubsetShortPaths for a description of the threshold and - nvars parameters. Returns a pointer to the result if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_SubsetHeavyBranch( - DdManager * dd, manager - DdNode * f, function to be subset - int numVars, number of variables in the support of f - int threshold maximum number of nodes in the subset -) - Extracts a dense subset from a BDD. This procedure builds a subset by - throwing away one of the children of each node, starting from the root, - until the result is small enough. The child that is eliminated from the - result is the one that contributes the fewer minterms. Returns a pointer to - the BDD of the subset if successful. NULL if the procedure runs out of - memory. The parameter numVars is the maximum number of variables to be used - in minterm calculation and node count calculation. The optimal number should - be as close as possible to the size of the support of f. However, it is safe - to pass the value returned by Cudd_ReadSize for numVars when the number of - variables is under 1023. If numVars is larger than 1023, it will overflow. - If a 0 parameter is passed then the procedure will compute a value which - will avoid overflow but will cause underflow with 2046 variables or more. - - Side Effects: None - -DdNode * -Cudd_SubsetShortPaths( - DdManager * dd, manager - DdNode * f, function to be subset - int numVars, number of variables in the support of f - int threshold, maximum number of nodes in the subset - int hardlimit flag: 1 if threshold is a hard limit -) - Extracts a dense subset from a BDD. This procedure tries to preserve the - shortest paths of the input BDD, because they give many minterms and - contribute few nodes. This procedure may increase the number of nodes in - trying to create the subset or reduce the number of nodes due to - recombination as compared to the original BDD. Hence the threshold may not - be strictly adhered to. In practice, recombination overshadows the increase - in the number of nodes and results in small BDDs as compared to the - threshold. The hardlimit specifies whether threshold needs to be strictly - adhered to. If it is set to 1, the procedure ensures that result is never - larger than the specified limit but may be considerably less than the - threshold. Returns a pointer to the BDD for the subset if successful; NULL - otherwise. The value for numVars should be as close as possible to the size - of the support of f for better efficiency. However, it is safe to pass the - value returned by Cudd_ReadSize for numVars. If 0 is passed, then the value - returned by Cudd_ReadSize is used. - - Side Effects: None - -DdNode * -Cudd_SubsetWithMaskVars( - DdManager * dd, manager - DdNode * f, function from which to pick a cube - DdNode ** vars, array of variables - int nvars, size of vars - DdNode ** maskVars, array of variables - int mvars size of maskVars -) - Extracts a subset from a BDD in the following procedure. 1. Compute the - weight for each mask variable by counting the number of minterms for both - positive and negative cofactors of the BDD with respect to each mask - variable. (weight = #positive - #negative) 2. Find a representative cube of - the BDD by using the weight. From the top variable of the BDD, for each - variable, if the weight is greater than 0.0, choose THEN branch, othereise - ELSE branch, until meeting the constant 1. 3. Quantify out the variables not - in maskVars from the representative cube and if a variable in maskVars is - don't care, replace the variable with a constant(1 or 0) depending on the - weight. 4. Make a subset of the BDD by multiplying with the modified cube. - - Side Effects: None - -DdNode * -Cudd_SupersetCompress( - DdManager * dd, manager - DdNode * f, BDD whose superset is sought - int nvars, number of variables in the support of f - int threshold maximum number of nodes in the superset -) - Finds a dense superset of BDD f. Density is the ratio of number - of minterms to number of nodes. Uses several techniques in series. It is - more expensive than other supersetting procedures, but often produces better - results. See Cudd_SupersetShortPaths for a description of the threshold and - nvars parameters. Returns a pointer to the result if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_SupersetHeavyBranch( - DdManager * dd, manager - DdNode * f, function to be superset - int numVars, number of variables in the support of f - int threshold maximum number of nodes in the superset -) - Extracts a dense superset from a BDD. The procedure is identical to the - subset procedure except for the fact that it receives the complement of the - given function. Extracting the subset of the complement function is - equivalent to extracting the superset of the function. This procedure builds - a superset by throwing away one of the children of each node starting from - the root of the complement function, until the result is small enough. The - child that is eliminated from the result is the one that contributes the - fewer minterms. Returns a pointer to the BDD of the superset if successful. - NULL if intermediate result causes the procedure to run out of memory. The - parameter numVars is the maximum number of variables to be used in minterm - calculation and node count calculation. The optimal number should be as - close as possible to the size of the support of f. However, it is safe to - pass the value returned by Cudd_ReadSize for numVars when the number of - variables is under 1023. If numVars is larger than 1023, it will overflow. - If a 0 parameter is passed then the procedure will compute a value which - will avoid overflow but will cause underflow with 2046 variables or more. - - Side Effects: None - -DdNode * -Cudd_SupersetShortPaths( - DdManager * dd, manager - DdNode * f, function to be superset - int numVars, number of variables in the support of f - int threshold, maximum number of nodes in the subset - int hardlimit flag: 1 if threshold is a hard limit -) - Extracts a dense superset from a BDD. The procedure is identical to the - subset procedure except for the fact that it receives the complement of the - given function. Extracting the subset of the complement function is - equivalent to extracting the superset of the function. This procedure tries - to preserve the shortest paths of the complement BDD, because they give many - minterms and contribute few nodes. This procedure may increase the number of - nodes in trying to create the superset or reduce the number of nodes due to - recombination as compared to the original BDD. Hence the threshold may not - be strictly adhered to. In practice, recombination overshadows the increase - in the number of nodes and results in small BDDs as compared to the - threshold. The hardlimit specifies whether threshold needs to be strictly - adhered to. If it is set to 1, the procedure ensures that result is never - larger than the specified limit but may be considerably less than the - threshold. Returns a pointer to the BDD for the superset if successful; NULL - otherwise. The value for numVars should be as close as possible to the size - of the support of f for better efficiency. However, it is safe to pass the - value returned by Cudd_ReadSize for numVar. If 0 is passed, then the value - returned by Cudd_ReadSize is used. - - Side Effects: None - -int * -Cudd_SupportIndex( - DdManager * dd, manager - DdNode * f DD whose support is sought -) - Finds the variables on which a DD depends. Returns an index array of the - variables if successful; NULL otherwise. The size of the array equals the - number of variables in the manager. Each entry of the array is 1 if the - corresponding variable is in the support of the DD and 0 otherwise. - - Side Effects: None - -int -Cudd_SupportIndices( - DdManager * dd, manager - DdNode * f, DD whose support is sought - int ** indices array containing (on return) the indices -) - Finds the variables on which a DD depends. Returns the number of variables - if successful; CUDD_OUT_OF_MEM otherwise. - - Side Effects: The indices of the support variables are returned as side - effects. If the function is constant, no array is allocated. - -int -Cudd_SupportSize( - DdManager * dd, manager - DdNode * f DD whose support size is sought -) - Returns the variables on which a DD depends. - - Side Effects: None - -DdNode * -Cudd_Support( - DdManager * dd, manager - DdNode * f DD whose support is sought -) - Finds the variables on which a DD depends. Returns a BDD consisting of the - product of the variables if successful; NULL otherwise. - - Side Effects: None - -void -Cudd_SymmProfile( - DdManager * table, - int lower, - int upper -) - Prints statistics on symmetric variables. - - Side Effects: None - -int -Cudd_TimeLimited( - DdManager * unique -) - Returns true if the time limit for the manager is set. - - Side Effects: None - -void -Cudd_TurnOffCountDead( - DdManager * dd -) - Causes the dead nodes not to be counted towards triggering reordering. This - causes less frequent reorderings. By default dead nodes are not counted. - Therefore there is no need to call this function unless Cudd_TurnOnCountDead - has been previously called. - - Side Effects: Changes the manager. - -void -Cudd_TurnOnCountDead( - DdManager * dd -) - Causes the dead nodes to be counted towards triggering reordering. This - causes more frequent reorderings. By default dead nodes are not counted. - - Side Effects: Changes the manager. - -DdNode * -Cudd_UnderApprox( - DdManager * dd, manager - DdNode * f, function to be subset - int numVars, number of variables in the support of f - int threshold, when to stop approximation - int safe, enforce safe approximation - double quality minimum improvement for accepted changes -) - Extracts a dense subset from a BDD. This procedure uses a variant of Tom - Shiple's underapproximation method. The main difference from the original - method is that density is used as cost function. Returns a pointer to the - BDD of the subset if successful. NULL if the procedure runs out of memory. - The parameter numVars is the maximum number of variables to be used in - minterm calculation. The optimal number should be as close as possible to - the size of the support of f. However, it is safe to pass the value returned - by Cudd_ReadSize for numVars when the number of variables is under 1023. If - numVars is larger than 1023, it will cause overflow. If a 0 parameter is - passed then the procedure will compute a value which will avoid overflow but - will cause underflow with 2046 variables or more. - - Side Effects: None - -void -Cudd_UnsetTimeLimit( - DdManager * unique -) - Unsets the time limit for the manager. Actually, sets it to a very large - value. - - Side Effects: None - -void -Cudd_UpdateTimeLimit( - DdManager * unique -) - Updates the time limit for the manager by subtracting the elapsed time from - it. - - Side Effects: None - -int * -Cudd_VectorSupportIndex( - DdManager * dd, manager - DdNode ** F, array of DDs whose support is sought - int n size of the array -) - Finds the variables on which a set of DDs depends. The set must contain - either BDDs and ADDs, or ZDDs. Returns an index array of the variables if - successful; NULL otherwise. - - Side Effects: None - -int -Cudd_VectorSupportIndices( - DdManager * dd, manager - DdNode ** F, DD whose support is sought - int n, size of the array - int ** indices array containing (on return) the indices -) - Finds the variables on which a set of DDs depends. The set must contain - either BDDs and ADDs, or ZDDs. Returns the number of variables if - successful; CUDD_OUT_OF_MEM otherwise. - - Side Effects: The indices of the support variables are returned as side - effects. If the function is constant, no array is allocated. - -int -Cudd_VectorSupportSize( - DdManager * dd, manager - DdNode ** F, array of DDs whose support is sought - int n size of the array -) - Returns the variables on which a set of DDs depends. The set must contain - either BDDs and ADDs, or ZDDs. - - Side Effects: None - -DdNode * -Cudd_VectorSupport( - DdManager * dd, manager - DdNode ** F, array of DDs whose support is sought - int n size of the array -) - Finds the variables on which a set of DDs depends. The set must contain - either BDDs and ADDs, or ZDDs. Returns a BDD consisting of the product of - the variables if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_VerifySol( - DdManager * bdd, - DdNode * F, the left-hand side of the equation - DdNode ** G, the array of solutions - int * yIndex, index of y variables - int n numbers of unknowns -) - Checks the solution of F(x,y) = 0. This procedure substitutes the solution - components for the unknowns of F and returns the resulting BDD for F. - - Side Effects: Frees the memory pointed by yIndex. - -DdNode * -Cudd_Xeqy( - DdManager * dd, DD manager - int N, number of x and y variables - DdNode ** x, array of x variables - DdNode ** y array of y variables -) - This function generates a BDD for the function x==y. Both x and y are N-bit - numbers, x[0] x[1] ... x[N-1] and y[0] y[1] ... y[N-1], with 0 the most - significant bit. The BDD is built bottom-up. It has 3*N-1 internal nodes, if - the variables are ordered as follows: x[0] y[0] x[1] y[1] ... x[N-1] y[N-1]. - - Side Effects: None - -DdNode * -Cudd_Xgty( - DdManager * dd, DD manager - int N, number of x and y variables - DdNode ** z, array of z variables: unused - DdNode ** x, array of x variables - DdNode ** y array of y variables -) - This function generates a BDD for the function x > y. Both x and y are N- - bit numbers, x[0] x[1] ... x[N-1] and y[0] y[1] ... y[N-1], with 0 the most - significant bit. The BDD is built bottom-up. It has 3*N-1 internal nodes, if - the variables are ordered as follows: x[0] y[0] x[1] y[1] ... x[N-1] y[N-1]. - Argument z is not used by Cudd_Xgty: it is included to make it call- - compatible to Cudd_Dxygtdxz and Cudd_Dxygtdyz. - - Side Effects: None - -DdNode * -Cudd_addAgreement( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - Returns NULL if not a terminal case; f op g otherwise, where f op g is f if - f==g; background if f!=g. - - Side Effects: None - -DdNode * -Cudd_addApply( - DdManager * dd, - DD_AOP op, - DdNode * f, - DdNode * g -) - Applies op to the corresponding discriminants of f and g. Returns a pointer - to the result if succssful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addBddInterval( - DdManager * dd, - DdNode * f, - CUDD_VALUE_TYPE lower, - CUDD_VALUE_TYPE upper -) - Converts an ADD to a BDD by replacing all discriminants greater than or - equal to lower and less than or equal to upper with 1, and all other - discriminants with 0. Returns a pointer to the resulting BDD if successful; - NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addBddIthBit( - DdManager * dd, - DdNode * f, - int bit -) - Converts an ADD to a BDD by replacing all discriminants whose i-th bit is - equal to 1 with 1, and all other discriminants with 0. The i-th bit refers - to the integer representation of the leaf value. If the value is has a - fractional part, it is ignored. Repeated calls to this procedure allow one - to transform an integer-valued ADD into an array of BDDs, one for each bit - of the leaf values. Returns a pointer to the resulting BDD if successful; - NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addBddPattern( - DdManager * dd, - DdNode * f -) - Converts an ADD to a BDD by replacing all discriminants different from 0 - with 1. Returns a pointer to the resulting BDD if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_addBddStrictThreshold( - DdManager * dd, - DdNode * f, - CUDD_VALUE_TYPE value -) - Converts an ADD to a BDD by replacing all discriminants STRICTLY greater - than value with 1, and all other discriminants with 0. Returns a pointer to - the resulting BDD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addBddThreshold( - DdManager * dd, - DdNode * f, - CUDD_VALUE_TYPE value -) - Converts an ADD to a BDD by replacing all discriminants greater than or - equal to value with 1, and all other discriminants with 0. Returns a pointer - to the resulting BDD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addCmpl( - DdManager * dd, - DdNode * f -) - Computes the complement of an ADD a la C language: The complement of 0 is 1 - and the complement of everything else is 0. Returns a pointer to the - resulting ADD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addCompose( - DdManager * dd, - DdNode * f, - DdNode * g, - int v -) - Substitutes g for x_v in the ADD for f. v is the index of the variable to be - substituted. g must be a 0-1 ADD. Cudd_bddCompose passes the corresponding - projection function to the recursive procedure, so that the cache may be - used. Returns the composed ADD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addComputeCube( - DdManager * dd, - DdNode ** vars, - int * phase, - int n -) - Computes the cube of an array of ADD variables. If non-null, the phase - argument indicates which literal of each variable should appear in the cube. - If phase[i] is nonzero, then the positive literal is used. If phase is NULL, - the cube is positive unate. Returns a pointer to the result if successful; - NULL otherwise. - - Side Effects: none - -DdNode * -Cudd_addConstrain( - DdManager * dd, - DdNode * f, - DdNode * c -) - Computes f constrain c (f @ c), for f an ADD and c a 0-1 ADD. List of - special cases: F @ 0 = 0 F @ 1 = F 0 @ c = 0 1 @ c - = 1 F @ F = 1 Returns a pointer to the result if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_addConst( - DdManager * dd, - CUDD_VALUE_TYPE c -) - Retrieves the ADD for constant c if it already exists, or creates a new ADD. - Returns a pointer to the ADD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addDiff( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - Returns NULL if not a terminal case; f op g otherwise, where f op g is - plusinfinity if f=g; min(f,g) if f!=g. - - Side Effects: None - -DdNode * -Cudd_addDivide( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - Integer and floating point division. Returns NULL if not a terminal case; f - / g otherwise. - - Side Effects: None - -DdNode * -Cudd_addEvalConst( - DdManager * dd, - DdNode * f, - DdNode * g -) - Checks whether ADD g is constant whenever ADD f is 1. f must be a 0-1 ADD. - Returns a pointer to the resulting ADD (which may or may not be constant) or - DD_NON_CONSTANT. If f is identically 0, the check is assumed to be - successful, and the background value is returned. No new nodes are created. - - Side Effects: None - -DdNode * -Cudd_addExistAbstract( - DdManager * manager, - DdNode * f, - DdNode * cube -) - Abstracts all the variables in cube from f by summing over all possible - values taken by the variables. Returns the abstracted ADD. - - Side Effects: None - -DdNode * -Cudd_addFindMax( - DdManager * dd, - DdNode * f -) - Returns a pointer to a constant ADD. - - Side Effects: None - -DdNode * -Cudd_addFindMin( - DdManager * dd, - DdNode * f -) - Returns a pointer to a constant ADD. - - Side Effects: None - -DdNode * -Cudd_addGeneralVectorCompose( - DdManager * dd, - DdNode * f, - DdNode ** vectorOn, - DdNode ** vectorOff -) - Given a vector of ADDs, creates a new ADD by substituting the ADDs for the - variables of the ADD f. vectorOn contains ADDs to be substituted for the x_v - and vectorOff the ADDs to be substituted for x_v'. There should be an entry - in vector for each variable in the manager. If no substitution is sought for - a given variable, the corresponding projection function should be specified - in the vector. This function implements simultaneous composition. Returns a - pointer to the resulting ADD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addHamming( - DdManager * dd, - DdNode ** xVars, - DdNode ** yVars, - int nVars -) - Computes the Hamming distance ADD. Returns an ADD that gives the Hamming - distance between its two arguments if successful; NULL otherwise. The two - vectors xVars and yVars identify the variables that form the two arguments. - - Side Effects: None - -int -Cudd_addHarwell( - FILE * fp, pointer to the input file - DdManager * dd, DD manager - DdNode ** E, characteristic function of the graph - DdNode *** x, array of row variables - DdNode *** y, array of column variables - DdNode *** xn, array of complemented row variables - DdNode *** yn_, array of complemented column variables - int * nx, number or row variables - int * ny, number or column variables - int * m, number of rows - int * n, number of columns - int bx, first index of row variables - int sx, step of row variables - int by, first index of column variables - int sy, step of column variables - int pr verbosity level -) - Reads in a matrix in the format of the Harwell-Boeing benchmark suite. The - variables are ordered as follows: x[0] y[0] x[1] y[1] ... - 0 is the most significant bit. On input, nx and ny hold the - numbers of row and column variables already in existence. On output, they - hold the numbers of row and column variables actually used by the matrix. m - and n are set to the numbers of rows and columns of the matrix. Their values - on input are immaterial. Returns 1 on success; 0 otherwise. The ADD for the - sparse matrix is returned in E, and its reference count is > 0. - - Side Effects: None - -DdNode * -Cudd_addIteConstant( - DdManager * dd, - DdNode * f, - DdNode * g, - DdNode * h -) - Implements ITEconstant for ADDs. f must be a 0-1 ADD. Returns a pointer to - the resulting ADD (which may or may not be constant) or DD_NON_CONSTANT. No - new nodes are created. This function can be used, for instance, to check - that g has a constant value (specified by h) whenever f is 1. If the - constant value is unknown, then one should use Cudd_addEvalConst. - - Side Effects: None - -DdNode * -Cudd_addIte( - DdManager * dd, - DdNode * f, - DdNode * g, - DdNode * h -) - Implements ITE(f,g,h). This procedure assumes that f is a 0-1 ADD. Returns a - pointer to the resulting ADD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addIthBit( - DdManager * dd, - DdNode * f, - int bit -) - Produces an ADD from another ADD by replacing all discriminants whose i-th - bit is equal to 1 with 1, and all other discriminants with 0. The i-th bit - refers to the integer representation of the leaf value. If the value is has - a fractional part, it is ignored. Repeated calls to this procedure allow one - to transform an integer-valued ADD into an array of ADDs, one for each bit - of the leaf values. Returns a pointer to the resulting ADD if successful; - NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addIthVar( - DdManager * dd, - int i -) - Retrieves the ADD variable with index i if it already exists, or creates a - new ADD variable. Returns a pointer to the variable if successful; NULL - otherwise. An ADD variable differs from a BDD variable because it points to - the arithmetic zero, instead of having a complement pointer to 1. - - Side Effects: None - -int -Cudd_addLeq( - DdManager * dd, - DdNode * f, - DdNode * g -) - Returns 1 if f is less than or equal to g; 0 otherwise. No new nodes are - created. This procedure works for arbitrary ADDs. For 0-1 ADDs - Cudd_addEvalConst is more efficient. - - Side Effects: None - -DdNode * -Cudd_addLog( - DdManager * dd, - DdNode * f -) - Natural logarithm of an ADDs. Returns NULL if not a terminal case; log(f) - otherwise. The discriminants of f must be positive double's. - - Side Effects: None - -DdNode * -Cudd_addMatrixMultiply( - DdManager * dd, - DdNode * A, - DdNode * B, - DdNode ** z, - int nz -) - Calculates the product of two matrices, A and B, represented as ADDs. This - procedure implements the quasiring multiplication algorithm. A is assumed to - depend on variables x (rows) and z (columns). B is assumed to depend on - variables z (rows) and y (columns). The product of A and B then depends on x - (rows) and y (columns). Only the z variables have to be explicitly - identified; they are the "summation" variables. Returns a pointer to the - result if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addMaximum( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - Integer and floating point max for Cudd_addApply. Returns NULL if not a - terminal case; max(f,g) otherwise. - - Side Effects: None - -DdNode * -Cudd_addMinimum( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - Integer and floating point min for Cudd_addApply. Returns NULL if not a - terminal case; min(f,g) otherwise. - - Side Effects: None - -DdNode * -Cudd_addMinus( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - Integer and floating point subtraction. Returns NULL if not a terminal case; - f - g otherwise. - - Side Effects: None - -DdNode * -Cudd_addMonadicApply( - DdManager * dd, - DD_MAOP op, - DdNode * f -) - Applies op to the discriminants of f. Returns a pointer to the result if - succssful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addNand( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - NAND of two 0-1 ADDs. Returns NULL if not a terminal case; f NAND g - otherwise. - - Side Effects: None - -DdNode * -Cudd_addNegate( - DdManager * dd, - DdNode * f -) - Computes the additive inverse of an ADD. Returns a pointer to the result if - successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addNewVarAtLevel( - DdManager * dd, - int level -) - Creates a new ADD variable. The new variable has an index equal to the - largest previous index plus 1 and is positioned at the specified level in - the order. Returns a pointer to the new variable if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_addNewVar( - DdManager * dd -) - Creates a new ADD variable. The new variable has an index equal to the - largest previous index plus 1. Returns a pointer to the new variable if - successful; NULL otherwise. An ADD variable differs from a BDD variable - because it points to the arithmetic zero, instead of having a complement - pointer to 1. - - Side Effects: None - -DdNode * -Cudd_addNonSimCompose( - DdManager * dd, - DdNode * f, - DdNode ** vector -) - Given a vector of 0-1 ADDs, creates a new ADD by substituting the 0-1 ADDs - for the variables of the ADD f. There should be an entry in vector for each - variable in the manager. This function implements non-simultaneous - composition. If any of the functions being composed depends on any of the - variables being substituted, then the result depends on the order of - composition, which in turn depends on the variable order: The variables - farther from the roots in the order are substituted first. Returns a pointer - to the resulting ADD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addNor( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - NOR of two 0-1 ADDs. Returns NULL if not a terminal case; f NOR g otherwise. - - Side Effects: None - -DdNode * -Cudd_addOneZeroMaximum( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - Returns 1 if f > g and 0 otherwise. Used in conjunction with - Cudd_addApply. Returns NULL if not a terminal case. - - Side Effects: None - -DdNode * -Cudd_addOrAbstract( - DdManager * manager, - DdNode * f, - DdNode * cube -) - Abstracts all the variables in cube from the 0-1 ADD f by taking the - disjunction over all possible values taken by the variables. Returns the - abstracted ADD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addOr( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - Disjunction of two 0-1 ADDs. Returns NULL if not a terminal case; f OR g - otherwise. - - Side Effects: None - -DdNode * -Cudd_addOuterSum( - DdManager * dd, - DdNode * M, - DdNode * r, - DdNode * c -) - Takes the pointwise minimum of a matrix and the outer sum of two vectors. - This procedure is used in the Floyd-Warshall all-pair shortest path - algorithm. Returns a pointer to the result if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addPermute( - DdManager * manager, - DdNode * node, - int * permut -) - Given a permutation in array permut, creates a new ADD with permuted - variables. There should be an entry in array permut for each variable in the - manager. The i-th entry of permut holds the index of the variable that is to - substitute the i-th variable. Returns a pointer to the resulting ADD if - successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addPlus( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - Integer and floating point addition. Returns NULL if not a terminal case; - f+g otherwise. - - Side Effects: None - -int -Cudd_addRead( - FILE * fp, input file pointer - DdManager * dd, DD manager - DdNode ** E, characteristic function of the graph - DdNode *** x, array of row variables - DdNode *** y, array of column variables - DdNode *** xn, array of complemented row variables - DdNode *** yn_, array of complemented column variables - int * nx, number or row variables - int * ny, number or column variables - int * m, number of rows - int * n, number of columns - int bx, first index of row variables - int sx, step of row variables - int by, first index of column variables - int sy step of column variables -) - Reads in a sparse matrix specified in a simple format. The first line of the - input contains the numbers of rows and columns. The remaining lines contain - the elements of the matrix, one per line. Given a background value - (specified by the background field of the manager), only the values - different from it are explicitly listed. Each foreground element is - described by two integers, i.e., the row and column number, and a real - number, i.e., the value. Cudd_addRead produces an ADD that depends on two - sets of variables: x and y. The x variables (x[0] ... x[nx-1]) encode the - row index and the y variables (y[0] ... y[ny-1]) encode the column index. - x[0] and y[0] are the most significant bits in the indices. The variables - may already exist or may be created by the function. The index of x[i] is - bx+i*sx, and the index of y[i] is by+i*sy. On input, nx and ny hold the - numbers of row and column variables already in existence. On output, they - hold the numbers of row and column variables actually used by the matrix. - When Cudd_addRead creates the variable arrays, the index of x[i] is bx+i*sx, - and the index of y[i] is by+i*sy. When some variables already exist - Cudd_addRead expects the indices of the existing x variables to be bx+i*sx, - and the indices of the existing y variables to be by+i*sy. m and n are - set to the numbers of rows and columns of the matrix. Their values on input - are immaterial. The ADD for the sparse matrix is returned in E, and its - reference count is > 0. Cudd_addRead returns 1 in case of success; 0 - otherwise. - - Side Effects: nx and ny are set to the numbers of row and column variables. - m and n are set to the numbers of rows and columns. x and y are possibly - extended to represent the array of row and column variables. Similarly for - xn and yn_, which hold on return from Cudd_addRead the complements of the - row and column variables. - -DdNode * -Cudd_addResidue( - DdManager * dd, manager - int n, number of bits - int m, modulus - int options, options - int top index of top variable -) - Builds an ADD for the residue modulo m of an n-bit number. The modulus must - be at least 2, and the number of bits at least 1. Parameter options - specifies whether the MSB should be on top or the LSB; and whther the number - whose residue is computed is in two's complement notation or not. The macro - CUDD_RESIDUE_DEFAULT specifies LSB on top and unsigned number. The macro - CUDD_RESIDUE_MSB specifies MSB on top, and the macro CUDD_RESIDUE_TC - specifies two's complement residue. To request MSB on top and two's - complement residue simultaneously, one can OR the two macros: - CUDD_RESIDUE_MSB | CUDD_RESIDUE_TC. Cudd_addResidue returns a pointer to the - resulting ADD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addRestrict( - DdManager * dd, - DdNode * f, - DdNode * c -) - ADD restrict according to Coudert and Madre's algorithm (ICCAD90). Returns - the restricted ADD if successful; otherwise NULL. If application of restrict - results in an ADD larger than the input ADD, the input ADD is returned. - - Side Effects: None - -DdNode * -Cudd_addRoundOff( - DdManager * dd, - DdNode * f, - int N -) - Rounds off the discriminants of an ADD. The discriminants are rounded off to - N digits after the decimal. Returns a pointer to the result ADD if - successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addScalarInverse( - DdManager * dd, - DdNode * f, - DdNode * epsilon -) - Computes an n ADD where the discriminants are the multiplicative inverses of - the corresponding discriminants of the argument ADD. Returns a pointer to - the resulting ADD in case of success. Returns NULL if any discriminants - smaller than epsilon is encountered. - - Side Effects: None - -DdNode * -Cudd_addSetNZ( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - This operator sets f to the value of g wherever g != 0. Returns NULL if not - a terminal case; f op g otherwise. - - Side Effects: None - -DdNode * -Cudd_addSwapVariables( - DdManager * dd, - DdNode * f, - DdNode ** x, - DdNode ** y, - int n -) - Swaps two sets of variables of the same size (x and y) in the ADD f. The - size is given by n. The two sets of variables are assumed to be disjoint. - Returns a pointer to the resulting ADD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addThreshold( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - Threshold operator for Apply (f if f >=g; 0 if f<g). Returns NULL if - not a terminal case; f op g otherwise. - - Side Effects: None - -DdNode * -Cudd_addTimesPlus( - DdManager * dd, - DdNode * A, - DdNode * B, - DdNode ** z, - int nz -) - Calculates the product of two matrices, A and B, represented as ADDs, using - the CMU matrix by matrix multiplication procedure by Clarke et al.. Matrix A - has x's as row variables and z's as column variables, while matrix B has z's - as row variables and y's as column variables. Returns the pointer to the - result if successful; NULL otherwise. The resulting matrix has x's as row - variables and y's as column variables. - - Side Effects: None - -DdNode * -Cudd_addTimes( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - Integer and floating point multiplication. Returns NULL if not a terminal - case; f * g otherwise. This function can be used also to take the AND of two - 0-1 ADDs. - - Side Effects: None - -DdNode * -Cudd_addTriangle( - DdManager * dd, - DdNode * f, - DdNode * g, - DdNode ** z, - int nz -) - Implements the semiring multiplication algorithm used in the triangulation - step for the shortest path computation. f is assumed to depend on variables - x (rows) and z (columns). g is assumed to depend on variables z (rows) and y - (columns). The product of f and g then depends on x (rows) and y (columns). - Only the z variables have to be explicitly identified; they are the - "abstraction" variables. Returns a pointer to the result if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_addUnivAbstract( - DdManager * manager, - DdNode * f, - DdNode * cube -) - Abstracts all the variables in cube from f by taking the product over all - possible values taken by the variable. Returns the abstracted ADD if - successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addVectorCompose( - DdManager * dd, - DdNode * f, - DdNode ** vector -) - Given a vector of 0-1 ADDs, creates a new ADD by substituting the 0-1 ADDs - for the variables of the ADD f. There should be an entry in vector for each - variable in the manager. If no substitution is sought for a given variable, - the corresponding projection function should be specified in the vector. - This function implements simultaneous composition. Returns a pointer to the - resulting ADD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addWalsh( - DdManager * dd, - DdNode ** x, - DdNode ** y, - int n -) - Generates a Walsh matrix in ADD form. Returns a pointer to the matrixi if - successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_addXeqy( - DdManager * dd, DD manager - int N, number of x and y variables - DdNode ** x, array of x variables - DdNode ** y array of y variables -) - This function generates an ADD for the function x==y. Both x and y are N-bit - numbers, x[0] x[1] ... x[N-1] and y[0] y[1] ... y[N-1], with 0 the most - significant bit. The ADD is built bottom-up. It has 3*N-1 internal nodes, if - the variables are ordered as follows: x[0] y[0] x[1] y[1] ... x[N-1] y[N-1]. - - Side Effects: None - -DdNode * -Cudd_addXnor( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - XNOR of two 0-1 ADDs. Returns NULL if not a terminal case; f XNOR g - otherwise. - - Side Effects: None - -DdNode * -Cudd_addXor( - DdManager * dd, - DdNode ** f, - DdNode ** g -) - XOR of two 0-1 ADDs. Returns NULL if not a terminal case; f XOR g otherwise. - - Side Effects: None - -DdNode * -Cudd_bddAdjPermuteX( - DdManager * dd, - DdNode * B, - DdNode ** x, - int n -) - Rearranges a set of variables in the BDD B. The size of the set is given by - n. This procedure is intended for the `randomization' of the priority - functions. Returns a pointer to the BDD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_bddAndAbstractLimit( - DdManager * manager, - DdNode * f, - DdNode * g, - DdNode * cube, - unsigned int limit -) - Takes the AND of two BDDs and simultaneously abstracts the variables in - cube. The variables are existentially abstracted. Returns a pointer to the - result is successful; NULL otherwise. In particular, if the number of new - nodes created exceeds limit, this function returns NULL. - - Side Effects: None - -DdNode * -Cudd_bddAndAbstract( - DdManager * manager, - DdNode * f, - DdNode * g, - DdNode * cube -) - Takes the AND of two BDDs and simultaneously abstracts the variables in - cube. The variables are existentially abstracted. Returns a pointer to the - result is successful; NULL otherwise. Cudd_bddAndAbstract implements the - semiring matrix multiplication algorithm for the boolean semiring. - - Side Effects: None - -DdNode * -Cudd_bddAndLimit( - DdManager * dd, - DdNode * f, - DdNode * g, - unsigned int limit -) - Computes the conjunction of two BDDs f and g. Returns a pointer to the - resulting BDD if successful; NULL if the intermediate result blows up or - more new nodes than limit are required. - - Side Effects: None - -DdNode * -Cudd_bddAnd( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes the conjunction of two BDDs f and g. Returns a pointer to the - resulting BDD if successful; NULL if the intermediate result blows up. - - Side Effects: None - -int -Cudd_bddApproxConjDecomp( - DdManager * dd, manager - DdNode * f, function to be decomposed - DdNode *** conjuncts address of the first factor -) - Performs two-way conjunctive decomposition of a BDD. This procedure owes its - name to the use of supersetting to obtain an initial factor of the given - function. Returns the number of conjuncts produced, that is, 2 if - successful; 1 if no meaningful decomposition was found; 0 otherwise. The - conjuncts produced by this procedure tend to be imbalanced. - - Side Effects: The factors are returned in an array as side effects. The - array is allocated by this function. It is the caller's responsibility to - free it. On successful completion, the conjuncts are already referenced. If - the function returns 0, the array for the conjuncts is not allocated. If the - function returns 1, the only factor equals the function to be decomposed. - -int -Cudd_bddApproxDisjDecomp( - DdManager * dd, manager - DdNode * f, function to be decomposed - DdNode *** disjuncts address of the array of the disjuncts -) - Performs two-way disjunctive decomposition of a BDD. Returns the number of - disjuncts produced, that is, 2 if successful; 1 if no meaningful - decomposition was found; 0 otherwise. The disjuncts produced by this - procedure tend to be imbalanced. - - Side Effects: The two disjuncts are returned in an array as side effects. - The array is allocated by this function. It is the caller's responsibility - to free it. On successful completion, the disjuncts are already referenced. - If the function returns 0, the array for the disjuncts is not allocated. If - the function returns 1, the only factor equals the function to be - decomposed. - -int -Cudd_bddBindVar( - DdManager * dd, manager - int index variable index -) - This function sets a flag to prevent sifting of a variable. Returns 1 if - successful; 0 otherwise (i.e., invalid variable index). - - Side Effects: Changes the "bindVar" flag in DdSubtable. - -DdNode * -Cudd_bddBooleanDiff( - DdManager * manager, - DdNode * f, - int x -) - Computes the boolean difference of f with respect to the variable with index - x. Returns the BDD of the boolean difference if successful; NULL otherwise. - - Side Effects: None - -DdNode ** -Cudd_bddCharToVect( - DdManager * dd, - DdNode * f -) - Computes a vector of BDDs whose image equals a non-zero function. The result - depends on the variable order. The i-th component of the vector depends only - on the first i variables in the order. Each BDD in the vector is not larger - than the BDD of the given characteristic function. This function is based on - the description of char-to-vect in "Verification of Sequential Machines - Using Boolean Functional Vectors" by O. Coudert, C. Berthet and J. C. Madre. - Returns a pointer to an array containing the result if successful; NULL - otherwise. The size of the array equals the number of variables in the - manager. The components of the solution have their reference counts already - incremented (unlike the results of most other functions in the package). - - Side Effects: None - -DdNode * -Cudd_bddClippingAndAbstract( - DdManager * dd, manager - DdNode * f, first conjunct - DdNode * g, second conjunct - DdNode * cube, cube of variables to be abstracted - int maxDepth, maximum recursion depth - int direction under (0) or over (1) approximation -) - Approximates the conjunction of two BDDs f and g and simultaneously - abstracts the variables in cube. The variables are existentially abstracted. - Returns a pointer to the resulting BDD if successful; NULL if the - intermediate result blows up. - - Side Effects: None - -DdNode * -Cudd_bddClippingAnd( - DdManager * dd, manager - DdNode * f, first conjunct - DdNode * g, second conjunct - int maxDepth, maximum recursion depth - int direction under (0) or over (1) approximation -) - Approximates the conjunction of two BDDs f and g. Returns a pointer to the - resulting BDD if successful; NULL if the intermediate result blows up. - - Side Effects: None - -DdNode * -Cudd_bddClosestCube( - DdManager * dd, - DdNode * f, - DdNode * g, - int * distance -) - Finds a cube of f at minimum Hamming distance from the minterms of g. All - the minterms of the cube are at the minimum distance. If the distance is 0, - the cube belongs to the intersection of f and g. Returns the cube if - successful; NULL otherwise. - - Side Effects: The distance is returned as a side effect. - -DdNode * -Cudd_bddCompose( - DdManager * dd, - DdNode * f, - DdNode * g, - int v -) - Substitutes g for x_v in the BDD for f. v is the index of the variable to be - substituted. Cudd_bddCompose passes the corresponding projection function to - the recursive procedure, so that the cache may be used. Returns the composed - BDD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_bddComputeCube( - DdManager * dd, - DdNode ** vars, - int * phase, - int n -) - Computes the cube of an array of BDD variables. If non-null, the phase - argument indicates which literal of each variable should appear in the cube. - If phase[i] is nonzero, then the positive literal is used. If phase is NULL, - the cube is positive unate. Returns a pointer to the result if successful; - NULL otherwise. - - Side Effects: None - -DdNode ** -Cudd_bddConstrainDecomp( - DdManager * dd, - DdNode * f -) - BDD conjunctive decomposition as in McMillan's CAV96 paper. The - decomposition is canonical only for a given variable order. If canonicity is - required, variable ordering must be disabled after the decomposition has - been computed. Returns an array with one entry for each BDD variable in the - manager if successful; otherwise NULL. The components of the solution have - their reference counts already incremented (unlike the results of most other - functions in the package). - - Side Effects: None - -DdNode * -Cudd_bddConstrain( - DdManager * dd, - DdNode * f, - DdNode * c -) - Computes f constrain c (f @ c). Uses a canonical form: (f' @ c) = (f @ c)'. - (Note: this is not true for c.) List of special cases: f @ 0 = 0 - f @ 1 = f 0 @ c = 0 1 @ c = 1 f @ f = 1 f @ f'= 0 - Returns a pointer to the result if successful; NULL otherwise. Note - that if F=(f1,...,fn) and reordering takes place while computing F @ c, then - the image restriction property (Img(F,c) = Img(F @ c)) is lost. - - Side Effects: None - -double -Cudd_bddCorrelationWeights( - DdManager * manager, - DdNode * f, - DdNode * g, - double * prob -) - Computes the correlation of f and g for given input probabilities. On input, - prob[i] is supposed to contain the probability of the i-th input variable to - be 1. If f == g, their correlation is 1. If f == g', their correlation is 0. - Returns the probability that f and g have the same value. If it runs out of - memory, returns (double)CUDD_OUT_OF_MEM. The correlation of f and the - constant one gives the probability of f. - - Side Effects: None - -double -Cudd_bddCorrelation( - DdManager * manager, - DdNode * f, - DdNode * g -) - Computes the correlation of f and g. If f == g, their correlation is 1. If f - == g', their correlation is 0. Returns the fraction of minterms in the ON- - set of the EXNOR of f and g. If it runs out of memory, returns - (double)CUDD_OUT_OF_MEM. - - Side Effects: None - -DdNode * -Cudd_bddExistAbstractLimit( - DdManager * manager, - DdNode * f, - DdNode * cube, - unsigned int limit -) - Existentially abstracts all the variables in cube from f. Returns the - abstracted BDD if successful; NULL if the intermediate result blows up or - more new nodes than limit are required. - - Side Effects: None - -DdNode * -Cudd_bddExistAbstract( - DdManager * manager, - DdNode * f, - DdNode * cube -) - Existentially abstracts all the variables in cube from f. Returns the - abstracted BDD if successful; NULL otherwise. - - Side Effects: None - -int -Cudd_bddGenConjDecomp( - DdManager * dd, manager - DdNode * f, function to be decomposed - DdNode *** conjuncts address of the array of conjuncts -) - Performs two-way conjunctive decomposition of a BDD. This procedure owes its - name to the fact tht it generalizes the decomposition based on the cofactors - with respect to one variable. Returns the number of conjuncts produced, that - is, 2 if successful; 1 if no meaningful decomposition was found; 0 - otherwise. The conjuncts produced by this procedure tend to be balanced. - - Side Effects: The two factors are returned in an array as side effects. The - array is allocated by this function. It is the caller's responsibility to - free it. On successful completion, the conjuncts are already referenced. If - the function returns 0, the array for the conjuncts is not allocated. If the - function returns 1, the only factor equals the function to be decomposed. - -int -Cudd_bddGenDisjDecomp( - DdManager * dd, manager - DdNode * f, function to be decomposed - DdNode *** disjuncts address of the array of the disjuncts -) - Performs two-way disjunctive decomposition of a BDD. Returns the number of - disjuncts produced, that is, 2 if successful; 1 if no meaningful - decomposition was found; 0 otherwise. The disjuncts produced by this - procedure tend to be balanced. - - Side Effects: The two disjuncts are returned in an array as side effects. - The array is allocated by this function. It is the caller's responsibility - to free it. On successful completion, the disjuncts are already referenced. - If the function returns 0, the array for the disjuncts is not allocated. If - the function returns 1, the only factor equals the function to be - decomposed. - -DdNode * -Cudd_bddIntersect( - DdManager * dd, manager - DdNode * f, first operand - DdNode * g second operand -) - Computes a function included in the intersection of f and g. (That is, a - witness that the intersection is not empty.) Cudd_bddIntersect tries to - build as few new nodes as possible. If the only result of interest is - whether f and g intersect, Cudd_bddLeq should be used instead. - - Side Effects: None - -DdNode * -Cudd_bddInterval( - DdManager * dd, DD manager - int N, number of x variables - DdNode ** x, array of x variables - unsigned int lowerB, lower bound - unsigned int upperB upper bound -) - This function generates a BDD for the function lowerB ≤ x ≤ upperB, - where x is an N-bit number, x[0] x[1] ... x[N-1], with 0 the most - significant bit (important!). The number of variables N should be sufficient - to represent the bounds; otherwise, the bounds are truncated to their N - least significant bits. Two BDDs are built bottom-up for lowerB ≤ x and x - ≤ upperB, and they are finally conjoined. - - Side Effects: None - -int -Cudd_bddIsNsVar( - DdManager * dd, - int index -) - Checks whether a variable is next state. Returns 1 if the variable's type is - present state; 0 if the variable exists but is not a present state; -1 if - the variable does not exist. - - Side Effects: none - -int -Cudd_bddIsPiVar( - DdManager * dd, manager - int index variable index -) - Checks whether a variable is primary input. Returns 1 if the variable's type - is primary input; 0 if the variable exists but is not a primary input; -1 if - the variable does not exist. - - Side Effects: none - -int -Cudd_bddIsPsVar( - DdManager * dd, - int index -) - Checks whether a variable is present state. Returns 1 if the variable's type - is present state; 0 if the variable exists but is not a present state; -1 if - the variable does not exist. - - Side Effects: none - -int -Cudd_bddIsVarEssential( - DdManager * manager, - DdNode * f, - int id, - int phase -) - Determines whether a given variable is essential with a given phase in a - BDD. Uses Cudd_bddIteConstant. Returns 1 if phase == 1 and f-->x_id, or if - phase == 0 and f-->x_id'. - - Side Effects: None - -int -Cudd_bddIsVarHardGroup( - DdManager * dd, - int index -) - Checks whether a variable is set to be in a hard group. This function is - used for lazy sifting. Returns 1 if the variable is marked to be in a hard - group; 0 if the variable exists, but it is not marked to be in a hard group; - -1 if the variable does not exist. - - Side Effects: none - -int -Cudd_bddIsVarToBeGrouped( - DdManager * dd, - int index -) - Checks whether a variable is set to be grouped. This function is used for - lazy sifting. - - Side Effects: none - -int -Cudd_bddIsVarToBeUngrouped( - DdManager * dd, - int index -) - Checks whether a variable is set to be ungrouped. This function is used for - lazy sifting. Returns 1 if the variable is marked to be ungrouped; 0 if the - variable exists, but it is not marked to be ungrouped; -1 if the variable - does not exist. - - Side Effects: none - -DdNode * -Cudd_bddIsop( - DdManager * dd, - DdNode * L, - DdNode * U -) - Computes a BDD in the interval between L and U with a simple sum-of-product - cover. This procedure is similar to Cudd_zddIsop, but it does not return the - ZDD for the cover. Returns a pointer to the BDD if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_bddIteConstant( - DdManager * dd, - DdNode * f, - DdNode * g, - DdNode * h -) - Implements ITEconstant(f,g,h). Returns a pointer to the resulting BDD (which - may or may not be constant) or DD_NON_CONSTANT. No new nodes are created. - - Side Effects: None - -DdNode * -Cudd_bddIteLimit( - DdManager * dd, - DdNode * f, - DdNode * g, - DdNode * h, - unsigned int limit -) - Implements ITE(f,g,h). Returns a pointer to the resulting BDD if successful; - NULL if the intermediate result blows up or more new nodes than - limit are required. - - Side Effects: None - -int -Cudd_bddIterConjDecomp( - DdManager * dd, manager - DdNode * f, function to be decomposed - DdNode *** conjuncts address of the array of conjuncts -) - Performs two-way conjunctive decomposition of a BDD. This procedure owes its - name to the iterated use of supersetting to obtain a factor of the given - function. Returns the number of conjuncts produced, that is, 2 if - successful; 1 if no meaningful decomposition was found; 0 otherwise. The - conjuncts produced by this procedure tend to be imbalanced. - - Side Effects: The factors are returned in an array as side effects. The - array is allocated by this function. It is the caller's responsibility to - free it. On successful completion, the conjuncts are already referenced. If - the function returns 0, the array for the conjuncts is not allocated. If the - function returns 1, the only factor equals the function to be decomposed. - -int -Cudd_bddIterDisjDecomp( - DdManager * dd, manager - DdNode * f, function to be decomposed - DdNode *** disjuncts address of the array of the disjuncts -) - Performs two-way disjunctive decomposition of a BDD. Returns the number of - disjuncts produced, that is, 2 if successful; 1 if no meaningful - decomposition was found; 0 otherwise. The disjuncts produced by this - procedure tend to be imbalanced. - - Side Effects: The two disjuncts are returned in an array as side effects. - The array is allocated by this function. It is the caller's responsibility - to free it. On successful completion, the disjuncts are already referenced. - If the function returns 0, the array for the disjuncts is not allocated. If - the function returns 1, the only factor equals the function to be - decomposed. - -DdNode * -Cudd_bddIte( - DdManager * dd, - DdNode * f, - DdNode * g, - DdNode * h -) - Implements ITE(f,g,h). Returns a pointer to the resulting BDD if successful; - NULL if the intermediate result blows up. - - Side Effects: None - -DdNode * -Cudd_bddIthVar( - DdManager * dd, - int i -) - Retrieves the BDD variable with index i if it already exists, or creates a - new BDD variable. Returns a pointer to the variable if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_bddLICompaction( - DdManager * dd, manager - DdNode * f, function to be minimized - DdNode * c constraint (care set) -) - Performs safe minimization of a BDD. Given the BDD f of a - function to be minimized and a BDD c representing the care set, - Cudd_bddLICompaction produces the BDD of a function that agrees with - f wherever c is 1. Safe minimization means that - the size of the result is guaranteed not to exceed the size of - f. This function is based on the DAC97 paper by Hong et al.. - Returns a pointer to the result if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_bddLargestPrimeUnate( - DdManager * dd, manager - DdNode * f, unate function - DdNode * phaseBdd cube of the phases -) - Find a largest prime implicant of a unate function. Returns the BDD for the - prime if succesful; NULL otherwise. The behavior is undefined if f is not - unate. The third argument is used to determine whether f is unate positive - (increasing) or negative (decreasing) in each of the variables in its - support. - - Side Effects: None - -int -Cudd_bddLeqUnless( - DdManager * dd, - DdNode * f, - DdNode * g, - DdNode * D -) - Tells whether f is less than of equal to G unless D is 1. f, g, and D are - BDDs. The function returns 1 if f is less than of equal to G, and 0 - otherwise. No new nodes are created. - - Side Effects: None - -int -Cudd_bddLeq( - DdManager * dd, - DdNode * f, - DdNode * g -) - Returns 1 if f is less than or equal to g; 0 otherwise. No new nodes are - created. - - Side Effects: None - -DdNode * -Cudd_bddLiteralSetIntersection( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes the intesection of two sets of literals represented as BDDs. Each - set is represented as a cube of the literals in the set. The empty set is - represented by the constant 1. No variable can be simultaneously present in - both phases in a set. Returns a pointer to the BDD representing the - intersected sets, if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_bddMakePrime( - DdManager * dd, manager - DdNode * cube, cube to be expanded - DdNode * f function of which the cube is to be made - a prime -) - Expands cube to a prime implicant of f. Returns the prime if successful; - NULL otherwise. In particular, NULL is returned if cube is not a real cube - or is not an implicant of f. - - Side Effects: None - -DdNode * -Cudd_bddMaximallyExpand( - DdManager * dd, manager - DdNode * lb, cube to be expanded - DdNode * ub, upper bound cube - DdNode * f function against which to expand -) - Expands lb to all prime implicants of (f and ub) that contain lb. Assumes - that lb is contained in ub. Returns the disjunction of the primes if lb is - contained in f; returns the zero BDD if lb is not contained in f; returns - NULL in case of failure. In particular, NULL is returned if cube is not a - real cube or is not an implicant of f. Returning the disjunction of all - prime implicants works because the resulting function is unate. - - Side Effects: None - -DdNode * -Cudd_bddMinimize( - DdManager * dd, - DdNode * f, - DdNode * c -) - Finds a small BDD that agrees with f over c. - Returns a pointer to the result if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_bddNPAnd( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes f non-polluting-and g. The non-polluting AND of f and g is a hybrid - of AND and Restrict. From Restrict, this operation takes the idea of - existentially quantifying the top variable of the second operand if it does - not appear in the first. Therefore, the variables that appear in the result - also appear in f. For the rest, the function behaves like AND. Since the two - operands play different roles, non-polluting AND is not commutative. Returns - a pointer to the result if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_bddNand( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes the NAND of two BDDs f and g. Returns a pointer to the resulting - BDD if successful; NULL if the intermediate result blows up. - - Side Effects: None - -DdNode * -Cudd_bddNewVarAtLevel( - DdManager * dd, - int level -) - Creates a new BDD variable. The new variable has an index equal to the - largest previous index plus 1 and is positioned at the specified level in - the order. Returns a pointer to the new variable if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_bddNewVar( - DdManager * dd -) - Creates a new BDD variable. The new variable has an index equal to the - largest previous index plus 1. Returns a pointer to the new variable if - successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_bddNor( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes the NOR of two BDDs f and g. Returns a pointer to the resulting BDD - if successful; NULL if the intermediate result blows up. - - Side Effects: None - -DdNode * -Cudd_bddOrLimit( - DdManager * dd, - DdNode * f, - DdNode * g, - unsigned int limit -) - Computes the disjunction of two BDDs f and g. Returns a pointer to the - resulting BDD if successful; NULL if the intermediate result blows up or - more new nodes than limit are required. - - Side Effects: None - -DdNode * -Cudd_bddOr( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes the disjunction of two BDDs f and g. Returns a pointer to the - resulting BDD if successful; NULL if the intermediate result blows up. - - Side Effects: None - -DdNode * -Cudd_bddPermute( - DdManager * manager, - DdNode * node, - int * permut -) - Given a permutation in array permut, creates a new BDD with permuted - variables. There should be an entry in array permut for each variable in the - manager. The i-th entry of permut holds the index of the variable that is to - substitute the i-th variable. Returns a pointer to the resulting BDD if - successful; NULL otherwise. - - Side Effects: None - -DdNode ** -Cudd_bddPickArbitraryMinterms( - DdManager * dd, manager - DdNode * f, function from which to pick k minterms - DdNode ** vars, array of variables - int n, size of vars - int k number of minterms to find -) - Picks k on-set minterms evenly distributed from given DD. The minterms are - in terms of vars. The array vars should contain at - least all variables in the support of f; if this condition is - not met the minterms built by this procedure may not be contained in - f. Builds an array of BDDs for the minterms and returns a - pointer to it if successful; NULL otherwise. There are three reasons why the - procedure may fail: It may run out of memory; the function - f may be the constant 0; the minterms may not be contained - in f. - - Side Effects: None - -int -Cudd_bddPickOneCube( - DdManager * ddm, - DdNode * node, - char * string -) - Picks one on-set cube randomly from the given DD. The cube is written into - an array of characters. The array must have at least as many entries as - there are variables. Returns 1 if successful; 0 otherwise. - - Side Effects: None - -DdNode * -Cudd_bddPickOneMinterm( - DdManager * dd, manager - DdNode * f, function from which to pick one minterm - DdNode ** vars, array of variables - int n size of vars -) - Picks one on-set minterm randomly from the given DD. The minterm is in terms - of vars. The array vars should contain at least - all variables in the support of f; if this condition is not met - the minterm built by this procedure may not be contained in f. - Builds a BDD for the minterm and returns a pointer to it if successful; NULL - otherwise. There are three reasons why the procedure may fail: It - may run out of memory; the function f may be the constant - 0; the minterm may not be contained in f. - - Side Effects: None - -int -Cudd_bddPrintCover( - DdManager * dd, - DdNode * l, - DdNode * u -) - Prints a sum of product cover for an incompletely specified function given - by a lower bound and an upper bound. Each product is a prime implicant - obtained by expanding the product corresponding to a path from node to the - constant one. Uses the package default output file. Returns 1 if successful; - 0 otherwise. - - Side Effects: None - -int -Cudd_bddReadPairIndex( - DdManager * dd, - int index -) - Reads a corresponding pair index for a given index. These pair indices are - present and next state variable. Returns the corresponding variable index if - the variable exists; -1 otherwise. - - Side Effects: modifies the manager - -int -Cudd_bddRead( - FILE * fp, input file pointer - DdManager * dd, DD manager - DdNode ** E, characteristic function of the graph - DdNode *** x, array of row variables - DdNode *** y, array of column variables - int * nx, number or row variables - int * ny, number or column variables - int * m, number of rows - int * n, number of columns - int bx, first index of row variables - int sx, step of row variables - int by, first index of column variables - int sy step of column variables -) - Reads in a graph (without labels) given as an adjacency matrix. The first - line of the input contains the numbers of rows and columns of the adjacency - matrix. The remaining lines contain the arcs of the graph, one per line. - Each arc is described by two integers, i.e., the row and column number, or - the indices of the two endpoints. Cudd_bddRead produces a BDD that depends - on two sets of variables: x and y. The x variables (x[0] ... x[nx-1]) encode - the row index and the y variables (y[0] ... y[ny-1]) encode the column - index. x[0] and y[0] are the most significant bits in the indices. The - variables may already exist or may be created by the function. The index of - x[i] is bx+i*sx, and the index of y[i] is by+i*sy. On input, nx and ny - hold the numbers of row and column variables already in existence. On - output, they hold the numbers of row and column variables actually used by - the matrix. When Cudd_bddRead creates the variable arrays, the index of x[i] - is bx+i*sx, and the index of y[i] is by+i*sy. When some variables already - exist, Cudd_bddRead expects the indices of the existing x variables to be - bx+i*sx, and the indices of the existing y variables to be by+i*sy. m and - n are set to the numbers of rows and columns of the matrix. Their values on - input are immaterial. The BDD for the graph is returned in E, and its - reference count is > 0. Cudd_bddRead returns 1 in case of success; 0 - otherwise. - - Side Effects: nx and ny are set to the numbers of row and column variables. - m and n are set to the numbers of rows and columns. x and y are possibly - extended to represent the array of row and column variables. - -void -Cudd_bddRealignDisable( - DdManager * unique -) - Disables realignment of ZDD order to BDD order. - - Side Effects: None - -void -Cudd_bddRealignEnable( - DdManager * unique -) - Enables realignment of the BDD variable order to the ZDD variable order - after the ZDDs have been reordered. The number of ZDD variables must be a - multiple of the number of BDD variables for realignment to make sense. If - this condition is not met, Cudd_zddReduceHeap will return 0. Let - M be the ratio of the two numbers. For the purpose of - realignment, the ZDD variables from M*i to (M+1)*i- - 1 are reagarded as corresponding to BDD variable i. - Realignment is initially disabled. - - Side Effects: None - -int -Cudd_bddRealignmentEnabled( - DdManager * unique -) - Returns 1 if the realignment of BDD order to ZDD order is enabled; 0 - otherwise. - - Side Effects: None - -int -Cudd_bddResetVarToBeGrouped( - DdManager * dd, - int index -) - Resets a variable not to be grouped. This function is used for lazy sifting. - Returns 1 if successful; 0 otherwise. - - Side Effects: modifies the manager - -DdNode * -Cudd_bddRestrict( - DdManager * dd, - DdNode * f, - DdNode * c -) - BDD restrict according to Coudert and Madre's algorithm (ICCAD90). Returns - the restricted BDD if successful; otherwise NULL. If application of restrict - results in a BDD larger than the input BDD, the input BDD is returned. - - Side Effects: None - -int -Cudd_bddSetNsVar( - DdManager * dd, manager - int index variable index -) - Sets a variable type to next state. The variable type is used by lazy - sifting. Returns 1 if successful; 0 otherwise. - - Side Effects: modifies the manager - -int -Cudd_bddSetPairIndex( - DdManager * dd, manager - int index, variable index - int pairIndex corresponding variable index -) - Sets a corresponding pair index for a given index. These pair indices are - present and next state variable. Returns 1 if successful; 0 otherwise. - - Side Effects: modifies the manager - -int -Cudd_bddSetPiVar( - DdManager * dd, manager - int index variable index -) - Sets a variable type to primary input. The variable type is used by lazy - sifting. Returns 1 if successful; 0 otherwise. - - Side Effects: modifies the manager - -int -Cudd_bddSetPsVar( - DdManager * dd, manager - int index variable index -) - Sets a variable type to present state. The variable type is used by lazy - sifting. Returns 1 if successful; 0 otherwise. - - Side Effects: modifies the manager - -int -Cudd_bddSetVarHardGroup( - DdManager * dd, - int index -) - Sets a variable to be a hard group. This function is used for lazy sifting. - Returns 1 if successful; 0 otherwise. - - Side Effects: modifies the manager - -int -Cudd_bddSetVarToBeGrouped( - DdManager * dd, - int index -) - Sets a variable to be grouped. This function is used for lazy sifting. - Returns 1 if successful; 0 otherwise. - - Side Effects: modifies the manager - -int -Cudd_bddSetVarToBeUngrouped( - DdManager * dd, - int index -) - Sets a variable to be ungrouped. This function is used for lazy sifting. - Returns 1 if successful; 0 otherwise. - - Side Effects: modifies the manager - -DdNode * -Cudd_bddSqueeze( - DdManager * dd, manager - DdNode * l, lower bound - DdNode * u upper bound -) - Finds a small BDD in a function interval. Given BDDs l and - u, representing the lower bound and upper bound of a function - interval, Cudd_bddSqueeze produces the BDD of a function within the interval - with a small BDD. Returns a pointer to the result if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_bddSwapVariables( - DdManager * dd, - DdNode * f, - DdNode ** x, - DdNode ** y, - int n -) - Swaps two sets of variables of the same size (x and y) in the BDD f. The - size is given by n. The two sets of variables are assumed to be disjoint. - Returns a pointer to the resulting BDD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_bddTransfer( - DdManager * ddSource, - DdManager * ddDestination, - DdNode * f -) - Convert a BDD from a manager to another one. The orders of the variables in - the two managers may be different. Returns a pointer to the BDD in the - destination manager if successful; NULL otherwise. - - Side Effects: None - -int -Cudd_bddUnbindVar( - DdManager * dd, manager - int index variable index -) - This function resets the flag that prevents the sifting of a variable. In - successive variable reorderings, the variable will NOT be skipped, that is, - sifted. Initially all variables can be sifted. It is necessary to call this - function only to re-enable sifting after a call to Cudd_bddBindVar. Returns - 1 if successful; 0 otherwise (i.e., invalid variable index). - - Side Effects: Changes the "bindVar" flag in DdSubtable. - -DdNode * -Cudd_bddUnivAbstract( - DdManager * manager, - DdNode * f, - DdNode * cube -) - Universally abstracts all the variables in cube from f. Returns the - abstracted BDD if successful; NULL otherwise. - - Side Effects: None - -int -Cudd_bddVarConjDecomp( - DdManager * dd, manager - DdNode * f, function to be decomposed - DdNode *** conjuncts address of the array of conjuncts -) - Conjunctively decomposes one BDD according to a variable. If f - is the function of the BDD and x is the variable, the - decomposition is (f+x)(f+x'). The variable is chosen so as to - balance the sizes of the two conjuncts and to keep them small. Returns the - number of conjuncts produced, that is, 2 if successful; 1 if no meaningful - decomposition was found; 0 otherwise. - - Side Effects: The two factors are returned in an array as side effects. The - array is allocated by this function. It is the caller's responsibility to - free it. On successful completion, the conjuncts are already referenced. If - the function returns 0, the array for the conjuncts is not allocated. If the - function returns 1, the only factor equals the function to be decomposed. - -int -Cudd_bddVarDisjDecomp( - DdManager * dd, manager - DdNode * f, function to be decomposed - DdNode *** disjuncts address of the array of the disjuncts -) - Performs two-way disjunctive decomposition of a BDD according to a variable. - If f is the function of the BDD and x is the - variable, the decomposition is f*x + f*x'. The variable is - chosen so as to balance the sizes of the two disjuncts and to keep them - small. Returns the number of disjuncts produced, that is, 2 if successful; 1 - if no meaningful decomposition was found; 0 otherwise. - - Side Effects: The two disjuncts are returned in an array as side effects. - The array is allocated by this function. It is the caller's responsibility - to free it. On successful completion, the disjuncts are already referenced. - If the function returns 0, the array for the disjuncts is not allocated. If - the function returns 1, the only factor equals the function to be - decomposed. - -int -Cudd_bddVarIsBound( - DdManager * dd, manager - int index variable index -) - This function returns 1 if a variable is enabled for sifting. Initially all - variables can be sifted. This function returns 0 only if there has been a - previous call to Cudd_bddBindVar for that variable not followed by a call to - Cudd_bddUnbindVar. The function returns 0 also in the case in which the - index of the variable is out of bounds. - - Side Effects: none - -int -Cudd_bddVarIsDependent( - DdManager * dd, - DdNode * f, - DdNode * var variable -) - Checks whether a variable is dependent on others in a function. Returns 1 if - the variable is dependent; 0 otherwise. No new nodes are created. - - Side Effects: None - -DdNode * -Cudd_bddVarMap( - DdManager * manager, DD manager - DdNode * f function in which to remap variables -) - Remaps the variables of a BDD using the default variable map. A typical use - of this function is to swap two sets of variables. The variable map must be - registered with Cudd_SetVarMap. Returns a pointer to the resulting BDD if - successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_bddVectorCompose( - DdManager * dd, - DdNode * f, - DdNode ** vector -) - Given a vector of BDDs, creates a new BDD by substituting the BDDs for the - variables of the BDD f. There should be an entry in vector for each variable - in the manager. If no substitution is sought for a given variable, the - corresponding projection function should be specified in the vector. This - function implements simultaneous composition. Returns a pointer to the - resulting BDD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_bddXnorLimit( - DdManager * dd, - DdNode * f, - DdNode * g, - unsigned int limit -) - Computes the exclusive NOR of two BDDs f and g. Returns a pointer to the - resulting BDD if successful; NULL if the intermediate result blows up or - more new nodes than limit are required. - - Side Effects: None - -DdNode * -Cudd_bddXnor( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes the exclusive NOR of two BDDs f and g. Returns a pointer to the - resulting BDD if successful; NULL if the intermediate result blows up. - - Side Effects: None - -DdNode * -Cudd_bddXorExistAbstract( - DdManager * manager, - DdNode * f, - DdNode * g, - DdNode * cube -) - Takes the exclusive OR of two BDDs and simultaneously abstracts the - variables in cube. The variables are existentially abstracted. Returns a - pointer to the result is successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_bddXor( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes the exclusive OR of two BDDs f and g. Returns a pointer to the - resulting BDD if successful; NULL if the intermediate result blows up. - - Side Effects: None - -void -Cudd_tlcInfoFree( - DdTlcInfo * t -) - Frees a DdTlcInfo Structure as well as the memory pointed by it. - - Side Effects: None - -DdNode * -Cudd_zddChange( - DdManager * dd, - DdNode * P, - int var -) - Substitutes a variable with its complement in a ZDD. returns a pointer to - the result if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_zddComplement( - DdManager * dd, - DdNode * node -) - Computes a complement cover for a ZDD node. For lack of a better method, we - first extract the function BDD from the ZDD cover, then make the complement - of the ZDD cover from the complement of the BDD node by using ISOP. Returns - a pointer to the resulting cover if successful; NULL otherwise. The result - depends on current variable order. - - Side Effects: The result depends on current variable order. - -double -Cudd_zddCountDouble( - DdManager * zdd, - DdNode * P -) - Counts the number of minterms of a ZDD. The result is returned as a double. - If the procedure runs out of memory, it returns (double) CUDD_OUT_OF_MEM. - This procedure is used in Cudd_zddCountMinterm. - - Side Effects: None - -double -Cudd_zddCountMinterm( - DdManager * zdd, - DdNode * node, - int path -) - Counts the number of minterms of the ZDD rooted at node. This - procedure takes a parameter path that specifies how many - variables are in the support of the function. If the procedure runs out of - memory, it returns (double) CUDD_OUT_OF_MEM. - - Side Effects: None - -int -Cudd_zddCount( - DdManager * zdd, - DdNode * P -) - Returns an integer representing the number of minterms in a ZDD. - - Side Effects: None - -char * -Cudd_zddCoverPathToString( - DdManager * zdd, DD manager - int * path, path of ZDD representing a cover - char * str pointer to string to use if != NULL -) - Converts a path of a ZDD representing a cover to a string. The string - represents an implicant of the cover. The path is typically produced by - Cudd_zddForeachPath. Returns a pointer to the string if successful; NULL - otherwise. If the str input is NULL, it allocates a new string. The string - passed to this function must have enough room for all variables and for the - terminator. - - Side Effects: None - -int -Cudd_zddDagSize( - DdNode * p_node -) - Counts the number of nodes in a ZDD. This function duplicates Cudd_DagSize - and is only retained for compatibility. - - Side Effects: None - -DdNode * -Cudd_zddDiffConst( - DdManager * zdd, - DdNode * P, - DdNode * Q -) - Inclusion test for ZDDs (P implies Q). No new nodes are generated by this - procedure. Returns empty if true; a valid pointer different from empty or - DD_NON_CONSTANT otherwise. - - Side Effects: None - -DdNode * -Cudd_zddDiff( - DdManager * dd, - DdNode * P, - DdNode * Q -) - Computes the difference of two ZDDs. Returns a pointer to the result if - successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_zddDivideF( - DdManager * dd, - DdNode * f, - DdNode * g -) - Modified version of Cudd_zddDivide. This function may disappear in future - releases. - - Side Effects: None - -DdNode * -Cudd_zddDivide( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes the quotient of two unate covers represented by ZDDs. Unate covers - use one ZDD variable for each BDD variable. Returns a pointer to the - resulting ZDD if successful; NULL otherwise. - - Side Effects: None - -int -Cudd_zddDumpDot( - DdManager * dd, manager - int n, number of output nodes to be dumped - DdNode ** f, array of output nodes to be dumped - char ** inames, array of input names (or NULL) - char ** onames, array of output names (or NULL) - FILE * fp pointer to the dump file -) - Writes a file representing the argument ZDDs in a format suitable for the - graph drawing program dot. It returns 1 in case of success; 0 otherwise - (e.g., out-of-memory, file system full). Cudd_zddDumpDot does not close the - file: This is the caller responsibility. Cudd_zddDumpDot uses a minimal - unique subset of the hexadecimal address of a node as name for it. If the - argument inames is non-null, it is assumed to hold the pointers to the names - of the inputs. Similarly for onames. Cudd_zddDumpDot uses the following - convention to draw arcs: solid line: THEN arcs; dashed line: - ELSE arcs. The dot options are chosen so that the drawing fits on a - letter-size sheet. - - Side Effects: None - -DdGen * -Cudd_zddFirstPath( - DdManager * zdd, - DdNode * f, - int ** path -) - Defines an iterator on the paths of a ZDD and finds its first path. Returns - a generator that contains the information necessary to continue the - enumeration if successful; NULL otherwise. A path is represented as an - array of literals, which are integers in {0, 1, 2}; 0 represents an else arc - out of a node, 1 represents a then arc out of a node, and 2 stands for the - absence of a node. The size of the array equals the number of variables in - the manager at the time Cudd_zddFirstCube is called. The paths that end - in the empty terminal are not enumerated. - - Side Effects: The first path is returned as a side effect. - -DdNode * -Cudd_zddIntersect( - DdManager * dd, - DdNode * P, - DdNode * Q -) - Computes the intersection of two ZDDs. Returns a pointer to the result if - successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_zddIsop( - DdManager * dd, - DdNode * L, - DdNode * U, - DdNode ** zdd_I -) - Computes an irredundant sum of products (ISOP) in ZDD form from BDDs. The - two BDDs L and U represent the lower bound and the upper bound, - respectively, of the function. The ISOP uses two ZDD variables for each BDD - variable: One for the positive literal, and one for the negative literal. - These two variables should be adjacent in the ZDD order. The two ZDD - variables corresponding to BDD variable i should have indices - 2i and 2i+1. The result of this procedure depends - on the variable order. If successful, Cudd_zddIsop returns the BDD for the - function chosen from the interval. The ZDD representing the irredundant - cover is returned as a side effect in zdd_I. In case of failure, NULL is - returned. - - Side Effects: zdd_I holds the pointer to the ZDD for the ISOP on successful - return. - -DdNode * -Cudd_zddIte( - DdManager * dd, - DdNode * f, - DdNode * g, - DdNode * h -) - Computes the ITE of three ZDDs. Returns a pointer to the result if - successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_zddIthVar( - DdManager * dd, - int i -) - Retrieves the ZDD variable with index i if it already exists, or creates a - new ZDD variable. Returns a pointer to the variable if successful; NULL - otherwise. - - Side Effects: None - -int -Cudd_zddNextPath( - DdGen * gen, - int ** path -) - Generates the next path of a ZDD onset, using generator gen. Returns 0 if - the enumeration is completed; 1 otherwise. - - Side Effects: The path is returned as a side effect. The generator is - modified. - -DdNode * -Cudd_zddPortFromBdd( - DdManager * dd, - DdNode * B -) - Converts a BDD into a ZDD. This function assumes that there is a one-to-one - correspondence between the BDD variables and the ZDD variables, and that the - variable order is the same for both types of variables. These conditions are - established if the ZDD variables are created by one call to - Cudd_zddVarsFromBddVars with multiplicity = 1. Returns a pointer to the - resulting ZDD if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_zddPortToBdd( - DdManager * dd, - DdNode * f -) - Converts a ZDD into a BDD. Returns a pointer to the resulting ZDD if - successful; NULL otherwise. - - Side Effects: None - -int -Cudd_zddPrintCover( - DdManager * zdd, - DdNode * node -) - Prints a sum of products from a ZDD representing a cover. Returns 1 if - successful; 0 otherwise. - - Side Effects: None - -int -Cudd_zddPrintDebug( - DdManager * zdd, - DdNode * f, - int n, - int pr -) - Prints to the standard output a DD and its statistics. The statistics - include the number of nodes and the number of minterms. (The number of - minterms is also the number of combinations in the set.) The statistics are - printed if pr > 0. Specifically: pr = 0 : prints nothing - pr = 1 : prints counts of nodes and minterms pr = 2 : prints counts + - disjoint sum of products pr = 3 : prints counts + list of nodes pr - > 3 : prints counts + disjoint sum of products + list of nodes - Returns 1 if successful; 0 otherwise. - - Side Effects: None - -int -Cudd_zddPrintMinterm( - DdManager * zdd, - DdNode * node -) - Prints a disjoint sum of product form for a ZDD. Returns 1 if successful; 0 - otherwise. - - Side Effects: None - -void -Cudd_zddPrintSubtable( - DdManager * table -) - Prints the ZDD table for debugging purposes. - - Side Effects: None - -DdNode * -Cudd_zddProduct( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes the product of two covers represented by ZDDs. The result is also a - ZDD. Returns a pointer to the result if successful; NULL otherwise. The - covers on which Cudd_zddProduct operates use two ZDD variables for each - function variable (one ZDD variable for each literal of the variable). Those - two ZDD variables should be adjacent in the order. - - Side Effects: None - -long -Cudd_zddReadNodeCount( - DdManager * dd -) - Reports the number of nodes in ZDDs. This number always includes the two - constants 1 and 0. - - Side Effects: None - -void -Cudd_zddRealignDisable( - DdManager * unique -) - Disables realignment of ZDD order to BDD order. - - Side Effects: None - -void -Cudd_zddRealignEnable( - DdManager * unique -) - Enables realignment of the ZDD variable order to the BDD variable order - after the BDDs and ADDs have been reordered. The number of ZDD variables - must be a multiple of the number of BDD variables for realignment to make - sense. If this condition is not met, Cudd_ReduceHeap will return 0. Let - M be the ratio of the two numbers. For the purpose of - realignment, the ZDD variables from M*i to (M+1)*i- - 1 are reagarded as corresponding to BDD variable i. - Realignment is initially disabled. - - Side Effects: None - -int -Cudd_zddRealignmentEnabled( - DdManager * unique -) - Returns 1 if the realignment of ZDD order to BDD order is enabled; 0 - otherwise. - - Side Effects: None - -int -Cudd_zddReduceHeap( - DdManager * table, DD manager - Cudd_ReorderingTy heuristic, method used for reordering - int minsize bound below which no reordering occurs -) - Main dynamic reordering routine for ZDDs. Calls one of the possible - reordering procedures: Swapping Sifting Symmetric Sifting - For sifting and symmetric sifting it is possible to request reordering - to convergence. The core of all methods is the reordering procedure - cuddZddSwapInPlace() which swaps two adjacent variables. Returns 1 in case - of success; 0 otherwise. In the case of symmetric sifting (with and without - convergence) returns 1 plus the number of symmetric variables, in case of - success. - - Side Effects: Changes the variable order for all ZDDs and clears the cache. - -int -Cudd_zddShuffleHeap( - DdManager * table, DD manager - int * permutation required variable permutation -) - Reorders ZDD variables according to given permutation. The i-th entry of the - permutation array contains the index of the variable that should be brought - to the i-th level. The size of the array should be equal or greater to the - number of variables currently in use. Returns 1 in case of success; 0 - otherwise. - - Side Effects: Changes the ZDD variable order for all diagrams and clears the - cache. - -DdNode * -Cudd_zddSubset0( - DdManager * dd, - DdNode * P, - int var -) - Computes the negative cofactor of a ZDD w.r.t. a variable. In terms of - combinations, the result is the set of all combinations in which the - variable is negated. Returns a pointer to the result if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_zddSubset1( - DdManager * dd, - DdNode * P, - int var -) - Computes the positive cofactor of a ZDD w.r.t. a variable. In terms of - combinations, the result is the set of all combinations in which the - variable is asserted. Returns a pointer to the result if successful; NULL - otherwise. - - Side Effects: None - -DdNode * -Cudd_zddSupport( - DdManager * dd, manager - DdNode * f ZDD whose support is sought -) - Finds the variables on which a ZDD depends. Returns a BDD consisting of the - product of the variables if successful; NULL otherwise. - - Side Effects: None - -void -Cudd_zddSymmProfile( - DdManager * table, - int lower, - int upper -) - Prints statistics on symmetric ZDD variables. - - Side Effects: None - -DdNode * -Cudd_zddUnateProduct( - DdManager * dd, - DdNode * f, - DdNode * g -) - Computes the product of two unate covers represented as ZDDs. Unate covers - use one ZDD variable for each BDD variable. Returns a pointer to the result - if successful; NULL otherwise. - - Side Effects: None - -DdNode * -Cudd_zddUnion( - DdManager * dd, - DdNode * P, - DdNode * Q -) - Computes the union of two ZDDs. Returns a pointer to the result if - successful; NULL otherwise. - - Side Effects: None - -int -Cudd_zddVarsFromBddVars( - DdManager * dd, DD manager - int multiplicity how many ZDD variables are created for - each BDD variable -) - Creates one or more ZDD variables for each BDD variable. If some ZDD - variables already exist, only the missing variables are created. Parameter - multiplicity allows the caller to control how many variables are created for - each BDD variable in existence. For instance, if ZDDs are used to represent - covers, two ZDD variables are required for each BDD variable. The order of - the BDD variables is transferred to the ZDD variables. If a variable group - tree exists for the BDD variables, a corresponding ZDD variable group tree - is created by expanding the BDD variable tree. In any case, the ZDD - variables derived from the same BDD variable are merged in a ZDD variable - group. If a ZDD variable group tree exists, it is freed. Returns 1 if - successful; 0 otherwise. - - Side Effects: None - -DdNode * -Cudd_zddWeakDivF( - DdManager * dd, - DdNode * f, - DdNode * g -) - Modified version of Cudd_zddWeakDiv. This function may disappear in future - releases. - - Side Effects: None - -DdNode * -Cudd_zddWeakDiv( - DdManager * dd, - DdNode * f, - DdNode * g -) - Applies weak division to two ZDDs representing two covers. Returns a pointer - to the ZDD representing the result if successful; NULL otherwise. The result - of weak division depends on the variable order. The covers on which - Cudd_zddWeakDiv operates use two ZDD variables for each function variable - (one ZDD variable for each literal of the variable). Those two ZDD variables - should be adjacent in the order. - - Side Effects: None - -writing ./cuddTitle.html diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cudd.ps b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cudd.ps deleted file mode 100644 index 0a12057cc..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cudd.ps +++ /dev/null @@ -1,5036 +0,0 @@ -%!PS-Adobe-2.0 -%%Creator: dvips(k) 5.92b Copyright 2002 Radical Eye Software -%%Title: cudd.dvi -%%Pages: 48 -%%PageOrder: Ascend -%%BoundingBox: 0 0 612 792 -%%DocumentFonts: Times-Roman CMMI12 Times-Bold Times-Italic CMSY10 CMR10 -%%+ CMMI10 CMMI8 Courier CMSY8 CMR8 Times-BoldItalic -%%EndComments -%DVIPSWebPage: (www.radicaleye.com) -%DVIPSCommandLine: dvips -o cudd.ps cudd -%DVIPSParameters: dpi=600, compressed -%DVIPSSource: TeX output 2012.02.04:1929 -%%BeginProcSet: texc.pro -%! -/TeXDict 300 dict def TeXDict begin/N{def}def/B{bind def}N/S{exch}N/X{S -N}B/A{dup}B/TR{translate}N/isls false N/vsize 11 72 mul N/hsize 8.5 72 -mul N/landplus90{false}def/@rigin{isls{[0 landplus90{1 -1}{-1 1}ifelse 0 -0 0]concat}if 72 Resolution div 72 VResolution div neg scale isls{ -landplus90{VResolution 72 div vsize mul 0 exch}{Resolution -72 div hsize -mul 0}ifelse TR}if Resolution VResolution vsize -72 div 1 add mul TR[ -matrix currentmatrix{A A round sub abs 0.00001 lt{round}if}forall round -exch round exch]setmatrix}N/@landscape{/isls true N}B/@manualfeed{ -statusdict/manualfeed true put}B/@copies{/#copies X}B/FMat[1 0 0 -1 0 0] -N/FBB[0 0 0 0]N/nn 0 N/IEn 0 N/ctr 0 N/df-tail{/nn 8 dict N nn begin -/FontType 3 N/FontMatrix fntrx N/FontBBox FBB N string/base X array -/BitMaps X/BuildChar{CharBuilder}N/Encoding IEn N end A{/foo setfont}2 -array copy cvx N load 0 nn put/ctr 0 N[}B/sf 0 N/df{/sf 1 N/fntrx FMat N -df-tail}B/dfs{div/sf X/fntrx[sf 0 0 sf neg 0 0]N df-tail}B/E{pop nn A -definefont setfont}B/Cw{Cd A length 5 sub get}B/Ch{Cd A length 4 sub get -}B/Cx{128 Cd A length 3 sub get sub}B/Cy{Cd A length 2 sub get 127 sub} -B/Cdx{Cd A length 1 sub get}B/Ci{Cd A type/stringtype ne{ctr get/ctr ctr -1 add N}if}B/id 0 N/rw 0 N/rc 0 N/gp 0 N/cp 0 N/G 0 N/CharBuilder{save 3 -1 roll S A/base get 2 index get S/BitMaps get S get/Cd X pop/ctr 0 N Cdx -0 Cx Cy Ch sub Cx Cw add Cy setcachedevice Cw Ch true[1 0 0 -1 -.1 Cx -sub Cy .1 sub]/id Ci N/rw Cw 7 add 8 idiv string N/rc 0 N/gp 0 N/cp 0 N{ -rc 0 ne{rc 1 sub/rc X rw}{G}ifelse}imagemask restore}B/G{{id gp get/gp -gp 1 add N A 18 mod S 18 idiv pl S get exec}loop}B/adv{cp add/cp X}B -/chg{rw cp id gp 4 index getinterval putinterval A gp add/gp X adv}B/nd{ -/cp 0 N rw exit}B/lsh{rw cp 2 copy get A 0 eq{pop 1}{A 255 eq{pop 254}{ -A A add 255 and S 1 and or}ifelse}ifelse put 1 adv}B/rsh{rw cp 2 copy -get A 0 eq{pop 128}{A 255 eq{pop 127}{A 2 idiv S 128 and or}ifelse} -ifelse put 1 adv}B/clr{rw cp 2 index string putinterval adv}B/set{rw cp -fillstr 0 4 index getinterval putinterval adv}B/fillstr 18 string 0 1 17 -{2 copy 255 put pop}for N/pl[{adv 1 chg}{adv 1 chg nd}{1 add chg}{1 add -chg nd}{adv lsh}{adv lsh nd}{adv rsh}{adv rsh nd}{1 add adv}{/rc X nd}{ -1 add set}{1 add clr}{adv 2 chg}{adv 2 chg nd}{pop nd}]A{bind pop} -forall N/D{/cc X A type/stringtype ne{]}if nn/base get cc ctr put nn -/BitMaps get S ctr S sf 1 ne{A A length 1 sub A 2 index S get sf div put -}if put/ctr ctr 1 add N}B/I{cc 1 add D}B/bop{userdict/bop-hook known{ -bop-hook}if/SI save N @rigin 0 0 moveto/V matrix currentmatrix A 1 get A -mul exch 0 get A mul add .99 lt{/QV}{/RV}ifelse load def pop pop}N/eop{ -SI restore userdict/eop-hook known{eop-hook}if showpage}N/@start{ -userdict/start-hook known{start-hook}if pop/VResolution X/Resolution X -1000 div/DVImag X/IEn 256 array N 2 string 0 1 255{IEn S A 360 add 36 4 -index cvrs cvn put}for pop 65781.76 div/vsize X 65781.76 div/hsize X}N -/p{show}N/RMat[1 0 0 -1 0 0]N/BDot 260 string N/Rx 0 N/Ry 0 N/V{}B/RV/v{ -/Ry X/Rx X V}B statusdict begin/product where{pop false[(Display)(NeXT) -(LaserWriter 16/600)]{A length product length le{A length product exch 0 -exch getinterval eq{pop true exit}if}{pop}ifelse}forall}{false}ifelse -end{{gsave TR -.1 .1 TR 1 1 scale Rx Ry false RMat{BDot}imagemask -grestore}}{{gsave TR -.1 .1 TR Rx Ry scale 1 1 false RMat{BDot} -imagemask grestore}}ifelse B/QV{gsave newpath transform round exch round -exch itransform moveto Rx 0 rlineto 0 Ry neg rlineto Rx neg 0 rlineto -fill grestore}B/a{moveto}B/delta 0 N/tail{A/delta X 0 rmoveto}B/M{S p -delta add tail}B/b{S p tail}B/c{-4 M}B/d{-3 M}B/e{-2 M}B/f{-1 M}B/g{0 M} -B/h{1 M}B/i{2 M}B/j{3 M}B/k{4 M}B/w{0 rmoveto}B/l{p -4 w}B/m{p -3 w}B/n{ -p -2 w}B/o{p -1 w}B/q{p 1 w}B/r{p 2 w}B/s{p 3 w}B/t{p 4 w}B/x{0 S -rmoveto}B/y{3 2 roll p a}B/bos{/SS save N}B/eos{SS restore}B end - -%%EndProcSet -%%BeginProcSet: 8r.enc -% File 8r.enc as of 2002-03-12 for PSNFSS 9 -% -% This is the encoding vector for Type1 and TrueType fonts to be used -% with TeX. This file is part of the PSNFSS bundle, version 9 -% -% Authors: S. Rahtz, P. MacKay, Alan Jeffrey, B. Horn, K. Berry, W. Schmidt -% -% Idea is to have all the characters normally included in Type 1 fonts -% available for typesetting. This is effectively the characters in Adobe -% Standard Encoding + ISO Latin 1 + extra characters from Lucida + Euro. -% -% Character code assignments were made as follows: -% -% (1) the Windows ANSI characters are almost all in their Windows ANSI -% positions, because some Windows users cannot easily reencode the -% fonts, and it makes no difference on other systems. The only Windows -% ANSI characters not available are those that make no sense for -% typesetting -- rubout (127 decimal), nobreakspace (160), softhyphen -% (173). quotesingle and grave are moved just because it's such an -% irritation not having them in TeX positions. -% -% (2) Remaining characters are assigned arbitrarily to the lower part -% of the range, avoiding 0, 10 and 13 in case we meet dumb software. -% -% (3) Y&Y Lucida Bright includes some extra text characters; in the -% hopes that other PostScript fonts, perhaps created for public -% consumption, will include them, they are included starting at 0x12. -% -% (4) Remaining positions left undefined are for use in (hopefully) -% upward-compatible revisions, if someday more characters are generally -% available. -% -% (5) hyphen appears twice for compatibility with both ASCII and Windows. -% -% (6) /Euro is assigned to 128, as in Windows ANSI -% -/TeXBase1Encoding [ -% 0x00 (encoded characters from Adobe Standard not in Windows 3.1) - /.notdef /dotaccent /fi /fl - /fraction /hungarumlaut /Lslash /lslash - /ogonek /ring /.notdef - /breve /minus /.notdef -% These are the only two remaining unencoded characters, so may as -% well include them. - /Zcaron /zcaron -% 0x10 - /caron /dotlessi -% (unusual TeX characters available in, e.g., Lucida Bright) - /dotlessj /ff /ffi /ffl - /.notdef /.notdef /.notdef /.notdef - /.notdef /.notdef /.notdef /.notdef - % very contentious; it's so painful not having quoteleft and quoteright - % at 96 and 145 that we move the things normally found there down to here. - /grave /quotesingle -% 0x20 (ASCII begins) - /space /exclam /quotedbl /numbersign - /dollar /percent /ampersand /quoteright - /parenleft /parenright /asterisk /plus /comma /hyphen /period /slash -% 0x30 - /zero /one /two /three /four /five /six /seven - /eight /nine /colon /semicolon /less /equal /greater /question -% 0x40 - /at /A /B /C /D /E /F /G /H /I /J /K /L /M /N /O -% 0x50 - /P /Q /R /S /T /U /V /W - /X /Y /Z /bracketleft /backslash /bracketright /asciicircum /underscore -% 0x60 - /quoteleft /a /b /c /d /e /f /g /h /i /j /k /l /m /n /o -% 0x70 - /p /q /r /s /t /u /v /w - /x /y /z /braceleft /bar /braceright /asciitilde - /.notdef % rubout; ASCII ends -% 0x80 - /Euro /.notdef /quotesinglbase /florin - /quotedblbase /ellipsis /dagger /daggerdbl - /circumflex /perthousand /Scaron /guilsinglleft - /OE /.notdef /.notdef /.notdef -% 0x90 - /.notdef /.notdef /.notdef /quotedblleft - /quotedblright /bullet /endash /emdash - /tilde /trademark /scaron /guilsinglright - /oe /.notdef /.notdef /Ydieresis -% 0xA0 - /.notdef % nobreakspace - /exclamdown /cent /sterling - /currency /yen /brokenbar /section - /dieresis /copyright /ordfeminine /guillemotleft - /logicalnot - /hyphen % Y&Y (also at 45); Windows' softhyphen - /registered - /macron -% 0xD0 - /degree /plusminus /twosuperior /threesuperior - /acute /mu /paragraph /periodcentered - /cedilla /onesuperior /ordmasculine /guillemotright - /onequarter /onehalf /threequarters /questiondown -% 0xC0 - /Agrave /Aacute /Acircumflex /Atilde /Adieresis /Aring /AE /Ccedilla - /Egrave /Eacute /Ecircumflex /Edieresis - /Igrave /Iacute /Icircumflex /Idieresis -% 0xD0 - /Eth /Ntilde /Ograve /Oacute - /Ocircumflex /Otilde /Odieresis /multiply - /Oslash /Ugrave /Uacute /Ucircumflex - /Udieresis /Yacute /Thorn /germandbls -% 0xE0 - /agrave /aacute /acircumflex /atilde - /adieresis /aring /ae /ccedilla - /egrave /eacute /ecircumflex /edieresis - /igrave /iacute /icircumflex /idieresis -% 0xF0 - /eth /ntilde /ograve /oacute - /ocircumflex /otilde /odieresis /divide - /oslash /ugrave /uacute /ucircumflex - /udieresis /yacute /thorn /ydieresis -] def - -%%EndProcSet -%%BeginProcSet: texps.pro -%! -TeXDict begin/rf{findfont dup length 1 add dict begin{1 index/FID ne 2 -index/UniqueID ne and{def}{pop pop}ifelse}forall[1 index 0 6 -1 roll -exec 0 exch 5 -1 roll VResolution Resolution div mul neg 0 0]FontType 0 -ne{/Metrics exch def dict begin Encoding{exch dup type/integertype ne{ -pop pop 1 sub dup 0 le{pop}{[}ifelse}{FontMatrix 0 get div Metrics 0 get -div def}ifelse}forall Metrics/Metrics currentdict end def}{{1 index type -/nametype eq{exit}if exch pop}loop}ifelse[2 index currentdict end -definefont 3 -1 roll makefont/setfont cvx]cvx def}def/ObliqueSlant{dup -sin S cos div neg}B/SlantFont{4 index mul add}def/ExtendFont{3 -1 roll -mul exch}def/ReEncodeFont{CharStrings rcheck{/Encoding false def dup[ -exch{dup CharStrings exch known not{pop/.notdef/Encoding true def}if} -forall Encoding{]exch pop}{cleartomark}ifelse}if/Encoding exch def}def -end - -%%EndProcSet -%%BeginProcSet: special.pro -%! -TeXDict begin/SDict 200 dict N SDict begin/@SpecialDefaults{/hs 612 N -/vs 792 N/ho 0 N/vo 0 N/hsc 1 N/vsc 1 N/ang 0 N/CLIP 0 N/rwiSeen false N -/rhiSeen false N/letter{}N/note{}N/a4{}N/legal{}N}B/@scaleunit 100 N -/@hscale{@scaleunit div/hsc X}B/@vscale{@scaleunit div/vsc X}B/@hsize{ -/hs X/CLIP 1 N}B/@vsize{/vs X/CLIP 1 N}B/@clip{/CLIP 2 N}B/@hoffset{/ho -X}B/@voffset{/vo X}B/@angle{/ang X}B/@rwi{10 div/rwi X/rwiSeen true N}B -/@rhi{10 div/rhi X/rhiSeen true N}B/@llx{/llx X}B/@lly{/lly X}B/@urx{ -/urx X}B/@ury{/ury X}B/magscale true def end/@MacSetUp{userdict/md known -{userdict/md get type/dicttype eq{userdict begin md length 10 add md -maxlength ge{/md md dup length 20 add dict copy def}if end md begin -/letter{}N/note{}N/legal{}N/od{txpose 1 0 mtx defaultmatrix dtransform S -atan/pa X newpath clippath mark{transform{itransform moveto}}{transform{ -itransform lineto}}{6 -2 roll transform 6 -2 roll transform 6 -2 roll -transform{itransform 6 2 roll itransform 6 2 roll itransform 6 2 roll -curveto}}{{closepath}}pathforall newpath counttomark array astore/gc xdf -pop ct 39 0 put 10 fz 0 fs 2 F/|______Courier fnt invertflag{PaintBlack} -if}N/txpose{pxs pys scale ppr aload pop por{noflips{pop S neg S TR pop 1 --1 scale}if xflip yflip and{pop S neg S TR 180 rotate 1 -1 scale ppr 3 -get ppr 1 get neg sub neg ppr 2 get ppr 0 get neg sub neg TR}if xflip -yflip not and{pop S neg S TR pop 180 rotate ppr 3 get ppr 1 get neg sub -neg 0 TR}if yflip xflip not and{ppr 1 get neg ppr 0 get neg TR}if}{ -noflips{TR pop pop 270 rotate 1 -1 scale}if xflip yflip and{TR pop pop -90 rotate 1 -1 scale ppr 3 get ppr 1 get neg sub neg ppr 2 get ppr 0 get -neg sub neg TR}if xflip yflip not and{TR pop pop 90 rotate ppr 3 get ppr -1 get neg sub neg 0 TR}if yflip xflip not and{TR pop pop 270 rotate ppr -2 get ppr 0 get neg sub neg 0 S TR}if}ifelse scaleby96{ppr aload pop 4 --1 roll add 2 div 3 1 roll add 2 div 2 copy TR .96 dup scale neg S neg S -TR}if}N/cp{pop pop showpage pm restore}N end}if}if}N/normalscale{ -Resolution 72 div VResolution 72 div neg scale magscale{DVImag dup scale -}if 0 setgray}N/psfts{S 65781.76 div N}N/startTexFig{/psf$SavedState -save N userdict maxlength dict begin/magscale true def normalscale -currentpoint TR/psf$ury psfts/psf$urx psfts/psf$lly psfts/psf$llx psfts -/psf$y psfts/psf$x psfts currentpoint/psf$cy X/psf$cx X/psf$sx psf$x -psf$urx psf$llx sub div N/psf$sy psf$y psf$ury psf$lly sub div N psf$sx -psf$sy scale psf$cx psf$sx div psf$llx sub psf$cy psf$sy div psf$ury sub -TR/showpage{}N/erasepage{}N/setpagedevice{pop}N/copypage{}N/p 3 def -@MacSetUp}N/doclip{psf$llx psf$lly psf$urx psf$ury currentpoint 6 2 roll -newpath 4 copy 4 2 roll moveto 6 -1 roll S lineto S lineto S lineto -closepath clip newpath moveto}N/endTexFig{end psf$SavedState restore}N -/@beginspecial{SDict begin/SpecialSave save N gsave normalscale -currentpoint TR @SpecialDefaults count/ocount X/dcount countdictstack N} -N/@setspecial{CLIP 1 eq{newpath 0 0 moveto hs 0 rlineto 0 vs rlineto hs -neg 0 rlineto closepath clip}if ho vo TR hsc vsc scale ang rotate -rwiSeen{rwi urx llx sub div rhiSeen{rhi ury lly sub div}{dup}ifelse -scale llx neg lly neg TR}{rhiSeen{rhi ury lly sub div dup scale llx neg -lly neg TR}if}ifelse CLIP 2 eq{newpath llx lly moveto urx lly lineto urx -ury lineto llx ury lineto closepath clip}if/showpage{}N/erasepage{}N -/setpagedevice{pop}N/copypage{}N newpath}N/@endspecial{count ocount sub{ -pop}repeat countdictstack dcount sub{end}repeat grestore SpecialSave -restore end}N/@defspecial{SDict begin}N/@fedspecial{end}B/li{lineto}B -/rl{rlineto}B/rc{rcurveto}B/np{/SaveX currentpoint/SaveY X N 1 -setlinecap newpath}N/st{stroke SaveX SaveY moveto}N/fil{fill SaveX SaveY -moveto}N/ellipse{/endangle X/startangle X/yrad X/xrad X/savematrix -matrix currentmatrix N TR xrad yrad scale 0 0 1 startangle endangle arc -savematrix setmatrix}N end - -%%EndProcSet -%%BeginProcSet: color.pro -%! -TeXDict begin/setcmykcolor where{pop}{/setcmykcolor{dup 10 eq{pop -setrgbcolor}{1 sub 4 1 roll 3{3 index add neg dup 0 lt{pop 0}if 3 1 roll -}repeat setrgbcolor pop}ifelse}B}ifelse/TeXcolorcmyk{setcmykcolor}def -/TeXcolorrgb{setrgbcolor}def/TeXcolorgrey{setgray}def/TeXcolorgray{ -setgray}def/TeXcolorhsb{sethsbcolor}def/currentcmykcolor where{pop}{ -/currentcmykcolor{currentrgbcolor 10}B}ifelse/DC{exch dup userdict exch -known{pop pop}{X}ifelse}B/GreenYellow{0.15 0 0.69 0 setcmykcolor}DC -/Yellow{0 0 1 0 setcmykcolor}DC/Goldenrod{0 0.10 0.84 0 setcmykcolor}DC -/Dandelion{0 0.29 0.84 0 setcmykcolor}DC/Apricot{0 0.32 0.52 0 -setcmykcolor}DC/Peach{0 0.50 0.70 0 setcmykcolor}DC/Melon{0 0.46 0.50 0 -setcmykcolor}DC/YellowOrange{0 0.42 1 0 setcmykcolor}DC/Orange{0 0.61 -0.87 0 setcmykcolor}DC/BurntOrange{0 0.51 1 0 setcmykcolor}DC -/Bittersweet{0 0.75 1 0.24 setcmykcolor}DC/RedOrange{0 0.77 0.87 0 -setcmykcolor}DC/Mahogany{0 0.85 0.87 0.35 setcmykcolor}DC/Maroon{0 0.87 -0.68 0.32 setcmykcolor}DC/BrickRed{0 0.89 0.94 0.28 setcmykcolor}DC/Red{ -0 1 1 0 setcmykcolor}DC/OrangeRed{0 1 0.50 0 setcmykcolor}DC/RubineRed{ -0 1 0.13 0 setcmykcolor}DC/WildStrawberry{0 0.96 0.39 0 setcmykcolor}DC -/Salmon{0 0.53 0.38 0 setcmykcolor}DC/CarnationPink{0 0.63 0 0 -setcmykcolor}DC/Magenta{0 1 0 0 setcmykcolor}DC/VioletRed{0 0.81 0 0 -setcmykcolor}DC/Rhodamine{0 0.82 0 0 setcmykcolor}DC/Mulberry{0.34 0.90 -0 0.02 setcmykcolor}DC/RedViolet{0.07 0.90 0 0.34 setcmykcolor}DC -/Fuchsia{0.47 0.91 0 0.08 setcmykcolor}DC/Lavender{0 0.48 0 0 -setcmykcolor}DC/Thistle{0.12 0.59 0 0 setcmykcolor}DC/Orchid{0.32 0.64 0 -0 setcmykcolor}DC/DarkOrchid{0.40 0.80 0.20 0 setcmykcolor}DC/Purple{ -0.45 0.86 0 0 setcmykcolor}DC/Plum{0.50 1 0 0 setcmykcolor}DC/Violet{ -0.79 0.88 0 0 setcmykcolor}DC/RoyalPurple{0.75 0.90 0 0 setcmykcolor}DC -/BlueViolet{0.86 0.91 0 0.04 setcmykcolor}DC/Periwinkle{0.57 0.55 0 0 -setcmykcolor}DC/CadetBlue{0.62 0.57 0.23 0 setcmykcolor}DC -/CornflowerBlue{0.65 0.13 0 0 setcmykcolor}DC/MidnightBlue{0.98 0.13 0 -0.43 setcmykcolor}DC/NavyBlue{0.94 0.54 0 0 setcmykcolor}DC/RoyalBlue{1 -0.50 0 0 setcmykcolor}DC/Blue{1 1 0 0 setcmykcolor}DC/Cerulean{0.94 0.11 -0 0 setcmykcolor}DC/Cyan{1 0 0 0 setcmykcolor}DC/ProcessBlue{0.96 0 0 0 -setcmykcolor}DC/SkyBlue{0.62 0 0.12 0 setcmykcolor}DC/Turquoise{0.85 0 -0.20 0 setcmykcolor}DC/TealBlue{0.86 0 0.34 0.02 setcmykcolor}DC -/Aquamarine{0.82 0 0.30 0 setcmykcolor}DC/BlueGreen{0.85 0 0.33 0 -setcmykcolor}DC/Emerald{1 0 0.50 0 setcmykcolor}DC/JungleGreen{0.99 0 -0.52 0 setcmykcolor}DC/SeaGreen{0.69 0 0.50 0 setcmykcolor}DC/Green{1 0 -1 0 setcmykcolor}DC/ForestGreen{0.91 0 0.88 0.12 setcmykcolor}DC -/PineGreen{0.92 0 0.59 0.25 setcmykcolor}DC/LimeGreen{0.50 0 1 0 -setcmykcolor}DC/YellowGreen{0.44 0 0.74 0 setcmykcolor}DC/SpringGreen{ -0.26 0 0.76 0 setcmykcolor}DC/OliveGreen{0.64 0 0.95 0.40 setcmykcolor} -DC/RawSienna{0 0.72 1 0.45 setcmykcolor}DC/Sepia{0 0.83 1 0.70 -setcmykcolor}DC/Brown{0 0.81 1 0.60 setcmykcolor}DC/Tan{0.14 0.42 0.56 0 -setcmykcolor}DC/Gray{0 0 0 0.50 setcmykcolor}DC/Black{0 0 0 1 -setcmykcolor}DC/White{0 0 0 0 setcmykcolor}DC end - -%%EndProcSet -%%BeginFont: CMR8 -%!PS-AdobeFont-1.1: CMR8 1.0 -%%CreationDate: 1991 Aug 20 16:39:40 -% Copyright (C) 1997 American Mathematical Society. All Rights Reserved. -11 dict begin -/FontInfo 7 dict dup begin -/version (1.0) readonly def -/Notice (Copyright (C) 1997 American Mathematical Society. All Rights Reserved) readonly def -/FullName (CMR8) readonly def -/FamilyName (Computer Modern) readonly def -/Weight (Medium) readonly def -/ItalicAngle 0 def -/isFixedPitch false def -end readonly def -/FontName /CMR8 def -/PaintType 0 def -/FontType 1 def -/FontMatrix [0.001 0 0 0.001 0 0] readonly def -/Encoding 256 array -0 1 255 {1 index exch /.notdef put} for -dup 48 /zero put -dup 49 /one put -dup 50 /two put -dup 51 /three put -readonly def -/FontBBox{-36 -250 1070 750}readonly def -/UniqueID 5000791 def -currentdict end -currentfile eexec -D9D66F633B846A97B686A97E45A3D0AA052A014267B7904EB3C0D3BD0B83D891 -016CA6CA4B712ADEB258FAAB9A130EE605E61F77FC1B738ABC7C51CD46EF8171 -9098D5FEE67660E69A7AB91B58F29A4D79E57022F783EB0FBBB6D4F4EC35014F -D2DECBA99459A4C59DF0C6EBA150284454E707DC2100C15B76B4C19B84363758 -469A6C558785B226332152109871A9883487DD7710949204DDCF837E6A8708B8 -2BDBF16FBC7512FAA308A093FE5CF4E9D2405B169CD5365D6ECED5D768D66D6C -68618B8C482B341F8CA38E9BB9BAFCFAAD9C2F3FD033B62690986ED43D9C9361 -3645B82392D5CAE11A7CB49D7E2E82DCD485CBA1772CE422BB1D7283AD675B65 -48A7EA0069A883EC1DAA3E1F9ECE7586D6CF0A128CD557C7E5D7AA3EA97EBAD3 -9619D1BFCF4A6D64768741EDEA0A5B0EFBBF347CDCBE2E03D756967A16B613DB -0FC45FA2A3312E0C46A5FD0466AB097C58FFEEC40601B8395E52775D0AFCD7DB -8AB317333110531E5C44A4CB4B5ACD571A1A60960B15E450948A5EEA14DD330F -EA209265DB8E1A1FC80DCD3860323FD26C113B041A88C88A21655878680A4466 -FA10403D24BB97152A49B842C180E4D258C9D48F21D057782D90623116830BA3 -9902B3C5F2F2DD01433B0D7099C07DBDE268D0FFED5169BCD03D48B2F058AD62 -D8678C626DC7A3F352152C99BA963EF95F8AD11DB8B0D351210A17E4C2C55AD8 -9EB64172935D3C20A398F3EEEEC31551966A7438EF3FEE422C6D4E05337620D5 -ACC7B52BED984BFAAD36EF9D20748B05D07BE4414A63975125D272FAD83F76E6 -10FFF8363014BE526D580873C5A42B70FA911EC7B86905F13AFE55EB0273F582 -83158793B8CC296B8DE1DCCF1250FD57CB0E035C7EDA3B0092ED940D37A05493 -2EC54E09B984FCA4AB7D2EA182BCF1263AA244B07EC0EA901C077A059F709F30 -4384CB5FA748F2054FAD9A7A43D4EA427918BD414F766531136B60C3477C6632 -BEFE3897B58C19276A301926C2AEF2756B367319772C9B201C49B4D935A8267B -041D6F1783B6AEA4DAC4F5B3507D7032AA640AAB12E343A4E9BDCF419C04A721 -3888B25AF4E293AACED9A6BDC78E61DA1C424C6503CC1885F762BE0618B16C14 -7386EB4C4B9B3142B9662F48CF5B55DC44261F9F0F975611120F7B9846423136 -B3A568B97F5822B76CF10ECD4CD0C64DC55413CC2E843FB37053EAFE985A98CF -9E408707AB2BBD2F036B622F74397BE4BEFA06A0CC51A30C326C3654B5E548B5 -FD5BE6BFFD05A02E81F12A94892139862012A6776D80F0B7C3E90F8E34918601 -8A6B25676CDD71F0DBD7CF514F0363B15B6C7E62EF9BE227EB164481CC0EF812 -8B8B5FDD0FA1815E629760FDEAA026094F96B05BE963194E99D2E5444F62C26B -1BBAD76672EEC98948B7D9C81CAEBBB7C9CBA16CBDFC595D7AD3F92651B63D50 -CC7E92F4E96C4DE2721AFEE94FBFE5843979D30068BC1F11E5374F6F6EF4586C -AB699727770D97A8681D2E75E907027302832D0834FD7BB48EE89D7F0A39E263 -C34F09602BDEF782A7BCF182CB6D8603E31EF82E669B294BBE9B5AD29CD12FA9 -DD1CAAC8AB4DBB663F8C50472C9D7CF3CFB9AE712D83B306991B89F75A87A6C8 -CF7901236E9EE16204F26C79404A6EB87AC532A29C47C9455D0F3DCCA48E2B26 -1240EB3CD115047EC6C4E3F5B3680127DF7509CD26BEF7C542D0332B2A2F680F -ECAC3A2C958DC3F17576DEBDB9478343EE622DF8C8F7C488ED049690697A6B1D -BAFF45A781099100DD7B0A0598A4A93E088E8B44198EB0DE3761F141AEF45C92 -1A71F32189FEFCC7978570BEBD53305BFB9B68829998196345770721ABAE7410 -50A99976446ABBBF31130CE1A85B4F37B85BBCCD2E31C072B96F005E7506BA7B -6AF46E32CEAB608411DACC4D93ECE77BC4C4282DE8FC4189C8661A93F0A3C0CC -B09077804522B3675B87F45E9E0AB99AFC3F6A979FB2030642DB80CBB4A92BA9 -8FEADF534577FE567839008FEB0F6CD811ACB7CEDCEFC98807636A24B6EDAD43 -83CE013C9E660F3F3DB842554D04B5D8277640A931ED4CC700F8BCFF901775C6 -DBE1A76EE8ADC5601FF1DC4EC663E3E960064875BBCA81F5B82118A055D48C9D -C2DC4C00BB1B42B6C3D00354040080ACAD10EE6A464E5F62E5AC4236FF2D2A6A -BBFE55CD6E55990D15C6A13229F0AB706D61C746EF99E2AF9365 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -cleartomark -%%EndFont -%%BeginFont: CMSY8 -%!PS-AdobeFont-1.1: CMSY8 1.0 -%%CreationDate: 1991 Aug 15 07:22:10 -% Copyright (C) 1997 American Mathematical Society. All Rights Reserved. -11 dict begin -/FontInfo 7 dict dup begin -/version (1.0) readonly def -/Notice (Copyright (C) 1997 American Mathematical Society. All Rights Reserved) readonly def -/FullName (CMSY8) readonly def -/FamilyName (Computer Modern) readonly def -/Weight (Medium) readonly def -/ItalicAngle -14.035 def -/isFixedPitch false def -end readonly def -/FontName /CMSY8 def -/PaintType 0 def -/FontType 1 def -/FontMatrix [0.001 0 0 0.001 0 0] readonly def -/Encoding 256 array -0 1 255 {1 index exch /.notdef put} for -dup 0 /minus put -dup 48 /prime put -readonly def -/FontBBox{-30 -955 1185 779}readonly def -/UniqueID 5000818 def -currentdict end -currentfile eexec -D9D66F633B846A97B686A97E45A3D0AA052F09F9C8ADE9D907C058B87E9B6964 -7D53359E51216774A4EAA1E2B58EC3176BD1184A633B951372B4198D4E8C5EF4 -A213ACB58AA0A658908035BF2ED8531779838A960DFE2B27EA49C37156989C85 -E21B3ABF72E39A89232CD9F4237FC80C9E64E8425AA3BEF7DED60B122A52922A -221A37D9A807DD01161779DDE7D5FC1B2109839E5B52DFBB2A7C1B5D8E7E8AA0 -5B10EA43D6A8ED61AF5B23D49920D8F79DAB6A59062134D84AC0100187A6CD1F -80F5DDD9D222ACB1C23326A7656A635C4A241CCD32CBFDF8363206B8AA36E107 -1477F5496111E055C7491002AFF272E46ECC46422F0380D093284870022523FB -DA1716CC4F2E2CCAD5F173FCBE6EDDB874AD255CD5E5C0F86214393FCB5F5C20 -9C3C2BB5886E36FC3CCC21483C3AC193485A46E9D22BD7201894E4D45ADD9BF1 -CC5CF6A5010B5654AC0BE0DA903DB563B13840BA3015F72E51E3BC80156388BA -F83C7D393392BCBC227771CDCB976E93302530FA3F4BEF341997D4302A48384A -CEFFC1559462EA5F60DC05245E8499D8E61397B2C094CEED1AF26EE15A837209 -ECE64FEF41ABE8DDA7BE1F351CF14E07BA8FD40CEFBFC3CE7B9D4912D6FE752D -9CF163084E688DDCC4B5AAEDEB6E94DDDE34330BA35394A8B485E767F0F94A71 -4532F3B89C51AC3FD1C082EF41EA489B9595B4120FDCA2F599C88F5058126CD1 -4C7F96B4FE22BAB1A5E16F215DECBCE4186C68B6263BD5331CDC1FF9F30332A7 -7B831255A41A642C5719272C6B5993171CA395A0D11B6376457EC30E1CDE47A4 -9B9EE95D112C64084901B6357E881C0DEB6836B80F21E57B660388BA4F7B89EB -9AF7DE8AEA702FC5B765552F78058A20E424277F667A4E9955A797593CE44E19 -A98F149CA17D6379040A1C836CA18234278DFDA205EFD55D527C7F38766D4C97 - -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -cleartomark -%%EndFont -%%BeginFont: CMMI8 -%!PS-AdobeFont-1.1: CMMI8 1.100 -%%CreationDate: 1996 Jul 23 07:53:54 -% Copyright (C) 1997 American Mathematical Society. All Rights Reserved. -11 dict begin -/FontInfo 7 dict dup begin -/version (1.100) readonly def -/Notice (Copyright (C) 1997 American Mathematical Society. All Rights Reserved) readonly def -/FullName (CMMI8) readonly def -/FamilyName (Computer Modern) readonly def -/Weight (Medium) readonly def -/ItalicAngle -14.04 def -/isFixedPitch false def -end readonly def -/FontName /CMMI8 def -/PaintType 0 def -/FontType 1 def -/FontMatrix [0.001 0 0 0.001 0 0] readonly def -/Encoding 256 array -0 1 255 {1 index exch /.notdef put} for -dup 110 /n put -readonly def -/FontBBox{-24 -250 1110 750}readonly def -/UniqueID 5087383 def -currentdict end -currentfile eexec -D9D66F633B846A97B686A97E45A3D0AA0529731C99A784CCBE85B4993B2EEBDE -3B12D472B7CF54651EF21185116A69AB1096ED4BAD2F646635E019B6417CC77B -532F85D811C70D1429A19A5307EF63EB5C5E02C89FC6C20F6D9D89E7D91FE470 -B72BEFDA23F5DF76BE05AF4CE93137A219ED8A04A9D7D6FDF37E6B7FCDE0D90B -986423E5960A5D9FBB4C956556E8DF90CBFAEC476FA36FD9A5C8175C9AF513FE -D919C2DDD26BDC0D99398B9F4D03D6A8F05B47AF95EF28A9C561DBDC98C47CF5 -5250011D19E9366EB6FD153D3A100CAA6212E3D5D93990737F8D326D347B7EDC -4391C9DF440285B8FC159D0E98D4258FC57892DDF753642CD526A96ACEDA4120 -788F22B1D09F149794E66DD1AC2C2B3BC6FEC59D626F427CD5AE9C54C7F78F62 -C36F49B3C2E5E62AFB56DCEE87445A12A942C14AE618D1FE1B11A9CF9FAA1F32 -617B598CE5058715EF3051E228F72F651040AD99A741F247C68007E68C84E9D1 -D0BF99AA5D777D88A7D3CED2EA67F4AE61E8BC0495E7DA382E82DDB2B009DD63 -532C74E3BE5EC555A014BCBB6AB31B8286D7712E0E926F8696830672B8214E9B -5D0740C16ADF0AFD47C4938F373575C6CA91E46D88DE24E682DEC44B57EA8AF8 -4E57D45646073250D82C4B50CBBB0B369932618301F3D4186277103B53B3C9E6 -DB42D6B30115F67B9D078220D5752644930643BDF9FACF684EBE13E39B65055E -B1BD054C324962025EC79E1D155936FE32D9F2224353F2A46C3558EF216F6BB2 -A304BAF752BEEC36C4440B556AEFECF454BA7CBBA7537BCB10EBC21047333A89 -8936419D857CD9F59EBA20B0A3D9BA4A0D3395336B4CDA4BA6451B6E4D1370FA -D9BDABB7F271BC1C6C48D9DF1E5A6FAE788F5609DE3C48D47A67097C547D9817 -AD3A7CCE2B771843D69F860DA4059A71494281C0AD8D4BAB3F67BB6739723C04 -AE05F9E35B2B2CB9C7874C114F57A185C8563C0DCCA93F8096384D71A2994748 -A3C7C8B8AF54961A8838AD279441D9A5EB6C1FE26C98BD025F353124DA68A827 -AE2AF8D25CA48031C242AA433EEEBB8ABA4B96821786C38BACB5F58C3D5DA011 -85B385124C2B6534F3CD1866AF92009D93B97F763AA3CF46C60636D7FC1564CF -1DDFBC12CA37D27A79B11F2AFF2D70DBEE03CF1DFA5B864A2DC22266E4FA43DC -3F2CC229231F1F72874E6A74A90E8003B9AF1BFAA55C071FDDE5C94E4AE3C5BF -936EDFD4164624881410AB9EF0593F823D40BA7D059992104D08E41EBAD8F276 -A84EE2C9AEBC7CCB72AA6B6E6FE52293DC7BC34C2D1B69418392608FC5920291 -733654FA401E05F3E647B1C6AF4BECC3E802F9963344B05EC3DE8C774293CDB4 -3F057D6F258BD341848FA7FDCFD4D1923FCAB51FA8ADAE6D9F19C1FFA6EB5E9F -ECF844CEC6C1320D3F00C7259EF5812526F58248C61F89A42D9C9288CA8076FA -77E1C950940D8D6A7D852A0D0ABEBF2EDEDCDF6DDE0C8CCAC8DA9B28207D9CF8 -46446E1153D8D8795EE914B12349137D4BE461BCF5A6A3CF15FA5B9E91EB9B90 -0483916D0CD40EDC29EB0B996B16462A64F3B19B57802D9AFE3F1D91D9A8553C -531EB8B4E975037ED620EED3020388BFE705958B1E3AD4638B9CC8644C2F4024 -5DACD97151C3DF7A448CC3 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -cleartomark -%%EndFont -%%BeginFont: CMMI10 -%!PS-AdobeFont-1.1: CMMI10 1.100 -%%CreationDate: 1996 Jul 23 07:53:57 -% Copyright (C) 1997 American Mathematical Society. All Rights Reserved. -11 dict begin -/FontInfo 7 dict dup begin -/version (1.100) readonly def -/Notice (Copyright (C) 1997 American Mathematical Society. All Rights Reserved) readonly def -/FullName (CMMI10) readonly def -/FamilyName (Computer Modern) readonly def -/Weight (Medium) readonly def -/ItalicAngle -14.04 def -/isFixedPitch false def -end readonly def -/FontName /CMMI10 def -/PaintType 0 def -/FontType 1 def -/FontMatrix [0.001 0 0 0.001 0 0] readonly def -/Encoding 256 array -0 1 255 {1 index exch /.notdef put} for -dup 59 /comma put -dup 76 /L put -dup 85 /U put -dup 102 /f put -dup 103 /g put -dup 104 /h put -dup 105 /i put -dup 110 /n put -dup 120 /x put -readonly def -/FontBBox{-32 -250 1048 750}readonly def -/UniqueID 5087385 def -currentdict end -currentfile eexec -D9D66F633B846A97B686A97E45A3D0AA0529731C99A784CCBE85B4993B2EEBDE -3B12D472B7CF54651EF21185116A69AB1096ED4BAD2F646635E019B6417CC77B -532F85D811C70D1429A19A5307EF63EB5C5E02C89FC6C20F6D9D89E7D91FE470 -B72BEFDA23F5DF76BE05AF4CE93137A219ED8A04A9D7D6FDF37E6B7FCDE0D90B -986423E5960A5D9FBB4C956556E8DF90CBFAEC476FA36FD9A5C8175C9AF513FE -D919C2DDD26BDC0D99398B9F4D03D5993DFC0930297866E1CD0A319B6B1FD958 -9E394A533A081C36D456A09920001A3D2199583EB9B84B4DEE08E3D12939E321 -990CD249827D9648574955F61BAAA11263A91B6C3D47A5190165B0C25ABF6D3E -6EC187E4B05182126BB0D0323D943170B795255260F9FD25F2248D04F45DFBFB -DEF7FF8B19BFEF637B210018AE02572B389B3F76282BEB29CC301905D388C721 -59616893E774413F48DE0B408BC66DCE3FE17CB9F84D205839D58014D6A88823 -D9320AE93AF96D97A02C4D5A2BB2B8C7925C4578003959C46E3CE1A2F0EAC4BF -8B9B325E46435BDE60BC54D72BC8ACB5C0A34413AC87045DC7B84646A324B808 -6FD8E34217213E131C3B1510415CE45420688ED9C1D27890EC68BD7C1235FAF9 -1DAB3A369DD2FC3BE5CF9655C7B7EDA7361D7E05E5831B6B8E2EEC542A7B38EE -03BE4BAC6079D038ACB3C7C916279764547C2D51976BABA94BA9866D79F13909 -95AA39B0F03103A07CBDF441B8C5669F729020AF284B7FF52A29C6255FCAACF1 -74109050FBA2602E72593FBCBFC26E726EE4AEF97B7632BC4F5F353B5C67FED2 -3EA752A4A57B8F7FEFF1D7341D895F0A3A0BE1D8E3391970457A967EFF84F6D8 -47750B1145B8CC5BD96EE7AA99DDC9E06939E383BDA41175233D58AD263EBF19 -AFC0E2F840512D321166547B306C592B8A01E1FA2564B9A26DAC14256414E4C8 -42616728D918C74D13C349F4186EC7B9708B86467425A6FDB3A396562F7EE4D8 -40B43621744CF8A23A6E532649B66C2A0002DD04F8F39618E4F572819DD34837 -B5A08E643FDCA1505AF6A1FA3DDFD1FA758013CAED8ACDDBBB334D664DFF5B53 -95601766758C197F327101A9C9BF396ED625E27A7791ADF7474135C50F2F927A -5B5E332A003F858399565E4C02931D19AC2866CEFAB2288ACA215F2B7BE37156 -89009B14D623E0A872AC17AA52D29EA6E8D725A05A300AAD937745F61803544E -978846734C4C8FEA576A5D77903920CF4531C051776BBDF99ABD8C09849E586C -ED0E1D51A0047D2FF9097EA10DE0E397D69BC302D7A949CC435EE46C508FB6D6 -DAA66F2EDD3A6881D50A440A702018A99102DE5039F7CA1EF9F4C36D5C66AA4C -97C81079C961F48C6EC9E1C26E3740945443C9A262373410B96043CF52CA074A -D18DAFCE0ADE27C2C4A109C21C1B2A8E2F9DF1F14ED57195984F76A5B4213F69 -53C017777402DB63066D528BD2C690959CFE72FAE34C98CA3E797C3CE2B8544E -143B2BB6D7ED137528BC8BB4AB4BB49A295C43C96E92D2D4AA0157DD37CFE2DA -921259A6876045871A994E1316BD39142279BEED0AFCAE7F8D847650D409C934 -D8D16486AC153C8C6F5849270F71DBB5A744A258D5EF64F8819025F49B5A3D29 -889F9CE6CAFB1A44F503559B63B9BEB727C9FD6F99F1E618DEC55C349E1D24BA -3E4599AC645E89E2852D0E152DC94465071B3835EDC93C2924778DFAC1664734 -98F5583DDF83315203AAF78897CE1768F22083276F6D29D07C72CE4B3FF6F293 -28DC673F80626F8654E4FCF6A0263C1DB7AC8F63790729256F9B969908F3A176 -05D7AD6ED5F8E8AF79890282AE7B4C55AEE6526920983A72C5876DE620CF4E3A -7D1376FEF0B296F62C5C29D8D9BEE6B622AAFB66335001F92DAA1E119CFD5101 -08FCB0F238A64FCF56A62C7C08C0871C8D15DB0374C53D39CCD8B1058BAA3FAF -F9785E2D17FCE278B5179EB8AE77B6F1ADBDA6284B0658A07D91B044ABD82EE8 -C9F1763A966496728615DD1EBAB159D7CF6168DBB2582815DA6733785828DF75 -D6848392D3E479E5527DFC967F36D3D66CA6FE01FC6FA9BF6AD401051013DE6A -C69971B1271DFE6ED6A8B53B394CE11FEE75CB1F9AB278A74FD2765FFA3773F9 -F61B5B11C462CE38287536B946E7BD1F8AE0C8F5804B04AFDBB624A2489DAE07 -903F90656C96D1E1C2101FBB9B48C66BFED1B572CEEA04A16AAFE734E754251F -EC12CAF4D56AA5A936D40CBB44E76FF4780B8594967138A1E3092254DB2D4C2C -CDECE9AF76FAF9B3DED9847C79C1723CDD328E4B0B15566C6CD8490ADFEB9169 -418B34C36EF4FB43EF7FB5F1BFE7F795E85FEBA443DCABD076418BA94DAE6505 -D4E6075D792C0C1A6BDFF56326FBA965DFB9519F072BBB8CA486D4C9AA6FCF62 -3CDACB91B41C69837DB4E6DACD0AC582A044D526E340343720AED1742DC4E52F -67579B3A625C4B5E508BCFF3DA667DAE69B25F9D50996033797C42D7CBD85F99 -AB2CDCF739E3B2C6AEA3C315AC2D0F0D48B293B1397A9C1E304260CD8D0C3497 -27385284419D6B3BFCD701C367149332FA1A58EAA22A193C24375D40482129C0 -55BD4147CF597B64FD1F3F3545A03235B6918790D39B7473FE8AE5ED218500D2 -1F6B8EE7632762D06578544C16D9D3866B4A8295904C95CE224E15044770C7B8 -F7408C215A0FA286CAE554D3C51D6BF20B33F4890784816A1AD1B202C381DA82 -01CBEFC0B043181DCD849BCCF035C87708B6E3A9CE4D68B61E35B9CF54123A30 -0939400BA136E6CD4D30F42259ADDAAC17D613E6998BBE4F37C414F397D802AF -83EB5B4247C648B834C3F59C566F252EACE08706E410299F72BEAB9A49274E5E -74F834B4A5983F4C00932124B5D9DFA54E5EF7C1CB9A97C29B49BBCE6F00AE13 -E9CB172D2033E719841728DAB47C858BA8C0687B844B7FC5C2513F5A88A9E5DF -436A28193F1C9A42F840634CCB6681EFC5249080769728E330520A5D6D50164C -0C9A8456535BC89E45BDA70C62CC42C5E750470EFAE512202D95E5BAF604352E -8001E29161B7D6FB6CAD331E42E636021B2854923894715B496038F4AEDBD1E9 -12CC6F15B440C87B8633C43B5D696AFE0C8ACDDC98503A6B3F8685987D178FD6 -E3E8DC9763CCB10ED3D8E065CF3354496D648053B2F0B7B5596528AA91EB6F7D -F7E856ECB8DDB8523CAB5CB6349827450C58A3B007CB9928AF1E98DF77D84B4A -A97B85CEC023289C82A2189AB947C56BAA64911653C2FFFB4D546F3A08821136 -14E904163C9F1CBC64BCC368CBE5764423BB308364B8CA907F38687A153BB01F -6BAE773B21DB3FFE55F9523A52C6286FA2C090F4B8EA11A7C793AC55AAEDDF0C -5E9219B11A940F1ACDE2E124F42F040C9B29D8A56099B0592E1FC33C42B5BAF5 -5CD5E0997B66D81132C4DEE5A9B34AB0761164E23B1418D9AF2EF466EE648BF7 -B550A0559B37AA4EEFE096D5B7B65A891FBB0364CDB8FAC49A7011152CA04B0C -4A91E982CF0E718DBDCAE97F90BC2D22EEA14CDE4003702563D5E02D758A3839 -4A4DDC3DF05069E1F23CB5B5ED68DBFDD1E26FF41967D5158056D86DE8BFAE94 -407645A693988C796417224C91661505FA3983863E2563E4228A5E76BA5E72B9 -10C08AF95D0C4C29E812EF8B3E2CD401562C1C7A35E49054D492DE9712D89C49 -FCB524E3D479A05DABA3D774E30F247A9287407468809AB93E53C3F9B5F5A6D7 -74F447C46BDA6AC95BBFF5A39268259C1E4A4C16FBE30C2DAD58C1D3F9DF5887 -CFE667D2E29DDBA05CE796355F0E1EC3A10FA0421074651E0B584FBD4A04D4C1 -3B4E8E729EB0F7676958F4A3677504132AEAF0DF00F781E4CC4E055917D0F363 -327C3C8E48E75675D425B02D4387269FC8487A325155B0335D -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -cleartomark -%%EndFont -%%BeginFont: CMR10 -%!PS-AdobeFont-1.1: CMR10 1.00B -%%CreationDate: 1992 Feb 19 19:54:52 -% Copyright (C) 1997 American Mathematical Society. All Rights Reserved. -11 dict begin -/FontInfo 7 dict dup begin -/version (1.00B) readonly def -/Notice (Copyright (C) 1997 American Mathematical Society. All Rights Reserved) readonly def -/FullName (CMR10) readonly def -/FamilyName (Computer Modern) readonly def -/Weight (Medium) readonly def -/ItalicAngle 0 def -/isFixedPitch false def -end readonly def -/FontName /CMR10 def -/PaintType 0 def -/FontType 1 def -/FontMatrix [0.001 0 0 0.001 0 0] readonly def -/Encoding 256 array -0 1 255 {1 index exch /.notdef put} for -dup 40 /parenleft put -dup 41 /parenright put -dup 43 /plus put -dup 48 /zero put -dup 49 /one put -dup 50 /two put -dup 53 /five put -dup 61 /equal put -readonly def -/FontBBox{-251 -250 1009 969}readonly def -/UniqueID 5000793 def -currentdict end -currentfile eexec -D9D66F633B846A97B686A97E45A3D0AA052A014267B7904EB3C0D3BD0B83D891 -016CA6CA4B712ADEB258FAAB9A130EE605E61F77FC1B738ABC7C51CD46EF8171 -9098D5FEE67660E69A7AB91B58F29A4D79E57022F783EB0FBBB6D4F4EC35014F -D2DECBA99459A4C59DF0C6EBA150284454E707DC2100C15B76B4C19B84363758 -469A6C558785B226332152109871A9883487DD7710949204DDCF837E6A8708B8 -2BDBF16FBC7512FAA308A093FE5CF7158F1163BC1F3352E22A1452E73FECA8A4 -87100FB1FFC4C8AF409B2067537220E605DA0852CA49839E1386AF9D7A1A455F -D1F017CE45884D76EF2CB9BC5821FD25365DDEA6E45F332B5F68A44AD8A530F0 -92A36FAC8D27F9087AFEEA2096F839A2BC4B937F24E080EF7C0F9374A18D565C -295A05210DB96A23175AC59A9BD0147A310EF49C551A417E0A22703F94FF7B75 -409A5D417DA6730A69E310FA6A4229FC7E4F620B0FC4C63C50E99E179EB51E4C -4BC45217722F1E8E40F1E1428E792EAFE05C5A50D38C52114DFCD24D54027CBF -2512DD116F0463DE4052A7AD53B641A27E81E481947884CE35661B49153FA19E -0A2A860C7B61558671303DE6AE06A80E4E450E17067676E6BBB42A9A24ACBC3E -B0CA7B7A3BFEA84FED39CCFB6D545BB2BCC49E5E16976407AB9D94556CD4F008 -24EF579B6800B6DC3AAF840B3FC6822872368E3B4274DD06CA36AF8F6346C11B -43C772CC242F3B212C4BD7018D71A1A74C9A94ED0093A5FB6557F4E0751047AF -D72098ECA301B8AE68110F983796E581F106144951DF5B750432A230FDA3B575 -5A38B5E7972AABC12306A01A99FCF8189D71B8DBF49550BAEA9CF1B97CBFC7CC -96498ECC938B1A1710B670657DE923A659DB8757147B140A48067328E7E3F9C3 -7D1888B284904301450CE0BC15EEEA00E48CCD6388F3FC390E75D51F36C3E61E -E84B5AD036ADADEBD4F8D399AA559B34270D370DEDF077D1D49253F313C333CB -F22FD740EDE076FE3383503F159888E77132A06528CEBA5BB0E57C07D36B73D7 -C81B71200D95D73A1AD33BBA5CA3E34B94447EAB8D27625CBFF13B56F87A9B74 -4B52A09BAB0AABD5E398B1E5E9868BC080EFC7ECBDA4D6817C3255A51A814A04 -0839172E2CCECB4F6E7B5B6B3B61D5858256AD27D93969EBB34C7EE68BF805D0 -39CA6AC7DECCD1A395E7BA297AB0E97B3290EDAED775EAB0D7D553F222A3B014 -FFA358EE448BBB24E1B44CE0BB474DFA01B0F4C4964248444FCA4DDEA8FDA9B8 -82F96DCBEF94CAC9C8F48922899CB1E7D70F650E6471E5408C44554E72599D97 -BC1D32360ECFB378192605E726A3DDA7E5B02736CEB7BE8A5C27AE952F4946D0 -1DD1D65C1D50D0317984B781D64B6075D35EC1E3507FD4FE2E7097A0EE116EEC -3497D2D84B19F68EBF7125FB02920466AE4FE25A3C3068A83A513556D05359A3 -93B6C6929BA47044787EEBA3A38E8266CF1D13DB69779644DF8AFE2C2C5C81F9 -75CBC9CA07E6CB70211CA62FD7CF596132333970E5233AAFBF984EC110664810 -AEFBADCE663CADF91D36D1587C5D7E7F63E3A674856AD7CDB99CD276D3659ED0 -CA0FDC17251E69BA7F2F3AC57257831C31AFBB0DADF44F7E6EF84D63C03E75FF -886FFDAF8153EA8E0779E46935AB0AEFC84AC2061291D39E5F67FB75BEA48EDA -030512CDB14B16D466CFBC58D3764B83AF5C00D05A3F052F53BBE4E1417773CA -BDBEAC50BB7BFF981255BDA6650870E4D67BCB80A63BA050F2650934CB6E742B -B2B2A115C1F9827C979E8F2E92C0A1F428288643C8A27B7105587366E1BFF1FB -056DE92CAD4A7F391A483DE4E9930E8C5BA9B215F1E3FA4798A1740A9B72810A -44CD1D1ECAC8ED7BA3655C4EEF6BF28A2B0B23B0BF783A4FBDDB1246B5EEA601 -6440F98C0A3B6ED360561479EA83990A78A0F4608698B30FE6476AED9349D11F -FB467D3C19D7A3539B8A2DA0C54454A231B87FB441A1BE6893E0F67081E8FF09 -FC20412C452D8227D4BA7665EA8F14A1987845CF8570EDD926F4EF5F2D85DB99 -736D7A939D4313F589033FA135D6366EB8B63C026357360A9E8717656ADABA76 -11B9D672B7D57F1422CAEA295A774CB1F6BEAE51A7A9F7EACF6F22CC6412F1D6 -9DDF884EB94F91B5F301039EE962C51F7FCEF8319CE80F46A7E3187EE60342DB -4057C2374CF68AAD30B5979B24D41ED8A803A1E6EA845D7E7675031A2D4257D8 -4BE91A75006673CE3C24AA4C4138EED6DE5147FD16049BC523D54F26BF951AAC -85157DB39E8B38798267AE2E5266331CFAA0E4D18D2F5C50277BE056498E569E -90AB0A7127F94F0EEC3FC2DC7BF421A2A855318646BACC78EC03D14CC41AB9CA -61649659F81614F8FA9E052F37445DBAF2B0873A06015E16A268544FB047AD0A -E9EF324844E8CA272D00944D54B691CA137E1CF59B69F59D5F9A40EEA081C9EC -6AD88DB832E588F5AACA900198105A8D59C215DCD387B32FE34E9B8476AB5C7A -B739EEE6840ACBFDC79501A04FFB2A57D3A4D3D181D68F074DFB0E828C41FBE3 -E7D0F2A7CE0AC1C7ED09FD9C6E085C89E8BC46BA83A8CED54EDB6EDE1B55B349 -84C37F33BB71994A8EF29050A902448E21CA0B2B5E9DDCF43ACBB79CC841E7EA -5D8BA0D8C18DDFB3B72559BF6251A5F026FAEB035509D20058FEC5FDB1B7E329 -3E299B4FBDF2BD3A5D27035BB8732C3688C3C203D1664522CEBC8BCAC7D4E643 -6490E8CAE79FB51F9285A64099719EA841CD4710392D94660920608397214CEA -588A9CFC233DA75C7C8F381ECEA4065F431122D472D333B2E260DB32F5CCCB15 -56BB953DEC3B6E451B212ABBE079888B73C48744CF5A9C1DCB47C423C647A94F -2B4358B020B2C5FDF1D4B7BE081BC0F4EA86359DFE9BDCC1CBDA475618A71ED4 -F61834FCC9DAA616C7C8D2407333ECE57AD5F5F43FD077EB12C2310BF7EB1EFC -1EAEE06F0891DEFD32AF69082D203207524CA6DC8005C22C1C1CE2C6CBED42B3 -122148A0A6BAFC0DEEEC37594B68494BB5EF16E510C1CD4BF3F6597F98E5362C -544F51DC368425AD6A867D1E6E9AB208C77982536D56581A539597DC172F1D09 -BF027427518C4CCD96BD4321DD8FF54C8D034F66F32F3A2DDFA05E33E5C5408B -8C8511FE0E8F52F38475B84E2A2F5F7B09F8F92D8E1DE2754E683A39EE71BD78 -EFFA9E0804386F6B98CB37112C4A8844C8E2F26C8920CD18089BE16D20922DD4 -AF2EFCE40BCFFB79A001E1DFF89AC67B02FFB09FD38354B57A5FAD9BA3640064 -E4CB7CFC355B5384699A57E86513CA2F89B938688A3F42A6FDBC6E92D50C050E -B96AFCE7691A96AEC83213FC00BD81EA3895 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -cleartomark -%%EndFont -%%BeginFont: CMSY10 -%!PS-AdobeFont-1.1: CMSY10 1.0 -%%CreationDate: 1991 Aug 15 07:20:57 -% Copyright (C) 1997 American Mathematical Society. All Rights Reserved. -11 dict begin -/FontInfo 7 dict dup begin -/version (1.0) readonly def -/Notice (Copyright (C) 1997 American Mathematical Society. All Rights Reserved) readonly def -/FullName (CMSY10) readonly def -/FamilyName (Computer Modern) readonly def -/Weight (Medium) readonly def -/ItalicAngle -14.035 def -/isFixedPitch false def -end readonly def -/FontName /CMSY10 def -/PaintType 0 def -/FontType 1 def -/FontMatrix [0.001 0 0 0.001 0 0] readonly def -/Encoding 256 array -0 1 255 {1 index exch /.notdef put} for -dup 1 /periodcentered put -dup 15 /bullet put -dup 102 /braceleft put -dup 103 /braceright put -readonly def -/FontBBox{-29 -960 1116 775}readonly def -/UniqueID 5000820 def -currentdict end -currentfile eexec -D9D66F633B846A97B686A97E45A3D0AA052F09F9C8ADE9D907C058B87E9B6964 -7D53359E51216774A4EAA1E2B58EC3176BD1184A633B951372B4198D4E8C5EF4 -A213ACB58AA0A658908035BF2ED8531779838A960DFE2B27EA49C37156989C85 -E21B3ABF72E39A89232CD9F4237FC80C9E64E8425AA3BEF7DED60B122A52922A -221A37D9A807DD01161779DDE7D31FF2B87F97C73D63EECDDA4C49501773468A -27D1663E0B62F461F6E40A5D6676D1D12B51E641C1D4E8E2771864FC104F8CBF -5B78EC1D88228725F1C453A678F58A7E1B7BD7CA700717D288EB8DA1F57C4F09 -0ABF1D42C5DDD0C384C7E22F8F8047BE1D4C1CC8E33368FB1AC82B4E96146730 -DE3302B2E6B819CB6AE455B1AF3187FFE8071AA57EF8A6616B9CB7941D44EC7A -71A7BB3DF755178D7D2E4BB69859EFA4BBC30BD6BB1531133FD4D9438FF99F09 -4ECC068A324D75B5F696B8688EEB2F17E5ED34CCD6D047A4E3806D000C199D7C -515DB70A8D4F6146FE068DC1E5DE8BC57030ACE57A0A31C99BEDB251A0ECAD78 -253AB3339E847FBB1AF693606A973F6ECD887C325CA59C6A4A9AC48AF5551D10 -EE26B8C4DA13F670D3F0C09187B9AB37F2BA6A32F8D363393D22215650EEE7F8 -DFB1378390C44F36098EA2DA6CB943DACFB8AECD62E46F120BE7A15C19200094 -7975CA278BAF5E155531F90FCBFE67D2AC15BA6E3B15FEF09F697956F198D111 -16292151DECACDAF2B2CF42B82DE6D4515735744887745770F8D8656BAEEFC04 -2F6A832F466D4244F1F9998BF49A413F094108FC90F586AEB324888BD885F2A1 -C749504E6DCB10F6A2B797826939AFA46BD208A268FB4C6635264B2B39F6E11E -34ED5B3D02E6C9178BFE61AE0A0B6B789E394F8A33730EC5E4484F2D962268F5 -8FD36EAD6CF68C7120E82FD8B2EA91095227CFF985054557361FD9B1E8FACB8C -A17AD35513D4D69B5D52470A6B4796299442430E66AAB39A574CF4C4D0838C52 -B675FB04C646FE52C599EA039302B200CEA102986E6549225D22F30455B7947B -5DCF0190B5296E12FA026272B1D2076B630CABB8F71589ECB69B95486A650A09 -05D11C00F0909A7228A107C7D27074FC6B5380FB3534816E122D65369D70C68E -98E1951DA9756B3CD665F378B661506661175A89D37889CDB07D1692988875EE -878DC0771EF29DDB382287584FE12E47FD7CEE6C130E2D2B3028C8C54B83C977 -26845C0960D62A50B290605368BE2568340524244ABCEE470B683E92456DEE76 -228DCCBDBC688458DF63F2C1E4D8BA46657CB79B9E28179AD2459603874FC200 -CAB2ABDBD725DB89EB7E7C5DFE03826FC7EA65F57CF87E382A976D70F44596B5 -53C6DC34FE7F2B295D67AA8A550F1DF1D040237352D42F14D1D0E7A23318E53B -BA0958CC11E47508EE8D9DCAB8116452978F0963222D14739F8E890A39AB41BC -B66B92570A18 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -cleartomark -%%EndFont -%%BeginFont: CMMI12 -%!PS-AdobeFont-1.1: CMMI12 1.100 -%%CreationDate: 1996 Jul 27 08:57:55 -% Copyright (C) 1997 American Mathematical Society. All Rights Reserved. -11 dict begin -/FontInfo 7 dict dup begin -/version (1.100) readonly def -/Notice (Copyright (C) 1997 American Mathematical Society. All Rights Reserved) readonly def -/FullName (CMMI12) readonly def -/FamilyName (Computer Modern) readonly def -/Weight (Medium) readonly def -/ItalicAngle -14.04 def -/isFixedPitch false def -end readonly def -/FontName /CMMI12 def -/PaintType 0 def -/FontType 1 def -/FontMatrix [0.001 0 0 0.001 0 0] readonly def -/Encoding 256 array -0 1 255 {1 index exch /.notdef put} for -dup 60 /less put -dup 62 /greater put -readonly def -/FontBBox{-30 -250 1026 750}readonly def -/UniqueID 5087386 def -currentdict end -currentfile eexec -D9D66F633B846A97B686A97E45A3D0AA0529731C99A784CCBE85B4993B2EEBDE -3B12D472B7CF54651EF21185116A69AB1096ED4BAD2F646635E019B6417CC77B -532F85D811C70D1429A19A5307EF63EB5C5E02C89FC6C20F6D9D89E7D91FE470 -B72BEFDA23F5DF76BE05AF4CE93137A219ED8A04A9D7D6FDF37E6B7FCDE0D90B -986423E5960A5D9FBB4C956556E8DF90CBFAEC476FA36FD9A5C8175C9AF513FE -D919C2DDD26BDC0D99398B9F4D03D6A8F05B47AF95EF28A9C561DBDC98C47CF5 -5250011D19E9366EB6FD153D3A100CAA6212E3D5D93990737F8D326D347B7EDC -4391C9DF440285B8FC159D0E98D4258FC57892DCC57F7903449E07914FBE9E67 -3C15C2153C061EB541F66C11E7EE77D5D77C0B11E1AC55101DA976CCACAB6993 -EED1406FBB7FF30EAC9E90B90B2AF4EC7C273CA32F11A5C1426FF641B4A2FB2F -4E68635C93DB835737567FAF8471CBC05078DCD4E40E25A2F4E5AF46C234CF59 -2A1CE8F39E1BA1B2A594355637E474167EAD4D97D51AF0A899B44387E1FD933A -323AFDA6BA740534A510B4705C0A15647AFBF3E53A82BF320DD96753639BE49C -2F79A1988863EF977B800C9DB5B42039C23EB86953713F730E03EA22FF7BB2C1 -D97D33FD77B1BDCC2A60B12CF7805CFC90C5B914C0F30A673DF9587F93E47CEA -5932DD1930560C4F0D97547BCD805D6D854455B13A4D7382A22F562D7C55041F -0FD294BDAA1834820F894265A667E5C97D95FF152531EF97258F56374502865D -A1E7C0C5FB7C6FB7D3C43FEB3431095A59FBF6F61CEC6D6DEE09F4EB0FD70D77 -2A8B0A4984C6120293F6B947944BE23259F6EB64303D627353163B6505FC8A60 -00681F7A3968B6CBB49E0420A691258F5E7B07B417157803FCBE9B9FB1F80FD8 -CA0DA1186446DD565542BCCC7D339A1EB34C7F49246E8D72E987EB477C6DB757 -99AF86CEBCD7605C487A00CD2CD093098182DC57B20D78ECE0BECF3A0BF88EBA -C866DB19F34BBBED6634AFC0F08D2AFB2A92578A6F8B4ADCD6594737FF6EED7D -5B536DA9E3E2CADB40DB7C600EA4D100D33C3B92B1CF857E012C4EB370BA8295 -55B50047CD58E912E67E22C1B92F41D0BEE742201DF198F3766AE35EA71D8195 -A8C94D661C40D718CB09497485FAA34204229AECFE644C93FFDA54C789E4F751 -3D2519F7CB9E79B2ABE3101DF2EBFAD375469CDC687FB3DC2833EDC0F946B41F -F28D72FFF2A9B8B0D76DC542537612E2BE0F3FB9601C897386359C55E867A547 -F872005F5C56C6EC5E9685E03D7A82653BE8B69741C4DF332AEEB2AA450B23F3 -EABD5ED060606CC7DB1762632EC3C6C4A66ADAF61A97D949DEA5156B4CF34765 -67AC3F10AE17199A710A882D47979F9D41AA2CB794648BE47479F0B00E18BF04 -923F54CEC1214BAFA39BB65ECB013875899E9901B7882D16D2E2C97AD3353668 -A6070081E4DC627AF9192599F5876369908FBDFA11E8D6CB2E83896E9C897CEC -FD1D25651D66A333AF531FF74E1B0DEB1E3D1B5B7D3FB9D1C8BF60517B31C8D2 -1C264F44BC9AF3D9BA5280D1618EED96C11ED24F789FAA263394C658DFCA8DE9 -D47D9E188E212F9EC1DCF449DFDAB8437FAB9EA9AF01AE1714E8F932855182 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -0000000000000000000000000000000000000000000000000000000000000000 -cleartomark -%%EndFont -TeXDict begin 40258431 52099146 1000 600 600 (cudd.dvi) -@start /Fa 137[40 51 1[35 35 8[25 2[30 40 45 40 16[61 -13[66 61 67[{ TeXBase1Encoding ReEncodeFont }12 90.9091 -/Times-BoldItalic rf /Fb 136[50 7[37 2[21 108[{ - TeXBase1Encoding ReEncodeFont }3 74.7198 /Times-Italic -rf /Fc 204[35 35 35 35 48[{}4 66.4176 /CMR8 rf /Fd 207[19 -47[55{}2 66.4176 /CMSY8 rf /Fe 133[33 37 37 54 37 37 -21 29 25 1[37 37 37 58 21 37 1[21 37 37 25 33 37 33 37 -33 9[71 54 54 46 11[54 2[46 54 50 7[21 21 10[21 19 25 -19 41[42 2[{ TeXBase1Encoding ReEncodeFont }39 74.7198 -/Times-Roman rf /Ff 201[25 25 25 25 25 25 49[{ - TeXBase1Encoding ReEncodeFont }6 49.8132 /Times-Roman -rf /Fg 201[33 33 33 33 33 33 49[{ TeXBase1Encoding ReEncodeFont }6 -66.4176 /Times-Roman rf /Fh 130[55 55 55 55 55 55 55 -55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 -55 55 55 55 1[55 1[55 55 55 55 1[55 1[55 55 55 55 55 -55 55 55 55 55 55 2[55 55 55 55 55 55 55 55 55 55 55 -55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 -55 55 55 55 55 2[55 1[55 55 55 33[{ TeXBase1Encoding ReEncodeFont }84 -90.9091 /Courier rf /Fi 133[44 50 1[72 50 55 33 39 44 -55 55 50 55 83 28 55 1[28 55 50 33 44 55 44 55 50 6[66 -2[100 72 72 66 55 72 1[61 78 1[94 66 78 1[39 78 78 61 -1[72 72 66 72 7[50 50 50 50 50 50 50 50 50 50 28 25 46[{ - TeXBase1Encoding ReEncodeFont }56 99.6264 /Times-Bold -rf /Fj 145[43 110[{}1 66.4176 /CMMI8 rf /Fk 135[52 9[55 -4[31 52 43 45 16[62 8[62 16[25 59[{}9 90.9091 /CMMI10 -rf /Fl 194[71 7[45 2[45 45 45 4[71 1[35 35 40[{}8 90.9091 -/CMR10 rf /Fm 152[45 45 86[45 13[25 1[{}4 90.9091 /CMSY10 -rf /Fn 133[35 40 40 61 40 45 25 35 35 45 45 45 45 66 -25 40 25 25 45 45 25 40 45 40 45 45 6[51 1[56 76 56 66 -51 45 56 66 56 66 61 76 51 61 40 30 66 66 56 56 66 61 -56 56 7[45 1[45 3[45 45 45 2[23 30 3[30 30 30 35[45 45 -2[{ TeXBase1Encoding ReEncodeFont }63 90.9091 /Times-Italic -rf /Fo 87[30 16[91 45 1[40 40 24[40 45 45 66 45 45 25 -35 30 45 45 45 45 71 25 45 25 25 45 45 30 40 45 40 45 -40 3[30 1[30 56 66 66 86 66 66 56 51 61 66 51 66 66 81 -56 66 35 30 66 66 51 56 66 61 61 66 5[25 25 45 45 45 -45 45 45 45 45 45 45 25 23 30 23 51 1[30 30 30 1[76 33[51 -51 2[{ TeXBase1Encoding ReEncodeFont }82 90.9091 /Times-Roman -rf /Fp 105[45 27[40 45 45 66 45 51 30 35 40 1[51 45 51 -76 25 51 1[25 51 45 30 40 51 40 51 45 6[61 66 66 91 66 -66 61 51 66 1[56 71 66 86 61 2[35 71 71 56 61 66 66 61 -66 5[30 30 1[45 1[45 45 45 45 45 45 45 1[23 1[23 52 3[30 -36[51 2[{ TeXBase1Encoding ReEncodeFont }63 90.9091 /Times-Bold -rf /Fq 135[60 86 1[66 40 47 53 2[60 66 100 33 66 1[33 -66 60 40 53 66 53 1[60 11[86 80 1[86 1[73 2[113 3[47 -93 93 2[86 86 1[86 10[60 60 60 60 60 60 5[68 3[40 39[{ - TeXBase1Encoding ReEncodeFont }38 119.552 /Times-Bold -rf /Fr 193[76 1[76 60[{}2 99.6264 /CMMI12 rf /Fs 133[44 -50 2[50 50 28 39 33 1[50 50 50 78 28 2[28 1[50 33 44 -50 44 50 44 11[72 1[55 12[55 61 72 66 66 1[92 11[50 1[50 -50 50 1[25 1[25 44[{ TeXBase1Encoding ReEncodeFont }34 -99.6264 /Times-Roman rf /Ft 140[56 48 2[72 72 112 40 -72 1[40 1[72 1[64 1[64 1[64 11[104 2[96 1[80 11[104 96 -8[40 4[72 2[72 1[72 1[36 46[{ TeXBase1Encoding ReEncodeFont }22 -143.462 /Times-Roman rf end -%%EndProlog -%%BeginSetup -%%Feature: *Resolution 600dpi -TeXDict begin - end -%%EndSetup -%%Page: 1 1 -TeXDict begin 1 0 bop Black Black Black Black 804 937 -a Ft(CUDD:)34 b(CU)i(Decision)d(Diagram)h(P)n(ackage)1558 -1120 y(Release)g(2.5.0)1643 1373 y Fs(F)o(abio)25 b(Somenzi)720 -1489 y(Department)f(of)h(Electrical,)g(Computer)l(,)f(and)h(Ener)n(gy)g -(Engineering)1261 1605 y(Uni)n(v)o(ersity)e(of)i(Colorado)f(at)h -(Boulder)1408 1721 y Fr(<)p Fs(F)o(abio@Colorado.EDU)p -Fr(>)1601 1923 y Fs(February)h(4,)e(2012)448 2316 y Fq(Contents)448 -2523 y Fp(1)92 b(Intr)n(oduction)2315 b(4)448 2726 y(2)92 -b(Ho)o(w)22 b(to)i(Get)f(CUDD)2077 b(5)585 2839 y Fo(2.1)96 -b(The)23 b(CUDD)e(P)o(ackage)92 b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.) -f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p -Black 171 w(5)p Black 585 2952 a(2.2)96 b(CUDD)21 b(Friends)81 -b(.)45 b(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.) -h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 171 w(5)p -Black 448 3156 a Fp(3)92 b(User')m(s)23 b(Manual)2238 -b(5)585 3269 y Fo(3.1)96 b(Compiling)24 b(and)g(Linking)53 -b(.)45 b(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.) -g(.)h(.)f(.)g(.)g(.)g(.)p Black 171 w(6)p Black 585 3382 -a(3.2)96 b(Basic)23 b(Data)h(Structures)51 b(.)45 b(.)g(.)h(.)f(.)g(.)g -(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.) -p Black 171 w(6)p Black 794 3495 a(3.2.1)110 b(Nodes)41 -b(.)46 b(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.) -g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 171 -w(6)p Black 794 3608 a(3.2.2)110 b(The)23 b(Manager)60 -b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.) -g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 171 w(7)p Black 794 -3721 a(3.2.3)110 b(Cache)46 b(.)g(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g -(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.) -p Black 171 w(8)p Black 585 3833 a(3.3)96 b(Initializing)26 -b(and)e(Shutting)h(Do)n(wn)e(a)g(DdManager)78 b(.)46 -b(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 171 w(8)p -Black 585 3946 a(3.4)96 b(Setting)24 b(P)o(arameters)87 -b(.)45 b(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.) -g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 171 w(9)p Black -585 4059 a(3.5)96 b(Constant)25 b(Functions)66 b(.)45 -b(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g -(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 171 w(9)p Black 794 -4172 a(3.5.1)110 b(One,)23 b(Logic)g(Zero,)g(and)h(Arithmetic)h(Zero)41 -b(.)46 b(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black -171 w(9)p Black 794 4285 a(3.5.2)110 b(Prede\002ned)24 -b(Constants)51 b(.)45 b(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g -(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(10)p Black 794 -4398 a(3.5.3)110 b(Background)36 b(.)45 b(.)g(.)g(.)h(.)f(.)g(.)g(.)g -(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p -Black 125 w(10)p Black 794 4511 a(3.5.4)110 b(Ne)n(w)22 -b(Constants)65 b(.)45 b(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h -(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(11)p -Black 585 4624 a(3.6)96 b(Creating)25 b(V)-10 b(ariables)28 -b(.)45 b(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.) -f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(11)p -Black 794 4737 a(3.6.1)110 b(Ne)n(w)22 b(BDD)f(and)j(ADD)e(V)-10 -b(ariables)43 b(.)i(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g -(.)p Black 125 w(11)p Black 794 4850 a(3.6.2)110 b(Ne)n(w)22 -b(ZDD)f(V)-10 b(ariables)81 b(.)45 b(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.) -h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(12)p -Black 585 4963 a(3.7)96 b(Basic)23 b(BDD)f(Manipulation)47 -b(.)f(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h -(.)f(.)g(.)g(.)g(.)p Black 125 w(12)p Black Black 1920 -5225 a(1)p Black eop end -%%Page: 2 2 -TeXDict begin 2 1 bop Black Black 585 573 a Fo(3.8)96 -b(Basic)23 b(ADD)f(Manipulation)42 b(.)k(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.) -g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p -Black 125 w(13)p Black 585 686 a(3.9)96 b(Basic)23 b(ZDD)f -(Manipulation)52 b(.)46 b(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h -(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(14)p -Black 585 799 a(3.10)51 b(Con)l(v)o(erting)26 b(ADDs)c(to)h(BDDs)f(and) -i(V)-5 b(ice)23 b(V)-10 b(ersa)85 b(.)45 b(.)h(.)f(.)g(.)g(.)g(.)h(.)f -(.)g(.)g(.)g(.)p Black 125 w(15)p Black 585 912 a(3.11)51 -b(Con)l(v)o(erting)26 b(BDDs)c(to)h(ZDDs)f(and)i(V)-5 -b(ice)23 b(V)-10 b(ersa)27 b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g -(.)g(.)g(.)p Black 125 w(15)p Black 585 1024 a(3.12)51 -b(V)-10 b(ariable)24 b(Reordering)i(for)e(BDDs)e(and)i(ADDs)63 -b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p -Black 125 w(16)p Black 585 1137 a(3.13)51 b(Grouping)25 -b(V)-10 b(ariables)61 b(.)45 b(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g -(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p -Black 125 w(19)p Black 585 1250 a(3.14)51 b(V)-10 b(ariable)24 -b(Reordering)i(for)e(ZDDs)68 b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h -(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(20)p -Black 585 1363 a(3.15)51 b(K)n(eeping)24 b(Consistent)i(V)-10 -b(ariable)24 b(Orders)h(for)e(BDDs)f(and)i(ZDDs)46 b(.)f(.)g(.)g(.)g(.) -p Black 125 w(21)p Black 585 1476 a(3.16)51 b(Hooks)k(.)45 -b(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g -(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p -Black 125 w(21)p Black 585 1589 a(3.17)51 b(T)m(imeouts)24 -b(and)g(Limits)82 b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g -(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black -125 w(22)p Black 585 1702 a(3.18)51 b(The)23 b(SIS/VIS)f(Interf)o(ace) -27 b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g -(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(22)p Black -794 1815 a(3.18.1)65 b(Using)24 b(the)f(CUDD)f(P)o(ackage)i(in)f(SIS)h -(.)45 b(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p -Black 125 w(22)p Black 585 1928 a(3.19)51 b(Writing)24 -b(Decision)h(Diagrams)f(to)g(a)f(File)57 b(.)45 b(.)g(.)g(.)g(.)g(.)h -(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(24)p -Black 585 2041 a(3.20)51 b(Sa)n(ving)24 b(and)g(Restoring)h(BDDs)78 -b(.)45 b(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.) -g(.)g(.)g(.)p Black 125 w(24)p Black 448 2245 a Fp(4)92 -b(Pr)n(ogrammer')m(s)25 b(Manual)1870 b(24)585 2357 y -Fo(4.1)96 b(Compiling)24 b(and)g(Linking)53 b(.)45 b(.)h(.)f(.)g(.)g(.) -g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p -Black 125 w(24)p Black 585 2470 a(4.2)96 b(Reference)25 -b(Counts)53 b(.)45 b(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.) -g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black -125 w(26)p Black 794 2583 a(4.2.1)110 b(NULL)21 b(Return)j(V)-10 -b(alues)42 b(.)j(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.) -h(.)f(.)g(.)g(.)g(.)p Black 125 w(27)p Black 794 2696 -a(4.2.2)110 b Fn(Cudd)p 1286 2696 28 4 v 33 w(Recur)o(siveDer)m(ef)40 -b Fo(vs.)23 b Fn(Cudd)p 2239 2696 V 34 w(Der)m(ef)45 -b Fo(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black -125 w(27)p Black 794 2809 a(4.2.3)110 b(When)23 b(Increasing)k(the)d -(Reference)h(Count)f(is)f(Unnecessary)90 b(.)45 b(.)p -Black 125 w(27)p Black 794 2922 a(4.2.4)110 b(Saturating)25 -b(Increments)h(and)e(Decrements)91 b(.)45 b(.)g(.)g(.)g(.)h(.)f(.)g(.)g -(.)g(.)p Black 125 w(28)p Black 585 3035 a(4.3)96 b(Complement)24 -b(Arcs)37 b(.)45 b(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g -(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black -125 w(28)p Black 585 3148 a(4.4)96 b(The)23 b(Cache)37 -b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.) -g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p -Black 125 w(29)p Black 794 3261 a(4.4.1)110 b(Cache)24 -b(Sizing)64 b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.) -h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(29)p -Black 794 3374 a(4.4.2)110 b(Local)23 b(Caches)55 b(.)45 -b(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g -(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(30)p Black 585 3487 -a(4.5)96 b(The)23 b(Unique)h(T)-7 b(able)47 b(.)e(.)g(.)g(.)g(.)h(.)f -(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.) -g(.)g(.)p Black 125 w(31)p Black 585 3599 a(4.6)96 b(Allo)n(wing)24 -b(Asynchronous)j(Reordering)64 b(.)45 b(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g -(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(32)p Black 585 -3712 a(4.7)96 b(Deb)n(ugging)28 b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.) -h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f -(.)g(.)g(.)g(.)p Black 125 w(33)p Black 585 3825 a(4.8)96 -b(Gathering)25 b(and)f(Interpreting)j(Statistics)64 b(.)45 -b(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p -Black 125 w(34)p Black 794 3938 a(4.8.1)110 b(Non)23 -b(Modi\002able)i(P)o(arameters)89 b(.)45 b(.)g(.)g(.)g(.)g(.)h(.)f(.)g -(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(34)p Black -794 4051 a(4.8.2)110 b(Modi\002able)24 b(P)o(arameters)64 -b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.) -g(.)g(.)p Black 125 w(37)p Black 794 4164 a(4.8.3)110 -b(Extended)25 b(Statistics)g(and)f(Reporting)63 b(.)45 -b(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black -125 w(39)p Black 585 4277 a(4.9)96 b(Guidelines)25 b(for)f -(Documentation)75 b(.)45 b(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g -(.)g(.)h(.)f(.)g(.)g(.)g(.)p Black 125 w(39)p Black 448 -4481 a Fp(5)92 b(The)22 b(C++)g(Interface)2044 b(40)585 -4594 y Fo(5.1)96 b(Compiling)24 b(and)g(Linking)53 b(.)45 -b(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h -(.)f(.)g(.)g(.)g(.)p Black 125 w(40)p Black 585 4707 -a(5.2)96 b(Basic)23 b(Manipulation)58 b(.)45 b(.)g(.)g(.)h(.)f(.)g(.)g -(.)g(.)h(.)f(.)g(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.)h(.)f(.)g(.)g(.)g(.) -p Black 125 w(40)p Black 448 4910 a Fp(6)92 b(Ackno)o(wledgments)2050 -b(41)p Black 1920 5225 a Fo(2)p Black eop end -%%Page: 3 3 -TeXDict begin 3 2 bop Black Black 585 573 a Fp(Refer)n(ences)2341 -b(41)585 777 y(Index)2539 b(43)p Black 1920 5225 a Fo(3)p -Black eop end -%%Page: 4 4 -TeXDict begin 4 3 bop Black Black 448 573 a Fq(1)120 -b(Intr)n(oduction)448 780 y Fo(The)28 b(CUDD)d(package)30 -b(pro)o(vides)g(functions)g(to)e(manipulate)i(Binary)e(Decision)i -(Diagrams)448 893 y(\(BDDs\))35 b([5,)f(3)q(],)j(Algebraic)g(Decision)g -(Diagrams)e(\(ADDs\))g([1],)j(and)d(Zero-suppressed)448 -1006 y(Binary)f(Decision)g(Diagrams)g(\(ZDDs\))e([12)q(].)56 -b(BDDs)32 b(are)h(used)g(to)g(represent)j(switching)448 -1119 y(functions;)i(ADDs)30 b(are)h(used)h(to)g(represent)h(function)h -(from)d Fm(f)p Fl(0)p Fk(;)15 b Fl(1)p Fm(g)2673 1086 -y Fj(n)2753 1119 y Fo(to)31 b(an)g(arbitrary)i(set.)448 -1231 y(ZDDs)20 b(represent)j(switching)g(functions)g(lik)o(e)f(BDDs;)e -(ho)n(we)n(v)o(er)l(,)i(the)o(y)g(are)f(much)g(more)g(ef)n(\002-)448 -1344 y(cient)27 b(than)f(BDDs)e(when)i(the)g(functions)i(to)d(be)h -(represented)j(are)c(characteristic)30 b(functions)448 -1457 y(of)h(cube)g(sets,)i(or)d(in)h(general,)i(when)e(the)g(ON-set)f -(of)g(the)h(function)i(to)d(be)h(represented)i(is)448 -1570 y(v)o(ery)24 b(sparse.)30 b(The)o(y)23 b(are)h(inferior)i(to)d -(BDDs)f(in)h(other)i(cases.)589 1683 y(The)30 b(package)h(pro)o(vides)h -(a)d(lar)n(ge)i(set)f(of)f(operations)k(on)c(BDDs,)h(ADDs,)f(and)h -(ZDDs,)448 1796 y(functions)d(to)d(con)l(v)o(ert)h(BDDs)e(into)h(ADDs)f -(or)g(ZDDs)g(and)h(vice)g(v)o(ersa,)h(and)f(a)g(lar)n(ge)h(assort-)448 -1909 y(ment)f(of)f(v)n(ariable)j(reordering)g(methods.)589 -2022 y(The)e(CUDD)d(package)k(can)f(be)g(used)g(in)g(three)g(w)o(ays:)p -Black 585 2190 a Fm(\017)p Black 46 w Fo(As)17 b(a)h(black)h(box.)28 -b(In)18 b(this)h(case,)g(the)g(application)i(program)f(that)f(needs)g -(to)f(manipulate)676 2303 y(decision)25 b(diagrams)f(only)g(uses)g(the) -g(e)o(xported)h(functions)g(of)e(the)h(package.)30 b(The)23 -b(rich)676 2416 y(set)g(of)h(functions)i(included)g(in)d(the)h(CUDD)d -(package)26 b(allo)n(ws)e(man)o(y)f(applications)k(to)676 -2529 y(be)21 b(written)i(in)f(this)g(w)o(ay)-6 b(.)28 -b(Section)23 b(3)e(describes)k(ho)n(w)c(to)h(use)g(the)g(e)o(xported)i -(functions)676 2642 y(of)g(the)h(package.)33 b(An)24 -b(application)k(written)d(in)f(terms)h(of)f(the)h(e)o(xported)h -(functions)h(of)676 2755 y(the)f(package)j(needs)e(not)g(concern)i -(itself)e(with)f(the)h(details)h(of)f(v)n(ariable)h(reordering,)676 -2868 y(which)23 b(may)h(tak)o(e)g(place)h(behind)g(the)f(scenes.)p -Black 585 3047 a Fm(\017)p Black 46 w Fo(As)h(a)g(clear)i(box.)36 -b(When)26 b(writing)g(a)g(sophisticated)j(application)g(based)e(on)f -(decision)676 3160 y(diagrams,)35 b(ef)n(\002cienc)o(y)e(often)g -(dictates)h(that)f(some)f(functions)i(be)e(implemented)i(as)676 -3273 y(direct)h(recursi)n(v)o(e)h(manipulation)i(of)c(the)h(diagrams,)j -(instead)e(of)f(being)g(written)g(in)676 3386 y(terms)e(of)g(e)o -(xisting)i(primiti)n(v)o(e)f(functions.)60 b(Section)35 -b(4)d(e)o(xplains)j(ho)n(w)e(to)g(add)h(ne)n(w)676 3499 -y(functions)j(to)f(the)f(CUDD)e(package.)66 b(It)35 b(also)h(details)h -(ho)n(w)d(to)i(write)f(a)g(recursi)n(v)o(e)676 3612 y(function)25 -b(that)f(can)g(be)g(interrupted)i(by)e(dynamic)h(v)n(ariable)g -(reordering.)p Black 585 3792 a Fm(\017)p Black 46 w -Fo(Through)c(an)f(interf)o(ace.)30 b(Object-oriented)23 -b(languages)g(lik)o(e)e(C++)e(and)h(Perl5)g(can)h(free)676 -3905 y(the)k(programmer)h(from)f(the)h(b)n(urden)h(of)e(memory)g -(management.)35 b(A)24 b(C++)g(interf)o(ace)676 4018 -y(is)k(included)i(in)e(the)h(distrib)n(ution)j(of)c(CUDD.)d(It)j -(automatically)k(frees)d(decision)h(di-)676 4131 y(agrams)g(that)f(are) -h(no)f(longer)i(used)f(by)f(the)h(application)i(and)e(o)o(v)o(erloads)h -(operators.)676 4244 y(Almost)i(all)h(the)g(functionality)k(pro)o -(vided)e(by)e(the)g(CUDD)d(e)o(xported)36 b(functions)g(is)676 -4356 y(a)n(v)n(ailable)d(through)g(the)e(C++)f(interf)o(ace,)35 -b(which)c(is)g(especially)j(recommended)f(for)676 4469 -y(f)o(ast)e(prototyping.)56 b(Section)32 b(5)f(e)o(xplains)j(ho)n(w)c -(to)i(use)f(the)h(interf)o(ace.)54 b(A)31 b(Perl5)g(in-)676 -4582 y(terf)o(ace)38 b(also)g(e)o(xists)g(and)f(is)g(ditrib)n(uted)j -(separately)-6 b(.)71 b(\(See)37 b(Section)h(2.2.\))69 -b(Some)676 4695 y(applications)27 b(de\002ne)d(their)g(o)n(wn)f(interf) -o(aces.)31 b(See)23 b(for)h(e)o(xample)g(Section)h(3.18.)448 -4863 y(In)k(the)h(follo)n(wing,)i(the)d(reader)i(is)e(supposed)j(to)d -(be)g(f)o(amiliar)h(with)f(the)h(basic)g(ideas)g(about)448 -4976 y(decision)c(diagrams,)f(as)e(found,)i(for)e(instance,)j(in)d([3)q -(].)p Black 1920 5225 a(4)p Black eop end -%%Page: 5 5 -TeXDict begin 5 4 bop Black Black 448 573 a Fq(2)120 -b(Ho)o(w)29 b(to)h(Get)g(CUDD)448 783 y Fi(2.1)99 b(The)26 -b(CUDD)f(P)o(ackage)448 957 y Fo(The)36 b(CUDD)e(package)39 -b(is)d(a)n(v)n(ailable)j(via)d(anon)o(ymous)j(FTP)34 -b(from)i(vlsi.Colorado.EDU.)448 1070 y(A)29 b(compressed)j(tar)e -(\002le)f(named)h Fh(cudd-2.5.0.tar.)o(gz)22 b Fo(can)31 -b(be)e(found)i(in)f(directory)448 1183 y Fh(pub)p Fo(.)d(Once)c(you)h -(ha)n(v)o(e)h(this)f(\002le,)p Black Black 676 1371 a -Fh(gzip)52 b(-dc)i(cudd-2.5.0.tar)o(.g)o(z)48 b(|)54 -b(tar)g(xvf)f(-)448 1559 y Fo(will)27 b(create)g(directory)j -Fh(cudd-2.5.0)21 b Fo(and)27 b(its)g(subdirectories.)42 -b(These)27 b(directories)j(con-)448 1671 y(tain)h(the)g(decision)i -(diagram)f(package,)i(a)c(fe)n(w)g(support)j(libraries,)h(and)d(a)f(to) -o(y)h(application)448 1784 y(based)23 b(on)f(the)h(decision)h(diagram)f -(package.)30 b(There)22 b(is)g(a)f(README)e(\002le)i(with)h -(instructions)448 1897 y(on)33 b(con\002guration)j(and)d(installation)j -(in)d Fh(cudd-2.5.0)p Fo(.)51 b(Y)-10 b(ou)32 b(can)i(use)f(a)f -(compiler)i(for)448 2010 y(either)25 b(ANSI)d(C)g(or)i(C++.)589 -2123 y(Once)g(you)g(ha)n(v)o(e)g(made)g(the)g(libraries)h(and)f -(program,)h(you)f(can)g(type:)p Black Black 676 2311 -a Fh(cd)53 b(nanotrav)676 2424 y(nanotrav)e(-p)i(1)h(-autodyn)d -(-reordering)f(sifting)h(-trav)676 2537 y(mult32a.blif)448 -2724 y Fo(This)26 b(will)g(run)h(a)e(simple-minded)k(FSM)c(tra)n(v)o -(ersal)j(program.)38 b(\(On)25 b(a)h(2.4)g(GHz)f(Pentium)i(4)448 -2837 y(\(TM\),)g(it)h(tak)o(es)h(about)h(0.5)e(s.\))42 -b(The)28 b(output)i(produced)g(by)f(the)f(program)h(can)g(be)f(check)o -(ed)448 2950 y(against)35 b Fh(cudd-2.5.0/nano)o(tra)o(v/)o(mu)o(lt)o -(32)o(a.o)o(ut)o Fo(.)52 b(More)34 b(information)i(on)e(the)448 -3063 y Fh(nanotrav)19 b Fo(program)25 b(can)f(be)g(found)g(in)g -Fh(cudd-2.5.0/nan)o(otr)o(av)o(/R)o(EA)o(DM)o(E)p Fo(.)589 -3176 y(If)i(you)h(w)o(ant)f(to)g(be)g(noti\002ed)h(of)f(ne)n(w)f -(releases)j(of)e(the)h(CUDD)c(package,)29 b(send)e(a)e(mes-)448 -3289 y(sage)g(to)e Fh(Fabio@Colorado.)o(ED)o(U)p Fo(.)448 -3538 y Fi(2.2)99 b(CUDD)25 b(Friends)448 3712 y Fo(T)-7 -b(w)o(o)18 b(CUDD)g(e)o(xtensions)k(are)e(a)n(v)n(ailable)h(via)f(anon) -o(ymous)i(FTP)17 b(from)i(vlsi.Colorado.EDU.)p Black -585 3900 a Fm(\017)p Black 46 w Fn(P)-7 b(erlDD)27 b -Fo(is)i(an)f(object-oriented)34 b(Perl5)29 b(interf)o(ace)i(to)d(CUDD.) -f(It)h(is)h(or)n(ganized)i(as)e(a)676 4013 y(standard)f(Perl)e(e)o -(xtension)j(module.)39 b(The)26 b(Perl)g(interf)o(ace)j(is)d(at)h(a)f -(some)n(what)h(higher)676 4126 y(le)n(v)o(el)c(than)i(the)e(C++)g -(interf)o(ace,)j(b)n(ut)e(it)f(is)h(not)g(as)f(complete.)p -Black 585 4313 a Fm(\017)p Black 46 w Fn(DDcal)g Fo(is)h(a)g(graphic)h -(BDD)e(calculator)j(based)f(on)f(CUDD,)e(Perl-Tk,)i(and)g(dot.)31 -b(\(See)676 4426 y(Section)24 b(3.19)g(for)g(information)i(on)d -Fn(dot)p Fo(.\))448 4719 y Fq(3)120 b(User')l(s)28 b(Manual)448 -4926 y Fo(This)c(section)h(describes)h(the)e(use)g(of)f(the)h(CUDD)d -(package)26 b(as)d(a)g(black)i(box.)p Black 1920 5225 -a(5)p Black eop end -%%Page: 6 6 -TeXDict begin 6 5 bop Black Black 448 573 a Fi(3.1)99 -b(Compiling)25 b(and)g(Linking)448 747 y Fo(T)-7 b(o)23 -b(b)n(uild)i(an)e(application)k(that)d(uses)g(the)g(CUDD)d(package,)26 -b(you)e(should)h(add)p Black Black 448 935 a Fh(#include)51 -b("util.h")448 1048 y(#include)g("cudd.h")448 1235 y -Fo(to)32 b(your)g(source)h(\002les,)g(and)g(should)g(link)f -Fh(libcudd.a)p Fo(,)d Fh(libmtr.a)p Fo(,)f Fh(libst.a)p -Fo(,)i(and)448 1348 y Fh(libutil.a)23 b Fo(to)28 b(your)h(e)o(x)o -(ecutable.)43 b(\(All)28 b(these)h(libraries)g(are)f(part)h(of)f(the)g -(distrib)n(ution.\))448 1461 y(Some)20 b(platforms)h(require)h -(speci\002c)e(compiler)i(and)e(link)o(er)h(\003ags.)28 -b(Refer)20 b(to)g(the)g Fh(Makefile)448 1574 y Fo(in)k(the)g(top)f(le)n -(v)o(el)h(directory)i(of)e(the)f(distrib)n(ution.)589 -1687 y(K)n(eep)d(in)g(mind)g(that)h(whate)n(v)o(er)g(\003ags)e(af)n -(fect)i(the)g(size)f(of)g(data)h(structures\227for)i(instance)448 -1800 y(the)e(\003ags)f(used)g(to)g(use)h(64-bit)g(pointers)h(where)f(a) -n(v)n(ailable\227must)i(be)d(speci\002ed)h(when)f(com-)448 -1913 y(piling)25 b(both)g(CUDD)c(and)j(the)g(\002les)f(that)h(include)h -(its)f(header)h(\002les.)448 2162 y Fi(3.2)99 b(Basic)25 -b(Data)g(Structur)n(es)448 2336 y Fp(3.2.1)92 b(Nodes)448 -2510 y Fo(BDDs,)24 b(ADDs,)h(and)h(ZDDs)d(are)j(made)g(of)f(DdNode')-5 -b(s.)35 b(A)25 b(DdNode)g(\(node)i(for)f(short\))g(is)g(a)448 -2623 y(structure)j(with)d(se)n(v)o(eral)i(\002elds.)37 -b(Those)27 b(that)g(are)f(of)h(interest)h(to)e(the)h(application)j -(that)d(uses)448 2736 y(the)e(CUDD)d(package)27 b(as)d(a)g(black)i(box) -f(are)f(the)h(v)n(ariable)h(inde)o(x,)g(the)e(reference)j(count,)f(and) -448 2849 y(the)f(v)n(alue.)33 b(The)24 b(remaining)i(\002elds)f(are)f -(pointers)j(that)e(connect)i(nodes)e(among)g(themselv)o(es)448 -2962 y(and)f(that)g(are)g(used)g(to)g(implement)h(the)e(unique)j -(table.)j(\(See)23 b(Section)i(3.2.2.\))589 3075 y(The)h -Fn(inde)n(x)i Fo(\002eld)e(holds)h(the)g(name)f(of)g(the)h(v)n(ariable) -h(that)e(labels)i(the)e(node.)38 b(The)25 b(inde)o(x)448 -3188 y(of)37 b(a)f(v)n(ariable)i(is)f(a)f(permanent)j(attrib)n(ute)g -(that)e(re\003ects)g(the)g(order)h(of)e(creation.)70 -b(Inde)o(x)448 3301 y(0)26 b(corresponds)k(to)c(the)g(v)n(ariable)i -(created)g(\002rst.)36 b(On)25 b(a)h(machine)h(with)f(32-bit)h -(pointers,)i(the)448 3414 y(maximum)21 b(number)h(of)e(v)n(ariables)j -(is)d(the)h(lar)n(gest)i(v)n(alue)e(that)h(can)f(be)f(stored)j(in)d(an) -h(unsigned)448 3527 y(short)27 b(inte)o(ger)g(minus)f(1.)35 -b(The)25 b(lar)n(gest)j(inde)o(x)f(is)e(reserv)o(ed)j(for)e(the)g -(constant)h(nodes.)37 b(When)448 3640 y(64-bit)24 b(pointers)g(are)e -(used,)h(the)f(maximum)g(number)h(of)f(v)n(ariables)i(is)e(the)g(lar)n -(gest)i(v)n(alue)f(that)448 3752 y(can)h(be)g(stored)h(in)e(an)h -(unsigned)i(inte)o(ger)e(minus)g(1.)589 3865 y(When)k(v)n(ariables)i -(are)e(reordered)i(to)e(reduce)h(the)f(size)g(of)f(the)h(decision)i -(diagrams,)g(the)448 3978 y(v)n(ariables)h(may)e(shift)h(in)f(the)g -(order)l(,)i(b)n(ut)f(the)o(y)f(retain)h(their)g(indices.)47 -b(The)28 b(package)j(k)o(eeps)448 4091 y(track)d(of)e(the)h(v)n -(ariable)h(permutation)h(\(and)e(its)g(in)l(v)o(erse\).)40 -b(The)26 b(application)j(is)e(not)g(af)n(fected)448 4204 -y(by)d(v)n(ariable)h(reordering,)h(e)o(xcept)f(in)e(the)h(follo)n(wing) -h(cases.)p Black 585 4392 a Fm(\017)p Black 46 w Fo(If)17 -b(the)i(application)i(uses)e(generators)i(\()p Fn(Cudd)p -2104 4392 28 4 v 34 w(F)-10 b(or)m(eac)o(hCube)20 b Fo(and)e -Fn(Cudd)p 2985 4392 V 34 w(F)-10 b(or)m(eac)o(hNode)p -Fo(\))676 4505 y(and)20 b(reordering)j(is)d(enabled,)j(then)e(it)f -(must)g(tak)o(e)h(care)f(not)h(to)f(call)h(an)o(y)f(operation)j(that) -676 4618 y(may)29 b(create)i(ne)n(w)e(nodes)j(\(and)e(hence)h(possibly) -h(trigger)g(reordering\).)51 b(This)29 b(is)h(be-)676 -4730 y(cause)j(the)g(cubes)h(\(i.e.,)g(paths\))g(and)f(nodes)h(of)e(a)g -(diagram)i(change)g(as)f(a)f(result)h(of)676 4843 y(reordering.)p -Black 1920 5225 a(6)p Black eop end -%%Page: 7 7 -TeXDict begin 7 6 bop Black Black Black 585 573 a Fm(\017)p -Black 46 w Fo(If)26 b(the)h(application)j(uses)d Fn(Cudd)p -1712 573 28 4 v 34 w(bddConstr)o(ain)j Fo(and)d(reordering)i(tak)o(es)f -(place,)h(then)676 686 y(the)23 b(property)j(of)e Fn(Cudd)p -1440 686 V 33 w(bddConstr)o(ain)j Fo(of)c(being)i(an)e(image)h -(restrictor)i(is)e(lost.)589 873 y(The)j(CUDD)f(package)j(relies)g(on)e -(garbage)i(collection)h(to)e(reclaim)g(the)g(memory)f(used)448 -986 y(by)35 b(diagrams)i(that)e(are)h(no)f(longer)h(in)f(use.)64 -b(The)34 b(scheme)i(emplo)o(yed)h(for)e(garbage)i(col-)448 -1099 y(lection)32 b(is)d(based)i(on)f(k)o(eeping)h(a)e(reference)j -(count)f(for)f(each)g(node.)48 b(The)29 b(references)k(that)448 -1212 y(are)26 b(counted)i(are)e(both)h(the)f(internal)h(references)i -(\(references)f(from)e(other)h(nodes\))g(and)f(e)o(x-)448 -1325 y(ternal)37 b(references)h(\(typically)g(references)g(from)d(the)g -(calling)i(en)l(vironment\).)68 b(When)35 b(an)448 1438 -y(application)25 b(creates)f(a)d(ne)n(w)g(BDD,)f(ADD,)f(or)j(ZDD,)d(it) -j(must)f(increase)j(its)e(reference)i(count)448 1551 -y(e)o(xplicitly)-6 b(,)40 b(through)d(a)e(call)g(to)g -Fn(Cudd)p 1707 1551 V 34 w(Ref)13 b Fo(.)62 b(Similarly)-6 -b(,)38 b(when)e(a)e(diagram)i(is)f(no)g(longer)448 1664 -y(needed,)28 b(the)e(application)i(must)e(call)g Fn(Cudd)p -1877 1664 V 34 w(Recur)o(siveDer)m(ef)41 b Fo(\(for)26 -b(BDDs)e(and)i(ADDs\))e(or)448 1777 y Fn(Cudd)p 649 1777 -V 34 w(Recur)o(siveDer)m(efZdd)29 b Fo(\(for)24 b(ZDDs\))e(to)h -(\223rec)o(ycle\224)j(the)e(nodes)h(of)e(the)h(diagram.)589 -1890 y(T)-6 b(erminal)37 b(nodes)h(carry)g(a)e(v)n(alue.)69 -b(This)36 b(is)h(especially)i(important)g(for)d(ADDs.)67 -b(By)448 2002 y(def)o(ault,)29 b(the)f(v)n(alue)f(is)g(a)f(double.)41 -b(T)-7 b(o)25 b(change)k(to)d(something)j(dif)n(ferent)g(\(e.g.,)e(an)g -(inte)o(ger\),)448 2115 y(the)21 b(package)i(must)d(be)h(modi\002ed)g -(and)g(recompiled.)30 b(Support)21 b(for)g(this)g(process)i(is)d -(currently)448 2228 y(v)o(ery)k(rudimentary)-6 b(.)448 -2474 y Fp(3.2.2)92 b(The)22 b(Manager)448 2648 y Fo(All)27 -b(nodes)i(used)g(in)f(BDDs,)f(ADDs,)g(and)h(ZDDs)e(are)i(k)o(ept)g(in)g -(special)h(hash)g(tables)g(called)448 2761 y(the)36 b -Fn(unique)i(tables)p Fo(.)66 b(Speci\002cally)-6 b(,)40 -b(BDDs)35 b(and)h(ADDs)e(share)j(the)f(same)f(unique)j(table,)448 -2874 y(whereas)24 b(ZDDs)d(ha)n(v)o(e)j(their)f(o)n(wn)f(table.)30 -b(As)22 b(the)h(name)f(implies,)i(the)f(main)g(purpose)h(of)f(the)448 -2987 y(unique)i(table)e(is)g(to)f(guarantee)k(that)d(each)g(node)h(is)e -(unique;)j(that)e(is,)g(there)g(is)g(no)g(other)g(node)448 -3100 y(labeled)h(by)e(the)h(same)f(v)n(ariable)i(and)e(with)g(the)g -(same)h(children.)30 b(This)22 b(uniqueness)j(property)448 -3213 y(mak)o(es)34 b(decision)i(diagrams)f(canonical.)61 -b(The)33 b(unique)i(tables)f(and)g(some)g(auxiliary)i(data)448 -3326 y(structures)e(mak)o(e)d(up)g(the)g(DdManager)h(\(manager)h(for)e -(short\).)52 b(Though)32 b(the)f(application)448 3439 -y(that)c(uses)h(only)f(the)g(e)o(xported)h(functions)h(needs)f(not)f -(be)f(concerned)j(with)e(most)f(details)i(of)448 3552 -y(the)20 b(manager)l(,)h(it)e(has)h(to)f(deal)h(with)f(the)h(manager)g -(in)g(the)f(follo)n(wing)i(sense.)28 b(The)19 b(application)448 -3665 y(must)28 b(initialize)h(the)f(manager)h(by)e(calling)i(an)e -(appropriate)k(function.)42 b(\(See)27 b(Section)h(3.3.\))448 -3778 y(Subsequently)-6 b(,)25 b(it)c(must)h(pass)g(a)f(pointer)j(to)d -(the)h(manager)h(to)e(all)h(the)f(functions)j(that)f(operate)448 -3890 y(on)h(decision)i(diagrams.)589 4003 y(W)l(ith)k(the)g(e)o -(xception)i(of)d(a)g(fe)n(w)g(statistical)j(counters,)h(there)d(are)g -(no)f(global)i(v)n(ariables)448 4116 y(in)f(the)g(CUDD)d(package.)50 -b(Therefore,)32 b(it)e(is)f(quite)i(possible)h(to)d(ha)n(v)o(e)i -(multiple)g(managers)448 4229 y(simultaneously)h(acti)n(v)o(e)d(in)f -(the)g(same)g(application.)2140 4196 y Fg(1)2223 4229 -y Fo(It)g(is)g(the)g(pointers)i(to)e(the)h(managers)448 -4342 y(that)24 b(tell)g(the)g(functions)i(on)e(what)f(data)h(the)o(y)g -(should)i(operate.)p Black 448 4423 1196 4 v 554 4479 -a Ff(1)583 4511 y Fe(The)18 b(global)h(statistical)e(counters)i(are)f -(used)h(locally;)g(hence)g(the)o(y)f(are)h(compatible)g(with)e(the)i -(use)f(of)g(multi-)448 4602 y(ple)h(managers.)p Black -Black 1920 5225 a Fo(7)p Black eop end -%%Page: 8 8 -TeXDict begin 8 7 bop Black Black 448 573 a Fp(3.2.3)92 -b(Cache)448 747 y Fo(Ef)n(\002cient)23 b(recursi)n(v)o(e)i -(manipulation)h(of)e(decision)h(diagrams)f(requires)i(the)d(use)h(of)f -(a)f(table)i(to)448 860 y(store)i(computed)g(results.)34 -b(This)24 b(table)i(is)e(called)i(here)g(the)e Fn(cac)o(he)i -Fo(because)g(it)f(is)f(ef)n(fecti)n(v)o(ely)448 973 y(handled)g(lik)o -(e)f(a)e(cache)i(of)f(v)n(ariable)i(b)n(ut)e(limited)h(capacity)-6 -b(.)30 b(The)22 b(CUDD)d(package)24 b(starts)f(by)448 -1086 y(def)o(ault)31 b(with)e(a)g(small)g(cache,)i(and)f(increases)h -(its)e(size)h(until)g(either)g(no)f(further)i(bene\002t)e(is)448 -1199 y(achie)n(v)o(ed,)c(or)f(a)f(limit)g(size)h(is)f(reached.)31 -b(The)23 b(user)h(can)g(in\003uence)h(this)f(polic)o(y)g(by)g(choosing) -448 1312 y(initial)h(and)f(limit)g(v)n(alues)g(for)g(the)g(cache)h -(size.)589 1425 y(T)-7 b(oo)22 b(small)g(a)f(cache)i(will)e(cause)i -(frequent)h(o)o(v)o(erwriting)f(of)f(useful)h(results.)30 -b(T)-7 b(oo)21 b(lar)n(ge)i(a)448 1537 y(cache)h(will)d(cause)j(o)o(v)o -(erhead,)g(because)g(the)e(whole)h(cache)g(is)f(scanned)i(e)n(v)o(ery)f -(time)f(garbage)448 1650 y(collection)27 b(tak)o(es)f(place.)32 -b(The)24 b(optimal)h(parameters)i(depend)f(on)e(the)h(speci\002c)g -(application.)448 1763 y(The)e(def)o(ault)j(parameters)f(w)o(ork)f -(reasonably)i(well)e(for)f(a)g(lar)n(ge)i(spectrum)g(of)f -(applications.)589 1876 y(The)32 b(cache)h(of)f(the)h(CUDD)d(package)k -(is)e(used)h(by)f(most)g(recursi)n(v)o(e)i(functions)h(of)d(the)448 -1989 y(package,)26 b(and)e(can)f(be)h(used)g(by)g(user)n(-supplied)k -(functions)e(as)d(well.)29 b(\(See)23 b(Section)h(4.4.\))448 -2236 y Fi(3.3)99 b(Initializing)24 b(and)i(Shutting)g(Do)o(wn)f(a)g -(DdManager)448 2411 y Fo(T)-7 b(o)27 b(use)g(the)h(functions)i(in)d -(the)h(CUDD)d(package,)30 b(one)e(has)g(\002rst)f(to)g(initialize)j -(the)d(package)448 2524 y(itself)e(by)e(calling)j Fn(Cudd)p -1238 2524 28 4 v 33 w(Init)r Fo(.)j(This)24 b(function)h(tak)o(es)g -(four)f(parameters:)p Black 585 2702 a Fm(\017)p Black -46 w Fo(numV)-10 b(ars:)28 b(It)21 b(is)h(the)f(initial)i(number)f(of)g -(v)n(ariables)h(for)f(BDDs)e(and)i(ADDs.)k(If)21 b(the)h(to-)676 -2815 y(tal)e(number)i(of)f(v)n(ariables)h(needed)h(by)d(the)h -(application)j(is)d(kno)n(wn,)g(then)g(it)g(is)f(slightly)676 -2928 y(more)h(ef)n(\002cient)h(to)f(create)i(a)e(manager)i(with)e(that) -h(number)g(of)f(v)n(ariables.)30 b(If)22 b(the)f(num-)676 -3041 y(ber)g(is)g(unkno)n(wn,)i(it)e(can)h(be)f(set)g(to)g(0,)h(or)f -(to)g(an)o(y)g(other)i(lo)n(wer)e(bound)h(on)g(the)f(number)676 -3154 y(of)28 b(v)n(ariables.)47 b(Requesting)31 b(more)e(v)n(ariables)i -(than)f(are)f(actually)i(needed)f(is)f(not)g(in-)676 -3267 y(correct,)24 b(b)n(ut)g(is)g(not)g(ef)n(\002cient.)p -Black 585 3450 a Fm(\017)p Black 46 w Fo(numV)-10 b(arsZ:)27 -b(It)h(is)f(the)h(initial)h(number)f(of)g(v)n(ariables)i(for)d(ZDDs.)40 -b(See)27 b(Sections)h(3.9)676 3563 y(and)c(3.11)f(for)h(a)f(discussion) -k(of)c(the)h(v)n(alue)g(of)g(this)g(ar)n(gument.)p Black -585 3747 a Fm(\017)p Black 46 w Fo(numSlots:)42 b(Determines)31 -b(the)f(initial)h(size)f(of)g(each)h(subtable)h(of)d(the)h(unique)i -(table.)676 3860 y(There)c(is)g(a)f(subtable)j(for)f(each)f(v)n -(ariable.)44 b(The)28 b(size)g(of)g(each)h(subtable)h(is)e(dynami-)676 -3973 y(cally)e(adjusted)i(to)e(re\003ect)g(the)g(number)h(of)f(nodes.) -37 b(It)25 b(is)h(normally)h(O.K.)d(to)i(use)g(the)676 -4086 y(def)o(ault)f(v)n(alue)f(for)g(this)g(parameter)l(,)h(which)f(is) -g(CUDD)p 2448 4086 V 31 w(UNIQ)o(UE)p 2828 4086 V 31 -w(SLO)l(TS.)p Black 585 4270 a Fm(\017)p Black 46 w Fo(cacheSize:)39 -b(It)28 b(is)g(the)g(initial)h(size)g(\(number)g(of)f(entries\))h(of)f -(the)h(cache.)43 b(Its)28 b(def)o(ault)676 4383 y(v)n(alue)c(is)f(CUDD) -p 1240 4383 V 32 w(CA)l(CHE)p 1578 4383 V 31 w(SLO)l(TS.)p -Black 585 4567 a Fm(\017)p Black 46 w Fo(maxMemory:)29 -b(It)23 b(is)g(the)h(tar)n(get)g(v)n(alue)g(for)f(the)h(maximum)f -(memory)g(occupation)j(\(in)676 4680 y(bytes\).)k(The)23 -b(package)i(uses)g(this)f(v)n(alue)g(to)f(decide)i(tw)o(o)f -(parameters.)p Black 785 4863 a Fp(\226)p Black 46 w -Fo(the)29 b(maximum)f(size)i(to)e(which)i(the)f(cache)h(will)e(gro)n(w) --6 b(,)30 b(re)o(gardless)g(of)f(the)g(hit)876 4976 y(rate)24 -b(or)f(the)h(size)g(of)f(the)h(unique)h(table.)p Black -1920 5225 a(8)p Black eop end -%%Page: 9 9 -TeXDict begin 9 8 bop Black Black Black 785 573 a Fp(\226)p -Black 46 w Fo(the)19 b(maximum)g(size)h(to)f(which)h(gro)n(wth)f(of)g -(the)h(unique)h(table)f(will)f(be)g(preferred)876 686 -y(to)k(garbage)i(collection.)676 873 y(If)j(maxMemory)h(is)g(set)g(to)f -(0,)h(CUDD)e(tries)i(to)g(guess)g(a)f(good)i(v)n(alue)g(based)f(on)g -(the)676 986 y(a)n(v)n(ailable)c(memory)-6 b(.)448 1174 -y(A)23 b(typical)i(call)f(to)f Fn(Cudd)p 1255 1174 28 -4 v 34 w(Init)j Fo(may)d(look)h(lik)o(e)g(this:)p Black -Black 557 1362 a Fh(manager)52 b(=)i(Cudd_Init\(0,0,)o(CUD)o(D_)o(UN)o -(IQ)o(UE)o(_SL)o(OT)o(S,)o(CU)o(DD)o(_CA)o(CH)o(E_)o(SL)o(OT)o(S,0)o -(\);)448 1549 y Fo(T)-7 b(o)34 b(reclaim)i(all)f(the)g(memory)g -(associated)j(with)d(a)f(manager)l(,)39 b(an)c(application)j(must)d -(call)448 1662 y Fn(Cudd)p 649 1662 V 34 w(Quit)r Fo(.)28 -b(This)c(is)f(normally)i(done)f(before)h(e)o(xiting.)448 -1911 y Fi(3.4)99 b(Setting)26 b(P)o(arameters)448 2086 -y Fo(The)i(package)j(pro)o(vides)f(se)n(v)o(eral)g(functions)h(to)d -(set)h(the)g(parameters)h(that)f(control)i(v)n(arious)448 -2198 y(functions.)g(F)o(or)22 b(instance,)j(the)e(package)i(has)f(an)f -(automatic)h(w)o(ay)f(of)g(determining)i(whether)448 -2311 y(a)f(lar)n(ger)i(unique)f(table)g(w)o(ould)g(mak)o(e)f(the)g -(application)k(run)c(f)o(aster)-5 b(.)32 b(In)24 b(that)g(case,)h(the)f -(pack-)448 2424 y(age)19 b(enters)h(a)e(\223f)o(ast)i(gro)n(wth\224)f -(mode)g(in)g(which)g(resizing)i(of)d(the)h(unique)h(subtables)i(is)c(f) -o(a)n(v)n(ored)448 2537 y(o)o(v)o(er)25 b(garbage)h(collection.)36 -b(When)25 b(the)g(unique)h(table)g(reaches)g(a)f(gi)n(v)o(en)g(size,)h -(ho)n(we)n(v)o(er)l(,)f(the)448 2650 y(package)d(returns)e(to)g(the)f -(normal)h(\223slo)n(w)f(gro)n(wth\224)i(mode,)f(e)n(v)o(en)f(though)i -(the)e(conditions)k(that)448 2763 y(caused)k(the)f(transition)i(to)d(f) -o(ast)h(gro)n(wth)f(still)h(pre)n(v)n(ail.)35 b(The)25 -b(limit)g(size)h(for)f(f)o(ast)h(gro)n(wth)g(can)448 -2876 y(be)k(read)h(by)f Fn(Cudd)p 1070 2876 V 33 w(ReadLooseUpT)-8 -b(o)31 b Fo(and)g(changed)h(by)e Fn(Cudd)p 2544 2876 -V 33 w(SetLooseUpT)-8 b(o)p Fo(.)49 b(Similar)448 2989 -y(pairs)25 b(of)e(functions)j(e)o(xist)e(for)g(se)n(v)o(eral)h(other)f -(parameters.)31 b(See)23 b(also)h(Section)h(4.8.)448 -3238 y Fi(3.5)99 b(Constant)26 b(Functions)448 3412 y -Fo(The)18 b(CUDD)e(P)o(ackage)j(de\002nes)g(se)n(v)o(eral)h(constant)g -(functions.)30 b(These)18 b(functions)j(are)e(created)448 -3525 y(when)24 b(the)g(manager)g(is)g(initialized,)i(and)e(are)g -(accessible)i(through)f(the)f(manager)h(itself.)448 3771 -y Fp(3.5.1)92 b(One,)22 b(Logic)i(Zer)n(o,)g(and)e(Arithmetic)i(Zer)n -(o)448 3945 y Fo(The)36 b(constant)i(1)d(\(returned)j(by)e -Fn(Cudd)p 1738 3945 V 34 w(ReadOne)p Fo(\))g(is)g(common)g(to)g(BDDs,)h -(ADDs,)g(and)448 4058 y(ZDDs.)42 b(Ho)n(we)n(v)o(er)l(,)29 -b(its)f(meaning)i(is)e(dif)n(ferent)i(for)f(ADDs)d(and)j(BDDs,)f(on)g -(the)h(one)g(hand,)448 4171 y(and)c(ZDDs,)f(on)g(the)h(other)h(hand.)33 -b(The)25 b(diagram)g(consisting)j(of)d(the)g(constant)h(1)f(node)g -(only)448 4284 y(represents)33 b(the)d(constant)i(1)e(function)i(for)e -(ADDs)f(and)h(BDDs.)46 b(F)o(or)29 b(ZDDs,)h(its)g(meaning)448 -4397 y(depends)i(on)d(the)g(number)i(of)e(v)n(ariables:)42 -b(It)29 b(is)g(the)h(conjunction)j(of)c(the)g(complements)i(of)448 -4510 y(all)j(v)n(ariables.)63 b(Con)l(v)o(ersely)-6 b(,)38 -b(the)d(representation)j(of)c(the)g(constant)i(1)e(function)i(depends) -448 4623 y(on)28 b(the)f(number)h(of)f(v)n(ariables.)42 -b(The)26 b(constant)k(1)c(function)k(of)d Fk(n)f Fo(v)n(ariables)j(is)e -(returned)i(by)448 4736 y Fn(Cudd)p 649 4736 V 34 w(ReadZddOne)p -Fo(.)p Black 1920 5225 a(9)p Black eop end -%%Page: 10 10 -TeXDict begin 10 9 bop Black Black 589 573 a Fo(The)29 -b(constant)j(0)c(is)h(common)h(to)f(ADDs)f(and)h(ZDDs,)g(b)n(ut)h(not)f -(to)g(BDDs.)44 b(The)29 b(BDD)448 686 y(logic)21 b(0)f(is)g -Fp(not)g Fo(associated)i(with)e(the)h(constant)h(0)e(function:)29 -b(It)20 b(is)g(obtained)i(by)f(complemen-)448 799 y(tation)26 -b(\()p Fn(Cudd)p 910 799 28 4 v 34 w(Not)r Fo(\))e(of)h(the)g(constant) -i(1.)32 b(\(It)24 b(is)h(also)g(returned)i(by)e Fn(Cudd)p -2795 799 V 33 w(ReadLo)o(gicZer)l(o)p Fo(.\))448 912 -y(All)e(other)i(constants)h(are)e(speci\002c)g(to)f(ADDs.)448 -1157 y Fp(3.5.2)92 b(Pr)n(ede\002ned)22 b(Constants)448 -1332 y Fo(Besides)34 b(0)e(\(returned)j(by)d Fn(Cudd)p -1528 1332 V 34 w(ReadZer)l(o)p Fo(\))h(and)g(1,)h(the)f(follo)n(wing)h -(constant)h(functions)448 1445 y(are)24 b(created)h(at)f -(initialization)j(time.)p Black 562 1632 a(1.)p Black -46 w(PlusIn\002nity)f(and)g(MinusIn\002nity:)34 b(On)25 -b(computers)i(implementing)g(the)e(IEEE)e(stan-)676 1745 -y(dard)39 b(754)g(for)f(\003oating-point)k(arithmetic,)h(these)d(tw)o -(o)e(constants)j(are)d(set)h(to)f(the)676 1858 y(signed)19 -b(in\002nities.)29 b(On)17 b(the)h(DEC)e(Alphas,)k(the)e(option)i -Fh(-ieee_with_no_i)o(ne)o(xa)o(ct)676 1971 y Fo(or)33 -b Fh(-ieee_with_inexa)o(ct)26 b Fo(must)34 b(be)g(passed)h(to)f(the)g -(DEC)e(compiler)j(to)f(get)676 2084 y(support)26 b(of)e(the)h(IEEE)d -(standard.)34 b(\(The)24 b(compiler)i(still)f(produces)h(a)e(w)o -(arning,)i(b)n(ut)f(it)676 2197 y(can)30 b(be)h(ignored.\))52 -b(Compiling)32 b(with)e(those)i(options)g(may)e(cause)i(substantial)i -(per)n(-)676 2310 y(formance)39 b(de)o(gradation)j(on)c(the)g(Ev)n -(olution)j(IV)c(CPUs.)71 b(\(Especially)41 b(if)d(the)g(ap-)676 -2423 y(plication)d(does)f(use)f(the)g(in\002nities.\))58 -b(The)33 b(problem)h(is)e(reportedly)k(solv)o(ed)e(in)f(the)676 -2536 y(Ev)n(olution)h(V)d(CPUs.)55 b(If)32 b Fh(gcc)e -Fo(is)j(used)g(to)f(compile)i(CUDD)c(on)j(the)g(Alphas,)i(the)676 -2648 y(symbol)26 b Fh(HAVE)p 1193 2648 V 31 w(IEEE)p -1444 2648 V 31 w(754)d Fo(must)j(be)f(unde\002ned.)37 -b(\(See)25 b(the)h(Mak)o(e\002le)g(for)f(the)h(de-)676 -2761 y(tails.\))39 b(The)26 b(v)n(alues)i(of)e(these)i(constants)h(are) -e(returned)i(by)d Fn(Cudd)p 2802 2761 V 34 w(ReadPlusIn\002nity)676 -2874 y Fo(and)e Fn(Cudd)p 1031 2874 V 33 w(ReadMinusIn\002nity)p -Fo(.)p Black 562 3062 a(2.)p Black 46 w(Epsilon:)38 b(This)28 -b(constant,)j(initially)f(set)e(to)f Fl(10)2183 3029 -y Fd(\000)p Fc(12)2314 3062 y Fo(,)h(is)f(used)i(in)f(comparing)h -(\003oating)676 3175 y(point)e(v)n(alues)g(for)f(equality)-6 -b(.)39 b(Its)26 b(v)n(alue)h(is)f(returned)j(by)d Fn(Cudd)p -2688 3175 V 34 w(ReadEpsilon)p Fo(,)i(and)f(it)676 3288 -y(can)h(be)g(modi\002ed)h(by)g(calling)g Fn(Cudd)p 1887 -3288 V 34 w(SetEpsilon)p Fo(.)45 b(Unlik)o(e)29 b(the)g(other)g -(constants,)j(it)676 3401 y(does)24 b(not)g(correspond)i(to)e(a)f -(node.)448 3646 y Fp(3.5.3)92 b(Backgr)n(ound)448 3821 -y Fo(The)22 b(background)k(v)n(alue)e(is)e(a)g(constant)j(typically)g -(used)e(to)g(represent)h(non-e)o(xisting)i(arcs)d(in)448 -3934 y(graphs.)31 b(Consider)26 b(a)d(shortest)j(path)e(problem.)31 -b(T)-7 b(w)o(o)22 b(nodes)j(that)g(are)f(not)g(connected)i(by)e(an)448 -4047 y(arc)31 b(can)f(be)g(re)o(garded)i(as)e(being)h(joined)h(by)e(an) -g(arc)g(of)g(in\002nite)h(length.)50 b(In)30 b(shortest)j(path)448 -4159 y(problems,)27 b(it)d(is)g(therefore)j(con)l(v)o(enient)h(to)d -(set)g(the)g(background)j(v)n(alue)d(to)g(PlusIn\002nity.)33 -b(In)448 4272 y(netw)o(ork)26 b(\003o)n(w)e(problems,)i(on)f(the)g -(other)h(hand,)g(tw)o(o)e(nodes)i(not)g(connected)h(by)e(an)g(arc)g -(can)448 4385 y(be)j(re)o(garded)h(as)f(joined)h(by)f(an)g(arc)g(of)f -(0)h(capacity)-6 b(.)43 b(F)o(or)27 b(these)i(problems,)h(therefore,)h -(it)c(is)448 4498 y(more)i(con)l(v)o(enient)j(to)c(set)h(the)g -(background)j(v)n(alue)d(to)g(0.)43 b(In)29 b(general,)i(when)e -(representing)448 4611 y(sparse)c(matrices,)g(the)e(background)k(v)n -(alue)e(is)e(the)h(v)n(alue)g(that)g(is)g(assumed)h(implicitly)-6 -b(.)589 4724 y(At)18 b(initialization,)k(the)d(background)i(v)n(alue)e -(is)f(set)g(to)g(0.)27 b(It)18 b(can)g(be)g(read)h(with)f -Fn(Cudd)p 3237 4724 V 34 w(ReadBac)n(kgr)l(ound)r Fo(,)448 -4837 y(and)k(modi\002ed)f(with)f Fn(Cudd)p 1325 4837 -V 34 w(SetBac)n(kgr)l(ound)p Fo(.)31 b(The)21 b(background)j(v)n(alue)d -(af)n(fects)h(procedures)p Black 1897 5225 a(10)p Black -eop end -%%Page: 11 11 -TeXDict begin 11 10 bop Black Black 448 573 a Fo(that)34 -b(read)f(sparse)i(matrices/graphs)h(\()p Fn(Cudd)p 1903 -573 28 4 v 34 w(addRead)h Fo(and)c Fn(Cudd)p 2654 573 -V 34 w(addHarwell)p Fo(\),)k(proce-)448 686 y(dures)31 -b(that)f(print)g(out)f(sum-of-product)34 b(e)o(xpressions)e(for)d(ADDs) -f(\()p Fn(Cudd)p 2855 686 V 34 w(PrintMinterm)p Fo(\),)448 -799 y(generators)43 b(of)d(cubes)h(\()p Fn(Cudd)p 1458 -799 V 34 w(F)-10 b(or)m(eac)o(hCube)p Fo(\),)46 b(and)40 -b(procedures)j(that)e(count)g(minterms)448 912 y(\()p -Fn(Cudd)p 679 912 V 34 w(CountMinterm)p Fo(\).)448 1157 -y Fp(3.5.4)92 b(New)22 b(Constants)448 1332 y Fo(Ne)n(w)d(constant)j -(can)f(be)f(created)i(by)e(calling)i Fn(Cudd)p 2070 1332 -V 34 w(addConst)r Fo(.)29 b(This)20 b(function)i(will)e(retrie)n(v)o(e) -448 1445 y(the)31 b(ADD)e(for)i(the)g(desired)h(constant,)i(if)d(it)f -(already)i(e)o(xist,)h(or)e(it)f(will)g(create)i(a)e(ne)n(w)g(one.)448 -1558 y(Ob)o(viously)-6 b(,)25 b(ne)n(w)e(constants)j(should)f(only)g -(be)e(used)i(when)e(manipulating)k(ADDs.)448 1807 y Fi(3.6)99 -b(Cr)n(eating)26 b(V)-9 b(ariables)448 1981 y Fo(Decision)28 -b(diagrams)g(are)e(typically)j(created)f(by)e(combining)i(simpler)g -(decision)g(diagrams.)448 2094 y(The)22 b(simplest)h(decision)h -(diagrams,)g(of)e(course,)h(cannot)h(be)e(created)h(in)f(that)h(w)o(ay) --6 b(.)28 b(Constant)448 2207 y(functions)e(ha)n(v)o(e)e(been)g -(discussed)h(in)e(Section)h(3.5.)29 b(In)23 b(this)g(section)i(we)d -(discuss)j(the)f(simple)448 2320 y(v)n(ariable)i(functions,)f(also)g -(kno)n(wn)e(as)h Fn(pr)l(ojection)i(functions)p Fo(.)448 -2566 y Fp(3.6.1)92 b(New)22 b(BDD)g(and)g(ADD)g(V)-8 -b(ariables)448 2740 y Fo(The)27 b(projection)j(functions)g(are)e -(distinct)h(for)f(BDDs)d(and)j(ADDs.)39 b(A)26 b(projection)k(function) -448 2853 y(for)24 b(BDDs)d(consists)k(of)e(an)h(internal)h(node)f(with) -f(both)h(outgoing)h(arcs)f(pointing)h(to)e(the)h(con-)448 -2966 y(stant)h(1.)j(The)23 b Fn(else)h Fo(arc)g(is)f(complemented.)589 -3079 y(An)e(ADD)e(projection)k(function,)h(on)d(the)g(other)h(hand,)g -(has)f(the)g Fn(else)h Fo(pointer)g(directed)h(to)448 -3192 y(the)35 b(arithmetic)h(zero)f(function.)64 b(One)34 -b(should)i(ne)n(v)o(er)f(mix)f(the)h(tw)o(o)f(types)h(of)f(v)n -(ariables.)448 3304 y(BDD)k(v)n(ariables)k(should)g(be)e(used)h(when)f -(manipulating)j(BDDs,)f(and)e(ADD)e(v)n(ariables)448 -3417 y(should)c(be)e(used)h(when)f(manipulating)j(ADDs.)53 -b(Three)33 b(functions)h(are)f(pro)o(vided)h(to)e(cre-)448 -3530 y(ate)24 b(BDD)e(v)n(ariables:)p Black 585 3718 -a Fm(\017)p Black 46 w Fn(Cudd)p 877 3718 V 33 w(bddIthV)-10 -b(ar)r Fo(:)40 b(Returns)29 b(the)f(projection)j(function)f(with)e -(inde)o(x)h Fk(i)p Fo(.)41 b(If)28 b(the)g(func-)676 -3831 y(tion)c(does)g(not)g(e)o(xist,)g(it)f(is)g(created.)p -Black 585 4018 a Fm(\017)p Black 46 w Fn(Cudd)p 877 4018 -V 33 w(bddNe)o(wV)-10 b(ar)r Fo(:)49 b(Returns)35 b(a)d(ne)n(w)h -(projection)j(function,)i(whose)c(inde)o(x)g(is)f(the)676 -4131 y(lar)n(gest)25 b(inde)o(x)f(in)g(use)g(at)f(the)h(time)f(of)h -(the)g(call,)f(plus)i(1.)p Black 585 4319 a Fm(\017)p -Black 46 w Fn(Cudd)p 877 4319 V 33 w(bddNe)o(wV)-10 b(arAtLe)o(vel)p -Fo(:)50 b(Similar)34 b(to)f Fn(Cudd)p 2283 4319 V 34 -w(bddNe)o(wV)-10 b(ar)r Fo(.)59 b(In)34 b(addition)i(it)d(al-)676 -4432 y(lo)n(ws)27 b(to)h(specify)i(the)e(position)i(in)e(the)g(v)n -(ariable)h(order)g(at)f(which)g(the)g(ne)n(w)g(v)n(ariable)676 -4545 y(should)i(be)f(inserted.)47 b(In)29 b(contrast,)j -Fn(Cudd)p 2060 4545 V 33 w(bddNe)o(wV)-10 b(ar)32 b Fo(adds)d(the)h(ne) -n(w)e(v)n(ariable)i(at)676 4658 y(the)23 b(end)h(of)g(the)g(order)-5 -b(.)448 4845 y(The)33 b(analogous)j(functions)g(for)d(ADDs)f(are)i -Fn(Cudd)p 2142 4845 V 33 w(addIthV)-10 b(ar)r Fo(,)38 -b Fn(Cudd)p 2795 4845 V 33 w(addNe)o(wV)-10 b(ar)r Fo(,)36 -b(and)448 4958 y Fn(Cudd)p 649 4958 V 34 w(addNe)o(wV)-10 -b(arAtLe)o(vel)p Fo(.)p Black 1897 5225 a(11)p Black -eop end -%%Page: 12 12 -TeXDict begin 12 11 bop Black Black 448 573 a Fp(3.6.2)92 -b(New)22 b(ZDD)g(V)-8 b(ariables)448 747 y Fo(Unlik)o(e)33 -b(the)f(projection)i(functions)g(of)e(BDDs)e(and)i(ADDs,)g(the)g -(projection)i(functions)g(of)448 860 y(ZDDs)20 b(ha)n(v)o(e)j(diagrams) -g(with)e Fk(n)13 b Fl(+)g(1)22 b Fo(nodes,)h(where)f -Fk(n)e Fo(is)i(the)f(number)i(of)f(v)n(ariables.)30 b(There-)448 -973 y(fore)g(the)f(ZDDs)e(of)h(the)h(projection)j(functions)f(change)g -(when)d(ne)n(w)h(v)n(ariables)h(are)f(added.)448 1086 -y(This)21 b(will)g(be)h(discussed)i(in)d(Section)h(3.9.)28 -b(Here)21 b(we)g(assume)h(that)g(the)g(number)g(of)f(v)n(ariables)448 -1199 y(is)j(\002x)o(ed.)k(The)23 b(ZDD)f(of)h(the)h Fk(i)p -Fo(-th)g(projection)i(function)g(is)d(returned)j(by)e -Fn(Cudd)p 2965 1199 28 4 v 33 w(zddIthV)-10 b(ar)r Fo(.)448 -1448 y Fi(3.7)99 b(Basic)25 b(BDD)h(Manipulation)448 -1622 y Fo(Common)34 b(manipulations)j(of)d(BDDs)e(can)i(be)g -(accomplished)j(by)d(calling)h Fn(Cudd)p 3153 1622 V -34 w(bddIte)p Fo(.)448 1735 y(This)19 b(function)i(tak)o(es)e(three)h -(BDDs,)d Fk(f)10 b Fo(,)18 b Fk(g)s Fo(,)h(and)g Fk(h)p -Fo(,)g(as)g(ar)n(guments)i(and)e(computes)h Fk(f)12 b -Fm(\001)r Fk(g)5 b Fl(+)r Fk(f)3311 1702 y Fd(0)3335 -1735 y Fm(\001)r Fk(h)p Fo(.)448 1848 y(Lik)o(e)29 b(all)g(the)g -(functions)j(that)d(create)h(ne)n(w)f(BDDs)e(or)i(ADDs,)f -Fn(Cudd)p 2698 1848 V 34 w(bddIte)i Fo(returns)h(a)d(re-)448 -1961 y(sult)j(that)g(must)f(be)g(e)o(xplicitly)i(referenced)h(by)d(the) -h(caller)-5 b(.)49 b Fn(Cudd)p 2609 1961 V 34 w(bddIte)32 -b Fo(can)e(be)g(used)h(to)448 2074 y(implement)i(all)e(tw)o(o-ar)n -(gument)k(boolean)e(functions.)55 b(Ho)n(we)n(v)o(er)l(,)33 -b(the)f(package)i(also)e(pro-)448 2187 y(vides)24 b Fn(Cudd)p -863 2187 V 33 w(bddAnd)i Fo(as)c(well)g(as)g(the)h(other)g(tw)o -(o-operand)i(boolean)f(functions,)h(which)d(are)448 2300 -y(slightly)32 b(more)f(ef)n(\002cient)f(when)h(a)e(tw)o(o-operand)k -(function)f(is)e(called)i(for)-5 b(.)48 b(The)30 b(follo)n(wing)448 -2413 y(fragment)24 b(of)f(code)h(illustrates)h(ho)n(w)d(to)h(b)n(uild)h -(the)f(BDD)e(for)h(the)h(function)i Fk(f)35 b Fl(=)25 -b Fk(x)3101 2380 y Fd(0)3101 2436 y Fc(0)3140 2413 y -Fk(x)3192 2380 y Fd(0)3192 2436 y Fc(1)3232 2413 y Fk(x)3284 -2380 y Fd(0)3284 2436 y Fc(2)3323 2413 y Fk(x)3375 2380 -y Fd(0)3375 2436 y Fc(3)3414 2413 y Fo(.)p Black Black -448 2600 a Fh(DdManager)51 b(*manager;)448 2713 y(DdNode)h(*f,)h(*var,) -g(*tmp;)448 2826 y(int)h(i;)448 3052 y(...)448 3278 y(f)g(=)h -(Cudd_ReadOne\(m)o(an)o(ag)o(er)o(\);)448 3391 y(Cudd_Ref\(f\);)448 -3504 y(for)f(\(i)f(=)h(3;)g(i)g(>=)g(0;)f(i--\))g({)667 -3616 y(var)g(=)h(Cudd_bddIthVar)o(\(m)o(ana)o(ge)o(r,)o(i\))o(;)667 -3729 y(tmp)f(=)h(Cudd_bddAnd\(ma)o(na)o(ger)o(,C)o(ud)o(d_)o(No)o(t\(v) -o(ar)o(\),)o(f\))o(;)667 3842 y(Cudd_Ref\(tmp\);)667 -3955 y(Cudd_Recursive)o(De)o(re)o(f\()o(ma)o(nag)o(er)o(,f)o(\);)667 -4068 y(f)g(=)g(tmp;)448 4181 y(})448 4369 y Fo(This)24 -b(e)o(xample)g(illustrates)i(the)e(follo)n(wing)h(points:)p -Black 585 4556 a Fm(\017)p Black 46 w Fo(Intermediate)40 -b(results)g(must)d(be)h(\223referenced\224)k(and)c(\223dereferenced.)-6 -b(\224)76 b(Ho)n(we)n(v)o(er)l(,)676 4669 y Fh(var)25 -b Fo(is)j(a)f(projection)k(function,)g(and)d(its)g(reference)i(count)f -(is)f(al)o(w)o(ays)g(greater)i(than)676 4782 y(0.)e(Therefore,)d(there) -f(is)g(no)f(call)h(to)g Fn(Cudd)p 2026 4782 V 33 w(Ref)13 -b Fo(.)p Black 1897 5225 a(12)p Black eop end -%%Page: 13 13 -TeXDict begin 13 12 bop Black Black Black 585 573 a Fm(\017)p -Black 46 w Fo(The)24 b(ne)n(w)g Fh(f)f Fo(must)i(be)f(assigned)j(to)e -(a)f(temporary)j(v)n(ariable)f(\()p Fh(tmp)d Fo(in)h(this)h(e)o -(xample\).)676 686 y(If)c(the)g(result)i(of)e Fn(Cudd)p -1408 686 28 4 v 34 w(bddAnd)k Fo(were)c(assigned)i(directly)h(to)d -Fh(f)p Fo(,)f(the)i(old)f Fh(f)f Fo(w)o(ould)i(be)676 -799 y(lost,)h(and)h(there)h(w)o(ould)f(be)f(no)h(w)o(ay)f(to)h(free)g -(its)f(nodes.)p Black 585 983 a Fm(\017)p Black 46 w -Fo(The)g(statement)i Fh(f)54 b(=)g(tmp)21 b Fo(has)j(the)g(same)g(ef)n -(fect)g(as:)p Black Black 894 1197 a Fh(f)54 b(=)g(tmp;)894 -1310 y(Cudd_Ref\(f\);)894 1423 y(Cudd_Recursive)o(De)o(ref)o(\(m)o(an)o -(ag)o(er)o(,tm)o(p\))o(;)676 1637 y Fo(b)n(ut)27 b(is)f(more)h(ef)n -(\002cient.)39 b(The)26 b(reference)j(is)d(\223passed\224)j(from)e -Fh(tmp)d Fo(to)j Fh(f)p Fo(,)f(and)h Fh(tmp)d Fo(is)676 -1750 y(no)n(w)f(ready)h(to)g(be)f(reutilized.)p Black -585 1934 a Fm(\017)p Black 46 w Fo(It)31 b(is)g(normally)h(more)g(ef)n -(\002cient)g(to)f(b)n(uild)h(BDDs)e(\223bottom-up.)-6 -b(\224)54 b(This)31 b(is)g(why)g(the)676 2047 y(loop)22 -b(goes)g(from)f(3)g(to)g(0.)28 b(Notice,)22 b(ho)n(we)n(v)o(er)l(,)g -(that)g(after)g(v)n(ariable)h(reordering,)h(higher)676 -2160 y(inde)o(x)30 b(does)h(not)f(necessarily)i(mean)e(\223closer)h(to) -f(the)g(bottom.)-6 b(\224)48 b(Of)29 b(course,)j(in)e(this)676 -2273 y(simple)24 b(e)o(xample,)g(ef)n(\002cienc)o(y)g(is)g(not)g(a)f -(concern.)p Black 585 2457 a Fm(\017)p Black 46 w Fo(Had)31 -b(we)g(w)o(anted)h(to)g(conjoin)i(the)e(v)n(ariables)h(in)f(a)f -(bottom-up)j(f)o(ashion)g(e)n(v)o(en)e(after)676 2569 -y(reordering,)26 b(we)c(should)j(ha)n(v)o(e)f(used)g -Fn(Cudd)p 2074 2569 V 34 w(ReadIn)l(vP)-7 b(erm)p Fo(.)30 -b(One)23 b(has)g(to)h(be)f(careful,)676 2682 y(though,)28 -b(to)e(\002x)f(the)i(order)g(of)f(conjunction)j(before)f(entering)g -(the)e(loop.)38 b(Otherwise,)676 2795 y(if)33 b(reordering)j(tak)o(es)e -(place,)i(it)d(is)h(possible)h(to)e(use)h(one)f(v)n(ariable)i(twice)f -(and)g(skip)676 2908 y(another)25 b(v)n(ariable.)448 -3156 y Fi(3.8)99 b(Basic)25 b(ADD)g(Manipulation)448 -3330 y Fo(The)f(most)f(common)h(w)o(ay)g(to)f(manipulate)j(ADDs)c(is)i -(via)g Fn(Cudd)p 2521 3330 V 34 w(addApply)p Fo(.)31 -b(This)23 b(function)448 3443 y(can)35 b(apply)g(a)e(wide)h(v)n(ariety) -h(of)f(operators)i(to)e(a)f(pair)h(of)g(ADDs.)58 b(Among)34 -b(the)g(a)n(v)n(ailable)448 3556 y(operators)27 b(are)d(addition,)i -(multiplication,)h(di)n(vision,)f(minimum,)d(maximum,)h(and)g(boolean) -448 3669 y(operators)i(that)e(w)o(ork)g(on)g(ADDs)e(whose)i(lea)n(v)o -(es)g(are)g(restricted)i(to)e(0)f(and)h(1)f(\(0-1)h(ADDs\).)589 -3782 y(The)g(follo)n(wing)h(fragment)g(of)f(code)h(illustrates)h(ho)n -(w)d(to)h(b)n(uild)h(the)f(ADD)e(for)i(the)g(func-)448 -3894 y(tion)g Fk(f)35 b Fl(=)25 b(5)p Fk(x)885 3908 y -Fc(0)925 3894 y Fk(x)977 3908 y Fc(1)1016 3894 y Fk(x)1068 -3908 y Fc(2)1108 3894 y Fk(x)1160 3908 y Fc(3)1199 3894 -y Fo(.)p Black Black 448 4073 a Fh(DdManager)51 b(*manager;)448 -4186 y(DdNode)h(*f,)h(*var,)g(*tmp;)448 4299 y(int)h(i;)448 -4525 y(...)448 4751 y(f)g(=)h(Cudd_addConst\()o(ma)o(na)o(ge)o(r,)o -(5\);)448 4863 y(Cudd_Ref\(f\);)448 4976 y(for)f(\(i)f(=)h(3;)g(i)g(>=) -g(0;)f(i--\))g({)p Black 1897 5225 a Fo(13)p Black eop -end -%%Page: 14 14 -TeXDict begin 14 13 bop Black Black 667 573 a Fh(var)53 -b(=)h(Cudd_addIthVar)o(\(m)o(ana)o(ge)o(r,)o(i\))o(;)667 -686 y(Cudd_Ref\(var\);)667 799 y(tmp)f(=)h(Cudd_addApply\()o(ma)o(nag)o -(er)o(,C)o(ud)o(d_)o(add)o(Ti)o(me)o(s,)o(va)o(r,f)o(\);)667 -912 y(Cudd_Ref\(tmp\);)667 1024 y(Cudd_Recursive)o(De)o(re)o(f\()o(ma)o -(nag)o(er)o(,f)o(\);)667 1137 y(Cudd_Recursive)o(De)o(re)o(f\()o(ma)o -(nag)o(er)o(,v)o(ar)o(\);)667 1250 y(f)g(=)g(tmp;)448 -1363 y(})448 1538 y Fo(This)25 b(e)o(xample,)i(contrasted)h(to)d(the)g -(e)o(xample)h(of)g(BDD)d(manipulation,)28 b(illustrates)g(the)e(fol-) -448 1651 y(lo)n(wing)e(points:)p Black 585 1826 a Fm(\017)p -Black 46 w Fo(The)d(ADD)f(projection)25 b(function)f(are)e(not)g -(maintained)i(by)e(the)g(manager)-5 b(.)30 b(It)21 b(is)h(there-)676 -1939 y(fore)i(necessary)i(to)d(reference)j(and)e(dereference)j(them.)p -Black 585 2122 a Fm(\017)p Black 46 w Fo(The)17 b(product)j(of)e(tw)o -(o)g(ADDs)e(is)i(computed)i(by)e(calling)i Fn(Cudd)p -2652 2122 28 4 v 34 w(addApply)g Fo(with)d Fn(Cudd)p -3426 2122 V 34 w(addT)-5 b(imes)676 2235 y Fo(as)19 b(parameter)-5 -b(.)29 b(There)20 b(is)f(no)h(\223apply\224)i(function)f(for)f(BDDs,)f -(because)i Fn(Cudd)p 3123 2235 V 34 w(bddAnd)676 2348 -y Fo(and)g Fn(Cudd)p 1028 2348 V 34 w(bddXor)i Fo(plus)f -(complementation)i(are)d(suf)n(\002cient)h(to)f(implement)h(all)e(tw)o -(o-)676 2461 y(ar)n(gument)25 b(boolean)h(functions.)448 -2707 y Fi(3.9)99 b(Basic)25 b(ZDD)h(Manipulation)448 -2882 y Fo(ZDDs)21 b(are)i(often)h(generated)h(by)e(con)l(v)o(erting)j -(e)o(xisting)e(BDDs.)j(\(See)c(Section)g(3.11.\))29 b(Ho)n(w-)448 -2995 y(e)n(v)o(er)l(,)20 b(it)e(is)g(also)h(possible)h(to)e(b)n(uild)i -(ZDDs)d(by)h(applying)j(boolean)f(operators)h(to)d(other)h(ZDDs,)448 -3108 y(starting)29 b(from)e(constants)i(and)e(projection)j(functions.) -41 b(The)26 b(follo)n(wing)j(fragment)f(of)e(code)448 -3220 y(illustrates)34 b(ho)n(w)d(to)h(b)n(uild)g(the)g(ZDD)d(for)j(the) -g(function)h Fk(f)49 b Fl(=)40 b Fk(x)2562 3187 y Fd(0)2562 -3244 y Fc(0)2627 3220 y Fl(+)26 b Fk(x)2776 3187 y Fd(0)2776 -3244 y Fc(1)2841 3220 y Fl(+)g Fk(x)2990 3187 y Fd(0)2990 -3244 y Fc(2)3056 3220 y Fl(+)f Fk(x)3204 3187 y Fd(0)3204 -3244 y Fc(3)3244 3220 y Fo(.)51 b(W)-7 b(e)448 3333 y(assume)25 -b(that)g(the)f(four)h(v)n(ariables)h(already)f(e)o(xist)g(in)f(the)g -(manager)h(when)g(the)f(ZDD)e(for)i Fk(f)32 b Fo(is)448 -3446 y(b)n(uilt.)e(Note)24 b(the)f(use)h(of)g(De)e(Mor)n(gan')-5 -b(s)26 b(la)o(w)-6 b(.)p Black Black 448 3621 a Fh(DdManager)51 -b(*manager;)448 3734 y(DdNode)h(*f,)h(*var,)g(*tmp;)448 -3847 y(int)h(i;)448 4073 y(manager)e(=)i(Cudd_Init\(0,4,)o(CU)o(DD_)o -(UN)o(IQ)o(UE)o(_S)o(LOT)o(S,)667 4186 y(CUDD_CACHE_SLO)o(TS)o(,0)o -(\);)448 4299 y(...)448 4525 y(tmp)g(=)g(Cudd_ReadZddOn)o(e\()o(ma)o -(na)o(ger)o(,0)o(\);)448 4638 y(Cudd_Ref\(tmp\);)448 -4751 y(for)g(\(i)f(=)h(3;)g(i)g(>=)g(0;)f(i--\))g({)667 -4863 y(var)g(=)h(Cudd_zddIthVar)o(\(m)o(ana)o(ge)o(r,)o(i\))o(;)667 -4976 y(Cudd_Ref\(var\);)p Black 1897 5225 a Fo(14)p Black -eop end -%%Page: 15 15 -TeXDict begin 15 14 bop Black Black 667 573 a Fh(f)54 -b(=)g(Cudd_zddInters)o(ec)o(t\()o(man)o(ag)o(er)o(,v)o(ar)o(,tm)o(p\))o -(;)667 686 y(Cudd_Ref\(f\);)667 799 y(Cudd_Recursive)o(De)o(re)o(fZ)o -(dd)o(\(ma)o(na)o(ge)o(r,)o(tm)o(p\);)667 912 y(Cudd_Recursive)o(De)o -(re)o(fZ)o(dd)o(\(ma)o(na)o(ge)o(r,)o(va)o(r\);)667 1024 -y(tmp)f(=)h(f;)448 1137 y(})448 1250 y(f)g(=)h(Cudd_zddDiff\(m)o(an)o -(ag)o(er)o(,C)o(udd)o(_R)o(ea)o(dZ)o(dd)o(One)o(\(m)o(an)o(ag)o(er)o -(,0\))o(,t)o(mp)o(\);)448 1363 y(Cudd_Ref\(f\);)448 1476 -y(Cudd_RecursiveD)o(ere)o(fZ)o(dd)o(\(m)o(an)o(age)o(r,)o(tm)o(p\))o(;) -448 1664 y Fo(This)24 b(e)o(xample)g(illustrates)i(the)e(follo)n(wing)h -(points:)p Black 585 1851 a Fm(\017)p Black 46 w Fo(The)e(projection)k -(functions)f(are)e(referenced,)j(because)f(the)o(y)e(are)g(not)g -(maintained)i(by)676 1964 y(the)d(manager)-5 b(.)p Black -585 2152 a Fm(\017)p Black 46 w Fo(Complementation)26 -b(is)d(obtained)j(by)e(subtracting)i(from)e(the)g(constant)h(1)f -(function.)p Black 585 2340 a Fm(\017)p Black 46 w Fo(The)f(result)h -(of)g Fn(Cudd)p 1364 2340 28 4 v 34 w(ReadZddOne)g Fo(does)g(not)g -(require)h(referencing.)448 2527 y(CUDD)31 b(pro)o(vides)j(functions)i -(for)d(the)g(manipulation)i(of)e(co)o(v)o(ers)g(represented)j(by)d -(ZDDs.)448 2640 y(F)o(or)40 b(instance,)47 b Fn(Cudd)p -1179 2640 V 33 w(zddIsop)c Fo(b)n(uilds)f(a)e(ZDD)f(representing)44 -b(an)c(irredundant)k(sum)c(of)448 2753 y(products)31 -b(for)e(the)g(incompletely)i(speci\002ed)f(function)h(de\002ned)e(by)f -(the)h(tw)o(o)f(BDDs)f Fk(L)h Fo(and)448 2866 y Fk(U)10 -b Fo(.)45 b Fn(Cudd)p 789 2866 V 33 w(zddW)-8 b(eakDiv)31 -b Fo(performs)f(the)f(weak)g(di)n(vision)i(of)e(tw)o(o)g(co)o(v)o(ers)h -(gi)n(v)o(en)f(as)g(ZDDs.)448 2979 y(These)c(functions)h(e)o(xpect)f -(the)f(tw)o(o)g(ZDD)e(v)n(ariables)k(corresponding)i(to)c(the)g(tw)o(o) -g(literals)h(of)448 3092 y(the)30 b(function)j(v)n(ariable)e(to)f(be)g -(adjacent.)50 b(One)29 b(has)h(to)g(create)h(v)n(ariable)h(groups)f -(\(see)g(Sec-)448 3205 y(tion)23 b(3.14\))g(for)g(reordering)i(of)d -(the)h(ZDD)e(v)n(ariables)j(to)e(w)o(ork.)29 b(BDD)20 -b(automatic)k(reordering)448 3318 y(is)31 b(safe)h(e)n(v)o(en)f -(without)h(groups:)45 b(If)31 b(realignment)i(of)e(ZDD)e(and)i(ADD/BDD) -d(v)n(ariables)33 b(is)448 3430 y(requested)26 b(\(see)e(Section)h -(3.15\))f(groups)h(will)e(be)h(k)o(ept)g(adjacent.)448 -3680 y Fi(3.10)99 b(Con)l(v)o(erting)26 b(ADDs)e(to)h(BDDs)g(and)h(V)l -(ice)f(V)-10 b(ersa)448 3854 y Fo(Se)n(v)o(eral)25 b(procedures)i(are)d -(pro)o(vided)i(to)e(con)l(v)o(ert)i(ADDs)d(to)h(BDDs,)f(according)j(to) -e(dif)n(ferent)448 3967 y(criteria.)29 b(\()p Fn(Cudd)p -986 3967 V 34 w(addBddP)-7 b(attern)p Fo(,)21 b Fn(Cudd)p -1805 3967 V 34 w(addBddInterval)p Fo(,)i(and)18 b Fn(Cudd)p -2795 3967 V 34 w(addBddThr)m(eshold)r Fo(.\))448 4080 -y(The)34 b(con)l(v)o(ersion)i(from)e(BDDs)e(to)h(ADDs)g(\()p -Fn(Cudd)p 2119 4080 V 34 w(BddT)-8 b(oAdd)r Fo(\))34 -b(is)f(based)i(on)f(the)g(simple)448 4193 y(principle)26 -b(of)e(mapping)h(the)f(logical)i(0)d(and)h(1)g(on)f(the)h(arithmetic)i -(0)d(and)i(1.)k(It)23 b(is)h(also)g(possi-)448 4306 y(ble)g(to)g(con)l -(v)o(ert)h(an)f(ADD)e(with)h(inte)o(ger)i(v)n(alues)g(\(more)f -(precisely)-6 b(,)26 b(\003oating)e(point)h(numbers)448 -4418 y(with)f(0)f(fractional)j(part\))e(to)g(an)f(array)i(of)e(BDDs)f -(by)i(repeatedly)i(calling)f Fn(Cudd)p 3012 4418 V 34 -w(addIthBit)r Fo(.)448 4668 y Fi(3.11)99 b(Con)l(v)o(erting)26 -b(BDDs)f(to)g(ZDDs)g(and)g(V)l(ice)g(V)-10 b(ersa)448 -4842 y Fo(Man)o(y)22 b(applications)k(\002rst)21 b(b)n(uild)j(a)d(set)h -(of)g(BDDs)f(and)h(then)h(deri)n(v)o(e)g(ZDDs)d(from)i(the)g(BDDs.)448 -4955 y(These)i(applications)j(should)e(create)f(the)g(manager)g(with)f -(0)g(ZDD)e(v)n(ariables)26 b(and)e(create)g(the)p Black -1897 5225 a(15)p Black eop end -%%Page: 16 16 -TeXDict begin 16 15 bop Black Black 448 573 a Fo(BDDs.)40 -b(Then)27 b(the)o(y)h(should)h(call)f Fn(Cudd)p 1762 -573 28 4 v 34 w(zddV)-10 b(ar)o(sF)-5 b(r)l(omBddV)-10 -b(ar)o(s)30 b Fo(to)d(create)i(the)f(necessary)448 686 -y(ZDD)j(v)n(ariables\227whose)36 b(number)e(is)e(lik)o(ely)i(to)f(be)g -(kno)n(wn)g(once)g(the)g(BDDs)e(are)i(a)n(v)n(ail-)448 -799 y(able.)g(This)24 b(approach)j(eliminates)f(the)f(dif)n -(\002culties)i(that)e(arise)g(when)g(the)f(number)i(of)e(ZDD)448 -912 y(v)n(ariables)i(changes)f(while)f(ZDDs)e(are)i(being)h(b)n(uilt.) -589 1024 y(The)h(simplest)h(con)l(v)o(ersion)h(from)e(BDDs)e(to)h(ZDDs) -f(is)i(a)f(simple)h(change)h(of)f(represen-)448 1137 -y(tation,)39 b(which)c(preserv)o(es)i(the)f(functions.)65 -b(Simply)35 b(put,)j(gi)n(v)o(en)d(a)g(BDD)e(for)i Fk(f)10 -b Fo(,)36 b(a)e(ZDD)448 1250 y(for)g Fk(f)42 b Fo(is)34 -b(requested.)61 b(In)34 b(this)g(case)h(the)e(correspondence)39 -b(between)c(the)e(BDD)f(v)n(ariables)448 1363 y(and)g(ZDD)e(v)n -(ariables)j(is)e(one-to-one.)55 b(Hence,)34 b Fn(Cudd)p -2232 1363 V 34 w(zddV)-10 b(ar)o(sF)-5 b(r)l(omBddV)-10 -b(ar)o(s)33 b Fo(should)g(be)448 1476 y(called)c(with)e(the)g -Fn(multiplicity)j Fo(parameter)f(equal)f(to)g(1.)39 b(The)27 -b(con)l(v)o(ersion)j(proper)f(can)f(then)448 1589 y(be)37 -b(performed)h(by)f(calling)h Fn(Cudd)p 1595 1589 V 33 -w(zddP)-7 b(ortF)i(r)l(omBdd)r Fo(.)69 b(The)36 b(in)l(v)o(erse)j -(transformation)g(is)448 1702 y(performed)26 b(by)d Fn(Cudd)p -1164 1702 V 34 w(zddP)-7 b(ortT)f(oBdd)r Fo(.)589 1815 -y(ZDDs)28 b(are)i(quite)h(often)f(used)h(for)e(the)h(representation)k -(of)c Fn(co)o(ver)o(s)p Fo(.)48 b(This)29 b(is)h(normally)448 -1928 y(done)36 b(by)g(associating)i(tw)o(o)d(ZDD)e(v)n(ariables)38 -b(to)d(each)h(v)n(ariable)h(of)e(the)g(function.)66 b(\(And)448 -2041 y(hence,)28 b(typically)-6 b(,)28 b(to)e(each)g(BDD)e(v)n -(ariable.\))38 b(One)25 b(ZDD)f(v)n(ariable)j(is)f(associated)i(with)e -(the)448 2154 y(positi)n(v)o(e)35 b(literal)f(of)f(the)g(BDD)e(v)n -(ariable,)37 b(while)d(the)f(other)h(ZDD)d(v)n(ariable)k(is)d -(associated)448 2267 y(with)i(the)f(ne)o(gati)n(v)o(e)h(literal.)60 -b(A)32 b(call)i(to)f Fn(Cudd)p 1980 2267 V 34 w(zddV)-10 -b(ar)o(sF)-5 b(r)l(omBddV)-10 b(ar)o(s)36 b Fo(with)d -Fn(multiplicity)448 2379 y Fo(equal)25 b(to)e(2)h(will)f(associate)j -(to)d(BDD)f(v)n(ariable)j Fk(i)e Fo(the)h(tw)o(o)f(ZDD)f(v)n(ariables)j -Fl(2)p Fk(i)f Fo(and)g Fl(2)p Fk(i)d Fl(+)f(1)p Fo(.)589 -2492 y(If)j(a)f(BDD)f(v)n(ariable)j(group)g(tree)f(e)o(xists)h(when)f -Fn(Cudd)p 2300 2492 V 34 w(zddV)-10 b(ar)o(sF)-5 b(r)l(omBddV)-10 -b(ar)o(s)25 b Fo(is)d(called)448 2605 y(\(see)29 b(Section)f(3.13\))g -(the)g(function)i(generates)g(a)e(ZDD)d(v)n(ariable)30 -b(group)f(tree)f(consistent)i(to)448 2718 y(it.)57 b(In)33 -b(an)o(y)h(case,)h(all)f(the)f(ZDD)e(v)n(ariables)k(deri)n(v)o(ed)g -(from)e(the)g(same)g(BDD)e(v)n(ariable)k(are)448 2831 -y(clustered)26 b(into)e(a)f(group.)589 2944 y(If)i(the)f(ZDD)e(for)j -Fk(f)33 b Fo(is)24 b(created)i(and)f(later)g(a)f(ne)n(w)f(ZDD)g(v)n -(ariable)j(is)e(added)h(to)g(the)f(man-)448 3057 y(ager)l(,)f(the)e -(function)i(represented)i(by)c(the)h(e)o(xisting)g(ZDD)e(changes.)29 -b(Suppose,)23 b(for)e(instance,)448 3170 y(that)26 b(tw)o(o)f(v)n -(ariables)i(are)e(initially)i(created,)g(and)e(that)h(the)f(ZDD)e(for)i -Fk(f)38 b Fl(=)27 b Fk(x)2896 3184 y Fc(0)2957 3170 y -Fl(+)21 b Fk(x)3101 3184 y Fc(1)3165 3170 y Fo(is)j(b)n(uilt.)448 -3283 y(If)33 b(a)g(third)h(v)n(ariable)h(is)e(added,)k(say)c -Fk(x)1714 3297 y Fc(2)1753 3283 y Fo(,)i(then)f(the)f(ZDD)e(represents) -36 b Fk(g)47 b Fl(=)c(\()p Fk(x)3054 3297 y Fc(0)3121 -3283 y Fl(+)27 b Fk(x)3271 3297 y Fc(1)3310 3283 y Fl(\))p -Fk(x)3397 3250 y Fd(0)3397 3306 y Fc(2)448 3396 y Fo(instead.)36 -b(This)25 b(change)i(in)e(function)j(ob)o(viously)g(applies)f(re)o -(gardless)g(of)e(what)g(use)h(is)f(made)448 3509 y(of)j(the)g(ZDD.)39 -b(Ho)n(we)n(v)o(er)l(,)29 b(if)e(the)h(ZDD)e(is)h(used)i(to)e -(represent)k(a)c(co)o(v)o(er,)i(the)f(co)o(v)o(er)g(itself)g(is)448 -3621 y(not)i(changed)h(by)e(the)g(addition)j(of)c(ne)n(w)h(v)n -(ariable.)47 b(\(What)29 b(changes)i(is)e(the)g(characteristic)448 -3734 y(function)d(of)d(the)h(co)o(v)o(er)-5 b(.\))448 -3984 y Fi(3.12)99 b(V)-9 b(ariable)25 b(Reordering)h(f)n(or)e(BDDs)h -(and)h(ADDs)448 4158 y Fo(The)20 b(CUDD)d(package)22 -b(pro)o(vides)g(a)d(rich)h(set)g(of)g(dynamic)h(reordering)i -(algorithms.)29 b(Some)19 b(of)448 4271 y(them)24 b(are)g(slight)g(v)n -(ariations)i(of)e(e)o(xisting)h(techniques)i([16)q(,)22 -b(6)q(,)g(2)q(,)g(10)q(,)h(15)q(,)f(11)q(];)h(some)h(others)448 -4384 y(ha)n(v)o(e)h(been)f(de)n(v)o(eloped)i(speci\002cally)f(for)f -(this)g(package)i([14)q(,)c(13)q(].)589 4497 y(Reordering)33 -b(af)n(fects)e(a)f(unique)i(table.)50 b(This)30 b(means)h(that)g(BDDs)e -(and)i(ADDs,)f(which)448 4609 y(share)36 b(the)g(same)f(unique)i(table) -f(are)f(simultaneously)k(reordered.)66 b(ZDDs,)36 b(on)f(the)g(other) -448 4722 y(hand,)22 b(are)f(reordered)i(separately)-6 -b(.)31 b(In)20 b(the)h(follo)n(wing)h(we)e(discuss)i(the)f(reordering)i -(of)e(BDDs)448 4835 y(and)j(ADDs.)j(Reordering)f(for)e(ZDDs)e(is)h(the) -h(subject)h(of)f(Section)g(3.14.)p Black 1897 5225 a(16)p -Black eop end -%%Page: 17 17 -TeXDict begin 17 16 bop Black Black 589 573 a Fo(Reordering)28 -b(of)d(the)g(v)n(ariables)i(can)f(be)f(in)l(v)n(ok)o(ed)j(directly)f -(by)e(the)g(application)j(by)e(call-)448 686 y(ing)g -Fn(Cudd)p 790 686 28 4 v 34 w(ReduceHeap)p Fo(.)35 b(Or)24 -b(it)h(can)h(be)f(automatically)k(triggered)e(by)e(the)h(package)h -(when)448 799 y(the)k(number)g(of)g(nodes)g(has)g(reached)h(a)e(gi)n(v) -o(en)h(threshold.)52 b(\(The)30 b(threshold)j(is)d(initialized)448 -912 y(and)h(automatically)j(adjusted)f(after)e(each)h(reordering)h(by)e -(the)g(package.\))52 b(T)-7 b(o)30 b(enable)i(au-)448 -1024 y(tomatic)c(dynamic)h(reordering)h(\(also)e(called)g -Fn(async)o(hr)l(onous)j Fo(dynamic)e(reordering)h(in)d(this)448 -1137 y(document\))37 b(the)f(application)i(must)d(call)h -Fn(Cudd)p 2033 1137 V 34 w(A)n(utodynEnable)p Fo(.)66 -b(Automatic)36 b(dynamic)448 1250 y(reordering)27 b(can)d(subsequently) -j(be)d(disabled)h(by)f(calling)h Fn(Cudd)p 2515 1250 -V 34 w(A)n(utodynDisable)p Fo(.)589 1363 y(All)18 b(reordering)j -(methods)e(are)f(a)n(v)n(ailable)j(in)d(both)h(the)f(case)h(of)f -(direct)h(call)g(to)f Fn(Cudd)p 3238 1363 V 33 w(ReduceHeap)448 -1476 y Fo(and)23 b(the)g(case)g(of)g(automatic)h(in)l(v)n(ocation.)32 -b(F)o(or)21 b(man)o(y)i(methods,)h(the)e(reordering)k(procedure)448 -1589 y(is)34 b(iterated)h(until)f(no)f(further)i(impro)o(v)o(ement)g -(is)e(obtained.)61 b(W)-7 b(e)32 b(call)i(these)g(methods)h(the)448 -1702 y Fn(con)l(ver)m(ging)40 b Fo(methods.)68 b(When)37 -b(constraints)i(are)e(imposed)g(on)g(the)f(relati)n(v)o(e)i(position)g -(of)448 1815 y(v)n(ariables)31 b(\(see)d(Section)h(3.13\))g(the)f -(reordering)j(methods)f(apply)f(inside)g(the)g(groups.)44 -b(The)448 1928 y(groups)33 b(themselv)o(es)g(are)e(reordered)i(by)e -(sifting.)53 b(Each)31 b(method)h(is)e(identi\002ed)j(by)e(a)g(con-)448 -2041 y(stant)24 b(of)f(the)h(enumerated)h(type)f Fn(Cudd)p -1700 2041 V 34 w(Reor)m(deringT)-7 b(ype)26 b Fo(de\002ned)e(in)f -Fn(cudd.h)h Fo(\(the)g(e)o(xternal)448 2154 y(header)h(\002le)e(of)h -(the)f(CUDD)f(package\):)p Black 448 2366 a Fp(CUDD)p -717 2366 V 32 w(REORDER)p 1206 2366 V 30 w(NONE:)p Black -44 w Fo(This)i(method)g(causes)h(no)f(reordering.)p Black -448 2554 a Fp(CUDD)p 717 2554 V 32 w(REORDER)p 1206 2554 -V 30 w(SAME:)p Black 44 w Fo(If)18 b(passed)i(to)e Fn(Cudd)p -2196 2554 V 33 w(A)n(utodynEnable)p Fo(,)k(this)d(method)g(lea)n(v)o -(es)676 2667 y(the)f(current)i(method)f(for)f(automatic)i(reordering)h -(unchanged.)30 b(If)17 b(passed)j(to)e Fn(Cudd)p 3333 -2667 V 34 w(ReduceHeap)p Fo(,)676 2780 y(this)24 b(method)g(causes)h -(the)f(current)h(method)g(for)e(automatic)j(reordering)g(to)d(be)h -(used.)p Black 448 2967 a Fp(CUDD)p 717 2967 V 32 w(REORDER)p -1206 2967 V 30 w(RANDOM:)p Black 44 w Fo(P)o(airs)17 -b(of)h(v)n(ariables)j(are)d(randomly)i(chosen,)g(and)f(sw)o(apped)676 -3080 y(in)29 b(the)h(order)-5 b(.)48 b(The)29 b(sw)o(ap)h(is)f -(performed)i(by)f(a)f(series)i(of)f(sw)o(aps)g(of)f(adjacent)j(v)n -(ari-)676 3193 y(ables.)c(The)18 b(best)h(order)g(among)g(those)h -(obtained)g(by)f(the)g(series)g(of)f(sw)o(aps)h(is)g(retained.)676 -3306 y(The)24 b(number)i(of)f(pairs)h(chosen)h(for)e(sw)o(apping)i -(equals)f(the)f(number)h(of)f(v)n(ariables)i(in)676 3419 -y(the)c(diagram.)p Black 448 3606 a Fp(CUDD)p 717 3606 -V 32 w(REORDER)p 1206 3606 V 30 w(RANDOM)p 1657 3606 -V 31 w(PIV)l(O)l(T:)p Black 45 w Fo(Same)17 b(as)h(CUDD)p -2615 3606 V 31 w(REORDER)p 3073 3606 V 30 w(RANDOM,)676 -3719 y(b)n(ut)30 b(the)g(tw)o(o)f(v)n(ariables)j(are)d(chosen)j(so)d -(that)h(the)g(\002rst)g(is)f(abo)o(v)o(e)h(the)g(v)n(ariable)h(with)676 -3832 y(the)d(lar)n(gest)h(number)g(of)e(nodes,)j(and)e(the)g(second)i -(is)d(belo)n(w)h(that)g(v)n(ariable.)43 b(In)28 b(case)676 -3945 y(there)h(are)g(se)n(v)o(eral)h(v)n(ariables)h(tied)e(for)g(the)g -(maximum)g(number)g(of)g(nodes,)i(the)e(one)676 4058 -y(closest)c(to)e(the)h(root)g(is)g(used.)p Black 448 -4246 a Fp(CUDD)p 717 4246 V 32 w(REORDER)p 1206 4246 -V 30 w(SIFT:)p Black 45 w Fo(This)g(method)h(is)g(an)f(implementation)k -(of)c(Rudell')-5 b(s)26 b(sifting)676 4359 y(algorithm)i([16)q(].)39 -b(A)26 b(simpli\002ed)i(description)i(of)d(sifting)h(is)f(as)g(follo)n -(ws:)37 b(Each)27 b(v)n(ari-)676 4472 y(able)32 b(is)g(considered)j(in) -d(turn.)55 b(A)30 b(v)n(ariable)k(is)e(mo)o(v)o(ed)g(up)g(and)g(do)n -(wn)g(in)g(the)g(order)676 4584 y(so)26 b(that)h(it)e(tak)o(es)j(all)e -(possible)i(positions.)40 b(The)25 b(best)i(position)i(is)d -(identi\002ed)h(and)g(the)676 4697 y(v)n(ariable)e(is)e(returned)j(to)d -(that)h(position.)676 4848 y(In)30 b(reality)-6 b(,)34 -b(things)e(are)f(a)g(bit)g(more)f(complicated.)53 b(F)o(or)30 -b(instance,)35 b(there)c(is)g(a)f(limit)676 4961 y(on)g(the)g(number)h -(of)f(v)n(ariables)i(that)f(will)f(be)g(sifted.)49 b(This)30 -b(limit)g(can)h(be)f(read)g(with)p Black 1897 5225 a(17)p -Black eop end -%%Page: 18 18 -TeXDict begin 18 17 bop Black Black 676 573 a Fn(Cudd)p -877 573 28 4 v 33 w(ReadSiftMaxV)-10 b(ar)29 b Fo(and)d(set)f(with)g -Fn(Cudd)p 2195 573 V 34 w(SetSiftMaxV)-10 b(ar)r Fo(.)35 -b(In)25 b(addition,)i(if)e(the)676 686 y(diagram)31 b(gro)n(ws)g(too)g -(much)g(while)g(mo)o(ving)h(a)e(v)n(ariable)j(up)d(or)h(do)n(wn,)h -(that)g(mo)o(v)o(e-)676 799 y(ment)37 b(is)f(terminated)j(before)g(the) -e(v)n(ariable)i(has)e(reached)i(one)e(end)g(of)g(the)h(order)-5 -b(.)676 912 y(The)27 b(maximum)g(ratio)i(by)f(which)g(the)g(diagram)h -(is)e(allo)n(wed)i(to)e(gro)n(w)h(while)f(a)h(v)n(ari-)676 -1024 y(able)35 b(is)f(being)h(sifted)h(can)f(be)f(read)h(with)g -Fn(Cudd)p 2292 1024 V 33 w(ReadMaxGr)l(owth)h Fo(and)f(set)f(with)676 -1137 y Fn(Cudd)p 877 1137 V 33 w(SetMaxGr)l(owth)p Fo(.)p -Black 448 1318 a Fp(CUDD)p 717 1318 V 32 w(REORDER)p -1206 1318 V 30 w(SIFT)p 1439 1318 V 32 w(CONVERGE:)p -Black 43 w Fo(This)18 b(is)f(the)i(con)l(v)o(er)n(ging)i(v)n(ariant)f -(of)e(CUDD-)p 676 1431 V 703 1431 a(REORDER)p 1135 1431 -V 30 w(SIFT)-7 b(.)p Black 448 1612 a Fp(CUDD)p 717 1612 -V 32 w(REORDER)p 1206 1612 V 30 w(SYMM)p 1525 1612 V -31 w(SIFT:)p Black 45 w Fo(This)34 b(method)h(is)f(an)g(implementation) -i(of)e(sym-)676 1725 y(metric)27 b(sifting)i([14)q(].)39 -b(It)26 b(is)h(similar)h(to)f(sifting,)i(with)e(one)h(addition:)38 -b(V)-10 b(ariables)29 b(that)676 1837 y(become)23 b(adjacent)i(during)f -(sifting)g(are)f(tested)h(for)f(symmetry.)29 b(If)22 -b(the)o(y)h(are)g(symmet-)676 1950 y(ric,)34 b(the)o(y)f(are)f(link)o -(ed)i(in)f(a)f(group.)56 b(Sifting)33 b(then)g(continues)i(with)e(a)e -(group)j(being)676 2063 y(mo)o(v)o(ed,)d(instead)h(of)f(a)e(single)j(v) -n(ariable.)51 b(After)30 b(symmetric)i(sifting)f(has)g(been)g(run,)676 -2176 y Fn(Cudd)p 877 2176 V 33 w(SymmPr)l(o\002le)h Fo(can)g(be)g -(called)g(to)g(report)h(on)e(the)h(symmetry)g(groups)h(found.)676 -2289 y(\(Both)23 b(positi)n(v)o(e)i(and)f(ne)o(gati)n(v)o(e)h -(symmetries)g(are)e(reported.\))p Black 448 2470 a Fp(CUDD)p -717 2470 V 32 w(REORDER)p 1206 2470 V 30 w(SYMM)p 1525 -2470 V 31 w(SIFT)p 1759 2470 V 32 w(CONV:)p Black 45 -w Fo(This)17 b(is)h(the)h(con)l(v)o(er)n(ging)i(v)n(ariant)f(of)e -(CUDD-)p 676 2583 V 703 2583 a(REORDER)p 1135 2583 V -30 w(SYMM)p 1444 2583 V 31 w(SIFT)-7 b(.)p Black 448 -2763 a Fp(CUDD)p 717 2763 V 32 w(REORDER)p 1206 2763 -V 30 w(GR)m(OUP)p 1563 2763 V 31 w(SIFT:)p Black 45 w -Fo(This)22 b(method)i(is)e(an)h(implementation)i(of)e(group)676 -2876 y(sifting)c([13)r(].)26 b(It)18 b(is)g(similar)h(to)f(symmetric)i -(sifting,)g(b)n(ut)f(aggre)o(gation)i(is)d(not)h(restricted)676 -2989 y(to)k(symmetric)i(v)n(ariables.)p Black 448 3170 -a Fp(CUDD)p 717 3170 V 32 w(REORDER)p 1206 3170 V 30 -w(GR)m(OUP)p 1563 3170 V 31 w(SIFT)p 1797 3170 V 32 w(CONV:)p -Black 44 w Fo(This)36 b(method)h(repeats)g(until)g(con)l(v)o(er)n(-)676 -3283 y(gence)h(the)f(combination)j(of)d(CUDD)p 1938 3283 -V 31 w(REORDER)p 2396 3283 V 30 w(GR)l(OUP)p 2732 3283 -V 32 w(SIFT)e(and)i(CUDD-)p 676 3396 V 703 3396 a(REORDER)p -1135 3396 V 30 w(WINDO)m(W4.)p Black 448 3576 a Fp(CUDD)p -717 3576 V 32 w(REORDER)p 1206 3576 V 30 w(WINDO)-5 b(W2:)p -Black 46 w Fo(This)30 b(method)h(implements)h(the)e(windo)n(w)h(permu-) -676 3689 y(tation)j(approach)i(of)d(Fujita)h([8)q(])f(and)g(Ishiura)j -([10)q(].)57 b(The)33 b(size)h(of)g(the)f(windo)n(w)g(is)676 -3802 y(2.)p Black 448 3983 a Fp(CUDD)p 717 3983 V 32 -w(REORDER)p 1206 3983 V 30 w(WINDO)-5 b(W3:)p Black 46 -w Fo(Similar)18 b(to)g(CUDD)p 2404 3983 V 31 w(REORDER)p -2862 3983 V 30 w(WINDO)m(W2,)f(b)n(ut)676 4096 y(with)23 -b(a)g(windo)n(w)g(of)h(size)g(3.)p Black 448 4276 a Fp(CUDD)p -717 4276 V 32 w(REORDER)p 1206 4276 V 30 w(WINDO)-5 b(W4:)p -Black 46 w Fo(Similar)18 b(to)g(CUDD)p 2404 4276 V 31 -w(REORDER)p 2862 4276 V 30 w(WINDO)m(W2,)f(b)n(ut)676 -4389 y(with)23 b(a)g(windo)n(w)g(of)h(size)g(4.)p Black -448 4570 a Fp(CUDD)p 717 4570 V 32 w(REORDER)p 1206 4570 -V 30 w(WINDO)-5 b(W2)p 1696 4570 V 33 w(CONV:)p Black -44 w Fo(This)18 b(is)g(the)g(con)l(v)o(er)n(ging)k(v)n(ariant)d(of)f -(CUDD-)p 676 4683 V 703 4683 a(REORDER)p 1135 4683 V -30 w(WINDO)m(W2.)p Black 448 4863 a Fp(CUDD)p 717 4863 -V 32 w(REORDER)p 1206 4863 V 30 w(WINDO)-5 b(W3)p 1696 -4863 V 33 w(CONV:)p Black 44 w Fo(This)18 b(is)g(the)g(con)l(v)o(er)n -(ging)k(v)n(ariant)d(of)f(CUDD-)p 676 4976 V 703 4976 -a(REORDER)p 1135 4976 V 30 w(WINDO)m(W3.)p Black 1897 -5225 a(18)p Black eop end -%%Page: 19 19 -TeXDict begin 19 18 bop Black Black Black 448 573 a Fp(CUDD)p -717 573 28 4 v 32 w(REORDER)p 1206 573 V 30 w(WINDO)-5 -b(W4)p 1696 573 V 33 w(CONV:)p Black 44 w Fo(This)18 -b(is)g(the)g(con)l(v)o(er)n(ging)k(v)n(ariant)d(of)f(CUDD-)p -676 686 V 703 686 a(REORDER)p 1135 686 V 30 w(WINDO)m(W4.)p -Black 448 867 a Fp(CUDD)p 717 867 V 32 w(REORDER)p 1206 -867 V 30 w(ANNEALING:)p Black 43 w Fo(This)24 b(method)h(is)f(an)h -(implementation)i(of)d(simu-)676 980 y(lated)e(annealing)h(for)f(v)n -(ariable)h(ordering,)g(v)n(aguely)g(resemblant)g(of)e(the)h(algorithm)g -(of)676 1093 y([2].)28 b(This)c(method)g(is)g(potentially)i(v)o(ery)e -(slo)n(w)-6 b(.)p Black 448 1275 a Fp(CUDD)p 717 1275 -V 32 w(REORDER)p 1206 1275 V 30 w(GENETIC:)p Black 44 -w Fo(This)26 b(method)i(is)e(an)h(implementation)j(of)c(a)h(genetic)676 -1388 y(algorithm)g(for)e(v)n(ariable)j(ordering,)f(inspired)h(by)d(the) -h(w)o(ork)g(of)f(Drechsler)i([6)q(].)33 b(This)676 1501 -y(method)24 b(is)f(potentially)k(v)o(ery)d(slo)n(w)-6 -b(.)p Black 448 1682 a Fp(CUDD)p 717 1682 V 32 w(REORDER)p -1206 1682 V 30 w(EXA)h(CT:)p Black 44 w Fo(This)22 b(method)i -(implements)h(a)d(dynamic)i(programming)676 1795 y(approach)d(to)f(e)o -(xact)g(reordering)i([9)q(,)c(7)q(,)g(10)q(],)h(with)h(impro)o(v)o -(ements)h(described)h(in)d([11)q(].)676 1908 y(It)33 -b(only)h(stores)g(one)g(BDD)d(at)j(the)f(time.)58 b(Therefore,)37 -b(it)c(is)g(relati)n(v)o(ely)i(ef)n(\002cient)f(in)676 -2021 y(terms)29 b(of)g(memory)-6 b(.)45 b(Compared)29 -b(to)g(other)h(reordering)i(strate)o(gies,)g(it)d(is)g(v)o(ery)g(slo)n -(w)-6 b(,)676 2134 y(and)24 b(is)f(not)h(recommended)i(for)d(more)h -(than)g(16)g(v)n(ariables.)448 2329 y(So)f(f)o(ar)h(we)e(ha)n(v)o(e)i -(described)i(methods)f(whereby)g(the)e(package)j(selects)f(an)e(order)i -(automati-)448 2442 y(cally)-6 b(.)28 b(A)17 b(gi)n(v)o(en)i(order)g -(of)f(the)g(v)n(ariables)i(can)f(also)g(be)f(imposed)h(by)f(calling)i -Fn(Cudd)p 3050 2442 V 34 w(Shuf)n(\003eHeap)p Fo(.)448 -2688 y Fi(3.13)99 b(Gr)n(ouping)26 b(V)-9 b(ariables)448 -2862 y Fo(CUDD)29 b(allo)n(ws)i(the)g(application)j(to)d(specify)h -(constraints)i(on)d(the)g(positions)j(of)c(group)i(of)448 -2975 y(v)n(ariables.)63 b(It)34 b(is)g(possible)j(to)d(request)i(that)f -(a)f(group)h(of)f(contiguous)k(v)n(ariables)e(be)e(k)o(ept)448 -3088 y(contiguous)39 b(by)d(the)g(reordering)i(procedures.)68 -b(It)35 b(is)g(also)h(possible)i(to)e(request)h(that)f(the)448 -3201 y(relati)n(v)o(e)31 b(order)f(of)g(some)f(groups)j(of)d(v)n -(ariables)j(be)d(left)h(unchanged.)50 b(The)29 b(constraints)j(on)448 -3314 y(the)24 b(order)h(are)e(speci\002ed)i(by)f(means)g(of)f(a)g -(tree,)h(which)g(is)f(created)j(in)d(one)h(of)g(tw)o(o)f(w)o(ays:)p -Black 585 3486 a Fm(\017)p Black 46 w Fo(By)f(calling)k -Fn(Cudd)p 1276 3486 V 33 w(Mak)o(eT)-5 b(r)m(eeNode)p -Fo(.)p Black 585 3668 a Fm(\017)p Black 46 w Fo(By)21 -b(calling)j(the)f(functions)i(of)d(the)h(MTR)e(library)j(\(part)f(of)f -(the)h(distrib)n(ution\),)j(and)d(by)676 3781 y(re)o(gistering)i(the)d -(result)i(with)e(the)g(manager)i(using)f Fn(Cudd)p 2510 -3781 V 34 w(SetT)-5 b(r)m(ee)p Fo(.)29 b(The)22 b(current)i(tree)676 -3894 y(re)o(gistered)h(with)f(the)g(manager)g(can)g(be)g(read)g(with)f -Fn(Cudd)p 2531 3894 V 34 w(ReadT)-5 b(r)m(ee)p Fo(.)589 -4067 y(Each)36 b(node)h(in)f(the)g(tree)h(represents)h(a)e(range)h(of)f -(v)n(ariables.)68 b(The)35 b(lo)n(wer)h(bound)h(of)448 -4180 y(the)29 b(range)g(is)f(gi)n(v)o(en)h(by)f(the)h -Fn(low)e Fo(\002eld)h(of)g(the)h(node,)h(and)f(the)f(size)h(of)f(the)g -(group)i(is)e(gi)n(v)o(en)448 4293 y(by)33 b(the)g Fn(size)g -Fo(\002eld)g(of)g(the)g(node.)1525 4260 y Fg(2)1619 4293 -y Fo(The)f(v)n(ariables)j(in)e(each)g(range)h(are)f(k)o(ept)g -(contiguous.)448 4405 y(Furthermore,)22 b(if)e(a)f(node)i(is)f(mark)o -(ed)g(with)g(the)g(MTR)p 2159 4405 V 32 w(FIXED)e(\003ag,)i(then)g(the) -g(relati)n(v)o(e)h(order)448 4518 y(of)32 b(the)g(v)n(ariable)i(ranges) -g(associated)g(to)e(its)g(children)i(is)e(not)h(changed.)56 -b(As)31 b(an)h(e)o(xample,)448 4631 y(suppose)26 b(the)e(initial)h(v)n -(ariable)g(order)f(is:)p Black 448 4706 1196 4 v 554 -4762 a Ff(2)583 4794 y Fe(When)18 b(the)g(v)n(ariables)h(in)f(a)g -(group)h(are)f(reordered,)h(the)g(association)g(between)f(the)h -Fb(low)e Fe(\002eld)h(and)h(the)f(inde)o(x)448 4885 y(of)k(the)h -(\002rst)e(v)n(ariable)h(in)g(the)h(group)g(is)f(lost.)32 -b(The)22 b(package)i(updates)f(the)f(tree)g(to)g(k)o(eep)h(track)f(of)h -(the)f(changes.)448 4976 y(Ho)n(we)n(v)o(er)m(,)e(the)f(application)g -(cannot)h(rely)f(on)h Fb(low)e Fe(to)h(determine)g(the)g(position)h(of) -f(v)n(ariables.)p Black Black 1897 5225 a Fo(19)p Black -eop end -%%Page: 20 20 -TeXDict begin 20 19 bop Black Black Black Black 448 573 -a Fh(x0,)54 b(y0,)f(z0,)g(x1,)g(y1,)g(z1,)g(...)h(,)g(x9,)f(y9,)g(z9.) -448 748 y Fo(Suppose)27 b(we)f(w)o(ant)f(to)h(k)o(eep)h(each)g(group)g -(of)f(three)g(v)n(ariables)i(with)e(the)g(same)g(inde)o(x)h(\(e.g.,)448 -861 y Fh(x3,)54 b(y3,)f(z3)p Fo(\))21 b(contiguous,)27 -b(while)c(allo)n(wing)h(the)g(package)h(to)e(change)i(the)f(order)g(of) -f(the)448 974 y(groups.)31 b(W)-7 b(e)22 b(can)i(accomplish)i(this)e -(with)f(the)h(follo)n(wing)h(code:)p Black Black 448 -1150 a Fh(for)54 b(\(i)f(=)h(0;)g(i)g(<)g(10;)f(i++\))g({)667 -1262 y(\(void\))e(Cudd_MakeTreeNo)o(de\()o(ma)o(na)o(ge)o(r,)o(i*3)o -(,3)o(,M)o(TR)o(_D)o(EFA)o(UL)o(T\))o(;)448 1375 y(})448 -1551 y Fo(If)26 b(we)f(w)o(ant)h(to)g(k)o(eep)h(the)f(order)h(within)g -(each)g(group)g(of)f(v)n(ariables)i(\002x)o(ed)e(\(i.e.,)f -Fh(x)g Fo(before)j Fh(y)448 1664 y Fo(before)d Fh(z)p -Fo(\))e(we)f(need)j(to)e(change)i(MTR)p 1710 1664 28 -4 v 32 w(DEF)-7 b(A)i(UL)d(T)20 b(into)k(MTR)p 2521 1664 -V 32 w(FIXED.)589 1777 y(The)32 b Fn(low)f Fo(parameter)i(passed)g(to)f -Fn(Cudd)p 1894 1777 V 33 w(Mak)o(eT)-5 b(r)m(eeNode)33 -b Fo(is)f(the)g(inde)o(x)g(of)f(a)h(v)n(ariable)448 1890 -y(\(as)27 b(opposed)i(to)e(its)f(le)n(v)o(el)h(or)g(position)i(in)d -(the)h(order\).)39 b(The)27 b(group)g(tree)h(can)f(be)f(created)i(at) -448 2003 y(an)o(y)g(time.)40 b(The)27 b(result)h(ob)o(viously)i -(depends)f(on)f(the)f(v)n(ariable)i(order)g(in)e(ef)n(fect)h(at)f -(creation)448 2115 y(time.)589 2228 y(It)20 b(is)g(possible)i(to)e -(create)h(a)e(v)n(ariable)j(group)f(tree)f(also)h(before)g(the)f(v)n -(ariables)i(themselv)o(es)448 2341 y(are)f(created.)29 -b(The)21 b(package)h(assumes)g(in)e(this)i(case)f(that)g(the)g(inde)o -(x)g(of)g(the)f(v)n(ariables)j(not)e(yet)448 2454 y(in)h(e)o(xistence)i -(will)e(equal)g(their)h(position)h(in)e(the)g(order)h(when)f(the)o(y)g -(are)g(created.)30 b(Therefore,)448 2567 y(applications)g(that)c(rely)h -(on)f Fn(Cudd)p 1558 2567 V 34 w(bddNe)o(wV)-10 b(arAtLe)o(vel)26 -b Fo(or)g Fn(Cudd)p 2613 2567 V 34 w(addNe)o(wV)-10 b(arAtLe)o(vel)26 -b Fo(to)448 2680 y(create)f(ne)n(w)e(v)n(ariables)j(ha)n(v)o(e)e(to)f -(create)i(the)f(v)n(ariables)h(before)g(the)o(y)f(group)h(them.)589 -2793 y(The)31 b(reordering)j(procedure)g(will)d(skip)h(all)g(groups)h -(whose)e(v)n(ariables)j(are)d(not)h(yet)f(in)448 2906 -y(e)o(xistence.)h(F)o(or)24 b(groups)h(that)g(are)f(only)h(partially)h -(in)e(e)o(xistence,)i(the)e(reordering)j(procedure)448 -3019 y(will)18 b(try)h(to)f(reorder)i(the)e(v)n(ariables)i(already)g -(instantiated,)j(without)c(violating)i(the)d(adjacenc)o(y)448 -3132 y(constraints.)448 3378 y Fi(3.14)99 b(V)-9 b(ariable)25 -b(Reordering)h(f)n(or)e(ZDDs)448 3553 y Fo(Reordering)h(of)d(ZDDs)f(is) -h(done)h(in)g(much)f(the)h(same)f(w)o(ay)h(as)f(the)g(reordering)k(of)c -(BDDs)f(and)448 3666 y(ADDs.)28 b(The)23 b(functions)j(corresponding)i -(to)c Fn(Cudd)p 2095 3666 V 33 w(ReduceHeap)i Fo(and)e -Fn(Cudd)p 2966 3666 V 33 w(Shuf)n(\003eHeap)448 3778 -y Fo(are)h Fn(Cudd)p 784 3778 V 33 w(zddReduceHeap)i -Fo(and)e Fn(Cudd)p 1782 3778 V 34 w(zddShuf)n(\003eHeap)p -Fo(.)34 b(T)-7 b(o)23 b(enable)j(dynamic)f(reorder)n(-)448 -3891 y(ing,)36 b(the)e(application)j(must)c(call)h Fn(Cudd)p -1777 3891 V 34 w(A)n(utodynEnableZdd)r Fo(,)39 b(and)34 -b(to)g(disable)h(dynamic)448 4004 y(reordering,)29 b(it)d(must)g(call)g -Fn(Cudd)p 1510 4004 V 34 w(A)n(utodynDisableZdd)r Fo(.)39 -b(In)26 b(the)g(current)i(implementation,)448 4117 y(ho)n(we)n(v)o(er)l -(,)c(the)f(choice)h(of)f(reordering)j(methods)e(for)g(ZDDs)d(is)i(more) -g(limited.)29 b(Speci\002cally)-6 b(,)448 4230 y(these)25 -b(methods)g(are)e(a)n(v)n(ailable:)p Black 448 4428 a -Fp(CUDD)p 717 4428 V 32 w(REORDER)p 1206 4428 V 30 w(NONE;)p -Black Black 448 4611 a(CUDD)p 717 4611 V 32 w(REORDER)p -1206 4611 V 30 w(SAME;)p Black Black 448 4794 a(CUDD)p -717 4794 V 32 w(REORDER)p 1206 4794 V 30 w(RANDOM;)p -Black Black 448 4976 a(CUDD)p 717 4976 V 32 w(REORDER)p -1206 4976 V 30 w(RANDOM)p 1657 4976 V 31 w(PIV)l(O)l(T;)p -Black Black 1897 5225 a Fo(20)p Black eop end -%%Page: 21 21 -TeXDict begin 21 20 bop Black Black Black 448 573 a Fp(CUDD)p -717 573 28 4 v 32 w(REORDER)p 1206 573 V 30 w(SIFT;)p -Black Black 448 760 a(CUDD)p 717 760 V 32 w(REORDER)p -1206 760 V 30 w(SIFT)p 1439 760 V 32 w(CONVERGE;)p Black -Black 448 948 a(CUDD)p 717 948 V 32 w(REORDER)p 1206 -948 V 30 w(SYMM)p 1525 948 V 31 w(SIFT;)p Black Black -448 1136 a(CUDD)p 717 1136 V 32 w(REORDER)p 1206 1136 -V 30 w(SYMM)p 1525 1136 V 31 w(SIFT)p 1759 1136 V 32 -w(CONV.)p Black 589 1348 a Fo(T)-7 b(o)20 b(create)j(ZDD)c(v)n(ariable) -k(groups,)g(the)e(application)j(calls)e Fn(Cudd)p 2693 -1348 V 34 w(Mak)o(eZddT)-5 b(r)m(eeNode)p Fo(.)448 1597 -y Fi(3.15)99 b(K)n(eeping)25 b(Consistent)g(V)-9 b(ariable)25 -b(Orders)g(f)n(or)g(BDDs)g(and)g(ZDDs)448 1772 y Fo(Se)n(v)o(eral)f -(applications)i(that)e(manipulate)i(both)e(BDDs)d(and)j(ZDDs)d -(bene\002t)j(from)f(k)o(eeping)j(a)448 1885 y(\002x)o(ed)e -(correspondence)29 b(between)d(the)f(order)g(of)f(the)h(BDD)d(v)n -(ariables)27 b(and)e(the)f(order)i(of)e(the)448 1998 -y(ZDD)k(v)n(ariables.)51 b(If)30 b(each)h(BDD)d(v)n(ariable)k -(corresponds)h(to)d(a)g(group)h(of)f(ZDD)e(v)n(ariables,)448 -2110 y(then)34 b(it)e(is)g(often)i(desirable)h(that)e(the)g(groups)h -(of)f(ZDD)d(v)n(ariables)35 b(be)d(in)h(the)g(same)f(order)448 -2223 y(as)g(the)g(corresponding)37 b(BDD)30 b(v)n(ariables.)55 -b(CUDD)30 b(allo)n(ws)i(the)h(ZDD)c(order)k(to)f(track)h(the)448 -2336 y(BDD)27 b(order)j(and)f(vice)g(v)o(ersa.)45 b(T)-7 -b(o)27 b(ha)n(v)o(e)j(the)f(ZDD)d(order)k(track)f(the)g(BDD)e(order)l -(,)k(the)e(ap-)448 2449 y(plication)g(calls)e Fn(Cudd)p -1185 2449 V 34 w(zddRealignEnable)p Fo(.)41 b(The)26 -b(ef)n(fect)i(of)e(this)h(call)g(can)g(be)f(re)n(v)o(ersed)i(by)448 -2562 y(calling)j Fn(Cudd)p 925 2562 V 34 w(zddRealignDisable)p -Fo(.)48 b(When)29 b(ZDD)e(realignment)k(is)e(in)g(ef)n(fect,)i -(automatic)448 2675 y(reordering)c(of)c(ZDDs)f(should)j(be)f(disabled.) -448 2924 y Fi(3.16)99 b(Hooks)448 3098 y Fo(Hooks)22 -b(in)f(CUDD)d(are)k(lists)f(of)g(application-speci\002ed)27 -b(functions)c(to)e(be)g(run)g(on)h(certain)g(oc-)448 -3211 y(casions.)29 b(Each)18 b(hook)h(is)f(identi\002ed)i(by)e(a)g -(constant)i(of)e(the)g(enumerated)j(type)d Fn(Cudd)p -3125 3211 V 34 w(HookT)-7 b(ype)p Fo(.)448 3324 y(In)24 -b(V)-10 b(ersion)24 b(2.5.0)g(hooks)h(are)e(de\002ned)i(for)e(these)i -(occasions:)p Black 585 3512 a Fm(\017)p Black 46 w Fo(before)f -(garbage)h(collection)i(\(CUDD)p 1916 3512 V 31 w(PRE)p -2115 3512 V 32 w(GC)p 2274 3512 V 32 w(HOOK\);)p Black -585 3700 a Fm(\017)p Black 46 w Fo(after)d(garbage)h(collection)h -(\(CUDD)p 1850 3700 V 32 w(POST)p 2106 3700 V 31 w(GC)p -2264 3700 V 32 w(HOOK\);)p Black 585 3887 a Fm(\017)p -Black 46 w Fo(before)e(v)n(ariable)i(reordering)g(\(CUDD)p -1939 3887 V 32 w(PRE)p 2139 3887 V 31 w(REORDERING)p -2759 3887 V 30 w(HOOK\);)p Black 585 4075 a Fm(\017)p -Black 46 w Fo(after)e(v)n(ariable)h(reordering)h(\(CUDD)p -1873 4075 V 32 w(POST)p 2129 4075 V 31 w(REORDERING)p -2749 4075 V 30 w(HOOK\).)448 4262 y(The)e(current)i(implementation)i -(of)c(hooks)i(is)e(e)o(xperimental.)34 b(A)24 b(function)i(added)g(to)e -(a)g(hook)448 4375 y(recei)n(v)o(es)c(a)e(pointer)i(to)e(the)g(manager) -l(,)j(a)d(pointer)i(to)e(a)g(constant)i(string,)h(and)d(a)g(pointer)i -(to)e(v)n(oid)448 4488 y(as)27 b(ar)n(guments;)j(it)d(must)f(return)i -(1)e(if)g(successful;)31 b(0)c(otherwise.)39 b(The)26 -b(second)i(ar)n(gument)g(is)448 4601 y(one)21 b(of)f(\223DD,)-6 -b(\224)19 b(\223BDD,)-6 b(\224)18 b(and)j(\223ZDD.)-6 -b(\224)18 b(This)i(allo)n(ws)h(the)f(hook)h(functions)i(to)d(tell)h -(the)f(type)h(of)448 4714 y(diagram)f(for)f(which)h(reordering)h(or)e -(garbage)h(collection)i(tak)o(es)e(place.)28 b(The)19 -b(third)g(ar)n(gument)448 4827 y(v)n(aries)30 b(depending)h(on)e(the)g -(hook.)45 b(The)28 b(hook)h(functions)i(called)f(before)g(or)f(after)g -(garbage)448 4940 y(collection)d(do)d(not)g(use)g(it.)28 -b(The)23 b(hook)h(functions)h(called)f(before)g(reordering)i(are)d -(passed,)h(in)p Black 1897 5225 a(21)p Black eop end -%%Page: 22 22 -TeXDict begin 22 21 bop Black Black 448 573 a Fo(addition)32 -b(to)d(the)h(pointer)h(to)f(the)g(manager)l(,)i(also)e(the)g(method)g -(used)h(for)e(reordering.)50 b(The)448 686 y(hook)27 -b(functions)h(called)f(after)f(reordering)j(are)d(passed)h(the)f(start) -g(time.)35 b(T)-7 b(o)25 b(add)h(a)f(function)448 799 -y(to)e(a)g(hook,)g(one)h(uses)f Fn(Cudd)p 1363 799 28 -4 v 34 w(AddHook)r Fo(.)29 b(The)22 b(function)j(of)e(a)g(gi)n(v)o(en)g -(hook)h(are)f(called)h(in)f(the)448 912 y(order)k(in)e(which)h(the)o(y) -g(were)f(added)i(to)f(the)f(hook.)36 b(F)o(or)25 b(sample)h(hook)g -(functions,)j(one)d(may)448 1024 y(look)f(at)e Fn(Cudd)p -922 1024 V 34 w(StdPr)m(eReor)m(dHook)k Fo(and)d Fn(Cudd)p -1990 1024 V 34 w(StdP)-7 b(ostReor)m(dHook)r Fo(.)448 -1274 y Fi(3.17)99 b(T)n(imeouts)26 b(and)f(Limits)448 -1448 y Fo(It)19 b(is)h(possible)h(to)f(set)f(a)g(time)g(limit)h(for)f -(a)g(manger)h(with)g Fn(Cudd)p 2413 1448 V 33 w(SetT)-5 -b(imeLimit)r Fo(.)27 b(Once)20 b(set,)g(the)448 1561 -y(time)g(a)n(v)n(ailable)i(to)e(the)h(manager)g(can)f(be)g(modi\002ed)h -(through)h(other)f(API)d(functions.)31 b(CUDD)448 1674 -y(checks)e(for)e(e)o(xpiration)i(periodically)-6 b(.)43 -b(When)27 b(time)g(has)g(e)o(xpired,)j(it)c(returns)j(NULL)24 -b(from)448 1787 y(the)29 b(call)h(in)e(progress,)k(b)n(ut)e(it)e(lea)n -(v)o(es)i(the)f(manager)h(in)f(a)f(consistent)k(state.)45 -b(The)28 b(in)l(v)n(oking)448 1900 y(application)f(must)d(be)f -(designed)j(to)d(handle)j(the)d(NULL)e(v)n(alues)k(returned.)589 -2013 y(When)35 b(reordering,)k(if)34 b(a)g(timout)h(is)f(approaching,) -41 b(CUDD)31 b(will)j(quit)h(reordering)i(to)448 2125 -y(gi)n(v)o(e)24 b(the)g(application)i(a)e(chance)h(to)e(\002nish)h -(some)g(computation.)589 2238 y(It)31 b(is)h(also)f(possible)j(to)d(in) -l(v)n(ok)o(e)j(some)d(functions)j(that)e(return)g(NULL)d(if)i(the)o(y)h -(cannot)448 2351 y(complete)k(without)f(creating)i(more)d(than)h(a)f -(set)g(number)h(of)g(nodes.)62 b(See,)36 b(for)e(instance,)448 -2464 y Fn(Cudd)p 649 2464 V 34 w(bddAndLimit)r Fo(.)448 -2713 y Fi(3.18)99 b(The)26 b(SIS/VIS)f(Interface)448 -2888 y Fo(The)j(CUDD)d(package)30 b(contains)f(interf)o(ace)h -(functions)h(that)d(emulate)g(the)g(beha)n(vior)i(of)e(the)448 -3001 y(original)i(BDD)c(package)k(used)f(in)f(SIS)e([17)q(])i(and)g(in) -g(the)g(ne)n(wer)g(VIS)2719 2968 y Fg(3)2783 3001 y Fo([4].)42 -b(Ho)n(w)26 b(to)i(b)n(uild)448 3113 y(VIS)i(with)i(CUDD)d(is)i -(described)j(in)e(the)f(installation)k(documents)f(of)d(VIS.)f(\(V)-10 -b(ersion)32 b(1.1)448 3226 y(and)24 b(later)-5 b(.\))448 -3472 y Fp(3.18.1)93 b(Using)22 b(the)h(CUDD)f(P)o(ackage)i(in)e(SIS)448 -3646 y Fo(This)32 b(section)h(describes)h(ho)n(w)d(to)h(b)n(uild)g(SIS) -f(with)g(the)h(CUDD)d(package.)55 b(Let)31 b Fh(SISDIR)448 -3759 y Fo(designate)41 b(the)d(root)h(of)f(the)g(directory)j(hierarchy) -f(where)e(the)h(sources)g(for)g(SIS)d(reside.)448 3872 -y(Let)27 b Fh(CUDDDIR)d Fo(be)j(the)h(root)g(of)g(the)f(directory)j -(hierarchy)g(where)e(the)f(distrib)n(ution)32 b(of)27 -b(the)448 3985 y(CUDD)21 b(package)k(resides.)30 b(T)-7 -b(o)22 b(b)n(uild)i(SIS)d(with)i(the)g(CUDD)e(package,)k(follo)n(w)e -(these)h(steps.)p Black 562 4173 a(1.)p Black 46 w(Create)g -(directories)i Fh(SISDIR/sis/cudd)16 b Fo(and)24 b Fh(SISDIR/sis/mtr)p -Fo(.)p Black 562 4360 a(2.)p Black 46 w(Cop)o(y)18 b(all)g(\002les)g -(from)g Fh(CUDDDIR/cudd)12 b Fo(and)18 b Fh(CUDDDIR/sis)13 -b Fo(to)18 b Fh(SISDIR/sis/cud)o(d)676 4473 y Fo(and)24 -b(all)f(\002les)g(from)h Fh(CUDDDIR/mtr)18 b Fo(to)23 -b Fh(SISDIR/sis/mtr)p Fo(.)p Black 562 4661 a(3.)p Black -46 w(Cop)o(y)35 b Fh(CUDDDIR/cudd/d)o(oc)o(/c)o(ud)o(d.d)o(oc)27 -b Fo(to)35 b Fh(SISDIR/sis/cud)o(d)p Fo(;)f(also)676 -4774 y(cop)o(y)24 b Fh(CUDDDIR/mtr/doc)o(/m)o(tr)o(.do)o(c)16 -b Fo(to)24 b Fh(SISDIR/sis/mtr)o Fo(.)p Black 448 4855 -1196 4 v 554 4911 a Ff(3)583 4942 y Fe(http://vlsi.Colorado.EDU/)18 -b(vis/)p Black Black 1897 5225 a Fo(22)p Black eop end -%%Page: 23 23 -TeXDict begin 23 22 bop Black Black Black 562 573 a Fo(4.)p -Black 46 w(In)38 b Fh(SISDIR/sis/cud)o(d)31 b Fo(mak)o(e)39 -b Fh(bdd.h)c Fo(a)j(symbolic)h(link)g(to)f Fh(cuddBdd.h)p -Fo(.)676 686 y(\(That)23 b(is:)29 b Fh(ln)54 b(-s)g(cuddBdd.h)c(bdd.h)p -Fo(.\))p Black 562 873 a(5.)p Black 46 w(In)27 b Fh(SISDIR/sis/cudd)20 -b Fo(delete)29 b Fh(Makefile)23 b Fo(and)28 b(rename)h -Fh(Makefile.sis)676 986 y Fo(as)23 b Fh(Makefile)p Fo(.)h(Do)f(the)h -(same)f(in)h Fh(SISDIR/sis/mtr)p Fo(.)p Black 562 1174 -a(6.)p Black 46 w(Cop)o(y)18 b Fh(CUDDDIR/sis/st.)o([c)o(h])11 -b Fo(and)18 b Fh(CUDDDIR/st/doc/)o(st)o(.d)o(oc)11 b -Fo(to)18 b Fh(SISDIR/sis/st)p Fo(.)676 1287 y(\(This)29 -b(will)h(o)o(v)o(erwrite)h(the)f(original)h(\002les:)42 -b(Y)-10 b(ou)29 b(may)h(w)o(ant)g(to)g(sa)n(v)o(e)g(them)g(before-)676 -1400 y(hand.\))p Black 562 1587 a(7.)p Black 46 w(From)17 -b Fh(CUDDDIR/util)12 b Fo(cop)o(y)19 b Fh(datalimit.c)12 -b Fo(to)18 b Fh(SISDIR/sis/util)o Fo(.)i(Up-)676 1700 -y(date)30 b Fh(util.h)d Fo(and)k Fh(Makefile)26 b Fo(in)k -Fh(SISDIR/sis/uti)o(l)p Fo(.)42 b(Speci\002cally)-6 b(,)33 -b(add)676 1813 y(the)38 b(declaration)k Fh(EXTERN)52 -b(long)g(getSoftDataLimi)o(t\(\))o(;)39 b Fo(to)f Fh(util.h)676 -1926 y Fo(and)24 b(add)g Fh(datalimit.c)17 b Fo(to)24 -b(the)g(list)f(of)h(source)h(\002les)e(\(PSRC\))f(in)h -Fh(Makefile)p Fo(.)p Black 562 2114 a(8.)p Black 46 w(In)g -Fh(SISDIR/sis)17 b Fo(remo)o(v)o(e)23 b(the)h(link)f(from)g -Fh(bdd)e Fo(to)i Fh(bdd)p 2578 2114 28 4 v 31 w(cmu)e -Fo(or)i Fh(bdd)p 3058 2114 V 32 w(ucb)d Fo(\(that)676 -2227 y(is,)36 b Fh(rm)54 b(bdd)p Fo(\))32 b(and)j(mak)o(e)f -Fh(bdd)e Fo(a)i(symbolic)i(link)f(to)f Fh(cudd)p Fo(.)58 -b(\(That)35 b(is:)50 b Fh(ln)k(-s)676 2340 y(cudd)e(bdd)p -Fo(.\))p Black 562 2527 a(9.)p Black 46 w(Still)17 b(in)h -Fh(SISDIR/sis)p Fo(,)c(edit)19 b Fh(Makefile)p Fo(,)14 -b Fh(Makefile.oct)p Fo(,)f(and)18 b Fh(Makefile.nooct)p -Fo(.)676 2640 y(In)23 b(all)h(three)g(\002les)f(add)h(mtr)f(to)h(the)g -(list)g(of)f(directories)j(to)e(be)f(made)h(\(DIRS\).)p -Black 517 2828 a(10.)p Black 46 w(In)18 b Fh(SISDIR/sis/inc)o(lu)o(de) -11 b Fo(mak)o(e)18 b Fh(mtr.h)d Fo(a)j(symbolic)h(link)g(to)f -Fh(../mtr/mtr.h)p Fo(.)p Black 517 3015 a(11.)p Black -46 w(In)g Fh(SISDIR/sis/doc)10 b Fo(mak)o(e)19 b Fh(cudd.doc)13 -b Fo(a)18 b(symbolic)i(link)e(to)g Fh(../cudd/cudd.doc)676 -3128 y Fo(and)32 b Fh(mtr.doc)d Fo(a)j(symbolic)h(link)g(to)g -Fh(../mtr/mtr.doc)o Fo(.)48 b(\(That)33 b(is:)46 b Fh(ln)54 -b(-s)676 3241 y(../cudd/cudd.d)o(oc)48 b(.;)53 b(ln)h(-s)g -(../mtr/mtr.doc)48 b(.)p Fo(.\))p Black 517 3429 a(12.)p -Black 46 w(From)25 b Fh(SISDIR)e Fo(do)j Fh(make)53 b(clean)23 -b Fo(follo)n(wed)k(by)f Fh(make)53 b(-i)p Fo(.)35 b(This)26 -b(should)i(cre-)676 3542 y(ate)23 b(a)g(w)o(orking)i(cop)o(y)g(of)e -(SIS)f(that)i(uses)h(the)e(CUDD)f(package.)589 3729 y(The)35 -b(replacement)j(for)d(the)h Fh(st)d Fo(library)k(is)e(because)i(the)e -(v)o(ersion)i(shipped)g(with)e(the)448 3842 y(CUDD)22 -b(package)27 b(tests)e(for)f(out-of-memory)j(conditions.)35 -b(Notice)24 b(that)h(the)g(v)o(ersion)h(of)e(the)448 -3955 y Fh(st)32 b Fo(library)k(to)e(be)f(used)i(for)f(replacement)j(is) -c(not)h(the)h(one)f(used)h(for)f(the)g(normal)g(b)n(uild,)448 -4068 y(because)26 b(the)e(latter)g(has)g(been)h(modi\002ed)f(for)g(C++) -f(compatibility)-6 b(.)32 b(The)23 b(abo)o(v)o(e)h(installation)448 -4181 y(procedure)34 b(has)e(been)h(tested)f(on)g(SIS)e(1.3.)52 -b(SIS)30 b(can)i(be)g(obtained)h(via)f(anon)o(ymous)h(FTP)448 -4294 y(from)18 b Fh(ic.eecs.berkele)o(y.e)o(du)o Fo(.)i(T)-7 -b(o)17 b(b)n(uild)j(SIS)c(1.3,)j(you)g(need)g Fh(sis-1.2.tar.Z)448 -4407 y Fo(and)g Fh(sis-1.2.patch1.Z)o Fo(.)12 b(When)19 -b(compiling)h(on)f(a)f(DEC)f(Alpha,)i(you)h(should)g(add)f(the)448 -4520 y Fh(-ieee)p 728 4520 V 31 w(with)p 979 4520 V 31 -w(no)p 1120 4520 V 31 w(inexact)e Fo(\003ag.)27 b(\(See)20 -b(Section)h(3.5.2.\))28 b(Refer)20 b(to)g(the)h Fh(Makefile)15 -b Fo(in)448 4633 y(the)24 b(top)g(le)n(v)o(el)g(directory)i(of)d(the)h -(distrib)n(ution)j(for)d(ho)n(w)f(to)g(compile)i(with)e(32-bit)i -(pointers.)p Black 1897 5225 a(23)p Black eop end -%%Page: 24 24 -TeXDict begin 24 23 bop Black Black 448 573 a Fi(3.19)99 -b(Writing)25 b(Decision)f(Diagrams)g(to)h(a)g(File)448 -747 y Fo(The)c(CUDD)e(package)k(pro)o(vides)g(se)n(v)o(eral)f -(functions)i(to)d(write)g(decision)j(diagrams)e(to)f(a)g(\002le.)448 -860 y Fn(Cudd)p 649 860 28 4 v 34 w(DumpBlif)35 b Fo(writes)23 -b(a)f(\002le)g(in)g Fn(blif)37 b Fo(format.)28 b(It)23 -b(is)f(restricted)j(to)d(BDDs.)27 b(The)22 b(diagrams)448 -973 y(are)j(written)g(as)f(a)g(netw)o(ork)i(of)e(multiple)o(x)o(ers,)i -(one)f(multiple)o(x)o(er)h(for)f(each)g(internal)h(node)f(of)448 -1086 y(the)f(BDD.)589 1199 y Fn(Cudd)p 790 1199 V 34 -w(DumpDot)37 b Fo(produces)i(input)e(suitable)h(to)e(the)g(graph-dra)o -(wing)j(program)e Fn(dot)3399 1166 y Fg(4)448 1312 y -Fo(written)29 b(by)g(Eleftherios)h(K)m(outso\002os)g(and)f(Stephen)g -(C.)e(North.)43 b(An)28 b(e)o(xample)h(of)g(dra)o(wing)448 -1425 y(produced)f(by)d(dot)g(from)g(the)g(output)h(of)f -Fn(Cudd)p 1959 1425 V 34 w(DumpDot)h Fo(is)e(sho)n(wn)i(in)e(Figure)i -(1.)32 b(It)25 b(is)f(re-)448 1537 y(stricted)j(to)d(BDDs)f(and)h -(ADDs.)30 b Fn(Cudd)p 1726 1537 V 34 w(zddDumpDot)d Fo(is)d(the)h -(analog)h(of)e Fn(Cudd)p 3050 1537 V 34 w(DumpDot)448 -1650 y Fo(for)g(ZDDs.)589 1763 y Fn(Cudd)p 790 1763 V -34 w(DumpDaV)-7 b(inci)41 b Fo(produces)i(input)f(suitable)g(to)f(the)g -(graph-dra)o(wing)i(program)448 1876 y Fn(daV)-7 b(inci)722 -1843 y Fg(5)799 1876 y Fo(de)n(v)o(eloped)40 b(at)d(the)i(Uni)n(v)o -(ersity)g(of)f(Bremen.)71 b(It)38 b(is)f(restricted)k(to)d(BDDs)e(and) -448 1989 y(ADDs.)589 2102 y(Functions)f(are)d(also)h(a)n(v)n(ailable)h -(to)f(produce)h(the)e(input)i(format)f(of)f Fn(DDcal)g -Fo(\(see)h(Sec-)448 2215 y(tion)24 b(2.2\))g(and)g(f)o(actored)i -(forms.)448 2464 y Fi(3.20)99 b(Sa)n(ving)25 b(and)g(Restoring)g(BDDs) -448 2638 y Fo(The)e Fn(dddmp)858 2605 y Fg(6)919 2638 -y Fo(library)i(by)e(Gianpiero)i(Cabodi)f(and)g(Stef)o(ano)g(Quer)f -(allo)n(ws)g(a)g(CUDD)e(appli-)448 2751 y(cation)30 b(to)e(sa)n(v)o(e)h -(BDDs)d(to)j(disk)g(in)f(compact)h(form)f(for)h(later)g(retrie)n(v)n -(al.)44 b(See)28 b(the)g(library')-5 b(s)448 2864 y(o)n(wn)23 -b(documentation)k(for)d(the)g(details.)448 3157 y Fq(4)120 -b(Pr)n(ogrammer')l(s)27 b(Manual)448 3364 y Fo(This)g(section)i(pro)o -(vides)g(additional)h(detail)e(on)f(the)g(w)o(orking)i(of)e(the)g(CUDD) -e(package)k(and)448 3477 y(on)37 b(the)g(programming)h(con)l(v)o -(entions)i(follo)n(wed)e(in)e(its)h(writing.)68 b(The)36 -b(additional)j(detail)448 3590 y(should)21 b(help)f(those)h(who)e(w)o -(ant)g(to)h(write)f(procedures)j(that)e(directly)h(manipulate)h(the)e -(CUDD)448 3703 y(data)k(structures.)448 3952 y Fi(4.1)99 -b(Compiling)25 b(and)g(Linking)448 4126 y Fo(If)32 b(you)h(plan)h(to)e -(use)h(the)f(CUDD)f(package)j(as)e(a)g(clear)i(box)f(\(for)f(instance,) -37 b(you)c(w)o(ant)f(to)448 4239 y(write)24 b(a)f(procedure)j(that)e -(tra)n(v)o(erses)i(a)d(decision)j(diagram\))f(you)f(need)g(to)f(add)p -Black Black 448 4427 a Fh(#include)51 b("cuddInt.h")p -Black 448 4491 1196 4 v 554 4546 a Ff(4)583 4578 y Fe(http://www)-5 -b(.research.att.com/sw/tools/graphviz)554 4640 y Ff(5)583 -4671 y Fe(ftp://ftp.uni-bremen.de/pub/graphics/daV)l(inci)554 -4733 y Ff(6)583 4764 y Fe(ftp://ftp.polito.it/pub/research/dddmp/)p -Black Black 1897 5225 a Fo(24)p Black eop end -%%Page: 25 25 -TeXDict begin 25 24 bop Black Black Black 721 4226 a -@beginspecial 66 @llx 36 @lly 547 @urx 757 @ury 4393 -@rhi @setspecial -%%BeginDocument: phase.ps -%!PS-Adobe-2.0 -%%Creator: dot version 95 (4-10-95) -%%For: (fabio) Fabio Somenzi,OT4-11,2-3466,ECE faculty -%%Title: DD -%%Pages: (atend) -%%BoundingBox: 66 36 547 757 -%%EndComments -%%BeginProlog -save -/DotDict 200 dict def -DotDict begin - -%%BeginResource: procset -/coord-font-family /Times-Roman def -/default-font-family /Times-Roman def -/coordfont coord-font-family findfont 8 scalefont def - -/InvScaleFactor 1.0 def -/set_scale { - dup 1 exch div /InvScaleFactor exch def - dup scale -} bind def - -% styles -/solid { } bind def -/dashed { [9 InvScaleFactor mul dup ] 0 setdash } bind def -/dotted { [1 InvScaleFactor mul 6 InvScaleFactor mul] 0 setdash } bind def -/invis {/fill {newpath} def /stroke {newpath} def /show {pop newpath} def} bind def -/bold { 2 setlinewidth } bind def -/filled { } bind def -/unfilled { } bind def -/rounded { } bind def -/diagonals { } bind def - -% hooks for setting color -/nodecolor { sethsbcolor } bind def -/edgecolor { sethsbcolor } bind def -/graphcolor { sethsbcolor } bind def -/nopcolor {pop pop pop} bind def - -/beginpage { % i j npages - /npages exch def - /j exch def - /i exch def - /str 10 string def - npages 1 gt { - gsave - coordfont setfont - 0 0 moveto - (() show i str cvs show (,) show j str cvs show ()) show - grestore - } if -} bind def - -/set_font { - findfont exch - scalefont setfont -} def - -/arrowhead { - /arrowwidth exch def - /arrowlength exch def - gsave - 3 1 roll - translate - rotate - newpath - arrowlength arrowwidth 2 div moveto - 0 0 lineto - arrowlength arrowwidth -2 div lineto - closepath fill - stroke - grestore -} def - -% draw aligned label in bounding box aligned to current point -% alignfactor tells what fraction to place on the left. -% -.5 is centered. -/alignedtext { % text labelwidth fontsz alignfactor - /alignfactor exch def - /fontsz exch def - /width exch def - /text exch def - gsave - % even if node or edge is dashed, don't paint text with dashes - [] 0 setdash - currentpoint newpath moveto - text stringwidth pop - alignfactor mul fontsz -.3 mul rmoveto - text show - grestore -} def - -/boxprim { % xcorner ycorner xsize ysize - 4 2 roll - moveto - 2 copy - exch 0 rlineto - 0 exch rlineto - pop neg 0 rlineto - closepath -} bind def - -/ellipse_path { - /ry exch def - /rx exch def - /y exch def - /x exch def - matrix currentmatrix - newpath - x y translate - rx ry scale - 0 0 1 0 360 arc - setmatrix -} bind def - -/endpage { showpage } bind def - -/layercolorseq - [ % layer color sequence - darkest to lightest - [0 0 0] - [.2 .8 .8] - [.4 .8 .8] - [.6 .8 .8] - [.8 .8 .8] - ] -def - -/setlayer {/maxlayer exch def /curlayer exch def - layercolorseq curlayer get - aload pop sethsbcolor - /nodecolor {nopcolor} def - /edgecolor {nopcolor} def - /graphcolor {nopcolor} def -} bind def - -/onlayer { curlayer ne {invis} if } def - -/onlayers { - /myupper exch def - /mylower exch def - curlayer mylower lt - curlayer myupper gt - or - {invis} if -} def - -/curlayer 0 def - -%%EndResource -%%EndProlog -%%BeginSetup -14 default-font-family set_font -% /arrowlength 10 def -% /arrowwidth 5 def -%%EndSetup -%%Page: 1 (atend) -%%PageBoundingBox: 66 36 547 757 -gsave -65 35 482 722 boxprim clip newpath -66 36 translate -0 0 1 beginpage -0.7407 set_scale -0 0 translate 0 rotate -0.000 0.000 0.000 graphcolor -14.00 /Times-Roman set_font - -% CONST NODES -gsave 10 dict begin -invis -gsave 10 dict begin -55 19 moveto (CONST NODES) 96 14.00 -0.50 alignedtext -end grestore -end grestore - -% a110 -gsave 10 dict begin -gsave 10 dict begin -55 883 moveto (a110) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a111 -gsave 10 dict begin -gsave 10 dict begin -55 811 moveto (a111) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a110 -> a111 -gsave 10 dict begin -invis -newpath 55 864 moveto -55 853 55 839 55 828 curveto -stroke -end grestore - -% a210 -gsave 10 dict begin -gsave 10 dict begin -55 739 moveto (a210) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a111 -> a210 -gsave 10 dict begin -invis -newpath 55 792 moveto -55 781 55 767 55 756 curveto -stroke -end grestore - -% a211 -gsave 10 dict begin -gsave 10 dict begin -55 667 moveto (a211) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a210 -> a211 -gsave 10 dict begin -invis -newpath 55 720 moveto -55 709 55 695 55 684 curveto -stroke -end grestore - -% a310 -gsave 10 dict begin -gsave 10 dict begin -55 595 moveto (a310) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a211 -> a310 -gsave 10 dict begin -invis -newpath 55 648 moveto -55 637 55 623 55 612 curveto -stroke -end grestore - -% a311 -gsave 10 dict begin -gsave 10 dict begin -55 523 moveto (a311) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a310 -> a311 -gsave 10 dict begin -invis -newpath 55 576 moveto -55 565 55 551 55 540 curveto -stroke -end grestore - -% a410 -gsave 10 dict begin -gsave 10 dict begin -55 451 moveto (a410) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a311 -> a410 -gsave 10 dict begin -invis -newpath 55 504 moveto -55 493 55 479 55 468 curveto -stroke -end grestore - -% a411 -gsave 10 dict begin -gsave 10 dict begin -55 379 moveto (a411) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a410 -> a411 -gsave 10 dict begin -invis -newpath 55 432 moveto -55 421 55 407 55 396 curveto -stroke -end grestore - -% a510 -gsave 10 dict begin -gsave 10 dict begin -55 307 moveto (a510) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a411 -> a510 -gsave 10 dict begin -invis -newpath 55 360 moveto -55 349 55 335 55 324 curveto -stroke -end grestore - -% a511 -gsave 10 dict begin -gsave 10 dict begin -55 235 moveto (a511) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a510 -> a511 -gsave 10 dict begin -invis -newpath 55 288 moveto -55 277 55 263 55 252 curveto -stroke -end grestore - -% a610 -gsave 10 dict begin -gsave 10 dict begin -55 163 moveto (a610) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a511 -> a610 -gsave 10 dict begin -invis -newpath 55 216 moveto -55 205 55 191 55 180 curveto -stroke -end grestore - -% a611 -gsave 10 dict begin -gsave 10 dict begin -55 91 moveto (a611) 27 14.00 -0.50 alignedtext -end grestore -end grestore - -% a610 -> a611 -gsave 10 dict begin -invis -newpath 55 144 moveto -55 133 55 119 55 108 curveto -stroke -end grestore - -% a611 -> CONST NODES -gsave 10 dict begin -invis -newpath 55 72 moveto -55 61 55 47 55 36 curveto -stroke -end grestore - -% o -gsave 10 dict begin -newpath 511 972 moveto -457 972 lineto -457 936 lineto -511 936 lineto -closepath -stroke -gsave 10 dict begin -484 955 moveto (o) 7 14.00 -0.50 alignedtext -end grestore -end grestore - -% a00 -gsave 10 dict begin -484 882 27 18 ellipse_path -stroke -gsave 10 dict begin -484 883 moveto (a00) 20 14.00 -0.50 alignedtext -end grestore -end grestore - -% o -> a00 -gsave 10 dict begin -solid -newpath 484 936 moveto -484 925 484 911 484 900 curveto -stroke -end grestore - -% 9fc -gsave 10 dict begin -448 810 27 18 ellipse_path -stroke -gsave 10 dict begin -448 811 moveto (9fc) 17 14.00 -0.50 alignedtext -end grestore -end grestore - -% a00 -> 9fc -newpath 475 865 moveto -470 853 462 839 457 827 curveto -stroke - -% 9ff -gsave 10 dict begin -520 810 27 18 ellipse_path -stroke -gsave 10 dict begin -520 811 moveto (9ff) 16 14.00 -0.50 alignedtext -end grestore -end grestore - -% a00 -> 9ff -gsave 10 dict begin -dashed -newpath 493 865 moveto -498 853 506 839 511 827 curveto -stroke -end grestore - -% 995 -gsave 10 dict begin -453 738 27 18 ellipse_path -stroke -gsave 10 dict begin -453 739 moveto (995) 21 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9fc -> 995 -gsave 10 dict begin -dashed -newpath 449 792 moveto -450 781 451 767 452 756 curveto -stroke -end grestore - -% 9fb -gsave 10 dict begin -381 738 27 18 ellipse_path -stroke -gsave 10 dict begin -381 739 moveto (9fb) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9fc -> 9fb -newpath 433 794 moveto -422 782 407 765 396 753 curveto -stroke - -% 9fe -gsave 10 dict begin -584 738 27 18 ellipse_path -stroke -gsave 10 dict begin -584 739 moveto (9fe) 17 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9ff -> 9fe -gsave 10 dict begin -dashed -newpath 534 794 moveto -545 782 560 765 570 753 curveto -stroke -end grestore - -% 95f -gsave 10 dict begin -512 666 27 18 ellipse_path -stroke -gsave 10 dict begin -512 667 moveto (95f) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9ff -> 95f -newpath 519 792 moveto -518 764 515 712 513 684 curveto -stroke - -% 994 -gsave 10 dict begin -347 594 27 18 ellipse_path -stroke -gsave 10 dict begin -347 595 moveto (994) 21 14.00 -0.50 alignedtext -end grestore -end grestore - -% 995 -> 994 -newpath 432 727 moveto -407 714 370 693 363 684 curveto -356 675 351 636 349 612 curveto -stroke - -% 946 -gsave 10 dict begin -newpath 401 36 moveto -347 36 lineto -347 0 lineto -401 0 lineto -closepath -stroke -gsave 10 dict begin -374 19 moveto (1) 7 14.00 -0.50 alignedtext -end grestore -end grestore - -% 995 -> 946 -gsave 10 dict begin -dotted -newpath 584 594 moveto -589 570 587 545 584 522 curveto -stroke -newpath 453 720 moveto -454 698 458 662 473 648 curveto -498 621 544 628 577 612 curveto -582 609 582 600 584 594 curveto -stroke -end grestore - -% 9f7 -gsave 10 dict begin -292 666 27 18 ellipse_path -stroke -gsave 10 dict begin -292 667 moveto (9f7) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9fb -> 9f7 -newpath 363 724 moveto -347 711 325 693 309 680 curveto -stroke - -% 9fa -gsave 10 dict begin -402 666 27 18 ellipse_path -stroke -gsave 10 dict begin -402 667 moveto (9fa) 17 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9fb -> 9fa -gsave 10 dict begin -dashed -newpath 386 720 moveto -389 709 393 695 397 684 curveto -stroke -end grestore - -% 9fd -gsave 10 dict begin -584 666 27 18 ellipse_path -stroke -gsave 10 dict begin -584 667 moveto (9fd) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9fe -> 9fd -newpath 584 720 moveto -584 709 584 695 584 684 curveto -stroke - -% 9fe -> 946 -gsave 10 dict begin -dotted -newpath 600 723 moveto -611 711 625 696 632 684 curveto -637 673 637 658 632 648 curveto -632 648 584 594 584 594 curveto -stroke -end grestore - -% 9f7 -> 994 -gsave 10 dict begin -dashed -newpath 304 650 moveto -313 638 326 622 335 610 curveto -stroke -end grestore - -% 9f6 -gsave 10 dict begin -275 594 27 18 ellipse_path -stroke -gsave 10 dict begin -275 595 moveto (9f6) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f7 -> 9f6 -newpath 288 648 moveto -285 637 282 623 279 612 curveto -stroke - -% 9f9 -gsave 10 dict begin -529 594 27 18 ellipse_path -stroke -gsave 10 dict begin -529 595 moveto (9f9) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9fa -> 9f9 -gsave 10 dict begin -dashed -newpath 423 654 moveto -447 641 485 619 508 606 curveto -stroke -end grestore - -% 95e -gsave 10 dict begin -457 522 27 18 ellipse_path -stroke -gsave 10 dict begin -457 523 moveto (95e) 20 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9fa -> 95e -newpath 465 594 moveto -464 579 462 556 460 540 curveto -stroke -newpath 420 652 moveto -439 638 464 614 465 594 curveto -stroke - -% 95f -> 95e -newpath 497 651 moveto -483 636 464 612 465 594 curveto -stroke - -% 95f -> 946 -gsave 10 dict begin -dotted -newpath 531 653 moveto -551 639 579 615 584 594 curveto -stroke -end grestore - -% 9fd -> 9f9 -newpath 572 650 moveto -563 638 550 622 541 610 curveto -stroke - -% 9fd -> 946 -gsave 10 dict begin -dotted -newpath 582 648 moveto -581 631 580 608 584 594 curveto -stroke -end grestore - -% 993 -gsave 10 dict begin -292 450 27 18 ellipse_path -stroke -gsave 10 dict begin -292 451 moveto (993) 21 14.00 -0.50 alignedtext -end grestore -end grestore - -% 994 -> 993 -newpath 333 578 moveto -323 566 312 551 308 540 curveto -301 521 296 489 294 468 curveto -stroke - -% 994 -> 946 -gsave 10 dict begin -dotted -newpath 357 577 moveto -371 556 396 519 418 504 curveto -447 482 489 484 522 468 curveto -527 465 527 456 529 450 curveto -stroke -newpath 529 450 moveto -534 426 532 401 529 378 curveto -stroke -end grestore - -% 9f5 -gsave 10 dict begin -347 522 27 18 ellipse_path -stroke -gsave 10 dict begin -347 523 moveto (9f5) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f6 -> 9f5 -gsave 10 dict begin -dashed -newpath 290 579 moveto -302 567 319 550 332 537 curveto -stroke -end grestore - -% 9f2 -gsave 10 dict begin -237 522 27 18 ellipse_path -stroke -gsave 10 dict begin -237 523 moveto (9f2) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f6 -> 9f2 -newpath 266 577 moveto -260 566 252 551 246 539 curveto -stroke - -% 9f8 -gsave 10 dict begin -529 522 27 18 ellipse_path -stroke -gsave 10 dict begin -529 523 moveto (9f8) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f9 -> 9f8 -newpath 529 576 moveto -529 565 529 551 529 540 curveto -stroke - -% 9f9 -> 946 -gsave 10 dict begin -dotted -newpath 546 580 moveto -563 565 587 541 584 522 curveto -stroke -newpath 584 522 moveto -579 492 522 479 529 450 curveto -stroke -end grestore - -% 9f4 -gsave 10 dict begin -474 450 27 18 ellipse_path -stroke -gsave 10 dict begin -474 451 moveto (9f4) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f5 -> 9f4 -gsave 10 dict begin -dashed -newpath 368 510 moveto -392 497 430 475 453 462 curveto -stroke -end grestore - -% 95d -gsave 10 dict begin -402 378 27 18 ellipse_path -stroke -gsave 10 dict begin -402 379 moveto (95d) 21 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f5 -> 95d -newpath 365 508 moveto -384 494 409 470 410 450 curveto -stroke -newpath 410 450 moveto -409 435 407 412 405 396 curveto -stroke - -% 9f2 -> 993 -gsave 10 dict begin -dashed -newpath 249 506 moveto -258 494 271 478 280 466 curveto -stroke -end grestore - -% 9f1 -gsave 10 dict begin -220 450 27 18 ellipse_path -stroke -gsave 10 dict begin -220 451 moveto (9f1) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f2 -> 9f1 -newpath 233 504 moveto -230 493 227 479 224 468 curveto -stroke - -% 95e -> 95d -newpath 442 507 moveto -428 492 409 468 410 450 curveto -stroke - -% 95e -> 946 -gsave 10 dict begin -dotted -newpath 476 509 moveto -496 495 524 471 529 450 curveto -stroke -end grestore - -% 9f8 -> 9f4 -newpath 517 506 moveto -508 494 495 478 486 466 curveto -stroke - -% 9f8 -> 946 -gsave 10 dict begin -dotted -newpath 527 504 moveto -526 487 525 464 529 450 curveto -stroke -end grestore - -% 992 -gsave 10 dict begin -237 306 27 18 ellipse_path -stroke -gsave 10 dict begin -237 307 moveto (992) 21 14.00 -0.50 alignedtext -end grestore -end grestore - -% 993 -> 992 -newpath 278 434 moveto -268 422 257 407 253 396 curveto -246 377 241 345 239 324 curveto -stroke - -% 993 -> 946 -gsave 10 dict begin -dotted -newpath 474 306 moveto -474 306 474 234 474 234 curveto -stroke -newpath 302 433 moveto -316 412 341 375 363 360 curveto -392 338 434 340 467 324 curveto -472 321 472 312 474 306 curveto -stroke -end grestore - -% 9ed -gsave 10 dict begin -182 378 27 18 ellipse_path -stroke -gsave 10 dict begin -182 379 moveto (9ed) 20 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f1 -> 9ed -newpath 211 433 moveto -205 422 197 407 191 395 curveto -stroke - -% 9f0 -gsave 10 dict begin -292 378 27 18 ellipse_path -stroke -gsave 10 dict begin -292 379 moveto (9f0) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f1 -> 9f0 -gsave 10 dict begin -dashed -newpath 235 435 moveto -247 423 264 406 277 393 curveto -stroke -end grestore - -% 9f3 -gsave 10 dict begin -474 378 27 18 ellipse_path -stroke -gsave 10 dict begin -474 379 moveto (9f3) 18 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f4 -> 9f3 -newpath 474 432 moveto -474 421 474 407 474 396 curveto -stroke - -% 9f4 -> 946 -gsave 10 dict begin -dotted -newpath 491 436 moveto -508 421 532 397 529 378 curveto -stroke -newpath 529 378 moveto -528 371 525 365 522 360 curveto -522 360 474 306 474 306 curveto -stroke -end grestore - -% 9ed -> 992 -gsave 10 dict begin -dashed -newpath 194 362 moveto -203 350 216 334 225 322 curveto -stroke -end grestore - -% 9ec -gsave 10 dict begin -165 306 27 18 ellipse_path -stroke -gsave 10 dict begin -165 307 moveto (9ec) 19 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9ed -> 9ec -newpath 178 360 moveto -175 349 172 335 169 324 curveto -stroke - -% 9ef -gsave 10 dict begin -419 306 27 18 ellipse_path -stroke -gsave 10 dict begin -419 307 moveto (9ef) 17 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f0 -> 9ef -gsave 10 dict begin -dashed -newpath 313 366 moveto -337 353 375 331 398 318 curveto -stroke -end grestore - -% 95c -gsave 10 dict begin -347 234 27 18 ellipse_path -stroke -gsave 10 dict begin -347 235 moveto (95c) 20 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9f0 -> 95c -newpath 310 364 moveto -329 350 354 326 355 306 curveto -stroke -newpath 355 306 moveto -354 291 352 268 350 252 curveto -stroke - -% 95d -> 95c -newpath 387 363 moveto -373 348 354 324 355 306 curveto -stroke - -% 95d -> 946 -gsave 10 dict begin -dotted -newpath 421 365 moveto -441 351 469 327 474 306 curveto -stroke -end grestore - -% 9f3 -> 9ef -newpath 462 362 moveto -453 350 440 334 431 322 curveto -stroke - -% 9f3 -> 946 -gsave 10 dict begin -dotted -newpath 472 360 moveto -471 343 470 320 474 306 curveto -stroke -end grestore - -% 954 -gsave 10 dict begin -165 162 27 18 ellipse_path -stroke -gsave 10 dict begin -165 163 moveto (954) 21 14.00 -0.50 alignedtext -end grestore -end grestore - -% 992 -> 954 -newpath 220 234 moveto -214 216 194 192 180 177 curveto -stroke -newpath 233 288 moveto -230 272 224 248 220 234 curveto -stroke - -% 992 -> 946 -gsave 10 dict begin -dotted -newpath 220 234 moveto -220 234 213 144 213 144 curveto -213 144 193 90 193 90 curveto -stroke -end grestore - -% 987 -gsave 10 dict begin -165 234 27 18 ellipse_path -stroke -gsave 10 dict begin -165 235 moveto (987) 21 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9ec -> 987 -newpath 165 288 moveto -165 277 165 263 165 252 curveto -stroke - -% 9eb -gsave 10 dict begin -275 234 27 18 ellipse_path -stroke -gsave 10 dict begin -275 235 moveto (9eb) 20 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9ec -> 9eb -gsave 10 dict begin -dashed -newpath 184 293 moveto -204 280 236 260 256 247 curveto -stroke -end grestore - -% 9ee -gsave 10 dict begin -419 234 27 18 ellipse_path -stroke -gsave 10 dict begin -419 235 moveto (9ee) 19 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9ef -> 9ee -newpath 419 288 moveto -419 277 419 263 419 252 curveto -stroke - -% 9ef -> 946 -gsave 10 dict begin -dotted -newpath 474 234 moveto -477 210 461 184 469 162 curveto -stroke -newpath 435 291 moveto -450 276 471 252 474 234 curveto -stroke -end grestore - -% 987 -> 954 -gsave 10 dict begin -dashed -newpath 165 216 moveto -165 205 165 191 165 180 curveto -stroke -end grestore - -% 987 -> 946 -newpath 193 90 moveto -225 56 305 34 347 24 curveto -stroke -newpath 152 218 moveto -136 197 113 162 126 144 curveto -144 120 173 110 193 90 curveto -stroke - -% 9ea -gsave 10 dict begin -410 162 27 18 ellipse_path -stroke -gsave 10 dict begin -410 163 moveto (9ea) 19 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9eb -> 9ea -gsave 10 dict begin -dashed -newpath 296 223 moveto -321 210 363 187 389 174 curveto -stroke -end grestore - -% 955 -gsave 10 dict begin -374 90 27 18 ellipse_path -stroke -gsave 10 dict begin -374 91 moveto (955) 21 14.00 -0.50 alignedtext -end grestore -end grestore - -% 9eb -> 955 -newpath 293 220 moveto -311 206 338 182 347 162 curveto -stroke -newpath 347 162 moveto -353 147 362 124 368 108 curveto -stroke - -% 95c -> 955 -newpath 344 216 moveto -342 199 341 175 347 162 curveto -stroke - -% 95c -> 946 -gsave 10 dict begin -dotted -newpath 368 222 moveto -372 220 376 217 380 216 curveto -407 203 436 195 462 180 curveto -467 176 466 168 469 162 curveto -stroke -newpath 469 162 moveto -476 139 475 113 469 90 curveto -stroke -end grestore - -% 9ee -> 9ea -newpath 417 216 moveto -415 205 414 191 412 180 curveto -stroke - -% 9ee -> 946 -gsave 10 dict begin -dotted -newpath 432 218 moveto -442 206 454 190 462 180 curveto -465 174 466 168 469 162 curveto -stroke -end grestore - -% 954 -> 946 -newpath 169 144 moveto -174 127 182 101 193 90 curveto -stroke - -% 954 -> 946 -gsave 10 dict begin -dotted -end grestore - -% 9ea -> 955 -newpath 401 145 moveto -396 133 388 119 383 107 curveto -stroke - -% 9ea -> 946 -gsave 10 dict begin -dotted -newpath 429 149 moveto -448 133 474 109 469 90 curveto -stroke -newpath 469 90 moveto -462 66 427 44 401 30 curveto -stroke -end grestore - -% 955 -> 946 -newpath 374 72 moveto -374 61 374 47 374 36 curveto -stroke - -% 955 -> 946 -gsave 10 dict begin -dotted -end grestore -endpage -grestore -%%PageTrailer -%%Trailer -%%Pages: 1 -end -restore -%%EOF - -%%EndDocument - @endspecial 448 4422 a Fo(Figure)34 b(1:)49 b(A)32 b(BDD)f -(representing)37 b(a)c(phase)h(constraint)i(for)e(the)f(optimization)j -(of)d(\002x)o(ed-)448 4535 y(polarity)27 b(Reed-Muller)g(forms.)33 -b(The)24 b(label)i(of)f(each)h(node)f(is)g(the)g(unique)i(part)e(of)g -(the)g(node)448 4648 y(address.)31 b(All)21 b(nodes)j(on)f(the)g(same)f -(le)n(v)o(el)h(correspond)i(to)e(the)g(same)f(v)n(ariable,)i(whose)f -(name)448 4761 y(is)f(sho)n(wn)h(at)f(the)g(left)g(of)g(the)h(diagram.) -29 b(Dotted)23 b(lines)g(indicate)h(complement)g(arcs.)k(Dashed)448 -4874 y(lines)d(indicate)g(re)o(gular)g(\223else\224)g(arcs.)p -Black Black 1897 5225 a(25)p Black eop end -%%Page: 26 26 -TeXDict begin 26 25 bop Black Black 448 573 a Fo(to)24 -b(your)h(source)h(\002les.)k(In)24 b(addition,)i(you)f(should)h(link)e -Fh(libcudd.a)19 b Fo(to)24 b(your)h(e)o(x)o(ecutable.)448 -686 y(Some)20 b(platforms)h(require)h(speci\002c)e(compiler)i(and)e -(link)o(er)h(\003ags.)28 b(Refer)20 b(to)g(the)g Fh(Makefile)448 -799 y Fo(in)k(the)g(top)f(le)n(v)o(el)h(directory)i(of)e(the)f(distrib) -n(ution.)448 1040 y Fi(4.2)99 b(Refer)n(ence)27 b(Counts)448 -1214 y Fo(Garbage)d(collection)i(in)d(the)g(CUDD)d(package)25 -b(is)e(based)h(on)f(reference)i(counts.)30 b(Each)22 -b(node)448 1327 y(stores)j(the)f(sum)f(of)g(the)h(e)o(xternal)h -(references)h(and)e(internal)h(references.)31 b(An)23 -b(internal)i(BDD)448 1440 y(or)33 b(ADD)e(node)i(is)g(created)h(by)f(a) -g(call)g(to)f Fn(cuddUniqueInter)r Fo(,)40 b(an)32 b(internal)j(ZDD)c -(node)i(is)448 1553 y(created)c(by)e(a)g(call)g(to)g -Fn(cuddUniqueInterZdd)r Fo(,)33 b(and)28 b(a)e(terminal)j(node)e(is)g -(created)i(by)e(a)g(call)448 1666 y(to)g Fn(cuddUniqueConst)r -Fo(.)40 b(If)27 b(the)f(node)i(returned)g(by)f(these)g(functions)i(is)d -(ne)n(w)-6 b(,)27 b(its)f(reference)448 1779 y(count)32 -b(is)e(zero.)51 b(The)30 b(function)i(that)g(calls)f -Fn(cuddUniqueInter)r Fo(,)36 b Fn(cuddUniqueInterZdd)r -Fo(,)h(or)448 1892 y Fn(cuddUniqueConst)j Fo(is)35 b(responsible)j(for) -d(increasing)i(the)e(reference)i(count)f(of)f(the)g(node.)448 -2005 y(This)24 b(is)f(accomplished)k(by)c(calling)i Fn(Cudd)p -1823 2005 28 4 v 34 w(Ref)13 b Fo(.)589 2118 y(When)22 -b(a)f(function)i(is)e(no)g(longer)i(needed)f(by)g(an)f(application,)j -(the)e(memory)f(used)h(by)f(its)448 2231 y(diagram)32 -b(can)g(be)f(rec)o(ycled)i(by)e(calling)i Fn(Cudd)p 1986 -2231 V 33 w(Recur)o(siveDer)m(ef)47 b Fo(\(BDDs)30 b(and)i(ADDs\))d(or) -448 2344 y Fn(Cudd)p 649 2344 V 34 w(Recur)o(siveDer)m(efZdd)36 -b Fo(\(ZDDs\).)49 b(These)31 b(functions)i(decrease)g(the)e(reference)i -(count)448 2456 y(of)h(the)h(node)g(passed)g(to)f(them.)61 -b(If)34 b(the)g(reference)i(count)g(becomes)f(0,)h(then)f(tw)o(o)f -(things)448 2569 y(happen:)p Black 562 2718 a(1.)p Black -46 w(The)23 b(node)i(is)f(declared)i(\223dead;\224)g(this)e(entails)h -(increasing)i(the)d(counters)i(of)e(the)g(dead)676 2831 -y(nodes.)56 b(\(One)32 b(counter)i(for)f(the)f(subtable)j(to)d(which)h -(the)g(node)g(belongs,)j(and)d(one)676 2944 y(global)f(counter)h(for)f -(the)f(unique)i(table)f(to)f(which)h(the)f(node)i(belongs.\))54 -b(The)30 b(node)676 3057 y(itself)24 b(is)f(not)h(af)n(fected.)p -Black 562 3229 a(2.)p Black 46 w(The)f(function)i(is)f(recursi)n(v)o -(ely)i(called)f(on)e(the)h(tw)o(o)f(children)j(of)d(the)h(node.)448 -3378 y(F)o(or)35 b(instance,)41 b(if)36 b(the)g(diagram)h(of)f(a)f -(function)j(does)f(not)f(share)h(an)o(y)f(nodes)i(with)d(other)448 -3491 y(diagrams,)k(then)c(calling)h Fn(Cudd)p 1513 3491 -V 33 w(Recur)o(siveDer)m(ef)50 b Fo(or)34 b Fn(Cudd)p -2459 3491 V 34 w(Recur)o(siveDer)m(efZdd)40 b Fo(on)34 -b(its)448 3603 y(root)24 b(will)g(cause)g(all)g(the)g(nodes)h(of)e(the) -h(diagram)g(to)g(become)g(dead.)589 3716 y(When)d(the)f(number)g(of)g -(dead)h(nodes)g(reaches)g(a)f(gi)n(v)o(en)g(le)n(v)o(el)g -(\(dynamically)j(determined)448 3829 y(by)33 b(the)f(package\))j -(garbage)e(collection)i(tak)o(es)f(place.)56 b(During)33 -b(garbage)g(collection)i(dead)448 3942 y(nodes)25 b(are)f(returned)h -(to)f(the)g(node)g(free)g(list.)589 4055 y(When)37 b(a)e(ne)n(w)g(node) -i(is)f(created,)k(it)c(is)g(important)h(to)f(increase)i(its)e -(reference)i(count)448 4168 y(before)25 b(one)f(of)g(the)f(tw)o(o)h -(follo)n(wing)h(e)n(v)o(ents)f(occurs:)p Black 562 4317 -a(1.)p Black 46 w(A)19 b(call)j(to)e Fn(cuddUniqueInter)r -Fo(,)26 b(to)21 b Fn(cuddUniqueInterZdd)r Fo(,)26 b(to)21 -b Fn(cuddUniqueConst)r Fo(,)j(or)676 4430 y(to)f(a)g(function)j(that)e -(may)f(e)n(v)o(entually)j(cause)f(a)e(call)h(to)f(them.)p -Black 562 4602 a(2.)p Black 46 w(A)28 b(call)i(to)f Fn(Cudd)p -1230 4602 V 34 w(Recur)o(siveDer)m(ef)13 b Fo(,)33 b(to)c -Fn(Cudd)p 2186 4602 V 34 w(Recur)o(siveDer)m(efZdd)r -Fo(,)34 b(or)29 b(to)g(a)g(func-)676 4715 y(tion)24 b(that)g(may)f(e)n -(v)o(entually)j(cause)f(a)e(call)h(to)f(them.)448 4863 -y(In)31 b(practice,)j(it)d(is)f(recommended)j(to)e(increase)i(the)e -(reference)i(count)f(as)f(soon)g(as)g(the)g(re-)448 4976 -y(turned)25 b(pointer)h(has)d(been)i(tested)g(for)e(not)h(being)h -(NULL.)p Black 1897 5225 a(26)p Black eop end -%%Page: 27 27 -TeXDict begin 27 26 bop Black Black 448 573 a Fp(4.2.1)92 -b(NULL)21 b(Retur)o(n)h(V)-8 b(alues)448 747 y Fo(The)25 -b(interf)o(ace)i(to)e(the)g(memory)g(management)i(functions)g(\(e.g.,)e -(malloc\))h(used)g(by)f(CUDD)448 860 y(intercepts)k(NULL)c(return)i(v)n -(alues)h(and)f(calls)g(a)f(handler)-5 b(.)40 b(The)26 -b(def)o(ault)i(handler)g(e)o(xits)f(with)448 973 y(an)i(error)h -(message.)47 b(If)29 b(the)g(application)k(does)d(not)f(install)i -(another)g(handler)l(,)h(therefore,)h(a)448 1086 y(NULL)21 -b(return)k(v)n(alue)g(from)e(an)h(e)o(xported)h(function)h(of)d(CUDD)e -(signals)26 b(an)d(internal)j(error)-5 b(.)589 1199 y(If)23 -b(the)f(aplication,)j(ho)n(we)n(v)o(er)l(,)e(installs)i(another)f -(handler)g(that)f(lets)g(e)o(x)o(ecution)h(continue,)448 -1312 y(a)i(NULL)f(pointer)j(returned)g(by)f(an)g(e)o(xported)h -(function)h(typically)g(indicates)g(that)e(the)g(pro-)448 -1425 y(cess)32 b(has)g(run)g(out)g(of)f(memory)-6 b(.)53 -b Fn(Cudd)p 1760 1425 28 4 v 33 w(ReadErr)l(orCode)34 -b Fo(can)d(be)h(used)g(to)f(ascertain)j(the)448 1537 -y(nature)25 b(of)f(the)f(problem.)589 1650 y(An)37 b(application)j -(that)d(tests)h(for)f(the)h(result)g(being)g(NULL)c(can)k(try)f(some)g -(remedial)448 1763 y(action,)25 b(if)e(it)g(runs)h(out)g(of)g(memory)-6 -b(.)28 b(F)o(or)23 b(instance,)i(it)e(may)h(free)g(some)f(memory)h -(that)g(is)f(not)448 1876 y(strictly)29 b(necessary)-6 -b(,)31 b(or)c(try)g(a)g(slo)n(wer)g(algorithm)i(that)f(tak)o(es)g(less) -g(space.)40 b(As)27 b(an)g(e)o(xample,)448 1989 y(CUDD)e(o)o(v)o -(errides)k(the)f(def)o(ault)h(handler)g(when)f(trying)g(to)g(enlar)n -(ge)h(the)f(cache)g(or)f(increase)448 2102 y(the)i(number)g(of)f(slots) -h(of)f(the)h(unique)h(table.)43 b(If)28 b(the)h(allocation)h(f)o(ails,) -g(the)f(package)h(prints)448 2215 y(out)24 b(a)f(message)i(and)f -(continues)i(without)f(resizing)g(the)f(cache.)448 2461 -y Fp(4.2.2)92 b Fa(Cudd)p 928 2461 V 33 w(Recursiv)o(eDeref)35 -b Fp(vs.)23 b Fa(Cudd)p 1901 2461 V 33 w(Deref)448 2635 -y Fo(It)36 b(is)f(often)i(the)f(case)g(that)h(a)e(recursi)n(v)o(e)i -(procedure)i(has)d(to)g(protect)h(the)f(result)h(it)e(is)h(go-)448 -2748 y(ing)j(to)g(return,)k(while)c(it)f(disposes)j(of)d(intermediate)j -(results.)75 b(\(See)38 b(the)h(pre)n(vious)i(dis-)448 -2861 y(cussion)i(on)d(when)h(to)f(increase)j(reference)g(counts.\))81 -b(Once)41 b(the)g(intermediate)i(results)448 2974 y(ha)n(v)o(e)37 -b(been)f(properly)i(disposed)f(of,)i(the)c(\002nal)h(result)h(must)e -(be)h(returned)h(to)f(its)f(pristine)448 3087 y(state,)h(in)d(which)g -(the)g(root)h(node)g(may)e(ha)n(v)o(e)i(a)e(reference)k(count)e(of)e -(0.)57 b(One)32 b(cannot)j(use)448 3200 y Fn(Cudd)p 649 -3200 V 34 w(Recur)o(siveDer)m(ef)49 b Fo(\(or)33 b Fn(Cudd)p -1624 3200 V 34 w(Recur)o(siveDer)m(efZdd)r Fo(\))j(for)d(this)h -(purpose,)j(because)e(it)448 3313 y(may)22 b(erroneously)j(mak)o(e)d -(some)g(nodes)h(dead.)29 b(Therefore,)24 b(the)e(package)i(pro)o(vides) -g(a)d(dif)n(fer)n(-)448 3425 y(ent)k(function:)35 b Fn(Cudd)p -1144 3425 V 33 w(Der)m(ef)13 b Fo(.)33 b(This)25 b(function)i(is)d(not) -i(recursi)n(v)o(e,)g(and)g(does)f(not)h(change)g(the)448 -3538 y(dead)g(node)f(counts.)34 b(Its)25 b(use)g(is)f(almost)h(e)o -(xclusi)n(v)o(ely)i(the)e(one)g(just)g(described:)34 -b(Decreasing)448 3651 y(the)26 b(reference)h(count)g(of)e(the)g(root)h -(of)f(the)h(\002nal)f(result)h(before)h(returning)h(from)d(a)g(recursi) -n(v)o(e)448 3764 y(procedure.)448 4010 y Fp(4.2.3)92 -b(When)22 b(Incr)n(easing)j(the)e(Refer)n(ence)i(Count)d(is)h -(Unnecessary)448 4184 y Fo(When)29 b(a)f(cop)o(y)h(of)f(a)g -(prede\002ned)i(constant)h(or)d(of)g(a)g(simple)h(BDD)d(v)n(ariable)k -(is)e(needed)i(for)448 4297 y(comparison)g(purposes,)g(then)f(calling)g -Fn(Cudd)p 1931 4297 V 33 w(Ref)40 b Fo(is)27 b(not)h(necessary)-6 -b(,)31 b(because)e(these)f(sim-)448 4410 y(ple)j(functions)i(are)d -(guaranteed)k(to)c(ha)n(v)o(e)h(reference)i(counts)f(greater)g(than)f -(0)f(at)g(all)g(times.)448 4523 y(If)35 b(no)g(call)g(to)f -Fn(Cudd)p 1138 4523 V 34 w(Ref)47 b Fo(is)35 b(made,)i(then)f(no)f -(attempt)g(to)g(free)g(the)g(diagram)h(by)f(calling)448 -4636 y Fn(Cudd)p 649 4636 V 34 w(Recur)o(siveDer)m(ef)k -Fo(or)24 b Fn(Cudd)p 1575 4636 V 33 w(Recur)o(siveDer)m(efZdd)29 -b Fo(should)c(be)f(made.)p Black 1897 5225 a(27)p Black -eop end -%%Page: 28 28 -TeXDict begin 28 27 bop Black Black 448 573 a Fp(4.2.4)92 -b(Saturating)24 b(Incr)n(ements)g(and)f(Decr)n(ements)448 -747 y Fo(On)30 b(32-bit)i(machines,)i(the)d(CUDD)d(package)33 -b(stores)f(the)f(reference)i(counts)f(in)f(unsigned)448 -860 y(short)38 b(int')-5 b(s.)68 b(F)o(or)36 b(lar)n(ge)i(diagrams,)j -(it)36 b(is)g(possible)j(for)e(some)f(reference)j(counts)f(to)e(e)o(x-) -448 973 y(ceed)27 b(the)g(capacity)h(of)f(an)f(unsigned)j(short)e(int.) -38 b(Therefore,)28 b(increments)g(and)f(decrements)448 -1086 y(of)34 b(reference)j(counts)f(are)e Fn(satur)o(ating)p -Fo(.)64 b(This)34 b(means)g(that)h(once)g(a)f(reference)j(count)e(has) -448 1199 y(reached)24 b(the)e(maximum)f(possible)j(v)n(alue,)f(it)e(is) -h(no)g(longer)h(changed)h(by)d(calls)i(to)e Fn(Cudd)p -3264 1199 28 4 v 34 w(Ref)p Fo(,)448 1312 y Fn(Cudd)p -649 1312 V 34 w(Recur)o(siveDer)m(ef)13 b Fo(,)46 b Fn(Cudd)p -1519 1312 V 34 w(Recur)o(siveDer)m(efZdd)r Fo(,)h(or)40 -b Fn(Cudd)p 2635 1312 V 34 w(Der)m(ef)13 b Fo(.)77 b(As)39 -b(a)h(conse-)448 1425 y(quence,)30 b(some)d(nodes)i(that)e(ha)n(v)o(e)h -(no)f(references)j(may)d(not)h(be)f(declared)i(dead.)41 -b(This)27 b(may)448 1537 y(result)j(in)e(a)g(small)h(w)o(aste)f(of)h -(memory)-6 b(,)29 b(which)g(is)f(normally)i(more)f(than)g(of)n(fset)g -(by)g(the)f(re-)448 1650 y(duction)e(in)d(size)h(of)g(the)g(node)g -(structure.)589 1763 y(When)j(using)h(64-bit)f(pointers,)i(there)f(is)e -(normally)i(no)e(memory)h(adv)n(antage)i(from)d(us-)448 -1876 y(ing)e(short)h(int')-5 b(s)24 b(instead)h(of)e(int')-5 -b(s)25 b(in)e(a)g(DdNode.)29 b(Therefore,)c(increments)g(and)f -(decrements)448 1989 y(are)31 b(not)h(saturating)h(in)e(that)h(case.)51 -b(What)31 b(option)i(is)e(in)f(ef)n(fect)i(depends)h(on)e(tw)o(o)g -(macros,)448 2102 y(SIZEOF)p 763 2102 V 31 w(V)l(OID)p -1018 2102 V 32 w(P)f(and)h(SIZEOF)p 1602 2102 V 30 w(INT,)e(de\002ned)j -(in)e(the)h(e)o(xternal)h(header)g(\002le)e(\()p Fn(cudd.h)p -Fo(\).)448 2215 y(The)g(increments)i(and)e(decrements)i(of)e(the)g -(reference)i(counts)f(are)f(performed)i(using)f(tw)o(o)448 -2328 y(macros:)d Fn(cuddSatInc)21 b Fo(and)d Fn(cuddSatDec)p -Fo(,)k(whose)c(de\002nitions)i(depend)g(on)e(SIZEOF)p -3170 2328 V 31 w(V)l(OID)p 3425 2328 V 33 w(P)448 2441 -y(and)24 b(SIZEOF)p 917 2441 V 31 w(INT.)448 2690 y Fi(4.3)99 -b(Complement)26 b(Ar)n(cs)448 2864 y Fo(If)j(ADDs)f(are)h(restricted)j -(to)d(use)g(only)h(the)g(constants)i(0)c(and)i(1,)g(the)o(y)f(beha)n(v) -o(e)i(lik)o(e)f(BDDs)448 2977 y(without)d(complement)h(arcs.)36 -b(It)25 b(is)h(normally)h(easier)g(to)f(write)g(code)g(that)h -(manipulates)h(0-1)448 3090 y(ADDs,)33 b(than)h(to)e(write)h(code)g -(for)g(BDDs.)54 b(Ho)n(we)n(v)o(er)l(,)34 b(complementation)i(is)d(tri) -n(vial)g(with)448 3203 y(complement)c(arcs,)g(and)f(is)f(not)h(tri)n -(vial)g(without.)41 b(As)27 b(a)g(consequence,)k(with)d(complement)448 -3316 y(arcs)h(it)g(is)f(possible)j(to)d(check)i(for)f(more)f(terminal)i -(cases)g(and)f(it)f(is)g(possible)j(to)d(apply)i(De)448 -3429 y(Mor)n(gan')-5 b(s)25 b(la)o(ws)d(to)g(reduce)j(problems)f(that)f -(are)g(essentially)j(identical)f(to)d(a)h(standard)i(form.)448 -3542 y(This)f(in)f(turn)h(increases)i(the)e(utilization)i(of)e(the)g -(cache.)589 3655 y(The)38 b(complement)h(attrib)n(ute)h(is)d(stored)i -(in)e(the)h(least)h(signi\002cant)g(bit)f(of)f(the)h(\223else\224)448 -3768 y(pointer)25 b(of)f(each)g(node.)29 b(An)23 b(e)o(xternal)i -(pointer)g(to)e(a)g(function)j(can)e(also)g(be)f(complemented.)448 -3880 y(The)d(\223then\224)j(pointer)f(to)e(a)h(node,)g(on)g(the)g -(other)g(hand,)h(is)f(al)o(w)o(ays)g Fn(r)m(e)l(gular)p -Fo(.)30 b(It)20 b(is)h(a)f(mistak)o(e)h(to)448 3993 y(use)f(a)f -(complement)i(pointer)g(as)f(it)f(is)g(to)g(address)j(memory)-6 -b(.)27 b(Instead,)22 b(it)d(is)g(al)o(w)o(ays)i(necessary)448 -4106 y(to)28 b(obtain)i(a)e(re)o(gular)h(v)o(ersion)h(of)e(it.)42 -b(This)28 b(is)g(normally)h(done)g(by)g(calling)g Fn(Cudd)p -3094 4106 V 34 w(Re)l(gular)r Fo(.)448 4219 y(It)f(is)f(also)h(a)f -(mistak)o(e)i(to)e(call)h Fn(cuddUniqueInter)34 b Fo(with)27 -b(a)g(complemented)j(\223then\224)f(child)f(as)448 4332 -y(ar)n(gument.)i(The)22 b(calling)i(procedure)h(must)d(apply)h(De)e -(Mor)n(gan')-5 b(s)24 b(la)o(ws)d(by)h(complementing)448 -4445 y(both)32 b(pointers)i(passed)f(to)e Fn(cuddUniqueInter)38 -b Fo(and)31 b(then)h(taking)h(the)f(complement)h(of)e(the)448 -4558 y(result.)p Black 1897 5225 a(28)p Black eop end -%%Page: 29 29 -TeXDict begin 29 28 bop Black Black 448 573 a Fi(4.4)99 -b(The)26 b(Cache)448 747 y Fo(Each)38 b(entry)g(of)g(the)f(cache)i -(consists)g(of)f(\002)n(v)o(e)e(\002elds:)57 b(The)37 -b(operator)l(,)43 b(three)c(pointers)g(to)448 860 y(operands)d(and)e(a) -f(pointer)i(to)e(the)h(result.)60 b(The)33 b(operator)i(and)f(the)g -(three)g(pointers)i(to)d(the)448 973 y(operands)26 b(are)e(combined)h -(to)f(form)f(three)i(w)o(ords.)k(The)23 b(combination)j(relies)f(on)e -(tw)o(o)h(f)o(acts:)p Black 585 1155 a Fm(\017)p Black -46 w Fo(Most)i(operations)k(ha)n(v)o(e)d(one)h(or)e(tw)o(o)h(operands.) -40 b(A)26 b(fe)n(w)g(bits)h(are)g(suf)n(\002cient)h(to)f(dis-)676 -1268 y(criminate)e(all)e(three-operands)28 b(operations.)p -Black 585 1454 a Fm(\017)p Black 46 w Fo(All)h(nodes)h(are)g(aligned)h -(to)f(16-byte)h(boundaries.)50 b(\(32-byte)32 b(boundaries)h(if)c -(64-bit)676 1567 y(pointers)j(are)f(used.\))51 b(Hence,)33 -b(there)e(are)g(a)g(fe)n(w)e(bits)j(a)n(v)n(ailable)h(to)d(distinguish) -k(the)676 1679 y(three-operand)27 b(operations)g(from)c(te)g(others)i -(and)f(to)g(assign)h(unique)g(codes)g(to)e(them.)589 -1862 y(The)30 b(cache)h(does)f(not)g(contrib)n(ute)j(to)d(the)g -(reference)i(counts)f(of)f(the)g(nodes.)48 b(The)30 b(f)o(act)448 -1975 y(that)h(the)g(cache)g(contains)h(a)e(pointer)i(to)e(a)g(node)h -(does)g(not)f(imply)h(that)g(the)f(node)h(is)f(ali)n(v)o(e.)448 -2088 y(Instead,)k(when)d(garbage)h(collection)h(tak)o(es)e(place,)i -(all)e(entries)h(of)e(the)h(cache)h(pointing)g(to)448 -2201 y(dead)25 b(nodes)f(are)g(cleared.)589 2313 y(The)f(cache)i(is)e -(also)h(cleared)h(\(of)f(all)f(entries\))j(when)d(dynamic)i(reordering) -h(tak)o(es)f(place.)448 2426 y(In)f(both)g(cases,)g(the)g(entries)h -(remo)o(v)o(ed)f(from)g(the)g(cache)g(are)g(about)h(to)e(become)i(in)l -(v)n(alid.)589 2539 y(All)30 b(operands)j(and)e(results)i(in)d(a)g -(cache)i(entry)g(must)e(be)h(pointers)h(to)f(DdNodes.)50 -b(If)31 b(a)448 2652 y(function)f(produces)f(more)f(than)g(one)f -(result,)j(or)d(uses)h(more)f(than)h(three)g(ar)n(guments,)i(there)448 -2765 y(are)24 b(currently)i(tw)o(o)d(solutions:)p Black -585 2947 a Fm(\017)p Black 46 w Fo(Build)g(a)g(separate,)j(local,)e -(cache.)30 b(\(Using,)24 b(for)f(instance,)j(the)e Fn(st)h -Fo(library.\))p Black 585 3133 a Fm(\017)p Black 46 w -Fo(Combine)33 b(multiple)h(results,)i(or)c(multiple)i(operands,)j(into) -c(a)g(single)h(diagram,)h(by)676 3246 y(b)n(uilding)26 -b(a)d(\223multiple)o(xing)j(structure\224)g(with)e(reserv)o(ed)h(v)n -(ariables.)448 3428 y(Support)35 b(of)f(the)h(former)f(solution)j(is)c -(under)j(de)n(v)o(elopment.)62 b(\(See)34 b Fh(cuddLCache.c)p -Fo(..\))448 3541 y(Support)25 b(for)f(the)f(latter)i(solution)h(may)d -(be)h(pro)o(vided)h(in)f(future)g(v)o(ersions)i(of)d(the)h(package.)589 -3654 y(There)e(are)g(three)h(sets)g(of)e(interf)o(ace)j(functions)h(to) -c(the)i(cache.)29 b(The)21 b(\002rst)h(set)g(is)f(for)h(func-)448 -3767 y(tions)31 b(with)f(three)i(operands:)44 b Fn(cuddCac)o(heInsert) -36 b Fo(and)31 b Fn(cuddCac)o(heLookup)p Fo(.)52 b(The)30 -b(second)448 3880 y(set)21 b(is)g(for)g(functions)j(with)c(tw)o(o)h -(operands:)30 b Fn(cuddCac)o(heInsert2)25 b Fo(and)d -Fn(cuddCac)o(heLookup2)p Fo(.)448 3993 y(The)33 b(second)i(set)f(is)f -(for)h(functions)i(with)d(one)h(operand:)51 b Fn(cuddCac)o(heInsert1)38 -b Fo(and)c Fn(cudd-)448 4106 y(Cac)o(heLookup1)p Fo(.)42 -b(The)26 b(second)j(set)e(is)g(slightly)i(f)o(aster)f(than)g(the)f -(\002rst,)h(and)f(the)g(third)h(set)f(is)448 4219 y(slightly)f(f)o -(aster)f(than)f(the)g(second.)448 4463 y Fp(4.4.1)92 -b(Cache)23 b(Sizing)448 4638 y Fo(The)e(size)i(of)e(the)h(cache)h(can)f -(increase)h(during)h(the)d(e)o(x)o(ecution)j(of)e(an)f(application.)31 -b(\(There)22 b(is)448 4751 y(currently)27 b(no)d(w)o(ay)g(to)g -(decrease)i(the)e(size)h(of)f(the)g(cache,)i(though)f(it)f(w)o(ould)h -(not)f(be)g(dif)n(\002cult)448 4863 y(to)33 b(do)g(it.\))57 -b(When)33 b(a)g(cache)h(miss)f(occurs,)j(the)e(package)g(uses)g(the)f -(follo)n(wing)i(criteria)f(to)448 4976 y(decide)25 b(whether)g(to)e -(resize)i(the)f(cache:)p Black 1897 5225 a(29)p Black -eop end -%%Page: 30 30 -TeXDict begin 30 29 bop Black Black Black 562 573 a Fo(1.)p -Black 46 w(If)28 b(the)h(cache)g(already)i(e)o(xceeds)f(the)f(limit)f -(gi)n(v)o(en)h(by)g(the)g Fh(maxCache)24 b Fo(\002eld)29 -b(of)f(the)676 686 y(manager)l(,)i(no)f(resizing)h(tak)o(es)f(place.)44 -b(The)28 b(limit)g(is)g(the)h(minimum)f(of)g(tw)o(o)g(v)n(alues:)676 -799 y(a)k(v)n(alue)i(set)f(at)f(initialization)37 b(time)c(and)g -(possibly)i(modi\002ed)e(by)g(the)g(application,)676 -912 y(which)g(constitutes)i(the)e(hard)h(limit)e(be)o(yond)i(which)f -(the)g(cache)h(will)e(ne)n(v)o(er)h(gro)n(w;)676 1024 -y(and)23 b(a)f(number)i(that)f(depends)i(on)e(the)g(current)h(total)g -(number)g(of)e(slots)i(in)f(the)g(unique)676 1137 y(table.)p -Black 562 1325 a(2.)p Black 46 w(If)f(the)h(cache)h(is)f(not)g(too)g -(lar)n(ge)h(already)-6 b(,)25 b(resizing)g(is)d(decided)j(based)f(on)f -(the)g(hit)g(rate.)676 1438 y(The)28 b(polic)o(y)i(adopted)h(by)e(the)h -(CUDD)c(package)31 b(is)e(\223re)n(w)o(ard-based.)-6 -b(\224)48 b(If)29 b(the)g(cache)676 1551 y(hit)23 b(rate)h(is)g(high,)g -(then)g(it)f(is)h(w)o(orthwhile)h(to)e(increase)j(the)d(size)h(of)g -(the)g(cache.)448 1738 y(When)i(resizing)h(tak)o(es)f(place,)g(the)g -(statistical)h(counters)h(used)e(to)f(compute)h(the)f(hit)h(rate)f(are) -448 1851 y(reinitialized)g(so)c(as)g(to)g(pre)n(v)o(ent)h(immediate)g -(resizing.)30 b(The)21 b(number)h(of)f(entries)i(is)d(doubled.)589 -1964 y(The)k(rationale)i(for)e(the)g(\223re)n(w)o(ard-based\224)j -(polic)o(y)e(is)e(as)h(follo)n(ws.)30 b(In)23 b(man)o(y)h(BDD/ADD)448 -2077 y(applications)j(the)c(hit)g(rate)g(is)g(not)g(v)o(ery)g(sensiti)n -(v)o(e)i(to)d(the)h(size)h(of)e(the)i(cache:)30 b(It)22 -b(is)h(primarily)448 2190 y(a)i(function)j(of)e(the)g(problem)g -(instance)i(at)d(hand.)36 b(If)25 b(a)h(lar)n(ge)g(hit)g(rate)g(is)g -(observ)o(ed,)h(chances)448 2303 y(are)c(that)g(by)g(using)g(a)f(lar)n -(ge)i(cache,)g(the)e(results)i(of)f(lar)n(ge)h(problems)g(\(those)f -(that)h(w)o(ould)f(tak)o(e)448 2416 y(longer)31 b(to)f(solv)o(e\))g -(will)g(survi)n(v)o(e)g(in)g(the)g(cache)h(without)f(being)h(o)o(v)o -(erwritten)g(long)f(enough)448 2529 y(to)i(cause)i(a)d(v)n(aluable)k -(cache)e(hit.)55 b(Notice)32 b(that)h(when)f(a)g(lar)n(ge)i(problem)f -(is)f(solv)o(ed)h(more)448 2642 y(than)c(once,)g(so)f(are)g(its)g -(recursi)n(v)o(ely)i(generated)g(subproblems.)44 b(If)28 -b(the)g(hit)f(rate)i(is)e(lo)n(w)-6 b(,)28 b(the)448 -2755 y(probability)f(of)c(lar)n(ge)i(problems)g(being)g(solv)o(ed)g -(more)e(than)i(once)f(is)f(lo)n(w)-6 b(.)589 2868 y(The)20 -b(other)h(observ)n(ation)j(about)d(the)f(cache)i(sizing)f(polic)o(y)g -(is)f(that)h(there)g(is)f(little)h(point)g(in)448 2980 -y(k)o(eeping)k(a)d(cache)h(which)g(is)f(much)h(lar)n(ger)h(than)f(the)g -(unique)h(table.)29 b(Ev)o(ery)23 b(time)f(the)h(unique)448 -3093 y(table)29 b(\223\002lls)g(up,)-6 b(\224)29 b(garbage)g -(collection)i(is)d(in)l(v)n(ok)o(ed)j(and)e(the)f(cache)h(is)f(cleared) -i(of)e(all)g(dead)448 3206 y(entries.)h(A)19 b(cache)i(that)g(is)f -(much)g(lar)n(ger)i(than)f(the)f(unique)i(table)f(is)f(therefore)i -(less)f(than)f(fully)448 3319 y(utilized.)448 3565 y -Fp(4.4.2)92 b(Local)24 b(Caches)448 3739 y Fo(Sometimes)k(it)f(may)f -(be)i(necessary)h(or)e(con)l(v)o(enient)j(to)d(use)h(a)f(local)h -(cache.)40 b(A)26 b(local)i(cache)448 3852 y(can)f(be)g(lossless)i -(\(no)e(results)h(are)e(e)n(v)o(er)h(o)o(v)o(erwritten\),)i(or)e(it)f -(may)g(store)i(objects)g(for)f(which)448 3965 y(canonical)36 -b(representations)h(are)c(not)g(a)n(v)n(ailable.)59 b(One)33 -b(important)h(f)o(act)g(to)f(k)o(eep)g(in)g(mind)448 -4078 y(when)d(using)g(a)f(local)h(cache)h(is)e(that)h(local)g(caches)h -(are)e(not)h(cleared)h(during)g(garbage)g(col-)448 4191 -y(lection)e(or)e(before)i(reordering.)42 b(Therefore,)29 -b(it)e(is)g(necessary)j(to)d(increment)i(the)e(reference)448 -4304 y(count)22 b(of)d(all)i(nodes)g(pointed)h(by)e(a)g(local)h(cache.) -28 b(\(Unless)21 b(their)g(reference)h(counts)g(are)e(guar)n(-)448 -4417 y(anteed)25 b(positi)n(v)o(e)h(in)d(some)h(other)h(w)o(ay)-6 -b(.)29 b(One)23 b(such)i(w)o(ay)e(is)h(by)f(including)k(all)d(partial)h -(results)448 4530 y(in)i(the)g(global)i(result.\))40 -b(Before)27 b(disposing)j(of)d(the)g(local)h(cache,)g(all)f(elements)i -(stored)f(in)f(it)448 4643 y(must)20 b(be)g(passed)h(to)e -Fn(Cudd)p 1300 4643 28 4 v 34 w(Recur)o(siveDer)m(ef)13 -b Fo(.)30 b(As)19 b(consequence)k(of)d(the)g(f)o(act)g(that)g(all)g -(results)448 4756 y(in)i(a)g(local)h(cache)g(are)g(referenced,)i(it)d -(is)g(generally)i(con)l(v)o(enient)h(to)e(store)g(in)f(the)g(local)h -(cache)448 4868 y(also)h(the)e(result)i(of)f(tri)n(vial)g(problems,)h -(which)f(are)g(not)g(usually)h(stored)g(in)f(the)f(global)i(cache.)p -Black 1897 5225 a(30)p Black eop end -%%Page: 31 31 -TeXDict begin 31 30 bop Black Black 448 573 a Fo(Otherwise,)35 -b(after)d(a)g(recursi)n(v)o(e)h(call,)i(it)c(is)h(dif)n(\002cult)g(to)g -(tell)h(whether)f(the)h(result)g(is)e(in)h(the)448 686 -y(cache,)25 b(and)f(therefore)h(referenced,)h(or)e(not)g(in)f(the)h -(cache,)g(and)g(therefore)i(not)e(referenced.)589 799 -y(An)19 b(alternati)n(v)o(e)i(approach)g(to)e(referencing)j(the)d -(results)i(in)e(the)g(local)h(caches)g(is)f(to)g(install)448 -912 y(hook)25 b(functions)h(\(see)e(Section)g(3.16\))h(to)e(be)h(e)o(x) -o(ecuted)h(before)g(garbage)g(collection.)448 1158 y -Fi(4.5)99 b(The)26 b(Unique)g(T)-9 b(able)448 1333 y -Fo(A)29 b(recursi)n(v)o(e)j(procedure)h(typically)f(splits)g(the)e -(operands)j(by)d(e)o(xpanding)j(with)d(respect)h(to)448 -1445 y(the)d(topmost)h(v)n(ariable.)43 b(T)-7 b(opmost)28 -b(in)g(this)g(conte)o(xt)h(refers)g(to)e(the)h(v)n(ariable)i(that)e(is) -g(closest)448 1558 y(to)i(the)f(roots)i(in)e(the)h(current)h(v)n -(ariable)g(order)-5 b(.)47 b(The)29 b(nodes,)j(on)d(the)h(other)g -(hand,)i(hold)e(the)448 1671 y(inde)o(x,)c(which)f(is)g(in)l(v)n -(ariant)i(with)e(reordering.)36 b(Therefore,)26 b(when)f(splitting,)j -(one)d(must)g(use)448 1784 y(the)j(permutation)i(array)e(maintained)i -(by)d(the)h(package)i(to)d(get)h(the)f(right)i(le)n(v)o(el.)40 -b(Access)28 b(to)448 1897 y(the)22 b(permutation)i(array)e(is)f(pro)o -(vided)i(by)f(the)f(macro)h Fn(cuddI)27 b Fo(for)21 b(BDDs)f(and)i -(ADDs,)d(and)j(by)448 2010 y(the)i(macro)g Fn(cuddIZ)29 -b Fo(for)24 b(ZDDs.)589 2123 y(The)i(unique)i(table)f(consists)h(of)e -(as)g(man)o(y)g(hash)h(tables)h(as)e(there)h(are)f(v)n(ariables)i(in)e -(use.)448 2236 y(These)e(has)f(tables)h(are)g(called)g -Fn(unique)h(subtables)p Fo(.)31 b(The)23 b(sizes)g(of)g(the)h(unique)h -(subtables)g(are)448 2349 y(determined)h(by)e(tw)o(o)f(criteria:)p -Black 562 2524 a(1.)p Black 46 w(The)g(collision)j(lists)e(should)h(be) -f(short)g(to)g(k)o(eep)g(access)h(time)e(do)n(wn.)p Black -562 2707 a(2.)p Black 46 w(There)18 b(should)i(be)e(enough)i(room)e -(for)g(dead)h(nodes,)h(to)e(pre)n(v)o(ent)h(too)g(frequent)h(garbage) -676 2819 y(collections.)448 2995 y(While)30 b(the)g(\002rst)g -(criterion)i(is)d(f)o(airly)i(straightforw)o(ard)j(to)c(implement,)i -(the)e(second)h(lea)n(v)o(es)448 3108 y(more)22 b(room)g(to)f(creati)n -(vity)-6 b(.)31 b(The)21 b(CUDD)e(package)24 b(tries)f(to)e(\002gure)h -(out)g(whether)h(more)e(dead)448 3220 y(node)j(should)h(be)e(allo)n -(wed)g(to)g(increase)i(performance.)31 b(\(See)23 b(also)h(Section)f -(3.4.\))29 b(There)23 b(are)448 3333 y(tw)o(o)k(reasons)h(for)f(not)g -(doing)h(garbage)g(collection)h(too)e(often.)39 b(The)26 -b(ob)o(vious)j(one)e(is)f(that)i(it)448 3446 y(is)21 -b(e)o(xpensi)n(v)o(e.)30 b(The)21 b(second)i(is)e(that)h(dead)g(nodes)g -(may)f(be)g(reclaimed,)j(if)d(the)o(y)g(are)h(the)f(result)448 -3559 y(of)k(a)g(successful)j(cache)f(lookup.)35 b(Hence)26 -b(dead)g(nodes)g(may)f(pro)o(vide)i(a)e(substantial)j(speed-)448 -3672 y(up)35 b(if)f(the)o(y)g(are)h(k)o(ept)g(around)g(long)h(enough.) -62 b(The)34 b(usefulness)j(of)d(k)o(eeping)i(man)o(y)e(dead)448 -3785 y(nodes)g(around)h(v)n(aries)f(from)e(application)k(to)d -(application,)38 b(and)33 b(from)g(problem)h(instance)448 -3898 y(to)d(problem)g(instance.)51 b(As)30 b(in)g(the)h(sizing)g(of)f -(the)h(cache,)i(the)e(CUDD)d(package)k(adopts)g(a)448 -4011 y(\223re)n(w)o(ard-based\224)k(polic)o(y)e(to)e(decide)i(ho)n(w)e -(much)h(room)f(should)i(be)f(used)g(for)g(the)g(unique)448 -4124 y(table.)62 b(If)35 b(the)f(number)h(of)g(dead)g(nodes)h -(reclaimed)g(is)e(lar)n(ge)h(compared)h(to)f(the)f(number)448 -4237 y(of)d(nodes)h(directly)g(requested)h(from)e(the)g(memory)f -(manager)l(,)k(then)d(the)g(CUDD)d(package)448 4350 y(assumes)34 -b(that)g(it)e(will)h(be)f(bene\002cial)j(to)e(allo)n(w)f(more)h(room)g -(for)g(the)g(subtables,)k(thereby)448 4462 y(reducing)31 -b(the)e(frequenc)o(y)i(of)e(garbage)h(collection.)47 -b(The)28 b(package)j(does)e(so)g(by)g(switching)448 4575 -y(between)c(tw)o(o)e(modes)h(of)g(operation:)p Black -562 4751 a(1.)p Black 46 w(F)o(ast)d(gro)n(wth:)30 b(In)22 -b(this)h(mode,)f(the)h(ratio)g(of)g(dead)g(nodes)g(to)g(total)g(nodes)h -(required)g(for)676 4863 y(garbage)k(collection)h(is)e(higher)h(than)g -(in)f(the)g(slo)n(w)f(gro)n(wth)h(mode)g(to)g(f)o(a)n(v)n(or)h -(resizing)676 4976 y(of)23 b(the)h(subtables.)p Black -1897 5225 a(31)p Black eop end -%%Page: 32 32 -TeXDict begin 32 31 bop Black Black Black 562 573 a Fo(2.)p -Black 46 w(Slo)n(w)28 b(gro)n(wth:)42 b(In)29 b(this)h(mode)g(k)o -(eeping)h(man)o(y)f(dead)g(nodes)h(around)g(is)f(not)f(as)h(im-)676 -686 y(portant)25 b(as)e(k)o(eeping)j(memory)e(requirements)i(lo)n(w)-6 -b(.)448 873 y(Switching)25 b(from)e(one)h(mode)g(to)f(the)h(other)h(is) -e(based)i(on)e(the)h(follo)n(wing)h(criteria:)p Black -562 1061 a(1.)p Black 46 w(If)e(the)h(unique)h(table)f(is)g(already)h -(lar)n(ge,)f(only)h(slo)n(w)e(gro)n(wth)h(is)f(possible.)p -Black 562 1249 a(2.)p Black 46 w(If)35 b(the)h(table)h(is)f(small)g -(and)g(man)o(y)g(dead)h(nodes)g(are)f(being)h(reclaimed,)j(then)d(f)o -(ast)676 1362 y(gro)n(wth)24 b(is)f(selected.)448 1549 -y(This)j(polic)o(y)g(is)g(especially)i(ef)n(fecti)n(v)o(e)f(when)f(the) -g(diagrams)h(being)f(manipulated)j(ha)n(v)o(e)d(lots)448 -1662 y(of)f(recombination.)37 b(Notice)25 b(the)h(interplay)h(of)e(the) -h(cache)g(sizing)g(and)g(unique)g(sizing:)34 b(F)o(ast)448 -1775 y(gro)n(wth)24 b(normally)h(occurs)f(when)g(the)f(cache)h(hit)g -(rate)g(is)f(lar)n(ge.)29 b(The)23 b(cache)h(and)g(the)g(unique)448 -1888 y(table)h(then)f(gro)n(w)f(in)h(concert,)h(preserving)h(a)d -(healthy)i(balance)h(between)e(their)h(sizes.)448 2137 -y Fi(4.6)99 b(Allo)o(wing)24 b(Asynchr)n(onous)i(Reordering)448 -2311 y Fo(Asynchronous)36 b(reordering)f(is)d(the)g(reordering)j(that)d -(is)g(triggered)j(automatically)g(by)d(the)448 2424 y(increase)37 -b(of)d(the)h(number)g(of)g(nodes.)62 b(Asynchronous)38 -b(reordering)f(tak)o(es)f(place)f(when)g(a)448 2537 y(ne)n(w)28 -b(internal)i(node)g(must)e(be)g(created,)j(and)e(the)g(number)g(of)f -(nodes)i(has)f(reached)h(a)e(gi)n(v)o(en)448 2650 y(threshold.)49 -b(\(The)29 b(threshold)j(is)d(adjusted)i(by)f(the)f(package)i(e)n(v)o -(ery)f(time)f(reordering)j(tak)o(es)448 2763 y(place.\))589 -2876 y(Those)24 b(procedures)j(that)d(do)g(not)f(create)i(ne)n(w)e -(nodes)i(\(e.g.,)e(procedures)j(that)e(count)h(the)448 -2989 y(number)g(of)e(nodes)h(or)g(minterms\))g(need)g(not)g(w)o(orry)f -(about)i(asynchronous)i(reordering:)32 b(No)448 3102 -y(special)25 b(precaution)i(is)c(necessary)j(in)e(writing)g(them.)589 -3215 y(Procedures)i(that)e(only)g(manipulate)i(decision)f(diagrams)g -(through)g(the)f(e)o(xported)h(func-)448 3328 y(tions)j(of)e(the)h -(CUDD)e(package)j(also)f(need)h(not)f(concern)h(themselv)o(es)h(with)d -(asynchronous)448 3440 y(reordering.)32 b(\(See)23 b(Section)i(3.2.1)e -(for)h(the)g(e)o(xceptions.\))589 3553 y(The)i(remaining)h(class)g(of)e -(procedures)k(is)c(composed)j(of)d(functions)j(that)e(visit)h(the)f -(dia-)448 3666 y(grams)h(and)h(may)e(create)i(ne)n(w)e(nodes.)39 -b(All)26 b(such)i(procedures)h(in)e(the)g(CUDD)d(package)29 -b(are)448 3779 y(written)35 b(so)e(that)h(the)o(y)g(can)g(be)f -(interrupted)k(by)d(dynamic)g(reordering.)62 b(The)33 -b(general)i(ap-)448 3892 y(proach)26 b(follo)n(wed)g(goes)f(under)g -(the)g(name)f(of)h(\223abort)g(and)g(retry.)-6 b(\224)32 -b(As)24 b(the)g(name)h(implies,)g(a)448 4005 y(computation)i(that)d(is) -f(interrupted)k(by)c(dynamic)i(reordering)h(is)e(aborted)h(and)f(tried) -h(again.)589 4118 y(A)e(recursi)n(v)o(e)i(procedure)h(that)e(can)f(be)h -(interrupted)i(by)e(dynamic)g(reordering)i(\(an)e(inter)n(-)448 -4231 y(ruptible)g(procedure)h(from)d(no)n(w)g(on\))h(is)f(composed)i -(of)e(tw)o(o)f(functions.)31 b(One)22 b(is)g(responsible)448 -4344 y(for)30 b(the)f(real)h(computation.)49 b(The)29 -b(other)h(is)f(a)g(simple)h(wrapper,)h(which)f(tests)g(whether)g(re-) -448 4457 y(ordering)c(occurred)g(and)e(restarts)h(the)f(computation)i -(if)d(it)h(did.)589 4570 y(Asynchronous)f(reordering)e(of)e(BDDs)e(and) -i(ADDs)e(can)i(only)h(be)e(triggered)k(inside)e Fn(cud-)448 -4682 y(dUniqueInter)r Fo(,)36 b(when)31 b(a)f(ne)n(w)g(node)i(is)f -(about)h(to)e(be)h(created.)53 b(Lik)o(e)n(wise,)32 b(asynchronous)448 -4795 y(reordering)f(of)d(ZDDs)f(can)h(only)h(be)f(triggered)j(inside)e -Fn(cuddUniqueInterZdd)r Fo(.)48 b(When)28 b(re-)448 4908 -y(ordering)e(is)d(triggered,)j(three)e(things)h(happen:)p -Black 1897 5225 a(32)p Black eop end -%%Page: 33 33 -TeXDict begin 33 32 bop Black Black Black 562 573 a Fo(1.)p -Black 46 w Fn(cuddUniqueInter)29 b Fo(returns)d(a)d(NULL)e(v)n(alue;)p -Black 562 760 a(2.)p Black 46 w(The)i(\003ag)g Fn(r)m(eor)m(der)m(ed)28 -b Fo(of)23 b(the)h(manager)h(is)e(set)h(to)g(1.)29 b(\(0)23 -b(means)h(no)g(reordering,)i(while)676 873 y(2)d(indicates)j(an)d -(error)i(occurred)g(during)g(reordering.\))p Black 562 -1061 a(3.)p Black 46 w(The)g(counter)k Fn(r)m(eor)m(derings)g -Fo(of)d(the)g(manager)i(is)e(incremented.)40 b(The)26 -b(counter)i(is)e(ini-)676 1174 y(tialized)37 b(to)f(0)f(when)h(the)g -(manager)h(is)f(started)h(and)f(can)g(be)g(accessed)i(by)e(calling)676 -1287 y Fn(Cudd)p 877 1287 28 4 v 33 w(ReadReor)m(derings)p -Fo(.)41 b(By)25 b(taking)j(tw)o(o)e(readings)j(of)d(the)h(counter)l(,)i -(an)d(applica-)676 1400 y(tion)32 b(can)g(determine)i(if)d(v)n(ariable) -j(reordering)h(has)d(tak)o(en)h(place)g(between)g(the)f(\002rst)676 -1513 y(and)27 b(the)g(second)h(reading.)41 b(The)26 b(package)j -(itself,)f(ho)n(we)n(v)o(er)l(,)g(does)g(not)f(mak)o(e)g(use)g(of)676 -1626 y(the)c(counter:)31 b(It)24 b(is)f(mentioned)j(here)e(for)g -(completeness.)589 1813 y(The)35 b(recursi)n(v)o(e)h(procedure)i(that)d -(recei)n(v)o(es)h(a)e(NULL)f(v)n(alue)i(from)g Fn(cuddUniqueInter)448 -1926 y Fo(must)g(free)h(all)f(intermediate)j(results)f(that)e(it)g(may) -g(ha)n(v)o(e)h(computed)g(before,)j(and)d(return)448 -2039 y(NULL)21 b(in)j(its)f(turn.)589 2152 y(The)31 b(wrapper)g -(function)i(does)e(not)g(decide)i(whether)e(reordering)j(occurred)e -(based)g(on)448 2265 y(the)37 b(NULL)e(return)j(v)n(alue,)i(because)f -(the)e(NULL)d(v)n(alue)k(may)e(be)h(the)g(result)h(of)f(lack)g(of)448 -2378 y(memory)-6 b(.)29 b(Instead,)c(it)f(checks)h(the)e -Fn(r)m(eor)m(der)m(ed)28 b Fo(\003ag.)589 2491 y(When)h(a)e(recursi)n -(v)o(e)i(procedure)i(calls)e(another)g(recursi)n(v)o(e)h(procedure)g -(that)f(may)e(cause)448 2604 y(reordering,)i(it)d(should)i(bypass)f -(the)f(wrapper)h(and)g(call)f(the)g(recursi)n(v)o(e)i(procedure)h -(directly)-6 b(.)448 2716 y(Otherwise,)29 b(the)f(calling)i(procedure)g -(will)d(not)h(kno)n(w)f(whether)i(reordering)h(occurred,)h(and)448 -2829 y(will)26 b(not)g(be)g(able)g(to)g(restart.)37 b(This)25 -b(is)h(the)g(main)g(reason)h(why)e(most)h(recursi)n(v)o(e)h(procedures) -448 2942 y(are)k(internal,)i(rather)e(than)g(static.)50 -b(\(The)30 b(wrappers,)j(on)d(the)h(other)g(hand,)h(are)e(mostly)h(e)o -(x-)448 3055 y(ported.\))448 3304 y Fi(4.7)99 b(Deb)n(ugging)448 -3479 y Fo(By)35 b(de\002ning)i(the)g(symbol)f(DD)p 1508 -3479 V 32 w(DEB)o(UG)e(during)j(compilation,)k(numerous)d(checks)f(are) -448 3592 y(added)20 b(to)e(the)g(code.)28 b(In)18 b(addition,)j(the)d -(procedures)j Fn(Cudd)p 2297 3592 V 34 w(Deb)n(ugChec)n(k)r -Fo(,)g Fn(Cudd)p 3036 3592 V 33 w(Chec)n(kK)m(e)m(ys)p -Fo(,)448 3704 y(and)g Fn(cuddHeapPr)l(o\002le)i Fo(can)e(be)f(called)h -(at)f(an)o(y)g(point)i(to)e(v)o(erify)h(the)f(consistenc)o(y)j(of)d -(the)h(data)448 3817 y(structure.)44 b(\()p Fn(cuddHeapPr)l(o\002le)31 -b Fo(is)d(an)f(internal)j(procedure.)44 b(It)27 b(is)h(declared)i(in)d -Fn(cuddInt.h)p Fo(.\))448 3930 y(Procedures)37 b Fn(Cudd)p -1087 3930 V 34 w(Deb)n(ugChec)n(k)h Fo(and)d Fn(Cudd)p -1983 3930 V 34 w(Chec)n(kK)m(e)m(ys)h Fo(are)f(especially)i(useful)f -(when)448 4043 y(CUDD)20 b(reports)k(that)e(during)i(garbage)f -(collection)i(the)d(number)h(of)e(nodes)j(actually)g(deleted)448 -4156 y(from)k(the)h(unique)h(table)f(is)f(dif)n(ferent)i(from)f(the)f -(count)i(of)e(dead)h(nodes)g(k)o(ept)g(by)g(the)f(man-)448 -4269 y(ager)-5 b(.)36 b(The)25 b(error)h(causing)h(the)f(discrepanc)o -(y)j(may)c(ha)n(v)o(e)h(occurred)i(much)d(earlier)i(than)f(it)f(is)448 -4382 y(disco)o(v)o(ered.)42 b(A)26 b(fe)n(w)h(strate)o(gicaly)j(placed) -f(calls)f(to)f(the)g(deb)n(ugging)k(procedures)f(can)e(con-)448 -4495 y(siderably)j(narro)n(w)e(do)n(wn)f(the)h(search)g(for)g(the)g -(source)g(of)g(the)f(problem.)45 b(\(F)o(or)27 b(instance,)32 -b(a)448 4608 y(call)23 b(to)g Fn(Cudd)p 895 4608 V 34 -w(Recur)o(siveDer)m(ef)38 b Fo(where)23 b(one)g(to)f -Fn(Cudd)p 2210 4608 V 34 w(Der)m(ef)36 b Fo(w)o(as)22 -b(required)i(may)f(be)f(iden-)448 4721 y(ti\002ed)i(in)f(this)h(w)o(ay) --6 b(.\))589 4834 y(One)29 b(of)g(the)g(most)g(common)g(problems)i -(encountered)h(in)d(deb)n(ugging)j(code)e(based)g(on)448 -4946 y(the)j(CUDD)e(package)k(is)e(a)f(missing)i(call)f(to)g -Fn(Cudd)p 2158 4946 V 34 w(Recur)o(siveDer)m(ef)13 b -Fo(.)59 b(T)-7 b(o)32 b(help)h(identify)p Black 1897 -5225 a(33)p Black eop end -%%Page: 34 34 -TeXDict begin 34 33 bop Black Black 448 573 a Fo(this)22 -b(type)g(of)f(problems,)i(the)e(package)i(pro)o(vides)g(a)e(function)i -(called)f Fn(Cudd)p 2858 573 28 4 v 34 w(Chec)n(kZer)l(oRef)13 -b Fo(.)448 686 y(This)37 b(function)h(should)h(be)d(called)i -(immediately)g(before)g(shutting)h(do)n(wn)e(the)f(manager)-5 -b(.)448 799 y Fn(Cudd)p 649 799 V 34 w(Chec)n(kZer)l(oRef)34 -b Fo(checks)20 b(that)g(the)f(only)h(nodes)g(left)f(with)g(non-zero)i -(reference)h(counts)448 912 y(are)27 b(the)f(prede\002ned)j(constants,) -g(the)e(BDD)d(projection)29 b(functions,)h(and)c(nodes)i(whose)f(ref-) -448 1024 y(erence)e(counts)g(are)f(saturated.)589 1137 -y(F)o(or)29 b(this)h(function)i(to)e(be)g(ef)n(fecti)n(v)o(e)h(the)f -(application)i(must)e(e)o(xplicitly)i(dispose)g(of)d(all)448 -1250 y(diagrams)c(to)f(which)g(it)f(has)h(pointers)h(before)g(calling)h -(it.)448 1498 y Fi(4.8)99 b(Gathering)26 b(and)f(Inter)o(pr)n(eting)i -(Statistics)448 1673 y Fo(Function)33 b Fn(Cudd)p 1003 -1673 V 34 w(PrintInfo)g Fo(can)f(be)f(called)i(to)e(print)i(out)f(the)f -(v)n(alues)i(of)e(parameters)j(and)448 1786 y(statistics)c(for)e(a)f -(manager)-5 b(.)41 b(The)27 b(output)j(of)d Fn(Cudd)p -2089 1786 V 34 w(PrintInfo)i Fo(is)e(di)n(vided)i(in)e(tw)o(o)g -(sections.)448 1899 y(The)19 b(\002rst)g(reports)i(the)e(v)n(alues)h -(of)f(parameters)j(that)d(are)h(under)g(the)f(application)k(control.)29 -b(The)448 2011 y(second)e(reports)g(the)f(v)n(alues)g(of)f(statistical) -j(counters)f(and)f(other)g(non-modi\002able)i(parame-)448 -2124 y(ters.)j(A)22 b(quick)k(guide)f(to)f(the)g(interpretation)k(of)c -(all)g(these)h(quantities)h(follo)n(ws.)31 b(F)o(or)23 -b(ease)h(of)448 2237 y(e)o(xposition,)30 b(we)25 b(re)n(v)o(erse)j(the) -f(order)g(and)g(describe)i(the)d(non-modi\002able)j(parameters)g -(\002rst.)448 2350 y(W)-7 b(e')o(ll)24 b(use)g(a)f(sample)h(run)g(as)f -(e)o(xample.)30 b(There)24 b(is)f(nothing)j(special)f(about)g(this)f -(run.)448 2595 y Fp(4.8.1)92 b(Non)22 b(Modi\002able)h(P)o(arameters) -448 2769 y Fo(The)g(list)h(of)g(non-modi\002able)i(parameters)g(starts) -e(with:)p Black Black 667 2952 a Fh(****)52 b(CUDD)h(non-modifiable)48 -b(parameters)i(****)667 3065 y(Memory)h(in)j(use:)f(32544220)448 -3247 y Fo(This)25 b(is)f(the)h(memory)g(used)h(by)f(CUDD)d(for)j(three) -h(things)g(mainly:)32 b(Unique)26 b(table)f(\(includ-)448 -3360 y(ing)i(all)g(DD)d(nodes)k(in)e(use\),)i(node)f(free)g(list,)g -(and)g(computed)h(table.)38 b(This)26 b(number)i(almost)448 -3473 y(ne)n(v)o(er)g(decreases)h(in)f(the)f(lifetime)h(of)f(a)g(CUDD)e -(manager)l(,)k(because)g(CUDD)c(does)j(not)f(re-)448 -3586 y(lease)k(memory)f(when)g(it)f(frees)h(nodes.)49 -b(Rather)l(,)32 b(it)d(puts)h(the)g(nodes)h(on)f(its)g(o)n(wn)f(free)h -(list.)448 3699 y(This)h(number)g(is)g(in)f(bytes.)51 -b(It)30 b(does)i(not)f(represent)i(the)e(peak)g(memory)g(occupation,)k -(be-)448 3812 y(cause)d(it)e(does)h(not)g(include)h(the)e(size)h(of)f -(data)h(structures)i(created)f(temporarily)h(by)d(some)448 -3925 y(functions)c(\(e.g.,)d(local)i(look-up)g(tables\).)p -Black Black 667 4131 a Fh(Peak)52 b(number)g(of)i(nodes:)d(837018)448 -4338 y Fo(This)31 b(number)h(is)f(the)g(number)g(of)g(nodes)h(that)g -(the)f(manager)h(has)f(allocated.)54 b(This)30 b(is)h(not)448 -4451 y(the)d(lar)n(gest)h(size)f(of)f(the)h(BDDs,)e(because)j(the)f -(manager)g(will)f(normally)i(ha)n(v)o(e)f(some)f(dead)448 -4563 y(nodes)e(and)f(some)g(nodes)h(on)e(the)h(free)g(list.)p -Black Black 667 4770 a Fh(Peak)52 b(number)g(of)i(live)e(nodes:)g -(836894)448 4976 y Fo(This)20 b(is)g(the)h(lar)n(gest)h(number)f(of)f -(li)n(v)o(e)g(nodes)h(that)g(the)f(manager)i(has)e(held)h(since)g(its)g -(creation.)p Black 1897 5225 a(34)p Black eop end -%%Page: 35 35 -TeXDict begin 35 34 bop Black Black Black Black 667 573 -a Fh(Number)51 b(of)j(BDD)f(variables:)d(198)667 686 -y(Number)h(of)j(ZDD)f(variables:)d(0)448 892 y Fo(These)24 -b(numbers)h(tell)f(us)f(this)h(run)g(w)o(as)g(not)f(using)i(ZDDs.)p -Black Black 667 1099 a Fh(Number)51 b(of)j(cache)e(entries:)f(1048576) -448 1306 y Fo(Current)25 b(number)g(of)f(slots)h(of)f(the)g(computed)i -(table.)31 b(If)24 b(one)g(has)g(a)g(performance)i(problem,)448 -1419 y(this)e(is)g(one)g(of)f(the)h(numbers)h(to)e(look)i(at.)j(The)23 -b(cache)i(size)f(is)f(al)o(w)o(ays)i(a)e(po)n(wer)g(of)h(2.)p -Black Black 667 1625 a Fh(Number)51 b(of)j(cache)e(look-ups:)f(2996536) -667 1738 y(Number)g(of)j(cache)e(hits:)g(1187087)448 -1945 y Fo(These)22 b(numbers)i(gi)n(v)o(e)e(an)g(indication)i(of)e(the) -g(hit)g(rate)h(in)e(the)i(computed)g(table.)29 b(It)22 -b(is)g(not)g(un-)448 2058 y(lik)o(ely)j(for)f(model)g(checking)i(runs)e -(to)g(get)f(hit)h(rates)g(e)n(v)o(en)g(higher)h(than)f(this)h(one)f -(\(39.62\045\).)p Black Black 667 2265 a Fh(Number)51 -b(of)j(cache)e(insertions:)e(1809473)667 2377 y(Number)h(of)j(cache)e -(collisions:)e(961208)667 2490 y(Number)h(of)j(cache)e(deletions:)e(0) -448 2697 y Fo(A)30 b(collision)j(occurs)f(when)f(a)f(cache)i(entry)g -(is)e(o)o(v)o(erwritten.)52 b(A)30 b(deletion)j(occurs)f(when)f(a)448 -2810 y(cache)c(entry)g(is)e(in)l(v)n(alidated)k(\(e.g.,)d(during)h -(garbage)g(collection\).)39 b(If)25 b(the)h(number)h(of)e(dele-)448 -2923 y(tions)d(is)f(high)g(compared)i(to)d(the)h(number)h(of)f -(collisions,)i(it)e(means)g(that)g(garbage)i(collection)448 -3036 y(occurs)32 b(too)e(often.)48 b(In)30 b(this)g(case)h(there)f -(were)g(no)g(garbage)h(collections;)36 b(hence,)d(no)c(dele-)448 -3149 y(tions.)p Black Black 667 3355 a Fh(Cache)52 b(used)g(slots)h(=)h -(80.90\045)e(\(expected)e(82.19\045\))448 3562 y Fo(Percentage)26 -b(of)e(cache)i(slots)f(that)f(contain)i(a)e(v)n(alid)h(entry)-6 -b(.)31 b(If)24 b(this)h(number)g(is)f(small,)g(it)g(may)448 -3675 y(signal)h(one)f(of)g(three)g(conditions:)p Black -562 3858 a(1.)p Black 46 w(The)f(cache)h(may)g(ha)n(v)o(e)g(been)g -(recently)i(resized)f(and)f(it)f(is)g(still)i(\002lling)f(up.)p -Black 562 4043 a(2.)p Black 46 w(The)j(cache)i(is)f(too)h(lar)n(ge)g -(for)f(the)g(BDDs.)41 b(This)28 b(should)i(not)e(happen)i(if)d(the)i -(size)f(of)676 4156 y(the)23 b(cache)i(is)e(determined)j(by)e(CUDD.)p -Black 562 4342 a(3.)p Black 46 w(The)f(hash)i(function)h(is)d(not)i(w)o -(orking)g(properly)-6 b(.)32 b(This)24 b(is)f(accompanied)k(by)d(a)f -(de)o(gra-)676 4455 y(dation)34 b(in)f(performance.)59 -b(Con)l(v)o(ersely)-6 b(,)37 b(a)c(de)o(gradation)j(in)c(performance)k -(may)c(be)676 4568 y(due)24 b(to)f(bad)h(hash)g(function)i(beha)n(vior) --5 b(.)448 4751 y(The)26 b(e)o(xpected)j(v)n(alue)e(is)f(computed)j -(assuming)f(a)e(uniformly)i(random)f(distrib)n(ution)k(of)26 -b(the)448 4863 y(accesses.)45 b(If)28 b(the)h(dif)n(ference)h(between)g -(the)e(measured)i(v)n(alue)f(and)g(the)f(e)o(xpected)i(v)n(alue)f(is) -448 4976 y(lar)n(ge)c(\(unlik)o(e)g(this)g(case\),)f(the)g(cache)g(is)g -(not)f(w)o(orking)i(properly)-6 b(.)p Black 1897 5225 -a(35)p Black eop end -%%Page: 36 36 -TeXDict begin 36 35 bop Black Black Black Black 667 573 -a Fh(Soft)52 b(limit)g(for)i(cache)e(size:)g(1318912)448 -781 y Fo(This)25 b(number)h(says)f(ho)n(w)g(lar)n(ge)h(the)f(cache)h -(can)f(gro)n(w)-6 b(.)33 b(This)24 b(limit)h(is)g(based)h(on)f(the)g -(size)g(of)448 894 y(the)k(unique)g(table.)43 b(CUDD)26 -b(uses)j(a)e(re)n(w)o(ard-based)k(polic)o(y)e(for)f(gro)n(wing)h(the)f -(cache.)44 b(\(See)448 1007 y(Section)32 b(4.4.1.\))49 -b(The)30 b(def)o(ault)i(hit)e(rate)h(for)g(resizing)h(is)e(30\045)g -(and)h(the)g(v)n(alue)g(in)f(ef)n(fect)h(is)448 1120 -y(reported)26 b(among)e(the)g(modi\002able)h(parameters.)p -Black Black 667 1328 a Fh(Number)51 b(of)j(buckets)d(in)j(unique)e -(table:)g(329728)448 1537 y Fo(This)28 b(number)g(is)g(e)o(xactly)h -(one)f(quarter)i(of)d(the)h(one)g(abo)o(v)o(e.)42 b(This)28 -b(is)f(indeed)j(ho)n(w)d(the)h(soft)448 1650 y(limit)37 -b(is)g(determined)i(currently)-6 b(,)43 b(unless)38 b(the)g(computed)g -(table)g(hits)g(the)f(speci\002ed)i(hard)448 1763 y(limit.)29 -b(\(See)23 b(belo)n(w)-6 b(.\))p Black Black 667 1971 -a Fh(Used)52 b(buckets)g(in)h(unique)f(table:)g(87.96\045)g(\(expected) -e(87.93\045\))448 2180 y Fo(Percentage)27 b(of)e(unique)i(table)f(b)n -(uck)o(ets)h(that)e(contain)i(at)e(least)g(one)h(node.)34 -b(Remarks)25 b(analo-)448 2293 y(gous)g(to)e(those)i(made)e(about)i -(the)f(used)g(cache)h(slots)f(apply)-6 b(.)p Black Black -667 2501 a Fh(Number)51 b(of)j(BDD)f(and)g(ADD)g(nodes:)f(836894)667 -2614 y(Number)f(of)j(ZDD)f(nodes:)f(0)448 2822 y Fo(Ho)n(w)22 -b(man)o(y)i(nodes)h(are)e(currently)j(in)e(the)g(unique)h(table,)f -(either)h(ali)n(v)o(e)e(or)h(dead.)p Black Black 667 -3031 a Fh(Number)51 b(of)j(dead)f(BDD)g(and)g(ADD)g(nodes:)f(0)667 -3144 y(Number)f(of)j(dead)f(ZDD)g(nodes:)f(0)448 3352 -y Fo(Subtract)29 b(these)f(numbers)g(from)f(those)i(abo)o(v)o(e)e(to)h -(get)f(the)g(number)i(of)e(li)n(v)o(e)g(nodes.)41 b(In)27 -b(this)448 3465 y(case)k(there)g(are)g(no)f(dead)h(nodes)g(because)i -(the)d(application)j(uses)e(delayed)h(dereferencing)448 -3578 y Fn(Cudd)p 649 3578 28 4 v 34 w(DelayedDer)m(efBdd)r -Fo(.)p Black Black 667 3786 a Fh(Total)52 b(number)g(of)h(nodes)f -(allocated:)e(836894)448 3995 y Fo(This)29 b(is)g(the)g(total)h(number) -g(of)e(nodes)j(that)e(were)g(requested)i(and)f(obtained)h(from)e(the)g -(free)448 4108 y(list.)52 b(It)31 b(ne)n(v)o(er)h(decreases,)j(and)d -(is)f(not)g(an)g(indication)j(of)e(memory)f(occupation)j(after)e(the) -448 4221 y(\002rst)23 b(garbage)i(collection.)32 b(Rather)l(,)24 -b(it)f(is)h(a)f(measure)h(of)g(the)g(package)h(acti)n(vity)-6 -b(.)p Black Black 667 4429 a Fh(Total)52 b(number)g(of)h(nodes)f -(reclaimed:)e(0)448 4638 y Fo(These)29 b(are)f(the)h(nodes)g(that)g -(were)f(resuscitated)k(from)c(the)h(dead.)43 b(If)28 -b(the)o(y)h(are)f(man)o(y)g(more)448 4751 y(than)23 b(the)e(allocated)j -(nodes,)f(and)f(the)g(total)g(number)h(of)e(slots)h(is)g(lo)n(w)f -(relati)n(v)o(e)h(to)g(the)f(number)448 4863 y(of)26 -b(nodes,)i(then)f(one)g(may)f(w)o(ant)g(to)g(increase)i(the)f(limit)f -(for)g(f)o(ast)h(unique)h(table)f(gro)n(wth.)37 b(In)448 -4976 y(this)24 b(case,)g(the)g(number)h(is)e(0)g(because)j(of)d -(delayed)i(dereferencing.)p Black 1897 5225 a(36)p Black -eop end -%%Page: 37 37 -TeXDict begin 37 36 bop Black Black Black Black 667 573 -a Fh(Garbage)51 b(collections)e(so)54 b(far:)f(0)667 -686 y(Time)f(for)h(garbage)f(collections:)d(0.00)k(sec)667 -799 y(Reorderings)c(so)54 b(far:)e(0)667 912 y(Time)g(for)h -(reordering:)d(0.00)j(sec)448 1124 y Fo(There)26 b(is)f(a)g(GC)f(for)i -(each)g(reordering.)37 b(Hence)26 b(the)f(\002rst)h(count)g(will)f(al)o -(w)o(ays)h(be)g(at)f(least)h(as)448 1237 y(lar)n(ge)f(as)f(the)f -(second.)p Black Black 667 1450 a Fh(Node)52 b(swaps)g(in)i -(reordering:)c(0)448 1662 y Fo(This)31 b(is)g(the)g(number)h(of)e -(elementary)j(reordering)h(steps.)52 b(Each)31 b(step)g(consists)i(of)e -(the)g(re-)448 1775 y(e)o(xpression)g(of)d(one)g(node)h(while)f(sw)o -(apping)i(tw)o(o)e(adjacent)i(v)n(ariables.)44 b(This)28 -b(number)h(is)f(a)448 1888 y(good)d(measure)f(of)g(the)g(amount)g(of)g -(w)o(ork)f(done)i(in)e(reordering.)448 2134 y Fp(4.8.2)92 -b(Modi\002able)23 b(P)o(arameters)448 2308 y Fo(Let)g(us)g(no)n(w)f -(consider)k(the)d(modi\002able)h(parameters,)h(that)f(is,)e(those)i -(settings)h(on)f(which)f(the)448 2421 y(application)k(or)c(the)h(user)g -(has)g(control.)p Black Black 667 2634 a Fh(****)52 b(CUDD)h -(modifiable)d(parameters)g(****)667 2746 y(Hard)i(limit)g(for)i(cache)e -(size:)g(8388608)448 2959 y Fo(This)30 b(number)i(counts)f(entries.)51 -b(Each)30 b(entry)h(is)f(16)h(bytes)g(if)f(CUDD)e(is)i(compiled)i(to)e -(use)448 3072 y(32-bit)25 b(pointers.)31 b(T)-7 b(w)o(o)22 -b(important)j(observ)n(ations)i(are)d(in)g(order:)p Black -562 3259 a(1.)p Black 46 w(If)29 b(the)i(datasize)h(limit)e(is)g(set,)h -(CUDD)d(will)i(use)g(it)g(to)g(determine)h(this)g(number)g(au-)676 -3372 y(tomatically)-6 b(.)39 b(On)26 b(a)g(Unix)g(system,)i(one)f(can)g -(type)g(\223limit\224)g(or)f(\223ulimit\224)i(to)e(v)o(erify)i(if)676 -3485 y(this)e(v)n(alue)h(is)e(set.)36 b(If)26 b(the)g(datasize)i(limit) -e(is)f(not)h(set,)h(CUDD)c(uses)k(a)e(def)o(ault)j(which)676 -3598 y(is)21 b(rather)i(small.)28 b(If)22 b(you)g(ha)n(v)o(e)g(enough)i -(memory)d(\(say)i(64MB)e(or)h(more\))f(you)i(should)676 -3711 y(seriously)29 b(consider)g Fn(not)f Fo(using)g(the)f(def)o(ault.) -40 b(So,)27 b(either)h(set)e(the)h(datasize)i(limit,)e(or)676 -3824 y(o)o(v)o(erride)d(the)g(def)o(ault)i(with)d Fn(Cudd)p -1792 3824 28 4 v 34 w(SetMaxCac)o(heHar)m(d)r Fo(.)p -Black 562 4012 a(2.)p Black 46 w(If)d(a)g(process)j(seems)e(to)g(be)f -(going)i(no)n(where,)g(a)f(small)f(v)n(alue)i(for)f(this)g(parameter)i -(may)676 4125 y(be)29 b(the)h(culprit.)47 b(One)29 b(cannot)i(o)o(v)o -(eremphasize)h(the)e(importance)i(of)d(the)h(computed)676 -4237 y(table)24 b(in)f(BDD)f(algorithms.)448 4425 y(In)i(this)g(case)g -(the)g(limit)f(w)o(as)g(automatically)k(set)d(for)f(a)g(tar)n(get)i -(maximum)f(memory)f(occupa-)448 4538 y(tion)h(of)g(104)g(MB.)p -Black Black 667 4751 a Fh(Cache)52 b(hit)h(threshold)d(for)k(resizing:) -c(15\045)p Black 1897 5225 a Fo(37)p Black eop end -%%Page: 38 38 -TeXDict begin 38 37 bop Black Black 448 573 a Fo(This)25 -b(number)g(can)g(be)f(changed)j(if)d(one)h(suspects)i(performance)g(is) -d(hindered)j(by)d(the)h(small)448 686 y(size)30 b(of)e(the)i(cache,)g -(and)g(the)f(cache)h(is)e(not)i(gro)n(wing)f(to)n(w)o(ards)h(the)f -(soft)g(limit)g(suf)n(\002ciently)448 799 y(f)o(ast.)g(In)21 -b(such)h(a)f(case)h(one)g(can)g(change)h(the)e(def)o(ault)i(30\045)f -(to)f(15\045)g(\(as)g(in)h(this)g(case\))g(or)f(e)n(v)o(en)448 -912 y(1\045.)p Black Black 667 1124 a Fh(Garbage)51 b(collection)f -(enabled:)h(yes)448 1337 y Fo(One)34 b(can)g(disable)i(it,)f(b)n(ut)g -(there)f(are)g(fe)n(w)f(good)i(reasons)h(for)e(doing)h(so.)60 -b(It)33 b(is)h(normally)448 1450 y(preferable)26 b(to)e(raise)g(the)g -(limit)g(for)f(f)o(ast)h(unique)i(table)e(gro)n(wth.)29 -b(\(See)24 b(belo)n(w)-6 b(.\))p Black Black 667 1662 -a Fh(Limit)52 b(for)h(fast)g(unique)e(table)i(growth:)e(1363148)448 -1875 y Fo(See)23 b(Section)i(4.5)f(and)g(the)g(comments)g(abo)o(v)o(e)h -(about)g(reclaimed)g(nodes)g(and)f(hard)g(limit)g(for)448 -1988 y(the)g(cache)h(size.)30 b(This)23 b(v)n(alue)i(w)o(as)e(chosen)i -(automatically)i(by)d(CUDD)d(for)j(a)g(datasize)h(limit)448 -2100 y(of)f(1)f(GB.)p Black Black 667 2313 a Fh(Maximum)51 -b(number)h(of)h(variables)e(sifted)h(per)h(reordering:)c(1000)667 -2426 y(Maximum)i(number)h(of)h(variable)e(swaps)h(per)i(reordering:)49 -b(2000000)667 2539 y(Maximum)i(growth)h(while)g(sifting)f(a)j -(variable:)d(1.2)448 2751 y Fo(Lo)n(wering)29 b(these)f(numbers)i(will) -d(cause)i(reordering)i(to)c(be)h(less)h(accurate)h(and)e(f)o(aster)-5 -b(.)43 b(Re-)448 2864 y(sults)22 b(are)f(some)n(what)g(unpredictable,)k -(because)d(lar)n(ger)g(BDDs)d(after)j(one)f(reordering)i(do)e(not)448 -2977 y(necessarily)27 b(mean)d(the)f(process)j(will)d(go)h(f)o(aster)g -(or)g(slo)n(wer)-5 b(.)p Black Black 667 3190 a Fh(Dynamic)51 -b(reordering)f(of)j(BDDs)g(enabled:)e(yes)667 3303 y(Default)g(BDD)i -(reordering)d(method:)h(4)667 3416 y(Dynamic)g(reordering)f(of)j(ZDDs)g -(enabled:)e(no)667 3528 y(Default)g(ZDD)i(reordering)d(method:)h(4)448 -3741 y Fo(These)38 b(lines)h(tell)f(whether)g(automatic)i(reordering)g -(can)e(tak)o(e)g(place)h(and)f(what)f(method)448 3854 -y(w)o(ould)28 b(be)f(used.)41 b(The)27 b(mapping)i(from)e(numbers)h(to) -f(methods)i(is)e(in)g Fh(cudd.h)p Fo(.)37 b(One)27 b(may)448 -3967 y(w)o(ant)i(to)f(try)g(dif)n(ferent)i(BDD)d(reordering)k(methods.) -44 b(If)28 b(v)n(ariable)i(groups)g(are)f(used,)h(ho)n(w-)448 -4080 y(e)n(v)o(er)l(,)21 b(one)f(should)i(not)e(e)o(xpect)h(to)e(see)h -(big)g(dif)n(ferences,)j(because)f(CUDD)c(uses)i(the)g(reported)448 -4193 y(method)31 b(only)f(to)f(reorder)i(each)f(leaf)g(v)n(ariable)h -(group)f(\(typically)i(corresponding)i(present)448 4306 -y(and)d(ne)o(xt)g(state)g(v)n(ariables\).)51 b(F)o(or)30 -b(the)h(relati)n(v)o(e)g(order)g(of)g(the)f(groups,)k(it)c(al)o(w)o -(ays)h(uses)g(the)448 4418 y(same)24 b(algorithm,)h(which)f(is)f(ef)n -(fecti)n(v)o(ely)j(sifting.)589 4531 y(As)i(for)h(enabling)h(dynamic)g -(reordering)h(or)e(not,)h(a)e(sensible)i(recommendation)i(is)c(the)448 -4644 y(follo)n(wing:)36 b(Unless)27 b(the)f(circuit)h(is)f(rather)h -(small)f(or)g(one)h(has)f(a)g(pretty)h(good)g(idea)f(of)g(what)448 -4757 y(the)e(order)h(should)g(be,)e(reordering)j(should)g(be)d -(enabled.)p Black 1897 5225 a(38)p Black eop end -%%Page: 39 39 -TeXDict begin 39 38 bop Black Black Black Black 667 573 -a Fh(Realignment)49 b(of)54 b(ZDDs)e(to)i(BDDs)f(enabled:)e(no)667 -686 y(Realignment)e(of)54 b(BDDs)e(to)i(ZDDs)f(enabled:)e(no)667 -799 y(Dead)h(nodes)g(counted)g(in)h(triggering)d(reordering:)g(no)667 -912 y(Group)i(checking)f(criterion:)f(7)667 1024 y(Recombination)e -(threshold:)i(0)667 1137 y(Symmetry)g(violation)h(threshold:)f(0)667 -1250 y(Arc)j(violation)d(threshold:)g(0)667 1363 y(GA)j(population)d -(size:)i(0)667 1476 y(Number)f(of)j(crossovers)c(for)j(GA:)g(0)448 -1681 y Fo(P)o(arameters)26 b(for)f(reordering.)37 b(See)24 -b(the)i(documentation)i(of)d(the)h(functions)i(used)e(to)f(control)448 -1794 y(these)g(parameters)g(for)f(the)g(details.)p Black -Black 667 1998 a Fh(Next)52 b(reordering)e(threshold:)g(100000)448 -2203 y Fo(When)25 b(the)g(number)g(of)g(nodes)h(crosses)g(this)f -(threshold,)i(reordering)g(will)e(be)f(triggered.)34 -b(\(If)448 2315 y(enabled;)26 b(in)d(this)h(case)f(it)g(is)g(not.\))30 -b(This)23 b(parameter)h(is)f(updated)j(by)d(the)g(package)i(whene)n(v)o -(er)448 2428 y(reordering)i(tak)o(es)f(place.)32 b(The)24 -b(application)j(can)e(change)h(it,)e(for)g(instance)j(at)d(start-up.)33 -b(An-)448 2541 y(other)24 b(possibility)h(is)e(to)f(use)h(a)f(hook)h -(function)i(\(see)e(Section)h(3.16\))f(to)f(o)o(v)o(erride)i(the)f(def) -o(ault)448 2654 y(updating)j(polic)o(y)-6 b(.)448 2899 -y Fp(4.8.3)92 b(Extended)22 b(Statistics)k(and)c(Reporting)448 -3073 y Fo(The)27 b(follo)n(wing)i(symbols)f(can)f(be)h(de\002ned)g -(during)g(compilation)i(to)d(increase)i(the)e(amount)448 -3186 y(of)d(statistics)i(gathered)f(and)f(the)g(number)g(of)g(messages) -h(produced)h(by)d(the)h(package:)p Black 585 3367 a Fm(\017)p -Black 46 w Fo(DD)p 813 3367 28 4 v 32 w(ST)-8 b(A)e(TS;)p -Black 585 3552 a Fm(\017)p Black 46 w Fo(DD)p 813 3552 -V 32 w(CA)l(CHE)p 1151 3552 V 31 w(PR)l(OFILE;)p Black -585 3737 a Fm(\017)p Black 46 w Fo(DD)p 813 3737 V 32 -w(UNIQ)o(UE)p 1194 3737 V 31 w(PR)l(OFILE.)p Black 585 -3922 a Fm(\017)p Black 46 w Fo(DD)p 813 3922 V 32 w(VERBOSE;)448 -4103 y(De\002ning)27 b(DD)p 929 4103 V 32 w(CA)l(CHE)p -1267 4103 V 32 w(PR)l(OFILE)d(causes)k(each)f(entry)h(of)e(the)h(cache) -h(to)f(include)h(an)f(ac-)448 4215 y(cess)i(counter)l(,)h(which)e(is)g -(used)g(to)g(compute)h(simple)f(statistics)i(on)e(the)g(distrib)n -(ution)j(of)d(the)448 4328 y(k)o(e)o(ys.)448 4576 y Fi(4.9)99 -b(Guidelines)25 b(f)n(or)g(Documentation)448 4751 y Fo(The)36 -b(documentation)j(of)d(the)g(CUDD)d(functions)38 b(is)e(e)o(xtracted)i -(automatically)g(from)e(the)448 4863 y(sources)23 b(by)e(Stephen)h(Edw) -o(ards')-5 b(s)21 b(e)o(xtdoc.)29 b(\(The)21 b(Ext)f(system)i(is)e(a)n -(v)n(ailable)j(via)e(anon)o(ymous)448 4976 y(FTP)27 b(from)i -Fh(ic.eecs.berkele)o(y.)o(ed)o(u)p Fo(.\))38 b(The)29 -b(follo)n(wing)h(guidelines)i(are)d(follo)n(wed)p Black -1897 5225 a(39)p Black eop end -%%Page: 40 40 -TeXDict begin 40 39 bop Black Black 448 573 a Fo(in)28 -b(CUDD)d(to)j(insure)h(consistent)h(and)f(ef)n(fecti)n(v)o(e)f(use)h -(of)e(automatic)i(e)o(xtraction.)44 b(It)27 b(is)h(rec-)448 -686 y(ommended)d(that)f(e)o(xtensions)i(to)e(CUDD)d(follo)n(w)j(the)g -(same)f(documentation)k(guidelines.)p Black 585 873 a -Fm(\017)p Black 46 w Fo(The)j(documentation)35 b(of)c(an)g(e)o(xported) -i(procedure)h(should)f(be)e(suf)n(\002cient)h(to)f(allo)n(w)676 -986 y(one)23 b(to)h(use)f(it)h(without)g(reading)h(the)f(code.)29 -b(It)23 b(is)g(not)h(necessary)i(to)d(e)o(xplain)i(ho)n(w)e(the)676 -1099 y(procedure)j(w)o(orks;)e(only)g(what)g(it)f(does.)p -Black 585 1287 a Fm(\017)p Black 46 w Fo(The)29 b Fn(SeeAlso)i -Fo(\002elds)f(should)i(be)e(space-separated)k(lists)d(of)f(function)i -(names.)49 b(The)676 1400 y Fn(SeeAlso)24 b Fo(\002eld)f(of)g(an)g(e)o -(xported)j(procedure)g(should)e(only)h(reference)g(other)f(e)o(xported) -676 1513 y(procedures.)39 b(The)26 b Fn(SeeAlso)h Fo(\002eld)f(of)h(an) -f(internal)i(procedure)h(may)d(reference)i(other)676 -1626 y(internal)c(procedures)i(as)d(well)f(as)h(e)o(xported)i -(procedures,)g(b)n(ut)f(no)f(static)h(procedures.)p Black -585 1813 a Fm(\017)p Black 46 w Fo(The)30 b(return)i(v)n(alues)g(are)f -(detailed)i(in)e(the)g Fn(Description)i Fo(\002eld,)g(not)e(in)g(the)g -Fn(Synopsis)676 1926 y Fo(\002eld.)p Black 585 2114 a -Fm(\017)p Black 46 w Fo(The)c(parameters)k(are)d(documented)j -(alongside)g(their)e(declarations.)46 b(Further)29 b(com-)676 -2227 y(ments)23 b(may)h(appear)h(in)e(the)h Fn(Description)i -Fo(\002eld.)p Black 585 2414 a Fm(\017)p Black 46 w Fo(If)i(the)i -Fn(Description)h Fo(\002eld)e(is)g(non-empty\227which)j(is)d(the)h -(normal)f(case)h(for)f(an)g(e)o(x-)676 2527 y(ported)19 -b(procedure\227then)j(the)d(synopsis)h(is)e(repeated\227possibly)23 -b(slightly)d(changed\227)676 2640 y(at)25 b(the)h(be)o(ginning)i(of)e -(the)g Fn(Description)i Fo(\002eld.)35 b(This)25 b(is)h(so)f(because)j -(e)o(xtdoc)f(will)e(not)676 2753 y(put)e(the)h(synopsis)i(in)e(the)f -(same)h(HTML)d(\002le)i(as)h(the)f(description.)p Black -585 2941 a Fm(\017)p Black 46 w Fo(The)g Fn(Synopsis)j -Fo(\002eld)d(should)i(be)f(about)g(one)g(line)g(long.)448 -3233 y Fq(5)120 b(The)30 b(C++)g(Interface)448 3444 y -Fi(5.1)99 b(Compiling)25 b(and)g(Linking)448 3618 y Fo(T)-7 -b(o)23 b(b)n(uild)i(an)e(application)k(that)d(uses)g(the)g(CUDD)d(C++)i -(interf)o(ace,)j(you)e(should)h(add)p Black Black 448 -3805 a Fh(#include)51 b("cuddObj.hh")448 3993 y Fo(to)31 -b(your)g(source)i(\002les.)50 b(In)30 b(addition)j(to)e(the)g(normal)g -(CUDD)e(libraries)j(\(see)g(Section)f(3.1\))448 4106 -y(you)22 b(should)g(link)g Fh(libobj.a)16 b Fo(to)21 -b(your)h(e)o(x)o(ecutable.)30 b(Refer)21 b(to)f(the)i -Fh(Makefile)16 b Fo(in)21 b(the)g(top)448 4219 y(le)n(v)o(el)j -(directory)i(of)d(the)h(distrib)n(ution)j(for)d(further)h(details.)448 -4468 y Fi(5.2)99 b(Basic)25 b(Manipulation)448 4642 y -Fo(The)d(follo)n(wing)i(fragment)g(of)f(code)g(illustrates)i(some)e -(simple)g(operations)j(on)c(BDDs)f(using)448 4755 y(the)j(C++)f(interf) -o(ace.)p Black 1897 5225 a(40)p Black eop end -%%Page: 41 41 -TeXDict begin 41 40 bop Black Black Black Black 448 573 -a Fh(Cudd)53 b(mgr\(0,0\);)448 686 y(BDD)h(x)g(=)g(mgr.bddVar\(\);)448 -799 y(BDD)g(y)g(=)g(mgr.bddVar\(\);)448 912 y(BDD)g(f)g(=)g(x)g(*)g(y;) -448 1024 y(BDD)g(g)g(=)g(y)g(+)g(!x;)448 1137 y(cout)f(<<)h("f)f(is")g -(<<)h(\(f)g(<=)f(g)h(?)h("")e(:)h(")g(not"\))721 1250 -y(<<)g(")g(less)e(than)h(or)h(equal)e(to)i(g\\n";)448 -1438 y Fo(This)22 b(code)h(creates)h(a)e(manager)h(called)h -Fh(mgr)c Fo(and)j(tw)o(o)e(v)n(ariables)k(in)d(it.)28 -b(It)22 b(then)h(de\002nes)g(tw)o(o)448 1551 y(functions)31 -b Fh(f)c Fo(and)h Fh(g)f Fo(in)h(terms)g(of)g(the)g(v)n(ariables.)44 -b(Finally)-6 b(,)30 b(it)e(prints)h(a)f(message)h(based)g(on)448 -1664 y(the)h(comparison)j(of)c(the)i(tw)o(o)e(functions.)50 -b(No)30 b(e)o(xplicit)h(referencing)i(or)d(dereferencing)j(is)448 -1777 y(required.)h(The)25 b(operators)i(are)d(o)o(v)o(erloaded)j(in)e -(the)g(intuiti)n(v)o(e)h(w)o(ay)-6 b(.)32 b(BDDs)23 b(are)i(freed)g -(when)448 1890 y(e)o(x)o(ecution)d(lea)n(v)o(es)e(the)g(scope)g(in)g -(which)g(the)o(y)f(are)h(de\002ned)g(or)f(when)h(the)g(v)n(ariables)h -(referring)448 2002 y(to)j(them)f(are)h(o)o(v)o(erwritten.)448 -2295 y Fq(6)120 b(Ackno)o(wledgments)448 2502 y Fo(The)27 -b(contrib)n(utors:)40 b(Iris)27 b(Bahar)l(,)h(Hyunw)o(oo)g(Cho,)f -(Erica)g(Frohm,)g(Charlie)h(Gaona,)g(Cheng)448 2615 y(Hua,)k(Jae-Y)-10 -b(oung)32 b(Jang,)g(Seh-W)-7 b(oong)31 b(Jeong,)i(Balakrishna)g(K)o -(umthekar)l(,)g(Enrico)d(Macii,)448 2728 y(Bobbie)19 -b(Manne,)h(In-Ho)e(Moon,)h(Curt)f(Musfeldt,)j(Shipra)d(P)o(anda,)h -(Abelardo)h(P)o(ardo,)f(Bernard)448 2841 y(Plessier)l(,)28 -b(Ka)n(vita)f(Ra)n(vi,)g(Hyongk)o(yoon)i(Shin,)d(Alan)h(Shuler)l(,)g -(Arun)f(Si)n(v)n(akumaran,)i(Jor)n(gen)448 2954 y(Si)n(v)o(esind.)448 -3067 y(The)k(early)h(adopters:)49 b(Gianpiero)34 b(Cabodi,)h(Jordi)e -(Cortadella,)j(Mario)d(Escobar)l(,)j(Gayani)448 3180 -y(Gamage,)28 b(Gary)f(Hachtel,)i(Mariano)g(Hermida,)f(W)-7 -b(oohyuk)28 b(Lee,)f(Enric)g(P)o(astor)l(,)i(Massimo)448 -3292 y(Poncino,)c(Ellen)e(Sento)o(vich,)i(the)f(students)i(of)d -(ECEN5139.)589 3405 y(I)36 b(am)f(also)h(particularly)k(indebted)e(to)e -(the)g(follo)n(wing)h(people)g(for)g(in-depth)h(discus-)448 -3518 y(sions)23 b(on)f(BDDs:)27 b(Armin)22 b(Biere,)g(Oli)n(vier)g -(Coudert,)h(Arie)f(Gur\002nk)o(el,)h(Geert)f(Janssen,)i(Don)448 -3631 y(Knuth,)39 b(Da)n(vid)d(Long,)i(Jean)f(Christophe)g(Madre,)i(K)n -(en)c(McMillan,)k(Shin-Ichi)e(Minato,)448 3744 y(Jaehong)24 -b(P)o(ark,)c(Rajee)n(v)i(Ranjan,)g(Rick)f(Rudell,)h(Ellen)f(Sento)o -(vich,)i(T)-7 b(om)20 b(Shiple,)i(Christian)448 3857 -y(Stangier)l(,)j(and)f(Bw)o(olen)g(Y)-9 b(ang.)589 3970 -y(Special)28 b(thanks)h(to)e(Norris)h(Ip)f(for)g(guiding)j(my)c(f)o -(altering)k(steps)e(in)f(the)g(design)i(of)e(the)448 -4083 y(C++)h(interf)o(ace.)46 b(Gianpiero)30 b(Cabodi)f(and)g(Stef)o -(ano)g(Quer)g(ha)n(v)o(e)g(graciously)i(agreed)f(to)e(let)448 -4196 y(me)23 b(distrib)n(ute)j(their)f(dddmp)f(library)h(with)f(CUDD.) -589 4309 y(Masahiro)j(Fujita,)e(Gary)g(Hachtel,)h(and)f(Carl)g(Pixle)o -(y)g(ha)n(v)o(e)h(pro)o(vided)h(encouragement)448 4422 -y(and)d(advice.)589 4534 y(The)31 b(National)i(Science)f(F)o(oundation) -h(and)f(the)f(Semiconductor)j(Research)f(Corpora-)448 -4647 y(tion)24 b(ha)n(v)o(e)h(supported)h(in)d(part)h(the)g(de)n(v)o -(elopment)i(of)d(this)i(package.)p Black 1897 5225 a(41)p -Black eop end -%%Page: 42 42 -TeXDict begin 42 41 bop Black Black 448 573 a Fq(Refer)n(ences)p -Black 494 780 a Fo([1])p Black 46 w(R.)27 b(I.)h(Bahar)l(,)i(E.)e(A.)f -(Frohm,)i(C.)e(M.)h(Gaona,)i(G.)d(D.)g(Hachtel,)j(E.)e(Macii,)h(A.)f(P) -o(ardo,)645 893 y(and)d(F)-7 b(.)23 b(Somenzi.)36 b(Algebraic)27 -b(decision)f(diagrams)g(and)f(their)g(applications.)40 -b(In)25 b Fn(Pr)l(o-)645 1006 y(ceedings)30 b(of)d(the)h(International) -k(Confer)m(ence)d(on)e(Computer)n(-Aided)j(Design)p Fo(,)f(pages)645 -1119 y(188\226191,)d(Santa)e(Clara,)f(CA,)f(No)o(v)o(ember)h(1993.)p -Black 494 1306 a([2])p Black 46 w(B.)36 b(Bollig,)41 -b(M.)35 b(L)8 b(\250)-38 b(obbing,)42 b(and)c(I.)e(W)-7 -b(e)o(gener)i(.)77 b(Simulated)38 b(annealing)i(to)d(impro)o(v)o(e)645 -1419 y(v)n(ariable)31 b(orderings)h(for)e(OBDDs.)50 b(Presented)30 -b(at)g(the)f(International)k(W)-7 b(orkshop)31 b(on)645 -1532 y(Logic)24 b(Synthesis,)h(Granlibakk)o(en,)h(CA,)c(May)h(1995.)p -Black 494 1720 a([3])p Black 46 w(K.)29 b(S.)f(Brace,)k(R.)d(L.)f -(Rudell,)k(and)f(R.)d(E.)h(Bryant.)55 b(Ef)n(\002cient)30 -b(implementation)j(of)d(a)645 1833 y(BDD)f(package.)57 -b(In)30 b Fn(Pr)l(oceedings)j(of)e(the)f(27th)h(Design)h(A)n(utomation) -g(Confer)m(ence)p Fo(,)645 1945 y(pages)25 b(40\22645,)g(Orlando,)f -(FL,)e(June)i(1990.)p Black 494 2133 a([4])p Black 46 -w(R.)g(K.)g(Brayton)j(et)e(al.)40 b(VIS:)24 b(A)h(system)h(for)f(v)o -(eri\002cation)j(and)e(synthesis.)42 b(T)-6 b(echnical)645 -2246 y(Report)31 b(UCB/ERL)26 b(M95/104,)33 b(Electronics)f(Research)f -(Lab,)g(Uni)n(v)-6 b(.)29 b(of)h(California,)645 2359 -y(December)24 b(1995.)p Black 494 2547 a([5])p Black -46 w(R.)32 b(E.)g(Bryant.)65 b(Graph-based)36 b(algorithms)g(for)d -(Boolean)i(function)h(manipulation.)645 2659 y Fn(IEEE)22 -b(T)-5 b(r)o(ansactions)26 b(on)e(Computer)o(s)p Fo(,)g -(C-35\(8\):677\226691,)k(August)c(1986.)p Black 494 2847 -a([6])p Black 46 w(R.)32 b(Drechsler)l(,)38 b(B.)32 b(Beck)o(er)l(,)k -(and)e(N.)e(G)8 b(\250)-38 b(ock)o(el.)66 b(A)32 b(genetic)j(algorithm) -g(for)f(v)n(ariable)645 2960 y(ordering)27 b(of)e(OBDDs.)35 -b(Presented)26 b(at)f(the)g(International)j(W)-7 b(orkshop)27 -b(on)d(Logic)h(Syn-)645 3073 y(thesis,)g(Granlibakk)o(en,)h(CA,)c(May)h -(1995.)p Black 494 3261 a([7])p Black 46 w(S.)j(J.)g(Friedman)i(and)g -(K.)e(J.)g(Supo)n(wit.)45 b(Finding)28 b(the)g(optimal)g(v)n(ariable)h -(ordering)g(for)645 3373 y(binary)24 b(decision)h(diagrams.)32 -b Fn(IEEE)21 b(T)-5 b(r)o(ansactions)25 b(on)d(Computer)o(s)p -Fo(,)i(39\(5\):710\226713,)645 3486 y(May)g(1990.)p Black -494 3674 a([8])p Black 46 w(M.)35 b(Fujita,)k(Y)-12 b(.)35 -b(Matsunaga,)40 b(and)d(T)-7 b(.)34 b(Kakuda.)74 b(On)35 -b(v)n(ariable)j(ordering)g(of)e(binary)645 3787 y(decision)30 -b(diagrams)f(for)f(the)g(application)j(of)c(multi-le)n(v)o(el)i(logic)g -(synthesis.)49 b(In)28 b Fn(Pr)l(o-)645 3900 y(ceedings)33 -b(of)e(the)g(Eur)l(opean)h(Confer)m(ence)h(on)e(Design)g(A)n(utomation) -p Fo(,)j(pages)e(50\22654,)645 4013 y(Amsterdam,)24 b(February)h(1991.) -p Black 494 4200 a([9])p Black 46 w(M.)h(Held)g(and)i(R.)d(M.)g(Karp.) -44 b(A)25 b(dynamic)j(programming)h(approach)g(to)e(sequencing)645 -4313 y(problems.)35 b Fn(J)n(.)23 b(SIAM)p Fo(,)f(10\(1\):196\226210,) -28 b(1962.)p Black 448 4501 a([10])p Black 47 w(N.)e(Ishiura,)i(H.)e -(Sa)o(w)o(ada,)h(and)g(S.)e(Y)-9 b(ajima.)43 b(Minimization)29 -b(of)e(binary)h(decision)h(dia-)645 4614 y(grams)f(based)g(on)g(e)o -(xchanges)h(of)e(v)n(ariables.)48 b(In)27 b Fn(Pr)l(oceedings)j(of)d -(the)g(International)645 4727 y(Confer)m(ence)37 b(on)e(Computer)n -(-Aided)j(Design)p Fo(,)g(pages)e(472\226475,)k(Santa)35 -b(Clara,)j(CA,)645 4840 y(No)o(v)o(ember)24 b(1991.)p -Black 1897 5225 a(42)p Black eop end -%%Page: 43 43 -TeXDict begin 43 42 bop Black Black Black 448 573 a Fo([11])p -Black 47 w(S.-W)-8 b(.)31 b(Jeong,)37 b(T)-7 b(.-S.)31 -b(Kim,)k(and)e(F)-7 b(.)32 b(Somenzi.)64 b(An)33 b(ef)n(\002cient)h -(method)g(for)f(optimal)645 686 y(BDD)25 b(ordering)k(computation.)47 -b(In)27 b Fn(International)k(Confer)m(ence)e(on)e(VLSI)f(and)h(CAD)645 -799 y(\(ICVC'93\))p Fo(,)c(T)-7 b(aejon,)24 b(K)m(orea,)f(No)o(v)o -(ember)h(1993.)p Black 448 986 a([12])p Black 47 w(S.-I.)29 -b(Minato.)55 b(Zero-suppressed)35 b(BDDs)28 b(for)j(set)f(manipulation) -j(in)d(combinatorial)645 1099 y(problems.)35 b(In)24 -b Fn(Pr)l(oceedings)i(of)e(the)g(Design)g(A)n(utomation)h(Confer)m -(ence)p Fo(,)g(pages)g(272\226)645 1212 y(277,)f(Dallas,)g(TX,)d(June)k -(1993.)p Black 448 1400 a([13])p Black 47 w(S.)38 b(P)o(anda)i(and)f(F) --7 b(.)38 b(Somenzi.)85 b(Who)39 b(are)h(the)f(v)n(ariables)j(in)d -(your)h(neighborhood.)645 1513 y(In)28 b Fn(Pr)l(oceedings)i(of)d(the)h -(International)j(Confer)m(ence)e(on)f(Computer)n(-Aided)i(Design)p -Fo(,)645 1626 y(pages)25 b(74\22677,)g(San)e(Jose,)h(CA,)d(No)o(v)o -(ember)j(1995.)p Black 448 1813 a([14])p Black 47 w(S.)41 -b(P)o(anda,)48 b(F)-7 b(.)40 b(Somenzi,)48 b(and)43 b(B.)e(F)-7 -b(.)41 b(Plessier)-5 b(.)96 b(Symmetry)43 b(detection)i(and)e(dy-)645 -1926 y(namic)31 b(v)n(ariable)i(ordering)f(of)f(decision)i(diagrams.)57 -b(In)30 b Fn(Pr)l(oceedings)k(of)c(the)h(Inter)n(-)645 -2039 y(national)h(Confer)m(ence)g(on)e(Computer)n(-Aided)i(Design)p -Fo(,)f(pages)g(628\226631,)j(San)29 b(Jose,)645 2152 -y(CA,)22 b(No)o(v)o(ember)i(1994.)p Black 448 2340 a([15])p -Black 47 w(B.)i(F)-7 b(.)25 b(Plessier)-5 b(.)46 b Fn(A)26 -b(Gener)o(al)i(F)-5 b(r)o(ame)o(work)27 b(for)g(V)-10 -b(eri\002cation)30 b(of)d(Sequential)j(Cir)m(cuits)p -Fo(.)645 2452 y(PhD)24 b(thesis,)i(Uni)n(v)o(ersity)h(of)e(Colorado)h -(at)f(Boulder)l(,)i(Dept.)d(of)h(Electrical)i(and)e(Com-)645 -2565 y(puter)g(Engineering,)h(1993.)p Black 448 2753 -a([16])p Black 47 w(R.)e(Rudell.)41 b(Dynamic)25 b(v)n(ariable)j -(ordering)f(for)f(ordered)h(binary)g(decision)h(diagrams.)645 -2866 y(In)g Fn(Pr)l(oceedings)i(of)d(the)h(International)j(Confer)m -(ence)e(on)f(Computer)n(-Aided)i(Design)p Fo(,)645 2979 -y(pages)25 b(42\22647,)g(Santa)e(Clara,)h(CA,)d(No)o(v)o(ember)j(1993.) -p Black 448 3166 a([17])p Black 47 w(E.)43 b(M.)f(Sento)o(vich,)51 -b(K.)42 b(J.)i(Singh,)49 b(C.)42 b(Moon,)50 b(H.)42 b(Sa)n(v)n(oj,)50 -b(R.)42 b(K.)h(Brayton,)50 b(and)645 3279 y(A.)35 b(Sangio)o(v)n -(anni-V)-5 b(incentelli.)79 b(Sequential)38 b(circuit)g(design)g(using) -f(synthesis)i(and)645 3392 y(optimization.)55 b(In)29 -b Fn(Pr)l(oceedings)j(of)e(the)f(International)34 b(Confer)m(ence)d(on) -e(Computer)645 3505 y(Design)p Fo(,)24 b(pages)h(328\226333,)h -(Cambridge,)e(MA,)e(October)i(1992.)p Black 1897 5225 -a(43)p Black eop end -%%Page: 44 44 -TeXDict begin 44 43 bop Black Black Black 448 705 a Fq(Index)p -Black 448 892 a Fo(ADD,)22 b(4,)h(7,)f(11,)i(13)448 1005 -y(aggre)o(gation,)i(18)448 1118 y(Algebraic)f(Decision)g(Diagram,)f -Fn(see)g Fo(ADD)448 1231 y(arc)614 1344 y(complement,)h(11,)f(25,)f(28) -614 1457 y(re)o(gular)l(,)i(25,)f(28)448 1653 y(background)j(v)n(alue,) -d(10)448 1766 y(BDD,)e(4,)h(7,)f(10,)i(12)448 1878 y(Binary)g(Decision) -h(Diagram,)f Fn(see)g Fo(BDD)448 1991 y(box)614 2104 -y(black,)h(4)614 2217 y(clear)l(,)g(4,)e(24)448 2413 -y(cache,)i(8,)e(28,)g(29)614 2526 y(collision,)j(35)614 -2639 y(collision)g(list,)e(31)614 2752 y(deletion,)i(35)614 -2865 y(local,)f(29,)e(30)614 2978 y(lossless,)j(30)614 -3091 y(re)n(w)o(ard-based)h(resizing,)e(30)614 3204 y(sizing,)g(29)448 -3316 y(cacheSize,)g(8)448 3429 y(canonical,)h(7,)d(30)448 -3542 y(compiling,)i(6,)e(10,)h(24)448 3655 y(con\002guration,)j(5)448 -3768 y(con)l(v)o(ersion)614 3881 y(of)d(ADDs)e(to)h(BDDs,)f(15)614 -3994 y(of)i(BDDs)e(to)h(ADDs,)f(15)614 4107 y(of)i(BDDs)e(to)h(ZDDs,)f -(14,)h(15)614 4220 y(of)h(ZDDs)e(to)h(BDDs,)f(15)448 -4333 y(cube)j(sets,)e(4)448 4446 y(cudd.h,)i(6,)e(17,)g(28)448 -4558 y Fn(Cudd)p 649 4558 28 4 v 34 w(addApply)p Fo(,)i(13,)e(14)448 -4671 y Fn(Cudd)p 649 4671 V 34 w(addBddInterval)p Fo(,)k(15)448 -4784 y Fn(Cudd)p 649 4784 V 34 w(addBddP)-7 b(attern)p -Fo(,)26 b(15)448 4897 y Fn(Cudd)p 649 4897 V 34 w(addBddThr)m(eshold)p -Fo(,)h(15)p Black Black 1984 892 a Fn(Cudd)p 2185 892 -V 34 w(addConst)p Fo(,)e(11)1984 1005 y Fn(Cudd)p 2185 -1005 V 34 w(addHarwell)p Fo(,)g(11)1984 1118 y Fn(Cudd)p -2185 1118 V 34 w(AddHook)p Fo(,)f(22)1984 1231 y Fn(Cudd)p -2185 1231 V 34 w(addIthBit)p Fo(,)h(15)1984 1344 y Fn(Cudd)p -2185 1344 V 34 w(addIthV)-10 b(ar)p Fo(,)25 b(11)1984 -1457 y Fn(Cudd)p 2185 1457 V 34 w(addNe)o(wV)-10 b(ar)p -Fo(,)23 b(11)1984 1570 y Fn(Cudd)p 2185 1570 V 34 w(addNe)o(wV)-10 -b(arAtLe)o(vel)p Fo(,)24 b(11,)f(20)1984 1683 y Fn(Cudd)p -2185 1683 V 34 w(addRead)p Fo(,)i(11)1984 1795 y Fn(Cudd)p -2185 1795 V 34 w(addT)-5 b(imes)p Fo(,)24 b(14)1984 1908 -y Fn(Cudd)p 2185 1908 V 34 w(A)n(utodynDisable)p Fo(,)i(17)1984 -2021 y Fn(Cudd)p 2185 2021 V 34 w(A)n(utodynDisableZdd)p -Fo(,)h(20)1984 2134 y Fn(Cudd)p 2185 2134 V 34 w(A)n(utodynEnable)p -Fo(,)f(17)1984 2247 y Fn(Cudd)p 2185 2247 V 34 w(A)n(utodynEnableZdd)p -Fo(,)h(20)1984 2360 y Fn(Cudd)p 2185 2360 V 34 w(bddAnd)p -Fo(,)d(12\22614)1984 2473 y Fn(Cudd)p 2185 2473 V 34 -w(bddAndLimit)p Fo(,)g(22)1984 2586 y Fn(Cudd)p 2185 -2586 V 34 w(bddConstr)o(ain)p Fo(,)i(7)1984 2699 y Fn(Cudd)p -2185 2699 V 34 w(bddIte)p Fo(,)f(12)1984 2812 y Fn(Cudd)p -2185 2812 V 34 w(bddIthV)-10 b(ar)p Fo(,)25 b(11)1984 -2925 y Fn(Cudd)p 2185 2925 V 34 w(bddNe)o(wV)-10 b(ar)p -Fo(,)23 b(11)1984 3037 y Fn(Cudd)p 2185 3037 V 34 w(bddNe)o(wV)-10 -b(arAtLe)o(vel)p Fo(,)24 b(11,)f(20)1984 3150 y Fn(Cudd)p -2185 3150 V 34 w(BddT)-8 b(oAdd)p Fo(,)23 b(15)1984 3263 -y Fn(Cudd)p 2185 3263 V 34 w(bddXor)p Fo(,)h(14)1984 -3376 y(CUDD)p 2248 3376 V 31 w(CA)l(CHE)p 2585 3376 V -32 w(SLO)l(TS,)c(8)1984 3489 y Fn(Cudd)p 2185 3489 V -34 w(Chec)n(kK)m(e)m(ys)p Fo(,)25 b(33)1984 3602 y Fn(Cudd)p -2185 3602 V 34 w(Chec)n(kZer)l(oRef)p Fo(,)g(34)1984 -3715 y Fn(Cudd)p 2185 3715 V 34 w(CountMinterm)p Fo(,)g(11)1984 -3828 y Fn(Cudd)p 2185 3828 V 34 w(Deb)n(ugChec)n(k)p -Fo(,)g(33)1984 3941 y Fn(Cudd)p 2185 3941 V 34 w(DelayedDer)m(efBdd)p -Fo(,)g(36)1984 4054 y Fn(Cudd)p 2185 4054 V 34 w(Der)m(ef)p -Fo(,)e(27,)g(28)1984 4167 y Fn(Cudd)p 2185 4167 V 34 -w(DumpBlif)p Fo(,)g(24)1984 4279 y Fn(Cudd)p 2185 4279 -V 34 w(DumpDaV)-7 b(inci)p Fo(,)24 b(24)1984 4392 y Fn(Cudd)p -2185 4392 V 34 w(DumpDot)p Fo(,)f(24)1984 4505 y Fn(Cudd)p -2185 4505 V 34 w(F)-10 b(or)m(eac)o(hCube)p Fo(,)25 b(6,)e(11)1984 -4618 y Fn(Cudd)p 2185 4618 V 34 w(F)-10 b(or)m(eac)o(hNode)p -Fo(,)25 b(6)1984 4731 y Fn(Cudd)p 2185 4731 V 34 w(HookT)-7 -b(ype)p Fo(,)24 b(21)1984 4844 y Fn(Cudd)p 2185 4844 -V 34 w(Init)p Fo(,)g(8,)f(9)1984 4957 y Fn(Cudd)p 2185 -4957 V 34 w(Mak)o(eT)-5 b(r)m(eeNode)p Fo(,)25 b(19,)e(20)p -Black 1897 5225 a(44)p Black eop end -%%Page: 45 45 -TeXDict begin 45 44 bop Black Black 448 573 a Fn(Cudd)p -649 573 28 4 v 34 w(Mak)o(eZddT)-5 b(r)m(eeNode)p Fo(,)25 -b(21)448 686 y Fn(Cudd)p 649 686 V 34 w(Not)p Fo(,)e(10)448 -799 y Fn(Cudd)p 649 799 V 34 w(PrintInfo)p Fo(,)i(34)448 -912 y Fn(Cudd)p 649 912 V 34 w(PrintMinterm)p Fo(,)f(11)448 -1024 y Fn(Cudd)p 649 1024 V 34 w(Quit)p Fo(,)f(9)448 -1137 y Fn(Cudd)p 649 1137 V 34 w(ReadBac)n(kgr)l(ound)p -Fo(,)k(10)448 1250 y Fn(Cudd)p 649 1250 V 34 w(ReadEpsilon)p -Fo(,)e(10)448 1363 y Fn(Cudd)p 649 1363 V 34 w(ReadErr)l(orCode)p -Fo(,)g(27)448 1476 y Fn(Cudd)p 649 1476 V 34 w(ReadIn)l(vP)-7 -b(erm)p Fo(,)24 b(13)448 1589 y Fn(Cudd)p 649 1589 V -34 w(ReadLo)o(gicZer)l(o)p Fo(,)h(10)448 1702 y Fn(Cudd)p -649 1702 V 34 w(ReadLooseUpto)p Fo(,)g(9)448 1815 y Fn(Cudd)p -649 1815 V 34 w(ReadMaxGr)l(owth)p Fo(,)g(18)448 1928 -y Fn(Cudd)p 649 1928 V 34 w(ReadMinusIn\002nity)p Fo(,)i(10)448 -2041 y Fn(Cudd)p 649 2041 V 34 w(ReadOne)p Fo(,)d(9)448 -2154 y Fn(Cudd)p 649 2154 V 34 w(ReadPlusIn\002nity)p -Fo(,)i(10)448 2267 y Fn(Cudd)p 649 2267 V 34 w(ReadReor)m(derings)p -Fo(,)g(33)448 2379 y Fn(Cudd)p 649 2379 V 34 w(ReadSiftMaxV)-10 -b(ar)p Fo(,)25 b(18)448 2492 y Fn(Cudd)p 649 2492 V 34 -w(ReadT)-5 b(r)m(ee)p Fo(,)24 b(19)448 2605 y Fn(Cudd)p -649 2605 V 34 w(ReadZddOne)p Fo(,)g(9,)f(15)448 2718 -y Fn(Cudd)p 649 2718 V 34 w(ReadZer)l(o)p Fo(,)h(10)448 -2831 y Fn(Cudd)p 649 2831 V 34 w(Recur)o(siveDer)m(ef)p -Fo(,)i(7,)d(26\22628,)h(30,)g(33)448 2944 y Fn(Cudd)p -649 2944 V 34 w(Recur)o(siveDer)m(efZdd)p Fo(,)i(7,)d(26\22628)448 -3057 y Fn(Cudd)p 649 3057 V 34 w(ReduceHeap)p Fo(,)i(17)448 -3170 y Fn(Cudd)p 649 3170 V 34 w(Ref)p Fo(,)e(7,)g(12,)g(26,)g(27)448 -3283 y Fn(Cudd)p 649 3283 V 34 w(Re)l(gular)p Fo(,)i(28)448 -3396 y(CUDD)p 712 3396 V 32 w(REORDER)p 1171 3396 V 30 -w(ANNEALING,)19 b(19)448 3509 y(CUDD)p 712 3509 V 32 -w(REORDER)p 1171 3509 V 30 w(EXA)l(CT)-7 b(,)21 b(19)448 -3621 y(CUDD)p 712 3621 V 32 w(REORDER)p 1171 3621 V 30 -w(GENETIC,)f(19)448 3734 y(CUDD)p 712 3734 V 32 w(REORDER)p -1171 3734 V 30 w(GR)l(OUP)p 1507 3734 V 31 w(SIFT)-7 -b(,)21 b(18)448 3847 y(CUDD)p 712 3847 V 32 w(REORDER)p -1171 3847 V 30 w(GR)l(OUP)p 1507 3847 V 31 w(SIFT)p 1726 -3847 V 31 w(CONV)-12 b(,)780 3960 y(18)448 4073 y(CUDD)p -712 4073 V 32 w(REORDER)p 1171 4073 V 30 w(NONE,)20 b(17,)k(20)448 -4186 y(CUDD)p 712 4186 V 32 w(REORDER)p 1171 4186 V 30 -w(RANDOM,)c(17,)j(20)448 4299 y(CUDD)p 712 4299 V 32 -w(REORDER)p 1171 4299 V 30 w(RANDOM)p 1607 4299 V 30 -w(PIV)l(O)l(T)-7 b(,)780 4412 y(17,)24 b(20)448 4525 -y(CUDD)p 712 4525 V 32 w(REORDER)p 1171 4525 V 30 w(SAME,)d(17,)i(20) -448 4638 y(CUDD)p 712 4638 V 32 w(REORDER)p 1171 4638 -V 30 w(SIFT)-7 b(,)21 b(17,)j(21)448 4751 y(CUDD)p 712 -4751 V 32 w(REORDER)p 1171 4751 V 30 w(SIFT)p 1389 4751 -V 31 w(CONVERGE,)780 4863 y(18,)g(21)448 4976 y(CUDD)p -712 4976 V 32 w(REORDER)p 1171 4976 V 30 w(SYMM)p 1480 -4976 V 31 w(SIFT)-7 b(,)16 b(18,)j(21)p Black Black 1984 -573 a(CUDD)p 2248 573 V 31 w(REORDER)p 2706 573 V 30 -w(SYMM)p 3015 573 V 32 w(SIFT)p 3235 573 V 32 w(CONV)-12 -b(,)2316 686 y(18,)24 b(21)1984 799 y(CUDD)p 2248 799 -V 31 w(REORDER)p 2706 799 V 30 w(WINDO)m(W2,)e(18)1984 -912 y(CUDD)p 2248 912 V 31 w(REORDER)p 2706 912 V 30 -w(WINDO)m(W2)p 3178 912 V 32 w(CONV)-12 b(,)2316 1024 -y(18)1984 1137 y(CUDD)p 2248 1137 V 31 w(REORDER)p 2706 -1137 V 30 w(WINDO)m(W3,)22 b(18)1984 1250 y(CUDD)p 2248 -1250 V 31 w(REORDER)p 2706 1250 V 30 w(WINDO)m(W3)p 3178 -1250 V 32 w(CONV)-12 b(,)2316 1363 y(18)1984 1476 y(CUDD)p -2248 1476 V 31 w(REORDER)p 2706 1476 V 30 w(WINDO)m(W4,)22 -b(18)1984 1589 y(CUDD)p 2248 1589 V 31 w(REORDER)p 2706 -1589 V 30 w(WINDO)m(W4)p 3178 1589 V 32 w(CONV)-12 b(,)2316 -1702 y(19)1984 1815 y Fn(Cudd)p 2185 1815 V 34 w(SetEpsilon)p -Fo(,)25 b(10)1984 1928 y Fn(Cudd)p 2185 1928 V 34 w(SetLooseUpT)-8 -b(o)p Fo(,)24 b(9)1984 2041 y Fn(Cudd)p 2185 2041 V 34 -w(SetMaxCac)o(heHar)m(d)p Fo(,)h(37)1984 2154 y Fn(Cudd)p -2185 2154 V 34 w(SetMaxGr)l(owth)p Fo(,)g(18)1984 2267 -y Fn(Cudd)p 2185 2267 V 34 w(SetSiftMaxV)-10 b(ar)p Fo(,)26 -b(18)1984 2379 y Fn(Cudd)p 2185 2379 V 34 w(SetT)-5 b(imeLimit)p -Fo(,)23 b(22)1984 2492 y Fn(Cudd)p 2185 2492 V 34 w(SetT)-5 -b(r)m(ee)p Fo(,)24 b(19)1984 2605 y Fn(Cudd)p 2185 2605 -V 34 w(Shuf)n(\003eHeap)p Fo(,)i(19)1984 2718 y Fn(Cudd)p -2185 2718 V 34 w(StdP)-7 b(ostReor)m(dHook)p Fo(,)26 -b(22)1984 2831 y Fn(Cudd)p 2185 2831 V 34 w(StdPr)m(eReor)m(dHook)p -Fo(,)f(22)1984 2944 y Fn(Cudd)p 2185 2944 V 34 w(SymmPr)l(o\002le)p -Fo(,)f(18)1984 3057 y(CUDD)p 2248 3057 V 31 w(UNIQ)o(UE)p -2628 3057 V 32 w(SLO)l(TS,)c(8)1984 3170 y Fn(Cudd)p -2185 3170 V 34 w(zddDumpDot)p Fo(,)k(24)1984 3283 y Fn(Cudd)p -2185 3283 V 34 w(zddIsop)p Fo(,)h(15)1984 3396 y Fn(Cudd)p -2185 3396 V 34 w(zddIthV)-10 b(ar)p Fo(,)25 b(12)1984 -3509 y Fn(Cudd)p 2185 3509 V 34 w(zddP)-7 b(ortF)i(r)l(omBdd)p -Fo(,)24 b(16)1984 3621 y Fn(Cudd)p 2185 3621 V 34 w(zddP)-7 -b(ortT)f(oBdd)p Fo(,)24 b(16)1984 3734 y Fn(Cudd)p 2185 -3734 V 34 w(zddRealignDisable)p Fo(,)j(21)1984 3847 y -Fn(Cudd)p 2185 3847 V 34 w(zddRealignEnable)p Fo(,)g(21)1984 -3960 y Fn(Cudd)p 2185 3960 V 34 w(zddReduceHeap)p Fo(,)f(20)1984 -4073 y Fn(Cudd)p 2185 4073 V 34 w(zddShuf)n(\003eHeap)p -Fo(,)h(20)1984 4186 y Fn(Cudd)p 2185 4186 V 34 w(zddV)-10 -b(ar)o(sF)-5 b(r)l(omBddV)-10 b(ar)o(s)p Fo(,)25 b(16)1984 -4299 y Fn(Cudd)p 2185 4299 V 34 w(zddW)-8 b(eakDiv)p -Fo(,)24 b(15)1984 4412 y Fn(cuddCac)o(heInsert)p Fo(,)j(29)1984 -4525 y Fn(cuddCac)o(heInsert1)p Fo(,)h(29)1984 4638 y -Fn(cuddCac)o(heInsert2)p Fo(,)g(29)1984 4751 y Fn(cuddCac)o(heLookup)p -Fo(,)f(29)1984 4863 y Fn(cuddCac)o(heLookup1)p Fo(,)g(29)1984 -4976 y Fn(cuddCac)o(heLookup2)p Fo(,)g(29)p Black 1897 -5225 a(45)p Black eop end -%%Page: 46 46 -TeXDict begin 46 45 bop Black Black 448 573 a Fo(CUDDDIR,)21 -b(22)448 686 y Fn(cuddHeapPr)l(o\002le)p Fo(,)27 b(33)448 -799 y Fn(cuddI)p Fo(,)e(31)448 912 y(cuddInt.h,)h(33)448 -1024 y Fn(cuddIZ)p Fo(,)e(31)448 1137 y Fn(cuddSatDec)p -Fo(,)i(28)448 1250 y Fn(cuddSatInc)p Fo(,)h(28)448 1363 -y Fn(cuddUniqueConst)p Fo(,)g(26)448 1476 y Fn(cuddUniqueInter)p -Fo(,)h(26,)23 b(28,)h(32,)f(33)448 1589 y Fn(cuddUniqueInterZdd)p -Fo(,)28 b(26,)c(32)448 1777 y(DD)p 585 1777 28 4 v 32 -w(CA)l(CHE)p 923 1777 V 31 w(PR)l(OFILE,)d(39)448 1890 -y(DD)p 585 1890 V 32 w(DEB)o(UG,)g(33)448 2003 y(DD)p -585 2003 V 32 w(ST)-8 b(A)e(TS,)20 b(39)448 2116 y(DD)p -585 2116 V 32 w(UNIQ)o(UE)p 966 2116 V 31 w(PR)l(OFILE,)h(39)448 -2229 y(DD)p 585 2229 V 32 w(VERBOSE,)f(39)448 2342 y(DdManager)l(,)25 -b(7,)e(8)448 2455 y(DdNode,)h(6,)f(29)448 2568 y(deb)n(ugging,)k(33)448 -2681 y(DEC)22 b(Alpha,)h(23)448 2793 y(DEC)f(Alpha,)h(10)448 -2906 y(documentation,)k(39)614 3019 y Fn(Description)p -Fo(,)f(40)614 3132 y(HTML)c(\002les,)h(40)614 3245 y -Fn(SeeAlso)p Fo(,)i(40)614 3358 y Fn(Synopsis)p Fo(,)h(40)448 -3471 y(dot,)e Fn(see)g Fo(graph,)g(dra)o(wing)448 3659 -y(Epsilon,)h(10)448 3772 y(e)o(xtdoc,)g Fn(see)f Fo(documentation)448 -3960 y(\003oating)h(point,)f(10)614 4073 y(double)i(\(C)c(type\),)i(7) -614 4186 y(IEEE)e(Standard)j(754,)f(10)448 4299 y(free)g(list,)g(26)448 -4412 y(FTP)-10 b(,)21 b(5,)i(23,)h(39)448 4525 y(function)614 -4638 y(characteristic,)j(4,)c(16)614 4751 y(co)o(v)o(er)l(,)h(15,)g(16) -697 4863 y(irredundant,)j(15)614 4976 y(minterms,)d(11,)g(32)p -Black Black 2150 573 a(ON-set,)f(4)2150 686 y(sum)h(of)f(products,)j -(11)2150 799 y(switching,)f(4)1984 995 y(garbage)g(collection,)h -(7\2269,)e(26,)f(29\22631)2150 1108 y(hooks,)i(21)1984 -1220 y(gcc,)f(10)1984 1333 y(generator)l(,)i(6)1984 1446 -y(global)f(v)n(ariables,)h(7)1984 1559 y(graph)2150 1672 -y(arc)e(capacity)-6 b(,)25 b(10)2150 1785 y(arc)f(length,)h(10)2150 -1898 y(dra)o(wing,)f(24)1984 2011 y(gro)n(wth,)g(9)1984 -2124 y(gzip,)g(5)1984 2320 y(HA)-12 b(VE)p 2231 2320 -V 31 w(IEEE)p 2460 2320 V 32 w(754,)24 b(10)1984 2433 -y(header)h(\002les,)e(17,)h(28)1984 2545 y(hook,)g(21)1984 -2741 y(in\002nities,)h(10)1984 2854 y(installation,)i(5)1984 -2967 y(Intel)e(Pentium)e(4,)g(5)1984 3080 y(interf)o(ace)2150 -3193 y(cache,)i(29)2150 3306 y(SIS,)d(22)2150 3419 y(VIS,)g(22)1984 -3615 y(libraries,)k(5)2150 3728 y(cudd,)e(6)2150 3841 -y(dddmp,)g(24)2150 3954 y(mtr)l(,)f(6,)g(19)2150 4066 -y(obj,)h(40)2150 4179 y(st,)f(6,)g(29)2150 4292 y(util,)h(6)1984 -4488 y(Mak)o(e\002le,)g(6,)f(10,)g(40)1984 4601 y(manager)l(,)i(7,)e(9) -1984 4714 y(matrix)2150 4827 y(sparse,)i(10)1984 4940 -y(maxCache,)f(30)p Black 1897 5225 a(46)p Black eop end -%%Page: 47 47 -TeXDict begin 47 46 bop Black Black 448 573 a Fo(maxMemory)-6 -b(,)24 b(8)448 686 y(MinusIn\002nity)-6 b(,)26 b(10)448 -799 y(MTR)p 651 799 28 4 v 32 w(DEF)-7 b(A)i(UL)d(T)h(,)20 -b(20)448 912 y(MTR)p 651 912 V 32 w(FIXED,)h(19)448 1100 -y(nanotra)n(v)-6 b(,)26 b(5)448 1213 y(node,)e(6)614 -1326 y(constant,)i(6,)d(9\22611,)h(26,)f(27)697 1438 -y(v)n(alue,)h(7)614 1551 y(dead,)g(26,)g(29,)f(31)614 -1664 y(dereference,)k(14)614 1777 y(reclaimed,)e(31)614 -1890 y(rec)o(ycling,)h(7)614 2003 y(reference,)g(14)614 -2116 y(reference)g(count,)f(26)614 2229 y(reference)c(count,)f(6,)f(7,) -g(12,)g(13,)g(26\22630,)780 2342 y(34)697 2455 y(saturated,)26 -b(34)614 2568 y(terminal,)f Fn(see)f Fo(node,)g(constant)614 -2681 y(v)n(ariable)i(inde)o(x,)e(6)448 2793 y(numSlots,)g(8)448 -2906 y(numV)-10 b(ars,)24 b(8)448 3019 y(numV)-10 b(arsZ,)23 -b(8)448 3207 y(PlusIn\002nity)-6 b(,)25 b(10)448 3320 -y(projection)i(functions,)e(11,)f(12,)f(14,)h(15,)f(34)448 -3509 y(README)e(\002le,)h(5)448 3621 y(reordering,)k(4,)d(6,)g(29)614 -3734 y(abort)i(and)f(retry)-6 b(,)24 b(32)614 3847 y(asynchronous,)k -(17,)23 b(32)614 3960 y(con)l(v)o(er)n(ging,)k(17,)d(18)614 -4073 y(Cudd)p 815 4073 V 34 w(ReorderingT)-7 b(ype,)26 -b(17)614 4186 y(dynamic,)f(4,)e(16,)g(20)614 4299 y(e)o(xact,)h(19)614 -4412 y(function)i(wrapper)l(,)f(32,)e(33)614 4525 y(genetic,)i(19)614 -4638 y(group,)g(17,)e(18)614 4751 y(hooks,)i(21)614 4863 -y(interruptible)j(procedure,)d(32)614 4976 y(of)f(BDDs)e(and)i(ADDs,)e -(16)p Black Black 2150 573 a(of)i(ZDDs,)d(15,)j(20)2150 -686 y(random,)g(17)2150 799 y(sifting,)h(17)2150 912 -y(simulated)h(annealing,)f(19)2150 1024 y(symmetric,)g(18)2150 -1137 y(threshold,)h(17,)d(32)2150 1250 y(windo)n(w)-6 -b(,)23 b(18)1984 1446 y(saturating)2150 1559 y(decrements,)j(28)2150 -1672 y(increments,)g(28)1984 1785 y(SISDIR,)c(22)1984 -1898 y(SIZEOF)p 2299 1898 V 31 w(INT)-7 b(,)22 b(28)1984 -2011 y(SIZEOF)p 2299 2011 V 31 w(V)l(OID)p 2554 2011 -V 32 w(P)-10 b(,)22 b(28)1984 2124 y(statistical)k(counters,)g(7,)d(30) -1984 2237 y(statistical)j(counters,)g(26)1984 2350 y(statistics,)g(34) -1984 2462 y(subtable,)g(8,)d(26)1984 2575 y(symmetry)-6 -b(,)24 b(18)1984 2771 y(table)2150 2884 y(computed,)h(8)2150 -2997 y(gro)n(wth,)f(9)2150 3110 y(hash,)g(7,)f(31)2150 -3223 y(unique,)i(6\2269,)f(16,)f(26,)h(30,)f(31)2233 -3336 y(f)o(ast)h(gro)n(wth,)g(31)2233 3449 y(re)n(w)o(ard-based)i -(resizing,)g(31)2233 3562 y(slo)n(w)d(gro)n(wth,)h(32)1984 -3675 y(timeout,)g(22)1984 3870 y(v)n(ariable)2150 3983 -y(groups,)h(19)2150 4096 y(order)l(,)g(6,)e(11)2150 4209 -y(permutation,)j(6,)d(31)2150 4322 y(tree,)h(19,)f(20)1984 -4518 y(ZDD,)e(4,)i(7,)g(12,)h(14,)f(15)1984 4631 y(zero)2150 -4744 y(arithmetic,)i(9,)e(11,)h(15)2150 4857 y(logical,)h(9,)e(15)p -Black 1897 5225 a(47)p Black eop end -%%Page: 48 48 -TeXDict begin 48 47 bop Black Black 448 573 a Fo(Zero-suppressed)22 -b(Binary)d(Decision)h(Diagram,)780 686 y Fn(see)k Fo(ZDD)p -Black Black Black 1897 5225 a(48)p Black eop end -%%Trailer - -userdict /end-hook known{end-hook}if -%%EOF diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllAbs.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllAbs.html deleted file mode 100644 index 969b6e6cc..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllAbs.html +++ /dev/null @@ -1,3114 +0,0 @@ -<HTML> -<HEAD><TITLE>cudd package abstract</TITLE></HEAD> -<BODY> - - -<!-- Function Abstracts --> - -<dl> -<DT> <A HREF="cuddAllDet.html#AssessPathLength" TARGET="MAIN"><CODE>AssessPathLength()</CODE></A> -<DD> Chooses the maximum allowable path length of nodes under the - threshold. - -<DT> <A HREF="cuddAllDet.html#BAapplyBias" TARGET="MAIN"><CODE>BAapplyBias()</CODE></A> -<DD> Finds don't care nodes. - -<DT> <A HREF="cuddAllDet.html#BAmarkNodes" TARGET="MAIN"><CODE>BAmarkNodes()</CODE></A> -<DD> Marks nodes for remapping. - -<DT> <A HREF="cuddAllDet.html#BuildConjuncts" TARGET="MAIN"><CODE>BuildConjuncts()</CODE></A> -<DD> Builds the conjuncts recursively, bottom up. - -<DT> <A HREF="cuddAllDet.html#BuildSubsetBdd" TARGET="MAIN"><CODE>BuildSubsetBdd()</CODE></A> -<DD> Builds the BDD with nodes labeled with path length less than or equal to maxpath - -<DT> <A HREF="cuddAllDet.html#BuildSubsetBdd" TARGET="MAIN"><CODE>BuildSubsetBdd()</CODE></A> -<DD> Builds the subset BDD using the heavy branch method. - -<DT> <A HREF="cuddAllDet.html#CheckInTables" TARGET="MAIN"><CODE>CheckInTables()</CODE></A> -<DD> Check if the two pairs exist in the table, If any of the - conjuncts do exist, store in the cache and return the corresponding pair. - -<DT> <A HREF="cuddAllDet.html#CheckTablesCacheAndReturn" TARGET="MAIN"><CODE>CheckTablesCacheAndReturn()</CODE></A> -<DD> Check the tables for the existence of pair and return one - combination, cache the result. - -<DT> <A HREF="cuddAllDet.html#ConjunctsFree" TARGET="MAIN"><CODE>ConjunctsFree()</CODE></A> -<DD> Free factors structure - -<DT> <A HREF="cuddAllDet.html#CorrelCleanUp" TARGET="MAIN"><CODE>CorrelCleanUp()</CODE></A> -<DD> Frees memory associated with hash table. - -<DT> <A HREF="cuddAllDet.html#CorrelCompare" TARGET="MAIN"><CODE>CorrelCompare()</CODE></A> -<DD> Compares two hash table entries. - -<DT> <A HREF="cuddAllDet.html#CorrelHash" TARGET="MAIN"><CODE>CorrelHash()</CODE></A> -<DD> Hashes a hash table entry. - -<DT> <A HREF="cuddAllDet.html#CountMinterms" TARGET="MAIN"><CODE>CountMinterms()</CODE></A> -<DD> Count the number of minterms of each node ina a BDD and - store it in a hash table. - -<DT> <A HREF="cuddAllDet.html#CreateBotDist" TARGET="MAIN"><CODE>CreateBotDist()</CODE></A> -<DD> Get longest distance of node from constant. - -<DT> <A HREF="cuddAllDet.html#CreateBotDist" TARGET="MAIN"><CODE>CreateBotDist()</CODE></A> -<DD> Labels each node with the shortest distance from the constant. - -<DT> <A HREF="cuddAllDet.html#CreatePathTable" TARGET="MAIN"><CODE>CreatePathTable()</CODE></A> -<DD> The outer procedure to label each node with its shortest - distance from the root and constant - -<DT> <A HREF="cuddAllDet.html#CreateTopDist" TARGET="MAIN"><CODE>CreateTopDist()</CODE></A> -<DD> Labels each node with its shortest distance from the root - -<DT> <A HREF="cuddAllDet.html#Cudd_AddHook" TARGET="MAIN"><CODE>Cudd_AddHook()</CODE></A> -<DD> Adds a function to a hook. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaAdd" TARGET="MAIN"><CODE>Cudd_ApaAdd()</CODE></A> -<DD> Adds two arbitrary precision integers. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaCompareRatios" TARGET="MAIN"><CODE>Cudd_ApaCompareRatios()</CODE></A> -<DD> Compares the ratios of two arbitrary precision integers to two - unsigned ints. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaCompare" TARGET="MAIN"><CODE>Cudd_ApaCompare()</CODE></A> -<DD> Compares two arbitrary precision integers. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaCopy" TARGET="MAIN"><CODE>Cudd_ApaCopy()</CODE></A> -<DD> Makes a copy of an arbitrary precision integer. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaCountMinterm" TARGET="MAIN"><CODE>Cudd_ApaCountMinterm()</CODE></A> -<DD> Counts the number of minterms of a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaIntDivision" TARGET="MAIN"><CODE>Cudd_ApaIntDivision()</CODE></A> -<DD> Divides an arbitrary precision integer by an integer. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaNumberOfDigits" TARGET="MAIN"><CODE>Cudd_ApaNumberOfDigits()</CODE></A> -<DD> Finds the number of digits for an arbitrary precision - integer. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaPowerOfTwo" TARGET="MAIN"><CODE>Cudd_ApaPowerOfTwo()</CODE></A> -<DD> Sets an arbitrary precision integer to a power of two. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintDecimal" TARGET="MAIN"><CODE>Cudd_ApaPrintDecimal()</CODE></A> -<DD> Prints an arbitrary precision integer in decimal format. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintDensity" TARGET="MAIN"><CODE>Cudd_ApaPrintDensity()</CODE></A> -<DD> Prints the density of a BDD or ADD using - arbitrary precision arithmetic. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintExponential" TARGET="MAIN"><CODE>Cudd_ApaPrintExponential()</CODE></A> -<DD> Prints an arbitrary precision integer in exponential format. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintHex" TARGET="MAIN"><CODE>Cudd_ApaPrintHex()</CODE></A> -<DD> Prints an arbitrary precision integer in hexadecimal format. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintMintermExp" TARGET="MAIN"><CODE>Cudd_ApaPrintMintermExp()</CODE></A> -<DD> Prints the number of minterms of a BDD or ADD in exponential - format using arbitrary precision arithmetic. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintMinterm" TARGET="MAIN"><CODE>Cudd_ApaPrintMinterm()</CODE></A> -<DD> Prints the number of minterms of a BDD or ADD using - arbitrary precision arithmetic. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaSetToLiteral" TARGET="MAIN"><CODE>Cudd_ApaSetToLiteral()</CODE></A> -<DD> Sets an arbitrary precision integer to a one-digit literal. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaShiftRight" TARGET="MAIN"><CODE>Cudd_ApaShiftRight()</CODE></A> -<DD> Shifts right an arbitrary precision integer by one binary - place. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaShortDivision" TARGET="MAIN"><CODE>Cudd_ApaShortDivision()</CODE></A> -<DD> Divides an arbitrary precision integer by a digit. - -<DT> <A HREF="cuddAllDet.html#Cudd_ApaSubtract" TARGET="MAIN"><CODE>Cudd_ApaSubtract()</CODE></A> -<DD> Subtracts two arbitrary precision integers. - -<DT> <A HREF="cuddAllDet.html#Cudd_AutodynDisableZdd" TARGET="MAIN"><CODE>Cudd_AutodynDisableZdd()</CODE></A> -<DD> Disables automatic dynamic reordering of ZDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_AutodynDisable" TARGET="MAIN"><CODE>Cudd_AutodynDisable()</CODE></A> -<DD> Disables automatic dynamic reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_AutodynEnableZdd" TARGET="MAIN"><CODE>Cudd_AutodynEnableZdd()</CODE></A> -<DD> Enables automatic dynamic reordering of ZDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_AutodynEnable" TARGET="MAIN"><CODE>Cudd_AutodynEnable()</CODE></A> -<DD> Enables automatic dynamic reordering of BDDs and ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_AverageDistance" TARGET="MAIN"><CODE>Cudd_AverageDistance()</CODE></A> -<DD> Computes the average distance between adjacent nodes. - -<DT> <A HREF="cuddAllDet.html#Cudd_BddToAdd" TARGET="MAIN"><CODE>Cudd_BddToAdd()</CODE></A> -<DD> Converts a BDD to a 0-1 ADD. - -<DT> <A HREF="cuddAllDet.html#Cudd_BddToCubeArray" TARGET="MAIN"><CODE>Cudd_BddToCubeArray()</CODE></A> -<DD> Builds a positional array from the BDD of a cube. - -<DT> <A HREF="cuddAllDet.html#Cudd_BiasedOverApprox" TARGET="MAIN"><CODE>Cudd_BiasedOverApprox()</CODE></A> -<DD> Extracts a dense superset from a BDD with the biased - underapproximation method. - -<DT> <A HREF="cuddAllDet.html#Cudd_BiasedUnderApprox" TARGET="MAIN"><CODE>Cudd_BiasedUnderApprox()</CODE></A> -<DD> Extracts a dense subset from a BDD with the biased - underapproximation method. - -<DT> <A HREF="cuddAllDet.html#Cudd_CProjection" TARGET="MAIN"><CODE>Cudd_CProjection()</CODE></A> -<DD> Computes the compatible projection of R w.r.t. cube Y. - -<DT> <A HREF="cuddAllDet.html#Cudd_CheckCube" TARGET="MAIN"><CODE>Cudd_CheckCube()</CODE></A> -<DD> Checks whether g is the BDD of a cube. - -<DT> <A HREF="cuddAllDet.html#Cudd_CheckKeys" TARGET="MAIN"><CODE>Cudd_CheckKeys()</CODE></A> -<DD> Checks for several conditions that should not occur. - -<DT> <A HREF="cuddAllDet.html#Cudd_CheckZeroRef" TARGET="MAIN"><CODE>Cudd_CheckZeroRef()</CODE></A> -<DD> Checks the unique table for nodes with non-zero reference - counts. - -<DT> <A HREF="cuddAllDet.html#Cudd_ClassifySupport" TARGET="MAIN"><CODE>Cudd_ClassifySupport()</CODE></A> -<DD> Classifies the variables in the support of two DDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_ClearErrorCode" TARGET="MAIN"><CODE>Cudd_ClearErrorCode()</CODE></A> -<DD> Clear the error code of a manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_CofMinterm" TARGET="MAIN"><CODE>Cudd_CofMinterm()</CODE></A> -<DD> Computes the fraction of minterms in the on-set of all the - positive cofactors of a BDD or ADD. - -<DT> <A HREF="cuddAllDet.html#Cudd_Cofactor" TARGET="MAIN"><CODE>Cudd_Cofactor()</CODE></A> -<DD> Computes the cofactor of f with respect to g. - -<DT> <A HREF="cuddAllDet.html#Cudd_CountLeaves" TARGET="MAIN"><CODE>Cudd_CountLeaves()</CODE></A> -<DD> Counts the number of leaves in a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_CountMinterm" TARGET="MAIN"><CODE>Cudd_CountMinterm()</CODE></A> -<DD> Counts the number of minterms of a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_CountPathsToNonZero" TARGET="MAIN"><CODE>Cudd_CountPathsToNonZero()</CODE></A> -<DD> Counts the number of paths to a non-zero terminal of a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_CountPath" TARGET="MAIN"><CODE>Cudd_CountPath()</CODE></A> -<DD> Counts the number of paths of a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_CubeArrayToBdd" TARGET="MAIN"><CODE>Cudd_CubeArrayToBdd()</CODE></A> -<DD> Builds the BDD of a cube from a positional array. - -<DT> <A HREF="cuddAllDet.html#Cudd_DagSize" TARGET="MAIN"><CODE>Cudd_DagSize()</CODE></A> -<DD> Counts the number of nodes in a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_DeadAreCounted" TARGET="MAIN"><CODE>Cudd_DeadAreCounted()</CODE></A> -<DD> Tells whether dead nodes are counted towards triggering - reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_DebugCheck" TARGET="MAIN"><CODE>Cudd_DebugCheck()</CODE></A> -<DD> Checks for inconsistencies in the DD heap. - -<DT> <A HREF="cuddAllDet.html#Cudd_Decreasing" TARGET="MAIN"><CODE>Cudd_Decreasing()</CODE></A> -<DD> Determines whether a BDD is negative unate in a - variable. - -<DT> <A HREF="cuddAllDet.html#Cudd_DelayedDerefBdd" TARGET="MAIN"><CODE>Cudd_DelayedDerefBdd()</CODE></A> -<DD> Decreases the reference count of BDD node n. - -<DT> <A HREF="cuddAllDet.html#Cudd_Density" TARGET="MAIN"><CODE>Cudd_Density()</CODE></A> -<DD> Computes the density of a BDD or ADD. - -<DT> <A HREF="cuddAllDet.html#Cudd_Deref" TARGET="MAIN"><CODE>Cudd_Deref()</CODE></A> -<DD> Decreases the reference count of node. - -<DT> <A HREF="cuddAllDet.html#Cudd_DisableGarbageCollection" TARGET="MAIN"><CODE>Cudd_DisableGarbageCollection()</CODE></A> -<DD> Disables garbage collection. - -<DT> <A HREF="cuddAllDet.html#Cudd_DisableOrderingMonitoring" TARGET="MAIN"><CODE>Cudd_DisableOrderingMonitoring()</CODE></A> -<DD> Disables monitoring of ordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_DisableReorderingReporting" TARGET="MAIN"><CODE>Cudd_DisableReorderingReporting()</CODE></A> -<DD> Disables reporting of reordering stats. - -<DT> <A HREF="cuddAllDet.html#Cudd_Disequality" TARGET="MAIN"><CODE>Cudd_Disequality()</CODE></A> -<DD> Generates a BDD for the function x - y != c. - -<DT> <A HREF="cuddAllDet.html#Cudd_DumpBlifBody" TARGET="MAIN"><CODE>Cudd_DumpBlifBody()</CODE></A> -<DD> Writes a blif body representing the argument BDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_DumpBlif" TARGET="MAIN"><CODE>Cudd_DumpBlif()</CODE></A> -<DD> Writes a blif file representing the argument BDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_DumpDDcal" TARGET="MAIN"><CODE>Cudd_DumpDDcal()</CODE></A> -<DD> Writes a DDcal file representing the argument BDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_DumpDaVinci" TARGET="MAIN"><CODE>Cudd_DumpDaVinci()</CODE></A> -<DD> Writes a daVinci file representing the argument BDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_DumpDot" TARGET="MAIN"><CODE>Cudd_DumpDot()</CODE></A> -<DD> Writes a dot file representing the argument DDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_DumpFactoredForm" TARGET="MAIN"><CODE>Cudd_DumpFactoredForm()</CODE></A> -<DD> Writes factored forms representing the argument BDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_Dxygtdxz" TARGET="MAIN"><CODE>Cudd_Dxygtdxz()</CODE></A> -<DD> Generates a BDD for the function d(x,y) > d(x,z). - -<DT> <A HREF="cuddAllDet.html#Cudd_Dxygtdyz" TARGET="MAIN"><CODE>Cudd_Dxygtdyz()</CODE></A> -<DD> Generates a BDD for the function d(x,y) > d(y,z). - -<DT> <A HREF="cuddAllDet.html#Cudd_EnableGarbageCollection" TARGET="MAIN"><CODE>Cudd_EnableGarbageCollection()</CODE></A> -<DD> Enables garbage collection. - -<DT> <A HREF="cuddAllDet.html#Cudd_EnableOrderingMonitoring" TARGET="MAIN"><CODE>Cudd_EnableOrderingMonitoring()</CODE></A> -<DD> Enables monitoring of ordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_EnableReorderingReporting" TARGET="MAIN"><CODE>Cudd_EnableReorderingReporting()</CODE></A> -<DD> Enables reporting of reordering stats. - -<DT> <A HREF="cuddAllDet.html#Cudd_EpdCountMinterm" TARGET="MAIN"><CODE>Cudd_EpdCountMinterm()</CODE></A> -<DD> Counts the number of minterms of a DD with extended precision. - -<DT> <A HREF="cuddAllDet.html#Cudd_EqualSupNorm" TARGET="MAIN"><CODE>Cudd_EqualSupNorm()</CODE></A> -<DD> Compares two ADDs for equality within tolerance. - -<DT> <A HREF="cuddAllDet.html#Cudd_EquivDC" TARGET="MAIN"><CODE>Cudd_EquivDC()</CODE></A> -<DD> Tells whether F and G are identical wherever D is 0. - -<DT> <A HREF="cuddAllDet.html#Cudd_EstimateCofactorSimple" TARGET="MAIN"><CODE>Cudd_EstimateCofactorSimple()</CODE></A> -<DD> Estimates the number of nodes in a cofactor of a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_EstimateCofactor" TARGET="MAIN"><CODE>Cudd_EstimateCofactor()</CODE></A> -<DD> Estimates the number of nodes in a cofactor of a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_Eval" TARGET="MAIN"><CODE>Cudd_Eval()</CODE></A> -<DD> Returns the value of a DD for a given variable assignment. - -<DT> <A HREF="cuddAllDet.html#Cudd_ExpectedUsedSlots" TARGET="MAIN"><CODE>Cudd_ExpectedUsedSlots()</CODE></A> -<DD> Computes the expected fraction of used slots in the unique - table. - -<DT> <A HREF="cuddAllDet.html#Cudd_FindEssential" TARGET="MAIN"><CODE>Cudd_FindEssential()</CODE></A> -<DD> Finds the essential variables of a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_FindTwoLiteralClauses" TARGET="MAIN"><CODE>Cudd_FindTwoLiteralClauses()</CODE></A> -<DD> Finds the two literal clauses of a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_FirstCube" TARGET="MAIN"><CODE>Cudd_FirstCube()</CODE></A> -<DD> Finds the first cube of a decision diagram. - -<DT> <A HREF="cuddAllDet.html#Cudd_FirstNode" TARGET="MAIN"><CODE>Cudd_FirstNode()</CODE></A> -<DD> Finds the first node of a decision diagram. - -<DT> <A HREF="cuddAllDet.html#Cudd_FirstPrime" TARGET="MAIN"><CODE>Cudd_FirstPrime()</CODE></A> -<DD> Finds the first prime of a Boolean function. - -<DT> <A HREF="cuddAllDet.html#Cudd_FreeTree" TARGET="MAIN"><CODE>Cudd_FreeTree()</CODE></A> -<DD> Frees the variable group tree of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_FreeZddTree" TARGET="MAIN"><CODE>Cudd_FreeZddTree()</CODE></A> -<DD> Frees the variable group tree of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_GarbageCollectionEnabled" TARGET="MAIN"><CODE>Cudd_GarbageCollectionEnabled()</CODE></A> -<DD> Tells whether garbage collection is enabled. - -<DT> <A HREF="cuddAllDet.html#Cudd_GenFree" TARGET="MAIN"><CODE>Cudd_GenFree()</CODE></A> -<DD> Frees a CUDD generator. - -<DT> <A HREF="cuddAllDet.html#Cudd_IncreaseTimeLimit" TARGET="MAIN"><CODE>Cudd_IncreaseTimeLimit()</CODE></A> -<DD> Increases the time limit for the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_Increasing" TARGET="MAIN"><CODE>Cudd_Increasing()</CODE></A> -<DD> Determines whether a BDD is positive unate in a - variable. - -<DT> <A HREF="cuddAllDet.html#Cudd_IndicesToCube" TARGET="MAIN"><CODE>Cudd_IndicesToCube()</CODE></A> -<DD> Builds a cube of BDD variables from an array of indices. - -<DT> <A HREF="cuddAllDet.html#Cudd_Inequality" TARGET="MAIN"><CODE>Cudd_Inequality()</CODE></A> -<DD> Generates a BDD for the function x - y ≥ c. - -<DT> <A HREF="cuddAllDet.html#Cudd_Init" TARGET="MAIN"><CODE>Cudd_Init()</CODE></A> -<DD> Creates a new DD manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_IsGenEmpty" TARGET="MAIN"><CODE>Cudd_IsGenEmpty()</CODE></A> -<DD> Queries the status of a generator. - -<DT> <A HREF="cuddAllDet.html#Cudd_IsInHook" TARGET="MAIN"><CODE>Cudd_IsInHook()</CODE></A> -<DD> Checks whether a function is in a hook. - -<DT> <A HREF="cuddAllDet.html#Cudd_IsNonConstant" TARGET="MAIN"><CODE>Cudd_IsNonConstant()</CODE></A> -<DD> Returns 1 if a DD node is not constant. - -<DT> <A HREF="cuddAllDet.html#Cudd_IterDerefBdd" TARGET="MAIN"><CODE>Cudd_IterDerefBdd()</CODE></A> -<DD> Decreases the reference count of BDD node n. - -<DT> <A HREF="cuddAllDet.html#Cudd_LargestCube" TARGET="MAIN"><CODE>Cudd_LargestCube()</CODE></A> -<DD> Finds a largest cube in a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_MakeBddFromZddCover" TARGET="MAIN"><CODE>Cudd_MakeBddFromZddCover()</CODE></A> -<DD> Converts a ZDD cover to a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_MakeTreeNode" TARGET="MAIN"><CODE>Cudd_MakeTreeNode()</CODE></A> -<DD> Creates a new variable group. - -<DT> <A HREF="cuddAllDet.html#Cudd_MakeZddTreeNode" TARGET="MAIN"><CODE>Cudd_MakeZddTreeNode()</CODE></A> -<DD> Creates a new ZDD variable group. - -<DT> <A HREF="cuddAllDet.html#Cudd_MinHammingDist" TARGET="MAIN"><CODE>Cudd_MinHammingDist()</CODE></A> -<DD> Returns the minimum Hamming distance between f and minterm. - -<DT> <A HREF="cuddAllDet.html#Cudd_NewApaNumber" TARGET="MAIN"><CODE>Cudd_NewApaNumber()</CODE></A> -<DD> Allocates memory for an arbitrary precision integer. - -<DT> <A HREF="cuddAllDet.html#Cudd_NextCube" TARGET="MAIN"><CODE>Cudd_NextCube()</CODE></A> -<DD> Generates the next cube of a decision diagram onset. - -<DT> <A HREF="cuddAllDet.html#Cudd_NextNode" TARGET="MAIN"><CODE>Cudd_NextNode()</CODE></A> -<DD> Finds the next node of a decision diagram. - -<DT> <A HREF="cuddAllDet.html#Cudd_NextPrime" TARGET="MAIN"><CODE>Cudd_NextPrime()</CODE></A> -<DD> Generates the next prime of a Boolean function. - -<DT> <A HREF="cuddAllDet.html#Cudd_NodeReadIndex" TARGET="MAIN"><CODE>Cudd_NodeReadIndex()</CODE></A> -<DD> Returns the index of the node. - -<DT> <A HREF="cuddAllDet.html#Cudd_OrderingMonitoring" TARGET="MAIN"><CODE>Cudd_OrderingMonitoring()</CODE></A> -<DD> Returns 1 if monitoring of ordering is enabled. - -<DT> <A HREF="cuddAllDet.html#Cudd_OutOfMem" TARGET="MAIN"><CODE>Cudd_OutOfMem()</CODE></A> -<DD> Warns that a memory allocation failed. - -<DT> <A HREF="cuddAllDet.html#Cudd_OverApprox" TARGET="MAIN"><CODE>Cudd_OverApprox()</CODE></A> -<DD> Extracts a dense superset from a BDD with Shiple's - underapproximation method. - -<DT> <A HREF="cuddAllDet.html#Cudd_Prime" TARGET="MAIN"><CODE>Cudd_Prime()</CODE></A> -<DD> Returns the next prime >= p. - -<DT> <A HREF="cuddAllDet.html#Cudd_PrintDebug" TARGET="MAIN"><CODE>Cudd_PrintDebug()</CODE></A> -<DD> Prints to the standard output a DD and its statistics. - -<DT> <A HREF="cuddAllDet.html#Cudd_PrintGroupedOrder" TARGET="MAIN"><CODE>Cudd_PrintGroupedOrder()</CODE></A> -<DD> Hook function to print the current variable order. - -<DT> <A HREF="cuddAllDet.html#Cudd_PrintInfo" TARGET="MAIN"><CODE>Cudd_PrintInfo()</CODE></A> -<DD> Prints out statistics and settings for a CUDD manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_PrintLinear" TARGET="MAIN"><CODE>Cudd_PrintLinear()</CODE></A> -<DD> Prints the linear transform matrix. - -<DT> <A HREF="cuddAllDet.html#Cudd_PrintMinterm" TARGET="MAIN"><CODE>Cudd_PrintMinterm()</CODE></A> -<DD> Prints a disjoint sum of products. - -<DT> <A HREF="cuddAllDet.html#Cudd_PrintTwoLiteralClauses" TARGET="MAIN"><CODE>Cudd_PrintTwoLiteralClauses()</CODE></A> -<DD> Prints the two literal clauses of a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_PrintVersion" TARGET="MAIN"><CODE>Cudd_PrintVersion()</CODE></A> -<DD> Prints the package version number. - -<DT> <A HREF="cuddAllDet.html#Cudd_PrioritySelect" TARGET="MAIN"><CODE>Cudd_PrioritySelect()</CODE></A> -<DD> Selects pairs from R using a priority function. - -<DT> <A HREF="cuddAllDet.html#Cudd_Quit" TARGET="MAIN"><CODE>Cudd_Quit()</CODE></A> -<DD> Deletes resources associated with a DD manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_Random" TARGET="MAIN"><CODE>Cudd_Random()</CODE></A> -<DD> Portable random number generator. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadArcviolation" TARGET="MAIN"><CODE>Cudd_ReadArcviolation()</CODE></A> -<DD> Returns the current value of the arcviolation parameter used - in group sifting. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadBackground" TARGET="MAIN"><CODE>Cudd_ReadBackground()</CODE></A> -<DD> Reads the background constant of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadCacheHits" TARGET="MAIN"><CODE>Cudd_ReadCacheHits()</CODE></A> -<DD> Returns the number of cache hits. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadCacheLookUps" TARGET="MAIN"><CODE>Cudd_ReadCacheLookUps()</CODE></A> -<DD> Returns the number of cache look-ups. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadCacheSlots" TARGET="MAIN"><CODE>Cudd_ReadCacheSlots()</CODE></A> -<DD> Reads the number of slots in the cache. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadCacheUsedSlots" TARGET="MAIN"><CODE>Cudd_ReadCacheUsedSlots()</CODE></A> -<DD> Reads the fraction of used slots in the cache. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadDead" TARGET="MAIN"><CODE>Cudd_ReadDead()</CODE></A> -<DD> Returns the number of dead nodes in the unique table. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadElapsedTime" TARGET="MAIN"><CODE>Cudd_ReadElapsedTime()</CODE></A> -<DD> Returns the time elapsed since the start time of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadEpsilon" TARGET="MAIN"><CODE>Cudd_ReadEpsilon()</CODE></A> -<DD> Reads the epsilon parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadErrorCode" TARGET="MAIN"><CODE>Cudd_ReadErrorCode()</CODE></A> -<DD> Returns the code of the last error. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadGarbageCollectionTime" TARGET="MAIN"><CODE>Cudd_ReadGarbageCollectionTime()</CODE></A> -<DD> Returns the time spent in garbage collection. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadGarbageCollections" TARGET="MAIN"><CODE>Cudd_ReadGarbageCollections()</CODE></A> -<DD> Returns the number of times garbage collection has occurred. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadGroupcheck" TARGET="MAIN"><CODE>Cudd_ReadGroupcheck()</CODE></A> -<DD> Reads the groupcheck parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadInvPermZdd" TARGET="MAIN"><CODE>Cudd_ReadInvPermZdd()</CODE></A> -<DD> Returns the index of the ZDD variable currently in the i-th - position of the order. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadInvPerm" TARGET="MAIN"><CODE>Cudd_ReadInvPerm()</CODE></A> -<DD> Returns the index of the variable currently in the i-th - position of the order. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadIthClause" TARGET="MAIN"><CODE>Cudd_ReadIthClause()</CODE></A> -<DD> Accesses the i-th clause of a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadKeys" TARGET="MAIN"><CODE>Cudd_ReadKeys()</CODE></A> -<DD> Returns the number of nodes in the unique table. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadLinear" TARGET="MAIN"><CODE>Cudd_ReadLinear()</CODE></A> -<DD> Reads an entry of the linear transform matrix. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadLogicZero" TARGET="MAIN"><CODE>Cudd_ReadLogicZero()</CODE></A> -<DD> Returns the logic zero constant of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadLooseUpTo" TARGET="MAIN"><CODE>Cudd_ReadLooseUpTo()</CODE></A> -<DD> Reads the looseUpTo parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxCacheHard" TARGET="MAIN"><CODE>Cudd_ReadMaxCacheHard()</CODE></A> -<DD> Reads the maxCacheHard parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxCache" TARGET="MAIN"><CODE>Cudd_ReadMaxCache()</CODE></A> -<DD> Returns the soft limit for the cache size. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxGrowthAlternate" TARGET="MAIN"><CODE>Cudd_ReadMaxGrowthAlternate()</CODE></A> -<DD> Reads the maxGrowthAlt parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxGrowth" TARGET="MAIN"><CODE>Cudd_ReadMaxGrowth()</CODE></A> -<DD> Reads the maxGrowth parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxLive" TARGET="MAIN"><CODE>Cudd_ReadMaxLive()</CODE></A> -<DD> Reads the maximum allowed number of live nodes. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxMemory" TARGET="MAIN"><CODE>Cudd_ReadMaxMemory()</CODE></A> -<DD> Reads the maximum allowed memory. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxReorderings" TARGET="MAIN"><CODE>Cudd_ReadMaxReorderings()</CODE></A> -<DD> Returns the maximum number of times reordering may be invoked. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadMemoryInUse" TARGET="MAIN"><CODE>Cudd_ReadMemoryInUse()</CODE></A> -<DD> Returns the memory in use by the manager measured in bytes. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadMinDead" TARGET="MAIN"><CODE>Cudd_ReadMinDead()</CODE></A> -<DD> Reads the minDead parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadMinHit" TARGET="MAIN"><CODE>Cudd_ReadMinHit()</CODE></A> -<DD> Reads the hit rate that causes resizinig of the computed - table. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadMinusInfinity" TARGET="MAIN"><CODE>Cudd_ReadMinusInfinity()</CODE></A> -<DD> Reads the minus-infinity constant from the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadNextReordering" TARGET="MAIN"><CODE>Cudd_ReadNextReordering()</CODE></A> -<DD> Returns the threshold for the next dynamic reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadNodeCount" TARGET="MAIN"><CODE>Cudd_ReadNodeCount()</CODE></A> -<DD> Reports the number of nodes in BDDs and ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadNodesDropped" TARGET="MAIN"><CODE>Cudd_ReadNodesDropped()</CODE></A> -<DD> Returns the number of nodes dropped. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadNodesFreed" TARGET="MAIN"><CODE>Cudd_ReadNodesFreed()</CODE></A> -<DD> Returns the number of nodes freed. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadNumberXovers" TARGET="MAIN"><CODE>Cudd_ReadNumberXovers()</CODE></A> -<DD> Reads the current number of crossovers used by the - genetic algorithm for reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadOne" TARGET="MAIN"><CODE>Cudd_ReadOne()</CODE></A> -<DD> Returns the one constant of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadOrderRandomization" TARGET="MAIN"><CODE>Cudd_ReadOrderRandomization()</CODE></A> -<DD> Returns the order randomization factor. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadPeakLiveNodeCount" TARGET="MAIN"><CODE>Cudd_ReadPeakLiveNodeCount()</CODE></A> -<DD> Reports the peak number of live nodes. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadPeakNodeCount" TARGET="MAIN"><CODE>Cudd_ReadPeakNodeCount()</CODE></A> -<DD> Reports the peak number of nodes. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadPermZdd" TARGET="MAIN"><CODE>Cudd_ReadPermZdd()</CODE></A> -<DD> Returns the current position of the i-th ZDD variable in the - order. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadPerm" TARGET="MAIN"><CODE>Cudd_ReadPerm()</CODE></A> -<DD> Returns the current position of the i-th variable in the - order. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadPlusInfinity" TARGET="MAIN"><CODE>Cudd_ReadPlusInfinity()</CODE></A> -<DD> Reads the plus-infinity constant from the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadPopulationSize" TARGET="MAIN"><CODE>Cudd_ReadPopulationSize()</CODE></A> -<DD> Reads the current size of the population used by the - genetic algorithm for reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadRecomb" TARGET="MAIN"><CODE>Cudd_ReadRecomb()</CODE></A> -<DD> Returns the current value of the recombination parameter used - in group sifting. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadRecursiveCalls" TARGET="MAIN"><CODE>Cudd_ReadRecursiveCalls()</CODE></A> -<DD> Returns the number of recursive calls. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadReorderingCycle" TARGET="MAIN"><CODE>Cudd_ReadReorderingCycle()</CODE></A> -<DD> Reads the reordCycle parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadReorderingTime" TARGET="MAIN"><CODE>Cudd_ReadReorderingTime()</CODE></A> -<DD> Returns the time spent in reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadReorderings" TARGET="MAIN"><CODE>Cudd_ReadReorderings()</CODE></A> -<DD> Returns the number of times reordering has occurred. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadSiftMaxSwap" TARGET="MAIN"><CODE>Cudd_ReadSiftMaxSwap()</CODE></A> -<DD> Reads the siftMaxSwap parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadSiftMaxVar" TARGET="MAIN"><CODE>Cudd_ReadSiftMaxVar()</CODE></A> -<DD> Reads the siftMaxVar parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadSize" TARGET="MAIN"><CODE>Cudd_ReadSize()</CODE></A> -<DD> Returns the number of BDD variables in existance. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadSlots" TARGET="MAIN"><CODE>Cudd_ReadSlots()</CODE></A> -<DD> Returns the total number of slots of the unique table. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadStartTime" TARGET="MAIN"><CODE>Cudd_ReadStartTime()</CODE></A> -<DD> Returns the start time of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadStderr" TARGET="MAIN"><CODE>Cudd_ReadStderr()</CODE></A> -<DD> Reads the stderr of a manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadStdout" TARGET="MAIN"><CODE>Cudd_ReadStdout()</CODE></A> -<DD> Reads the stdout of a manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadSwapSteps" TARGET="MAIN"><CODE>Cudd_ReadSwapSteps()</CODE></A> -<DD> Reads the number of elementary reordering steps. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadSymmviolation" TARGET="MAIN"><CODE>Cudd_ReadSymmviolation()</CODE></A> -<DD> Returns the current value of the symmviolation parameter used - in group sifting. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadTimeLimit" TARGET="MAIN"><CODE>Cudd_ReadTimeLimit()</CODE></A> -<DD> Returns the time limit for the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadTree" TARGET="MAIN"><CODE>Cudd_ReadTree()</CODE></A> -<DD> Returns the variable group tree of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadUniqueLinks" TARGET="MAIN"><CODE>Cudd_ReadUniqueLinks()</CODE></A> -<DD> Returns the number of links followed in the unique table. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadUniqueLookUps" TARGET="MAIN"><CODE>Cudd_ReadUniqueLookUps()</CODE></A> -<DD> Returns the number of look-ups in the unique table. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadUsedSlots" TARGET="MAIN"><CODE>Cudd_ReadUsedSlots()</CODE></A> -<DD> Reads the fraction of used slots in the unique table. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadVars" TARGET="MAIN"><CODE>Cudd_ReadVars()</CODE></A> -<DD> Returns the i-th element of the vars array. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadZddOne" TARGET="MAIN"><CODE>Cudd_ReadZddOne()</CODE></A> -<DD> Returns the ZDD for the constant 1 function. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadZddSize" TARGET="MAIN"><CODE>Cudd_ReadZddSize()</CODE></A> -<DD> Returns the number of ZDD variables in existance. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadZddTree" TARGET="MAIN"><CODE>Cudd_ReadZddTree()</CODE></A> -<DD> Returns the variable group tree of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReadZero" TARGET="MAIN"><CODE>Cudd_ReadZero()</CODE></A> -<DD> Returns the zero constant of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_RecursiveDerefZdd" TARGET="MAIN"><CODE>Cudd_RecursiveDerefZdd()</CODE></A> -<DD> Decreases the reference count of ZDD node n. - -<DT> <A HREF="cuddAllDet.html#Cudd_RecursiveDeref" TARGET="MAIN"><CODE>Cudd_RecursiveDeref()</CODE></A> -<DD> Decreases the reference count of node n. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReduceHeap" TARGET="MAIN"><CODE>Cudd_ReduceHeap()</CODE></A> -<DD> Main dynamic reordering routine. - -<DT> <A HREF="cuddAllDet.html#Cudd_Ref" TARGET="MAIN"><CODE>Cudd_Ref()</CODE></A> -<DD> Increases the reference count of a node, if it is not - saturated. - -<DT> <A HREF="cuddAllDet.html#Cudd_RemapOverApprox" TARGET="MAIN"><CODE>Cudd_RemapOverApprox()</CODE></A> -<DD> Extracts a dense superset from a BDD with the remapping - underapproximation method. - -<DT> <A HREF="cuddAllDet.html#Cudd_RemapUnderApprox" TARGET="MAIN"><CODE>Cudd_RemapUnderApprox()</CODE></A> -<DD> Extracts a dense subset from a BDD with the remapping - underapproximation method. - -<DT> <A HREF="cuddAllDet.html#Cudd_RemoveHook" TARGET="MAIN"><CODE>Cudd_RemoveHook()</CODE></A> -<DD> Removes a function from a hook. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReorderingReporting" TARGET="MAIN"><CODE>Cudd_ReorderingReporting()</CODE></A> -<DD> Returns 1 if reporting of reordering stats is enabled. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReorderingStatusZdd" TARGET="MAIN"><CODE>Cudd_ReorderingStatusZdd()</CODE></A> -<DD> Reports the status of automatic dynamic reordering of ZDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_ReorderingStatus" TARGET="MAIN"><CODE>Cudd_ReorderingStatus()</CODE></A> -<DD> Reports the status of automatic dynamic reordering of BDDs - and ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_Reserve" TARGET="MAIN"><CODE>Cudd_Reserve()</CODE></A> -<DD> Expand manager without creating variables. - -<DT> <A HREF="cuddAllDet.html#Cudd_ResetStartTime" TARGET="MAIN"><CODE>Cudd_ResetStartTime()</CODE></A> -<DD> Resets the start time of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetArcviolation" TARGET="MAIN"><CODE>Cudd_SetArcviolation()</CODE></A> -<DD> Sets the value of the arcviolation parameter used - in group sifting. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetBackground" TARGET="MAIN"><CODE>Cudd_SetBackground()</CODE></A> -<DD> Sets the background constant of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetEpsilon" TARGET="MAIN"><CODE>Cudd_SetEpsilon()</CODE></A> -<DD> Sets the epsilon parameter of the manager to ep. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetGroupcheck" TARGET="MAIN"><CODE>Cudd_SetGroupcheck()</CODE></A> -<DD> Sets the parameter groupcheck of the manager to gc. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetLooseUpTo" TARGET="MAIN"><CODE>Cudd_SetLooseUpTo()</CODE></A> -<DD> Sets the looseUpTo parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetMaxCacheHard" TARGET="MAIN"><CODE>Cudd_SetMaxCacheHard()</CODE></A> -<DD> Sets the maxCacheHard parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetMaxGrowthAlternate" TARGET="MAIN"><CODE>Cudd_SetMaxGrowthAlternate()</CODE></A> -<DD> Sets the maxGrowthAlt parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetMaxGrowth" TARGET="MAIN"><CODE>Cudd_SetMaxGrowth()</CODE></A> -<DD> Sets the maxGrowth parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetMaxLive" TARGET="MAIN"><CODE>Cudd_SetMaxLive()</CODE></A> -<DD> Sets the maximum allowed number of live nodes. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetMaxMemory" TARGET="MAIN"><CODE>Cudd_SetMaxMemory()</CODE></A> -<DD> Sets the maximum allowed memory. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetMaxReorderings" TARGET="MAIN"><CODE>Cudd_SetMaxReorderings()</CODE></A> -<DD> Sets the maximum number of times reordering may be invoked. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetMinHit" TARGET="MAIN"><CODE>Cudd_SetMinHit()</CODE></A> -<DD> Sets the hit rate that causes resizinig of the computed - table. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetNextReordering" TARGET="MAIN"><CODE>Cudd_SetNextReordering()</CODE></A> -<DD> Sets the threshold for the next dynamic reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetNumberXovers" TARGET="MAIN"><CODE>Cudd_SetNumberXovers()</CODE></A> -<DD> Sets the number of crossovers used by the - genetic algorithm for reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetOrderRandomization" TARGET="MAIN"><CODE>Cudd_SetOrderRandomization()</CODE></A> -<DD> Sets the order randomization factor. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetPopulationSize" TARGET="MAIN"><CODE>Cudd_SetPopulationSize()</CODE></A> -<DD> Sets the size of the population used by the - genetic algorithm for reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetRecomb" TARGET="MAIN"><CODE>Cudd_SetRecomb()</CODE></A> -<DD> Sets the value of the recombination parameter used in group - sifting. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetReorderingCycle" TARGET="MAIN"><CODE>Cudd_SetReorderingCycle()</CODE></A> -<DD> Sets the reordCycle parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetSiftMaxSwap" TARGET="MAIN"><CODE>Cudd_SetSiftMaxSwap()</CODE></A> -<DD> Sets the siftMaxSwap parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetSiftMaxVar" TARGET="MAIN"><CODE>Cudd_SetSiftMaxVar()</CODE></A> -<DD> Sets the siftMaxVar parameter of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetStartTime" TARGET="MAIN"><CODE>Cudd_SetStartTime()</CODE></A> -<DD> Sets the start time of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetStderr" TARGET="MAIN"><CODE>Cudd_SetStderr()</CODE></A> -<DD> Sets the stderr of a manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetStdout" TARGET="MAIN"><CODE>Cudd_SetStdout()</CODE></A> -<DD> Sets the stdout of a manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetSymmviolation" TARGET="MAIN"><CODE>Cudd_SetSymmviolation()</CODE></A> -<DD> Sets the value of the symmviolation parameter used - in group sifting. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetTimeLimit" TARGET="MAIN"><CODE>Cudd_SetTimeLimit()</CODE></A> -<DD> Sets the time limit for the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetTree" TARGET="MAIN"><CODE>Cudd_SetTree()</CODE></A> -<DD> Sets the variable group tree of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetVarMap" TARGET="MAIN"><CODE>Cudd_SetVarMap()</CODE></A> -<DD> Registers a variable mapping with the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SetZddTree" TARGET="MAIN"><CODE>Cudd_SetZddTree()</CODE></A> -<DD> Sets the ZDD variable group tree of the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_SharingSize" TARGET="MAIN"><CODE>Cudd_SharingSize()</CODE></A> -<DD> Counts the number of nodes in an array of DDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_ShortestLength" TARGET="MAIN"><CODE>Cudd_ShortestLength()</CODE></A> -<DD> Find the length of the shortest path(s) in a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_ShortestPath" TARGET="MAIN"><CODE>Cudd_ShortestPath()</CODE></A> -<DD> Finds a shortest path in a DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_ShuffleHeap" TARGET="MAIN"><CODE>Cudd_ShuffleHeap()</CODE></A> -<DD> Reorders variables according to given permutation. - -<DT> <A HREF="cuddAllDet.html#Cudd_SolveEqn" TARGET="MAIN"><CODE>Cudd_SolveEqn()</CODE></A> -<DD> Implements the solution of F(x,y) = 0. - -<DT> <A HREF="cuddAllDet.html#Cudd_SplitSet" TARGET="MAIN"><CODE>Cudd_SplitSet()</CODE></A> -<DD> Returns m minterms from a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_Srandom" TARGET="MAIN"><CODE>Cudd_Srandom()</CODE></A> -<DD> Initializer for the portable random number generator. - -<DT> <A HREF="cuddAllDet.html#Cudd_StdPostReordHook" TARGET="MAIN"><CODE>Cudd_StdPostReordHook()</CODE></A> -<DD> Sample hook function to call after reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_StdPreReordHook" TARGET="MAIN"><CODE>Cudd_StdPreReordHook()</CODE></A> -<DD> Sample hook function to call before reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_SubsetCompress" TARGET="MAIN"><CODE>Cudd_SubsetCompress()</CODE></A> -<DD> Find a dense subset of BDD <code>f</code>. - -<DT> <A HREF="cuddAllDet.html#Cudd_SubsetHeavyBranch" TARGET="MAIN"><CODE>Cudd_SubsetHeavyBranch()</CODE></A> -<DD> Extracts a dense subset from a BDD with the heavy branch - heuristic. - -<DT> <A HREF="cuddAllDet.html#Cudd_SubsetShortPaths" TARGET="MAIN"><CODE>Cudd_SubsetShortPaths()</CODE></A> -<DD> Extracts a dense subset from a BDD with the shortest paths - heuristic. - -<DT> <A HREF="cuddAllDet.html#Cudd_SubsetWithMaskVars" TARGET="MAIN"><CODE>Cudd_SubsetWithMaskVars()</CODE></A> -<DD> Extracts a subset from a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_SupersetCompress" TARGET="MAIN"><CODE>Cudd_SupersetCompress()</CODE></A> -<DD> Find a dense superset of BDD <code>f</code>. - -<DT> <A HREF="cuddAllDet.html#Cudd_SupersetHeavyBranch" TARGET="MAIN"><CODE>Cudd_SupersetHeavyBranch()</CODE></A> -<DD> Extracts a dense superset from a BDD with the heavy branch - heuristic. - -<DT> <A HREF="cuddAllDet.html#Cudd_SupersetShortPaths" TARGET="MAIN"><CODE>Cudd_SupersetShortPaths()</CODE></A> -<DD> Extracts a dense superset from a BDD with the shortest paths - heuristic. - -<DT> <A HREF="cuddAllDet.html#Cudd_SupportIndex" TARGET="MAIN"><CODE>Cudd_SupportIndex()</CODE></A> -<DD> Finds the variables on which a DD depends. - -<DT> <A HREF="cuddAllDet.html#Cudd_SupportIndices" TARGET="MAIN"><CODE>Cudd_SupportIndices()</CODE></A> -<DD> Finds the variables on which a DD depends. - -<DT> <A HREF="cuddAllDet.html#Cudd_SupportSize" TARGET="MAIN"><CODE>Cudd_SupportSize()</CODE></A> -<DD> Counts the variables on which a DD depends. - -<DT> <A HREF="cuddAllDet.html#Cudd_Support" TARGET="MAIN"><CODE>Cudd_Support()</CODE></A> -<DD> Finds the variables on which a DD depends. - -<DT> <A HREF="cuddAllDet.html#Cudd_SymmProfile" TARGET="MAIN"><CODE>Cudd_SymmProfile()</CODE></A> -<DD> Prints statistics on symmetric variables. - -<DT> <A HREF="cuddAllDet.html#Cudd_TimeLimited" TARGET="MAIN"><CODE>Cudd_TimeLimited()</CODE></A> -<DD> Returns true if the time limit for the manager is set. - -<DT> <A HREF="cuddAllDet.html#Cudd_TurnOffCountDead" TARGET="MAIN"><CODE>Cudd_TurnOffCountDead()</CODE></A> -<DD> Causes the dead nodes not to be counted towards triggering - reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_TurnOnCountDead" TARGET="MAIN"><CODE>Cudd_TurnOnCountDead()</CODE></A> -<DD> Causes the dead nodes to be counted towards triggering - reordering. - -<DT> <A HREF="cuddAllDet.html#Cudd_UnderApprox" TARGET="MAIN"><CODE>Cudd_UnderApprox()</CODE></A> -<DD> Extracts a dense subset from a BDD with Shiple's - underapproximation method. - -<DT> <A HREF="cuddAllDet.html#Cudd_UnsetTimeLimit" TARGET="MAIN"><CODE>Cudd_UnsetTimeLimit()</CODE></A> -<DD> Unsets the time limit for the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_UpdateTimeLimit" TARGET="MAIN"><CODE>Cudd_UpdateTimeLimit()</CODE></A> -<DD> Updates the time limit for the manager. - -<DT> <A HREF="cuddAllDet.html#Cudd_VectorSupportIndex" TARGET="MAIN"><CODE>Cudd_VectorSupportIndex()</CODE></A> -<DD> Finds the variables on which a set of DDs depends. - -<DT> <A HREF="cuddAllDet.html#Cudd_VectorSupportIndices" TARGET="MAIN"><CODE>Cudd_VectorSupportIndices()</CODE></A> -<DD> Finds the variables on which a set of DDs depends. - -<DT> <A HREF="cuddAllDet.html#Cudd_VectorSupportSize" TARGET="MAIN"><CODE>Cudd_VectorSupportSize()</CODE></A> -<DD> Counts the variables on which a set of DDs depends. - -<DT> <A HREF="cuddAllDet.html#Cudd_VectorSupport" TARGET="MAIN"><CODE>Cudd_VectorSupport()</CODE></A> -<DD> Finds the variables on which a set of DDs depends. - -<DT> <A HREF="cuddAllDet.html#Cudd_VerifySol" TARGET="MAIN"><CODE>Cudd_VerifySol()</CODE></A> -<DD> Checks the solution of F(x,y) = 0. - -<DT> <A HREF="cuddAllDet.html#Cudd_Xeqy" TARGET="MAIN"><CODE>Cudd_Xeqy()</CODE></A> -<DD> Generates a BDD for the function x==y. - -<DT> <A HREF="cuddAllDet.html#Cudd_Xgty" TARGET="MAIN"><CODE>Cudd_Xgty()</CODE></A> -<DD> Generates a BDD for the function x > y. - -<DT> <A HREF="cuddAllDet.html#Cudd_addAgreement" TARGET="MAIN"><CODE>Cudd_addAgreement()</CODE></A> -<DD> f if f==g; background if f!=g. - -<DT> <A HREF="cuddAllDet.html#Cudd_addApply" TARGET="MAIN"><CODE>Cudd_addApply()</CODE></A> -<DD> Applies op to the corresponding discriminants of f and g. - -<DT> <A HREF="cuddAllDet.html#Cudd_addBddInterval" TARGET="MAIN"><CODE>Cudd_addBddInterval()</CODE></A> -<DD> Converts an ADD to a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_addBddIthBit" TARGET="MAIN"><CODE>Cudd_addBddIthBit()</CODE></A> -<DD> Converts an ADD to a BDD by extracting the i-th bit from - the leaves. - -<DT> <A HREF="cuddAllDet.html#Cudd_addBddPattern" TARGET="MAIN"><CODE>Cudd_addBddPattern()</CODE></A> -<DD> Converts an ADD to a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_addBddStrictThreshold" TARGET="MAIN"><CODE>Cudd_addBddStrictThreshold()</CODE></A> -<DD> Converts an ADD to a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_addBddThreshold" TARGET="MAIN"><CODE>Cudd_addBddThreshold()</CODE></A> -<DD> Converts an ADD to a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_addCmpl" TARGET="MAIN"><CODE>Cudd_addCmpl()</CODE></A> -<DD> Computes the complement of an ADD a la C language. - -<DT> <A HREF="cuddAllDet.html#Cudd_addCompose" TARGET="MAIN"><CODE>Cudd_addCompose()</CODE></A> -<DD> Substitutes g for x_v in the ADD for f. - -<DT> <A HREF="cuddAllDet.html#Cudd_addComputeCube" TARGET="MAIN"><CODE>Cudd_addComputeCube()</CODE></A> -<DD> Computes the cube of an array of ADD variables. - -<DT> <A HREF="cuddAllDet.html#Cudd_addConstrain" TARGET="MAIN"><CODE>Cudd_addConstrain()</CODE></A> -<DD> Computes f constrain c for ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_addConst" TARGET="MAIN"><CODE>Cudd_addConst()</CODE></A> -<DD> Returns the ADD for constant c. - -<DT> <A HREF="cuddAllDet.html#Cudd_addDiff" TARGET="MAIN"><CODE>Cudd_addDiff()</CODE></A> -<DD> Returns plusinfinity if f=g; returns min(f,g) if f!=g. - -<DT> <A HREF="cuddAllDet.html#Cudd_addDivide" TARGET="MAIN"><CODE>Cudd_addDivide()</CODE></A> -<DD> Integer and floating point division. - -<DT> <A HREF="cuddAllDet.html#Cudd_addEvalConst" TARGET="MAIN"><CODE>Cudd_addEvalConst()</CODE></A> -<DD> Checks whether ADD g is constant whenever ADD f is 1. - -<DT> <A HREF="cuddAllDet.html#Cudd_addExistAbstract" TARGET="MAIN"><CODE>Cudd_addExistAbstract()</CODE></A> -<DD> Existentially Abstracts all the variables in cube from f. - -<DT> <A HREF="cuddAllDet.html#Cudd_addFindMax" TARGET="MAIN"><CODE>Cudd_addFindMax()</CODE></A> -<DD> Finds the maximum discriminant of f. - -<DT> <A HREF="cuddAllDet.html#Cudd_addFindMin" TARGET="MAIN"><CODE>Cudd_addFindMin()</CODE></A> -<DD> Finds the minimum discriminant of f. - -<DT> <A HREF="cuddAllDet.html#Cudd_addGeneralVectorCompose" TARGET="MAIN"><CODE>Cudd_addGeneralVectorCompose()</CODE></A> -<DD> Composes an ADD with a vector of ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_addHamming" TARGET="MAIN"><CODE>Cudd_addHamming()</CODE></A> -<DD> Computes the Hamming distance ADD. - -<DT> <A HREF="cuddAllDet.html#Cudd_addHarwell" TARGET="MAIN"><CODE>Cudd_addHarwell()</CODE></A> -<DD> Reads in a matrix in the format of the Harwell-Boeing - benchmark suite. - -<DT> <A HREF="cuddAllDet.html#Cudd_addIteConstant" TARGET="MAIN"><CODE>Cudd_addIteConstant()</CODE></A> -<DD> Implements ITEconstant for ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_addIte" TARGET="MAIN"><CODE>Cudd_addIte()</CODE></A> -<DD> Implements ITE(f,g,h). - -<DT> <A HREF="cuddAllDet.html#Cudd_addIthBit" TARGET="MAIN"><CODE>Cudd_addIthBit()</CODE></A> -<DD> Extracts the i-th bit from an ADD. - -<DT> <A HREF="cuddAllDet.html#Cudd_addIthVar" TARGET="MAIN"><CODE>Cudd_addIthVar()</CODE></A> -<DD> Returns the ADD variable with index i. - -<DT> <A HREF="cuddAllDet.html#Cudd_addLeq" TARGET="MAIN"><CODE>Cudd_addLeq()</CODE></A> -<DD> Determines whether f is less than or equal to g. - -<DT> <A HREF="cuddAllDet.html#Cudd_addLog" TARGET="MAIN"><CODE>Cudd_addLog()</CODE></A> -<DD> Natural logarithm of an ADD. - -<DT> <A HREF="cuddAllDet.html#Cudd_addMatrixMultiply" TARGET="MAIN"><CODE>Cudd_addMatrixMultiply()</CODE></A> -<DD> Calculates the product of two matrices represented as - ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_addMaximum" TARGET="MAIN"><CODE>Cudd_addMaximum()</CODE></A> -<DD> Integer and floating point max. - -<DT> <A HREF="cuddAllDet.html#Cudd_addMinimum" TARGET="MAIN"><CODE>Cudd_addMinimum()</CODE></A> -<DD> Integer and floating point min. - -<DT> <A HREF="cuddAllDet.html#Cudd_addMinus" TARGET="MAIN"><CODE>Cudd_addMinus()</CODE></A> -<DD> Integer and floating point subtraction. - -<DT> <A HREF="cuddAllDet.html#Cudd_addMonadicApply" TARGET="MAIN"><CODE>Cudd_addMonadicApply()</CODE></A> -<DD> Applies op to the discriminants of f. - -<DT> <A HREF="cuddAllDet.html#Cudd_addNand" TARGET="MAIN"><CODE>Cudd_addNand()</CODE></A> -<DD> NAND of two 0-1 ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_addNegate" TARGET="MAIN"><CODE>Cudd_addNegate()</CODE></A> -<DD> Computes the additive inverse of an ADD. - -<DT> <A HREF="cuddAllDet.html#Cudd_addNewVarAtLevel" TARGET="MAIN"><CODE>Cudd_addNewVarAtLevel()</CODE></A> -<DD> Returns a new ADD variable at a specified level. - -<DT> <A HREF="cuddAllDet.html#Cudd_addNewVar" TARGET="MAIN"><CODE>Cudd_addNewVar()</CODE></A> -<DD> Returns a new ADD variable. - -<DT> <A HREF="cuddAllDet.html#Cudd_addNonSimCompose" TARGET="MAIN"><CODE>Cudd_addNonSimCompose()</CODE></A> -<DD> Composes an ADD with a vector of 0-1 ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_addNor" TARGET="MAIN"><CODE>Cudd_addNor()</CODE></A> -<DD> NOR of two 0-1 ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_addOneZeroMaximum" TARGET="MAIN"><CODE>Cudd_addOneZeroMaximum()</CODE></A> -<DD> Returns 1 if f > g and 0 otherwise. - -<DT> <A HREF="cuddAllDet.html#Cudd_addOrAbstract" TARGET="MAIN"><CODE>Cudd_addOrAbstract()</CODE></A> -<DD> Disjunctively abstracts all the variables in cube from the - 0-1 ADD f. - -<DT> <A HREF="cuddAllDet.html#Cudd_addOr" TARGET="MAIN"><CODE>Cudd_addOr()</CODE></A> -<DD> Disjunction of two 0-1 ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_addOuterSum" TARGET="MAIN"><CODE>Cudd_addOuterSum()</CODE></A> -<DD> Takes the minimum of a matrix and the outer sum of two vectors. - -<DT> <A HREF="cuddAllDet.html#Cudd_addPermute" TARGET="MAIN"><CODE>Cudd_addPermute()</CODE></A> -<DD> Permutes the variables of an ADD. - -<DT> <A HREF="cuddAllDet.html#Cudd_addPlus" TARGET="MAIN"><CODE>Cudd_addPlus()</CODE></A> -<DD> Integer and floating point addition. - -<DT> <A HREF="cuddAllDet.html#Cudd_addRead" TARGET="MAIN"><CODE>Cudd_addRead()</CODE></A> -<DD> Reads in a sparse matrix. - -<DT> <A HREF="cuddAllDet.html#Cudd_addResidue" TARGET="MAIN"><CODE>Cudd_addResidue()</CODE></A> -<DD> Builds an ADD for the residue modulo m of an n-bit - number. - -<DT> <A HREF="cuddAllDet.html#Cudd_addRestrict" TARGET="MAIN"><CODE>Cudd_addRestrict()</CODE></A> -<DD> ADD restrict according to Coudert and Madre's algorithm - (ICCAD90). - -<DT> <A HREF="cuddAllDet.html#Cudd_addRoundOff" TARGET="MAIN"><CODE>Cudd_addRoundOff()</CODE></A> -<DD> Rounds off the discriminants of an ADD. - -<DT> <A HREF="cuddAllDet.html#Cudd_addScalarInverse" TARGET="MAIN"><CODE>Cudd_addScalarInverse()</CODE></A> -<DD> Computes the scalar inverse of an ADD. - -<DT> <A HREF="cuddAllDet.html#Cudd_addSetNZ" TARGET="MAIN"><CODE>Cudd_addSetNZ()</CODE></A> -<DD> This operator sets f to the value of g wherever g != 0. - -<DT> <A HREF="cuddAllDet.html#Cudd_addSwapVariables" TARGET="MAIN"><CODE>Cudd_addSwapVariables()</CODE></A> -<DD> Swaps two sets of variables of the same size (x and y) in - the ADD f. - -<DT> <A HREF="cuddAllDet.html#Cudd_addThreshold" TARGET="MAIN"><CODE>Cudd_addThreshold()</CODE></A> -<DD> f if f>=g; 0 if f<g. - -<DT> <A HREF="cuddAllDet.html#Cudd_addTimesPlus" TARGET="MAIN"><CODE>Cudd_addTimesPlus()</CODE></A> -<DD> Calculates the product of two matrices represented as - ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_addTimes" TARGET="MAIN"><CODE>Cudd_addTimes()</CODE></A> -<DD> Integer and floating point multiplication. - -<DT> <A HREF="cuddAllDet.html#Cudd_addTriangle" TARGET="MAIN"><CODE>Cudd_addTriangle()</CODE></A> -<DD> Performs the triangulation step for the shortest path - computation. - -<DT> <A HREF="cuddAllDet.html#Cudd_addUnivAbstract" TARGET="MAIN"><CODE>Cudd_addUnivAbstract()</CODE></A> -<DD> Universally Abstracts all the variables in cube from f. - -<DT> <A HREF="cuddAllDet.html#Cudd_addVectorCompose" TARGET="MAIN"><CODE>Cudd_addVectorCompose()</CODE></A> -<DD> Composes an ADD with a vector of 0-1 ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_addWalsh" TARGET="MAIN"><CODE>Cudd_addWalsh()</CODE></A> -<DD> Generates a Walsh matrix in ADD form. - -<DT> <A HREF="cuddAllDet.html#Cudd_addXeqy" TARGET="MAIN"><CODE>Cudd_addXeqy()</CODE></A> -<DD> Generates an ADD for the function x==y. - -<DT> <A HREF="cuddAllDet.html#Cudd_addXnor" TARGET="MAIN"><CODE>Cudd_addXnor()</CODE></A> -<DD> XNOR of two 0-1 ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_addXor" TARGET="MAIN"><CODE>Cudd_addXor()</CODE></A> -<DD> XOR of two 0-1 ADDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddAdjPermuteX" TARGET="MAIN"><CODE>Cudd_bddAdjPermuteX()</CODE></A> -<DD> Rearranges a set of variables in the BDD B. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddAndAbstractLimit" TARGET="MAIN"><CODE>Cudd_bddAndAbstractLimit()</CODE></A> -<DD> Takes the AND of two BDDs and simultaneously abstracts the - variables in cube. Returns NULL if too many nodes are required. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddAndAbstract" TARGET="MAIN"><CODE>Cudd_bddAndAbstract()</CODE></A> -<DD> Takes the AND of two BDDs and simultaneously abstracts the - variables in cube. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddAndLimit" TARGET="MAIN"><CODE>Cudd_bddAndLimit()</CODE></A> -<DD> Computes the conjunction of two BDDs f and g. Returns - NULL if too many nodes are required. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddAnd" TARGET="MAIN"><CODE>Cudd_bddAnd()</CODE></A> -<DD> Computes the conjunction of two BDDs f and g. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddApproxConjDecomp" TARGET="MAIN"><CODE>Cudd_bddApproxConjDecomp()</CODE></A> -<DD> Performs two-way conjunctive decomposition of a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddApproxDisjDecomp" TARGET="MAIN"><CODE>Cudd_bddApproxDisjDecomp()</CODE></A> -<DD> Performs two-way disjunctive decomposition of a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddBindVar" TARGET="MAIN"><CODE>Cudd_bddBindVar()</CODE></A> -<DD> Prevents sifting of a variable. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddBooleanDiff" TARGET="MAIN"><CODE>Cudd_bddBooleanDiff()</CODE></A> -<DD> Computes the boolean difference of f with respect to x. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddCharToVect" TARGET="MAIN"><CODE>Cudd_bddCharToVect()</CODE></A> -<DD> Computes a vector whose image equals a non-zero function. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddClippingAndAbstract" TARGET="MAIN"><CODE>Cudd_bddClippingAndAbstract()</CODE></A> -<DD> Approximates the conjunction of two BDDs f and g and - simultaneously abstracts the variables in cube. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddClippingAnd" TARGET="MAIN"><CODE>Cudd_bddClippingAnd()</CODE></A> -<DD> Approximates the conjunction of two BDDs f and g. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddClosestCube" TARGET="MAIN"><CODE>Cudd_bddClosestCube()</CODE></A> -<DD> Finds a cube of f at minimum Hamming distance from g. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddCompose" TARGET="MAIN"><CODE>Cudd_bddCompose()</CODE></A> -<DD> Substitutes g for x_v in the BDD for f. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddComputeCube" TARGET="MAIN"><CODE>Cudd_bddComputeCube()</CODE></A> -<DD> Computes the cube of an array of BDD variables. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddConstrainDecomp" TARGET="MAIN"><CODE>Cudd_bddConstrainDecomp()</CODE></A> -<DD> BDD conjunctive decomposition as in McMillan's CAV96 paper. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddConstrain" TARGET="MAIN"><CODE>Cudd_bddConstrain()</CODE></A> -<DD> Computes f constrain c. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddCorrelationWeights" TARGET="MAIN"><CODE>Cudd_bddCorrelationWeights()</CODE></A> -<DD> Computes the correlation of f and g for given input - probabilities. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddCorrelation" TARGET="MAIN"><CODE>Cudd_bddCorrelation()</CODE></A> -<DD> Computes the correlation of f and g. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddExistAbstractLimit" TARGET="MAIN"><CODE>Cudd_bddExistAbstractLimit()</CODE></A> -<DD> Existentially abstracts all the variables in cube from f. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddExistAbstract" TARGET="MAIN"><CODE>Cudd_bddExistAbstract()</CODE></A> -<DD> Existentially abstracts all the variables in cube from f. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddGenConjDecomp" TARGET="MAIN"><CODE>Cudd_bddGenConjDecomp()</CODE></A> -<DD> Performs two-way conjunctive decomposition of a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddGenDisjDecomp" TARGET="MAIN"><CODE>Cudd_bddGenDisjDecomp()</CODE></A> -<DD> Performs two-way disjunctive decomposition of a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIntersect" TARGET="MAIN"><CODE>Cudd_bddIntersect()</CODE></A> -<DD> Returns a function included in the intersection of f and g. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddInterval" TARGET="MAIN"><CODE>Cudd_bddInterval()</CODE></A> -<DD> Generates a BDD for the function lowerB ≤ x ≤ upperB. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIsNsVar" TARGET="MAIN"><CODE>Cudd_bddIsNsVar()</CODE></A> -<DD> Checks whether a variable is next state. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIsPiVar" TARGET="MAIN"><CODE>Cudd_bddIsPiVar()</CODE></A> -<DD> Checks whether a variable is primary input. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIsPsVar" TARGET="MAIN"><CODE>Cudd_bddIsPsVar()</CODE></A> -<DD> Checks whether a variable is present state. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIsVarEssential" TARGET="MAIN"><CODE>Cudd_bddIsVarEssential()</CODE></A> -<DD> Determines whether a given variable is essential with a - given phase in a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIsVarHardGroup" TARGET="MAIN"><CODE>Cudd_bddIsVarHardGroup()</CODE></A> -<DD> Checks whether a variable is set to be in a hard group. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIsVarToBeGrouped" TARGET="MAIN"><CODE>Cudd_bddIsVarToBeGrouped()</CODE></A> -<DD> Checks whether a variable is set to be grouped. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIsVarToBeUngrouped" TARGET="MAIN"><CODE>Cudd_bddIsVarToBeUngrouped()</CODE></A> -<DD> Checks whether a variable is set to be ungrouped. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIsop" TARGET="MAIN"><CODE>Cudd_bddIsop()</CODE></A> -<DD> Computes a BDD in the interval between L and U with a - simple sum-of-product cover. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIteConstant" TARGET="MAIN"><CODE>Cudd_bddIteConstant()</CODE></A> -<DD> Implements ITEconstant(f,g,h). - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIteLimit" TARGET="MAIN"><CODE>Cudd_bddIteLimit()</CODE></A> -<DD> Implements ITE(f,g,h). Returns - NULL if too many nodes are required. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIterConjDecomp" TARGET="MAIN"><CODE>Cudd_bddIterConjDecomp()</CODE></A> -<DD> Performs two-way conjunctive decomposition of a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIterDisjDecomp" TARGET="MAIN"><CODE>Cudd_bddIterDisjDecomp()</CODE></A> -<DD> Performs two-way disjunctive decomposition of a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIte" TARGET="MAIN"><CODE>Cudd_bddIte()</CODE></A> -<DD> Implements ITE(f,g,h). - -<DT> <A HREF="cuddAllDet.html#Cudd_bddIthVar" TARGET="MAIN"><CODE>Cudd_bddIthVar()</CODE></A> -<DD> Returns the BDD variable with index i. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddLICompaction" TARGET="MAIN"><CODE>Cudd_bddLICompaction()</CODE></A> -<DD> Performs safe minimization of a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddLargestPrimeUnate" TARGET="MAIN"><CODE>Cudd_bddLargestPrimeUnate()</CODE></A> -<DD> Find a largest prime of a unate function. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddLeqUnless" TARGET="MAIN"><CODE>Cudd_bddLeqUnless()</CODE></A> -<DD> Tells whether f is less than of equal to G unless D is 1. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddLeq" TARGET="MAIN"><CODE>Cudd_bddLeq()</CODE></A> -<DD> Determines whether f is less than or equal to g. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddLiteralSetIntersection" TARGET="MAIN"><CODE>Cudd_bddLiteralSetIntersection()</CODE></A> -<DD> Computes the intesection of two sets of literals - represented as BDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddMakePrime" TARGET="MAIN"><CODE>Cudd_bddMakePrime()</CODE></A> -<DD> Expands cube to a prime implicant of f. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddMaximallyExpand" TARGET="MAIN"><CODE>Cudd_bddMaximallyExpand()</CODE></A> -<DD> Expands lb to prime implicants of (f and ub). - -<DT> <A HREF="cuddAllDet.html#Cudd_bddMinimize" TARGET="MAIN"><CODE>Cudd_bddMinimize()</CODE></A> -<DD> Finds a small BDD that agrees with <code>f</code> over - <code>c</code>. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddNPAnd" TARGET="MAIN"><CODE>Cudd_bddNPAnd()</CODE></A> -<DD> Computes f non-polluting-and g. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddNand" TARGET="MAIN"><CODE>Cudd_bddNand()</CODE></A> -<DD> Computes the NAND of two BDDs f and g. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddNewVarAtLevel" TARGET="MAIN"><CODE>Cudd_bddNewVarAtLevel()</CODE></A> -<DD> Returns a new BDD variable at a specified level. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddNewVar" TARGET="MAIN"><CODE>Cudd_bddNewVar()</CODE></A> -<DD> Returns a new BDD variable. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddNor" TARGET="MAIN"><CODE>Cudd_bddNor()</CODE></A> -<DD> Computes the NOR of two BDDs f and g. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddOrLimit" TARGET="MAIN"><CODE>Cudd_bddOrLimit()</CODE></A> -<DD> Computes the disjunction of two BDDs f and g. Returns - NULL if too many nodes are required. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddOr" TARGET="MAIN"><CODE>Cudd_bddOr()</CODE></A> -<DD> Computes the disjunction of two BDDs f and g. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddPermute" TARGET="MAIN"><CODE>Cudd_bddPermute()</CODE></A> -<DD> Permutes the variables of a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddPickArbitraryMinterms" TARGET="MAIN"><CODE>Cudd_bddPickArbitraryMinterms()</CODE></A> -<DD> Picks k on-set minterms evenly distributed from given DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddPickOneCube" TARGET="MAIN"><CODE>Cudd_bddPickOneCube()</CODE></A> -<DD> Picks one on-set cube randomly from the given DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddPickOneMinterm" TARGET="MAIN"><CODE>Cudd_bddPickOneMinterm()</CODE></A> -<DD> Picks one on-set minterm randomly from the given DD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddPrintCover" TARGET="MAIN"><CODE>Cudd_bddPrintCover()</CODE></A> -<DD> Prints a sum of prime implicants of a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddReadPairIndex" TARGET="MAIN"><CODE>Cudd_bddReadPairIndex()</CODE></A> -<DD> Reads a corresponding pair index for a given index. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddRead" TARGET="MAIN"><CODE>Cudd_bddRead()</CODE></A> -<DD> Reads in a graph (without labels) given as a list of arcs. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddRealignDisable" TARGET="MAIN"><CODE>Cudd_bddRealignDisable()</CODE></A> -<DD> Disables realignment of ZDD order to BDD order. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddRealignEnable" TARGET="MAIN"><CODE>Cudd_bddRealignEnable()</CODE></A> -<DD> Enables realignment of BDD order to ZDD order. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddRealignmentEnabled" TARGET="MAIN"><CODE>Cudd_bddRealignmentEnabled()</CODE></A> -<DD> Tells whether the realignment of BDD order to ZDD order is - enabled. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddResetVarToBeGrouped" TARGET="MAIN"><CODE>Cudd_bddResetVarToBeGrouped()</CODE></A> -<DD> Resets a variable not to be grouped. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddRestrict" TARGET="MAIN"><CODE>Cudd_bddRestrict()</CODE></A> -<DD> BDD restrict according to Coudert and Madre's algorithm - (ICCAD90). - -<DT> <A HREF="cuddAllDet.html#Cudd_bddSetNsVar" TARGET="MAIN"><CODE>Cudd_bddSetNsVar()</CODE></A> -<DD> Sets a variable type to next state. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddSetPairIndex" TARGET="MAIN"><CODE>Cudd_bddSetPairIndex()</CODE></A> -<DD> Sets a corresponding pair index for a given index. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddSetPiVar" TARGET="MAIN"><CODE>Cudd_bddSetPiVar()</CODE></A> -<DD> Sets a variable type to primary input. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddSetPsVar" TARGET="MAIN"><CODE>Cudd_bddSetPsVar()</CODE></A> -<DD> Sets a variable type to present state. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddSetVarHardGroup" TARGET="MAIN"><CODE>Cudd_bddSetVarHardGroup()</CODE></A> -<DD> Sets a variable to be a hard group. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddSetVarToBeGrouped" TARGET="MAIN"><CODE>Cudd_bddSetVarToBeGrouped()</CODE></A> -<DD> Sets a variable to be grouped. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddSetVarToBeUngrouped" TARGET="MAIN"><CODE>Cudd_bddSetVarToBeUngrouped()</CODE></A> -<DD> Sets a variable to be ungrouped. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddSqueeze" TARGET="MAIN"><CODE>Cudd_bddSqueeze()</CODE></A> -<DD> Finds a small BDD in a function interval. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddSwapVariables" TARGET="MAIN"><CODE>Cudd_bddSwapVariables()</CODE></A> -<DD> Swaps two sets of variables of the same size (x and y) in - the BDD f. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddTransfer" TARGET="MAIN"><CODE>Cudd_bddTransfer()</CODE></A> -<DD> Convert a BDD from a manager to another one. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddUnbindVar" TARGET="MAIN"><CODE>Cudd_bddUnbindVar()</CODE></A> -<DD> Allows the sifting of a variable. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddUnivAbstract" TARGET="MAIN"><CODE>Cudd_bddUnivAbstract()</CODE></A> -<DD> Universally abstracts all the variables in cube from f. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddVarConjDecomp" TARGET="MAIN"><CODE>Cudd_bddVarConjDecomp()</CODE></A> -<DD> Performs two-way conjunctive decomposition of a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddVarDisjDecomp" TARGET="MAIN"><CODE>Cudd_bddVarDisjDecomp()</CODE></A> -<DD> Performs two-way disjunctive decomposition of a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddVarIsBound" TARGET="MAIN"><CODE>Cudd_bddVarIsBound()</CODE></A> -<DD> Tells whether a variable can be sifted. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddVarIsDependent" TARGET="MAIN"><CODE>Cudd_bddVarIsDependent()</CODE></A> -<DD> Checks whether a variable is dependent on others in a - function. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddVarMap" TARGET="MAIN"><CODE>Cudd_bddVarMap()</CODE></A> -<DD> Remaps the variables of a BDD using the default variable map. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddVectorCompose" TARGET="MAIN"><CODE>Cudd_bddVectorCompose()</CODE></A> -<DD> Composes a BDD with a vector of BDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddXnorLimit" TARGET="MAIN"><CODE>Cudd_bddXnorLimit()</CODE></A> -<DD> Computes the exclusive NOR of two BDDs f and g. Returns - NULL if too many nodes are required. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddXnor" TARGET="MAIN"><CODE>Cudd_bddXnor()</CODE></A> -<DD> Computes the exclusive NOR of two BDDs f and g. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddXorExistAbstract" TARGET="MAIN"><CODE>Cudd_bddXorExistAbstract()</CODE></A> -<DD> Takes the exclusive OR of two BDDs and simultaneously abstracts the - variables in cube. - -<DT> <A HREF="cuddAllDet.html#Cudd_bddXor" TARGET="MAIN"><CODE>Cudd_bddXor()</CODE></A> -<DD> Computes the exclusive OR of two BDDs f and g. - -<DT> <A HREF="cuddAllDet.html#Cudd_tlcInfoFree" TARGET="MAIN"><CODE>Cudd_tlcInfoFree()</CODE></A> -<DD> Frees a DdTlcInfo Structure. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddChange" TARGET="MAIN"><CODE>Cudd_zddChange()</CODE></A> -<DD> Substitutes a variable with its complement in a ZDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddComplement" TARGET="MAIN"><CODE>Cudd_zddComplement()</CODE></A> -<DD> Computes a complement cover for a ZDD node. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddCountDouble" TARGET="MAIN"><CODE>Cudd_zddCountDouble()</CODE></A> -<DD> Counts the number of minterms of a ZDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddCountMinterm" TARGET="MAIN"><CODE>Cudd_zddCountMinterm()</CODE></A> -<DD> Counts the number of minterms of a ZDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddCount" TARGET="MAIN"><CODE>Cudd_zddCount()</CODE></A> -<DD> Counts the number of minterms in a ZDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddCoverPathToString" TARGET="MAIN"><CODE>Cudd_zddCoverPathToString()</CODE></A> -<DD> Converts a path of a ZDD representing a cover to a string. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddDagSize" TARGET="MAIN"><CODE>Cudd_zddDagSize()</CODE></A> -<DD> Counts the number of nodes in a ZDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddDiffConst" TARGET="MAIN"><CODE>Cudd_zddDiffConst()</CODE></A> -<DD> Performs the inclusion test for ZDDs (P implies Q). - -<DT> <A HREF="cuddAllDet.html#Cudd_zddDiff" TARGET="MAIN"><CODE>Cudd_zddDiff()</CODE></A> -<DD> Computes the difference of two ZDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddDivideF" TARGET="MAIN"><CODE>Cudd_zddDivideF()</CODE></A> -<DD> Modified version of Cudd_zddDivide. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddDivide" TARGET="MAIN"><CODE>Cudd_zddDivide()</CODE></A> -<DD> Computes the quotient of two unate covers. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddDumpDot" TARGET="MAIN"><CODE>Cudd_zddDumpDot()</CODE></A> -<DD> Writes a dot file representing the argument ZDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddFirstPath" TARGET="MAIN"><CODE>Cudd_zddFirstPath()</CODE></A> -<DD> Finds the first path of a ZDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddIntersect" TARGET="MAIN"><CODE>Cudd_zddIntersect()</CODE></A> -<DD> Computes the intersection of two ZDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddIsop" TARGET="MAIN"><CODE>Cudd_zddIsop()</CODE></A> -<DD> Computes an ISOP in ZDD form from BDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddIte" TARGET="MAIN"><CODE>Cudd_zddIte()</CODE></A> -<DD> Computes the ITE of three ZDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddIthVar" TARGET="MAIN"><CODE>Cudd_zddIthVar()</CODE></A> -<DD> Returns the ZDD variable with index i. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddNextPath" TARGET="MAIN"><CODE>Cudd_zddNextPath()</CODE></A> -<DD> Generates the next path of a ZDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddPortFromBdd" TARGET="MAIN"><CODE>Cudd_zddPortFromBdd()</CODE></A> -<DD> Converts a BDD into a ZDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddPortToBdd" TARGET="MAIN"><CODE>Cudd_zddPortToBdd()</CODE></A> -<DD> Converts a ZDD into a BDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddPrintCover" TARGET="MAIN"><CODE>Cudd_zddPrintCover()</CODE></A> -<DD> Prints a sum of products from a ZDD representing a cover. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddPrintDebug" TARGET="MAIN"><CODE>Cudd_zddPrintDebug()</CODE></A> -<DD> Prints to the standard output a ZDD and its statistics. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddPrintMinterm" TARGET="MAIN"><CODE>Cudd_zddPrintMinterm()</CODE></A> -<DD> Prints a disjoint sum of product form for a ZDD. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddPrintSubtable" TARGET="MAIN"><CODE>Cudd_zddPrintSubtable()</CODE></A> -<DD> Prints the ZDD table. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddProduct" TARGET="MAIN"><CODE>Cudd_zddProduct()</CODE></A> -<DD> Computes the product of two covers represented by ZDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddReadNodeCount" TARGET="MAIN"><CODE>Cudd_zddReadNodeCount()</CODE></A> -<DD> Reports the number of nodes in ZDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddRealignDisable" TARGET="MAIN"><CODE>Cudd_zddRealignDisable()</CODE></A> -<DD> Disables realignment of ZDD order to BDD order. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddRealignEnable" TARGET="MAIN"><CODE>Cudd_zddRealignEnable()</CODE></A> -<DD> Enables realignment of ZDD order to BDD order. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddRealignmentEnabled" TARGET="MAIN"><CODE>Cudd_zddRealignmentEnabled()</CODE></A> -<DD> Tells whether the realignment of ZDD order to BDD order is - enabled. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddReduceHeap" TARGET="MAIN"><CODE>Cudd_zddReduceHeap()</CODE></A> -<DD> Main dynamic reordering routine for ZDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddShuffleHeap" TARGET="MAIN"><CODE>Cudd_zddShuffleHeap()</CODE></A> -<DD> Reorders ZDD variables according to given permutation. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddSubset0" TARGET="MAIN"><CODE>Cudd_zddSubset0()</CODE></A> -<DD> Computes the negative cofactor of a ZDD w.r.t. a variable. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddSubset1" TARGET="MAIN"><CODE>Cudd_zddSubset1()</CODE></A> -<DD> Computes the positive cofactor of a ZDD w.r.t. a variable. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddSupport" TARGET="MAIN"><CODE>Cudd_zddSupport()</CODE></A> -<DD> Finds the variables on which a ZDD depends. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddSymmProfile" TARGET="MAIN"><CODE>Cudd_zddSymmProfile()</CODE></A> -<DD> Prints statistics on symmetric ZDD variables. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddUnateProduct" TARGET="MAIN"><CODE>Cudd_zddUnateProduct()</CODE></A> -<DD> Computes the product of two unate covers. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddUnion" TARGET="MAIN"><CODE>Cudd_zddUnion()</CODE></A> -<DD> Computes the union of two ZDDs. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddVarsFromBddVars" TARGET="MAIN"><CODE>Cudd_zddVarsFromBddVars()</CODE></A> -<DD> Creates one or more ZDD variables for each BDD variable. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddWeakDivF" TARGET="MAIN"><CODE>Cudd_zddWeakDivF()</CODE></A> -<DD> Modified version of Cudd_zddWeakDiv. - -<DT> <A HREF="cuddAllDet.html#Cudd_zddWeakDiv" TARGET="MAIN"><CODE>Cudd_zddWeakDiv()</CODE></A> -<DD> Applies weak division to two covers. - -<DT> <A HREF="cuddAllDet.html#MarkCacheCleanUp" TARGET="MAIN"><CODE>MarkCacheCleanUp()</CODE></A> -<DD> Frees memory associated with computed table of - cuddBddLICMarkEdges. - -<DT> <A HREF="cuddAllDet.html#MarkCacheCompare" TARGET="MAIN"><CODE>MarkCacheCompare()</CODE></A> -<DD> Comparison function for the computed table of - cuddBddLICMarkEdges. - -<DT> <A HREF="cuddAllDet.html#MarkCacheHash" TARGET="MAIN"><CODE>MarkCacheHash()</CODE></A> -<DD> Hash function for the computed table of cuddBddLICMarkEdges. - -<DT> <A HREF="cuddAllDet.html#PMX" TARGET="MAIN"><CODE>PMX()</CODE></A> -<DD> Performs the crossover between two parents. - -<DT> <A HREF="cuddAllDet.html#PairInTables" TARGET="MAIN"><CODE>PairInTables()</CODE></A> -<DD> Check whether the given pair is in the tables. - -<DT> <A HREF="cuddAllDet.html#PickOnePair" TARGET="MAIN"><CODE>PickOnePair()</CODE></A> -<DD> Check the tables for the existence of pair and return one - combination, store in cache. - -<DT> <A HREF="cuddAllDet.html#RAbuildSubset" TARGET="MAIN"><CODE>RAbuildSubset()</CODE></A> -<DD> Builds the subset BDD for cuddRemapUnderApprox. - -<DT> <A HREF="cuddAllDet.html#RAmarkNodes" TARGET="MAIN"><CODE>RAmarkNodes()</CODE></A> -<DD> Marks nodes for remapping. - -<DT> <A HREF="cuddAllDet.html#ResizeCountMintermPages" TARGET="MAIN"><CODE>ResizeCountMintermPages()</CODE></A> -<DD> Resize the number of pages allocated to store the minterm - counts. - -<DT> <A HREF="cuddAllDet.html#ResizeCountNodePages" TARGET="MAIN"><CODE>ResizeCountNodePages()</CODE></A> -<DD> Resize the number of pages allocated to store the node counts. - -<DT> <A HREF="cuddAllDet.html#ResizeNodeDataPages" TARGET="MAIN"><CODE>ResizeNodeDataPages()</CODE></A> -<DD> Resize the number of pages allocated to store the node data. - -<DT> <A HREF="cuddAllDet.html#ResizeNodeDistPages" TARGET="MAIN"><CODE>ResizeNodeDistPages()</CODE></A> -<DD> Resize the number of pages allocated to store the distances - related to each node. - -<DT> <A HREF="cuddAllDet.html#ResizeQueuePages" TARGET="MAIN"><CODE>ResizeQueuePages()</CODE></A> -<DD> Resize the number of pages allocated to store nodes in the BFS - traversal of the Bdd . - -<DT> <A HREF="cuddAllDet.html#StoreNodes" TARGET="MAIN"><CODE>StoreNodes()</CODE></A> -<DD> Procedure to recursively store nodes that are retained in the subset. - -<DT> <A HREF="cuddAllDet.html#SubsetCountMintermAux" TARGET="MAIN"><CODE>SubsetCountMintermAux()</CODE></A> -<DD> Recursively counts minterms of each node in the DAG. - -<DT> <A HREF="cuddAllDet.html#SubsetCountMinterm" TARGET="MAIN"><CODE>SubsetCountMinterm()</CODE></A> -<DD> Counts minterms of each node in the DAG - -<DT> <A HREF="cuddAllDet.html#SubsetCountNodesAux" TARGET="MAIN"><CODE>SubsetCountNodesAux()</CODE></A> -<DD> Recursively counts the number of nodes under the dag. - Also counts the number of nodes under the lighter child of - this node. - -<DT> <A HREF="cuddAllDet.html#SubsetCountNodes" TARGET="MAIN"><CODE>SubsetCountNodes()</CODE></A> -<DD> Counts the nodes under the current node and its lighter child - -<DT> <A HREF="cuddAllDet.html#UAbuildSubset" TARGET="MAIN"><CODE>UAbuildSubset()</CODE></A> -<DD> Builds the subset BDD. - -<DT> <A HREF="cuddAllDet.html#UAmarkNodes" TARGET="MAIN"><CODE>UAmarkNodes()</CODE></A> -<DD> Marks nodes for replacement by zero. - -<DT> <A HREF="cuddAllDet.html#ZeroCase" TARGET="MAIN"><CODE>ZeroCase()</CODE></A> -<DD> If one child is zero, do explicitly what Restrict does or better - -<DT> <A HREF="cuddAllDet.html#addBddDoInterval" TARGET="MAIN"><CODE>addBddDoInterval()</CODE></A> -<DD> Performs the recursive step for Cudd_addBddInterval. - -<DT> <A HREF="cuddAllDet.html#addBddDoIthBit" TARGET="MAIN"><CODE>addBddDoIthBit()</CODE></A> -<DD> Performs the recursive step for Cudd_addBddIthBit. - -<DT> <A HREF="cuddAllDet.html#addBddDoStrictThreshold" TARGET="MAIN"><CODE>addBddDoStrictThreshold()</CODE></A> -<DD> Performs the recursive step for Cudd_addBddStrictThreshold. - -<DT> <A HREF="cuddAllDet.html#addBddDoThreshold" TARGET="MAIN"><CODE>addBddDoThreshold()</CODE></A> -<DD> Performs the recursive step for Cudd_addBddThreshold. - -<DT> <A HREF="cuddAllDet.html#addCheckPositiveCube" TARGET="MAIN"><CODE>addCheckPositiveCube()</CODE></A> -<DD> Checks whether cube is an ADD representing the product - of positive literals. - -<DT> <A HREF="cuddAllDet.html#addDoIthBit" TARGET="MAIN"><CODE>addDoIthBit()</CODE></A> -<DD> Performs the recursive step for Cudd_addIthBit. - -<DT> <A HREF="cuddAllDet.html#addMMRecur" TARGET="MAIN"><CODE>addMMRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addMatrixMultiply. - -<DT> <A HREF="cuddAllDet.html#addMultiplicityGroups" TARGET="MAIN"><CODE>addMultiplicityGroups()</CODE></A> -<DD> Adds multiplicity groups to a ZDD variable group tree. - -<DT> <A HREF="cuddAllDet.html#addTriangleRecur" TARGET="MAIN"><CODE>addTriangleRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addTriangle. - -<DT> <A HREF="cuddAllDet.html#addVarToConst" TARGET="MAIN"><CODE>addVarToConst()</CODE></A> -<DD> Replaces variables with constants if possible (part of - canonical form). - -<DT> <A HREF="cuddAllDet.html#addWalshInt" TARGET="MAIN"><CODE>addWalshInt()</CODE></A> -<DD> Implements the recursive step of Cudd_addWalsh. - -<DT> <A HREF="cuddAllDet.html#array_compare" TARGET="MAIN"><CODE>array_compare()</CODE></A> -<DD> Comparison function for the computed table. - -<DT> <A HREF="cuddAllDet.html#array_hash" TARGET="MAIN"><CODE>array_hash()</CODE></A> -<DD> Hash function for the computed table. - -<DT> <A HREF="cuddAllDet.html#bddAnnotateMintermCount" TARGET="MAIN"><CODE>bddAnnotateMintermCount()</CODE></A> -<DD> Annotates every node in the BDD node with its minterm count. - -<DT> <A HREF="cuddAllDet.html#bddCheckPositiveCube" TARGET="MAIN"><CODE>bddCheckPositiveCube()</CODE></A> -<DD> Checks whether cube is an BDD representing the product of - positive literals. - -<DT> <A HREF="cuddAllDet.html#bddCorrelationAux" TARGET="MAIN"><CODE>bddCorrelationAux()</CODE></A> -<DD> Performs the recursive step of Cudd_bddCorrelation. - -<DT> <A HREF="cuddAllDet.html#bddCorrelationWeightsAux" TARGET="MAIN"><CODE>bddCorrelationWeightsAux()</CODE></A> -<DD> Performs the recursive step of Cudd_bddCorrelationWeigths. - -<DT> <A HREF="cuddAllDet.html#bddFixTree" TARGET="MAIN"><CODE>bddFixTree()</CODE></A> -<DD> Fixes the BDD variable group tree after a shuffle. - -<DT> <A HREF="cuddAllDet.html#bddVarToCanonicalSimple" TARGET="MAIN"><CODE>bddVarToCanonicalSimple()</CODE></A> -<DD> Picks unique member from equiv expressions. - -<DT> <A HREF="cuddAllDet.html#bddVarToCanonical" TARGET="MAIN"><CODE>bddVarToCanonical()</CODE></A> -<DD> Picks unique member from equiv expressions. - -<DT> <A HREF="cuddAllDet.html#bddVarToConst" TARGET="MAIN"><CODE>bddVarToConst()</CODE></A> -<DD> Replaces variables with constants if possible. - -<DT> <A HREF="cuddAllDet.html#beforep" TARGET="MAIN"><CODE>beforep()</CODE></A> -<DD> Returns true iff the first argument precedes the second in - the clause order. - -<DT> <A HREF="cuddAllDet.html#bitVectorAlloc" TARGET="MAIN"><CODE>bitVectorAlloc()</CODE></A> -<DD> Allocates a bit vector. - -<DT> <A HREF="cuddAllDet.html#bitVectorFree" TARGET="MAIN"><CODE>bitVectorFree()</CODE></A> -<DD> Frees a bit vector. - -<DT> <A HREF="cuddAllDet.html#build_dd" TARGET="MAIN"><CODE>build_dd()</CODE></A> -<DD> Builds a DD from a given order. - -<DT> <A HREF="cuddAllDet.html#checkSymmInfo" TARGET="MAIN"><CODE>checkSymmInfo()</CODE></A> -<DD> Check symmetry condition. - -<DT> <A HREF="cuddAllDet.html#computeClausesWithUniverse" TARGET="MAIN"><CODE>computeClausesWithUniverse()</CODE></A> -<DD> Computes the two-literal clauses for a node. - -<DT> <A HREF="cuddAllDet.html#computeClauses" TARGET="MAIN"><CODE>computeClauses()</CODE></A> -<DD> Computes the two-literal clauses for a node. - -<DT> <A HREF="cuddAllDet.html#computeLB" TARGET="MAIN"><CODE>computeLB()</CODE></A> -<DD> Computes a lower bound on the size of a BDD. - -<DT> <A HREF="cuddAllDet.html#computeSavings" TARGET="MAIN"><CODE>computeSavings()</CODE></A> -<DD> Counts the nodes that would be eliminated if a given node - were replaced by zero. - -<DT> <A HREF="cuddAllDet.html#copyOrder" TARGET="MAIN"><CODE>copyOrder()</CODE></A> -<DD> Copies the current variable order to array. - -<DT> <A HREF="cuddAllDet.html#createResult" TARGET="MAIN"><CODE>createResult()</CODE></A> -<DD> Builds a result for cache storage. - -<DT> <A HREF="cuddAllDet.html#cuddAddApplyRecur" TARGET="MAIN"><CODE>cuddAddApplyRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addApply. - -<DT> <A HREF="cuddAllDet.html#cuddAddBddDoPattern" TARGET="MAIN"><CODE>cuddAddBddDoPattern()</CODE></A> -<DD> Performs the recursive step for Cudd_addBddPattern. - -<DT> <A HREF="cuddAllDet.html#cuddAddCmplRecur" TARGET="MAIN"><CODE>cuddAddCmplRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addCmpl. - -<DT> <A HREF="cuddAllDet.html#cuddAddComposeRecur" TARGET="MAIN"><CODE>cuddAddComposeRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addCompose. - -<DT> <A HREF="cuddAllDet.html#cuddAddConstrainRecur" TARGET="MAIN"><CODE>cuddAddConstrainRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addConstrain. - -<DT> <A HREF="cuddAllDet.html#cuddAddExistAbstractRecur" TARGET="MAIN"><CODE>cuddAddExistAbstractRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addExistAbstract. - -<DT> <A HREF="cuddAllDet.html#cuddAddGeneralVectorComposeRecur" TARGET="MAIN"><CODE>cuddAddGeneralVectorComposeRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addGeneralVectorCompose. - -<DT> <A HREF="cuddAllDet.html#cuddAddIteRecur" TARGET="MAIN"><CODE>cuddAddIteRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_addIte(f,g,h). - -<DT> <A HREF="cuddAllDet.html#cuddAddMonadicApplyRecur" TARGET="MAIN"><CODE>cuddAddMonadicApplyRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addMonadicApply. - -<DT> <A HREF="cuddAllDet.html#cuddAddNegateRecur" TARGET="MAIN"><CODE>cuddAddNegateRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_addNegate. - -<DT> <A HREF="cuddAllDet.html#cuddAddNonSimComposeRecur" TARGET="MAIN"><CODE>cuddAddNonSimComposeRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addNonSimCompose. - -<DT> <A HREF="cuddAllDet.html#cuddAddOrAbstractRecur" TARGET="MAIN"><CODE>cuddAddOrAbstractRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addOrAbstract. - -<DT> <A HREF="cuddAllDet.html#cuddAddOuterSumRecur" TARGET="MAIN"><CODE>cuddAddOuterSumRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addOuterSum. - -<DT> <A HREF="cuddAllDet.html#cuddAddPermuteRecur" TARGET="MAIN"><CODE>cuddAddPermuteRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_addPermute. - -<DT> <A HREF="cuddAllDet.html#cuddAddRestrictRecur" TARGET="MAIN"><CODE>cuddAddRestrictRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addRestrict. - -<DT> <A HREF="cuddAllDet.html#cuddAddRoundOffRecur" TARGET="MAIN"><CODE>cuddAddRoundOffRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_addRoundOff. - -<DT> <A HREF="cuddAllDet.html#cuddAddScalarInverseRecur" TARGET="MAIN"><CODE>cuddAddScalarInverseRecur()</CODE></A> -<DD> Performs the recursive step of addScalarInverse. - -<DT> <A HREF="cuddAllDet.html#cuddAddUnivAbstractRecur" TARGET="MAIN"><CODE>cuddAddUnivAbstractRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addUnivAbstract. - -<DT> <A HREF="cuddAllDet.html#cuddAddVectorComposeRecur" TARGET="MAIN"><CODE>cuddAddVectorComposeRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_addVectorCompose. - -<DT> <A HREF="cuddAllDet.html#cuddAllocNode" TARGET="MAIN"><CODE>cuddAllocNode()</CODE></A> -<DD> Fast storage allocation for DdNodes in the table. - -<DT> <A HREF="cuddAllDet.html#cuddAnnealing" TARGET="MAIN"><CODE>cuddAnnealing()</CODE></A> -<DD> Get new variable-order by simulated annealing algorithm. - -<DT> <A HREF="cuddAllDet.html#cuddApaCountMintermAux" TARGET="MAIN"><CODE>cuddApaCountMintermAux()</CODE></A> -<DD> Performs the recursive step of Cudd_ApaCountMinterm. - -<DT> <A HREF="cuddAllDet.html#cuddApaStCountfree" TARGET="MAIN"><CODE>cuddApaStCountfree()</CODE></A> -<DD> Frees the memory used to store the minterm counts recorded - in the visited table. - -<DT> <A HREF="cuddAllDet.html#cuddBddAlignToZdd" TARGET="MAIN"><CODE>cuddBddAlignToZdd()</CODE></A> -<DD> Reorders BDD variables according to the order of the ZDD - variables. - -<DT> <A HREF="cuddAllDet.html#cuddBddAndAbstractRecur" TARGET="MAIN"><CODE>cuddBddAndAbstractRecur()</CODE></A> -<DD> Takes the AND of two BDDs and simultaneously abstracts the - variables in cube. - -<DT> <A HREF="cuddAllDet.html#cuddBddAndRecur" TARGET="MAIN"><CODE>cuddBddAndRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_bddAnd. - -<DT> <A HREF="cuddAllDet.html#cuddBddBooleanDiffRecur" TARGET="MAIN"><CODE>cuddBddBooleanDiffRecur()</CODE></A> -<DD> Performs the recursive steps of Cudd_bddBoleanDiff. - -<DT> <A HREF="cuddAllDet.html#cuddBddCharToVect" TARGET="MAIN"><CODE>cuddBddCharToVect()</CODE></A> -<DD> Performs the recursive step of Cudd_bddCharToVect. - -<DT> <A HREF="cuddAllDet.html#cuddBddClipAndAbsRecur" TARGET="MAIN"><CODE>cuddBddClipAndAbsRecur()</CODE></A> -<DD> Approximates the AND of two BDDs and simultaneously abstracts the - variables in cube. - -<DT> <A HREF="cuddAllDet.html#cuddBddClippingAndAbstract" TARGET="MAIN"><CODE>cuddBddClippingAndAbstract()</CODE></A> -<DD> Approximates the conjunction of two BDDs f and g and - simultaneously abstracts the variables in cube. - -<DT> <A HREF="cuddAllDet.html#cuddBddClippingAndRecur" TARGET="MAIN"><CODE>cuddBddClippingAndRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_bddClippingAnd. - -<DT> <A HREF="cuddAllDet.html#cuddBddClippingAnd" TARGET="MAIN"><CODE>cuddBddClippingAnd()</CODE></A> -<DD> Approximates the conjunction of two BDDs f and g. - -<DT> <A HREF="cuddAllDet.html#cuddBddClosestCube" TARGET="MAIN"><CODE>cuddBddClosestCube()</CODE></A> -<DD> Performs the recursive step of Cudd_bddClosestCube. - -<DT> <A HREF="cuddAllDet.html#cuddBddComposeRecur" TARGET="MAIN"><CODE>cuddBddComposeRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_bddCompose. - -<DT> <A HREF="cuddAllDet.html#cuddBddConstrainDecomp" TARGET="MAIN"><CODE>cuddBddConstrainDecomp()</CODE></A> -<DD> Performs the recursive step of Cudd_bddConstrainDecomp. - -<DT> <A HREF="cuddAllDet.html#cuddBddConstrainRecur" TARGET="MAIN"><CODE>cuddBddConstrainRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_bddConstrain. - -<DT> <A HREF="cuddAllDet.html#cuddBddExistAbstractRecur" TARGET="MAIN"><CODE>cuddBddExistAbstractRecur()</CODE></A> -<DD> Performs the recursive steps of Cudd_bddExistAbstract. - -<DT> <A HREF="cuddAllDet.html#cuddBddIntersectRecur" TARGET="MAIN"><CODE>cuddBddIntersectRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_bddIntersect. - -<DT> <A HREF="cuddAllDet.html#cuddBddIsop" TARGET="MAIN"><CODE>cuddBddIsop()</CODE></A> -<DD> Performs the recursive step of Cudd_bddIsop. - -<DT> <A HREF="cuddAllDet.html#cuddBddIteRecur" TARGET="MAIN"><CODE>cuddBddIteRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_bddIte. - -<DT> <A HREF="cuddAllDet.html#cuddBddLICBuildResult" TARGET="MAIN"><CODE>cuddBddLICBuildResult()</CODE></A> -<DD> Builds the result of Cudd_bddLICompaction. - -<DT> <A HREF="cuddAllDet.html#cuddBddLICMarkEdges" TARGET="MAIN"><CODE>cuddBddLICMarkEdges()</CODE></A> -<DD> Performs the edge marking step of Cudd_bddLICompaction. - -<DT> <A HREF="cuddAllDet.html#cuddBddLICompaction" TARGET="MAIN"><CODE>cuddBddLICompaction()</CODE></A> -<DD> Performs safe minimization of a BDD. - -<DT> <A HREF="cuddAllDet.html#cuddBddLiteralSetIntersectionRecur" TARGET="MAIN"><CODE>cuddBddLiteralSetIntersectionRecur()</CODE></A> -<DD> Performs the recursive step of - Cudd_bddLiteralSetIntersection. - -<DT> <A HREF="cuddAllDet.html#cuddBddMakePrime" TARGET="MAIN"><CODE>cuddBddMakePrime()</CODE></A> -<DD> Performs the recursive step of Cudd_bddMakePrime. - -<DT> <A HREF="cuddAllDet.html#cuddBddNPAndRecur" TARGET="MAIN"><CODE>cuddBddNPAndRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_bddAnd. - -<DT> <A HREF="cuddAllDet.html#cuddBddPermuteRecur" TARGET="MAIN"><CODE>cuddBddPermuteRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_bddPermute. - -<DT> <A HREF="cuddAllDet.html#cuddBddRestrictRecur" TARGET="MAIN"><CODE>cuddBddRestrictRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_bddRestrict. - -<DT> <A HREF="cuddAllDet.html#cuddBddSqueeze" TARGET="MAIN"><CODE>cuddBddSqueeze()</CODE></A> -<DD> Performs the recursive step of Cudd_bddSqueeze. - -<DT> <A HREF="cuddAllDet.html#cuddBddTransferRecur" TARGET="MAIN"><CODE>cuddBddTransferRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_bddTransfer. - -<DT> <A HREF="cuddAllDet.html#cuddBddTransfer" TARGET="MAIN"><CODE>cuddBddTransfer()</CODE></A> -<DD> Convert a BDD from a manager to another one. - -<DT> <A HREF="cuddAllDet.html#cuddBddVarMapRecur" TARGET="MAIN"><CODE>cuddBddVarMapRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_bddVarMap. - -<DT> <A HREF="cuddAllDet.html#cuddBddVectorComposeRecur" TARGET="MAIN"><CODE>cuddBddVectorComposeRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_bddVectorCompose. - -<DT> <A HREF="cuddAllDet.html#cuddBddXorExistAbstractRecur" TARGET="MAIN"><CODE>cuddBddXorExistAbstractRecur()</CODE></A> -<DD> Takes the exclusive OR of two BDDs and simultaneously abstracts the - variables in cube. - -<DT> <A HREF="cuddAllDet.html#cuddBddXorRecur" TARGET="MAIN"><CODE>cuddBddXorRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_bddXor. - -<DT> <A HREF="cuddAllDet.html#cuddBiasedUnderApprox" TARGET="MAIN"><CODE>cuddBiasedUnderApprox()</CODE></A> -<DD> Applies the biased remapping underappoximation algorithm. - -<DT> <A HREF="cuddAllDet.html#cuddCProjectionRecur" TARGET="MAIN"><CODE>cuddCProjectionRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_CProjection. - -<DT> <A HREF="cuddAllDet.html#cuddCacheFlush" TARGET="MAIN"><CODE>cuddCacheFlush()</CODE></A> -<DD> Flushes the cache. - -<DT> <A HREF="cuddAllDet.html#cuddCacheInsert1" TARGET="MAIN"><CODE>cuddCacheInsert1()</CODE></A> -<DD> Inserts a result in the cache for a function with two - operands. - -<DT> <A HREF="cuddAllDet.html#cuddCacheInsert2" TARGET="MAIN"><CODE>cuddCacheInsert2()</CODE></A> -<DD> Inserts a result in the cache for a function with two - operands. - -<DT> <A HREF="cuddAllDet.html#cuddCacheInsert" TARGET="MAIN"><CODE>cuddCacheInsert()</CODE></A> -<DD> Inserts a result in the cache for a function with three - operands. - -<DT> <A HREF="cuddAllDet.html#cuddCacheLookup1Zdd" TARGET="MAIN"><CODE>cuddCacheLookup1Zdd()</CODE></A> -<DD> Looks up in the cache for the result of op applied to f. - -<DT> <A HREF="cuddAllDet.html#cuddCacheLookup1" TARGET="MAIN"><CODE>cuddCacheLookup1()</CODE></A> -<DD> Looks up in the cache for the result of op applied to f. - -<DT> <A HREF="cuddAllDet.html#cuddCacheLookup2Zdd" TARGET="MAIN"><CODE>cuddCacheLookup2Zdd()</CODE></A> -<DD> Looks up in the cache for the result of op applied to f - and g. - -<DT> <A HREF="cuddAllDet.html#cuddCacheLookup2" TARGET="MAIN"><CODE>cuddCacheLookup2()</CODE></A> -<DD> Looks up in the cache for the result of op applied to f - and g. - -<DT> <A HREF="cuddAllDet.html#cuddCacheLookupZdd" TARGET="MAIN"><CODE>cuddCacheLookupZdd()</CODE></A> -<DD> Looks up in the cache for the result of op applied to f, - g, and h. - -<DT> <A HREF="cuddAllDet.html#cuddCacheLookup" TARGET="MAIN"><CODE>cuddCacheLookup()</CODE></A> -<DD> Looks up in the cache for the result of op applied to f, - g, and h. - -<DT> <A HREF="cuddAllDet.html#cuddCacheProfile" TARGET="MAIN"><CODE>cuddCacheProfile()</CODE></A> -<DD> Computes and prints a profile of the cache usage. - -<DT> <A HREF="cuddAllDet.html#cuddCacheResize" TARGET="MAIN"><CODE>cuddCacheResize()</CODE></A> -<DD> Resizes the cache. - -<DT> <A HREF="cuddAllDet.html#cuddCheckCollisionOrdering" TARGET="MAIN"><CODE>cuddCheckCollisionOrdering()</CODE></A> -<DD> Checks whether a collision list is ordered. - -<DT> <A HREF="cuddAllDet.html#cuddClearDeathRow" TARGET="MAIN"><CODE>cuddClearDeathRow()</CODE></A> -<DD> Clears the death row. - -<DT> <A HREF="cuddAllDet.html#cuddCofactorRecur" TARGET="MAIN"><CODE>cuddCofactorRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_Cofactor. - -<DT> <A HREF="cuddAllDet.html#cuddCollectNodes" TARGET="MAIN"><CODE>cuddCollectNodes()</CODE></A> -<DD> Recursively collects all the nodes of a DD in a symbol - table. - -<DT> <A HREF="cuddAllDet.html#cuddComputeFloorLog2" TARGET="MAIN"><CODE>cuddComputeFloorLog2()</CODE></A> -<DD> Returns the floor of the logarithm to the base 2. - -<DT> <A HREF="cuddAllDet.html#cuddConjunctsAux" TARGET="MAIN"><CODE>cuddConjunctsAux()</CODE></A> -<DD> Procedure to compute two conjunctive factors of f and place in *c1 and *c2. - -<DT> <A HREF="cuddAllDet.html#cuddConstantLookup" TARGET="MAIN"><CODE>cuddConstantLookup()</CODE></A> -<DD> Looks up in the cache for the result of op applied to f, - g, and h. - -<DT> <A HREF="cuddAllDet.html#cuddDestroySubtables" TARGET="MAIN"><CODE>cuddDestroySubtables()</CODE></A> -<DD> Destroys the n most recently created subtables in a unique table. - -<DT> <A HREF="cuddAllDet.html#cuddDoRebalance" TARGET="MAIN"><CODE>cuddDoRebalance()</CODE></A> -<DD> Rebalances a red/black tree. - -<DT> <A HREF="cuddAllDet.html#cuddDynamicAllocNode" TARGET="MAIN"><CODE>cuddDynamicAllocNode()</CODE></A> -<DD> Dynamically allocates a Node. - -<DT> <A HREF="cuddAllDet.html#cuddEstimateCofactorSimple" TARGET="MAIN"><CODE>cuddEstimateCofactorSimple()</CODE></A> -<DD> Performs the recursive step of Cudd_CofactorEstimateSimple. - -<DT> <A HREF="cuddAllDet.html#cuddEstimateCofactor" TARGET="MAIN"><CODE>cuddEstimateCofactor()</CODE></A> -<DD> Performs the recursive step of Cudd_CofactorEstimate. - -<DT> <A HREF="cuddAllDet.html#cuddExact" TARGET="MAIN"><CODE>cuddExact()</CODE></A> -<DD> Exact variable ordering algorithm. - -<DT> <A HREF="cuddAllDet.html#cuddFindParent" TARGET="MAIN"><CODE>cuddFindParent()</CODE></A> -<DD> Searches the subtables above node for a parent. - -<DT> <A HREF="cuddAllDet.html#cuddFreeTable" TARGET="MAIN"><CODE>cuddFreeTable()</CODE></A> -<DD> Frees the resources associated to a unique table. - -<DT> <A HREF="cuddAllDet.html#cuddGarbageCollect" TARGET="MAIN"><CODE>cuddGarbageCollect()</CODE></A> -<DD> Performs garbage collection on the unique tables. - -<DT> <A HREF="cuddAllDet.html#cuddGa" TARGET="MAIN"><CODE>cuddGa()</CODE></A> -<DD> Genetic algorithm for DD reordering. - -<DT> <A HREF="cuddAllDet.html#cuddGetBranches" TARGET="MAIN"><CODE>cuddGetBranches()</CODE></A> -<DD> Computes the children of g. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableGenericInsert" TARGET="MAIN"><CODE>cuddHashTableGenericInsert()</CODE></A> -<DD> Inserts an item in a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableGenericLookup" TARGET="MAIN"><CODE>cuddHashTableGenericLookup()</CODE></A> -<DD> Looks up a key consisting of one pointer in a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableGenericQuit" TARGET="MAIN"><CODE>cuddHashTableGenericQuit()</CODE></A> -<DD> Shuts down a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableInit" TARGET="MAIN"><CODE>cuddHashTableInit()</CODE></A> -<DD> Initializes a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableInsert1" TARGET="MAIN"><CODE>cuddHashTableInsert1()</CODE></A> -<DD> Inserts an item in a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableInsert2" TARGET="MAIN"><CODE>cuddHashTableInsert2()</CODE></A> -<DD> Inserts an item in a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableInsert3" TARGET="MAIN"><CODE>cuddHashTableInsert3()</CODE></A> -<DD> Inserts an item in a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableInsert" TARGET="MAIN"><CODE>cuddHashTableInsert()</CODE></A> -<DD> Inserts an item in a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableLookup1" TARGET="MAIN"><CODE>cuddHashTableLookup1()</CODE></A> -<DD> Looks up a key consisting of one pointer in a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableLookup2" TARGET="MAIN"><CODE>cuddHashTableLookup2()</CODE></A> -<DD> Looks up a key consisting of two pointers in a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableLookup3" TARGET="MAIN"><CODE>cuddHashTableLookup3()</CODE></A> -<DD> Looks up a key consisting of three pointers in a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableLookup" TARGET="MAIN"><CODE>cuddHashTableLookup()</CODE></A> -<DD> Looks up a key in a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableQuit" TARGET="MAIN"><CODE>cuddHashTableQuit()</CODE></A> -<DD> Shuts down a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHashTableResize" TARGET="MAIN"><CODE>cuddHashTableResize()</CODE></A> -<DD> Resizes a hash table. - -<DT> <A HREF="cuddAllDet.html#cuddHeapProfile" TARGET="MAIN"><CODE>cuddHeapProfile()</CODE></A> -<DD> Prints information about the heap. - -<DT> <A HREF="cuddAllDet.html#cuddInitCache" TARGET="MAIN"><CODE>cuddInitCache()</CODE></A> -<DD> Initializes the computed table. - -<DT> <A HREF="cuddAllDet.html#cuddInitInteract" TARGET="MAIN"><CODE>cuddInitInteract()</CODE></A> -<DD> Initializes the interaction matrix. - -<DT> <A HREF="cuddAllDet.html#cuddInitLinear" TARGET="MAIN"><CODE>cuddInitLinear()</CODE></A> -<DD> Initializes the linear transform matrix. - -<DT> <A HREF="cuddAllDet.html#cuddInitTable" TARGET="MAIN"><CODE>cuddInitTable()</CODE></A> -<DD> Creates and initializes the unique table. - -<DT> <A HREF="cuddAllDet.html#cuddInsertSubtables" TARGET="MAIN"><CODE>cuddInsertSubtables()</CODE></A> -<DD> Inserts n new subtables in a unique table at level. - -<DT> <A HREF="cuddAllDet.html#cuddIsInDeathRow" TARGET="MAIN"><CODE>cuddIsInDeathRow()</CODE></A> -<DD> Checks whether a node is in the death row. - -<DT> <A HREF="cuddAllDet.html#cuddLevelQueueDequeue" TARGET="MAIN"><CODE>cuddLevelQueueDequeue()</CODE></A> -<DD> Remove an item from the front of a level queue. - -<DT> <A HREF="cuddAllDet.html#cuddLevelQueueEnqueue" TARGET="MAIN"><CODE>cuddLevelQueueEnqueue()</CODE></A> -<DD> Inserts a new key in a level queue. - -<DT> <A HREF="cuddAllDet.html#cuddLevelQueueFirst" TARGET="MAIN"><CODE>cuddLevelQueueFirst()</CODE></A> -<DD> Inserts the first key in a level queue. - -<DT> <A HREF="cuddAllDet.html#cuddLevelQueueInit" TARGET="MAIN"><CODE>cuddLevelQueueInit()</CODE></A> -<DD> Initializes a level queue. - -<DT> <A HREF="cuddAllDet.html#cuddLevelQueueQuit" TARGET="MAIN"><CODE>cuddLevelQueueQuit()</CODE></A> -<DD> Shuts down a level queue. - -<DT> <A HREF="cuddAllDet.html#cuddLinearAndSifting" TARGET="MAIN"><CODE>cuddLinearAndSifting()</CODE></A> -<DD> BDD reduction based on combination of sifting and linear - transformations. - -<DT> <A HREF="cuddAllDet.html#cuddLinearInPlace" TARGET="MAIN"><CODE>cuddLinearInPlace()</CODE></A> -<DD> Linearly combines two adjacent variables. - -<DT> <A HREF="cuddAllDet.html#cuddLocalCacheAddToList" TARGET="MAIN"><CODE>cuddLocalCacheAddToList()</CODE></A> -<DD> Inserts a local cache in the manager list. - -<DT> <A HREF="cuddAllDet.html#cuddLocalCacheClearAll" TARGET="MAIN"><CODE>cuddLocalCacheClearAll()</CODE></A> -<DD> Clears the local caches of a manager. - -<DT> <A HREF="cuddAllDet.html#cuddLocalCacheClearDead" TARGET="MAIN"><CODE>cuddLocalCacheClearDead()</CODE></A> -<DD> Clears the dead entries of the local caches of a manager. - -<DT> <A HREF="cuddAllDet.html#cuddLocalCacheInit" TARGET="MAIN"><CODE>cuddLocalCacheInit()</CODE></A> -<DD> Initializes a local computed table. - -<DT> <A HREF="cuddAllDet.html#cuddLocalCacheInsert" TARGET="MAIN"><CODE>cuddLocalCacheInsert()</CODE></A> -<DD> Inserts a result in a local cache. - -<DT> <A HREF="cuddAllDet.html#cuddLocalCacheLookup" TARGET="MAIN"><CODE>cuddLocalCacheLookup()</CODE></A> -<DD> Looks up in a local cache. - -<DT> <A HREF="cuddAllDet.html#cuddLocalCacheProfile" TARGET="MAIN"><CODE>cuddLocalCacheProfile()</CODE></A> -<DD> Computes and prints a profile of a local cache usage. - -<DT> <A HREF="cuddAllDet.html#cuddLocalCacheQuit" TARGET="MAIN"><CODE>cuddLocalCacheQuit()</CODE></A> -<DD> Shuts down a local computed table. - -<DT> <A HREF="cuddAllDet.html#cuddLocalCacheRemoveFromList" TARGET="MAIN"><CODE>cuddLocalCacheRemoveFromList()</CODE></A> -<DD> Removes a local cache from the manager list. - -<DT> <A HREF="cuddAllDet.html#cuddLocalCacheResize" TARGET="MAIN"><CODE>cuddLocalCacheResize()</CODE></A> -<DD> Resizes a local cache. - -<DT> <A HREF="cuddAllDet.html#cuddMakeBddFromZddCover" TARGET="MAIN"><CODE>cuddMakeBddFromZddCover()</CODE></A> -<DD> Converts a ZDD cover to a BDD. - -<DT> <A HREF="cuddAllDet.html#cuddMinHammingDistRecur" TARGET="MAIN"><CODE>cuddMinHammingDistRecur()</CODE></A> -<DD> Performs the recursive step of Cudd_MinHammingDist. - -<DT> <A HREF="cuddAllDet.html#cuddNextHigh" TARGET="MAIN"><CODE>cuddNextHigh()</CODE></A> -<DD> Finds the next subtable with a larger index. - -<DT> <A HREF="cuddAllDet.html#cuddNextLow" TARGET="MAIN"><CODE>cuddNextLow()</CODE></A> -<DD> Finds the next subtable with a smaller index. - -<DT> <A HREF="cuddAllDet.html#cuddNodeArrayRecur" TARGET="MAIN"><CODE>cuddNodeArrayRecur()</CODE></A> -<DD> Performs the recursive step of cuddNodeArray. - -<DT> <A HREF="cuddAllDet.html#cuddNodeArray" TARGET="MAIN"><CODE>cuddNodeArray()</CODE></A> -<DD> Recursively collects all the nodes of a DD in an array. - -<DT> <A HREF="cuddAllDet.html#cuddOrderedInsert" TARGET="MAIN"><CODE>cuddOrderedInsert()</CODE></A> -<DD> Inserts a DdNode in a red/black search tree. - -<DT> <A HREF="cuddAllDet.html#cuddOrderedThread" TARGET="MAIN"><CODE>cuddOrderedThread()</CODE></A> -<DD> Threads all the nodes of a search tree into a linear list. - -<DT> <A HREF="cuddAllDet.html#cuddPrintNode" TARGET="MAIN"><CODE>cuddPrintNode()</CODE></A> -<DD> Prints out information on a node. - -<DT> <A HREF="cuddAllDet.html#cuddPrintVarGroups" TARGET="MAIN"><CODE>cuddPrintVarGroups()</CODE></A> -<DD> Prints the variable groups as a parenthesized list. - -<DT> <A HREF="cuddAllDet.html#cuddP" TARGET="MAIN"><CODE>cuddP()</CODE></A> -<DD> Prints a DD to the standard output. One line per node is - printed. - -<DT> <A HREF="cuddAllDet.html#cuddReclaimZdd" TARGET="MAIN"><CODE>cuddReclaimZdd()</CODE></A> -<DD> Brings children of a dead ZDD node back. - -<DT> <A HREF="cuddAllDet.html#cuddReclaim" TARGET="MAIN"><CODE>cuddReclaim()</CODE></A> -<DD> Brings children of a dead node back. - -<DT> <A HREF="cuddAllDet.html#cuddRehash" TARGET="MAIN"><CODE>cuddRehash()</CODE></A> -<DD> Rehashes a unique subtable. - -<DT> <A HREF="cuddAllDet.html#cuddRemapUnderApprox" TARGET="MAIN"><CODE>cuddRemapUnderApprox()</CODE></A> -<DD> Applies the remapping underappoximation algorithm. - -<DT> <A HREF="cuddAllDet.html#cuddResizeLinear" TARGET="MAIN"><CODE>cuddResizeLinear()</CODE></A> -<DD> Resizes the linear transform matrix. - -<DT> <A HREF="cuddAllDet.html#cuddResizeTableZdd" TARGET="MAIN"><CODE>cuddResizeTableZdd()</CODE></A> -<DD> Increases the number of ZDD subtables in a unique table so - that it meets or exceeds index. - -<DT> <A HREF="cuddAllDet.html#cuddSetInteract" TARGET="MAIN"><CODE>cuddSetInteract()</CODE></A> -<DD> Set interaction matrix entries. - -<DT> <A HREF="cuddAllDet.html#cuddShrinkDeathRow" TARGET="MAIN"><CODE>cuddShrinkDeathRow()</CODE></A> -<DD> Shrinks the death row. - -<DT> <A HREF="cuddAllDet.html#cuddShrinkSubtable" TARGET="MAIN"><CODE>cuddShrinkSubtable()</CODE></A> -<DD> Shrinks a subtable. - -<DT> <A HREF="cuddAllDet.html#cuddSifting" TARGET="MAIN"><CODE>cuddSifting()</CODE></A> -<DD> Implementation of Rudell's sifting algorithm. - -<DT> <A HREF="cuddAllDet.html#cuddSlowTableGrowth" TARGET="MAIN"><CODE>cuddSlowTableGrowth()</CODE></A> -<DD> Adjusts parameters of a table to slow down its growth. - -<DT> <A HREF="cuddAllDet.html#cuddSolveEqnRecur" TARGET="MAIN"><CODE>cuddSolveEqnRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_SolveEqn. - -<DT> <A HREF="cuddAllDet.html#cuddSplitSetRecur" TARGET="MAIN"><CODE>cuddSplitSetRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_SplitSet. - -<DT> <A HREF="cuddAllDet.html#cuddStCountfree" TARGET="MAIN"><CODE>cuddStCountfree()</CODE></A> -<DD> Frees the memory used to store the minterm counts recorded - in the visited table. - -<DT> <A HREF="cuddAllDet.html#cuddSubsetHeavyBranch" TARGET="MAIN"><CODE>cuddSubsetHeavyBranch()</CODE></A> -<DD> The main procedure that returns a subset by choosing the heavier - branch in the BDD. - -<DT> <A HREF="cuddAllDet.html#cuddSubsetShortPaths" TARGET="MAIN"><CODE>cuddSubsetShortPaths()</CODE></A> -<DD> The outermost procedure to return a subset of the given BDD - with the shortest path lengths. - -<DT> <A HREF="cuddAllDet.html#cuddSwapInPlace" TARGET="MAIN"><CODE>cuddSwapInPlace()</CODE></A> -<DD> Swaps two adjacent variables. - -<DT> <A HREF="cuddAllDet.html#cuddSwapping" TARGET="MAIN"><CODE>cuddSwapping()</CODE></A> -<DD> Reorders variables by a sequence of (non-adjacent) swaps. - -<DT> <A HREF="cuddAllDet.html#cuddSymmCheck" TARGET="MAIN"><CODE>cuddSymmCheck()</CODE></A> -<DD> Checks for symmetry of x and y. - -<DT> <A HREF="cuddAllDet.html#cuddSymmSiftingConv" TARGET="MAIN"><CODE>cuddSymmSiftingConv()</CODE></A> -<DD> Symmetric sifting to convergence algorithm. - -<DT> <A HREF="cuddAllDet.html#cuddSymmSifting" TARGET="MAIN"><CODE>cuddSymmSifting()</CODE></A> -<DD> Symmetric sifting algorithm. - -<DT> <A HREF="cuddAllDet.html#cuddTestInteract" TARGET="MAIN"><CODE>cuddTestInteract()</CODE></A> -<DD> Test interaction matrix entries. - -<DT> <A HREF="cuddAllDet.html#cuddTimesInDeathRow" TARGET="MAIN"><CODE>cuddTimesInDeathRow()</CODE></A> -<DD> Counts how many times a node is in the death row. - -<DT> <A HREF="cuddAllDet.html#cuddTreeSifting" TARGET="MAIN"><CODE>cuddTreeSifting()</CODE></A> -<DD> Tree sifting algorithm. - -<DT> <A HREF="cuddAllDet.html#cuddUnderApprox" TARGET="MAIN"><CODE>cuddUnderApprox()</CODE></A> -<DD> Applies Tom Shiple's underappoximation algorithm. - -<DT> <A HREF="cuddAllDet.html#cuddUniqueConst" TARGET="MAIN"><CODE>cuddUniqueConst()</CODE></A> -<DD> Checks the unique table for the existence of a constant node. - -<DT> <A HREF="cuddAllDet.html#cuddUniqueInterIVO" TARGET="MAIN"><CODE>cuddUniqueInterIVO()</CODE></A> -<DD> Wrapper for cuddUniqueInter that is independent of variable - ordering. - -<DT> <A HREF="cuddAllDet.html#cuddUniqueInterZdd" TARGET="MAIN"><CODE>cuddUniqueInterZdd()</CODE></A> -<DD> Checks the unique table for the existence of an internal - ZDD node. - -<DT> <A HREF="cuddAllDet.html#cuddUniqueInter" TARGET="MAIN"><CODE>cuddUniqueInter()</CODE></A> -<DD> Checks the unique table for the existence of an internal node. - -<DT> <A HREF="cuddAllDet.html#cuddUniqueLookup" TARGET="MAIN"><CODE>cuddUniqueLookup()</CODE></A> -<DD> Checks the unique table for the existence of an internal node. - -<DT> <A HREF="cuddAllDet.html#cuddUpdateInteractionMatrix" TARGET="MAIN"><CODE>cuddUpdateInteractionMatrix()</CODE></A> -<DD> Updates the interaction matrix. - -<DT> <A HREF="cuddAllDet.html#cuddVerifySol" TARGET="MAIN"><CODE>cuddVerifySol()</CODE></A> -<DD> Implements the recursive step of Cudd_VerifySol. - -<DT> <A HREF="cuddAllDet.html#cuddWindowReorder" TARGET="MAIN"><CODE>cuddWindowReorder()</CODE></A> -<DD> Reorders by applying the method of the sliding window. - -<DT> <A HREF="cuddAllDet.html#cuddXorLinear" TARGET="MAIN"><CODE>cuddXorLinear()</CODE></A> -<DD> XORs two rows of the linear transform matrix. - -<DT> <A HREF="cuddAllDet.html#cuddZddAlignToBdd" TARGET="MAIN"><CODE>cuddZddAlignToBdd()</CODE></A> -<DD> Reorders ZDD variables according to the order of the BDD - variables. - -<DT> <A HREF="cuddAllDet.html#cuddZddChangeAux" TARGET="MAIN"><CODE>cuddZddChangeAux()</CODE></A> -<DD> Performs the recursive step of Cudd_zddChange. - -<DT> <A HREF="cuddAllDet.html#cuddZddChange" TARGET="MAIN"><CODE>cuddZddChange()</CODE></A> -<DD> Substitutes a variable with its complement in a ZDD. - -<DT> <A HREF="cuddAllDet.html#cuddZddComplement" TARGET="MAIN"><CODE>cuddZddComplement()</CODE></A> -<DD> Computes a complement of a ZDD node. - -<DT> <A HREF="cuddAllDet.html#cuddZddCountDoubleStep" TARGET="MAIN"><CODE>cuddZddCountDoubleStep()</CODE></A> -<DD> Performs the recursive step of Cudd_zddCountDouble. - -<DT> <A HREF="cuddAllDet.html#cuddZddCountStep" TARGET="MAIN"><CODE>cuddZddCountStep()</CODE></A> -<DD> Performs the recursive step of Cudd_zddCount. - -<DT> <A HREF="cuddAllDet.html#cuddZddDagInt" TARGET="MAIN"><CODE>cuddZddDagInt()</CODE></A> -<DD> Performs the recursive step of Cudd_zddDagSize. - -<DT> <A HREF="cuddAllDet.html#cuddZddDiff" TARGET="MAIN"><CODE>cuddZddDiff()</CODE></A> -<DD> Performs the recursive step of Cudd_zddDiff. - -<DT> <A HREF="cuddAllDet.html#cuddZddDivideF" TARGET="MAIN"><CODE>cuddZddDivideF()</CODE></A> -<DD> Performs the recursive step of Cudd_zddDivideF. - -<DT> <A HREF="cuddAllDet.html#cuddZddDivide" TARGET="MAIN"><CODE>cuddZddDivide()</CODE></A> -<DD> Performs the recursive step of Cudd_zddDivide. - -<DT> <A HREF="cuddAllDet.html#cuddZddFreeUniv" TARGET="MAIN"><CODE>cuddZddFreeUniv()</CODE></A> -<DD> Frees the ZDD universe. - -<DT> <A HREF="cuddAllDet.html#cuddZddGetCofactors2" TARGET="MAIN"><CODE>cuddZddGetCofactors2()</CODE></A> -<DD> Computes the two-way decomposition of f w.r.t. v. - -<DT> <A HREF="cuddAllDet.html#cuddZddGetCofactors3" TARGET="MAIN"><CODE>cuddZddGetCofactors3()</CODE></A> -<DD> Computes the three-way decomposition of f w.r.t. v. - -<DT> <A HREF="cuddAllDet.html#cuddZddGetNegVarIndex" TARGET="MAIN"><CODE>cuddZddGetNegVarIndex()</CODE></A> -<DD> Returns the index of negative ZDD variable. - -<DT> <A HREF="cuddAllDet.html#cuddZddGetNegVarLevel" TARGET="MAIN"><CODE>cuddZddGetNegVarLevel()</CODE></A> -<DD> Returns the level of negative ZDD variable. - -<DT> <A HREF="cuddAllDet.html#cuddZddGetNodeIVO" TARGET="MAIN"><CODE>cuddZddGetNodeIVO()</CODE></A> -<DD> Wrapper for cuddUniqueInterZdd that is independent of variable - ordering. - -<DT> <A HREF="cuddAllDet.html#cuddZddGetNode" TARGET="MAIN"><CODE>cuddZddGetNode()</CODE></A> -<DD> Wrapper for cuddUniqueInterZdd. - -<DT> <A HREF="cuddAllDet.html#cuddZddGetPosVarIndex" TARGET="MAIN"><CODE>cuddZddGetPosVarIndex()</CODE></A> -<DD> Returns the index of positive ZDD variable. - -<DT> <A HREF="cuddAllDet.html#cuddZddGetPosVarLevel" TARGET="MAIN"><CODE>cuddZddGetPosVarLevel()</CODE></A> -<DD> Returns the level of positive ZDD variable. - -<DT> <A HREF="cuddAllDet.html#cuddZddInitUniv" TARGET="MAIN"><CODE>cuddZddInitUniv()</CODE></A> -<DD> Initializes the ZDD universe. - -<DT> <A HREF="cuddAllDet.html#cuddZddIntersect" TARGET="MAIN"><CODE>cuddZddIntersect()</CODE></A> -<DD> Performs the recursive step of Cudd_zddIntersect. - -<DT> <A HREF="cuddAllDet.html#cuddZddIsop" TARGET="MAIN"><CODE>cuddZddIsop()</CODE></A> -<DD> Performs the recursive step of Cudd_zddIsop. - -<DT> <A HREF="cuddAllDet.html#cuddZddIte" TARGET="MAIN"><CODE>cuddZddIte()</CODE></A> -<DD> Performs the recursive step of Cudd_zddIte. - -<DT> <A HREF="cuddAllDet.html#cuddZddLinearAux" TARGET="MAIN"><CODE>cuddZddLinearAux()</CODE></A> -<DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - -<DT> <A HREF="cuddAllDet.html#cuddZddLinearBackward" TARGET="MAIN"><CODE>cuddZddLinearBackward()</CODE></A> -<DD> Given a set of moves, returns the ZDD heap to the position - giving the minimum size. - -<DT> <A HREF="cuddAllDet.html#cuddZddLinearDown" TARGET="MAIN"><CODE>cuddZddLinearDown()</CODE></A> -<DD> Sifts a variable down and applies the XOR transformation. - -<DT> <A HREF="cuddAllDet.html#cuddZddLinearInPlace" TARGET="MAIN"><CODE>cuddZddLinearInPlace()</CODE></A> -<DD> Linearly combines two adjacent variables. - -<DT> <A HREF="cuddAllDet.html#cuddZddLinearSifting" TARGET="MAIN"><CODE>cuddZddLinearSifting()</CODE></A> -<DD> Implementation of the linear sifting algorithm for ZDDs. - -<DT> <A HREF="cuddAllDet.html#cuddZddLinearUp" TARGET="MAIN"><CODE>cuddZddLinearUp()</CODE></A> -<DD> Sifts a variable up applying the XOR transformation. - -<DT> <A HREF="cuddAllDet.html#cuddZddNextHigh" TARGET="MAIN"><CODE>cuddZddNextHigh()</CODE></A> -<DD> Finds the next subtable with a larger index. - -<DT> <A HREF="cuddAllDet.html#cuddZddNextLow" TARGET="MAIN"><CODE>cuddZddNextLow()</CODE></A> -<DD> Finds the next subtable with a smaller index. - -<DT> <A HREF="cuddAllDet.html#cuddZddProduct" TARGET="MAIN"><CODE>cuddZddProduct()</CODE></A> -<DD> Performs the recursive step of Cudd_zddProduct. - -<DT> <A HREF="cuddAllDet.html#cuddZddP" TARGET="MAIN"><CODE>cuddZddP()</CODE></A> -<DD> Prints a ZDD to the standard output. One line per node is - printed. - -<DT> <A HREF="cuddAllDet.html#cuddZddSiftingAux" TARGET="MAIN"><CODE>cuddZddSiftingAux()</CODE></A> -<DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - -<DT> <A HREF="cuddAllDet.html#cuddZddSiftingBackward" TARGET="MAIN"><CODE>cuddZddSiftingBackward()</CODE></A> -<DD> Given a set of moves, returns the ZDD heap to the position - giving the minimum size. - -<DT> <A HREF="cuddAllDet.html#cuddZddSiftingDown" TARGET="MAIN"><CODE>cuddZddSiftingDown()</CODE></A> -<DD> Sifts a variable down. - -<DT> <A HREF="cuddAllDet.html#cuddZddSiftingUp" TARGET="MAIN"><CODE>cuddZddSiftingUp()</CODE></A> -<DD> Sifts a variable up. - -<DT> <A HREF="cuddAllDet.html#cuddZddSifting" TARGET="MAIN"><CODE>cuddZddSifting()</CODE></A> -<DD> Implementation of Rudell's sifting algorithm. - -<DT> <A HREF="cuddAllDet.html#cuddZddSubset0" TARGET="MAIN"><CODE>cuddZddSubset0()</CODE></A> -<DD> Computes the negative cofactor of a ZDD w.r.t. a variable. - -<DT> <A HREF="cuddAllDet.html#cuddZddSubset1" TARGET="MAIN"><CODE>cuddZddSubset1()</CODE></A> -<DD> Computes the positive cofactor of a ZDD w.r.t. a variable. - -<DT> <A HREF="cuddAllDet.html#cuddZddSwapInPlace" TARGET="MAIN"><CODE>cuddZddSwapInPlace()</CODE></A> -<DD> Swaps two adjacent variables. - -<DT> <A HREF="cuddAllDet.html#cuddZddSwapping" TARGET="MAIN"><CODE>cuddZddSwapping()</CODE></A> -<DD> Reorders variables by a sequence of (non-adjacent) swaps. - -<DT> <A HREF="cuddAllDet.html#cuddZddSymmCheck" TARGET="MAIN"><CODE>cuddZddSymmCheck()</CODE></A> -<DD> Checks for symmetry of x and y. - -<DT> <A HREF="cuddAllDet.html#cuddZddSymmSiftingAux" TARGET="MAIN"><CODE>cuddZddSymmSiftingAux()</CODE></A> -<DD> Given x_low <= x <= x_high moves x up and down between the - boundaries. - -<DT> <A HREF="cuddAllDet.html#cuddZddSymmSiftingBackward" TARGET="MAIN"><CODE>cuddZddSymmSiftingBackward()</CODE></A> -<DD> Given a set of moves, returns the ZDD heap to the position - giving the minimum size. - -<DT> <A HREF="cuddAllDet.html#cuddZddSymmSiftingConvAux" TARGET="MAIN"><CODE>cuddZddSymmSiftingConvAux()</CODE></A> -<DD> Given x_low <= x <= x_high moves x up and down between the - boundaries. - -<DT> <A HREF="cuddAllDet.html#cuddZddSymmSiftingConv" TARGET="MAIN"><CODE>cuddZddSymmSiftingConv()</CODE></A> -<DD> Symmetric sifting to convergence algorithm for ZDDs. - -<DT> <A HREF="cuddAllDet.html#cuddZddSymmSifting_down" TARGET="MAIN"><CODE>cuddZddSymmSifting_down()</CODE></A> -<DD> Moves x down until either it reaches the bound (x_high) or - the size of the ZDD heap increases too much. - -<DT> <A HREF="cuddAllDet.html#cuddZddSymmSifting_up" TARGET="MAIN"><CODE>cuddZddSymmSifting_up()</CODE></A> -<DD> Moves x up until either it reaches the bound (x_low) or - the size of the ZDD heap increases too much. - -<DT> <A HREF="cuddAllDet.html#cuddZddSymmSifting" TARGET="MAIN"><CODE>cuddZddSymmSifting()</CODE></A> -<DD> Symmetric sifting algorithm for ZDDs. - -<DT> <A HREF="cuddAllDet.html#cuddZddSymmSummary" TARGET="MAIN"><CODE>cuddZddSymmSummary()</CODE></A> -<DD> Counts numbers of symmetric variables and symmetry - groups. - -<DT> <A HREF="cuddAllDet.html#cuddZddTreeSifting" TARGET="MAIN"><CODE>cuddZddTreeSifting()</CODE></A> -<DD> Tree sifting algorithm for ZDDs. - -<DT> <A HREF="cuddAllDet.html#cuddZddUnateProduct" TARGET="MAIN"><CODE>cuddZddUnateProduct()</CODE></A> -<DD> Performs the recursive step of Cudd_zddUnateProduct. - -<DT> <A HREF="cuddAllDet.html#cuddZddUndoMoves" TARGET="MAIN"><CODE>cuddZddUndoMoves()</CODE></A> -<DD> Given a set of moves, returns the ZDD heap to the order - in effect before the moves. - -<DT> <A HREF="cuddAllDet.html#cuddZddUnion" TARGET="MAIN"><CODE>cuddZddUnion()</CODE></A> -<DD> Performs the recursive step of Cudd_zddUnion. - -<DT> <A HREF="cuddAllDet.html#cuddZddUniqueCompare" TARGET="MAIN"><CODE>cuddZddUniqueCompare()</CODE></A> -<DD> Comparison function used by qsort. - -<DT> <A HREF="cuddAllDet.html#cuddZddWeakDivF" TARGET="MAIN"><CODE>cuddZddWeakDivF()</CODE></A> -<DD> Performs the recursive step of Cudd_zddWeakDivF. - -<DT> <A HREF="cuddAllDet.html#cuddZddWeakDiv" TARGET="MAIN"><CODE>cuddZddWeakDiv()</CODE></A> -<DD> Performs the recursive step of Cudd_zddWeakDiv. - -<DT> <A HREF="cuddAllDet.html#ddBddMaximallyExpand" TARGET="MAIN"><CODE>ddBddMaximallyExpand()</CODE></A> -<DD> Performs the recursive step of Cudd_bddMaximallyExpand. - -<DT> <A HREF="cuddAllDet.html#ddBddShortestPathUnate" TARGET="MAIN"><CODE>ddBddShortestPathUnate()</CODE></A> -<DD> Performs shortest path computation on a unate function. - -<DT> <A HREF="cuddAllDet.html#ddBddToAddRecur" TARGET="MAIN"><CODE>ddBddToAddRecur()</CODE></A> -<DD> Performs the recursive step for Cudd_BddToAdd. - -<DT> <A HREF="cuddAllDet.html#ddCheckPermuation" TARGET="MAIN"><CODE>ddCheckPermuation()</CODE></A> -<DD> Checks the BDD variable group tree before a shuffle. - -<DT> <A HREF="cuddAllDet.html#ddClearFlag" TARGET="MAIN"><CODE>ddClearFlag()</CODE></A> -<DD> Performs a DFS from f, clearing the LSB of the next - pointers. - -<DT> <A HREF="cuddAllDet.html#ddClearGlobal" TARGET="MAIN"><CODE>ddClearGlobal()</CODE></A> -<DD> Scans the DD and clears the LSB of the next pointers. - -<DT> <A HREF="cuddAllDet.html#ddClearGlobal" TARGET="MAIN"><CODE>ddClearGlobal()</CODE></A> -<DD> Scans the DD and clears the LSB of the next pointers. - -<DT> <A HREF="cuddAllDet.html#ddClearLocal" TARGET="MAIN"><CODE>ddClearLocal()</CODE></A> -<DD> Performs a DFS from f, clearing the LSB of the then pointers. - -<DT> <A HREF="cuddAllDet.html#ddClearVars" TARGET="MAIN"><CODE>ddClearVars()</CODE></A> -<DD> Clears visited flags for variables. - -<DT> <A HREF="cuddAllDet.html#ddCofMintermAux" TARGET="MAIN"><CODE>ddCofMintermAux()</CODE></A> -<DD> Recursive Step for Cudd_CofMinterm function. - -<DT> <A HREF="cuddAllDet.html#ddCountInternalMtrNodes" TARGET="MAIN"><CODE>ddCountInternalMtrNodes()</CODE></A> -<DD> Counts the number of internal nodes of the group tree. - -<DT> <A HREF="cuddAllDet.html#ddCountMintermAux" TARGET="MAIN"><CODE>ddCountMintermAux()</CODE></A> -<DD> Performs the recursive step of Cudd_CountMinterm. - -<DT> <A HREF="cuddAllDet.html#ddCountPathAux" TARGET="MAIN"><CODE>ddCountPathAux()</CODE></A> -<DD> Performs the recursive step of Cudd_CountPath. - -<DT> <A HREF="cuddAllDet.html#ddCountPathsToNonZero" TARGET="MAIN"><CODE>ddCountPathsToNonZero()</CODE></A> -<DD> Performs the recursive step of Cudd_CountPathsToNonZero. - -<DT> <A HREF="cuddAllDet.html#ddCountRoots" TARGET="MAIN"><CODE>ddCountRoots()</CODE></A> -<DD> Counts the number of roots. - -<DT> <A HREF="cuddAllDet.html#ddCreateGroup" TARGET="MAIN"><CODE>ddCreateGroup()</CODE></A> -<DD> Creates a group encompassing variables from x to y in the - DD table. - -<DT> <A HREF="cuddAllDet.html#ddDagInt" TARGET="MAIN"><CODE>ddDagInt()</CODE></A> -<DD> Performs the recursive step of Cudd_DagSize. - -<DT> <A HREF="cuddAllDet.html#ddDissolveGroup" TARGET="MAIN"><CODE>ddDissolveGroup()</CODE></A> -<DD> Dissolves a group in the DD table. - -<DT> <A HREF="cuddAllDet.html#ddDoDumpBlif" TARGET="MAIN"><CODE>ddDoDumpBlif()</CODE></A> -<DD> Performs the recursive step of Cudd_DumpBlif. - -<DT> <A HREF="cuddAllDet.html#ddDoDumpDDcal" TARGET="MAIN"><CODE>ddDoDumpDDcal()</CODE></A> -<DD> Performs the recursive step of Cudd_DumpDDcal. - -<DT> <A HREF="cuddAllDet.html#ddDoDumpDaVinci" TARGET="MAIN"><CODE>ddDoDumpDaVinci()</CODE></A> -<DD> Performs the recursive step of Cudd_DumpDaVinci. - -<DT> <A HREF="cuddAllDet.html#ddDoDumpFactoredForm" TARGET="MAIN"><CODE>ddDoDumpFactoredForm()</CODE></A> -<DD> Performs the recursive step of Cudd_DumpFactoredForm. - -<DT> <A HREF="cuddAllDet.html#ddEpdCountMintermAux" TARGET="MAIN"><CODE>ddEpdCountMintermAux()</CODE></A> -<DD> Performs the recursive step of Cudd_EpdCountMinterm. - -<DT> <A HREF="cuddAllDet.html#ddEpdFree" TARGET="MAIN"><CODE>ddEpdFree()</CODE></A> -<DD> Frees the memory used to store the minterm counts recorded - in the visited table. - -<DT> <A HREF="cuddAllDet.html#ddExchange" TARGET="MAIN"><CODE>ddExchange()</CODE></A> -<DD> This function is for exchanging two variables, x and y. - -<DT> <A HREF="cuddAllDet.html#ddExtSymmCheck" TARGET="MAIN"><CODE>ddExtSymmCheck()</CODE></A> -<DD> Checks for extended symmetry of x and y. - -<DT> <A HREF="cuddAllDet.html#ddFindEssentialRecur" TARGET="MAIN"><CODE>ddFindEssentialRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_FindEssential. - -<DT> <A HREF="cuddAllDet.html#ddFindNodeHiLo" TARGET="MAIN"><CODE>ddFindNodeHiLo()</CODE></A> -<DD> Finds the lower and upper bounds of the group represented - by treenode. - -<DT> <A HREF="cuddAllDet.html#ddFindSupport" TARGET="MAIN"><CODE>ddFindSupport()</CODE></A> -<DD> Recursively find the support of f. - -<DT> <A HREF="cuddAllDet.html#ddFindTwoLiteralClausesRecur" TARGET="MAIN"><CODE>ddFindTwoLiteralClausesRecur()</CODE></A> -<DD> Implements the recursive step of Cudd_FindTwoLiteralClauses. - -<DT> <A HREF="cuddAllDet.html#ddGetLargestCubeUnate" TARGET="MAIN"><CODE>ddGetLargestCubeUnate()</CODE></A> -<DD> Extracts largest prime of a unate function. - -<DT> <A HREF="cuddAllDet.html#ddGroupMoveBackward" TARGET="MAIN"><CODE>ddGroupMoveBackward()</CODE></A> -<DD> Undoes the swap two groups. - -<DT> <A HREF="cuddAllDet.html#ddGroupMove" TARGET="MAIN"><CODE>ddGroupMove()</CODE></A> -<DD> Swaps two groups and records the move. - -<DT> <A HREF="cuddAllDet.html#ddGroupSiftingAux" TARGET="MAIN"><CODE>ddGroupSiftingAux()</CODE></A> -<DD> Sifts one variable up and down until it has taken all - positions. Checks for aggregation. - -<DT> <A HREF="cuddAllDet.html#ddGroupSiftingBackward" TARGET="MAIN"><CODE>ddGroupSiftingBackward()</CODE></A> -<DD> Determines the best position for a variables and returns - it there. - -<DT> <A HREF="cuddAllDet.html#ddGroupSiftingDown" TARGET="MAIN"><CODE>ddGroupSiftingDown()</CODE></A> -<DD> Sifts down a variable until it reaches position xHigh. - -<DT> <A HREF="cuddAllDet.html#ddGroupSiftingUp" TARGET="MAIN"><CODE>ddGroupSiftingUp()</CODE></A> -<DD> Sifts up a variable until either it reaches position xLow - or the size of the DD heap increases too much. - -<DT> <A HREF="cuddAllDet.html#ddGroupSifting" TARGET="MAIN"><CODE>ddGroupSifting()</CODE></A> -<DD> Sifts from treenode->low to treenode->high. - -<DT> <A HREF="cuddAllDet.html#ddIsVarHandled" TARGET="MAIN"><CODE>ddIsVarHandled()</CODE></A> -<DD> Checks whether a variables is already handled. - -<DT> <A HREF="cuddAllDet.html#ddJumpingAux" TARGET="MAIN"><CODE>ddJumpingAux()</CODE></A> -<DD> Moves a variable to a specified position. - -<DT> <A HREF="cuddAllDet.html#ddJumpingDown" TARGET="MAIN"><CODE>ddJumpingDown()</CODE></A> -<DD> This function is for jumping down. - -<DT> <A HREF="cuddAllDet.html#ddJumpingUp" TARGET="MAIN"><CODE>ddJumpingUp()</CODE></A> -<DD> This function is for jumping up. - -<DT> <A HREF="cuddAllDet.html#ddLeavesInt" TARGET="MAIN"><CODE>ddLeavesInt()</CODE></A> -<DD> Performs the recursive step of Cudd_CountLeaves. - -<DT> <A HREF="cuddAllDet.html#ddLinearAndSiftingAux" TARGET="MAIN"><CODE>ddLinearAndSiftingAux()</CODE></A> -<DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - -<DT> <A HREF="cuddAllDet.html#ddLinearAndSiftingBackward" TARGET="MAIN"><CODE>ddLinearAndSiftingBackward()</CODE></A> -<DD> Given a set of moves, returns the DD heap to the order - giving the minimum size. - -<DT> <A HREF="cuddAllDet.html#ddLinearAndSiftingDown" TARGET="MAIN"><CODE>ddLinearAndSiftingDown()</CODE></A> -<DD> Sifts a variable down and applies linear transformations. - -<DT> <A HREF="cuddAllDet.html#ddLinearAndSiftingUp" TARGET="MAIN"><CODE>ddLinearAndSiftingUp()</CODE></A> -<DD> Sifts a variable up and applies linear transformations. - -<DT> <A HREF="cuddAllDet.html#ddLinearUniqueCompare" TARGET="MAIN"><CODE>ddLinearUniqueCompare()</CODE></A> -<DD> Comparison function used by qsort. - -<DT> <A HREF="cuddAllDet.html#ddMergeGroups" TARGET="MAIN"><CODE>ddMergeGroups()</CODE></A> -<DD> Merges groups in the DD table. - -<DT> <A HREF="cuddAllDet.html#ddNoCheck" TARGET="MAIN"><CODE>ddNoCheck()</CODE></A> -<DD> Pretends to check two variables for aggregation. - -<DT> <A HREF="cuddAllDet.html#ddPatchTree" TARGET="MAIN"><CODE>ddPatchTree()</CODE></A> -<DD> Fixes a variable tree after the insertion of new subtables. - -<DT> <A HREF="cuddAllDet.html#ddPermuteWindow3" TARGET="MAIN"><CODE>ddPermuteWindow3()</CODE></A> -<DD> Tries all the permutations of the three variables between - x and x+2 and retains the best. - -<DT> <A HREF="cuddAllDet.html#ddPermuteWindow4" TARGET="MAIN"><CODE>ddPermuteWindow4()</CODE></A> -<DD> Tries all the permutations of the four variables between w - and w+3 and retains the best. - -<DT> <A HREF="cuddAllDet.html#ddPickArbitraryMinterms" TARGET="MAIN"><CODE>ddPickArbitraryMinterms()</CODE></A> -<DD> Performs the recursive step of Cudd_bddPickArbitraryMinterms. - -<DT> <A HREF="cuddAllDet.html#ddPickRepresentativeCube" TARGET="MAIN"><CODE>ddPickRepresentativeCube()</CODE></A> -<DD> Finds a representative cube of a BDD. - -<DT> <A HREF="cuddAllDet.html#ddPrintMintermAux" TARGET="MAIN"><CODE>ddPrintMintermAux()</CODE></A> -<DD> Performs the recursive step of Cudd_PrintMinterm. - -<DT> <A HREF="cuddAllDet.html#ddRehashZdd" TARGET="MAIN"><CODE>ddRehashZdd()</CODE></A> -<DD> Rehashes a ZDD unique subtable. - -<DT> <A HREF="cuddAllDet.html#ddReorderChildren" TARGET="MAIN"><CODE>ddReorderChildren()</CODE></A> -<DD> Reorders the children of a group tree node according to - the options. - -<DT> <A HREF="cuddAllDet.html#ddReorderPostprocess" TARGET="MAIN"><CODE>ddReorderPostprocess()</CODE></A> -<DD> Cleans up at the end of reordering. - -<DT> <A HREF="cuddAllDet.html#ddReorderPreprocess" TARGET="MAIN"><CODE>ddReorderPreprocess()</CODE></A> -<DD> Prepares the DD heap for dynamic reordering. - -<DT> <A HREF="cuddAllDet.html#ddReportRefMess" TARGET="MAIN"><CODE>ddReportRefMess()</CODE></A> -<DD> Reports problem in garbage collection. - -<DT> <A HREF="cuddAllDet.html#ddResetVarHandled" TARGET="MAIN"><CODE>ddResetVarHandled()</CODE></A> -<DD> Resets a variable to be processed. - -<DT> <A HREF="cuddAllDet.html#ddResizeTable" TARGET="MAIN"><CODE>ddResizeTable()</CODE></A> -<DD> Increases the number of subtables in a unique table so - that it meets or exceeds index. - -<DT> <A HREF="cuddAllDet.html#ddSecDiffCheck" TARGET="MAIN"><CODE>ddSecDiffCheck()</CODE></A> -<DD> Checks two variables for aggregation. - -<DT> <A HREF="cuddAllDet.html#ddSetVarHandled" TARGET="MAIN"><CODE>ddSetVarHandled()</CODE></A> -<DD> Sets a variable to already handled. - -<DT> <A HREF="cuddAllDet.html#ddShuffle" TARGET="MAIN"><CODE>ddShuffle()</CODE></A> -<DD> Reorders variables according to a given permutation. - -<DT> <A HREF="cuddAllDet.html#ddShuffle" TARGET="MAIN"><CODE>ddShuffle()</CODE></A> -<DD> Reorders variables according to a given permutation. - -<DT> <A HREF="cuddAllDet.html#ddSiftUp" TARGET="MAIN"><CODE>ddSiftUp()</CODE></A> -<DD> Moves one variable up. - -<DT> <A HREF="cuddAllDet.html#ddSiftUp" TARGET="MAIN"><CODE>ddSiftUp()</CODE></A> -<DD> Moves one variable up. - -<DT> <A HREF="cuddAllDet.html#ddSiftingAux" TARGET="MAIN"><CODE>ddSiftingAux()</CODE></A> -<DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - -<DT> <A HREF="cuddAllDet.html#ddSiftingBackward" TARGET="MAIN"><CODE>ddSiftingBackward()</CODE></A> -<DD> Given a set of moves, returns the DD heap to the position - giving the minimum size. - -<DT> <A HREF="cuddAllDet.html#ddSiftingDown" TARGET="MAIN"><CODE>ddSiftingDown()</CODE></A> -<DD> Sifts a variable down. - -<DT> <A HREF="cuddAllDet.html#ddSiftingUp" TARGET="MAIN"><CODE>ddSiftingUp()</CODE></A> -<DD> Sifts a variable up. - -<DT> <A HREF="cuddAllDet.html#ddSuppInteract" TARGET="MAIN"><CODE>ddSuppInteract()</CODE></A> -<DD> Find the support of f. - -<DT> <A HREF="cuddAllDet.html#ddSupportStep" TARGET="MAIN"><CODE>ddSupportStep()</CODE></A> -<DD> Performs the recursive step of Cudd_Support. - -<DT> <A HREF="cuddAllDet.html#ddSwapAny" TARGET="MAIN"><CODE>ddSwapAny()</CODE></A> -<DD> Swaps any two variables. - -<DT> <A HREF="cuddAllDet.html#ddSymmGroupMoveBackward" TARGET="MAIN"><CODE>ddSymmGroupMoveBackward()</CODE></A> -<DD> Undoes the swap of two groups. - -<DT> <A HREF="cuddAllDet.html#ddSymmGroupMove" TARGET="MAIN"><CODE>ddSymmGroupMove()</CODE></A> -<DD> Swaps two groups. - -<DT> <A HREF="cuddAllDet.html#ddSymmSiftingAux" TARGET="MAIN"><CODE>ddSymmSiftingAux()</CODE></A> -<DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - -<DT> <A HREF="cuddAllDet.html#ddSymmSiftingBackward" TARGET="MAIN"><CODE>ddSymmSiftingBackward()</CODE></A> -<DD> Given a set of moves, returns the DD heap to the position - giving the minimum size. - -<DT> <A HREF="cuddAllDet.html#ddSymmSiftingConvAux" TARGET="MAIN"><CODE>ddSymmSiftingConvAux()</CODE></A> -<DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - -<DT> <A HREF="cuddAllDet.html#ddSymmSiftingDown" TARGET="MAIN"><CODE>ddSymmSiftingDown()</CODE></A> -<DD> Moves x down until either it reaches the bound (xHigh) or - the size of the DD heap increases too much. - -<DT> <A HREF="cuddAllDet.html#ddSymmSiftingUp" TARGET="MAIN"><CODE>ddSymmSiftingUp()</CODE></A> -<DD> Moves x up until either it reaches the bound (xLow) or - the size of the DD heap increases too much. - -<DT> <A HREF="cuddAllDet.html#ddSymmSummary" TARGET="MAIN"><CODE>ddSymmSummary()</CODE></A> -<DD> Counts numbers of symmetric variables and symmetry - groups. - -<DT> <A HREF="cuddAllDet.html#ddSymmUniqueCompare" TARGET="MAIN"><CODE>ddSymmUniqueCompare()</CODE></A> -<DD> Comparison function used by qsort. - -<DT> <A HREF="cuddAllDet.html#ddTreeSiftingAux" TARGET="MAIN"><CODE>ddTreeSiftingAux()</CODE></A> -<DD> Visits the group tree and reorders each group. - -<DT> <A HREF="cuddAllDet.html#ddUndoMoves" TARGET="MAIN"><CODE>ddUndoMoves()</CODE></A> -<DD> Given a set of moves, returns the DD heap to the order - in effect before the moves. - -<DT> <A HREF="cuddAllDet.html#ddUniqueCompareGroup" TARGET="MAIN"><CODE>ddUniqueCompareGroup()</CODE></A> -<DD> Comparison function used by qsort. - -<DT> <A HREF="cuddAllDet.html#ddUniqueCompare" TARGET="MAIN"><CODE>ddUniqueCompare()</CODE></A> -<DD> Comparison function used by qsort. - -<DT> <A HREF="cuddAllDet.html#ddUpdateInteract" TARGET="MAIN"><CODE>ddUpdateInteract()</CODE></A> -<DD> Marks as interacting all pairs of variables that appear in - support. - -<DT> <A HREF="cuddAllDet.html#ddUpdateMtrTree" TARGET="MAIN"><CODE>ddUpdateMtrTree()</CODE></A> -<DD> Updates the BDD variable group tree before a shuffle. - -<DT> <A HREF="cuddAllDet.html#ddVarGroupCheck" TARGET="MAIN"><CODE>ddVarGroupCheck()</CODE></A> -<DD> Checks for grouping of x and y. - -<DT> <A HREF="cuddAllDet.html#ddWindow2" TARGET="MAIN"><CODE>ddWindow2()</CODE></A> -<DD> Reorders by applying a sliding window of width 2. - -<DT> <A HREF="cuddAllDet.html#ddWindow3" TARGET="MAIN"><CODE>ddWindow3()</CODE></A> -<DD> Reorders by applying a sliding window of width 3. - -<DT> <A HREF="cuddAllDet.html#ddWindow4" TARGET="MAIN"><CODE>ddWindow4()</CODE></A> -<DD> Reorders by applying a sliding window of width 4. - -<DT> <A HREF="cuddAllDet.html#ddWindowConv2" TARGET="MAIN"><CODE>ddWindowConv2()</CODE></A> -<DD> Reorders by repeatedly applying a sliding window of width 2. - -<DT> <A HREF="cuddAllDet.html#ddWindowConv3" TARGET="MAIN"><CODE>ddWindowConv3()</CODE></A> -<DD> Reorders by repeatedly applying a sliding window of width 3. - -<DT> <A HREF="cuddAllDet.html#ddWindowConv4" TARGET="MAIN"><CODE>ddWindowConv4()</CODE></A> -<DD> Reorders by repeatedly applying a sliding window of width 4. - -<DT> <A HREF="cuddAllDet.html#debugCheckParent" TARGET="MAIN"><CODE>debugCheckParent()</CODE></A> -<DD> Reports an error if a (dead) node has a non-dead parent. - -<DT> <A HREF="cuddAllDet.html#debugFindParent" TARGET="MAIN"><CODE>debugFindParent()</CODE></A> -<DD> Searches the subtables above node for its parents. - -<DT> <A HREF="cuddAllDet.html#dp2" TARGET="MAIN"><CODE>dp2()</CODE></A> -<DD> Performs the recursive step of cuddP. - -<DT> <A HREF="cuddAllDet.html#emptyClauseSet" TARGET="MAIN"><CODE>emptyClauseSet()</CODE></A> -<DD> Returns an enpty set of clauses. - -<DT> <A HREF="cuddAllDet.html#equalp" TARGET="MAIN"><CODE>equalp()</CODE></A> -<DD> Returns true iff the two arguments are identical clauses. - -<DT> <A HREF="cuddAllDet.html#find_best" TARGET="MAIN"><CODE>find_best()</CODE></A> -<DD> Returns the index of the fittest individual. - -<DT> <A HREF="cuddAllDet.html#fixVarTree" TARGET="MAIN"><CODE>fixVarTree()</CODE></A> -<DD> Fixes a variable group tree. - -<DT> <A HREF="cuddAllDet.html#freeMatrix" TARGET="MAIN"><CODE>freeMatrix()</CODE></A> -<DD> Frees a two-dimensional matrix allocated by getMatrix. - -<DT> <A HREF="cuddAllDet.html#freePathPair" TARGET="MAIN"><CODE>freePathPair()</CODE></A> -<DD> Frees the entries of the visited symbol table. - -<DT> <A HREF="cuddAllDet.html#gatherInfoAux" TARGET="MAIN"><CODE>gatherInfoAux()</CODE></A> -<DD> Recursively counts minterms and computes reference counts - of each node in the BDD. - -<DT> <A HREF="cuddAllDet.html#gatherInfo" TARGET="MAIN"><CODE>gatherInfo()</CODE></A> -<DD> Gathers information about each node. - -<DT> <A HREF="cuddAllDet.html#gcd" TARGET="MAIN"><CODE>gcd()</CODE></A> -<DD> Returns the gcd of two integers. - -<DT> <A HREF="cuddAllDet.html#getCube" TARGET="MAIN"><CODE>getCube()</CODE></A> -<DD> Build a BDD for a largest cube of f. - -<DT> <A HREF="cuddAllDet.html#getLargest" TARGET="MAIN"><CODE>getLargest()</CODE></A> -<DD> Finds the size of the largest cube(s) in a DD. - -<DT> <A HREF="cuddAllDet.html#getLevelKeys" TARGET="MAIN"><CODE>getLevelKeys()</CODE></A> -<DD> Returns the number of nodes at one level of a unique table. - -<DT> <A HREF="cuddAllDet.html#getMatrix" TARGET="MAIN"><CODE>getMatrix()</CODE></A> -<DD> Allocates a two-dimensional matrix of ints. - -<DT> <A HREF="cuddAllDet.html#getMaxBinomial" TARGET="MAIN"><CODE>getMaxBinomial()</CODE></A> -<DD> Returns the maximum value of (n choose k) for a given n. - -<DT> <A HREF="cuddAllDet.html#getPath" TARGET="MAIN"><CODE>getPath()</CODE></A> -<DD> Build a BDD for a shortest path of f. - -<DT> <A HREF="cuddAllDet.html#getShortest" TARGET="MAIN"><CODE>getShortest()</CODE></A> -<DD> Finds the length of the shortest path(s) in a DD. - -<DT> <A HREF="cuddAllDet.html#hashDelete" TARGET="MAIN"><CODE>hashDelete()</CODE></A> -<DD> Removes an item from the hash table of a level queue. - -<DT> <A HREF="cuddAllDet.html#hashInsert" TARGET="MAIN"><CODE>hashInsert()</CODE></A> -<DD> Inserts an item in the hash table of a level queue. - -<DT> <A HREF="cuddAllDet.html#hashLookup" TARGET="MAIN"><CODE>hashLookup()</CODE></A> -<DD> Looks up a key in the hash table of a level queue. - -<DT> <A HREF="cuddAllDet.html#hashResize" TARGET="MAIN"><CODE>hashResize()</CODE></A> -<DD> Resizes the hash table of a level queue. - -<DT> <A HREF="cuddAllDet.html#impliedp" TARGET="MAIN"><CODE>impliedp()</CODE></A> -<DD> Returns true iff either literal of a clause is in a set of - literals. - -<DT> <A HREF="cuddAllDet.html#indexCompare" TARGET="MAIN"><CODE>indexCompare()</CODE></A> -<DD> Compares indices for qsort. - -<DT> <A HREF="cuddAllDet.html#initSymmInfo" TARGET="MAIN"><CODE>initSymmInfo()</CODE></A> -<DD> Gathers symmetry information. - -<DT> <A HREF="cuddAllDet.html#largest" TARGET="MAIN"><CODE>largest()</CODE></A> -<DD> Finds the largest DD in the population. - -<DT> <A HREF="cuddAllDet.html#make_random" TARGET="MAIN"><CODE>make_random()</CODE></A> -<DD> Generates the random sequences for the initial population. - -<DT> <A HREF="cuddAllDet.html#mintermsFromUniverse" TARGET="MAIN"><CODE>mintermsFromUniverse()</CODE></A> -<DD> Recursive procedure to extract n mintems from constant 1. - -<DT> <A HREF="cuddAllDet.html#oneliteralp" TARGET="MAIN"><CODE>oneliteralp()</CODE></A> -<DD> Returns true iff the argument is a one-literal clause. - -<DT> <A HREF="cuddAllDet.html#pushDown" TARGET="MAIN"><CODE>pushDown()</CODE></A> -<DD> Pushes a variable in the order down to position "level." - -<DT> <A HREF="cuddAllDet.html#rand_int" TARGET="MAIN"><CODE>rand_int()</CODE></A> -<DD> Generates a random number between 0 and the integer a. - -<DT> <A HREF="cuddAllDet.html#random_generator" TARGET="MAIN"><CODE>random_generator()</CODE></A> -<DD> Random number generator. - -<DT> <A HREF="cuddAllDet.html#restoreOrder" TARGET="MAIN"><CODE>restoreOrder()</CODE></A> -<DD> Restores the variable order in array by a series of sifts up. - -<DT> <A HREF="cuddAllDet.html#roulette" TARGET="MAIN"><CODE>roulette()</CODE></A> -<DD> Selects two parents with the roulette wheel method. - -<DT> <A HREF="cuddAllDet.html#selectMintermsFromUniverse" TARGET="MAIN"><CODE>selectMintermsFromUniverse()</CODE></A> -<DD> This function prepares an array of variables which have not been - encountered so far when traversing the procedure cuddSplitSetRecur. - -<DT> <A HREF="cuddAllDet.html#sentinelp" TARGET="MAIN"><CODE>sentinelp()</CODE></A> -<DD> Returns true iff the argument is the sentinel clause. - -<DT> <A HREF="cuddAllDet.html#separateCube" TARGET="MAIN"><CODE>separateCube()</CODE></A> -<DD> Separates cube from distance. - -<DT> <A HREF="cuddAllDet.html#siftBackwardProb" TARGET="MAIN"><CODE>siftBackwardProb()</CODE></A> -<DD> Returns the DD to the best position encountered during - sifting if there was improvement. - -<DT> <A HREF="cuddAllDet.html#sift_up" TARGET="MAIN"><CODE>sift_up()</CODE></A> -<DD> Moves one variable up. - -<DT> <A HREF="cuddAllDet.html#stPathTableDdFree" TARGET="MAIN"><CODE>stPathTableDdFree()</CODE></A> -<DD> Procedure to free te result dds stored in the NodeDist pages. - -<DT> <A HREF="cuddAllDet.html#st_zdd_count_dbl_free" TARGET="MAIN"><CODE>st_zdd_count_dbl_free()</CODE></A> -<DD> Frees the memory associated with the computed table of - Cudd_zddCountDouble. - -<DT> <A HREF="cuddAllDet.html#st_zdd_countfree" TARGET="MAIN"><CODE>st_zdd_countfree()</CODE></A> -<DD> Frees the memory associated with the computed table of - Cudd_zddCount. - -<DT> <A HREF="cuddAllDet.html#stopping_criterion" TARGET="MAIN"><CODE>stopping_criterion()</CODE></A> -<DD> Checks termination condition. - -<DT> <A HREF="cuddAllDet.html#tlcInfoAlloc" TARGET="MAIN"><CODE>tlcInfoAlloc()</CODE></A> -<DD> Allocates a DdTlcInfo Structure. - -<DT> <A HREF="cuddAllDet.html#updateEntry" TARGET="MAIN"><CODE>updateEntry()</CODE></A> -<DD> Updates entry for a subset. - -<DT> <A HREF="cuddAllDet.html#updateParity" TARGET="MAIN"><CODE>updateParity()</CODE></A> -<DD> Recursively update the parity of the paths reaching a node. - -<DT> <A HREF="cuddAllDet.html#updateRefs" TARGET="MAIN"><CODE>updateRefs()</CODE></A> -<DD> Update function reference counts. - -<DT> <A HREF="cuddAllDet.html#updateUB" TARGET="MAIN"><CODE>updateUB()</CODE></A> -<DD> Updates the upper bound and saves the best order seen so far. - -<DT> <A HREF="cuddAllDet.html#zddClearFlag" TARGET="MAIN"><CODE>zddClearFlag()</CODE></A> -<DD> Performs a DFS from f, clearing the LSB of the next - pointers. - -<DT> <A HREF="cuddAllDet.html#zddCountInternalMtrNodes" TARGET="MAIN"><CODE>zddCountInternalMtrNodes()</CODE></A> -<DD> Counts the number of internal nodes of the group tree. - -<DT> <A HREF="cuddAllDet.html#zddFindNodeHiLo" TARGET="MAIN"><CODE>zddFindNodeHiLo()</CODE></A> -<DD> Finds the lower and upper bounds of the group represented - by treenode. - -<DT> <A HREF="cuddAllDet.html#zddFixTree" TARGET="MAIN"><CODE>zddFixTree()</CODE></A> -<DD> Fixes the ZDD variable group tree after a shuffle. - -<DT> <A HREF="cuddAllDet.html#zddGroupMoveBackward" TARGET="MAIN"><CODE>zddGroupMoveBackward()</CODE></A> -<DD> Undoes the swap two groups. - -<DT> <A HREF="cuddAllDet.html#zddGroupMove" TARGET="MAIN"><CODE>zddGroupMove()</CODE></A> -<DD> Swaps two groups and records the move. - -<DT> <A HREF="cuddAllDet.html#zddGroupSiftingAux" TARGET="MAIN"><CODE>zddGroupSiftingAux()</CODE></A> -<DD> Sifts one variable up and down until it has taken all - positions. Checks for aggregation. - -<DT> <A HREF="cuddAllDet.html#zddGroupSiftingBackward" TARGET="MAIN"><CODE>zddGroupSiftingBackward()</CODE></A> -<DD> Determines the best position for a variables and returns - it there. - -<DT> <A HREF="cuddAllDet.html#zddGroupSiftingDown" TARGET="MAIN"><CODE>zddGroupSiftingDown()</CODE></A> -<DD> Sifts down a variable until it reaches position xHigh. - -<DT> <A HREF="cuddAllDet.html#zddGroupSiftingUp" TARGET="MAIN"><CODE>zddGroupSiftingUp()</CODE></A> -<DD> Sifts up a variable until either it reaches position xLow - or the size of the DD heap increases too much. - -<DT> <A HREF="cuddAllDet.html#zddGroupSifting" TARGET="MAIN"><CODE>zddGroupSifting()</CODE></A> -<DD> Sifts from treenode->low to treenode->high. - -<DT> <A HREF="cuddAllDet.html#zddMergeGroups" TARGET="MAIN"><CODE>zddMergeGroups()</CODE></A> -<DD> Merges groups in the DD table. - -<DT> <A HREF="cuddAllDet.html#zddPortFromBddStep" TARGET="MAIN"><CODE>zddPortFromBddStep()</CODE></A> -<DD> Performs the recursive step of Cudd_zddPortFromBdd. - -<DT> <A HREF="cuddAllDet.html#zddPortToBddStep" TARGET="MAIN"><CODE>zddPortToBddStep()</CODE></A> -<DD> Performs the recursive step of Cudd_zddPortToBdd. - -<DT> <A HREF="cuddAllDet.html#zddPrintCoverAux" TARGET="MAIN"><CODE>zddPrintCoverAux()</CODE></A> -<DD> Performs the recursive step of Cudd_zddPrintCover. - -<DT> <A HREF="cuddAllDet.html#zddReorderChildren" TARGET="MAIN"><CODE>zddReorderChildren()</CODE></A> -<DD> Reorders the children of a group tree node according to - the options. - -<DT> <A HREF="cuddAllDet.html#zddReorderPostprocess" TARGET="MAIN"><CODE>zddReorderPostprocess()</CODE></A> -<DD> Shrinks almost empty ZDD subtables at the end of reordering - to guarantee that they have a reasonable load factor. - -<DT> <A HREF="cuddAllDet.html#zddReorderPreprocess" TARGET="MAIN"><CODE>zddReorderPreprocess()</CODE></A> -<DD> Prepares the ZDD heap for dynamic reordering. - -<DT> <A HREF="cuddAllDet.html#zddShuffle" TARGET="MAIN"><CODE>zddShuffle()</CODE></A> -<DD> Reorders ZDD variables according to a given permutation. - -<DT> <A HREF="cuddAllDet.html#zddSiftUp" TARGET="MAIN"><CODE>zddSiftUp()</CODE></A> -<DD> Moves one ZDD variable up. - -<DT> <A HREF="cuddAllDet.html#zddSupportStep" TARGET="MAIN"><CODE>zddSupportStep()</CODE></A> -<DD> Performs the recursive step of Cudd_zddSupport. - -<DT> <A HREF="cuddAllDet.html#zddSwapAny" TARGET="MAIN"><CODE>zddSwapAny()</CODE></A> -<DD> Swaps any two variables. - -<DT> <A HREF="cuddAllDet.html#zddTreeSiftingAux" TARGET="MAIN"><CODE>zddTreeSiftingAux()</CODE></A> -<DD> Visits the group tree and reorders each group. - -<DT> <A HREF="cuddAllDet.html#zddUniqueCompareGroup" TARGET="MAIN"><CODE>zddUniqueCompareGroup()</CODE></A> -<DD> Comparison function used by qsort. - -<DT> <A HREF="cuddAllDet.html#zddVarToConst" TARGET="MAIN"><CODE>zddVarToConst()</CODE></A> -<DD> Replaces variables with constants if possible (part of - canonical form). - -<DT> <A HREF="cuddAllDet.html#zdd_group_move_backward" TARGET="MAIN"><CODE>zdd_group_move_backward()</CODE></A> -<DD> Undoes the swap of two groups. - -<DT> <A HREF="cuddAllDet.html#zdd_group_move" TARGET="MAIN"><CODE>zdd_group_move()</CODE></A> -<DD> Swaps two groups. - -<DT> <A HREF="cuddAllDet.html#zdd_print_minterm_aux" TARGET="MAIN"><CODE>zdd_print_minterm_aux()</CODE></A> -<DD> Performs the recursive step of Cudd_zddPrintMinterm. - -<DT> <A HREF="cuddAllDet.html#zdd_subset0_aux" TARGET="MAIN"><CODE>zdd_subset0_aux()</CODE></A> -<DD> Performs the recursive step of Cudd_zddSubset0. - -<DT> <A HREF="cuddAllDet.html#zdd_subset1_aux" TARGET="MAIN"><CODE>zdd_subset1_aux()</CODE></A> -<DD> Performs the recursive step of Cudd_zddSubset1. - -<DT> <A HREF="cuddAllDet.html#zp2" TARGET="MAIN"><CODE>zp2()</CODE></A> -<DD> Performs the recursive step of cuddZddP. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Adds node to the head of the free list. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Adds node to the head of the free list. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Adjusts the values of table limits. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Clears a bit vector. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Clears the 4 least significant bits of a pointer. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Comparison of a function to the i-th ADD variable. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Comparison of a pair of functions to the i-th ADD variable. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Complements a DD if a condition is true. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Complements a DD. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Computes hash function for keys of one operand. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Computes hash function for keys of three operands. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Computes hash function for keys of two operands. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Computes the absolute value of a number. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Computes the hash value for a local cache. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Computes the maximum of two numbers. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Computes the minimum of two numbers. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Decreases the reference count of a node, if it is not - saturated. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Enforces DD_MINUS_INF_VAL <= x <= DD_PLUS_INF_VAL. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Extract the least significant digit of a double digit. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Extract the most significant digit of a double digit. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Fast storage allocation for items in a hash table. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Finds the current position of ZDD variable index in the - order. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Finds the current position of variable index in the - order. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Hash function for the cache for functions with two - operands. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Hash function for the cache. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Hash function for the table of a level queue. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Hash function for the unique table. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Increases the reference count of a node, if it is not - saturated. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Iterates over the cubes of a decision diagram. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Iterates over the nodes of a decision diagram. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Iterates over the paths of a ZDD. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Iterates over the primes of a Boolean function. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Outputs a line of stats. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Performs the left rotation for red/black trees. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Performs the right rotation for red/black trees. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns 1 if a pointer is complemented. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns 1 if the absolute value of the difference of the two - arguments x and y is less than e. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns 1 if the node is a constant node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns 1 if the node is a constant node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the arithmetic 0 constant node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the average fitness of the population. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the complemented version of a pointer. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the constant 1 node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the current position in the order of variable - index. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the else child of an internal node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the else child of an internal node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the i-th entry of a bit vector. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the minus infinity constant node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the plus infinity constant node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the regular version of a pointer. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the then child of an internal node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the then child of an internal node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the value of a constant node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Returns the value of a constant node. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Saturating decrement operator. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Saturating increment operator. - -<DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> -<DD> Sets the i-th entry of a bit vector to a value. - -</DL> - -<HR> - -Last updated on 20120204 17h33 -</BODY></HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllByFile.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllByFile.html deleted file mode 100644 index 4076ddeae..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllByFile.html +++ /dev/null @@ -1,13 +0,0 @@ -<HTML> -<HEAD><TITLE>The cudd package for maintainers</TITLE></HEAD> - -<FRAMESET ROWS="5%,90%,5%"> - <FRAME SRC="cuddTitle.html"> - <FRAMESET COLS="40%,60%"> - <FRAME SRC="cuddAllFile.html" NAME="ABSTRACT"> - <FRAME SRC="cuddAllDet.html" NAME="MAIN"> - </FRAMESET> - <FRAME SRC="credit.html"> -</FRAMESET> - -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllByFunc.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllByFunc.html deleted file mode 100644 index 76ec3ae05..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllByFunc.html +++ /dev/null @@ -1,13 +0,0 @@ -<HTML> -<HEAD><TITLE>The cudd package for maintainers</TITLE></HEAD> - -<FRAMESET ROWS="5%,90%,5%"> - <FRAME SRC="cuddTitle.html"> - <FRAMESET COLS="40%,60%"> - <FRAME SRC="cuddAllAbs.html" NAME="ABSTRACT"> - <FRAME SRC="cuddAllDet.html" NAME="MAIN"> - </FRAMESET> - <FRAME SRC="credit.html"> -</FRAMESET> - -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllDet.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllDet.html deleted file mode 100644 index b700560e8..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllDet.html +++ /dev/null @@ -1,15754 +0,0 @@ -<html> -<head><title>The cudd package: all functions </title></head> -<body> - - -<HR> -<DL> -<dt><pre> -<A NAME="AssessPathLength"></A> -static unsigned int <I></I> -<B>AssessPathLength</B>( - unsigned int * <b>pathLengthArray</b>, <i>array determining number of nodes belonging to the different path lengths</i> - int <b>threshold</b>, <i>threshold to determine maximum allowable nodes in the subset</i> - int <b>numVars</b>, <i>maximum number of variables</i> - unsigned int * <b>excess</b>, <i>number of nodes labeled maxpath required in the subset</i> - FILE * <b>fp</b> <i>where to write messages</i> -) -</pre> -<dd> Chooses the maximum allowable path length under each node. - The corner cases are when the threshold is larger than the number - of nodes in the BDD iself, in which case 'numVars + 1' is returned. - If all nodes of a particular path length are needed, then the - maxpath returned is the next one with excess nodes = 0; -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetSP.c"TARGET="ABSTRACT"><CODE>cuddSubsetSP.c</CODE></A> - -<dt><pre> -<A NAME="BAapplyBias"></A> -static int <I></I> -<B>BAapplyBias</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>b</b>, <i></i> - ApproxInfo * <b>info</b>, <i></i> - DdHashTable * <b>cache</b> <i></i> -) -</pre> -<dd> Finds don't care nodes by traversing f and b in parallel. - Returns the care status of the visited f node if successful; CARE_ERROR - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddBiasedUnderApprox">cuddBiasedUnderApprox</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="BAmarkNodes"></A> -static int <I></I> -<B>BAmarkNodes</B>( - DdManager * <b>dd</b>, <i>manager</i> - DdNode * <b>f</b>, <i>function to be analyzed</i> - ApproxInfo * <b>info</b>, <i>info on BDD</i> - int <b>threshold</b>, <i>when to stop approximating</i> - double <b>quality1</b>, <i>minimum improvement for accepted changes when b=1</i> - double <b>quality0</b> <i>minimum improvement for accepted changes when b=0</i> -) -</pre> -<dd> Marks nodes for remapping. Returns 1 if successful; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddBiasedUnderApprox">cuddBiasedUnderApprox</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="BuildConjuncts"></A> -static Conjuncts * <I></I> -<B>BuildConjuncts</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>node</b>, <i></i> - st_table * <b>distanceTable</b>, <i></i> - st_table * <b>cacheTable</b>, <i></i> - int <b>approxDistance</b>, <i></i> - int <b>maxLocalRef</b>, <i></i> - st_table * <b>ghTable</b>, <i></i> - st_table * <b>mintermTable</b> <i></i> -) -</pre> -<dd> Builds the conjuncts recursively, bottom up. Constants - are returned as (f, f). The cache is checked for previously computed - result. The decomposition points are determined by the local - reference count of this node and the longest distance from the - constant. At the decomposition point, the factors returned are (f, - 1). Recur on the two children. The order is determined by the - heavier branch. Combine the factors of the two children and pick the - one that already occurs in the gh table. Occurence in g is indicated - by value 1, occurence in h by 2, occurence in both 3. -<p> - -<dd> <b>See Also</b> <code><a href="#cuddConjunctsAux">cuddConjunctsAux</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddDecomp.c"TARGET="ABSTRACT"><CODE>cuddDecomp.c</CODE></A> - -<dt><pre> -<A NAME="BuildSubsetBdd"></A> -static DdNode * <I></I> -<B>BuildSubsetBdd</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - GlobalInfo_t * <b>gInfo</b>, <i>global information</i> - st_table * <b>pathTable</b>, <i>path table with path lengths and computed results</i> - DdNode * <b>node</b>, <i>current node</i> - struct AssortedInfo * <b>info</b>, <i>assorted information structure</i> - st_table * <b>subsetNodeTable</b> <i>table storing computed results</i> -) -</pre> -<dd> Builds the BDD with nodes labeled with path length - under maxpath and as many nodes labeled maxpath as determined by the - threshold. The procedure uses the path table to determine which nodes - in the original bdd need to be retained. This procedure picks a - shortest path (tie break decided by taking the child with the shortest - distance to the constant) and recurs down the path till it reaches the - constant. the procedure then starts building the subset upward from - the constant. All nodes labeled by path lengths less than the given - maxpath are used to build the subset. However, in the case of nodes - that have label equal to maxpath, as many are chosen as required by - the threshold. This number is stored in the info structure in the - field thresholdReached. This field is decremented whenever a node - labeled maxpath is encountered and the nodes labeled maxpath are - aggregated in a maxpath table. As soon as the thresholdReached count - goes to 0, the shortest path from this node to the constant is found. - The extraction of nodes with the above labeling is based on the fact - that each node, labeled with a path length, P, has at least one child - labeled P or less. So extracting all nodes labeled a given path length - P ensures complete paths between the root and the constant. Extraction - of a partial number of nodes with a given path length may result in - incomplete paths and hence the additional number of nodes are grabbed - to complete the path. Since the Bdd is built bottom-up, other nodes - labeled maxpath do lie on complete paths. The procedure may cause the - subset to have a larger or smaller number of nodes than the specified - threshold. The increase in the number of nodes is caused by the - building of a subset and the reduction by recombination. However in - most cases, the recombination overshadows the increase and the - procedure returns a result with lower number of nodes than specified. - The subsetNodeTable is NIL when there is no hard limit on the number - of nodes. Further efforts towards keeping the subset closer to the - threshold number were abandoned in favour of keeping the procedure - simple and fast. -<p> - -<dd> <b>Side Effects</b> SubsetNodeTable is changed if it is not NIL. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetSP.c"TARGET="ABSTRACT"><CODE>cuddSubsetSP.c</CODE></A> - -<dt><pre> -<A NAME="BuildSubsetBdd"></A> -static DdNode * <I></I> -<B>BuildSubsetBdd</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - DdNode * <b>node</b>, <i>current node</i> - int * <b>size</b>, <i>current size of the subset</i> - st_table * <b>visitedTable</b>, <i>visited table storing all node data</i> - int <b>threshold</b>, <i></i> - st_table * <b>storeTable</b>, <i></i> - st_table * <b>approxTable</b> <i></i> -) -</pre> -<dd> The procedure carries out the building of the subset BDD - starting at the root. Using the three different counts labelling each node, - the procedure chooses the heavier branch starting from the root and keeps - track of the number of nodes it discards at each step, thus keeping count - of the size of the subset BDD dynamically. Once the threshold is satisfied, - the procedure then calls ITE to build the BDD. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetHB.c"TARGET="ABSTRACT"><CODE>cuddSubsetHB.c</CODE></A> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE *�value�"></A> - <I></I> -<B>CUDD_VALUE_TYPE *�value�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE *�value�"></A> - <I></I> -<B>CUDD_VALUE_TYPE *�value�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE �c�"></A> - <I></I> -<B>CUDD_VALUE_TYPE �c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE �ep�"></A> - <I></I> -<B>CUDD_VALUE_TYPE �ep�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE �upper�"></A> - <I></I> -<B>CUDD_VALUE_TYPE �upper�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE �value�"></A> - <I></I> -<B>CUDD_VALUE_TYPE �value�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE �value�"></A> - <I></I> -<B>CUDD_VALUE_TYPE �value�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CheckInTables"></A> -static Conjuncts * <I></I> -<B>CheckInTables</B>( - DdNode * <b>node</b>, <i></i> - DdNode * <b>g1</b>, <i></i> - DdNode * <b>h1</b>, <i></i> - DdNode * <b>g2</b>, <i></i> - DdNode * <b>h2</b>, <i></i> - st_table * <b>ghTable</b>, <i></i> - st_table * <b>cacheTable</b>, <i></i> - int * <b>outOfMem</b> <i></i> -) -</pre> -<dd> Check if the two pairs exist in the table. If any of - the conjuncts do exist, store in the cache and return the - corresponding pair. -<p> - -<dd> <b>See Also</b> <code><a href="#ZeroCase">ZeroCase</a> -<a href="#BuildConjuncts">BuildConjuncts</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddDecomp.c"TARGET="ABSTRACT"><CODE>cuddDecomp.c</CODE></A> - -<dt><pre> -<A NAME="CheckTablesCacheAndReturn"></A> -static Conjuncts * <I></I> -<B>CheckTablesCacheAndReturn</B>( - DdNode * <b>node</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b>, <i></i> - st_table * <b>ghTable</b>, <i></i> - st_table * <b>cacheTable</b> <i></i> -) -</pre> -<dd> Check the tables for the existence of pair and return - one combination, cache the result. The assumption is that one of the - conjuncts is already in the tables. -<p> - -<dd> <b>Side Effects</b> g and h referenced for the cache -<p> - -<dd> <b>See Also</b> <code><a href="#ZeroCase">ZeroCase</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddDecomp.c"TARGET="ABSTRACT"><CODE>cuddDecomp.c</CODE></A> - -<dt><pre> -<A NAME="ConjunctsFree"></A> -static void <I></I> -<B>ConjunctsFree</B>( - DdManager * <b>dd</b>, <i></i> - Conjuncts * <b>factors</b> <i></i> -) -</pre> -<dd> Free factors structure -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddDecomp.c"TARGET="ABSTRACT"><CODE>cuddDecomp.c</CODE></A> - -<dt><pre> -<A NAME="CorrelCleanUp"></A> -static enum st_retval <I></I> -<B>CorrelCleanUp</B>( - char * <b>key</b>, <i></i> - char * <b>value</b>, <i></i> - char * <b>arg</b> <i></i> -) -</pre> -<dd> Frees memory associated with hash table. Returns - ST_CONTINUE. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddCorr.c"TARGET="ABSTRACT"><CODE>cuddBddCorr.c</CODE></A> - -<dt><pre> -<A NAME="CorrelCompare"></A> -static int <I></I> -<B>CorrelCompare</B>( - const char * <b>key1</b>, <i></i> - const char * <b>key2</b> <i></i> -) -</pre> -<dd> Compares two hash table entries. Returns 0 if they are - identical; 1 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddCorr.c"TARGET="ABSTRACT"><CODE>cuddBddCorr.c</CODE></A> - -<dt><pre> -<A NAME="CorrelHash"></A> -static int <I></I> -<B>CorrelHash</B>( - char * <b>key</b>, <i></i> - int <b>modulus</b> <i></i> -) -</pre> -<dd> Hashes a hash table entry. It is patterned after - st_strhash. Returns a value between 0 and modulus. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddCorr.c"TARGET="ABSTRACT"><CODE>cuddBddCorr.c</CODE></A> - -<dt><pre> -<A NAME="CountMinterms"></A> -static double <I></I> -<B>CountMinterms</B>( - DdNode * <b>node</b>, <i></i> - double <b>max</b>, <i></i> - st_table * <b>mintermTable</b>, <i></i> - FILE * <b>fp</b> <i></i> -) -</pre> -<dd> Count the number of minterms of each node ina a BDD and - store it in a hash table. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddDecomp.c"TARGET="ABSTRACT"><CODE>cuddDecomp.c</CODE></A> - -<dt><pre> -<A NAME="CreateBotDist"></A> -static NodeStat * <I></I> -<B>CreateBotDist</B>( - DdNode * <b>node</b>, <i></i> - st_table * <b>distanceTable</b> <i></i> -) -</pre> -<dd> Get longest distance of node from constant. Returns the - distance of the root from the constant if successful; CUDD_OUT_OF_MEM - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddDecomp.c"TARGET="ABSTRACT"><CODE>cuddDecomp.c</CODE></A> - -<dt><pre> -<A NAME="CreateBotDist"></A> -static int <I></I> -<B>CreateBotDist</B>( - DdNode * <b>node</b>, <i>current node</i> - st_table * <b>pathTable</b>, <i>path table with path lengths</i> - unsigned int * <b>pathLengthArray</b>, <i>array that stores number of nodes belonging to a particular path length.</i> - FILE * <b>fp</b> <i>where to write messages</i> -) -</pre> -<dd> Labels each node with the shortest distance from the constant. - This is done in a DFS search of the BDD. Each node has an odd - and even parity distance from the sink (since there exists paths to both - zero and one) which is less than MAXSHORTINT. At each node these distances - are updated using the minimum distance of its children from the constant. - SInce now both the length from the root and child is known, the minimum path - length(length of the shortest path between the root and the constant that - this node lies on) of this node can be calculated and used to update the - pathLengthArray -<p> - -<dd> <b>Side Effects</b> Updates Path Table and path length array -<p> - -<dd> <b>See Also</b> <code><a href="#CreatePathTable">CreatePathTable</a> -<a href="#CreateTopDist">CreateTopDist</a> -<a href="#AssessPathLength">AssessPathLength</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetSP.c"TARGET="ABSTRACT"><CODE>cuddSubsetSP.c</CODE></A> - -<dt><pre> -<A NAME="CreatePathTable"></A> -static st_table * <I></I> -<B>CreatePathTable</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - GlobalInfo_t * <b>gInfo</b>, <i>global information</i> - DdNode * <b>node</b>, <i>root of function</i> - unsigned int * <b>pathLengthArray</b>, <i>array of path lengths to store nodes labeled with the various path lengths</i> - FILE * <b>fp</b> <i>where to write messages</i> -) -</pre> -<dd> The outer procedure to label each node with its shortest - distance from the root and constant. Calls CreateTopDist and CreateBotDist. - The basis for computing the distance between root and constant is that - the distance may be the sum of even distances from the node to the root - and constant or the sum of odd distances from the node to the root and - constant. Both CreateTopDist and CreateBotDist create the odd and - even parity distances from the root and constant respectively. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#CreateTopDist">CreateTopDist</a> -<a href="#CreateBotDist">CreateBotDist</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetSP.c"TARGET="ABSTRACT"><CODE>cuddSubsetSP.c</CODE></A> - -<dt><pre> -<A NAME="CreateTopDist"></A> -static void <I></I> -<B>CreateTopDist</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - GlobalInfo_t * <b>gInfo</b>, <i>global information</i> - st_table * <b>pathTable</b>, <i>hast table to store path lengths</i> - int <b>parentPage</b>, <i>the pointer to the page on which the first parent in the queue is to be found.</i> - int <b>parentQueueIndex</b>, <i>pointer to the first parent on the page</i> - int <b>topLen</b>, <i>current distance from the root</i> - DdNode ** <b>childPage</b>, <i>pointer to the page on which the first child is to be added.</i> - int <b>childQueueIndex</b>, <i>pointer to the first child</i> - int <b>numParents</b>, <i>number of parents to process in this recursive call</i> - FILE * <b>fp</b> <i>where to write messages</i> -) -</pre> -<dd> Labels each node with its shortest distance from the root. - This is done in a BFS search of the BDD. The nodes are processed - in a queue implemented as pages(array) to reduce memory fragmentation. - An entry is created for each node visited. The distance from the root - to the node with the corresponding parity is updated. The procedure - is called recursively each recusion level handling nodes at a given - level from the root. -<p> - -<dd> <b>Side Effects</b> Creates entries in the pathTable -<p> - -<dd> <b>See Also</b> <code><a href="#CreatePathTable">CreatePathTable</a> -<a href="#CreateBotDist">CreateBotDist</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetSP.c"TARGET="ABSTRACT"><CODE>cuddSubsetSP.c</CODE></A> - -<dt><pre> -<A NAME="Cudd_AggregationType �gc�"></A> - <I></I> -<B>Cudd_AggregationType �gc�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_HookType �where�"></A> - <I></I> -<B>Cudd_HookType �where�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_HookType �where�"></A> - <I></I> -<B>Cudd_HookType �where�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_HookType �where�"></A> - <I></I> -<B>Cudd_HookType �where�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_ReorderingType *�method�"></A> - <I></I> -<B>Cudd_ReorderingType *�method�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_ReorderingType *�method�"></A> - <I></I> -<B>Cudd_ReorderingType *�method�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_ReorderingType �method�"></A> - <I></I> -<B>Cudd_ReorderingType �method�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_ReorderingType �method�"></A> - <I></I> -<B>Cudd_ReorderingType �method�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DD_PRFP �Pifunc�function used to build Pi if it is NULL"></A> - <I></I> -<B>DD_PRFP �Pifunc�function used to build Pi if it is NULL</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaDigit �literal�"></A> - <I></I> -<B>DdApaDigit �literal�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �b�"></A> - <I></I> -<B>DdApaNumber �b�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �dest�"></A> - <I></I> -<B>DdApaNumber �dest�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �diff�"></A> - <I></I> -<B>DdApaNumber �diff�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �number�"></A> - <I></I> -<B>DdApaNumber �number�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �number�"></A> - <I></I> -<B>DdApaNumber �number�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �quotient�"></A> - <I></I> -<B>DdApaNumber �quotient�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �quotient�"></A> - <I></I> -<B>DdApaNumber �quotient�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �second�"></A> - <I></I> -<B>DdApaNumber �second�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �sum�"></A> - <I></I> -<B>DdApaNumber �sum�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdGen *�gen�"></A> - <I></I> -<B>DdGen *�gen�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdGen *�gen�"></A> - <I></I> -<B>DdGen *�gen�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�manager�"></A> - <I></I> -<B>DdManager *�manager�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�table�"></A> - <I></I> -<B>DdManager *�table�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�table�"></A> - <I></I> -<B>DdManager *�table�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�table�"></A> - <I></I> -<B>DdManager *�table�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�table�"></A> - <I></I> -<B>DdManager *�table�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�conjuncts�address of the array of conjuncts"></A> - <I></I> -<B>DdNode ***�conjuncts�address of the array of conjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�conjuncts�address of the array of conjuncts"></A> - <I></I> -<B>DdNode ***�conjuncts�address of the array of conjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�conjuncts�address of the array of conjuncts"></A> - <I></I> -<B>DdNode ***�conjuncts�address of the array of conjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�conjuncts�address of the first factor"></A> - <I></I> -<B>DdNode ***�conjuncts�address of the first factor</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�disjuncts�address of the array of the disjuncts"></A> - <I></I> -<B>DdNode ***�disjuncts�address of the array of the disjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�disjuncts�address of the array of the disjuncts"></A> - <I></I> -<B>DdNode ***�disjuncts�address of the array of the disjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�disjuncts�address of the array of the disjuncts"></A> - <I></I> -<B>DdNode ***�disjuncts�address of the array of the disjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�disjuncts�address of the array of the disjuncts"></A> - <I></I> -<B>DdNode ***�disjuncts�address of the array of the disjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�node�"></A> - <I></I> -<B>DdNode **�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�node�"></A> - <I></I> -<B>DdNode **�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�onlyG�cube of variables only in g"></A> - <I></I> -<B>DdNode **�onlyG�cube of variables only in g</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�vectorOff�"></A> - <I></I> -<B>DdNode **�vectorOff�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�vector�"></A> - <I></I> -<B>DdNode **�vector�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�vector�"></A> - <I></I> -<B>DdNode **�vector�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�vector�"></A> - <I></I> -<B>DdNode **�vector�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�y�array of y variables"></A> - <I></I> -<B>DdNode **�y�array of y variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�y�array of y variables"></A> - <I></I> -<B>DdNode **�y�array of y variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�y�array of y variables"></A> - <I></I> -<B>DdNode **�y�array of y variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�y�array of y variables"></A> - <I></I> -<B>DdNode **�y�array of y variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�y�array of y variables"></A> - <I></I> -<B>DdNode **�y�array of y variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�zdd_I�"></A> - <I></I> -<B>DdNode **�zdd_I�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�z�array of z variables"></A> - <I></I> -<B>DdNode **�z�array of z variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�z�array of z variables"></A> - <I></I> -<B>DdNode **�z�array of z variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�B�"></A> - <I></I> -<B>DdNode *�B�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�B�"></A> - <I></I> -<B>DdNode *�B�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�D�"></A> - <I></I> -<B>DdNode *�D�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�D�"></A> - <I></I> -<B>DdNode *�D�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�P�"></A> - <I></I> -<B>DdNode *�P�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�P�"></A> - <I></I> -<B>DdNode *�P�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�Q�"></A> - <I></I> -<B>DdNode *�Q�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�Q�"></A> - <I></I> -<B>DdNode *�Q�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�Q�"></A> - <I></I> -<B>DdNode *�Q�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�Q�"></A> - <I></I> -<B>DdNode *�Q�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�U�"></A> - <I></I> -<B>DdNode *�U�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�Y�"></A> - <I></I> -<B>DdNode *�Y�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�bck�"></A> - <I></I> -<B>DdNode *�bck�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�constraint (care set)"></A> - <I></I> -<B>DdNode *�c�constraint (care set)</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�epsilon�"></A> - <I></I> -<B>DdNode *�epsilon�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�DD whose support is sought"></A> - <I></I> -<B>DdNode *�f�DD whose support is sought</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�DD whose support is sought"></A> - <I></I> -<B>DdNode *�f�DD whose support is sought</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�DD whose support size is sought"></A> - <I></I> -<B>DdNode *�f�DD whose support size is sought</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�ZDD whose support is sought"></A> - <I></I> -<B>DdNode *�f�ZDD whose support is sought</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�function against which to expand"></A> - <I></I> -<B>DdNode *�f�function against which to expand</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�function in which to remap variables"></A> - <I></I> -<B>DdNode *ï¿½f�function in which to remap variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�function of which the cube is to be made a prime"></A> - <I></I> -<B>DdNode *�f�function of which the cube is to be made a prime</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�second operand"></A> - <I></I> -<B>DdNode *�g�second operand</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�h�"></A> - <I></I> -<B>DdNode *�h�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�h�"></A> - <I></I> -<B>DdNode *�h�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�h�"></A> - <I></I> -<B>DdNode *�h�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�h�"></A> - <I></I> -<B>DdNode *�h�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�h�"></A> - <I></I> -<B>DdNode *�h�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�n�"></A> - <I></I> -<B>DdNode *�n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�n�"></A> - <I></I> -<B>DdNode *�n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�n�"></A> - <I></I> -<B>DdNode *�n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�n�"></A> - <I></I> -<B>DdNode *�n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�n�"></A> - <I></I> -<B>DdNode *�n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�p_node�"></A> - <I></I> -<B>DdNode *�p_node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�phaseBdd�cube of the phases"></A> - <I></I> -<B>DdNode *�phaseBdd�cube of the phases</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�u�"></A> - <I></I> -<B>DdNode *�u�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�u�upper bound"></A> - <I></I> -<B>DdNode *�u�upper bound</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�var�variable"></A> - <I></I> -<B>DdNode *�var�variable</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdTlcInfo *�t�"></A> - <I></I> -<B>DdTlcInfo *�t�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="EpDouble *�epd�"></A> - <I></I> -<B>EpDouble *�epd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�"></A> - <I></I> -<B>FILE *�fp�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�"></A> - <I></I> -<B>FILE *�fp�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�"></A> - <I></I> -<B>FILE *�fp�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�"></A> - <I></I> -<B>FILE *�fp�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�"></A> - <I></I> -<B>FILE *�fp�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�pointer to the dump file"></A> - <I></I> -<B>FILE *�fp�pointer to the dump file</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�pointer to the dump file"></A> - <I></I> -<B>FILE *�fp�pointer to the dump file</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�pointer to the dump file"></A> - <I></I> -<B>FILE *�fp�pointer to the dump file</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�pointer to the dump file"></A> - <I></I> -<B>FILE *�fp�pointer to the dump file</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�pointer to the dump file"></A> - <I></I> -<B>FILE *�fp�pointer to the dump file</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="MarkCacheCleanUp"></A> -static enum st_retval <I></I> -<B>MarkCacheCleanUp</B>( - char * <b>key</b>, <i></i> - char * <b>value</b>, <i></i> - char * <b>arg</b> <i></i> -) -</pre> -<dd> Frees memory associated with computed table of - cuddBddLICMarkEdges. Returns ST_CONTINUE. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddLICompaction">Cudd_bddLICompaction</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="MarkCacheCompare"></A> -static int <I></I> -<B>MarkCacheCompare</B>( - const char * <b>ptr1</b>, <i></i> - const char * <b>ptr2</b> <i></i> -) -</pre> -<dd> Comparison function for the computed table of - cuddBddLICMarkEdges. Returns 0 if the two nodes of the key are equal; 1 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddLICompaction">Cudd_bddLICompaction</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="MarkCacheHash"></A> -static int <I></I> -<B>MarkCacheHash</B>( - char * <b>ptr</b>, <i></i> - int <b>modulus</b> <i></i> -) -</pre> -<dd> Hash function for the computed table of - cuddBddLICMarkEdges. Returns the bucket number. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddLICompaction">Cudd_bddLICompaction</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="MtrNode *�tree�"></A> - <I></I> -<B>MtrNode *�tree�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="MtrNode *�tree�"></A> - <I></I> -<B>MtrNode *�tree�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="PMX"></A> -static int <I></I> -<B>PMX</B>( - int <b>maxvar</b> <i></i> -) -</pre> -<dd> Performs the crossover between two randomly chosen - parents, and creates two children, x1 and x2. Uses the Partially - Matched Crossover operator. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME="PairInTables"></A> -static int <I></I> -<B>PairInTables</B>( - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b>, <i></i> - st_table * <b>ghTable</b> <i></i> -) -</pre> -<dd> .Check whether the given pair is in the tables. gTable - and hTable are combined. - absence in both is indicated by 0, - presence in gTable is indicated by 1, - presence in hTable by 2 and - presence in both by 3. - The values returned by this function are PAIR_ST, - PAIR_CR, G_ST, G_CR, H_ST, H_CR, BOTH_G, BOTH_H, NONE. - PAIR_ST implies g in gTable and h in hTable - PAIR_CR implies g in hTable and h in gTable - G_ST implies g in gTable and h not in any table - G_CR implies g in hTable and h not in any table - H_ST implies h in hTable and g not in any table - H_CR implies h in gTable and g not in any table - BOTH_G implies both in gTable - BOTH_H implies both in hTable - NONE implies none in table; -<p> - -<dd> <b>See Also</b> <code><a href="#CheckTablesCacheAndReturn">CheckTablesCacheAndReturn</a> -<a href="#CheckInTables">CheckInTables</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddDecomp.c"TARGET="ABSTRACT"><CODE>cuddDecomp.c</CODE></A> - -<dt><pre> -<A NAME="PickOnePair"></A> -static Conjuncts * <I></I> -<B>PickOnePair</B>( - DdNode * <b>node</b>, <i></i> - DdNode * <b>g1</b>, <i></i> - DdNode * <b>h1</b>, <i></i> - DdNode * <b>g2</b>, <i></i> - DdNode * <b>h2</b>, <i></i> - st_table * <b>ghTable</b>, <i></i> - st_table * <b>cacheTable</b> <i></i> -) -</pre> -<dd> Check the tables for the existence of pair and return - one combination, store in cache. The pair that has more pointers to - it is picked. An approximation of the number of local pointers is - made by taking the reference count of the pairs sent. -<p> - -<dd> <b>See Also</b> <code><a href="#ZeroCase">ZeroCase</a> -<a href="#BuildConjuncts">BuildConjuncts</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddDecomp.c"TARGET="ABSTRACT"><CODE>cuddDecomp.c</CODE></A> - -<dt><pre> -<A NAME="RAbuildSubset"></A> -static DdNode * <I></I> -<B>RAbuildSubset</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - DdNode * <b>node</b>, <i>current node</i> - ApproxInfo * <b>info</b> <i>node info</i> -) -</pre> -<dd> Builds the subset BDDfor cuddRemapUnderApprox. Based - on the info table, performs remapping or replacement at selected - nodes. Returns a pointer to the result if successful; NULL - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddRemapUnderApprox">cuddRemapUnderApprox</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="RAmarkNodes"></A> -static int <I></I> -<B>RAmarkNodes</B>( - DdManager * <b>dd</b>, <i>manager</i> - DdNode * <b>f</b>, <i>function to be analyzed</i> - ApproxInfo * <b>info</b>, <i>info on BDD</i> - int <b>threshold</b>, <i>when to stop approximating</i> - double <b>quality</b> <i>minimum improvement for accepted changes</i> -) -</pre> -<dd> Marks nodes for remapping. Returns 1 if successful; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddRemapUnderApprox">cuddRemapUnderApprox</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="ResizeCountMintermPages"></A> -static void <I></I> -<B>ResizeCountMintermPages</B>( - <b></b> <i></i> -) -</pre> -<dd> Resize the number of pages allocated to store the minterm - counts. The procedure moves the counter to the next page when the - end of the page is reached and allocates new pages when necessary. -<p> - -<dd> <b>Side Effects</b> Changes the size of minterm pages, page, page index, maximum - number of pages freeing stuff in case of memory out. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetHB.c"TARGET="ABSTRACT"><CODE>cuddSubsetHB.c</CODE></A> - -<dt><pre> -<A NAME="ResizeCountNodePages"></A> -static void <I></I> -<B>ResizeCountNodePages</B>( - <b></b> <i></i> -) -</pre> -<dd> Resize the number of pages allocated to store the node counts. - The procedure moves the counter to the next page when the end of - the page is reached and allocates new pages when necessary. -<p> - -<dd> <b>Side Effects</b> Changes the size of pages, page, page index, maximum - number of pages freeing stuff in case of memory out. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetHB.c"TARGET="ABSTRACT"><CODE>cuddSubsetHB.c</CODE></A> - -<dt><pre> -<A NAME="ResizeNodeDataPages"></A> -static void <I></I> -<B>ResizeNodeDataPages</B>( - <b></b> <i></i> -) -</pre> -<dd> Resize the number of pages allocated to store the node data - The procedure moves the counter to the next page when the end of - the page is reached and allocates new pages when necessary. -<p> - -<dd> <b>Side Effects</b> Changes the size of pages, page, page index, maximum - number of pages freeing stuff in case of memory out. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetHB.c"TARGET="ABSTRACT"><CODE>cuddSubsetHB.c</CODE></A> - -<dt><pre> -<A NAME="ResizeNodeDistPages"></A> -static void <I></I> -<B>ResizeNodeDistPages</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - GlobalInfo_t * <b>gInfo</b> <i>global information</i> -) -</pre> -<dd> Resize the number of pages allocated to store the distances - related to each node. The procedure moves the counter to the - next page when the end of the page is reached and allocates new - pages when necessary. -<p> - -<dd> <b>Side Effects</b> Changes the size of pages, page, page index, maximum - number of pages freeing stuff in case of memory out. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetSP.c"TARGET="ABSTRACT"><CODE>cuddSubsetSP.c</CODE></A> - -<dt><pre> -<A NAME="ResizeQueuePages"></A> -static void <I></I> -<B>ResizeQueuePages</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - GlobalInfo_t * <b>gInfo</b> <i>global information</i> -) -</pre> -<dd> Resize the number of pages allocated to store nodes in the BFS - traversal of the Bdd. The procedure moves the counter to the - next page when the end of the page is reached and allocates new - pages when necessary. -<p> - -<dd> <b>Side Effects</b> Changes the size of pages, page, page index, maximum - number of pages freeing stuff in case of memory out. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetSP.c"TARGET="ABSTRACT"><CODE>cuddSubsetSP.c</CODE></A> - -<dt><pre> -<A NAME="StoreNodes"></A> -static void <I></I> -<B>StoreNodes</B>( - st_table * <b>storeTable</b>, <i></i> - DdManager * <b>dd</b>, <i></i> - DdNode * <b>node</b> <i></i> -) -</pre> -<dd> rocedure to recursively store nodes that are retained in the subset. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#StoreNodes">StoreNodes</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetHB.c"TARGET="ABSTRACT"><CODE>cuddSubsetHB.c</CODE></A> - -<dt><pre> -<A NAME="SubsetCountMintermAux"></A> -static double <I></I> -<B>SubsetCountMintermAux</B>( - DdNode * <b>node</b>, <i>function to analyze</i> - double <b>max</b>, <i>number of minterms of constant 1</i> - st_table * <b>table</b> <i>visitedTable table</i> -) -</pre> -<dd> Recursively counts minterms of each node in the DAG. - Similar to the cuddCountMintermAux which recursively counts the - number of minterms for the dag rooted at each node in terms of the - total number of variables (max). This procedure creates the node - data structure and stores the minterm count as part of the node - data structure. -<p> - -<dd> <b>Side Effects</b> Creates structures of type node quality and fills the st_table -<p> - -<dd> <b>See Also</b> <code><a href="#SubsetCountMinterm">SubsetCountMinterm</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetHB.c"TARGET="ABSTRACT"><CODE>cuddSubsetHB.c</CODE></A> - -<dt><pre> -<A NAME="SubsetCountMinterm"></A> -static st_table * <I></I> -<B>SubsetCountMinterm</B>( - DdNode * <b>node</b>, <i>function to be analyzed</i> - int <b>nvars</b> <i>number of variables node depends on</i> -) -</pre> -<dd> Counts minterms of each node in the DAG. Similar to the - Cudd_CountMinterm procedure except this returns the minterm count for - all the nodes in the bdd in an st_table. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#SubsetCountMintermAux">SubsetCountMintermAux</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetHB.c"TARGET="ABSTRACT"><CODE>cuddSubsetHB.c</CODE></A> - -<dt><pre> -<A NAME="SubsetCountNodesAux"></A> -static int <I></I> -<B>SubsetCountNodesAux</B>( - DdNode * <b>node</b>, <i>current node</i> - st_table * <b>table</b>, <i>table to update node count, also serves as visited table.</i> - double <b>max</b> <i>maximum number of variables</i> -) -</pre> -<dd> Recursively counts the number of nodes under the dag. - Also counts the number of nodes under the lighter child of - this node. . Note that the same dag may be the lighter child of two - different nodes and have different counts. As with the minterm counts, - the node counts are stored in pages to be space efficient and the - address for these node counts are stored in an st_table associated - to each node. -<p> - -<dd> <b>Side Effects</b> Updates the node data table with node counts -<p> - -<dd> <b>See Also</b> <code><a href="#SubsetCountNodes">SubsetCountNodes</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetHB.c"TARGET="ABSTRACT"><CODE>cuddSubsetHB.c</CODE></A> - -<dt><pre> -<A NAME="SubsetCountNodes"></A> -static int <I></I> -<B>SubsetCountNodes</B>( - DdNode * <b>node</b>, <i>function to be analyzed</i> - st_table * <b>table</b>, <i>node quality table</i> - int <b>nvars</b> <i>number of variables node depends on</i> -) -</pre> -<dd> Counts the nodes under the current node and its lighter - child. Calls a recursive procedure to count the number of nodes of - a DAG rooted at a particular node and the number of nodes taken by its - lighter child. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#SubsetCountNodesAux">SubsetCountNodesAux</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetHB.c"TARGET="ABSTRACT"><CODE>cuddSubsetHB.c</CODE></A> - -<dt><pre> -<A NAME="UAbuildSubset"></A> -static DdNode * <I></I> -<B>UAbuildSubset</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - DdNode * <b>node</b>, <i>current node</i> - ApproxInfo * <b>info</b> <i>node info</i> -) -</pre> -<dd> Builds the subset BDD. Based on the info table, - replaces selected nodes by zero. Returns a pointer to the result if - successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddUnderApprox">cuddUnderApprox</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="UAmarkNodes"></A> -static int <I></I> -<B>UAmarkNodes</B>( - DdManager * <b>dd</b>, <i>manager</i> - DdNode * <b>f</b>, <i>function to be analyzed</i> - ApproxInfo * <b>info</b>, <i>info on BDD</i> - int <b>threshold</b>, <i>when to stop approximating</i> - int <b>safe</b>, <i>enforce safe approximation</i> - double <b>quality</b> <i>minimum improvement for accepted changes</i> -) -</pre> -<dd> Marks nodes for replacement by zero. Returns 1 if successful; - 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddUnderApprox">cuddUnderApprox</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="ZeroCase"></A> -static Conjuncts * <I></I> -<B>ZeroCase</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>node</b>, <i></i> - Conjuncts * <b>factorsNv</b>, <i></i> - st_table * <b>ghTable</b>, <i></i> - st_table * <b>cacheTable</b>, <i></i> - int <b>switched</b> <i></i> -) -</pre> -<dd> If one child is zero, do explicitly what Restrict does or better. - First separate a variable and its child in the base case. In case of a cube - times a function, separate the cube and function. As a last resort, look in - tables. -<p> - -<dd> <b>Side Effects</b> Frees the BDDs in factorsNv. factorsNv itself is not freed - because it is freed above. -<p> - -<dd> <b>See Also</b> <code><a href="#BuildConjuncts">BuildConjuncts</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddDecomp.c"TARGET="ABSTRACT"><CODE>cuddDecomp.c</CODE></A> - -<dt><pre> -<A NAME="addBddDoInterval"></A> -static DdNode * <I></I> -<B>addBddDoInterval</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>l</b>, <i></i> - DdNode * <b>u</b> <i></i> -) -</pre> -<dd> Performs the recursive step for Cudd_addBddInterval. - Returns a pointer to the BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#addBddDoThreshold">addBddDoThreshold</a> -<a href="#addBddDoStrictThreshold">addBddDoStrictThreshold</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBridge.c"TARGET="ABSTRACT"><CODE>cuddBridge.c</CODE></A> - -<dt><pre> -<A NAME="addBddDoIthBit"></A> -static DdNode * <I></I> -<B>addBddDoIthBit</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>index</b> <i></i> -) -</pre> -<dd> Performs the recursive step for Cudd_addBddIthBit. - Returns a pointer to the BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBridge.c"TARGET="ABSTRACT"><CODE>cuddBridge.c</CODE></A> - -<dt><pre> -<A NAME="addBddDoStrictThreshold"></A> -static DdNode * <I></I> -<B>addBddDoStrictThreshold</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>val</b> <i></i> -) -</pre> -<dd> Performs the recursive step for Cudd_addBddStrictThreshold. - Returns a pointer to the BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#addBddDoThreshold">addBddDoThreshold</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBridge.c"TARGET="ABSTRACT"><CODE>cuddBridge.c</CODE></A> - -<dt><pre> -<A NAME="addBddDoThreshold"></A> -static DdNode * <I></I> -<B>addBddDoThreshold</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>val</b> <i></i> -) -</pre> -<dd> Performs the recursive step for Cudd_addBddThreshold. - Returns a pointer to the BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#addBddDoStrictThreshold">addBddDoStrictThreshold</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBridge.c"TARGET="ABSTRACT"><CODE>cuddBridge.c</CODE></A> - -<dt><pre> -<A NAME="addCheckPositiveCube"></A> -static int <I></I> -<B>addCheckPositiveCube</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>cube</b> <i></i> -) -</pre> -<dd> Checks whether cube is an ADD representing the product of - positive literals. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddAbs.c"TARGET="ABSTRACT"><CODE>cuddAddAbs.c</CODE></A> - -<dt><pre> -<A NAME="addDoIthBit"></A> -static DdNode * <I></I> -<B>addDoIthBit</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>index</b> <i></i> -) -</pre> -<dd> Performs the recursive step for Cudd_addIthBit. - Returns a pointer to the BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddFind.c"TARGET="ABSTRACT"><CODE>cuddAddFind.c</CODE></A> - -<dt><pre> -<A NAME="addMMRecur"></A> -static DdNode * <I></I> -<B>addMMRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>A</b>, <i></i> - DdNode * <b>B</b>, <i></i> - int <b>topP</b>, <i></i> - int * <b>vars</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addMatrixMultiply. - Returns a pointer to the result if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddMatMult.c"TARGET="ABSTRACT"><CODE>cuddMatMult.c</CODE></A> - -<dt><pre> -<A NAME="addMultiplicityGroups"></A> -static int <I></I> -<B>addMultiplicityGroups</B>( - DdManager * <b>dd</b>, <i>manager</i> - MtrNode * <b>treenode</b>, <i>current tree node</i> - int <b>multiplicity</b>, <i>how many ZDD vars per BDD var</i> - char * <b>vmask</b>, <i>variable pairs for which a group has been already built</i> - char * <b>lmask</b> <i>levels for which a group has already been built</i> -) -</pre> -<dd> Adds multiplicity groups to a ZDD variable group tree. - Returns 1 if successful; 0 otherwise. This function creates the groups - for set of ZDD variables (whose cardinality is given by parameter - multiplicity) that are created for each BDD variable in - Cudd_zddVarsFromBddVars. The crux of the matter is to determine the index - each new group. (The index of the first variable in the group.) - We first build all the groups for the children of a node, and then deal - with the ZDD variables that are directly attached to the node. The problem - for these is that the tree itself does not provide information on their - position inside the group. While we deal with the children of the node, - therefore, we keep track of all the positions they occupy. The remaining - positions in the tree can be freely used. Also, we keep track of all the - variables placed in the children. All the remaining variables are directly - attached to the group. We can then place any pair of variables not yet - grouped in any pair of available positions in the node. -<p> - -<dd> <b>Side Effects</b> Changes the variable group tree. -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddVarsFromBddVars">Cudd_zddVarsFromBddVars</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAPI.c"TARGET="ABSTRACT"><CODE>cuddAPI.c</CODE></A> - -<dt><pre> -<A NAME="addTriangleRecur"></A> -static DdNode * <I></I> -<B>addTriangleRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - int * <b>vars</b>, <i></i> - DdNode * <b>cube</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addTriangle. Returns - a pointer to the result if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddMatMult.c"TARGET="ABSTRACT"><CODE>cuddMatMult.c</CODE></A> - -<dt><pre> -<A NAME="addVarToConst"></A> -static void <I></I> -<B>addVarToConst</B>( - DdNode * <b>f</b>, <i></i> - DdNode ** <b>gp</b>, <i></i> - DdNode ** <b>hp</b>, <i></i> - DdNode * <b>one</b>, <i></i> - DdNode * <b>zero</b> <i></i> -) -</pre> -<dd> Replaces variables with constants if possible (part of - canonical form). -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddIte.c"TARGET="ABSTRACT"><CODE>cuddAddIte.c</CODE></A> - -<dt><pre> -<A NAME="addWalshInt"></A> -static DdNode * <I></I> -<B>addWalshInt</B>( - DdManager * <b>dd</b>, <i></i> - DdNode ** <b>x</b>, <i></i> - DdNode ** <b>y</b>, <i></i> - int <b>n</b> <i></i> -) -</pre> -<dd> Generates a Walsh matrix in ADD form. Returns a pointer - to the matrixi if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddWalsh.c"TARGET="ABSTRACT"><CODE>cuddAddWalsh.c</CODE></A> - -<dt><pre> -<A NAME="array_compare"></A> -static int <I></I> -<B>array_compare</B>( - const char * <b>array1</b>, <i></i> - const char * <b>array2</b> <i></i> -) -</pre> -<dd> Comparison function for the computed table. Returns 0 if - the two arrays are equal; 1 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME="array_hash"></A> -static int <I></I> -<B>array_hash</B>( - char * <b>array</b>, <i></i> - int <b>modulus</b> <i></i> -) -</pre> -<dd> Hash function for the computed table. Returns the bucket - number. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME="bddAnnotateMintermCount"></A> -static double <I></I> -<B>bddAnnotateMintermCount</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>node</b>, <i></i> - double <b>max</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Annotates every node in the BDD node with its minterm count. - In this function, every node and the minterm count represented by it are - stored in a hash table. -<p> - -<dd> <b>Side Effects</b> Fills up 'table' with the pair <node,minterm_count>. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSplit.c"TARGET="ABSTRACT"><CODE>cuddSplit.c</CODE></A> - -<dt><pre> -<A NAME="bddCheckPositiveCube"></A> -static int <I></I> -<B>bddCheckPositiveCube</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>cube</b> <i></i> -) -</pre> -<dd> Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddAbs.c"TARGET="ABSTRACT"><CODE>cuddBddAbs.c</CODE></A> - -<dt><pre> -<A NAME="bddCorrelationAux"></A> -static double <I></I> -<B>bddCorrelationAux</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddCorrelation. - Returns the fraction of minterms in the ON-set of the EXNOR of f and - g. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#bddCorrelationWeightsAux">bddCorrelationWeightsAux</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddCorr.c"TARGET="ABSTRACT"><CODE>cuddBddCorr.c</CODE></A> - -<dt><pre> -<A NAME="bddCorrelationWeightsAux"></A> -static double <I></I> -<B>bddCorrelationWeightsAux</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - double * <b>prob</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddCorrelationWeigths. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#bddCorrelationAux">bddCorrelationAux</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddCorr.c"TARGET="ABSTRACT"><CODE>cuddBddCorr.c</CODE></A> - -<dt><pre> -<A NAME="bddFixTree"></A> -static void <I></I> -<B>bddFixTree</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b> <i></i> -) -</pre> -<dd> Fixes the BDD variable group tree after a - shuffle. Assumes that the order of the variables in a terminal node - has not been changed. -<p> - -<dd> <b>Side Effects</b> Changes the BDD variable group tree. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="bddVarToCanonicalSimple"></A> -static int <I></I> -<B>bddVarToCanonicalSimple</B>( - DdManager * <b>dd</b>, <i></i> - DdNode ** <b>fp</b>, <i></i> - DdNode ** <b>gp</b>, <i></i> - DdNode ** <b>hp</b>, <i></i> - unsigned int * <b>topfp</b>, <i></i> - unsigned int * <b>topgp</b>, <i></i> - unsigned int * <b>tophp</b> <i></i> -) -</pre> -<dd> Makes sure the first two pointers are regular. This - mat require the complementation of the result, which is signaled by - returning 1 instead of 0. This function is simpler than the general - case because it assumes that no two arguments are the same or - complementary, and no argument is constant. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#bddVarToConst">bddVarToConst</a> -<a href="#bddVarToCanonical">bddVarToCanonical</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddIte.c"TARGET="ABSTRACT"><CODE>cuddBddIte.c</CODE></A> - -<dt><pre> -<A NAME="bddVarToCanonical"></A> -static int <I></I> -<B>bddVarToCanonical</B>( - DdManager * <b>dd</b>, <i></i> - DdNode ** <b>fp</b>, <i></i> - DdNode ** <b>gp</b>, <i></i> - DdNode ** <b>hp</b>, <i></i> - unsigned int * <b>topfp</b>, <i></i> - unsigned int * <b>topgp</b>, <i></i> - unsigned int * <b>tophp</b> <i></i> -) -</pre> -<dd> Reduces 2 variable expressions to canonical form. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#bddVarToConst">bddVarToConst</a> -<a href="#bddVarToCanonicalSimple">bddVarToCanonicalSimple</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddIte.c"TARGET="ABSTRACT"><CODE>cuddBddIte.c</CODE></A> - -<dt><pre> -<A NAME="bddVarToConst"></A> -static void <I></I> -<B>bddVarToConst</B>( - DdNode * <b>f</b>, <i></i> - DdNode ** <b>gp</b>, <i></i> - DdNode ** <b>hp</b>, <i></i> - DdNode * <b>one</b> <i></i> -) -</pre> -<dd> This function performs part of the transformation to - standard form by replacing variables with constants if possible. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#bddVarToCanonical">bddVarToCanonical</a> -<a href="#bddVarToCanonicalSimple">bddVarToCanonicalSimple</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddIte.c"TARGET="ABSTRACT"><CODE>cuddBddIte.c</CODE></A> - -<dt><pre> -<A NAME="beforep"></A> -static int <I></I> -<B>beforep</B>( - DdHalfWord <b>var1a</b>, <i></i> - short <b>phase1a</b>, <i></i> - DdHalfWord <b>var1b</b>, <i></i> - short <b>phase1b</b>, <i></i> - DdHalfWord <b>var2a</b>, <i></i> - short <b>phase2a</b>, <i></i> - DdHalfWord <b>var2b</b>, <i></i> - short <b>phase2b</b> <i></i> -) -</pre> -<dd> Returns true iff the first argument precedes the second - in the clause order. A clause precedes another if its first lieral - precedes the first literal of the other, or if the first literals - are the same, and its second literal precedes the second literal of - the other clause. A literal precedes another if it has a higher - index, of if it has the same index, but it has lower phase. Phase 0 - is the positive phase, and it is lower than Phase 1 (negative - phase). -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#equalp">equalp</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="bitVectorAlloc"></A> -static BitVector * <I></I> -<B>bitVectorAlloc</B>( - int <b>size</b> <i></i> -) -</pre> -<dd> Allocates a bit vector. The parameter size gives the - number of bits. This procedure allocates enough long's to hold the - specified number of bits. Returns a pointer to the allocated vector - if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#bitVectorClear">bitVectorClear</a> -<a href="#bitVectorFree">bitVectorFree</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="bitVectorFree"></A> -static void <I></I> -<B>bitVectorFree</B>( - BitVector * <b>vector</b> <i></i> -) -</pre> -<dd> Frees a bit vector. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#bitVectorAlloc">bitVectorAlloc</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="build_dd"></A> -static int <I></I> -<B>build_dd</B>( - DdManager * <b>table</b>, <i></i> - int <b>num</b>, <i>the index of the individual to be built</i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Builds a DD from a given order. This procedure also - sifts the final order and inserts into the array the size in nodes - of the result. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME="char *�string�"></A> - <I></I> -<B>char *�string�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="char *�str�pointer to string to use if != NULL"></A> - <I></I> -<B>char *�str�pointer to string to use if != NULL</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="checkSymmInfo"></A> -static int <I></I> -<B>checkSymmInfo</B>( - DdManager * <b>table</b>, <i></i> - DdHalfWord * <b>symmInfo</b>, <i></i> - int <b>index</b>, <i></i> - int <b>level</b> <i></i> -) -</pre> -<dd> Returns 1 if a variable is the one with the highest index - among those belonging to a symmetry group that are in the top part of - the BDD. The top part is given by level. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#initSymmInfo">initSymmInfo</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="computeClausesWithUniverse"></A> -static DdTlcInfo * <I></I> -<B>computeClausesWithUniverse</B>( - DdTlcInfo * <b>Cres</b>, <i>list of clauses for child</i> - DdHalfWord <b>label</b>, <i>variable labeling the current node</i> - short <b>phase</b> <i>0 if E child is zero; 1 if T child is zero</i> -) -</pre> -<dd> Computes the two-literal clauses for a node with a zero - child, given the clauses for its other child and the label of the - node. Returns a pointer to a TclInfo structure if successful; NULL - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#computeClauses">computeClauses</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="computeClauses"></A> -static DdTlcInfo * <I></I> -<B>computeClauses</B>( - DdTlcInfo * <b>Tres</b>, <i>list of clauses for T child</i> - DdTlcInfo * <b>Eres</b>, <i>list of clauses for E child</i> - DdHalfWord <b>label</b>, <i>variable labeling the current node</i> - int <b>size</b> <i>number of variables in the manager</i> -) -</pre> -<dd> Computes the two-literal clauses for a node given the - clauses for its children and the label of the node. Returns a - pointer to a TclInfo structure if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#computeClausesWithUniverse">computeClausesWithUniverse</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="computeLB"></A> -static int <I></I> -<B>computeLB</B>( - DdManager * <b>table</b>, <i>manager</i> - DdHalfWord * <b>order</b>, <i>optimal order for the subset</i> - int <b>roots</b>, <i>roots between lower and upper</i> - int <b>cost</b>, <i>minimum cost for the subset</i> - int <b>lower</b>, <i>lower level to be reordered</i> - int <b>upper</b>, <i>upper level to be reordered</i> - int <b>level</b> <i>offset for the current top bottom var</i> -) -</pre> -<dd> Computes a lower bound on the size of a BDD from the - following factors: - <ul> - <li> size of the lower part of it; - <li> size of the part of the upper part not subjected to reordering; - <li> number of roots in the part of the BDD subjected to reordering; - <li> variable in the support of the roots in the upper part of the - BDD subjected to reordering. - <ul/> -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="computeSavings"></A> -static int <I></I> -<B>computeSavings</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>skip</b>, <i></i> - ApproxInfo * <b>info</b>, <i></i> - DdLevelQueue * <b>queue</b> <i></i> -) -</pre> -<dd> Counts the nodes that would be eliminated if a given - node were replaced by zero. This procedure uses a queue passed by - the caller for efficiency: since the queue is left empty at the - endof the search, it can be reused as is by the next search. Returns - the count (always striclty positive) if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code>UAmarkNodes -RAmarkNodes -BAmarkNodes -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="copyOrder"></A> -static void <I></I> -<B>copyOrder</B>( - DdManager * <b>table</b>, <i></i> - int * <b>array</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Copies the current variable order to array. - At the same time inverts the permutation. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAnneal.c"TARGET="ABSTRACT"><CODE>cuddAnneal.c</CODE></A> - -<dt><pre> -<A NAME="createResult"></A> -static DdNode * <I></I> -<B>createResult</B>( - DdManager * <b>dd</b>, <i></i> - unsigned int <b>index</b>, <i></i> - unsigned int <b>phase</b>, <i></i> - DdNode * <b>cube</b>, <i></i> - CUDD_VALUE_TYPE <b>distance</b> <i></i> -) -</pre> -<dd> Builds a result for cache storage. Returns a pointer - to the resulting ADD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddBddClosestCube">cuddBddClosestCube</a> -separateCube -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddPriority.c"TARGET="ABSTRACT"><CODE>cuddPriority.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddApplyRecur"></A> -DdNode * <I></I> -<B>cuddAddApplyRecur</B>( - DdManager * <b>dd</b>, <i></i> - DD_AOP <b>op</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addApply. Returns a - pointer to the result if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddAddMonadicApplyRecur">cuddAddMonadicApplyRecur</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddApply.c"TARGET="ABSTRACT"><CODE>cuddAddApply.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddBddDoPattern"></A> -DdNode * <I></I> -<B>cuddAddBddDoPattern</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Performs the recursive step for Cudd_addBddPattern. Returns a - pointer to the resulting BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBridge.c"TARGET="ABSTRACT"><CODE>cuddBridge.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddCmplRecur"></A> -DdNode * <I></I> -<B>cuddAddCmplRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addCmpl. Returns a - pointer to the resulting ADD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_addCmpl">Cudd_addCmpl</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddIte.c"TARGET="ABSTRACT"><CODE>cuddAddIte.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddComposeRecur"></A> -DdNode * <I></I> -<B>cuddAddComposeRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>proj</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addCompose. - Returns the composed BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_addCompose">Cudd_addCompose</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCompose.c"TARGET="ABSTRACT"><CODE>cuddCompose.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddConstrainRecur"></A> -DdNode * <I></I> -<B>cuddAddConstrainRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>c</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addConstrain. - Returns a pointer to the result if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_addConstrain">Cudd_addConstrain</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddExistAbstractRecur"></A> -DdNode * <I></I> -<B>cuddAddExistAbstractRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>cube</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addExistAbstract. - Returns the ADD obtained by abstracting the variables of cube from f, - if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddAbs.c"TARGET="ABSTRACT"><CODE>cuddAddAbs.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddGeneralVectorComposeRecur"></A> -static DdNode * <I></I> -<B>cuddAddGeneralVectorComposeRecur</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - DdHashTable * <b>table</b>, <i>computed table</i> - DdNode * <b>f</b>, <i>ADD in which to compose</i> - DdNode ** <b>vectorOn</b>, <i>functions to substitute for x_i</i> - DdNode ** <b>vectorOff</b>, <i>functions to substitute for x_i'</i> - int <b>deepest</b> <i>depth of deepest substitution</i> -) -</pre> -<dd> Performs the recursive step of Cudd_addGeneralVectorCompose. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCompose.c"TARGET="ABSTRACT"><CODE>cuddCompose.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddIteRecur"></A> -DdNode * <I></I> -<B>cuddAddIteRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b> <i></i> -) -</pre> -<dd> Implements the recursive step of Cudd_addIte(f,g,h). - Returns a pointer to the resulting ADD if successful; NULL - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_addIte">Cudd_addIte</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddIte.c"TARGET="ABSTRACT"><CODE>cuddAddIte.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddMonadicApplyRecur"></A> -DdNode * <I></I> -<B>cuddAddMonadicApplyRecur</B>( - DdManager * <b>dd</b>, <i></i> - DD_MAOP <b>op</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addMonadicApply. Returns a - pointer to the result if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddAddApplyRecur">cuddAddApplyRecur</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddApply.c"TARGET="ABSTRACT"><CODE>cuddAddApply.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddNegateRecur"></A> -DdNode * <I></I> -<B>cuddAddNegateRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Implements the recursive step of Cudd_addNegate. - Returns a pointer to the result. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddNeg.c"TARGET="ABSTRACT"><CODE>cuddAddNeg.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddNonSimComposeRecur"></A> -static DdNode * <I></I> -<B>cuddAddNonSimComposeRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode ** <b>vector</b>, <i></i> - DdNode * <b>key</b>, <i></i> - DdNode * <b>cube</b>, <i></i> - int <b>lastsub</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addNonSimCompose. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCompose.c"TARGET="ABSTRACT"><CODE>cuddCompose.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddOrAbstractRecur"></A> -DdNode * <I></I> -<B>cuddAddOrAbstractRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>cube</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addOrAbstract. - Returns the ADD obtained by abstracting the variables of cube from f, - if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddAbs.c"TARGET="ABSTRACT"><CODE>cuddAddAbs.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddOuterSumRecur"></A> -static DdNode * <I></I> -<B>cuddAddOuterSumRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>M</b>, <i></i> - DdNode * <b>r</b>, <i></i> - DdNode * <b>c</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addOuterSum. - Returns a pointer to the result if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddMatMult.c"TARGET="ABSTRACT"><CODE>cuddMatMult.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddPermuteRecur"></A> -static DdNode * <I></I> -<B>cuddAddPermuteRecur</B>( - DdManager * <b>manager</b>, <i>DD manager</i> - DdHashTable * <b>table</b>, <i>computed table</i> - DdNode * <b>node</b>, <i>ADD to be reordered</i> - int * <b>permut</b> <i>permutation array</i> -) -</pre> -<dd> Recursively puts the ADD in the order given in the - array permut. Checks for trivial cases to terminate recursion, then - splits on the children of this node. Once the solutions for the - children are obtained, it puts into the current position the node - from the rest of the ADD that should be here. Then returns this ADD. - The key here is that the node being visited is NOT put in its proper - place by this instance, but rather is switched when its proper - position is reached in the recursion tree.<p> - The DdNode * that is returned is the same ADD as passed in as node, - but in the new order. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_addPermute">Cudd_addPermute</a> -<a href="#cuddBddPermuteRecur">cuddBddPermuteRecur</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCompose.c"TARGET="ABSTRACT"><CODE>cuddCompose.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddRestrictRecur"></A> -DdNode * <I></I> -<B>cuddAddRestrictRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>c</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addRestrict. - Returns the restricted ADD if successful; otherwise NULL. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_addRestrict">Cudd_addRestrict</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddRoundOffRecur"></A> -DdNode * <I></I> -<B>cuddAddRoundOffRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - double <b>trunc</b> <i></i> -) -</pre> -<dd> Implements the recursive step of Cudd_addRoundOff. - Returns a pointer to the result. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddNeg.c"TARGET="ABSTRACT"><CODE>cuddAddNeg.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddScalarInverseRecur"></A> -DdNode * <I></I> -<B>cuddAddScalarInverseRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>epsilon</b> <i></i> -) -</pre> -<dd> Returns a pointer to the resulting ADD in case of - success. Returns NULL if any discriminants smaller than epsilon is - encountered. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddInv.c"TARGET="ABSTRACT"><CODE>cuddAddInv.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddUnivAbstractRecur"></A> -DdNode * <I></I> -<B>cuddAddUnivAbstractRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>cube</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_addUnivAbstract. - Returns the ADD obtained by abstracting the variables of cube from f, - if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAddAbs.c"TARGET="ABSTRACT"><CODE>cuddAddAbs.c</CODE></A> - -<dt><pre> -<A NAME="cuddAddVectorComposeRecur"></A> -static DdNode * <I></I> -<B>cuddAddVectorComposeRecur</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - DdHashTable * <b>table</b>, <i>computed table</i> - DdNode * <b>f</b>, <i>ADD in which to compose</i> - DdNode ** <b>vector</b>, <i>functions to substitute</i> - int <b>deepest</b> <i>depth of deepest substitution</i> -) -</pre> -<dd> Performs the recursive step of Cudd_addVectorCompose. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCompose.c"TARGET="ABSTRACT"><CODE>cuddCompose.c</CODE></A> - -<dt><pre> -<A NAME="cuddAllocNode"></A> -DdNode * <I></I> -<B>cuddAllocNode</B>( - DdManager * <b>unique</b> <i></i> -) -</pre> -<dd> Fast storage allocation for DdNodes in the table. The - first 4 bytes of a chunk contain a pointer to the next block; the - rest contains DD_MEM_CHUNK spaces for DdNodes. Returns a pointer to - a new node if successful; NULL is memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddDynamicAllocNode">cuddDynamicAllocNode</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddAnnealing"></A> -int <I></I> -<B>cuddAnnealing</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Get x, y by random selection. Choose either - exchange or jump randomly. In case of jump, choose between jump_up - and jump_down randomly. Do exchange or jump and get optimal case. - Loop until there is no improvement or temperature reaches - minimum. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAnneal.c"TARGET="ABSTRACT"><CODE>cuddAnneal.c</CODE></A> - -<dt><pre> -<A NAME="cuddApaCountMintermAux"></A> -static DdApaNumber <I></I> -<B>cuddApaCountMintermAux</B>( - DdNode * <b>node</b>, <i></i> - int <b>digits</b>, <i></i> - DdApaNumber <b>max</b>, <i></i> - DdApaNumber <b>min</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_ApaCountMinterm. - It is based on the following identity. Let |f| be the - number of minterms of f. Then: - <xmp> - |f| = (|f0|+|f1|)/2 - </xmp> - where f0 and f1 are the two cofactors of f. - Uses the identity <code>|f'| = max - |f|</code>. - The procedure expects the argument "node" to be a regular pointer, and - guarantees this condition is met in the recursive calls. - For efficiency, the result of a call is cached only if the node has - a reference count greater than 1. - Returns the number of minterms of the function rooted at node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApa.c"TARGET="ABSTRACT"><CODE>cuddApa.c</CODE></A> - -<dt><pre> -<A NAME="cuddApaStCountfree"></A> -static enum st_retval <I></I> -<B>cuddApaStCountfree</B>( - char * <b>key</b>, <i></i> - char * <b>value</b>, <i></i> - char * <b>arg</b> <i></i> -) -</pre> -<dd> Frees the memory used to store the minterm counts - recorded in the visited table. Returns ST_CONTINUE. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApa.c"TARGET="ABSTRACT"><CODE>cuddApa.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddAlignToZdd"></A> -int <I></I> -<B>cuddBddAlignToZdd</B>( - DdManager * <b>table</b> <i>DD manager</i> -) -</pre> -<dd> Reorders BDD variables according to the order of the - ZDD variables. This function can be called at the end of ZDD - reordering to insure that the order of the BDD variables is - consistent with the order of the ZDD variables. The number of ZDD - variables must be a multiple of the number of BDD variables. Let - <code>M</code> be the ratio of the two numbers. cuddBddAlignToZdd - then considers the ZDD variables from <code>M*i</code> to - <code>(M+1)*i-1</code> as corresponding to BDD variable - <code>i</code>. This function should be normally called from - Cudd_zddReduceHeap, which clears the cache. Returns 1 in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Changes the BDD variable order for all diagrams and performs - garbage collection of the BDD unique table. -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_ShuffleHeap">Cudd_ShuffleHeap</a> -<a href="#Cudd_zddReduceHeap">Cudd_zddReduceHeap</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddAndAbstractRecur"></A> -DdNode * <I></I> -<B>cuddBddAndAbstractRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>cube</b> <i></i> -) -</pre> -<dd> Takes the AND of two BDDs and simultaneously abstracts - the variables in cube. The variables are existentially abstracted. - Returns a pointer to the result is successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddAndAbstract">Cudd_bddAndAbstract</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAndAbs.c"TARGET="ABSTRACT"><CODE>cuddAndAbs.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddAndRecur"></A> -DdNode * <I></I> -<B>cuddBddAndRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Implements the recursive step of Cudd_bddAnd by taking - the conjunction of two BDDs. Returns a pointer to the result is - successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddAnd">Cudd_bddAnd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddIte.c"TARGET="ABSTRACT"><CODE>cuddBddIte.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddBooleanDiffRecur"></A> -DdNode * <I></I> -<B>cuddBddBooleanDiffRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>var</b> <i></i> -) -</pre> -<dd> Performs the recursive steps of Cudd_bddBoleanDiff. - Returns the BDD obtained by XORing the cofactors of f with respect to - var if successful; NULL otherwise. Exploits the fact that dF/dx = - dF'/dx. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddAbs.c"TARGET="ABSTRACT"><CODE>cuddBddAbs.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddCharToVect"></A> -static DdNode * <I></I> -<B>cuddBddCharToVect</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>x</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddCharToVect. - This function maintains the invariant that f is non-zero. - Returns the i-th component of the vector if successful; otherwise NULL. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddCharToVect">Cudd_bddCharToVect</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddClipAndAbsRecur"></A> -static DdNode * <I></I> -<B>cuddBddClipAndAbsRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>cube</b>, <i></i> - int <b>distance</b>, <i></i> - int <b>direction</b> <i></i> -) -</pre> -<dd> Approximates the AND of two BDDs and simultaneously - abstracts the variables in cube. The variables are existentially - abstracted. Returns a pointer to the result is successful; NULL - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddClippingAndAbstract">Cudd_bddClippingAndAbstract</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddClip.c"TARGET="ABSTRACT"><CODE>cuddClip.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddClippingAndAbstract"></A> -DdNode * <I></I> -<B>cuddBddClippingAndAbstract</B>( - DdManager * <b>dd</b>, <i>manager</i> - DdNode * <b>f</b>, <i>first conjunct</i> - DdNode * <b>g</b>, <i>second conjunct</i> - DdNode * <b>cube</b>, <i>cube of variables to be abstracted</i> - int <b>maxDepth</b>, <i>maximum recursion depth</i> - int <b>direction</b> <i>under (0) or over (1) approximation</i> -) -</pre> -<dd> Approximates the conjunction of two BDDs f and g and - simultaneously abstracts the variables in cube. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddClippingAndAbstract">Cudd_bddClippingAndAbstract</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddClip.c"TARGET="ABSTRACT"><CODE>cuddClip.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddClippingAndRecur"></A> -static DdNode * <I></I> -<B>cuddBddClippingAndRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - int <b>distance</b>, <i></i> - int <b>direction</b> <i></i> -) -</pre> -<dd> Implements the recursive step of Cudd_bddClippingAnd by taking - the conjunction of two BDDs. Returns a pointer to the result is - successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddBddClippingAnd">cuddBddClippingAnd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddClip.c"TARGET="ABSTRACT"><CODE>cuddClip.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddClippingAnd"></A> -DdNode * <I></I> -<B>cuddBddClippingAnd</B>( - DdManager * <b>dd</b>, <i>manager</i> - DdNode * <b>f</b>, <i>first conjunct</i> - DdNode * <b>g</b>, <i>second conjunct</i> - int <b>maxDepth</b>, <i>maximum recursion depth</i> - int <b>direction</b> <i>under (0) or over (1) approximation</i> -) -</pre> -<dd> Approximates the conjunction of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddClippingAnd">Cudd_bddClippingAnd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddClip.c"TARGET="ABSTRACT"><CODE>cuddClip.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddClosestCube"></A> -DdNode * <I></I> -<B>cuddBddClosestCube</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - CUDD_VALUE_TYPE <b>bound</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddClosestCube. - Returns the cube if succesful; NULL otherwise. The procedure uses a - four-way recursion to examine all four combinations of cofactors of - <code>f</code> and <code>g</code> according to the following formula. - <pre> - H(f,g) = min(H(ft,gt), H(fe,ge), H(ft,ge)+1, H(fe,gt)+1) - </pre> - Bounding is based on the following observations. - <ul> - <li> If we already found two points at distance 0, there is no point in - continuing. Furthermore, - <li> If F == not(G) then the best we can hope for is a minimum distance - of 1. If we have already found two points at distance 1, there is - no point in continuing. (Indeed, H(F,G) == 1 in this case. We - have to continue, though, to find the cube.) - </ul> - The variable <code>bound</code> is set at the largest value of the distance - that we are still interested in. Therefore, we desist when - <pre> - (bound == -1) and (F != not(G)) or (bound == 0) and (F == not(G)). - </pre> - If we were maximally aggressive in using the bound, we would always - set the bound to the minimum distance seen thus far minus one. That - is, we would maintain the invariant - <pre> - bound < minD, - </pre> - except at the very beginning, when we have no value for - <code>minD</code>.<p> - - However, we do not use <code>bound < minD</code> when examining the - two negative cofactors, because we try to find a large cube at - minimum distance. To do so, we try to find a cube in the negative - cofactors at the same or smaller distance from the cube found in the - positive cofactors.<p> - - When we compute <code>H(ft,ge)</code> and <code>H(fe,gt)</code> we - know that we are going to add 1 to the result of the recursive call - to account for the difference in the splitting variable. Therefore, - we decrease the bound correspondingly.<p> - - Another important observation concerns the need of examining all - four pairs of cofators only when both <code>f</code> and - <code>g</code> depend on the top variable.<p> - - Suppose <code>gt == ge == g</code>. (That is, <code>g</code> does - not depend on the top variable.) Then - <pre> - H(f,g) = min(H(ft,g), H(fe,g), H(ft,g)+1, H(fe,g)+1) - = min(H(ft,g), H(fe,g)) . - </pre> - Therefore, under these circumstances, we skip the two "cross" cases.<p> - - An interesting feature of this function is the scheme used for - caching the results in the global computed table. Since we have a - cube and a distance, we combine them to form an ADD. The - combination replaces the zero child of the top node of the cube with - the negative of the distance. (The use of the negative is to avoid - ambiguity with 1.) The degenerate cases (zero and one) are treated - specially because the distance is known (0 for one, and infinity for - zero). -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddClosestCube">Cudd_bddClosestCube</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddPriority.c"TARGET="ABSTRACT"><CODE>cuddPriority.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddComposeRecur"></A> -DdNode * <I></I> -<B>cuddBddComposeRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>proj</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddCompose. - Exploits the fact that the composition of f' with g - produces the complement of the composition of f with g to better - utilize the cache. Returns the composed BDD if successful; NULL - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddCompose">Cudd_bddCompose</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCompose.c"TARGET="ABSTRACT"><CODE>cuddCompose.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddConstrainDecomp"></A> -static int <I></I> -<B>cuddBddConstrainDecomp</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode ** <b>decomp</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddConstrainDecomp. - Returns f super (i) if successful; otherwise NULL. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddConstrainDecomp">Cudd_bddConstrainDecomp</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddConstrainRecur"></A> -DdNode * <I></I> -<B>cuddBddConstrainRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>c</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddConstrain. - Returns a pointer to the result if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddConstrain">Cudd_bddConstrain</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddExistAbstractRecur"></A> -DdNode * <I></I> -<B>cuddBddExistAbstractRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>cube</b> <i></i> -) -</pre> -<dd> Performs the recursive steps of Cudd_bddExistAbstract. - Returns the BDD obtained by abstracting the variables - of cube from f if successful; NULL otherwise. It is also used by - Cudd_bddUnivAbstract. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddExistAbstract">Cudd_bddExistAbstract</a> -<a href="#Cudd_bddUnivAbstract">Cudd_bddUnivAbstract</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddAbs.c"TARGET="ABSTRACT"><CODE>cuddBddAbs.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddIntersectRecur"></A> -DdNode * <I></I> -<B>cuddBddIntersectRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Implements the recursive step of Cudd_bddIntersect. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddIntersect">Cudd_bddIntersect</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddIte.c"TARGET="ABSTRACT"><CODE>cuddBddIte.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddIsop"></A> -DdNode * <I></I> -<B>cuddBddIsop</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>L</b>, <i></i> - DdNode * <b>U</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddIsop. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddIsop">Cudd_bddIsop</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddIsop.c"TARGET="ABSTRACT"><CODE>cuddZddIsop.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddIteRecur"></A> -DdNode * <I></I> -<B>cuddBddIteRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b> <i></i> -) -</pre> -<dd> Implements the recursive step of Cudd_bddIte. Returns a - pointer to the resulting BDD. NULL if the intermediate result blows - up or if reordering occurs. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddIte.c"TARGET="ABSTRACT"><CODE>cuddBddIte.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddLICBuildResult"></A> -static DdNode * <I></I> -<B>cuddBddLICBuildResult</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - st_table * <b>cache</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Builds the results of Cudd_bddLICompaction. - Returns a pointer to the minimized BDD if successful; otherwise NULL. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddLICompaction">Cudd_bddLICompaction</a> -<a href="#cuddBddLICMarkEdges">cuddBddLICMarkEdges</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddLICMarkEdges"></A> -static int <I></I> -<B>cuddBddLICMarkEdges</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>c</b>, <i></i> - st_table * <b>table</b>, <i></i> - st_table * <b>cache</b> <i></i> -) -</pre> -<dd> Performs the edge marking step of Cudd_bddLICompaction. - Returns the LUB of the markings of the two outgoing edges of <code>f</code> - if successful; otherwise CUDD_OUT_OF_MEM. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddLICompaction">Cudd_bddLICompaction</a> -<a href="#cuddBddLICBuildResult">cuddBddLICBuildResult</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddLICompaction"></A> -DdNode * <I></I> -<B>cuddBddLICompaction</B>( - DdManager * <b>dd</b>, <i>manager</i> - DdNode * <b>f</b>, <i>function to be minimized</i> - DdNode * <b>c</b> <i>constraint (care set)</i> -) -</pre> -<dd> Performs safe minimization of a BDD. Given the BDD - <code>f</code> of a function to be minimized and a BDD - <code>c</code> representing the care set, Cudd_bddLICompaction - produces the BDD of a function that agrees with <code>f</code> - wherever <code>c</code> is 1. Safe minimization means that the size - of the result is guaranteed not to exceed the size of - <code>f</code>. This function is based on the DAC97 paper by Hong et - al.. Returns a pointer to the result if successful; NULL - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddLICompaction">Cudd_bddLICompaction</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddLiteralSetIntersectionRecur"></A> -DdNode * <I></I> -<B>cuddBddLiteralSetIntersectionRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Performs the recursive step of - Cudd_bddLiteralSetIntersection. Scans the cubes for common variables, - and checks whether they agree in phase. Returns a pointer to the - resulting cube if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLiteral.c"TARGET="ABSTRACT"><CODE>cuddLiteral.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddMakePrime"></A> -DdNode * <I></I> -<B>cuddBddMakePrime</B>( - DdManager * <b>dd</b>, <i>manager</i> - DdNode * <b>cube</b>, <i>cube to be expanded</i> - DdNode * <b>f</b> <i>function of which the cube is to be made a prime</i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddMakePrime. - Returns the prime if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSat.c"TARGET="ABSTRACT"><CODE>cuddSat.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddNPAndRecur"></A> -DdNode * <I></I> -<B>cuddBddNPAndRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Implements the recursive step of Cudd_bddNPAnd. - Returns a pointer to the result is successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddNPAnd">Cudd_bddNPAnd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddPermuteRecur"></A> -static DdNode * <I></I> -<B>cuddBddPermuteRecur</B>( - DdManager * <b>manager</b>, <i>DD manager</i> - DdHashTable * <b>table</b>, <i>computed table</i> - DdNode * <b>node</b>, <i>BDD to be reordered</i> - int * <b>permut</b> <i>permutation array</i> -) -</pre> -<dd> Recursively puts the BDD in the order given in the array permut. - Checks for trivial cases to terminate recursion, then splits on the - children of this node. Once the solutions for the children are - obtained, it puts into the current position the node from the rest of - the BDD that should be here. Then returns this BDD. - The key here is that the node being visited is NOT put in its proper - place by this instance, but rather is switched when its proper position - is reached in the recursion tree.<p> - The DdNode * that is returned is the same BDD as passed in as node, - but in the new order. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddPermute">Cudd_bddPermute</a> -<a href="#cuddAddPermuteRecur">cuddAddPermuteRecur</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCompose.c"TARGET="ABSTRACT"><CODE>cuddCompose.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddRestrictRecur"></A> -DdNode * <I></I> -<B>cuddBddRestrictRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>c</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddRestrict. - Returns the restricted BDD if successful; otherwise NULL. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddRestrict">Cudd_bddRestrict</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddSqueeze"></A> -static DdNode * <I></I> -<B>cuddBddSqueeze</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>l</b>, <i></i> - DdNode * <b>u</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddSqueeze. This - procedure exploits the fact that if we complement and swap the - bounds of the interval we obtain a valid solution by taking the - complement of the solution to the original problem. Therefore, we - can enforce the condition that the upper bound is always regular. - Returns a pointer to the result if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddSqueeze">Cudd_bddSqueeze</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenCof.c"TARGET="ABSTRACT"><CODE>cuddGenCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddTransferRecur"></A> -static DdNode * <I></I> -<B>cuddBddTransferRecur</B>( - DdManager * <b>ddS</b>, <i></i> - DdManager * <b>ddD</b>, <i></i> - DdNode * <b>f</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddTransfer. - Returns a pointer to the result if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddBddTransfer">cuddBddTransfer</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBridge.c"TARGET="ABSTRACT"><CODE>cuddBridge.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddTransfer"></A> -DdNode * <I></I> -<B>cuddBddTransfer</B>( - DdManager * <b>ddS</b>, <i></i> - DdManager * <b>ddD</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Convert a BDD from a manager to another one. Returns a - pointer to the BDD in the destination manager if successful; NULL - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddTransfer">Cudd_bddTransfer</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBridge.c"TARGET="ABSTRACT"><CODE>cuddBridge.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddVarMapRecur"></A> -static DdNode * <I></I> -<B>cuddBddVarMapRecur</B>( - DdManager * <b>manager</b>, <i>DD manager</i> - DdNode * <b>f</b> <i>BDD to be remapped</i> -) -</pre> -<dd> Implements the recursive step of Cudd_bddVarMap. - Returns a pointer to the result if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddVarMap">Cudd_bddVarMap</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCompose.c"TARGET="ABSTRACT"><CODE>cuddCompose.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddVectorComposeRecur"></A> -static DdNode * <I></I> -<B>cuddBddVectorComposeRecur</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - DdHashTable * <b>table</b>, <i>computed table</i> - DdNode * <b>f</b>, <i>BDD in which to compose</i> - DdNode ** <b>vector</b>, <i>functions to be composed</i> - int <b>deepest</b> <i>depth of the deepest substitution</i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddVectorCompose. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCompose.c"TARGET="ABSTRACT"><CODE>cuddCompose.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddXorExistAbstractRecur"></A> -DdNode * <I></I> -<B>cuddBddXorExistAbstractRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>cube</b> <i></i> -) -</pre> -<dd> Takes the exclusive OR of two BDDs and simultaneously abstracts - the variables in cube. The variables are existentially abstracted. Returns a - pointer to the result is successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddAndAbstract">Cudd_bddAndAbstract</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddAbs.c"TARGET="ABSTRACT"><CODE>cuddBddAbs.c</CODE></A> - -<dt><pre> -<A NAME="cuddBddXorRecur"></A> -DdNode * <I></I> -<B>cuddBddXorRecur</B>( - DdManager * <b>manager</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Implements the recursive step of Cudd_bddXor by taking - the exclusive OR of two BDDs. Returns a pointer to the result is - successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddXor">Cudd_bddXor</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBddIte.c"TARGET="ABSTRACT"><CODE>cuddBddIte.c</CODE></A> - -<dt><pre> -<A NAME="cuddBiasedUnderApprox"></A> -DdNode * <I></I> -<B>cuddBiasedUnderApprox</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - DdNode * <b>f</b>, <i>current DD</i> - DdNode * <b>b</b>, <i>bias function</i> - int <b>numVars</b>, <i>maximum number of variables</i> - int <b>threshold</b>, <i>threshold under which approximation stops</i> - double <b>quality1</b>, <i>minimum improvement for accepted changes when b=1</i> - double <b>quality0</b> <i>minimum improvement for accepted changes when b=0</i> -) -</pre> -<dd> Applies the biased remapping underappoximation algorithm. - Proceeds in three phases: - <ul> - <li> collect information on each node in the BDD; this is done via DFS. - <li> traverse the BDD in top-down fashion and compute for each node - whether remapping increases density. - <li> traverse the BDD via DFS and actually perform the elimination. - </ul> - Returns the approximated BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_BiasedUnderApprox">Cudd_BiasedUnderApprox</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="cuddCProjectionRecur"></A> -DdNode * <I></I> -<B>cuddCProjectionRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>R</b>, <i></i> - DdNode * <b>Y</b>, <i></i> - DdNode * <b>Ysupp</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_CProjection. Returns - the projection if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_CProjection">Cudd_CProjection</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddPriority.c"TARGET="ABSTRACT"><CODE>cuddPriority.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheFlush"></A> -void <I></I> -<B>cuddCacheFlush</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Flushes the cache. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheInsert1"></A> -void <I></I> -<B>cuddCacheInsert1</B>( - DdManager * <b>table</b>, <i></i> - DD_CTFP1 <b>op</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>data</b> <i></i> -) -</pre> -<dd> Inserts a result in the cache for a function with two - operands. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddCacheInsert">cuddCacheInsert</a> -<a href="#cuddCacheInsert2">cuddCacheInsert2</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheInsert2"></A> -void <I></I> -<B>cuddCacheInsert2</B>( - DdManager * <b>table</b>, <i></i> - DD_CTFP <b>op</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>data</b> <i></i> -) -</pre> -<dd> Inserts a result in the cache for a function with two - operands. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddCacheInsert">cuddCacheInsert</a> -<a href="#cuddCacheInsert1">cuddCacheInsert1</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheInsert"></A> -void <I></I> -<B>cuddCacheInsert</B>( - DdManager * <b>table</b>, <i></i> - ptruint <b>op</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b>, <i></i> - DdNode * <b>data</b> <i></i> -) -</pre> -<dd> Inserts a result in the cache for a function with three - operands. The operator tag (see cuddInt.h for details) is split and stored - into unused bits of the first two pointers. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddCacheInsert2">cuddCacheInsert2</a> -<a href="#cuddCacheInsert1">cuddCacheInsert1</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheLookup1Zdd"></A> -DdNode * <I></I> -<B>cuddCacheLookup1Zdd</B>( - DdManager * <b>table</b>, <i></i> - DD_CTFP1 <b>op</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Returns the result if found; it returns NULL if no - result is found. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddCacheLookupZdd">cuddCacheLookupZdd</a> -<a href="#cuddCacheLookup2Zdd">cuddCacheLookup2Zdd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheLookup1"></A> -DdNode * <I></I> -<B>cuddCacheLookup1</B>( - DdManager * <b>table</b>, <i></i> - DD_CTFP1 <b>op</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Returns the result if found; it returns NULL if no - result is found. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddCacheLookup">cuddCacheLookup</a> -<a href="#cuddCacheLookup2">cuddCacheLookup2</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheLookup2Zdd"></A> -DdNode * <I></I> -<B>cuddCacheLookup2Zdd</B>( - DdManager * <b>table</b>, <i></i> - DD_CTFP <b>op</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Returns the result if found; it returns NULL if no - result is found. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddCacheLookupZdd">cuddCacheLookupZdd</a> -<a href="#cuddCacheLookup1Zdd">cuddCacheLookup1Zdd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheLookup2"></A> -DdNode * <I></I> -<B>cuddCacheLookup2</B>( - DdManager * <b>table</b>, <i></i> - DD_CTFP <b>op</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Returns the result if found; it returns NULL if no - result is found. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddCacheLookup">cuddCacheLookup</a> -<a href="#cuddCacheLookup1">cuddCacheLookup1</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheLookupZdd"></A> -DdNode * <I></I> -<B>cuddCacheLookupZdd</B>( - DdManager * <b>table</b>, <i></i> - ptruint <b>op</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b> <i></i> -) -</pre> -<dd> Returns the result if found; it returns NULL if no - result is found. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddCacheLookup2Zdd">cuddCacheLookup2Zdd</a> -<a href="#cuddCacheLookup1Zdd">cuddCacheLookup1Zdd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheLookup"></A> -DdNode * <I></I> -<B>cuddCacheLookup</B>( - DdManager * <b>table</b>, <i></i> - ptruint <b>op</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b> <i></i> -) -</pre> -<dd> Returns the result if found; it returns NULL if no - result is found. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddCacheLookup2">cuddCacheLookup2</a> -<a href="#cuddCacheLookup1">cuddCacheLookup1</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheProfile"></A> -int <I></I> -<B>cuddCacheProfile</B>( - DdManager * <b>table</b>, <i></i> - FILE * <b>fp</b> <i></i> -) -</pre> -<dd> Computes and prints a profile of the cache usage. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCacheResize"></A> -void <I></I> -<B>cuddCacheResize</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Resizes the cache. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddCheckCollisionOrdering"></A> -static int <I></I> -<B>cuddCheckCollisionOrdering</B>( - DdManager * <b>unique</b>, <i></i> - int <b>i</b>, <i></i> - int <b>j</b> <i></i> -) -</pre> -<dd> Checks whether a collision list is ordered. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddClearDeathRow"></A> -void <I></I> -<B>cuddClearDeathRow</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Clears the death row. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_DelayedDerefBdd">Cudd_DelayedDerefBdd</a> -<a href="#Cudd_IterDerefBdd">Cudd_IterDerefBdd</a> -<a href="#Cudd_CheckZeroRef">Cudd_CheckZeroRef</a> -<a href="#cuddGarbageCollect">cuddGarbageCollect</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddRef.c"TARGET="ABSTRACT"><CODE>cuddRef.c</CODE></A> - -<dt><pre> -<A NAME="cuddCofactorRecur"></A> -DdNode * <I></I> -<B>cuddCofactorRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_Cofactor. Returns a - pointer to the cofactor if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_Cofactor">Cudd_Cofactor</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCof.c"TARGET="ABSTRACT"><CODE>cuddCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddCollectNodes"></A> -int <I></I> -<B>cuddCollectNodes</B>( - DdNode * <b>f</b>, <i></i> - st_table * <b>visited</b> <i></i> -) -</pre> -<dd> Traverses the DD f and collects all its nodes in a - symbol table. f is assumed to be a regular pointer and - cuddCollectNodes guarantees this assumption in the recursive calls. - Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="cuddComputeFloorLog2"></A> -int <I></I> -<B>cuddComputeFloorLog2</B>( - unsigned int <b>value</b> <i></i> -) -</pre> -<dd> Returns the floor of the logarithm to the base 2. - The input value is assumed to be greater than 0. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddConjunctsAux"></A> -static int <I></I> -<B>cuddConjunctsAux</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode ** <b>c1</b>, <i></i> - DdNode ** <b>c2</b> <i></i> -) -</pre> -<dd> Procedure to compute two conjunctive factors of f and - place in *c1 and *c2. Sets up the required data - table of distances - from the constant and local reference count. Also minterm table. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddDecomp.c"TARGET="ABSTRACT"><CODE>cuddDecomp.c</CODE></A> - -<dt><pre> -<A NAME="cuddConstantLookup"></A> -DdNode * <I></I> -<B>cuddConstantLookup</B>( - DdManager * <b>table</b>, <i></i> - ptruint <b>op</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b> <i></i> -) -</pre> -<dd> Looks up in the cache for the result of op applied to f, - g, and h. Assumes that the calling procedure (e.g., - Cudd_bddIteConstant) is only interested in whether the result is - constant or not. Returns the result if found (possibly - DD_NON_CONSTANT); otherwise it returns NULL. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddCacheLookup">cuddCacheLookup</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddDestroySubtables"></A> -int <I></I> -<B>cuddDestroySubtables</B>( - DdManager * <b>unique</b>, <i></i> - int <b>n</b> <i></i> -) -</pre> -<dd> Destroys the n most recently created subtables in a unique - table. n should be positive. The subtables should not contain any live - nodes, except the (isolated) projection function. The projection - functions are freed. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> The variable map used for fast variable substitution is - destroyed if it exists. In this case the cache is also cleared. -<p> - -<dd> <b>See Also</b> <code><a href="#cuddInsertSubtables">cuddInsertSubtables</a> -<a href="#Cudd_SetVarMap">Cudd_SetVarMap</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddDoRebalance"></A> -static void <I></I> -<B>cuddDoRebalance</B>( - DdNodePtr ** <b>stack</b>, <i></i> - int <b>stackN</b> <i></i> -) -</pre> -<dd> Rebalances a red/black tree. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddDynamicAllocNode"></A> -DdNode * <I></I> -<B>cuddDynamicAllocNode</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Dynamically allocates a Node. This procedure is similar - to cuddAllocNode in Cudd_Table.c, but it does not attempt garbage - collection, because during reordering there are no dead nodes. - Returns a pointer to a new node if successful; NULL is memory is - full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddAllocNode">cuddAllocNode</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="cuddEstimateCofactorSimple"></A> -static int <I></I> -<B>cuddEstimateCofactorSimple</B>( - DdNode * <b>node</b>, <i></i> - int <b>i</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_CofactorEstimateSimple. - Returns an estimate of the number of nodes in the DD of the positive - cofactor of node. Uses the least significant bit of the next field as - visited flag. node is supposed to be regular; the invariant is maintained - by this procedure. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="cuddEstimateCofactor"></A> -static int <I></I> -<B>cuddEstimateCofactor</B>( - DdManager * <b>dd</b>, <i></i> - st_table * <b>table</b>, <i></i> - DdNode * <b>node</b>, <i></i> - int <b>i</b>, <i></i> - int <b>phase</b>, <i></i> - DdNode ** <b>ptr</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_CofactorEstimate. - Returns an estimate of the number of nodes in the DD of a - cofactor of node. Uses the least significant bit of the next field as - visited flag. node is supposed to be regular; the invariant is maintained - by this procedure. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="cuddExact"></A> -int <I></I> -<B>cuddExact</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Exact variable ordering algorithm. Finds an optimum - order for the variables between lower and upper. Returns 1 if - successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="cuddFindParent"></A> -static int <I></I> -<B>cuddFindParent</B>( - DdManager * <b>table</b>, <i></i> - DdNode * <b>node</b> <i></i> -) -</pre> -<dd> Searches the subtables above node for a parent. Returns 1 - as soon as one parent is found. Returns 0 is the search is fruitless. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddFreeTable"></A> -void <I></I> -<B>cuddFreeTable</B>( - DdManager * <b>unique</b> <i></i> -) -</pre> -<dd> Frees the resources associated to a unique table. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddInitTable">cuddInitTable</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddGarbageCollect"></A> -int <I></I> -<B>cuddGarbageCollect</B>( - DdManager * <b>unique</b>, <i></i> - int <b>clearCache</b> <i></i> -) -</pre> -<dd> Performs garbage collection on the BDD and ZDD unique tables. - If clearCache is 0, the cache is not cleared. This should only be - specified if the cache has been cleared right before calling - cuddGarbageCollect. (As in the case of dynamic reordering.) - Returns the total number of deleted nodes. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddGa"></A> -int <I></I> -<B>cuddGa</B>( - DdManager * <b>table</b>, <i>manager</i> - int <b>lower</b>, <i>lowest level to be reordered</i> - int <b>upper</b> <i>highest level to be reorderded</i> -) -</pre> -<dd> Genetic algorithm for DD reordering. - The two children of a crossover will be stored in - storedd[popsize -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME="cuddGetBranches"></A> -void <I></I> -<B>cuddGetBranches</B>( - DdNode * <b>g</b>, <i></i> - DdNode ** <b>g1</b>, <i></i> - DdNode ** <b>g0</b> <i></i> -) -</pre> -<dd> Computes the children of g. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCof.c"TARGET="ABSTRACT"><CODE>cuddCof.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableGenericInsert"></A> -int <I></I> -<B>cuddHashTableGenericInsert</B>( - DdHashTable * <b>hash</b>, <i></i> - DdNode * <b>f</b>, <i></i> - void * <b>value</b> <i></i> -) -</pre> -<dd> Inserts an item in a hash table when the key is one - pointer and the value is not a DdNode pointer. Returns 1 if - successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableInsert1">cuddHashTableInsert1</a> -<a href="#cuddHashTableGenericLookup">cuddHashTableGenericLookup</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableGenericLookup"></A> -void * <I></I> -<B>cuddHashTableGenericLookup</B>( - DdHashTable * <b>hash</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Looks up a key consisting of one pointer in a hash - table when the value is not a DdNode pointer. Returns the value - associated to the key if there is an entry for the given key in the - table; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableLookup1">cuddHashTableLookup1</a> -<a href="#cuddHashTableGenericInsert">cuddHashTableGenericInsert</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableGenericQuit"></A> -void <I></I> -<B>cuddHashTableGenericQuit</B>( - DdHashTable * <b>hash</b> <i></i> -) -</pre> -<dd> Shuts down a hash table, when the values are not DdNode - pointers. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableInit">cuddHashTableInit</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableInit"></A> -DdHashTable * <I></I> -<B>cuddHashTableInit</B>( - DdManager * <b>manager</b>, <i></i> - unsigned int <b>keySize</b>, <i></i> - unsigned int <b>initSize</b> <i></i> -) -</pre> -<dd> Initializes a hash table. Returns a pointer to the new - table if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableQuit">cuddHashTableQuit</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableInsert1"></A> -int <I></I> -<B>cuddHashTableInsert1</B>( - DdHashTable * <b>hash</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>value</b>, <i></i> - ptrint <b>count</b> <i></i> -) -</pre> -<dd> Inserts an item in a hash table when the key is one pointer. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableInsert">cuddHashTableInsert</a> -<a href="#cuddHashTableInsert2">cuddHashTableInsert2</a> -<a href="#cuddHashTableInsert3">cuddHashTableInsert3</a> -<a href="#cuddHashTableLookup1">cuddHashTableLookup1</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableInsert2"></A> -int <I></I> -<B>cuddHashTableInsert2</B>( - DdHashTable * <b>hash</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>value</b>, <i></i> - ptrint <b>count</b> <i></i> -) -</pre> -<dd> Inserts an item in a hash table when the key is - composed of two pointers. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableInsert">cuddHashTableInsert</a> -<a href="#cuddHashTableInsert1">cuddHashTableInsert1</a> -<a href="#cuddHashTableInsert3">cuddHashTableInsert3</a> -<a href="#cuddHashTableLookup2">cuddHashTableLookup2</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableInsert3"></A> -int <I></I> -<B>cuddHashTableInsert3</B>( - DdHashTable * <b>hash</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b>, <i></i> - DdNode * <b>value</b>, <i></i> - ptrint <b>count</b> <i></i> -) -</pre> -<dd> Inserts an item in a hash table when the key is - composed of three pointers. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableInsert">cuddHashTableInsert</a> -<a href="#cuddHashTableInsert1">cuddHashTableInsert1</a> -<a href="#cuddHashTableInsert2">cuddHashTableInsert2</a> -<a href="#cuddHashTableLookup3">cuddHashTableLookup3</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableInsert"></A> -int <I></I> -<B>cuddHashTableInsert</B>( - DdHashTable * <b>hash</b>, <i></i> - DdNodePtr * <b>key</b>, <i></i> - DdNode * <b>value</b>, <i></i> - ptrint <b>count</b> <i></i> -) -</pre> -<dd> Inserts an item in a hash table when the key has more than - three pointers. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code>[cuddHashTableInsert1 -<a href="#cuddHashTableInsert2">cuddHashTableInsert2</a> -<a href="#cuddHashTableInsert3">cuddHashTableInsert3</a> -<a href="#cuddHashTableLookup">cuddHashTableLookup</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableLookup1"></A> -DdNode * <I></I> -<B>cuddHashTableLookup1</B>( - DdHashTable * <b>hash</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Looks up a key consisting of one pointer in a hash table. - Returns the value associated to the key if there is an entry for the given - key in the table; NULL otherwise. If the entry is present, its reference - counter is decremented if not saturated. If the counter reaches 0, the - value of the entry is dereferenced, and the entry is returned to the free - list. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableLookup">cuddHashTableLookup</a> -<a href="#cuddHashTableLookup2">cuddHashTableLookup2</a> -<a href="#cuddHashTableLookup3">cuddHashTableLookup3</a> -<a href="#cuddHashTableInsert1">cuddHashTableInsert1</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableLookup2"></A> -DdNode * <I></I> -<B>cuddHashTableLookup2</B>( - DdHashTable * <b>hash</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Looks up a key consisting of two pointer in a hash table. - Returns the value associated to the key if there is an entry for the given - key in the table; NULL otherwise. If the entry is present, its reference - counter is decremented if not saturated. If the counter reaches 0, the - value of the entry is dereferenced, and the entry is returned to the free - list. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableLookup">cuddHashTableLookup</a> -<a href="#cuddHashTableLookup1">cuddHashTableLookup1</a> -<a href="#cuddHashTableLookup3">cuddHashTableLookup3</a> -<a href="#cuddHashTableInsert2">cuddHashTableInsert2</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableLookup3"></A> -DdNode * <I></I> -<B>cuddHashTableLookup3</B>( - DdHashTable * <b>hash</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b> <i></i> -) -</pre> -<dd> Looks up a key consisting of three pointers in a hash table. - Returns the value associated to the key if there is an entry for the given - key in the table; NULL otherwise. If the entry is present, its reference - counter is decremented if not saturated. If the counter reaches 0, the - value of the entry is dereferenced, and the entry is returned to the free - list. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableLookup">cuddHashTableLookup</a> -<a href="#cuddHashTableLookup1">cuddHashTableLookup1</a> -<a href="#cuddHashTableLookup2">cuddHashTableLookup2</a> -<a href="#cuddHashTableInsert3">cuddHashTableInsert3</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableLookup"></A> -DdNode * <I></I> -<B>cuddHashTableLookup</B>( - DdHashTable * <b>hash</b>, <i></i> - DdNodePtr * <b>key</b> <i></i> -) -</pre> -<dd> Looks up a key consisting of more than three pointers - in a hash table. Returns the value associated to the key if there - is an entry for the given key in the table; NULL otherwise. If the - entry is present, its reference counter is decremented if not - saturated. If the counter reaches 0, the value of the entry is - dereferenced, and the entry is returned to the free list. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableLookup1">cuddHashTableLookup1</a> -<a href="#cuddHashTableLookup2">cuddHashTableLookup2</a> -<a href="#cuddHashTableLookup3">cuddHashTableLookup3</a> -<a href="#cuddHashTableInsert">cuddHashTableInsert</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableQuit"></A> -void <I></I> -<B>cuddHashTableQuit</B>( - DdHashTable * <b>hash</b> <i></i> -) -</pre> -<dd> Shuts down a hash table, dereferencing all the values. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableInit">cuddHashTableInit</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHashTableResize"></A> -static int <I></I> -<B>cuddHashTableResize</B>( - DdHashTable * <b>hash</b> <i></i> -) -</pre> -<dd> Resizes a hash table. Returns 1 if successful; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddHashTableInsert">cuddHashTableInsert</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddHeapProfile"></A> -int <I></I> -<B>cuddHeapProfile</B>( - DdManager * <b>dd</b> <i></i> -) -</pre> -<dd> Prints to the manager's stdout the number of live nodes for each - level of the DD heap that contains at least one live node. It also - prints a summary containing: - <ul> - <li> total number of tables; - <li> number of tables with live nodes; - <li> table with the largest number of live nodes; - <li> number of nodes in that table. - </ul> - If more than one table contains the maximum number of live nodes, - only the one of lowest index is reported. Returns 1 in case of success - and 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCheck.c"TARGET="ABSTRACT"><CODE>cuddCheck.c</CODE></A> - -<dt><pre> -<A NAME="cuddInitCache"></A> -int <I></I> -<B>cuddInitCache</B>( - DdManager * <b>unique</b>, <i>unique table</i> - unsigned int <b>cacheSize</b>, <i>initial size of the cache</i> - unsigned int <b>maxCacheSize</b> <i>cache size beyond which no resizing occurs</i> -) -</pre> -<dd> Initializes the computed table. It is called by - Cudd_Init. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_Init">Cudd_Init</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCache.c"TARGET="ABSTRACT"><CODE>cuddCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddInitInteract"></A> -int <I></I> -<B>cuddInitInteract</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Initializes the interaction matrix. The interaction - matrix is implemented as a bit vector storing the upper triangle of - the symmetric interaction matrix. The bit vector is kept in an array - of long integers. The computation is based on a series of depth-first - searches, one for each root of the DAG. Two flags are needed: The - local visited flag uses the LSB of the then pointer. The global - visited flag uses the LSB of the next pointer. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddInteract.c"TARGET="ABSTRACT"><CODE>cuddInteract.c</CODE></A> - -<dt><pre> -<A NAME="cuddInitLinear"></A> -int <I></I> -<B>cuddInitLinear</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Initializes the linear transform matrix. Returns 1 if - successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="cuddInitTable"></A> -DdManager * <I></I> -<B>cuddInitTable</B>( - unsigned int <b>numVars</b>, <i>Initial number of BDD variables (and subtables)</i> - unsigned int <b>numVarsZ</b>, <i>Initial number of ZDD variables (and subtables)</i> - unsigned int <b>numSlots</b>, <i>Initial size of the BDD subtables</i> - unsigned int <b>looseUpTo</b> <i>Limit for fast table growth</i> -) -</pre> -<dd> Creates and initializes the unique table. Returns a pointer - to the table if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_Init">Cudd_Init</a> -<a href="#cuddFreeTable">cuddFreeTable</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddInsertSubtables"></A> -int <I></I> -<B>cuddInsertSubtables</B>( - DdManager * <b>unique</b>, <i></i> - int <b>n</b>, <i></i> - int <b>level</b> <i></i> -) -</pre> -<dd> Inserts n new subtables in a unique table at level. - The number n should be positive, and level should be an existing level. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddDestroySubtables">cuddDestroySubtables</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddIsInDeathRow"></A> -int <I></I> -<B>cuddIsInDeathRow</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Checks whether a node is in the death row. Returns the - position of the first occurrence if the node is present; -1 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_DelayedDerefBdd">Cudd_DelayedDerefBdd</a> -<a href="#cuddClearDeathRow">cuddClearDeathRow</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddRef.c"TARGET="ABSTRACT"><CODE>cuddRef.c</CODE></A> - -<dt><pre> -<A NAME="cuddLevelQueueDequeue"></A> -void <I></I> -<B>cuddLevelQueueDequeue</B>( - DdLevelQueue * <b>queue</b>, <i></i> - int <b>level</b> <i></i> -) -</pre> -<dd> Remove an item from the front of a level queue. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddLevelQueueEnqueue">cuddLevelQueueEnqueue</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLevelQ.c"TARGET="ABSTRACT"><CODE>cuddLevelQ.c</CODE></A> - -<dt><pre> -<A NAME="cuddLevelQueueEnqueue"></A> -void * <I></I> -<B>cuddLevelQueueEnqueue</B>( - DdLevelQueue * <b>queue</b>, <i>level queue</i> - void * <b>key</b>, <i>key to be enqueued</i> - int <b>level</b> <i>level at which to insert</i> -) -</pre> -<dd> Inserts a new key in a level queue. A new entry is - created in the queue only if the node is not already - enqueued. Returns a pointer to the queue item if successful; NULL - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddLevelQueueInit">cuddLevelQueueInit</a> -<a href="#cuddLevelQueueDequeue">cuddLevelQueueDequeue</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLevelQ.c"TARGET="ABSTRACT"><CODE>cuddLevelQ.c</CODE></A> - -<dt><pre> -<A NAME="cuddLevelQueueFirst"></A> -void * <I></I> -<B>cuddLevelQueueFirst</B>( - DdLevelQueue * <b>queue</b>, <i>level queue</i> - void * <b>key</b>, <i>key to be enqueued</i> - int <b>level</b> <i>level at which to insert</i> -) -</pre> -<dd> Inserts the first key in a level queue. Returns a - pointer to the queue item if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddLevelQueueEnqueue">cuddLevelQueueEnqueue</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLevelQ.c"TARGET="ABSTRACT"><CODE>cuddLevelQ.c</CODE></A> - -<dt><pre> -<A NAME="cuddLevelQueueInit"></A> -DdLevelQueue * <I></I> -<B>cuddLevelQueueInit</B>( - int <b>levels</b>, <i>number of levels</i> - int <b>itemSize</b>, <i>size of the item</i> - int <b>numBuckets</b> <i>initial number of hash buckets</i> -) -</pre> -<dd> Initializes a level queue. A level queue is a queue - where inserts are based on the levels of the nodes. Within each - level the policy is FIFO. Level queues are useful in traversing a - BDD top-down. Queue items are kept in a free list when dequeued for - efficiency. Returns a pointer to the new queue if successful; NULL - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddLevelQueueQuit">cuddLevelQueueQuit</a> -<a href="#cuddLevelQueueEnqueue">cuddLevelQueueEnqueue</a> -<a href="#cuddLevelQueueDequeue">cuddLevelQueueDequeue</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLevelQ.c"TARGET="ABSTRACT"><CODE>cuddLevelQ.c</CODE></A> - -<dt><pre> -<A NAME="cuddLevelQueueQuit"></A> -void <I></I> -<B>cuddLevelQueueQuit</B>( - DdLevelQueue * <b>queue</b> <i></i> -) -</pre> -<dd> Shuts down a level queue and releases all the - associated memory. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddLevelQueueInit">cuddLevelQueueInit</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLevelQ.c"TARGET="ABSTRACT"><CODE>cuddLevelQ.c</CODE></A> - -<dt><pre> -<A NAME="cuddLinearAndSifting"></A> -int <I></I> -<B>cuddLinearAndSifting</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> BDD reduction based on combination of sifting and linear - transformations. Assumes that no dead nodes are present. - <ol> - <li> Order all the variables according to the number of entries - in each unique table. - <li> Sift the variable up and down, remembering each time the - total size of the DD heap. At each position, linear transformation - of the two adjacent variables is tried and is accepted if it reduces - the size of the DD. - <li> Select the best permutation. - <li> Repeat 3 and 4 for all variables. - </ol> - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="cuddLinearInPlace"></A> -int <I></I> -<B>cuddLinearInPlace</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Linearly combines two adjacent variables. Specifically, - replaces the top variable with the exclusive nor of the two variables. - It assumes that no dead nodes are present on entry to this - procedure. The procedure then guarantees that no dead nodes will be - present when it terminates. cuddLinearInPlace assumes that x < - y. Returns the number of keys in the table if successful; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> The two subtables corrresponding to variables x and y are - modified. The global counters of the unique table are also affected. -<p> - -<dd> <b>See Also</b> <code><a href="#cuddSwapInPlace">cuddSwapInPlace</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="cuddLocalCacheAddToList"></A> -static void <I></I> -<B>cuddLocalCacheAddToList</B>( - DdLocalCache * <b>cache</b> <i></i> -) -</pre> -<dd> Inserts a local cache in the manager list. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddLocalCacheClearAll"></A> -void <I></I> -<B>cuddLocalCacheClearAll</B>( - DdManager * <b>manager</b> <i></i> -) -</pre> -<dd> Clears the local caches of a manager. - Used before reordering. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddLocalCacheClearDead"></A> -void <I></I> -<B>cuddLocalCacheClearDead</B>( - DdManager * <b>manager</b> <i></i> -) -</pre> -<dd> Clears the dead entries of the local caches of a manager. - Used during garbage collection. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddLocalCacheInit"></A> -DdLocalCache * <I></I> -<B>cuddLocalCacheInit</B>( - DdManager * <b>manager</b>, <i>manager</i> - unsigned int <b>keySize</b>, <i>size of the key (number of operands)</i> - unsigned int <b>cacheSize</b>, <i>Initial size of the cache</i> - unsigned int <b>maxCacheSize</b> <i>Size of the cache beyond which no resizing occurs</i> -) -</pre> -<dd> Initializes a computed table. Returns a pointer the - the new local cache in case of success; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddInitCache">cuddInitCache</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddLocalCacheInsert"></A> -void <I></I> -<B>cuddLocalCacheInsert</B>( - DdLocalCache * <b>cache</b>, <i></i> - DdNodePtr * <b>key</b>, <i></i> - DdNode * <b>value</b> <i></i> -) -</pre> -<dd> Inserts a result in a local cache. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddLocalCacheLookup"></A> -DdNode * <I></I> -<B>cuddLocalCacheLookup</B>( - DdLocalCache * <b>cache</b>, <i></i> - DdNodePtr * <b>key</b> <i></i> -) -</pre> -<dd> Looks up in a local cache. Returns the result if found; - it returns NULL if no result is found. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddLocalCacheProfile"></A> -int <I></I> -<B>cuddLocalCacheProfile</B>( - DdLocalCache * <b>cache</b> <i></i> -) -</pre> -<dd> Computes and prints a profile of a local cache usage. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddLocalCacheQuit"></A> -void <I></I> -<B>cuddLocalCacheQuit</B>( - DdLocalCache * <b>cache</b> <i>cache to be shut down</i> -) -</pre> -<dd> Initializes the computed table. It is called by - Cudd_Init. Returns a pointer the the new local cache in case of - success; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddLocalCacheInit">cuddLocalCacheInit</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddLocalCacheRemoveFromList"></A> -static void <I></I> -<B>cuddLocalCacheRemoveFromList</B>( - DdLocalCache * <b>cache</b> <i></i> -) -</pre> -<dd> Removes a local cache from the manager list. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddLocalCacheResize"></A> -static void <I></I> -<B>cuddLocalCacheResize</B>( - DdLocalCache * <b>cache</b> <i></i> -) -</pre> -<dd> Resizes a local cache. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME="cuddMakeBddFromZddCover"></A> -DdNode * <I></I> -<B>cuddMakeBddFromZddCover</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>node</b> <i></i> -) -</pre> -<dd> Converts a ZDD cover to a BDD. If successful, it returns - a BDD node, otherwise it returns NULL. It is a recursive algorithm - that works as follows. First it computes 3 cofactors of a ZDD cover: - f1, f0 and fd. Second, it compute BDDs (b1, b0 and bd) of f1, f0 and fd. - Third, it computes T=b1+bd and E=b0+bd. Fourth, it computes ITE(v,T,E) where - v is the variable which has the index of the top node of the ZDD cover. - In this case, since the index of v can be larger than either the one of T - or the one of E, cuddUniqueInterIVO is called, where IVO stands for - independent from variable ordering. -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_MakeBddFromZddCover">Cudd_MakeBddFromZddCover</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddIsop.c"TARGET="ABSTRACT"><CODE>cuddZddIsop.c</CODE></A> - -<dt><pre> -<A NAME="cuddMinHammingDistRecur"></A> -static int <I></I> -<B>cuddMinHammingDistRecur</B>( - DdNode * <b>f</b>, <i></i> - int * <b>minterm</b>, <i></i> - DdHashTable * <b>table</b>, <i></i> - int <b>upperBound</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_MinHammingDist. - It is based on the following identity. Let H(f) be the - minimum Hamming distance of the minterms of f from the reference - minterm. Then: - <xmp> - H(f) = min(H(f0)+h0,H(f1)+h1) - </xmp> - where f0 and f1 are the two cofactors of f with respect to its top - variable; h0 is 1 if the minterm assigns 1 to the top variable of f; - h1 is 1 if the minterm assigns 0 to the top variable of f. - The upper bound on the distance is used to bound the depth of the - recursion. - Returns the minimum distance unless it exceeds the upper bound or - computation fails. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_MinHammingDist">Cudd_MinHammingDist</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddPriority.c"TARGET="ABSTRACT"><CODE>cuddPriority.c</CODE></A> - -<dt><pre> -<A NAME="cuddNextHigh"></A> -int <I></I> -<B>cuddNextHigh</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b> <i></i> -) -</pre> -<dd> Finds the next subtable with a larger index. Returns the - index. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddNextLow">cuddNextLow</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="cuddNextLow"></A> -int <I></I> -<B>cuddNextLow</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b> <i></i> -) -</pre> -<dd> Finds the next subtable with a smaller index. Returns the - index. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddNextHigh">cuddNextHigh</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="cuddNodeArrayRecur"></A> -static int <I></I> -<B>cuddNodeArrayRecur</B>( - DdNode * <b>f</b>, <i></i> - DdNodePtr * <b>table</b>, <i></i> - int <b>index</b> <i></i> -) -</pre> -<dd> Performs the recursive step of cuddNodeArray. Returns - an the number of nodes in the DD. Clear the least significant bit - of the next field that was used as visited flag by - cuddNodeArrayRecur when counting the nodes. node is supposed to be - regular; the invariant is maintained by this procedure. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="cuddNodeArray"></A> -DdNodePtr * <I></I> -<B>cuddNodeArray</B>( - DdNode * <b>f</b>, <i></i> - int * <b>n</b> <i></i> -) -</pre> -<dd> Traverses the DD f and collects all its nodes in an array. - The caller should free the array returned by cuddNodeArray. - Returns a pointer to the array of nodes in case of success; NULL - otherwise. The nodes are collected in reverse topological order, so - that a node is always preceded in the array by all its descendants. -<p> - -<dd> <b>Side Effects</b> The number of nodes is returned as a side effect. -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_FirstNode">Cudd_FirstNode</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="cuddOrderedInsert"></A> -static void <I></I> -<B>cuddOrderedInsert</B>( - DdNodePtr * <b>root</b>, <i></i> - DdNodePtr <b>node</b> <i></i> -) -</pre> -<dd> Inserts a DdNode in a red/black search tree. Nodes from - the same "page" (defined by DD_PAGE_MASK) are linked in a LIFO list. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddOrderedThread">cuddOrderedThread</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddOrderedThread"></A> -static DdNode * <I></I> -<B>cuddOrderedThread</B>( - DdNode * <b>root</b>, <i></i> - DdNode * <b>list</b> <i></i> -) -</pre> -<dd> Threads all the nodes of a search tree into a linear - list. For each node of the search tree, the "left" child, if non-null, has - a lower address than its parent, and the "right" child, if non-null, has a - higher address than its parent. - The list is sorted in order of increasing addresses. The search - tree is destroyed as a result of this operation. The last element of - the linear list is made to point to the address passed in list. Each - node if the search tree is a linearly-linked list of nodes from the - same memory page (as defined in DD_PAGE_MASK). When a node is added to - the linear list, all the elements of the linked list are added. -<p> - -<dd> <b>Side Effects</b> The search tree is destroyed as a result of this operation. -<p> - -<dd> <b>See Also</b> <code><a href="#cuddOrderedInsert">cuddOrderedInsert</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddPrintNode"></A> -void <I></I> -<B>cuddPrintNode</B>( - DdNode * <b>f</b>, <i></i> - FILE * <b>fp</b> <i></i> -) -</pre> -<dd> Prints out information on a node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCheck.c"TARGET="ABSTRACT"><CODE>cuddCheck.c</CODE></A> - -<dt><pre> -<A NAME="cuddPrintVarGroups"></A> -void <I></I> -<B>cuddPrintVarGroups</B>( - DdManager * <b>dd</b>, <i>manager</i> - MtrNode * <b>root</b>, <i>root of the group tree</i> - int <b>zdd</b>, <i>0: BDD; 1: ZDD</i> - int <b>silent</b> <i>flag to check tree syntax only</i> -) -</pre> -<dd> Prints the variable groups as a parenthesized list. - For each group the level range that it represents is printed. After - each group, the group's flags are printed, preceded by a `|'. For - each flag (except MTR_TERMINAL) a character is printed. - <ul> - <li>F: MTR_FIXED - <li>N: MTR_NEWNODE - <li>S: MTR_SOFT - </ul> - The second argument, silent, if different from 0, causes - Cudd_PrintVarGroups to only check the syntax of the group tree. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCheck.c"TARGET="ABSTRACT"><CODE>cuddCheck.c</CODE></A> - -<dt><pre> -<A NAME="cuddP"></A> -int <I></I> -<B>cuddP</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Prints a DD to the standard output. One line per node is - printed. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_PrintDebug">Cudd_PrintDebug</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="cuddReclaimZdd"></A> -void <I></I> -<B>cuddReclaimZdd</B>( - DdManager * <b>table</b>, <i></i> - DdNode * <b>n</b> <i></i> -) -</pre> -<dd> Brings children of a dead ZDD node back. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddReclaim">cuddReclaim</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddRef.c"TARGET="ABSTRACT"><CODE>cuddRef.c</CODE></A> - -<dt><pre> -<A NAME="cuddReclaim"></A> -void <I></I> -<B>cuddReclaim</B>( - DdManager * <b>table</b>, <i></i> - DdNode * <b>n</b> <i></i> -) -</pre> -<dd> Brings children of a dead node back. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddReclaimZdd">cuddReclaimZdd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddRef.c"TARGET="ABSTRACT"><CODE>cuddRef.c</CODE></A> - -<dt><pre> -<A NAME="cuddRehash"></A> -void <I></I> -<B>cuddRehash</B>( - DdManager * <b>unique</b>, <i></i> - int <b>i</b> <i></i> -) -</pre> -<dd> Doubles the size of a unique subtable and rehashes its - contents. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddRemapUnderApprox"></A> -DdNode * <I></I> -<B>cuddRemapUnderApprox</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - DdNode * <b>f</b>, <i>current DD</i> - int <b>numVars</b>, <i>maximum number of variables</i> - int <b>threshold</b>, <i>threshold under which approximation stops</i> - double <b>quality</b> <i>minimum improvement for accepted changes</i> -) -</pre> -<dd> Applies the remapping underappoximation algorithm. - Proceeds in three phases: - <ul> - <li> collect information on each node in the BDD; this is done via DFS. - <li> traverse the BDD in top-down fashion and compute for each node - whether remapping increases density. - <li> traverse the BDD via DFS and actually perform the elimination. - </ul> - Returns the approximated BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_RemapUnderApprox">Cudd_RemapUnderApprox</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="cuddResizeLinear"></A> -int <I></I> -<B>cuddResizeLinear</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Resizes the linear transform matrix. Returns 1 if - successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="cuddResizeTableZdd"></A> -int <I></I> -<B>cuddResizeTableZdd</B>( - DdManager * <b>unique</b>, <i></i> - int <b>index</b> <i></i> -) -</pre> -<dd> Increases the number of ZDD subtables in a unique table so - that it meets or exceeds index. When new ZDD variables are created, it - is possible to preserve the functions unchanged, or it is possible to - preserve the covers unchanged, but not both. cuddResizeTableZdd preserves - the covers. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#ddResizeTable">ddResizeTable</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddSetInteract"></A> -void <I></I> -<B>cuddSetInteract</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Given a pair of variables 0 <= x < y < table->size, - sets the corresponding bit of the interaction matrix to 1. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddInteract.c"TARGET="ABSTRACT"><CODE>cuddInteract.c</CODE></A> - -<dt><pre> -<A NAME="cuddShrinkDeathRow"></A> -void <I></I> -<B>cuddShrinkDeathRow</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Shrinks the death row by a factor of four. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddClearDeathRow">cuddClearDeathRow</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddRef.c"TARGET="ABSTRACT"><CODE>cuddRef.c</CODE></A> - -<dt><pre> -<A NAME="cuddShrinkSubtable"></A> -void <I></I> -<B>cuddShrinkSubtable</B>( - DdManager * <b>unique</b>, <i></i> - int <b>i</b> <i></i> -) -</pre> -<dd> Shrinks a subtable. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddRehash">cuddRehash</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddSifting"></A> -int <I></I> -<B>cuddSifting</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Implementation of Rudell's sifting algorithm. - Assumes that no dead nodes are present. - <ol> - <li> Order all the variables according to the number of entries - in each unique table. - <li> Sift the variable up and down, remembering each time the - total size of the DD heap. - <li> Select the best permutation. - <li> Repeat 3 and 4 for all variables. - </ol> - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="cuddSlowTableGrowth"></A> -void <I></I> -<B>cuddSlowTableGrowth</B>( - DdManager * <b>unique</b> <i></i> -) -</pre> -<dd> Adjusts parameters of a table to slow down its growth. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddSolveEqnRecur"></A> -DdNode * <I></I> -<B>cuddSolveEqnRecur</B>( - DdManager * <b>bdd</b>, <i></i> - DdNode * <b>F</b>, <i>the left-hand side of the equation</i> - DdNode * <b>Y</b>, <i>the cube of remaining y variables</i> - DdNode ** <b>G</b>, <i>the array of solutions</i> - int <b>n</b>, <i>number of unknowns</i> - int * <b>yIndex</b>, <i>array holding the y variable indices</i> - int <b>i</b> <i>level of recursion</i> -) -</pre> -<dd> Implements the recursive step of Cudd_SolveEqn. - Returns NULL if the intermediate solution blows up - or reordering occurs. The parametric solutions are - stored in the array G. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_SolveEqn">Cudd_SolveEqn</a> -<a href="#Cudd_VerifySol">Cudd_VerifySol</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSolve.c"TARGET="ABSTRACT"><CODE>cuddSolve.c</CODE></A> - -<dt><pre> -<A NAME="cuddSplitSetRecur"></A> -DdNode* <I></I> -<B>cuddSplitSetRecur</B>( - DdManager * <b>manager</b>, <i></i> - st_table * <b>mtable</b>, <i></i> - int * <b>varSeen</b>, <i></i> - DdNode * <b>p</b>, <i></i> - double <b>n</b>, <i></i> - double <b>max</b>, <i></i> - int <b>index</b> <i></i> -) -</pre> -<dd> Implements the recursive step of Cudd_SplitSet. The - procedure recursively traverses the BDD and checks to see if any - node satisfies the minterm requirements as specified by 'n'. At any - node X, n is compared to the number of minterms in the onset of X's - children. If either of the child nodes have exactly n minterms, then - that node is returned; else, if n is greater than the onset of one - of the child nodes, that node is retained and the difference in the - number of minterms is extracted from the other child. In case n - minterms can be extracted from constant 1, the algorithm returns the - result with at most log(n) nodes. -<p> - -<dd> <b>Side Effects</b> The array 'varSeen' is updated at every recursive call - to set the variables traversed by the procedure. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSplit.c"TARGET="ABSTRACT"><CODE>cuddSplit.c</CODE></A> - -<dt><pre> -<A NAME="cuddStCountfree"></A> -enum st_retval <I></I> -<B>cuddStCountfree</B>( - char * <b>key</b>, <i></i> - char * <b>value</b>, <i></i> - char * <b>arg</b> <i></i> -) -</pre> -<dd> Frees the memory used to store the minterm counts - recorded in the visited table. Returns ST_CONTINUE. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="cuddSubsetHeavyBranch"></A> -DdNode * <I></I> -<B>cuddSubsetHeavyBranch</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - DdNode * <b>f</b>, <i>current DD</i> - int <b>numVars</b>, <i>maximum number of variables</i> - int <b>threshold</b> <i>threshold size for the subset</i> -) -</pre> -<dd> Here a subset BDD is built by throwing away one of the - children. Starting at root, annotate each node with the number of - minterms (in terms of the total number of variables specified - - numVars), number of nodes taken by the DAG rooted at this node and - number of additional nodes taken by the child that has the lesser - minterms. The child with the lower number of minterms is thrown away - and a dyanmic count of the nodes of the subset is kept. Once the - threshold is reached the subset is returned to the calling - procedure. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_SubsetHeavyBranch">Cudd_SubsetHeavyBranch</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetHB.c"TARGET="ABSTRACT"><CODE>cuddSubsetHB.c</CODE></A> - -<dt><pre> -<A NAME="cuddSubsetShortPaths"></A> -DdNode * <I></I> -<B>cuddSubsetShortPaths</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - DdNode * <b>f</b>, <i>function to be subset</i> - int <b>numVars</b>, <i>total number of variables in consideration</i> - int <b>threshold</b>, <i>maximum number of nodes allowed in the subset</i> - int <b>hardlimit</b> <i>flag determining whether threshold should be respected strictly</i> -) -</pre> -<dd> The outermost procedure to return a subset of the given - BDD with the largest cubes. The path lengths are calculated, the maximum - allowable path length is determined and the number of nodes of this - path length that can be used to build a subset. If the threshold is - larger than the size of the original BDD, the original BDD is - returned. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_SubsetShortPaths">Cudd_SubsetShortPaths</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetSP.c"TARGET="ABSTRACT"><CODE>cuddSubsetSP.c</CODE></A> - -<dt><pre> -<A NAME="cuddSwapInPlace"></A> -int <I></I> -<B>cuddSwapInPlace</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Swaps two adjacent variables. It assumes that no dead - nodes are present on entry to this procedure. The procedure then - guarantees that no dead nodes will be present when it terminates. - cuddSwapInPlace assumes that x < y. Returns the number of keys in - the table if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="cuddSwapping"></A> -int <I></I> -<B>cuddSwapping</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b>, <i></i> - Cudd_ReorderingType <b>heuristic</b> <i></i> -) -</pre> -<dd> Implementation of Plessier's algorithm that reorders - variables by a sequence of (non-adjacent) swaps. - <ol> - <li> Select two variables (RANDOM or HEURISTIC). - <li> Permute these variables. - <li> If the nodes have decreased accept the permutation. - <li> Otherwise reconstruct the original heap. - <li> Loop. - </ol> - Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="cuddSymmCheck"></A> -int <I></I> -<B>cuddSymmCheck</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Checks for symmetry of x and y. Ignores projection - functions, unless they are isolated. Returns 1 in case of symmetry; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="cuddSymmSiftingConv"></A> -int <I></I> -<B>cuddSymmSiftingConv</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Symmetric sifting to convergence algorithm. - Assumes that no dead nodes are present. - <ol> - <li> Order all the variables according to the number of entries in - each unique subtable. - <li> Sift the variable up and down, remembering each time the total - size of the DD heap and grouping variables that are symmetric. - <li> Select the best permutation. - <li> Repeat 3 and 4 for all variables. - <li> Repeat 1-4 until no further improvement. - </ol> - Returns 1 plus the number of symmetric variables if successful; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddSymmSifting">cuddSymmSifting</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="cuddSymmSifting"></A> -int <I></I> -<B>cuddSymmSifting</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Symmetric sifting algorithm. - Assumes that no dead nodes are present. - <ol> - <li> Order all the variables according to the number of entries in - each unique subtable. - <li> Sift the variable up and down, remembering each time the total - size of the DD heap and grouping variables that are symmetric. - <li> Select the best permutation. - <li> Repeat 3 and 4 for all variables. - </ol> - Returns 1 plus the number of symmetric variables if successful; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddSymmSiftingConv">cuddSymmSiftingConv</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="cuddTestInteract"></A> -int <I></I> -<B>cuddTestInteract</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Given a pair of variables 0 <= x < y < table->size, - tests whether the corresponding bit of the interaction matrix is 1. - Returns the value of the bit. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddInteract.c"TARGET="ABSTRACT"><CODE>cuddInteract.c</CODE></A> - -<dt><pre> -<A NAME="cuddTimesInDeathRow"></A> -int <I></I> -<B>cuddTimesInDeathRow</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Counts how many times a node is in the death row. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_DelayedDerefBdd">Cudd_DelayedDerefBdd</a> -<a href="#cuddClearDeathRow">cuddClearDeathRow</a> -<a href="#cuddIsInDeathRow">cuddIsInDeathRow</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddRef.c"TARGET="ABSTRACT"><CODE>cuddRef.c</CODE></A> - -<dt><pre> -<A NAME="cuddTreeSifting"></A> -int <I></I> -<B>cuddTreeSifting</B>( - DdManager * <b>table</b>, <i>DD table</i> - Cudd_ReorderingType <b>method</b> <i>reordering method for the groups of leaves</i> -) -</pre> -<dd> Tree sifting algorithm. Assumes that a tree representing - a group hierarchy is passed as a parameter. It then reorders each - group in postorder fashion by calling ddTreeSiftingAux. Assumes that - no dead nodes are present. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="cuddUnderApprox"></A> -DdNode * <I></I> -<B>cuddUnderApprox</B>( - DdManager * <b>dd</b>, <i>DD manager</i> - DdNode * <b>f</b>, <i>current DD</i> - int <b>numVars</b>, <i>maximum number of variables</i> - int <b>threshold</b>, <i>threshold under which approximation stops</i> - int <b>safe</b>, <i>enforce safe approximation</i> - double <b>quality</b> <i>minimum improvement for accepted changes</i> -) -</pre> -<dd> Applies Tom Shiple's underappoximation algorithm. Proceeds - in three phases: - <ul> - <li> collect information on each node in the BDD; this is done via DFS. - <li> traverse the BDD in top-down fashion and compute for each node - whether its elimination increases density. - <li> traverse the BDD via DFS and actually perform the elimination. - </ul> - Returns the approximated BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_UnderApprox">Cudd_UnderApprox</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="cuddUniqueConst"></A> -DdNode * <I></I> -<B>cuddUniqueConst</B>( - DdManager * <b>unique</b>, <i></i> - CUDD_VALUE_TYPE <b>value</b> <i></i> -) -</pre> -<dd> Checks the unique table for the existence of a constant node. - If it does not exist, it creates a new one. Does not - modify the reference count of whatever is returned. A newly created - internal node comes back with a reference count 0. Returns a - pointer to the new node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddUniqueInterIVO"></A> -DdNode * <I></I> -<B>cuddUniqueInterIVO</B>( - DdManager * <b>unique</b>, <i></i> - int <b>index</b>, <i></i> - DdNode * <b>T</b>, <i></i> - DdNode * <b>E</b> <i></i> -) -</pre> -<dd> Wrapper for cuddUniqueInter that is independent of - variable ordering (IVO). This function does not require parameter - index to precede the indices of the top nodes of T and E in the - variable order. Returns a pointer to the result node under normal - conditions; NULL if reordering occurred or memory was exhausted. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddUniqueInter">cuddUniqueInter</a> -<a href="#Cudd_MakeBddFromZddCover">Cudd_MakeBddFromZddCover</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddUniqueInterZdd"></A> -DdNode * <I></I> -<B>cuddUniqueInterZdd</B>( - DdManager * <b>unique</b>, <i></i> - int <b>index</b>, <i></i> - DdNode * <b>T</b>, <i></i> - DdNode * <b>E</b> <i></i> -) -</pre> -<dd> Checks the unique table for the existence of an internal - ZDD node. If it does not exist, it creates a new one. Does not - modify the reference count of whatever is returned. A newly created - internal node comes back with a reference count 0. For a newly - created node, increments the reference counts of what T and E point - to. Returns a pointer to the new node if successful; NULL if memory - is exhausted or if reordering took place. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddUniqueInter">cuddUniqueInter</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddUniqueInter"></A> -DdNode * <I></I> -<B>cuddUniqueInter</B>( - DdManager * <b>unique</b>, <i></i> - int <b>index</b>, <i></i> - DdNode * <b>T</b>, <i></i> - DdNode * <b>E</b> <i></i> -) -</pre> -<dd> Checks the unique table for the existence of an internal - node. If it does not exist, it creates a new one. Does not - modify the reference count of whatever is returned. A newly created - internal node comes back with a reference count 0. For a newly - created node, increments the reference counts of what T and E point - to. Returns a pointer to the new node if successful; NULL if memory - is exhausted or if reordering took place. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddUniqueInterZdd">cuddUniqueInterZdd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddUniqueLookup"></A> -static DdNode * <I></I> -<B>cuddUniqueLookup</B>( - DdManager * <b>unique</b>, <i></i> - int <b>index</b>, <i></i> - DdNode * <b>T</b>, <i></i> - DdNode * <b>E</b> <i></i> -) -</pre> -<dd> Checks the unique table for the existence of an internal - node. Returns a pointer to the node if it is in the table; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddUniqueInter">cuddUniqueInter</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="cuddUpdateInteractionMatrix"></A> -void <I></I> -<B>cuddUpdateInteractionMatrix</B>( - DdManager * <b>table</b>, <i></i> - int <b>xindex</b>, <i></i> - int <b>yindex</b> <i></i> -) -</pre> -<dd> Updates the interaction matrix. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="cuddVerifySol"></A> -DdNode * <I></I> -<B>cuddVerifySol</B>( - DdManager * <b>bdd</b>, <i></i> - DdNode * <b>F</b>, <i>the left-hand side of the equation</i> - DdNode ** <b>G</b>, <i>the array of solutions</i> - int * <b>yIndex</b>, <i>array holding the y variable indices</i> - int <b>n</b> <i>number of unknowns</i> -) -</pre> -<dd> Implements the recursive step of Cudd_VerifySol. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_VerifySol">Cudd_VerifySol</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSolve.c"TARGET="ABSTRACT"><CODE>cuddSolve.c</CODE></A> - -<dt><pre> -<A NAME="cuddWindowReorder"></A> -int <I></I> -<B>cuddWindowReorder</B>( - DdManager * <b>table</b>, <i>DD table</i> - int <b>low</b>, <i>lowest index to reorder</i> - int <b>high</b>, <i>highest index to reorder</i> - Cudd_ReorderingType <b>submethod</b> <i>window reordering option</i> -) -</pre> -<dd> Reorders by applying the method of the sliding window. - Tries all possible permutations to the variables in a window that - slides from low to high. The size of the window is determined by - submethod. Assumes that no dead nodes are present. Returns 1 in - case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddWindow.c"TARGET="ABSTRACT"><CODE>cuddWindow.c</CODE></A> - -<dt><pre> -<A NAME="cuddXorLinear"></A> -static void <I></I> -<B>cuddXorLinear</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> XORs two rows of the linear transform matrix and replaces - the first row with the result. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddAlignToBdd"></A> -int <I></I> -<B>cuddZddAlignToBdd</B>( - DdManager * <b>table</b> <i>DD manager</i> -) -</pre> -<dd> Reorders ZDD variables according to the order of the - BDD variables. This function can be called at the end of BDD - reordering to insure that the order of the ZDD variables is - consistent with the order of the BDD variables. The number of ZDD - variables must be a multiple of the number of BDD variables. Let - <code>M</code> be the ratio of the two numbers. cuddZddAlignToBdd - then considers the ZDD variables from <code>M*i</code> to - <code>(M+1)*i-1</code> as corresponding to BDD variable - <code>i</code>. This function should be normally called from - Cudd_ReduceHeap, which clears the cache. Returns 1 in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Changes the ZDD variable order for all diagrams and performs - garbage collection of the ZDD unique table. -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddShuffleHeap">Cudd_zddShuffleHeap</a> -<a href="#Cudd_ReduceHeap">Cudd_ReduceHeap</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddChangeAux"></A> -DdNode * <I></I> -<B>cuddZddChangeAux</B>( - DdManager * <b>zdd</b>, <i></i> - DdNode * <b>P</b>, <i></i> - DdNode * <b>zvar</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddChange. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSetop.c"TARGET="ABSTRACT"><CODE>cuddZddSetop.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddChange"></A> -DdNode * <I></I> -<B>cuddZddChange</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>P</b>, <i></i> - int <b>var</b> <i></i> -) -</pre> -<dd> Substitutes a variable with its complement in a ZDD. - returns a pointer to the result if successful; NULL - otherwise. cuddZddChange performs the same function as - Cudd_zddChange, but does not restart if reordering has taken - place. Therefore it can be called from within a recursive - procedure. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddChange">Cudd_zddChange</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSetop.c"TARGET="ABSTRACT"><CODE>cuddZddSetop.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddComplement"></A> -DdNode * <I></I> -<B>cuddZddComplement</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>node</b> <i></i> -) -</pre> -<dd> Computes the complement of a ZDD node. So far, since we - couldn't find a direct way to get the complement of a ZDD cover, we first - convert a ZDD cover to a BDD, then make the complement of the ZDD cover - from the complement of the BDD node by using ISOP. -<p> - -<dd> <b>Side Effects</b> The result depends on current variable order. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddCountDoubleStep"></A> -static double <I></I> -<B>cuddZddCountDoubleStep</B>( - DdNode * <b>P</b>, <i></i> - st_table * <b>table</b>, <i></i> - DdNode * <b>base</b>, <i></i> - DdNode * <b>empty</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddCountDouble. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddCount.c"TARGET="ABSTRACT"><CODE>cuddZddCount.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddCountStep"></A> -static int <I></I> -<B>cuddZddCountStep</B>( - DdNode * <b>P</b>, <i></i> - st_table * <b>table</b>, <i></i> - DdNode * <b>base</b>, <i></i> - DdNode * <b>empty</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddCount. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddCount.c"TARGET="ABSTRACT"><CODE>cuddZddCount.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddDagInt"></A> -static int <I></I> -<B>cuddZddDagInt</B>( - DdNode * <b>n</b>, <i></i> - st_table * <b>tab</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddDagSize. Does - not check for out-of-memory conditions. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddMisc.c"TARGET="ABSTRACT"><CODE>cuddZddMisc.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddDiff"></A> -DdNode * <I></I> -<B>cuddZddDiff</B>( - DdManager * <b>zdd</b>, <i></i> - DdNode * <b>P</b>, <i></i> - DdNode * <b>Q</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddDiff. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSetop.c"TARGET="ABSTRACT"><CODE>cuddZddSetop.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddDivideF"></A> -DdNode * <I></I> -<B>cuddZddDivideF</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddDivideF. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddDivideF">Cudd_zddDivideF</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddDivide"></A> -DdNode * <I></I> -<B>cuddZddDivide</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddDivide. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddDivide">Cudd_zddDivide</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddFreeUniv"></A> -void <I></I> -<B>cuddZddFreeUniv</B>( - DdManager * <b>zdd</b> <i></i> -) -</pre> -<dd> Frees the ZDD universe. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddZddInitUniv">cuddZddInitUniv</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddInit.c"TARGET="ABSTRACT"><CODE>cuddInit.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddGetCofactors2"></A> -int <I></I> -<B>cuddZddGetCofactors2</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - int <b>v</b>, <i></i> - DdNode ** <b>f1</b>, <i></i> - DdNode ** <b>f0</b> <i></i> -) -</pre> -<dd> Computes the two-way decomposition of f w.r.t. v. -<p> - -<dd> <b>Side Effects</b> The results are returned in f1 and f0. -<p> - -<dd> <b>See Also</b> <code><a href="#cuddZddGetCofactors3">cuddZddGetCofactors3</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddGetCofactors3"></A> -int <I></I> -<B>cuddZddGetCofactors3</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - int <b>v</b>, <i></i> - DdNode ** <b>f1</b>, <i></i> - DdNode ** <b>f0</b>, <i></i> - DdNode ** <b>fd</b> <i></i> -) -</pre> -<dd> Computes the three-way decomposition of function f (represented - by a ZDD) wit respect to variable v. Returns 0 if successful; 1 otherwise. -<p> - -<dd> <b>Side Effects</b> The results are returned in f1, f0, and fd. -<p> - -<dd> <b>See Also</b> <code><a href="#cuddZddGetCofactors2">cuddZddGetCofactors2</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddGetNegVarIndex"></A> -int <I></I> -<B>cuddZddGetNegVarIndex</B>( - DdManager * <b>dd</b>, <i></i> - int <b>index</b> <i></i> -) -</pre> -<dd> Returns the index of negative ZDD variable. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddGetNegVarLevel"></A> -int <I></I> -<B>cuddZddGetNegVarLevel</B>( - DdManager * <b>dd</b>, <i></i> - int <b>index</b> <i></i> -) -</pre> -<dd> Returns the level of negative ZDD variable. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddGetNodeIVO"></A> -DdNode * <I></I> -<B>cuddZddGetNodeIVO</B>( - DdManager * <b>dd</b>, <i></i> - int <b>index</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b> <i></i> -) -</pre> -<dd> Wrapper for cuddUniqueInterZdd that is independent of - variable ordering (IVO). This function does not require parameter - index to precede the indices of the top nodes of g and h in the - variable order. Returns a pointer to the result node under normal - conditions; NULL if reordering occurred or memory was exhausted. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddZddGetNode">cuddZddGetNode</a> -<a href="#cuddZddIsop">cuddZddIsop</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddGetNode"></A> -DdNode * <I></I> -<B>cuddZddGetNode</B>( - DdManager * <b>zdd</b>, <i></i> - int <b>id</b>, <i></i> - DdNode * <b>T</b>, <i></i> - DdNode * <b>E</b> <i></i> -) -</pre> -<dd> Wrapper for cuddUniqueInterZdd, which applies the ZDD - reduction rule. Returns a pointer to the result node under normal - conditions; NULL if reordering occurred or memory was exhausted. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddUniqueInterZdd">cuddUniqueInterZdd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddGetPosVarIndex"></A> -int <I></I> -<B>cuddZddGetPosVarIndex</B>( - DdManager * <b>dd</b>, <i></i> - int <b>index</b> <i></i> -) -</pre> -<dd> Returns the index of positive ZDD variable. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddGetPosVarLevel"></A> -int <I></I> -<B>cuddZddGetPosVarLevel</B>( - DdManager * <b>dd</b>, <i></i> - int <b>index</b> <i></i> -) -</pre> -<dd> Returns the level of positive ZDD variable. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddInitUniv"></A> -int <I></I> -<B>cuddZddInitUniv</B>( - DdManager * <b>zdd</b> <i></i> -) -</pre> -<dd> Initializes the ZDD universe. Returns 1 if successful; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddZddFreeUniv">cuddZddFreeUniv</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddInit.c"TARGET="ABSTRACT"><CODE>cuddInit.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddIntersect"></A> -DdNode * <I></I> -<B>cuddZddIntersect</B>( - DdManager * <b>zdd</b>, <i></i> - DdNode * <b>P</b>, <i></i> - DdNode * <b>Q</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddIntersect. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSetop.c"TARGET="ABSTRACT"><CODE>cuddZddSetop.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddIsop"></A> -DdNode * <I></I> -<B>cuddZddIsop</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>L</b>, <i></i> - DdNode * <b>U</b>, <i></i> - DdNode ** <b>zdd_I</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddIsop. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddIsop">Cudd_zddIsop</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddIsop.c"TARGET="ABSTRACT"><CODE>cuddZddIsop.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddIte"></A> -DdNode * <I></I> -<B>cuddZddIte</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b>, <i></i> - DdNode * <b>h</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddIte. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSetop.c"TARGET="ABSTRACT"><CODE>cuddZddSetop.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddLinearAux"></A> -static int <I></I> -<B>cuddZddLinearAux</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xLow</b>, <i></i> - int <b>xHigh</b> <i></i> -) -</pre> -<dd> Given xLow <= x <= xHigh moves x up and down between the - boundaries. Finds the best position and does the required changes. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddLin.c"TARGET="ABSTRACT"><CODE>cuddZddLin.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddLinearBackward"></A> -static int <I></I> -<B>cuddZddLinearBackward</B>( - DdManager * <b>table</b>, <i></i> - int <b>size</b>, <i></i> - Move * <b>moves</b> <i></i> -) -</pre> -<dd> Given a set of moves, returns the ZDD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddLin.c"TARGET="ABSTRACT"><CODE>cuddZddLin.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddLinearDown"></A> -static Move * <I></I> -<B>cuddZddLinearDown</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xHigh</b>, <i></i> - Move * <b>prevMoves</b> <i></i> -) -</pre> -<dd> Sifts a variable down. Moves x down until either it - reaches the bound (xHigh) or the size of the ZDD heap increases too - much. Returns the set of moves in case of success; NULL if memory is - full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddLin.c"TARGET="ABSTRACT"><CODE>cuddZddLin.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddLinearInPlace"></A> -static int <I></I> -<B>cuddZddLinearInPlace</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Linearly combines two adjacent variables. It assumes - that no dead nodes are present on entry to this procedure. The - procedure then guarantees that no dead nodes will be present when it - terminates. cuddZddLinearInPlace assumes that x < y. Returns the - number of keys in the table if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddZddSwapInPlace">cuddZddSwapInPlace</a> -<a href="#cuddLinearInPlace">cuddLinearInPlace</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddLin.c"TARGET="ABSTRACT"><CODE>cuddZddLin.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddLinearSifting"></A> -int <I></I> -<B>cuddZddLinearSifting</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Implementation of the linear sifting algorithm for ZDDs. - Assumes that no dead nodes are present. - <ol> - <li> Order all the variables according to the number of entries - in each unique table. - <li> Sift the variable up and down and applies the XOR transformation, - remembering each time the total size of the DD heap. - <li> Select the best permutation. - <li> Repeat 3 and 4 for all variables. - </ol> - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddLin.c"TARGET="ABSTRACT"><CODE>cuddZddLin.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddLinearUp"></A> -static Move * <I></I> -<B>cuddZddLinearUp</B>( - DdManager * <b>table</b>, <i></i> - int <b>y</b>, <i></i> - int <b>xLow</b>, <i></i> - Move * <b>prevMoves</b> <i></i> -) -</pre> -<dd> Sifts a variable up applying the XOR - transformation. Moves y up until either it reaches the bound (xLow) - or the size of the ZDD heap increases too much. Returns the set of - moves in case of success; NULL if memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddLin.c"TARGET="ABSTRACT"><CODE>cuddZddLin.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddNextHigh"></A> -int <I></I> -<B>cuddZddNextHigh</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b> <i></i> -) -</pre> -<dd> Finds the next subtable with a larger index. Returns the - index. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddNextLow"></A> -int <I></I> -<B>cuddZddNextLow</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b> <i></i> -) -</pre> -<dd> Finds the next subtable with a smaller index. Returns the - index. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddProduct"></A> -DdNode * <I></I> -<B>cuddZddProduct</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddProduct. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddProduct">Cudd_zddProduct</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddP"></A> -int <I></I> -<B>cuddZddP</B>( - DdManager * <b>zdd</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Prints a ZDD to the standard output. One line per node is - printed. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddPrintDebug">Cudd_zddPrintDebug</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddUtil.c"TARGET="ABSTRACT"><CODE>cuddZddUtil.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSiftingAux"></A> -static int <I></I> -<B>cuddZddSiftingAux</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>x_low</b>, <i></i> - int <b>x_high</b> <i></i> -) -</pre> -<dd> Given xLow <= x <= xHigh moves x up and down between the - boundaries. Finds the best position and does the required changes. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSiftingBackward"></A> -static int <I></I> -<B>cuddZddSiftingBackward</B>( - DdManager * <b>table</b>, <i></i> - Move * <b>moves</b>, <i></i> - int <b>size</b> <i></i> -) -</pre> -<dd> Given a set of moves, returns the ZDD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSiftingDown"></A> -static Move * <I></I> -<B>cuddZddSiftingDown</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>x_high</b>, <i></i> - int <b>initial_size</b> <i></i> -) -</pre> -<dd> Sifts a variable down. Moves x down until either it - reaches the bound (x_high) or the size of the ZDD heap increases too - much. Returns the set of moves in case of success; NULL if memory is - full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSiftingUp"></A> -static Move * <I></I> -<B>cuddZddSiftingUp</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>x_low</b>, <i></i> - int <b>initial_size</b> <i></i> -) -</pre> -<dd> Sifts a variable up. Moves y up until either it reaches - the bound (x_low) or the size of the ZDD heap increases too much. - Returns the set of moves in case of success; NULL if memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSifting"></A> -int <I></I> -<B>cuddZddSifting</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Implementation of Rudell's sifting algorithm. - Assumes that no dead nodes are present. - <ol> - <li> Order all the variables according to the number of entries - in each unique table. - <li> Sift the variable up and down, remembering each time the - total size of the DD heap. - <li> Select the best permutation. - <li> Repeat 3 and 4 for all variables. - </ol> - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSubset0"></A> -DdNode * <I></I> -<B>cuddZddSubset0</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>P</b>, <i></i> - int <b>var</b> <i></i> -) -</pre> -<dd> Computes the negative cofactor of a ZDD w.r.t. a - variable. In terms of combinations, the result is the set of all - combinations in which the variable is negated. Returns a pointer to - the result if successful; NULL otherwise. cuddZddSubset0 performs - the same function as Cudd_zddSubset0, but does not restart if - reordering has taken place. Therefore it can be called from within a - recursive procedure. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddZddSubset1">cuddZddSubset1</a> -<a href="#Cudd_zddSubset0">Cudd_zddSubset0</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSetop.c"TARGET="ABSTRACT"><CODE>cuddZddSetop.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSubset1"></A> -DdNode * <I></I> -<B>cuddZddSubset1</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>P</b>, <i></i> - int <b>var</b> <i></i> -) -</pre> -<dd> Computes the positive cofactor of a ZDD w.r.t. a - variable. In terms of combinations, the result is the set of all - combinations in which the variable is asserted. Returns a pointer to - the result if successful; NULL otherwise. cuddZddSubset1 performs - the same function as Cudd_zddSubset1, but does not restart if - reordering has taken place. Therefore it can be called from within a - recursive procedure. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddZddSubset0">cuddZddSubset0</a> -<a href="#Cudd_zddSubset1">Cudd_zddSubset1</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSetop.c"TARGET="ABSTRACT"><CODE>cuddZddSetop.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSwapInPlace"></A> -int <I></I> -<B>cuddZddSwapInPlace</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Swaps two adjacent variables. It assumes that no dead - nodes are present on entry to this procedure. The procedure then - guarantees that no dead nodes will be present when it terminates. - cuddZddSwapInPlace assumes that x < y. Returns the number of keys in - the table if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSwapping"></A> -int <I></I> -<B>cuddZddSwapping</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b>, <i></i> - Cudd_ReorderingType <b>heuristic</b> <i></i> -) -</pre> -<dd> Implementation of Plessier's algorithm that reorders - variables by a sequence of (non-adjacent) swaps. - <ol> - <li> Select two variables (RANDOM or HEURISTIC). - <li> Permute these variables. - <li> If the nodes have decreased accept the permutation. - <li> Otherwise reconstruct the original heap. - <li> Loop. - </ol> - Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSymmCheck"></A> -int <I></I> -<B>cuddZddSymmCheck</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Checks for symmetry of x and y. Ignores projection - functions, unless they are isolated. Returns 1 in case of - symmetry; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSymm.c"TARGET="ABSTRACT"><CODE>cuddZddSymm.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSymmSiftingAux"></A> -static int <I></I> -<B>cuddZddSymmSiftingAux</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>x_low</b>, <i></i> - int <b>x_high</b> <i></i> -) -</pre> -<dd> Given x_low <= x <= x_high moves x up and down between the - boundaries. Finds the best position and does the required changes. - Assumes that x is not part of a symmetry group. Returns 1 if - successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSymm.c"TARGET="ABSTRACT"><CODE>cuddZddSymm.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSymmSiftingBackward"></A> -static int <I></I> -<B>cuddZddSymmSiftingBackward</B>( - DdManager * <b>table</b>, <i></i> - Move * <b>moves</b>, <i></i> - int <b>size</b> <i></i> -) -</pre> -<dd> Given a set of moves, returns the ZDD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSymm.c"TARGET="ABSTRACT"><CODE>cuddZddSymm.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSymmSiftingConvAux"></A> -static int <I></I> -<B>cuddZddSymmSiftingConvAux</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>x_low</b>, <i></i> - int <b>x_high</b> <i></i> -) -</pre> -<dd> Given x_low <= x <= x_high moves x up and down between the - boundaries. Finds the best position and does the required changes. - Assumes that x is either an isolated variable, or it is the bottom of - a symmetry group. All symmetries may not have been found, because of - exceeded growth limit. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSymm.c"TARGET="ABSTRACT"><CODE>cuddZddSymm.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSymmSiftingConv"></A> -int <I></I> -<B>cuddZddSymmSiftingConv</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Symmetric sifting to convergence algorithm for ZDDs. - Assumes that no dead nodes are present. - <ol> - <li> Order all the variables according to the number of entries in - each unique subtable. - <li> Sift the variable up and down, remembering each time the total - size of the ZDD heap and grouping variables that are symmetric. - <li> Select the best permutation. - <li> Repeat 3 and 4 for all variables. - <li> Repeat 1-4 until no further improvement. - </ol> - Returns 1 plus the number of symmetric variables if successful; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddZddSymmSifting">cuddZddSymmSifting</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSymm.c"TARGET="ABSTRACT"><CODE>cuddZddSymm.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSymmSifting_down"></A> -static Move * <I></I> -<B>cuddZddSymmSifting_down</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>x_high</b>, <i></i> - int <b>initial_size</b> <i></i> -) -</pre> -<dd> Moves x down until either it reaches the bound (x_high) - or the size of the ZDD heap increases too much. Assumes that x is the - bottom of a symmetry group. Checks x for symmetry to the adjacent - variables. If symmetry is found, the symmetry group of x is merged - with the symmetry group of the other variable. Returns the set of - moves in case of success; ZDD_MV_OOM if memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSymm.c"TARGET="ABSTRACT"><CODE>cuddZddSymm.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSymmSifting_up"></A> -static Move * <I></I> -<B>cuddZddSymmSifting_up</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>x_low</b>, <i></i> - int <b>initial_size</b> <i></i> -) -</pre> -<dd> Moves x up until either it reaches the bound (x_low) or - the size of the ZDD heap increases too much. Assumes that x is the top - of a symmetry group. Checks x for symmetry to the adjacent - variables. If symmetry is found, the symmetry group of x is merged - with the symmetry group of the other variable. Returns the set of - moves in case of success; ZDD_MV_OOM if memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSymm.c"TARGET="ABSTRACT"><CODE>cuddZddSymm.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSymmSifting"></A> -int <I></I> -<B>cuddZddSymmSifting</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Symmetric sifting algorithm. - Assumes that no dead nodes are present. - <ol> - <li> Order all the variables according to the number of entries in - each unique subtable. - <li> Sift the variable up and down, remembering each time the total - size of the ZDD heap and grouping variables that are symmetric. - <li> Select the best permutation. - <li> Repeat 3 and 4 for all variables. - </ol> - Returns 1 plus the number of symmetric variables if successful; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddZddSymmSiftingConv">cuddZddSymmSiftingConv</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSymm.c"TARGET="ABSTRACT"><CODE>cuddZddSymm.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddSymmSummary"></A> -static void <I></I> -<B>cuddZddSymmSummary</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b>, <i></i> - int * <b>symvars</b>, <i></i> - int * <b>symgroups</b> <i></i> -) -</pre> -<dd> Counts numbers of symmetric variables and symmetry - groups. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSymm.c"TARGET="ABSTRACT"><CODE>cuddZddSymm.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddTreeSifting"></A> -int <I></I> -<B>cuddZddTreeSifting</B>( - DdManager * <b>table</b>, <i>DD table</i> - Cudd_ReorderingType <b>method</b> <i>reordering method for the groups of leaves</i> -) -</pre> -<dd> Tree sifting algorithm for ZDDs. Assumes that a tree - representing a group hierarchy is passed as a parameter. It then - reorders each group in postorder fashion by calling - zddTreeSiftingAux. Assumes that no dead nodes are present. Returns - 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddUnateProduct"></A> -DdNode * <I></I> -<B>cuddZddUnateProduct</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddUnateProduct. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddUnateProduct">Cudd_zddUnateProduct</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddUndoMoves"></A> -static Move* <I></I> -<B>cuddZddUndoMoves</B>( - DdManager * <b>table</b>, <i></i> - Move * <b>moves</b> <i></i> -) -</pre> -<dd> Given a set of moves, returns the ZDD heap to the - order in effect before the moves. Returns 1 in case of success; - 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddLin.c"TARGET="ABSTRACT"><CODE>cuddZddLin.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddUnion"></A> -DdNode * <I></I> -<B>cuddZddUnion</B>( - DdManager * <b>zdd</b>, <i></i> - DdNode * <b>P</b>, <i></i> - DdNode * <b>Q</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddUnion. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSetop.c"TARGET="ABSTRACT"><CODE>cuddZddSetop.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddUniqueCompare"></A> -int <I></I> -<B>cuddZddUniqueCompare</B>( - int * <b>ptr_x</b>, <i></i> - int * <b>ptr_y</b> <i></i> -) -</pre> -<dd> Comparison function used by qsort to order the - variables according to the number of keys in the subtables. - Returns the difference in number of keys between the two - variables being compared. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddWeakDivF"></A> -DdNode * <I></I> -<B>cuddZddWeakDivF</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddWeakDivF. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddWeakDivF">Cudd_zddWeakDivF</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="cuddZddWeakDiv"></A> -DdNode * <I></I> -<B>cuddZddWeakDiv</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>g</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddWeakDiv. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddWeakDiv">Cudd_zddWeakDiv</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddFuncs.c"TARGET="ABSTRACT"><CODE>cuddZddFuncs.c</CODE></A> - -<dt><pre> -<A NAME="ddBddMaximallyExpand"></A> -static DdNode * <I></I> -<B>ddBddMaximallyExpand</B>( - DdManager * <b>dd</b>, <i>manager</i> - DdNode * <b>lb</b>, <i>cube to be expanded</i> - DdNode * <b>ub</b>, <i>upper bound cube</i> - DdNode * <b>f</b> <i>function against which to expand</i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddMaximallyExpand. - Returns set of primes or zero BDD if successful; NULL otherwise. On entry - to this function, ub and lb should be different from the zero BDD. The - function then maintains this invariant. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSat.c"TARGET="ABSTRACT"><CODE>cuddSat.c</CODE></A> - -<dt><pre> -<A NAME="ddBddShortestPathUnate"></A> -static int <I></I> -<B>ddBddShortestPathUnate</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - int * <b>phases</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Performs shortest path computation on a unate function. - Returns the length of the shortest path to one if successful; - CUDD_OUT_OF_MEM otherwise. This function is based on the observation - that in the BDD of a unate function no node except the constant is - reachable from the root via paths of different parity. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#getShortest">getShortest</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSat.c"TARGET="ABSTRACT"><CODE>cuddSat.c</CODE></A> - -<dt><pre> -<A NAME="ddBddToAddRecur"></A> -static DdNode * <I></I> -<B>ddBddToAddRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>B</b> <i></i> -) -</pre> -<dd> Performs the recursive step for Cudd_BddToAdd. Returns a - pointer to the resulting ADD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddBridge.c"TARGET="ABSTRACT"><CODE>cuddBridge.c</CODE></A> - -<dt><pre> -<A NAME="ddCheckPermuation"></A> -static int <I></I> -<B>ddCheckPermuation</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b>, <i></i> - int * <b>perm</b>, <i></i> - int * <b>invperm</b> <i></i> -) -</pre> -<dd> Checks the BDD variable group tree before a shuffle. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Changes the BDD variable group tree. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddClearFlag"></A> -static void <I></I> -<B>ddClearFlag</B>( - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Performs a DFS from f, clearing the LSB of the next - pointers. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#ddSupportStep">ddSupportStep</a> -<a href="#ddFindSupport">ddFindSupport</a> -<a href="#ddLeavesInt">ddLeavesInt</a> -<a href="#ddDagInt">ddDagInt</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddClearGlobal"></A> -static void <I></I> -<B>ddClearGlobal</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>maxlevel</b> <i></i> -) -</pre> -<dd> Scans the DD and clears the LSB of the next pointers. - The LSB of the next pointers are used as markers to tell whether a - node was reached. Once the roots are counted, these flags are - reset. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#ddCountRoots">ddCountRoots</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="ddClearGlobal"></A> -static void <I></I> -<B>ddClearGlobal</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> The LSB of the next pointers are used as markers to tell - whether a node was reached by at least one DFS. Once the interaction - matrix is built, these flags are reset. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddInteract.c"TARGET="ABSTRACT"><CODE>cuddInteract.c</CODE></A> - -<dt><pre> -<A NAME="ddClearLocal"></A> -static void <I></I> -<B>ddClearLocal</B>( - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Performs a DFS from f, clearing the LSB of the then pointers. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddInteract.c"TARGET="ABSTRACT"><CODE>cuddInteract.c</CODE></A> - -<dt><pre> -<A NAME="ddClearVars"></A> -static void <I></I> -<B>ddClearVars</B>( - DdManager * <b>dd</b>, <i></i> - int <b>SP</b> <i></i> -) -</pre> -<dd> Clears visited flags for variables. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddCofMintermAux"></A> -static double * <I></I> -<B>ddCofMintermAux</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>node</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Traverses the DD node and computes the fraction of - minterms in the on-set of all positive cofactors simultaneously. - It allocates an array with two more entries than there are - variables below the one labeling the node. One extra entry (the - first in the array) is for the variable labeling the node. The other - entry (the last one in the array) holds the fraction of minterms of - the function rooted at node. Each other entry holds the value for - one cofactor. The array is put in a symbol table, to avoid repeated - computation, and its address is returned by the procedure, for use - by the caller. Returns a pointer to the array of cofactor measures. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSign.c"TARGET="ABSTRACT"><CODE>cuddSign.c</CODE></A> - -<dt><pre> -<A NAME="ddCountInternalMtrNodes"></A> -static int <I></I> -<B>ddCountInternalMtrNodes</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b> <i></i> -) -</pre> -<dd> Counts the number of internal nodes of the group tree. - Returns the count. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddCountMintermAux"></A> -static double <I></I> -<B>ddCountMintermAux</B>( - DdNode * <b>node</b>, <i></i> - double <b>max</b>, <i></i> - DdHashTable * <b>table</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_CountMinterm. - It is based on the following identity. Let |f| be the - number of minterms of f. Then: - <xmp> - |f| = (|f0|+|f1|)/2 - </xmp> - where f0 and f1 are the two cofactors of f. Does not use the - identity |f'| = max - |f|, to minimize loss of accuracy due to - roundoff. Returns the number of minterms of the function rooted at - node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddCountPathAux"></A> -static double <I></I> -<B>ddCountPathAux</B>( - DdNode * <b>node</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_CountPath. - It is based on the following identity. Let |f| be the - number of paths of f. Then: - <xmp> - |f| = |f0|+|f1| - </xmp> - where f0 and f1 are the two cofactors of f. Uses the - identity |f'| = |f|, to improve the utilization of the (local) cache. - Returns the number of paths of the function rooted at node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddCountPathsToNonZero"></A> -static double <I></I> -<B>ddCountPathsToNonZero</B>( - DdNode * <b>N</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_CountPathsToNonZero. - It is based on the following identity. Let |f| be the - number of paths of f. Then: - <xmp> - |f| = |f0|+|f1| - </xmp> - where f0 and f1 are the two cofactors of f. Returns the number of - paths of the function rooted at node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddCountRoots"></A> -static int <I></I> -<B>ddCountRoots</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Counts the number of roots at the levels between lower and - upper. The computation is based on breadth-first search. - A node is a root if it is not reachable from any previously visited node. - (All the nodes at level lower are therefore considered roots.) - The visited flag uses the LSB of the next pointer. Returns the root - count. The roots that are constant nodes are always ignored. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#ddClearGlobal">ddClearGlobal</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="ddCreateGroup"></A> -static void <I></I> -<B>ddCreateGroup</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Creates a group encompassing variables from x to y in the - DD table. In the current implementation it must be y == x+1. - Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddDagInt"></A> -static int <I></I> -<B>ddDagInt</B>( - DdNode * <b>n</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_DagSize. Returns the - number of nodes in the graph rooted at n. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddDissolveGroup"></A> -static void <I></I> -<B>ddDissolveGroup</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> x and y are variables in a group to be cut in two. The cut - is to pass between x and y. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddDoDumpBlif"></A> -static int <I></I> -<B>ddDoDumpBlif</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - FILE * <b>fp</b>, <i></i> - st_table * <b>visited</b>, <i></i> - char ** <b>names</b>, <i></i> - int <b>mv</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_DumpBlif. Traverses - the BDD f and writes a multiplexer-network description to the file - pointed by fp in blif format. f is assumed to be a regular pointer - and ddDoDumpBlif guarantees this assumption in the recursive calls. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExport.c"TARGET="ABSTRACT"><CODE>cuddExport.c</CODE></A> - -<dt><pre> -<A NAME="ddDoDumpDDcal"></A> -static int <I></I> -<B>ddDoDumpDDcal</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - FILE * <b>fp</b>, <i></i> - st_table * <b>visited</b>, <i></i> - char ** <b>names</b>, <i></i> - ptruint <b>mask</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_DumpDDcal. Traverses - the BDD f and writes a line for each node to the file - pointed by fp in DDcal format. f is assumed to be a regular pointer - and ddDoDumpDDcal guarantees this assumption in the recursive calls. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExport.c"TARGET="ABSTRACT"><CODE>cuddExport.c</CODE></A> - -<dt><pre> -<A NAME="ddDoDumpDaVinci"></A> -static int <I></I> -<B>ddDoDumpDaVinci</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - FILE * <b>fp</b>, <i></i> - st_table * <b>visited</b>, <i></i> - char ** <b>names</b>, <i></i> - ptruint <b>mask</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_DumpDaVinci. Traverses - the BDD f and writes a term expression to the file - pointed by fp in daVinci format. f is assumed to be a regular pointer - and ddDoDumpDaVinci guarantees this assumption in the recursive calls. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExport.c"TARGET="ABSTRACT"><CODE>cuddExport.c</CODE></A> - -<dt><pre> -<A NAME="ddDoDumpFactoredForm"></A> -static int <I></I> -<B>ddDoDumpFactoredForm</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - FILE * <b>fp</b>, <i></i> - char ** <b>names</b> <i></i> -) -</pre> -<dd> Performs the recursive step of - Cudd_DumpFactoredForm. Traverses the BDD f and writes a factored - form for each node to the file pointed by fp in terms of the - factored forms of the children. Constants are propagated, and - absorption is applied. f is assumed to be a regular pointer and - ddDoDumpFActoredForm guarantees this assumption in the recursive - calls. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_DumpFactoredForm">Cudd_DumpFactoredForm</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExport.c"TARGET="ABSTRACT"><CODE>cuddExport.c</CODE></A> - -<dt><pre> -<A NAME="ddEpdCountMintermAux"></A> -static int <I></I> -<B>ddEpdCountMintermAux</B>( - DdNode * <b>node</b>, <i></i> - EpDouble * <b>max</b>, <i></i> - EpDouble * <b>epd</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_EpdCountMinterm. - It is based on the following identity. Let |f| be the - number of minterms of f. Then: - <xmp> - |f| = (|f0|+|f1|)/2 - </xmp> - where f0 and f1 are the two cofactors of f. Does not use the - identity |f'| = max - |f|, to minimize loss of accuracy due to - roundoff. Returns the number of minterms of the function rooted at - node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddEpdFree"></A> -static enum st_retval <I></I> -<B>ddEpdFree</B>( - char * <b>key</b>, <i></i> - char * <b>value</b>, <i></i> - char * <b>arg</b> <i></i> -) -</pre> -<dd> Frees the memory used to store the minterm counts - recorded in the visited table. Returns ST_CONTINUE. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddExchange"></A> -static int <I></I> -<B>ddExchange</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b>, <i></i> - double <b>temp</b> <i></i> -) -</pre> -<dd> This is the same funcion as ddSwapping except for - comparison expression. Use probability function, exp(-size_change/temp). -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAnneal.c"TARGET="ABSTRACT"><CODE>cuddAnneal.c</CODE></A> - -<dt><pre> -<A NAME="ddExtSymmCheck"></A> -static int <I></I> -<B>ddExtSymmCheck</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Checks for extended symmetry of x and y. Returns 1 in - case of extended symmetry; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddFindEssentialRecur"></A> -static DdNode * <I></I> -<B>ddFindEssentialRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Implements the recursive step of Cudd_FindEssential. - Returns a pointer to the cube BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="ddFindNodeHiLo"></A> -static void <I></I> -<B>ddFindNodeHiLo</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b>, <i></i> - int * <b>lower</b>, <i></i> - int * <b>upper</b> <i></i> -) -</pre> -<dd> Finds the lower and upper bounds of the group - represented by treenode. From the index and size fields we need to - derive the current positions, and find maximum and minimum. -<p> - -<dd> <b>Side Effects</b> The bounds are returned as side effects. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddFindSupport"></A> -static void <I></I> -<B>ddFindSupport</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - int * <b>SP</b> <i></i> -) -</pre> -<dd> Recursively find the support of f. This function uses the - LSB of the next field of the nodes of f as visited flag. It also uses the - LSB of the next field of the variables as flag to remember whether a - certain index has already been seen. Finally, it uses the manager stack - to record all seen indices. -<p> - -<dd> <b>Side Effects</b> The stack pointer SP is modified by side-effect. The next - fields are changed and need to be reset. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddFindTwoLiteralClausesRecur"></A> -static DdTlcInfo * <I></I> -<B>ddFindTwoLiteralClausesRecur</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Implements the recursive step of - Cudd_FindTwoLiteralClauses. The DD node is assumed to be not - constant. Returns a pointer to a set of clauses if successful; NULL - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_FindTwoLiteralClauses">Cudd_FindTwoLiteralClauses</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="ddGetLargestCubeUnate"></A> -static DdNode * <I></I> -<B>ddGetLargestCubeUnate</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - int * <b>phases</b>, <i></i> - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Extracts largest prime of a unate function. Returns the BDD of - the prime if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#getPath">getPath</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSat.c"TARGET="ABSTRACT"><CODE>cuddSat.c</CODE></A> - -<dt><pre> -<A NAME="ddGroupMoveBackward"></A> -static int <I></I> -<B>ddGroupMoveBackward</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Undoes the swap two groups. Returns 1 in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddGroupMove"></A> -static int <I></I> -<B>ddGroupMove</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b>, <i></i> - Move ** <b>moves</b> <i></i> -) -</pre> -<dd> Swaps two groups and records the move. Returns the - number of keys in the DD table in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddGroupSiftingAux"></A> -static int <I></I> -<B>ddGroupSiftingAux</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xLow</b>, <i></i> - int <b>xHigh</b>, <i></i> - DD_CHKFP <b>checkFunction</b>, <i></i> - int <b>lazyFlag</b> <i></i> -) -</pre> -<dd> Sifts one variable up and down until it has taken all - positions. Checks for aggregation. There may be at most two sweeps, - even if the group grows. Assumes that x is either an isolated - variable, or it is the bottom of a group. All groups may not have - been found. The variable being moved is returned to the best position - seen during sifting. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddGroupSiftingBackward"></A> -static int <I></I> -<B>ddGroupSiftingBackward</B>( - DdManager * <b>table</b>, <i></i> - Move * <b>moves</b>, <i></i> - int <b>size</b>, <i></i> - int <b>upFlag</b>, <i></i> - int <b>lazyFlag</b> <i></i> -) -</pre> -<dd> Determines the best position for a variables and returns - it there. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddGroupSiftingDown"></A> -static int <I></I> -<B>ddGroupSiftingDown</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xHigh</b>, <i></i> - DD_CHKFP <b>checkFunction</b>, <i></i> - Move ** <b>moves</b> <i></i> -) -</pre> -<dd> Sifts down a variable until it reaches position xHigh. - Assumes that x is the bottom of a group (or a singleton). Records - all the moves. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddGroupSiftingUp"></A> -static int <I></I> -<B>ddGroupSiftingUp</B>( - DdManager * <b>table</b>, <i></i> - int <b>y</b>, <i></i> - int <b>xLow</b>, <i></i> - DD_CHKFP <b>checkFunction</b>, <i></i> - Move ** <b>moves</b> <i></i> -) -</pre> -<dd> Sifts up a variable until either it reaches position - xLow or the size of the DD heap increases too much. Assumes that y is - the top of a group (or a singleton). Checks y for aggregation to the - adjacent variables. Records all the moves that are appended to the - list of moves received as input and returned as a side effect. - Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddGroupSifting"></A> -static int <I></I> -<B>ddGroupSifting</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b>, <i></i> - DD_CHKFP <b>checkFunction</b>, <i></i> - int <b>lazyFlag</b> <i></i> -) -</pre> -<dd> Sifts from treenode->low to treenode->high. If - croupcheck == CUDD_GROUP_CHECK7, it checks for group creation at the - end of the initial sifting. If a group is created, it is then sifted - again. After sifting one variable, the group that contains it is - dissolved. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddIsVarHandled"></A> -static int <I></I> -<B>ddIsVarHandled</B>( - DdManager * <b>dd</b>, <i></i> - int <b>index</b> <i></i> -) -</pre> -<dd> Checks whether a variables is already handled. This - function is used for lazy sifting. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddJumpingAux"></A> -static int <I></I> -<B>ddJumpingAux</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>x_low</b>, <i></i> - int <b>x_high</b>, <i></i> - double <b>temp</b> <i></i> -) -</pre> -<dd> If x==x_low, it executes jumping_down. If x==x_high, it - executes jumping_up. This funcion is similar to ddSiftingAux. Returns - 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAnneal.c"TARGET="ABSTRACT"><CODE>cuddAnneal.c</CODE></A> - -<dt><pre> -<A NAME="ddJumpingDown"></A> -static Move * <I></I> -<B>ddJumpingDown</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>x_high</b>, <i></i> - int <b>initial_size</b> <i></i> -) -</pre> -<dd> This is a simplified version of ddSiftingDown. It does not - use lower bounding. Returns the set of moves in case of success; NULL - if memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAnneal.c"TARGET="ABSTRACT"><CODE>cuddAnneal.c</CODE></A> - -<dt><pre> -<A NAME="ddJumpingUp"></A> -static Move * <I></I> -<B>ddJumpingUp</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>x_low</b>, <i></i> - int <b>initial_size</b> <i></i> -) -</pre> -<dd> This is a simplified version of ddSiftingUp. It does not - use lower bounding. Returns the set of moves in case of success; NULL - if memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAnneal.c"TARGET="ABSTRACT"><CODE>cuddAnneal.c</CODE></A> - -<dt><pre> -<A NAME="ddLeavesInt"></A> -static int <I></I> -<B>ddLeavesInt</B>( - DdNode * <b>n</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_CountLeaves. Returns - the number of leaves in the DD rooted at n. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_CountLeaves">Cudd_CountLeaves</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddLinearAndSiftingAux"></A> -static int <I></I> -<B>ddLinearAndSiftingAux</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xLow</b>, <i></i> - int <b>xHigh</b> <i></i> -) -</pre> -<dd> Given xLow <= x <= xHigh moves x up and down between the - boundaries. At each step a linear transformation is tried, and, if it - decreases the size of the DD, it is accepted. Finds the best position - and does the required changes. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="ddLinearAndSiftingBackward"></A> -static int <I></I> -<B>ddLinearAndSiftingBackward</B>( - DdManager * <b>table</b>, <i></i> - int <b>size</b>, <i></i> - Move * <b>moves</b> <i></i> -) -</pre> -<dd> Given a set of moves, returns the DD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="ddLinearAndSiftingDown"></A> -static Move * <I></I> -<B>ddLinearAndSiftingDown</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xHigh</b>, <i></i> - Move * <b>prevMoves</b> <i></i> -) -</pre> -<dd> Sifts a variable down and applies linear - transformations. Moves x down until either it reaches the bound - (xHigh) or the size of the DD heap increases too much. Returns the - set of moves in case of success; NULL if memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="ddLinearAndSiftingUp"></A> -static Move * <I></I> -<B>ddLinearAndSiftingUp</B>( - DdManager * <b>table</b>, <i></i> - int <b>y</b>, <i></i> - int <b>xLow</b>, <i></i> - Move * <b>prevMoves</b> <i></i> -) -</pre> -<dd> Sifts a variable up and applies linear transformations. - Moves y up until either it reaches the bound (xLow) or the size of - the DD heap increases too much. Returns the set of moves in case of - success; NULL if memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="ddLinearUniqueCompare"></A> -static int <I></I> -<B>ddLinearUniqueCompare</B>( - int * <b>ptrX</b>, <i></i> - int * <b>ptrY</b> <i></i> -) -</pre> -<dd> Comparison function used by qsort to order the - variables according to the number of keys in the subtables. - Returns the difference in number of keys between the two - variables being compared. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="ddMergeGroups"></A> -static void <I></I> -<B>ddMergeGroups</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b>, <i></i> - int <b>low</b>, <i></i> - int <b>high</b> <i></i> -) -</pre> -<dd> Creates a single group from low to high and adjusts the - index field of the tree node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddNoCheck"></A> -static int <I></I> -<B>ddNoCheck</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Pretends to check two variables for aggregation. Always - returns 0. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddPatchTree"></A> -static void <I></I> -<B>ddPatchTree</B>( - DdManager * <b>dd</b>, <i></i> - MtrNode * <b>treenode</b> <i></i> -) -</pre> -<dd> Fixes a variable tree after the insertion of new subtables. - After such an insertion, the low fields of the tree below the insertion - point are inconsistent. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="ddPermuteWindow3"></A> -static int <I></I> -<B>ddPermuteWindow3</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b> <i></i> -) -</pre> -<dd> Tries all the permutations of the three variables between - x and x+2 and retains the best. Assumes that no dead nodes are - present. Returns the index of the best permutation (1-6) in case of - success; 0 otherwise.Assumes that no dead nodes are present. Returns - the index of the best permutation (1-6) in case of success; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddWindow.c"TARGET="ABSTRACT"><CODE>cuddWindow.c</CODE></A> - -<dt><pre> -<A NAME="ddPermuteWindow4"></A> -static int <I></I> -<B>ddPermuteWindow4</B>( - DdManager * <b>table</b>, <i></i> - int <b>w</b> <i></i> -) -</pre> -<dd> Tries all the permutations of the four variables between - w and w+3 and retains the best. Assumes that no dead nodes are - present. Returns the index of the best permutation (1-24) in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddWindow.c"TARGET="ABSTRACT"><CODE>cuddWindow.c</CODE></A> - -<dt><pre> -<A NAME="ddPickArbitraryMinterms"></A> -static int <I></I> -<B>ddPickArbitraryMinterms</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>node</b>, <i></i> - int <b>nvars</b>, <i></i> - int <b>nminterms</b>, <i></i> - char ** <b>string</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_bddPickArbitraryMinterms. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_bddPickArbitraryMinterms">Cudd_bddPickArbitraryMinterms</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddPickRepresentativeCube"></A> -static int <I></I> -<B>ddPickRepresentativeCube</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>node</b>, <i></i> - double * <b>weight</b>, <i></i> - char * <b>string</b> <i></i> -) -</pre> -<dd> Finds a representative cube of a BDD with the weight of - each variable. From the top variable, if the weight is greater than or - equal to 0.0, choose THEN branch unless the child is the constant 0. - Otherwise, choose ELSE branch unless the child is the constant 0. -<p> - -<dd> <b>Side Effects</b> Cudd_SubsetWithMaskVars Cudd_bddPickOneCube -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddPrintMintermAux"></A> -static void <I></I> -<B>ddPrintMintermAux</B>( - DdManager * <b>dd</b>, <i>manager</i> - DdNode * <b>node</b>, <i>current node</i> - int * <b>list</b> <i>current recursion path</i> -) -</pre> -<dd> Performs the recursive step of Cudd_PrintMinterm. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddRehashZdd"></A> -static void <I></I> -<B>ddRehashZdd</B>( - DdManager * <b>unique</b>, <i></i> - int <b>i</b> <i></i> -) -</pre> -<dd> Rehashes a ZDD unique subtable. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddRehash">cuddRehash</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="ddReorderChildren"></A> -static int <I></I> -<B>ddReorderChildren</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b>, <i></i> - Cudd_ReorderingType <b>method</b> <i></i> -) -</pre> -<dd> Reorders the children of a group tree node according to - the options. After reordering puts all the variables in the group - and/or its descendents in a single group. This allows hierarchical - reordering. If the variables in the group do not exist yet, simply - does nothing. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddReorderPostprocess"></A> -static int <I></I> -<B>ddReorderPostprocess</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Cleans up at the end of reordering. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddReorderPreprocess"></A> -static int <I></I> -<B>ddReorderPreprocess</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Prepares the DD heap for dynamic reordering. Does - garbage collection, to guarantee that there are no dead nodes; - clears the cache, which is invalidated by dynamic reordering; initializes - the number of isolated projection functions; and initializes the - interaction matrix. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddReportRefMess"></A> -static void <I></I> -<B>ddReportRefMess</B>( - DdManager * <b>unique</b>, <i>manager</i> - int <b>i</b>, <i>table in which the problem occurred</i> - const char * <b>caller</b> <i>procedure that detected the problem</i> -) -</pre> -<dd> Reports problem in garbage collection. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddGarbageCollect">cuddGarbageCollect</a> -<a href="#cuddGarbageCollectZdd">cuddGarbageCollectZdd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="ddResetVarHandled"></A> -static int <I></I> -<B>ddResetVarHandled</B>( - DdManager * <b>dd</b>, <i></i> - int <b>index</b> <i></i> -) -</pre> -<dd> Resets a variable to be processed. This function is used - for lazy sifting. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddResizeTable"></A> -static int <I></I> -<B>ddResizeTable</B>( - DdManager * <b>unique</b>, <i></i> - int <b>index</b>, <i></i> - int <b>amount</b> <i></i> -) -</pre> -<dd> Increases the number of subtables in a unique table so - that it meets or exceeds index. The parameter amount determines how - much spare space is allocated to prevent too frequent resizing. If - index is negative, the table is resized, but no new variables are - created. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_Reserve">Cudd_Reserve</a> -<a href="#cuddResizeTableZdd">cuddResizeTableZdd</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME="ddSecDiffCheck"></A> -static int <I></I> -<B>ddSecDiffCheck</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Checks two variables for aggregation. The check is based - on the second difference of the number of nodes as a function of the - layer. If the second difference is lower than a given threshold - (typically negative) then the two variables should be aggregated. - Returns 1 if the two variables pass the test; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddSetVarHandled"></A> -static int <I></I> -<B>ddSetVarHandled</B>( - DdManager * <b>dd</b>, <i></i> - int <b>index</b> <i></i> -) -</pre> -<dd> Sets a variable to already handled. This function is used - for lazy sifting. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddShuffle"></A> -static int <I></I> -<B>ddShuffle</B>( - DdManager * <b>table</b>, <i></i> - DdHalfWord * <b>permutation</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Reorders variables according to a given permutation. - The i-th permutation array contains the index of the variable that - should be brought to the i-th level. ddShuffle assumes that no - dead nodes are present and that the interaction matrix is properly - initialized. The reordering is achieved by a series of upward sifts. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="ddShuffle"></A> -static int <I></I> -<B>ddShuffle</B>( - DdManager * <b>table</b>, <i></i> - int * <b>permutation</b> <i></i> -) -</pre> -<dd> Reorders variables according to a given permutation. - The i-th permutation array contains the index of the variable that - should be brought to the i-th level. ddShuffle assumes that no - dead nodes are present and that the interaction matrix is properly - initialized. The reordering is achieved by a series of upward sifts. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddSiftUp"></A> -static int <I></I> -<B>ddSiftUp</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xLow</b> <i></i> -) -</pre> -<dd> Takes a variable from position x and sifts it up to - position xLow; xLow should be less than or equal to x. - Returns 1 if successful; 0 otherwise -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="ddSiftUp"></A> -static int <I></I> -<B>ddSiftUp</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xLow</b> <i></i> -) -</pre> -<dd> Takes a variable from position x and sifts it up to - position xLow; xLow should be less than or equal to x. - Returns 1 if successful; 0 otherwise -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddSiftingAux"></A> -static int <I></I> -<B>ddSiftingAux</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xLow</b>, <i></i> - int <b>xHigh</b> <i></i> -) -</pre> -<dd> Given xLow <= x <= xHigh moves x up and down between the - boundaries. Finds the best position and does the required changes. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddSiftingBackward"></A> -static int <I></I> -<B>ddSiftingBackward</B>( - DdManager * <b>table</b>, <i></i> - int <b>size</b>, <i></i> - Move * <b>moves</b> <i></i> -) -</pre> -<dd> Given a set of moves, returns the DD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddSiftingDown"></A> -static Move * <I></I> -<B>ddSiftingDown</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xHigh</b> <i></i> -) -</pre> -<dd> Sifts a variable down. Moves x down until either it - reaches the bound (xHigh) or the size of the DD heap increases too - much. Returns the set of moves in case of success; NULL if memory is - full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddSiftingUp"></A> -static Move * <I></I> -<B>ddSiftingUp</B>( - DdManager * <b>table</b>, <i></i> - int <b>y</b>, <i></i> - int <b>xLow</b> <i></i> -) -</pre> -<dd> Sifts a variable up. Moves y up until either it reaches - the bound (xLow) or the size of the DD heap increases too much. - Returns the set of moves in case of success; NULL if memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddSuppInteract"></A> -static void <I></I> -<B>ddSuppInteract</B>( - DdNode * <b>f</b>, <i></i> - char * <b>support</b> <i></i> -) -</pre> -<dd> Performs a DFS from f. Uses the LSB of the then pointer - as visited flag. -<p> - -<dd> <b>Side Effects</b> Accumulates in support the variables on which f depends. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddInteract.c"TARGET="ABSTRACT"><CODE>cuddInteract.c</CODE></A> - -<dt><pre> -<A NAME="ddSupportStep"></A> -static void <I></I> -<B>ddSupportStep</B>( - DdNode * <b>f</b>, <i></i> - int * <b>support</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_Support. Performs a - DFS from f. The support is accumulated in supp as a side effect. Uses - the LSB of the then pointer as visited flag. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#ddClearFlag">ddClearFlag</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="ddSwapAny"></A> -static Move * <I></I> -<B>ddSwapAny</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Swaps any two variables. Returns the set of moves. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddSymmGroupMoveBackward"></A> -static int <I></I> -<B>ddSymmGroupMoveBackward</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Undoes the swap of two groups. x is assumed to be the - bottom variable of the first group. y is assumed to be the top - variable of the second group. Returns the number of keys in the table - if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="ddSymmGroupMove"></A> -static int <I></I> -<B>ddSymmGroupMove</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b>, <i></i> - Move ** <b>moves</b> <i></i> -) -</pre> -<dd> Swaps two groups. x is assumed to be the bottom variable - of the first group. y is assumed to be the top variable of the second - group. Updates the list of moves. Returns the number of keys in the - table if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="ddSymmSiftingAux"></A> -static int <I></I> -<B>ddSymmSiftingAux</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xLow</b>, <i></i> - int <b>xHigh</b> <i></i> -) -</pre> -<dd> Given xLow <= x <= xHigh moves x up and down between the - boundaries. Finds the best position and does the required changes. - Assumes that x is not part of a symmetry group. Returns 1 if - successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="ddSymmSiftingBackward"></A> -static int <I></I> -<B>ddSymmSiftingBackward</B>( - DdManager * <b>table</b>, <i></i> - Move * <b>moves</b>, <i></i> - int <b>size</b> <i></i> -) -</pre> -<dd> Given a set of moves, returns the DD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="ddSymmSiftingConvAux"></A> -static int <I></I> -<B>ddSymmSiftingConvAux</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xLow</b>, <i></i> - int <b>xHigh</b> <i></i> -) -</pre> -<dd> Given xLow <= x <= xHigh moves x up and down between the - boundaries. Finds the best position and does the required changes. - Assumes that x is either an isolated variable, or it is the bottom of - a symmetry group. All symmetries may not have been found, because of - exceeded growth limit. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="ddSymmSiftingDown"></A> -static Move * <I></I> -<B>ddSymmSiftingDown</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xHigh</b> <i></i> -) -</pre> -<dd> Moves x down until either it reaches the bound (xHigh) - or the size of the DD heap increases too much. Assumes that x is the - bottom of a symmetry group. Checks x for symmetry to the adjacent - variables. If symmetry is found, the symmetry group of x is merged - with the symmetry group of the other variable. Returns the set of - moves in case of success; MV_OOM if memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="ddSymmSiftingUp"></A> -static Move * <I></I> -<B>ddSymmSiftingUp</B>( - DdManager * <b>table</b>, <i></i> - int <b>y</b>, <i></i> - int <b>xLow</b> <i></i> -) -</pre> -<dd> Moves x up until either it reaches the bound (xLow) or - the size of the DD heap increases too much. Assumes that x is the top - of a symmetry group. Checks x for symmetry to the adjacent - variables. If symmetry is found, the symmetry group of x is merged - with the symmetry group of the other variable. Returns the set of - moves in case of success; MV_OOM if memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="ddSymmSummary"></A> -static void <I></I> -<B>ddSymmSummary</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b>, <i></i> - int * <b>symvars</b>, <i></i> - int * <b>symgroups</b> <i></i> -) -</pre> -<dd> Counts numbers of symmetric variables and symmetry - groups. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="ddSymmUniqueCompare"></A> -static int <I></I> -<B>ddSymmUniqueCompare</B>( - int * <b>ptrX</b>, <i></i> - int * <b>ptrY</b> <i></i> -) -</pre> -<dd> Comparison function used by qsort to order the variables - according to the number of keys in the subtables. - Returns the difference in number of keys between the two - variables being compared. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSymmetry.c"TARGET="ABSTRACT"><CODE>cuddSymmetry.c</CODE></A> - -<dt><pre> -<A NAME="ddTreeSiftingAux"></A> -static int <I></I> -<B>ddTreeSiftingAux</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b>, <i></i> - Cudd_ReorderingType <b>method</b> <i></i> -) -</pre> -<dd> Recursively visits the group tree and reorders each - group in postorder fashion. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddUndoMoves"></A> -static Move* <I></I> -<B>ddUndoMoves</B>( - DdManager * <b>table</b>, <i></i> - Move * <b>moves</b> <i></i> -) -</pre> -<dd> Given a set of moves, returns the DD heap to the - order in effect before the moves. Returns 1 in case of success; - 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLinear.c"TARGET="ABSTRACT"><CODE>cuddLinear.c</CODE></A> - -<dt><pre> -<A NAME="ddUniqueCompareGroup"></A> -static int <I></I> -<B>ddUniqueCompareGroup</B>( - int * <b>ptrX</b>, <i></i> - int * <b>ptrY</b> <i></i> -) -</pre> -<dd> Comparison function used by qsort to order the variables - according to the number of keys in the subtables. Returns the - difference in number of keys between the two variables being - compared. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddUniqueCompare"></A> -static int <I></I> -<B>ddUniqueCompare</B>( - int * <b>ptrX</b>, <i></i> - int * <b>ptrY</b> <i></i> -) -</pre> -<dd> Comparison function used by qsort to order the - variables according to the number of keys in the subtables. - Returns the difference in number of keys between the two - variables being compared. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddUpdateInteract"></A> -static void <I></I> -<B>ddUpdateInteract</B>( - DdManager * <b>table</b>, <i></i> - char * <b>support</b> <i></i> -) -</pre> -<dd> If support[i -<p> - -<dd> <b>Side Effects</b> Clears support. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddInteract.c"TARGET="ABSTRACT"><CODE>cuddInteract.c</CODE></A> - -<dt><pre> -<A NAME="ddUpdateMtrTree"></A> -static int <I></I> -<B>ddUpdateMtrTree</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b>, <i></i> - int * <b>perm</b>, <i></i> - int * <b>invperm</b> <i></i> -) -</pre> -<dd> Updates the BDD variable group tree before a shuffle. - Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Changes the BDD variable group tree. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddReorder.c"TARGET="ABSTRACT"><CODE>cuddReorder.c</CODE></A> - -<dt><pre> -<A NAME="ddVarGroupCheck"></A> -static int <I></I> -<B>ddVarGroupCheck</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Checks for grouping of x and y. Returns 1 in - case of grouping; 0 otherwise. This function is used for lazy sifting. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGroup.c"TARGET="ABSTRACT"><CODE>cuddGroup.c</CODE></A> - -<dt><pre> -<A NAME="ddWindow2"></A> -static int <I></I> -<B>ddWindow2</B>( - DdManager * <b>table</b>, <i></i> - int <b>low</b>, <i></i> - int <b>high</b> <i></i> -) -</pre> -<dd> Reorders by applying a sliding window of width 2. - Tries both permutations of the variables in a window - that slides from low to high. Assumes that no dead nodes are - present. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddWindow.c"TARGET="ABSTRACT"><CODE>cuddWindow.c</CODE></A> - -<dt><pre> -<A NAME="ddWindow3"></A> -static int <I></I> -<B>ddWindow3</B>( - DdManager * <b>table</b>, <i></i> - int <b>low</b>, <i></i> - int <b>high</b> <i></i> -) -</pre> -<dd> Reorders by applying a sliding window of width 3. - Tries all possible permutations to the variables in a - window that slides from low to high. Assumes that no dead nodes are - present. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddWindow.c"TARGET="ABSTRACT"><CODE>cuddWindow.c</CODE></A> - -<dt><pre> -<A NAME="ddWindow4"></A> -static int <I></I> -<B>ddWindow4</B>( - DdManager * <b>table</b>, <i></i> - int <b>low</b>, <i></i> - int <b>high</b> <i></i> -) -</pre> -<dd> Reorders by applying a sliding window of width 4. - Tries all possible permutations to the variables in a - window that slides from low to high. Assumes that no dead nodes are - present. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddWindow.c"TARGET="ABSTRACT"><CODE>cuddWindow.c</CODE></A> - -<dt><pre> -<A NAME="ddWindowConv2"></A> -static int <I></I> -<B>ddWindowConv2</B>( - DdManager * <b>table</b>, <i></i> - int <b>low</b>, <i></i> - int <b>high</b> <i></i> -) -</pre> -<dd> Reorders by repeatedly applying a sliding window of width - 2. Tries both permutations of the variables in a window - that slides from low to high. Assumes that no dead nodes are - present. Uses an event-driven approach to determine convergence. - Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddWindow.c"TARGET="ABSTRACT"><CODE>cuddWindow.c</CODE></A> - -<dt><pre> -<A NAME="ddWindowConv3"></A> -static int <I></I> -<B>ddWindowConv3</B>( - DdManager * <b>table</b>, <i></i> - int <b>low</b>, <i></i> - int <b>high</b> <i></i> -) -</pre> -<dd> Reorders by repeatedly applying a sliding window of width - 3. Tries all possible permutations to the variables in a - window that slides from low to high. Assumes that no dead nodes are - present. Uses an event-driven approach to determine convergence. - Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddWindow.c"TARGET="ABSTRACT"><CODE>cuddWindow.c</CODE></A> - -<dt><pre> -<A NAME="ddWindowConv4"></A> -static int <I></I> -<B>ddWindowConv4</B>( - DdManager * <b>table</b>, <i></i> - int <b>low</b>, <i></i> - int <b>high</b> <i></i> -) -</pre> -<dd> Reorders by repeatedly applying a sliding window of width - 4. Tries all possible permutations to the variables in a - window that slides from low to high. Assumes that no dead nodes are - present. Uses an event-driven approach to determine convergence. - Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddWindow.c"TARGET="ABSTRACT"><CODE>cuddWindow.c</CODE></A> - -<dt><pre> -<A NAME="debugCheckParent"></A> -static void <I></I> -<B>debugCheckParent</B>( - DdManager * <b>table</b>, <i></i> - DdNode * <b>node</b> <i></i> -) -</pre> -<dd> Searches all the subtables above node. Very expensive. - The same check is now implemented more efficiently in ddDebugCheck. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#debugFindParent">debugFindParent</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCheck.c"TARGET="ABSTRACT"><CODE>cuddCheck.c</CODE></A> - -<dt><pre> -<A NAME="debugFindParent"></A> -static void <I></I> -<B>debugFindParent</B>( - DdManager * <b>table</b>, <i></i> - DdNode * <b>node</b> <i></i> -) -</pre> -<dd> Searches the subtables above node for its parents. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCheck.c"TARGET="ABSTRACT"><CODE>cuddCheck.c</CODE></A> - -<dt><pre> -<A NAME="double *�prob�"></A> - <I></I> -<B>double *�prob�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �mg�"></A> - <I></I> -<B>double �mg�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �mg�"></A> - <I></I> -<B>double �mg�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �m�"></A> - <I></I> -<B>double �m�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality0�minimum improvement for accepted changes when b=0"></A> - <I></I> -<B>double �quality0�minimum improvement for accepted changes when b=0</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality0�minimum improvement for accepted changes when b=0"></A> - <I></I> -<B>double �quality0�minimum improvement for accepted changes when b=0</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality�minimum improvement for accepted changes"></A> - <I></I> -<B>double �quality�minimum improvement for accepted changes</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality�minimum improvement for accepted changes"></A> - <I></I> -<B>double �quality�minimum improvement for accepted changes</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality�minimum improvement for accepted changes"></A> - <I></I> -<B>double �quality�minimum improvement for accepted changes</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality�minimum improvement for accepted changes"></A> - <I></I> -<B>double �quality�minimum improvement for accepted changes</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="dp2"></A> -static int <I></I> -<B>dp2</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - st_table * <b>t</b> <i></i> -) -</pre> -<dd> Performs the recursive step of cuddP. Returns 1 in case - of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="emptyClauseSet"></A> -static DdTlcInfo * <I></I> -<B>emptyClauseSet</B>( - <b></b> <i></i> -) -</pre> -<dd> Returns a pointer to an empty set of clauses if - successful; NULL otherwise. No bit vector for the phases is - allocated. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="equalp"></A> -static int <I></I> -<B>equalp</B>( - DdHalfWord <b>var1a</b>, <i></i> - short <b>phase1a</b>, <i></i> - DdHalfWord <b>var1b</b>, <i></i> - short <b>phase1b</b>, <i></i> - DdHalfWord <b>var2a</b>, <i></i> - short <b>phase2a</b>, <i></i> - DdHalfWord <b>var2b</b>, <i></i> - short <b>phase2b</b> <i></i> -) -</pre> -<dd> Returns true iff the two arguments are identical - clauses. Since literals are sorted, we only need to compare - literals in the same position. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#beforep">beforep</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="find_best"></A> -static int <I></I> -<B>find_best</B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the index of the fittest individual. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME="fixVarTree"></A> -static void <I></I> -<B>fixVarTree</B>( - MtrNode * <b>treenode</b>, <i></i> - int * <b>perm</b>, <i></i> - int <b>size</b> <i></i> -) -</pre> -<dd> Fixes a variable group tree. -<p> - -<dd> <b>Side Effects</b> Changes the variable group tree. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAPI.c"TARGET="ABSTRACT"><CODE>cuddAPI.c</CODE></A> - -<dt><pre> -<A NAME="freeMatrix"></A> -static void <I></I> -<B>freeMatrix</B>( - DdHalfWord ** <b>matrix</b> <i></i> -) -</pre> -<dd> Frees a two-dimensional matrix allocated by getMatrix. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#getMatrix">getMatrix</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="freePathPair"></A> -static enum st_retval <I></I> -<B>freePathPair</B>( - char * <b>key</b>, <i></i> - char * <b>value</b>, <i></i> - char * <b>arg</b> <i></i> -) -</pre> -<dd> Frees the entries of the visited symbol table. Returns - ST_CONTINUE. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSat.c"TARGET="ABSTRACT"><CODE>cuddSat.c</CODE></A> - -<dt><pre> -<A NAME="gatherInfoAux"></A> -static NodeData * <I></I> -<B>gatherInfoAux</B>( - DdNode * <b>node</b>, <i>function to analyze</i> - ApproxInfo * <b>info</b>, <i>info on BDD</i> - int <b>parity</b> <i>gather parity information</i> -) -</pre> -<dd> Recursively counts minterms and computes reference - counts of each node in the BDD. Similar to the cuddCountMintermAux - which recursively counts the number of minterms for the dag rooted - at each node in terms of the total number of variables (max). It assumes - that the node pointer passed to it is regular and it maintains the - invariant. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#gatherInfo">gatherInfo</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="gatherInfo"></A> -static ApproxInfo * <I></I> -<B>gatherInfo</B>( - DdManager * <b>dd</b>, <i>manager</i> - DdNode * <b>node</b>, <i>function to be analyzed</i> - int <b>numVars</b>, <i>number of variables node depends on</i> - int <b>parity</b> <i>gather parity information</i> -) -</pre> -<dd> Counts minterms and computes reference counts of each - node in the BDD. The minterm count is separately computed for the - node and its complement. This is to avoid cancellation - errors. Returns a pointer to the data structure holding the - information gathered if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddUnderApprox">cuddUnderApprox</a> -<a href="#gatherInfoAux">gatherInfoAux</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="gcd"></A> -static int <I></I> -<B>gcd</B>( - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Returns the gcd of two integers. Uses the binary GCD - algorithm described in Cormen, Leiserson, and Rivest. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="getCube"></A> -static DdNode * <I></I> -<B>getCube</B>( - DdManager * <b>manager</b>, <i></i> - st_table * <b>visited</b>, <i></i> - DdNode * <b>f</b>, <i></i> - int <b>cost</b> <i></i> -) -</pre> -<dd> Build a BDD for a largest cube of f. - Given the minimum length from the root, and the minimum - lengths for each node (in visited), apply triangulation at each node. - Of the two children of each node on a shortest path, at least one is - on a shortest path. In case of ties the procedure chooses the THEN - children. - Returns a pointer to the cube BDD representing the path if - successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSat.c"TARGET="ABSTRACT"><CODE>cuddSat.c</CODE></A> - -<dt><pre> -<A NAME="getLargest"></A> -static cuddPathPair <I></I> -<B>getLargest</B>( - DdNode * <b>root</b>, <i></i> - st_table * <b>visited</b> <i></i> -) -</pre> -<dd> Finds the size of the largest cube(s) in a DD. - This problem is translated into finding the shortest paths from a node - when both THEN and ELSE arcs have unit lengths. - Uses a local symbol table to store the lengths for each - node. Only the lengths for the regular nodes are entered in the table, - because those for the complement nodes are simply obtained by swapping - the two lenghts. - Returns a pair of lengths: the length of the shortest path to 1; - and the length of the shortest path to 0. This is done so as to take - complement arcs into account. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSat.c"TARGET="ABSTRACT"><CODE>cuddSat.c</CODE></A> - -<dt><pre> -<A NAME="getLevelKeys"></A> -static int <I></I> -<B>getLevelKeys</B>( - DdManager * <b>table</b>, <i></i> - int <b>l</b> <i></i> -) -</pre> -<dd> Returns the number of nodes at one level of a unique table. - The projection function, if isolated, is not counted. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="getMatrix"></A> -static DdHalfWord ** <I></I> -<B>getMatrix</B>( - int <b>rows</b>, <i>number of rows</i> - int <b>cols</b> <i>number of columns</i> -) -</pre> -<dd> Allocates a two-dimensional matrix of ints. - Returns the pointer to the matrix if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#freeMatrix">freeMatrix</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="getMaxBinomial"></A> -static int <I></I> -<B>getMaxBinomial</B>( - int <b>n</b> <i></i> -) -</pre> -<dd> Computes the maximum value of (n choose k) for a given - n. The maximum value occurs for k = n/2 when n is even, or k = - (n-1)/2 when n is odd. The algorithm used in this procedure avoids - intermediate overflow problems. It is based on the identity - <pre> - binomial(n,k) = n/k * binomial(n-1,k-1). - </pre> - Returns the computed value if successful; -1 if out of range. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="getPath"></A> -static DdNode * <I></I> -<B>getPath</B>( - DdManager * <b>manager</b>, <i></i> - st_table * <b>visited</b>, <i></i> - DdNode * <b>f</b>, <i></i> - int * <b>weight</b>, <i></i> - int <b>cost</b> <i></i> -) -</pre> -<dd> Build a BDD for a shortest path of f. - Given the minimum length from the root, and the minimum - lengths for each node (in visited), apply triangulation at each node. - Of the two children of each node on a shortest path, at least one is - on a shortest path. In case of ties the procedure chooses the THEN - children. - Returns a pointer to the cube BDD representing the path if - successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSat.c"TARGET="ABSTRACT"><CODE>cuddSat.c</CODE></A> - -<dt><pre> -<A NAME="getShortest"></A> -static cuddPathPair <I></I> -<B>getShortest</B>( - DdNode * <b>root</b>, <i></i> - int * <b>cost</b>, <i></i> - int * <b>support</b>, <i></i> - st_table * <b>visited</b> <i></i> -) -</pre> -<dd> Finds the length of the shortest path(s) in a DD. - Uses a local symbol table to store the lengths for each - node. Only the lengths for the regular nodes are entered in the table, - because those for the complement nodes are simply obtained by swapping - the two lenghts. - Returns a pair of lengths: the length of the shortest path to 1; - and the length of the shortest path to 0. This is done so as to take - complement arcs into account. -<p> - -<dd> <b>Side Effects</b> Accumulates the support of the DD in support. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSat.c"TARGET="ABSTRACT"><CODE>cuddSat.c</CODE></A> - -<dt><pre> -<A NAME="hashDelete"></A> -static void <I></I> -<B>hashDelete</B>( - DdLevelQueue * <b>queue</b>, <i></i> - DdQueueItem * <b>item</b> <i></i> -) -</pre> -<dd> Removes an item from the hash table of a level queue. - Nothing is done if the item is not in the table. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddLevelQueueDequeue">cuddLevelQueueDequeue</a> -<a href="#hashInsert">hashInsert</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLevelQ.c"TARGET="ABSTRACT"><CODE>cuddLevelQ.c</CODE></A> - -<dt><pre> -<A NAME="hashInsert"></A> -static int <I></I> -<B>hashInsert</B>( - DdLevelQueue * <b>queue</b>, <i></i> - DdQueueItem * <b>item</b> <i></i> -) -</pre> -<dd> Inserts an item in the hash table of a level queue. Returns - 1 if successful; 0 otherwise. No check is performed to see if an item with - the same key is already in the hash table. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddLevelQueueEnqueue">cuddLevelQueueEnqueue</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLevelQ.c"TARGET="ABSTRACT"><CODE>cuddLevelQ.c</CODE></A> - -<dt><pre> -<A NAME="hashLookup"></A> -static DdQueueItem * <I></I> -<B>hashLookup</B>( - DdLevelQueue * <b>queue</b>, <i></i> - void * <b>key</b> <i></i> -) -</pre> -<dd> Looks up a key in the hash table of a level queue. Returns - a pointer to the item with the given key if the key is found; NULL - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddLevelQueueEnqueue">cuddLevelQueueEnqueue</a> -<a href="#hashInsert">hashInsert</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLevelQ.c"TARGET="ABSTRACT"><CODE>cuddLevelQ.c</CODE></A> - -<dt><pre> -<A NAME="hashResize"></A> -static int <I></I> -<B>hashResize</B>( - DdLevelQueue * <b>queue</b> <i></i> -) -</pre> -<dd> Resizes the hash table of a level queue. Returns 1 if - successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#hashInsert">hashInsert</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLevelQ.c"TARGET="ABSTRACT"><CODE>cuddLevelQ.c</CODE></A> - -<dt><pre> -<A NAME="impliedp"></A> -static int <I></I> -<B>impliedp</B>( - DdHalfWord <b>var1</b>, <i></i> - short <b>phase1</b>, <i></i> - DdHalfWord <b>var2</b>, <i></i> - short <b>phase2</b>, <i></i> - BitVector * <b>olv</b>, <i></i> - BitVector * <b>olp</b> <i></i> -) -</pre> -<dd> Returns true iff either literal of a clause is in a set - of literals. The first four arguments specify the clause. The - remaining two arguments specify the literal set. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="indexCompare"></A> -static int <I></I> -<B>indexCompare</B>( - const void * <b>a</b>, <i></i> - const void * <b>b</b> <i></i> -) -</pre> -<dd> Compares indices for qsort. Subtracting these integers - cannot produce overflow, because they are non-negative. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddUtil.c"TARGET="ABSTRACT"><CODE>cuddUtil.c</CODE></A> - -<dt><pre> -<A NAME="initSymmInfo"></A> -static DdHalfWord * <I></I> -<B>initSymmInfo</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Translates the symmetry information stored in the next - field of each subtable from level to indices. This procedure is called - immediately after symmetric sifting, so that the next fields are correct. - By translating this informaton in terms of indices, we make it independent - of subsequent reorderings. The format used is that of the next fields: - a circular list where each variable points to the next variable in the - same symmetry group. Only the entries between lower and upper are - considered. The procedure returns a pointer to an array - holding the symmetry information if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#checkSymmInfo">checkSymmInfo</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="int **�cube�"></A> - <I></I> -<B>int **�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int **�cube�"></A> - <I></I> -<B>int **�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int **�indices�array containing (on return) the indices"></A> - <I></I> -<B>int **�indices�array containing (on return) the indices</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int **�indices�array containing (on return) the indices"></A> - <I></I> -<B>int **�indices�array containing (on return) the indices</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int **�path�"></A> - <I></I> -<B>int **�path�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int **�path�"></A> - <I></I> -<B>int **�path�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�array�"></A> - <I></I> -<B>int *�array�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�array�"></A> - <I></I> -<B>int *�array�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�digits�"></A> - <I></I> -<B>int *�digits�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�distance�"></A> - <I></I> -<B>int *�distance�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�inputs�"></A> - <I></I> -<B>int *�inputs�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�length�"></A> - <I></I> -<B>int *�length�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�length�"></A> - <I></I> -<B>int *�length�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�permutation�required variable permutation"></A> - <I></I> -<B>int *�permutation�required variable permutation</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�permutation�required variable permutation"></A> - <I></I> -<B>int *�permutation�required variable permutation</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�permut�"></A> - <I></I> -<B>int *�permut�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�permut�"></A> - <I></I> -<B>int *�permut�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�phase2�"></A> - <I></I> -<B>int *�phase2�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�weight�"></A> - <I></I> -<B>int *�weight�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �N�"></A> - <I></I> -<B>int �N�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �amount�"></A> - <I></I> -<B>int �amount�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �arcviolation�"></A> - <I></I> -<B>int �arcviolation�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �binaryDigits�"></A> - <I></I> -<B>int �binaryDigits�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �bit�"></A> - <I></I> -<B>int �bit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �bit�"></A> - <I></I> -<B>int �bit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �cycle�"></A> - <I></I> -<B>int �cycle�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �digits�"></A> - <I></I> -<B>int �digits�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �direction�under (0) or over (1) approximation"></A> - <I></I> -<B>int �direction�under (0) or over (1) approximation</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �direction�under (0) or over (1) approximation"></A> - <I></I> -<B>int �direction�under (0) or over (1) approximation</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �hardlimit�flag: 1 if threshold is a hard limit"></A> - <I></I> -<B>int �hardlimit�flag: 1 if threshold is a hard limit</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �hardlimit�flag: 1 if threshold is a hard limit"></A> - <I></I> -<B>int �hardlimit�flag: 1 if threshold is a hard limit</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �k�number of minterms to find"></A> - <I></I> -<B>int �k�number of minterms to find</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �level�"></A> - <I></I> -<B>int �level�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �level�"></A> - <I></I> -<B>int �level�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �minsize�bound below which no reordering occurs"></A> - <I></I> -<B>int �minsize�bound below which no reordering occurs</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �minsize�bound below which no reordering occurs"></A> - <I></I> -<B>int �minsize�bound below which no reordering occurs</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �multiplicity�how many ZDD variables are created for each BDD variable"></A> - <I></I> -<B>int �multiplicity�how many ZDD variables are created for each BDD variable</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �mvars�size of <code>maskVars</code>"></A> - <I></I> -<B>int �mvars�size of <code>maskVars</code></B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �mv�0: blif, 1: blif-MV"></A> - <I></I> -<B>int �mv�0: blif, 1: blif-MV</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �mv�0: blif, 1: blif-MV"></A> - <I></I> -<B>int �mv�0: blif, 1: blif-MV</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nVars�"></A> - <I></I> -<B>int �nVars�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �numberXovers�"></A> - <I></I> -<B>int �numberXovers�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nvars�"></A> - <I></I> -<B>int �nvars�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nvars�"></A> - <I></I> -<B>int �nvars�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nvars�"></A> - <I></I> -<B>int �nvars�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nvars�size of the support of f"></A> - <I></I> -<B>int �nvars�size of the support of f</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nz�"></A> - <I></I> -<B>int �nz�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nz�"></A> - <I></I> -<B>int �nz�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nz�"></A> - <I></I> -<B>int �nz�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�length of both arrays"></A> - <I></I> -<B>int �n�length of both arrays</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�numbers of unknowns"></A> - <I></I> -<B>int �n�numbers of unknowns</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�numbers of unknowns"></A> - <I></I> -<B>int �n�numbers of unknowns</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�size of <code>vars</code>"></A> - <I></I> -<B>int �n�size of <code>vars</code></B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�size of the array"></A> - <I></I> -<B>int �n�size of the array</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�size of the array"></A> - <I></I> -<B>int �n�size of the array</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�size of the array"></A> - <I></I> -<B>int �n�size of the array</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �pairIndex�corresponding variable index"></A> - <I></I> -<B>int �pairIndex�corresponding variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �path�"></A> - <I></I> -<B>int �path�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �phase�"></A> - <I></I> -<B>int �phase�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �phase�1: positive; 0: negative"></A> - <I></I> -<B>int �phase�1: positive; 0: negative</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �populationSize�"></A> - <I></I> -<B>int �populationSize�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �power�"></A> - <I></I> -<B>int �power�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �precision�"></A> - <I></I> -<B>int �precision�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �precision�"></A> - <I></I> -<B>int �precision�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �pr�"></A> - <I></I> -<B>int �pr�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �pr�"></A> - <I></I> -<B>int �pr�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �pr�verbosity level"></A> - <I></I> -<B>int �pr�verbosity level</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �pr�verbosity level"></A> - <I></I> -<B>int �pr�verbosity level</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �recomb�"></A> - <I></I> -<B>int �recomb�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �sms�"></A> - <I></I> -<B>int �sms�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �smv�"></A> - <I></I> -<B>int �smv�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �symmviolation�"></A> - <I></I> -<B>int �symmviolation�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �sy�step of column variables"></A> - <I></I> -<B>int �sy�step of column variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �sy�step of column variables"></A> - <I></I> -<B>int �sy�step of column variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �threshold�maximum number of nodes in the subset"></A> - <I></I> -<B>int �threshold�maximum number of nodes in the subset</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �threshold�maximum number of nodes in the subset"></A> - <I></I> -<B>int �threshold�maximum number of nodes in the subset</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �threshold�maximum number of nodes in the superset"></A> - <I></I> -<B>int �threshold�maximum number of nodes in the superset</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �threshold�maximum number of nodes in the superset"></A> - <I></I> -<B>int �threshold�maximum number of nodes in the superset</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �top�index of top variable"></A> - <I></I> -<B>int �top�index of top variable</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �upperBound�distance above which an approximate answer is OK"></A> - <I></I> -<B>int �upperBound�distance above which an approximate answer is OK</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �upper�"></A> - <I></I> -<B>int �upper�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �upper�"></A> - <I></I> -<B>int �upper�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �var�"></A> - <I></I> -<B>int �var�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �var�"></A> - <I></I> -<B>int �var�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �var�"></A> - <I></I> -<B>int �var�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �v�"></A> - <I></I> -<B>int �v�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �v�"></A> - <I></I> -<B>int �v�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �x�"></A> - <I></I> -<B>int �x�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �y�column index"></A> - <I></I> -<B>int �y�column index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="largest"></A> -static int <I></I> -<B>largest</B>( - <b></b> <i></i> -) -</pre> -<dd> Finds the largest DD in the population. If an order is - repeated, it avoids choosing the copy that is in the computed table - (it has repeat[i -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME="long �seed�"></A> - <I></I> -<B>long �seed�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="long �size�size of the allocation that failed"></A> - <I></I> -<B>long �size�size of the allocation that failed</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="make_random"></A> -static int <I></I> -<B>make_random</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b> <i></i> -) -</pre> -<dd> Generates the random sequences for the initial population. - The sequences are permutations of the indices between lower and - upper in the current order. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME="mintermsFromUniverse"></A> -static DdNode * <I></I> -<B>mintermsFromUniverse</B>( - DdManager * <b>manager</b>, <i></i> - DdNode ** <b>vars</b>, <i></i> - int <b>numVars</b>, <i></i> - double <b>n</b>, <i></i> - int <b>index</b> <i></i> -) -</pre> -<dd> Recursive procedure to extract n mintems from constant 1. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSplit.c"TARGET="ABSTRACT"><CODE>cuddSplit.c</CODE></A> - -<dt><pre> -<A NAME="oneliteralp"></A> -static int <I></I> -<B>oneliteralp</B>( - DdHalfWord <b>var</b> <i></i> -) -</pre> -<dd> Returns true iff the argument is a one-literal clause. - A one-litaral clause has the constant FALSE as second literal. - Since the constant TRUE is never used, it is sufficient to test for - a constant. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="pushDown"></A> -static void <I></I> -<B>pushDown</B>( - DdHalfWord * <b>order</b>, <i></i> - int <b>j</b>, <i></i> - int <b>level</b> <i></i> -) -</pre> -<dd> Pushes a variable in the order down to position "level." -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="rand_int"></A> -static int <I></I> -<B>rand_int</B>( - int <b>a</b> <i></i> -) -</pre> -<dd> Generates a random number between 0 and the integer a. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME="random_generator"></A> -static double <I></I> -<B>random_generator</B>( - <b></b> <i></i> -) -</pre> -<dd> Returns a double precision value between 0.0 and 1.0. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAnneal.c"TARGET="ABSTRACT"><CODE>cuddAnneal.c</CODE></A> - -<dt><pre> -<A NAME="restoreOrder"></A> -static int <I></I> -<B>restoreOrder</B>( - DdManager * <b>table</b>, <i></i> - int * <b>array</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Restores the variable order in array by a series of sifts up. - Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAnneal.c"TARGET="ABSTRACT"><CODE>cuddAnneal.c</CODE></A> - -<dt><pre> -<A NAME="roulette"></A> -static int <I></I> -<B>roulette</B>( - int * <b>p1</b>, <i></i> - int * <b>p2</b> <i></i> -) -</pre> -<dd> Selects two distinct parents with the roulette wheel method. -<p> - -<dd> <b>Side Effects</b> The indices of the selected parents are returned as side - effects. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME="selectMintermsFromUniverse"></A> -static DdNode * <I></I> -<B>selectMintermsFromUniverse</B>( - DdManager * <b>manager</b>, <i></i> - int * <b>varSeen</b>, <i></i> - double <b>n</b> <i></i> -) -</pre> -<dd> This function prepares an array of variables which have not been - encountered so far when traversing the procedure cuddSplitSetRecur. This - array is then used to extract the required number of minterms from a constant - 1. The algorithm guarantees that the size of BDD will be utmost log(n). -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSplit.c"TARGET="ABSTRACT"><CODE>cuddSplit.c</CODE></A> - -<dt><pre> -<A NAME="sentinelp"></A> -static int <I></I> -<B>sentinelp</B>( - DdHalfWord <b>var1</b>, <i></i> - DdHalfWord <b>var2</b> <i></i> -) -</pre> -<dd> Returns true iff the argument is the sentinel clause. - A sentinel clause has both variables equal to 0. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="separateCube"></A> -static DdNode * <I></I> -<B>separateCube</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - CUDD_VALUE_TYPE * <b>distance</b> <i></i> -) -</pre> -<dd> Separates cube from distance. Returns the cube if - successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> The distance is returned as a side effect. -<p> - -<dd> <b>See Also</b> <code><a href="#cuddBddClosestCube">cuddBddClosestCube</a> -<a href="#createResult">createResult</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddPriority.c"TARGET="ABSTRACT"><CODE>cuddPriority.c</CODE></A> - -<dt><pre> -<A NAME="siftBackwardProb"></A> -static int <I></I> -<B>siftBackwardProb</B>( - DdManager * <b>table</b>, <i></i> - Move * <b>moves</b>, <i></i> - int <b>size</b>, <i></i> - double <b>temp</b> <i></i> -) -</pre> -<dd> Otherwise, "tosses a coin" to decide whether to keep - the current configuration or return the DD to the original - one. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAnneal.c"TARGET="ABSTRACT"><CODE>cuddAnneal.c</CODE></A> - -<dt><pre> -<A NAME="sift_up"></A> -static int <I></I> -<B>sift_up</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>x_low</b> <i></i> -) -</pre> -<dd> Takes a variable from position x and sifts it up to - position x_low; x_low should be less than x. Returns 1 if successful; - 0 otherwise -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME="stPathTableDdFree"></A> -static enum st_retval <I></I> -<B>stPathTableDdFree</B>( - char * <b>key</b>, <i></i> - char * <b>value</b>, <i></i> - char * <b>arg</b> <i></i> -) -</pre> -<dd> None -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddSubsetSP.c"TARGET="ABSTRACT"><CODE>cuddSubsetSP.c</CODE></A> - -<dt><pre> -<A NAME="st_zdd_count_dbl_free"></A> -static enum st_retval <I></I> -<B>st_zdd_count_dbl_free</B>( - char * <b>key</b>, <i></i> - char * <b>value</b>, <i></i> - char * <b>arg</b> <i></i> -) -</pre> -<dd> Frees the memory associated with the computed table of - Cudd_zddCountDouble. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddCount.c"TARGET="ABSTRACT"><CODE>cuddZddCount.c</CODE></A> - -<dt><pre> -<A NAME="st_zdd_countfree"></A> -static enum st_retval <I></I> -<B>st_zdd_countfree</B>( - char * <b>key</b>, <i></i> - char * <b>value</b>, <i></i> - char * <b>arg</b> <i></i> -) -</pre> -<dd> Frees the memory associated with the computed table of - Cudd_zddCount. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddCount.c"TARGET="ABSTRACT"><CODE>cuddZddCount.c</CODE></A> - -<dt><pre> -<A NAME="stopping_criterion"></A> -static int <I></I> -<B>stopping_criterion</B>( - int <b>c1</b>, <i></i> - int <b>c2</b>, <i></i> - int <b>c3</b>, <i></i> - int <b>c4</b>, <i></i> - double <b>temp</b> <i></i> -) -</pre> -<dd> If temperature is STOP_TEMP or there is no improvement - then terminates. Returns 1 if the termination criterion is met; 0 - otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddAnneal.c"TARGET="ABSTRACT"><CODE>cuddAnneal.c</CODE></A> - -<dt><pre> -<A NAME="tlcInfoAlloc"></A> -static DdTlcInfo * <I></I> -<B>tlcInfoAlloc</B>( - <b></b> <i></i> -) -</pre> -<dd> Returns a pointer to a DdTlcInfo Structure if successful; - NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_tlcInfoFree">Cudd_tlcInfoFree</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME="unsigned int �factor�"></A> - <I></I> -<B>unsigned int �factor�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �hr�"></A> - <I></I> -<B>unsigned int �hr�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �lut�"></A> - <I></I> -<B>unsigned int �lut�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �maxLive�"></A> - <I></I> -<B>unsigned int �maxLive�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �mc�"></A> - <I></I> -<B>unsigned int �mc�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �mr�"></A> - <I></I> -<B>unsigned int �mr�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �next�"></A> - <I></I> -<B>unsigned int �next�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �p�"></A> - <I></I> -<B>unsigned int �p�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �secondDen�"></A> - <I></I> -<B>unsigned int �secondDen�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �type�MTR_DEFAULT or MTR_FIXED"></A> - <I></I> -<B>unsigned int �type�MTR_DEFAULT or MTR_FIXED</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �type�MTR_DEFAULT or MTR_FIXED"></A> - <I></I> -<B>unsigned int �type�MTR_DEFAULT or MTR_FIXED</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �upperB�upper bound"></A> - <I></I> -<B>unsigned int �upperB�upper bound</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned long �increase�"></A> - <I></I> -<B>unsigned long �increase�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned long �maxMemory�"></A> - <I></I> -<B>unsigned long �maxMemory�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned long �maxMemory�target maximum memory occupation"></A> - <I></I> -<B>unsigned long �maxMemory�target maximum memory occupation</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned long �st�"></A> - <I></I> -<B>unsigned long �st�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned long �tl�"></A> - <I></I> -<B>unsigned long �tl�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="updateEntry"></A> -static int <I></I> -<B>updateEntry</B>( - DdManager * <b>table</b>, <i></i> - DdHalfWord * <b>order</b>, <i></i> - int <b>level</b>, <i></i> - int <b>cost</b>, <i></i> - DdHalfWord ** <b>orders</b>, <i></i> - int * <b>costs</b>, <i></i> - int <b>subsets</b>, <i></i> - char * <b>mask</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Updates entry for a subset. Finds the subset, if it exists. - If the new order for the subset has lower cost, or if the subset did not - exist, it stores the new order and cost. Returns the number of subsets - currently in the table. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="updateParity"></A> -static void <I></I> -<B>updateParity</B>( - DdNode * <b>node</b>, <i>function to analyze</i> - ApproxInfo * <b>info</b>, <i>info on BDD</i> - int <b>newparity</b> <i>new parity for node</i> -) -</pre> -<dd> Recursively update the parity of the paths reaching a node. - Assumes that node is regular and propagates the invariant. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#gatherInfoAux">gatherInfoAux</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="updateRefs"></A> -static int <I></I> -<B>updateRefs</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - DdNode * <b>skip</b>, <i></i> - ApproxInfo * <b>info</b>, <i></i> - DdLevelQueue * <b>queue</b> <i></i> -) -</pre> -<dd> Update function reference counts to account for replacement. - Returns the number of nodes saved if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code>UAmarkNodes -RAmarkNodes -BAmarkNodes -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddApprox.c"TARGET="ABSTRACT"><CODE>cuddApprox.c</CODE></A> - -<dt><pre> -<A NAME="updateUB"></A> -static int <I></I> -<B>updateUB</B>( - DdManager * <b>table</b>, <i></i> - int <b>oldBound</b>, <i></i> - DdHalfWord * <b>bestOrder</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Updates the upper bound and saves the best order seen so far. - Returns the current value of the upper bound. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddExact.c"TARGET="ABSTRACT"><CODE>cuddExact.c</CODE></A> - -<dt><pre> -<A NAME="void *�data�"></A> - <I></I> -<B>void *�data�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="void *�data�"></A> - <I></I> -<B>void *�data�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="void *�data�"></A> - <I></I> -<B>void *�data�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="zddClearFlag"></A> -static void <I></I> -<B>zddClearFlag</B>( - DdNode * <b>f</b> <i></i> -) -</pre> -<dd> Performs a DFS from f, clearing the LSB of the next - pointers. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#zddSupportStep">zddSupportStep</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddUtil.c"TARGET="ABSTRACT"><CODE>cuddZddUtil.c</CODE></A> - -<dt><pre> -<A NAME="zddCountInternalMtrNodes"></A> -static int <I></I> -<B>zddCountInternalMtrNodes</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b> <i></i> -) -</pre> -<dd> Counts the number of internal nodes of the group tree. - Returns the count. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddFindNodeHiLo"></A> -static void <I></I> -<B>zddFindNodeHiLo</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b>, <i></i> - int * <b>lower</b>, <i></i> - int * <b>upper</b> <i></i> -) -</pre> -<dd> Finds the lower and upper bounds of the group represented - by treenode. The high and low fields of treenode are indices. From - those we need to derive the current positions, and find maximum and - minimum. -<p> - -<dd> <b>Side Effects</b> The bounds are returned as side effects. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddFixTree"></A> -static void <I></I> -<B>zddFixTree</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b> <i></i> -) -</pre> -<dd> Fixes the ZDD variable group tree after a - shuffle. Assumes that the order of the variables in a terminal node - has not been changed. -<p> - -<dd> <b>Side Effects</b> Changes the ZDD variable group tree. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="zddGroupMoveBackward"></A> -static int <I></I> -<B>zddGroupMoveBackward</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Undoes the swap two groups. Returns 1 in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddGroupMove"></A> -static int <I></I> -<B>zddGroupMove</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b>, <i></i> - Move ** <b>moves</b> <i></i> -) -</pre> -<dd> Swaps two groups and records the move. Returns the - number of keys in the DD table in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddGroupSiftingAux"></A> -static int <I></I> -<B>zddGroupSiftingAux</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xLow</b>, <i></i> - int <b>xHigh</b> <i></i> -) -</pre> -<dd> Sifts one variable up and down until it has taken all - positions. Checks for aggregation. There may be at most two sweeps, - even if the group grows. Assumes that x is either an isolated - variable, or it is the bottom of a group. All groups may not have - been found. The variable being moved is returned to the best position - seen during sifting. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddGroupSiftingBackward"></A> -static int <I></I> -<B>zddGroupSiftingBackward</B>( - DdManager * <b>table</b>, <i></i> - Move * <b>moves</b>, <i></i> - int <b>size</b> <i></i> -) -</pre> -<dd> Determines the best position for a variables and returns - it there. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddGroupSiftingDown"></A> -static int <I></I> -<B>zddGroupSiftingDown</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xHigh</b>, <i></i> - Move ** <b>moves</b> <i></i> -) -</pre> -<dd> Sifts down a variable until it reaches position xHigh. - Assumes that x is the bottom of a group (or a singleton). Records - all the moves. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddGroupSiftingUp"></A> -static int <I></I> -<B>zddGroupSiftingUp</B>( - DdManager * <b>table</b>, <i></i> - int <b>y</b>, <i></i> - int <b>xLow</b>, <i></i> - Move ** <b>moves</b> <i></i> -) -</pre> -<dd> Sifts up a variable until either it reaches position - xLow or the size of the DD heap increases too much. Assumes that y is - the top of a group (or a singleton). Checks y for aggregation to the - adjacent variables. Records all the moves that are appended to the - list of moves received as input and returned as a side effect. - Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddGroupSifting"></A> -static int <I></I> -<B>zddGroupSifting</B>( - DdManager * <b>table</b>, <i></i> - int <b>lower</b>, <i></i> - int <b>upper</b> <i></i> -) -</pre> -<dd> Sifts from treenode->low to treenode->high. If - croupcheck == CUDD_GROUP_CHECK7, it checks for group creation at the - end of the initial sifting. If a group is created, it is then sifted - again. After sifting one variable, the group that contains it is - dissolved. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddMergeGroups"></A> -static void <I></I> -<B>zddMergeGroups</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b>, <i></i> - int <b>low</b>, <i></i> - int <b>high</b> <i></i> -) -</pre> -<dd> Creates a single group from low to high and adjusts the - idex field of the tree node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddPortFromBddStep"></A> -static DdNode * <I></I> -<B>zddPortFromBddStep</B>( - DdManager * <b>dd</b>, <i></i> - DdNode * <b>B</b>, <i></i> - int <b>expected</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddPortFromBdd. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddPort.c"TARGET="ABSTRACT"><CODE>cuddZddPort.c</CODE></A> - -<dt><pre> -<A NAME="zddPortToBddStep"></A> -static DdNode * <I></I> -<B>zddPortToBddStep</B>( - DdManager * <b>dd</b>, <i>manager</i> - DdNode * <b>f</b>, <i>ZDD to be converted</i> - int <b>depth</b> <i>recursion depth</i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddPortToBdd. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddPort.c"TARGET="ABSTRACT"><CODE>cuddZddPort.c</CODE></A> - -<dt><pre> -<A NAME="zddPrintCoverAux"></A> -static void <I></I> -<B>zddPrintCoverAux</B>( - DdManager * <b>zdd</b>, <i>manager</i> - DdNode * <b>node</b>, <i>current node</i> - int <b>level</b>, <i>depth in the recursion</i> - int * <b>list</b> <i>current recursion path</i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddPrintCover. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddUtil.c"TARGET="ABSTRACT"><CODE>cuddZddUtil.c</CODE></A> - -<dt><pre> -<A NAME="zddReorderChildren"></A> -static int <I></I> -<B>zddReorderChildren</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b>, <i></i> - Cudd_ReorderingType <b>method</b> <i></i> -) -</pre> -<dd> Reorders the children of a group tree node according to - the options. After reordering puts all the variables in the group - and/or its descendents in a single group. This allows hierarchical - reordering. If the variables in the group do not exist yet, simply - does nothing. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddReorderPostprocess"></A> -static int <I></I> -<B>zddReorderPostprocess</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Shrinks almost empty subtables at the end of reordering to - guarantee that they have a reasonable load factor. However, if there many - nodes are being reclaimed, then no resizing occurs. Returns 1 in case of - success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="zddReorderPreprocess"></A> -static void <I></I> -<B>zddReorderPreprocess</B>( - DdManager * <b>table</b> <i></i> -) -</pre> -<dd> Prepares the ZDD heap for dynamic reordering. Does - garbage collection, to guarantee that there are no dead nodes; - and clears the cache, which is invalidated by dynamic reordering. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="zddShuffle"></A> -static int <I></I> -<B>zddShuffle</B>( - DdManager * <b>table</b>, <i></i> - int * <b>permutation</b> <i></i> -) -</pre> -<dd> Reorders ZDD variables according to a given permutation. - The i-th permutation array contains the index of the variable that - should be brought to the i-th level. zddShuffle assumes that no - dead nodes are present. The reordering is achieved by a series of - upward sifts. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="zddSiftUp"></A> -static int <I></I> -<B>zddSiftUp</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>xLow</b> <i></i> -) -</pre> -<dd> Takes a ZDD variable from position x and sifts it up to - position xLow; xLow should be less than or equal to x. - Returns 1 if successful; 0 otherwise -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="zddSupportStep"></A> -static void <I></I> -<B>zddSupportStep</B>( - DdNode * <b>f</b>, <i></i> - int * <b>support</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddSupport. Performs a - DFS from f. The support is accumulated in supp as a side effect. Uses - the LSB of the then pointer as visited flag. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#zddClearFlag">zddClearFlag</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddUtil.c"TARGET="ABSTRACT"><CODE>cuddZddUtil.c</CODE></A> - -<dt><pre> -<A NAME="zddSwapAny"></A> -static Move * <I></I> -<B>zddSwapAny</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Swaps any two variables. Returns the set of moves. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddReord.c"TARGET="ABSTRACT"><CODE>cuddZddReord.c</CODE></A> - -<dt><pre> -<A NAME="zddTreeSiftingAux"></A> -static int <I></I> -<B>zddTreeSiftingAux</B>( - DdManager * <b>table</b>, <i></i> - MtrNode * <b>treenode</b>, <i></i> - Cudd_ReorderingType <b>method</b> <i></i> -) -</pre> -<dd> Recursively visits the group tree and reorders each - group in postorder fashion. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddUniqueCompareGroup"></A> -static int <I></I> -<B>zddUniqueCompareGroup</B>( - int * <b>ptrX</b>, <i></i> - int * <b>ptrY</b> <i></i> -) -</pre> -<dd> Comparison function used by qsort to order the variables - according to the number of keys in the subtables. Returns the - difference in number of keys between the two variables being - compared. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddGroup.c"TARGET="ABSTRACT"><CODE>cuddZddGroup.c</CODE></A> - -<dt><pre> -<A NAME="zddVarToConst"></A> -static void <I></I> -<B>zddVarToConst</B>( - DdNode * <b>f</b>, <i></i> - DdNode ** <b>gp</b>, <i></i> - DdNode ** <b>hp</b>, <i></i> - DdNode * <b>base</b>, <i></i> - DdNode * <b>empty</b> <i></i> -) -</pre> -<dd> Replaces variables with constants if possible (part of - canonical form). -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSetop.c"TARGET="ABSTRACT"><CODE>cuddZddSetop.c</CODE></A> - -<dt><pre> -<A NAME="zdd_group_move_backward"></A> -static int <I></I> -<B>zdd_group_move_backward</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b> <i></i> -) -</pre> -<dd> Undoes the swap of two groups. x is assumed to be the - bottom variable of the first group. y is assumed to be the top - variable of the second group. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSymm.c"TARGET="ABSTRACT"><CODE>cuddZddSymm.c</CODE></A> - -<dt><pre> -<A NAME="zdd_group_move"></A> -static int <I></I> -<B>zdd_group_move</B>( - DdManager * <b>table</b>, <i></i> - int <b>x</b>, <i></i> - int <b>y</b>, <i></i> - Move ** <b>moves</b> <i></i> -) -</pre> -<dd> Swaps two groups. x is assumed to be the bottom variable - of the first group. y is assumed to be the top variable of the second - group. Updates the list of moves. Returns the number of keys in the - table if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSymm.c"TARGET="ABSTRACT"><CODE>cuddZddSymm.c</CODE></A> - -<dt><pre> -<A NAME="zdd_print_minterm_aux"></A> -static void <I></I> -<B>zdd_print_minterm_aux</B>( - DdManager * <b>zdd</b>, <i>manager</i> - DdNode * <b>node</b>, <i>current node</i> - int <b>level</b>, <i>depth in the recursion</i> - int * <b>list</b> <i>current recursion path</i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddPrintMinterm. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddUtil.c"TARGET="ABSTRACT"><CODE>cuddZddUtil.c</CODE></A> - -<dt><pre> -<A NAME="zdd_subset0_aux"></A> -static DdNode * <I></I> -<B>zdd_subset0_aux</B>( - DdManager * <b>zdd</b>, <i></i> - DdNode * <b>P</b>, <i></i> - DdNode * <b>zvar</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddSubset0. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSetop.c"TARGET="ABSTRACT"><CODE>cuddZddSetop.c</CODE></A> - -<dt><pre> -<A NAME="zdd_subset1_aux"></A> -static DdNode * <I></I> -<B>zdd_subset1_aux</B>( - DdManager * <b>zdd</b>, <i></i> - DdNode * <b>P</b>, <i></i> - DdNode * <b>zvar</b> <i></i> -) -</pre> -<dd> Performs the recursive step of Cudd_zddSubset1. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddSetop.c"TARGET="ABSTRACT"><CODE>cuddZddSetop.c</CODE></A> - -<dt><pre> -<A NAME="zp2"></A> -static int <I></I> -<B>zp2</B>( - DdManager * <b>zdd</b>, <i></i> - DdNode * <b>f</b>, <i></i> - st_table * <b>t</b> <i></i> -) -</pre> -<dd> Performs the recursive step of cuddZddP. Returns 1 in - case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddZddUtil.c"TARGET="ABSTRACT"><CODE>cuddZddUtil.c</CODE></A> - -<dt><pre> -<A NAME="��"></A> - <I></I> -<B>��</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Adds node to the head of the free list. Does not - deallocate memory chunks that become free. This function is also - used by the dynamic reordering functions. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddAllocNode">cuddAllocNode</a> -<a href="#cuddDynamicAllocNode">cuddDynamicAllocNode</a> -<a href="#cuddDeallocMove">cuddDeallocMove</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Adds node to the head of the free list. Does not - deallocate memory chunks that become free. This function is also - used by the dynamic reordering functions. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddDeallocNode">cuddDeallocNode</a> -<a href="#cuddDynamicAllocNode">cuddDynamicAllocNode</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Adjusts the values of table fields controlling the. - sizes of subtables and computed table. If the computed table is too small - according to the new values, it is resized. -<p> - -<dd> <b>Side Effects</b> Modifies manager fields. May resize computed table. -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Clears a bit vector. The parameter size gives the - number of bits. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#bitVectorAlloc">bitVectorAlloc</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Clears the 4 least significant bits of a pointer. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Comparison of a function to the i-th ADD variable. Returns 1 if - the function is the i-th ADD variable; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCompose.c"TARGET="ABSTRACT"><CODE>cuddCompose.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Comparison of a pair of functions to the i-th ADD - variable. Returns 1 if the functions are the i-th ADD variable and its - complement; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddCompose.c"TARGET="ABSTRACT"><CODE>cuddCompose.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Complements a DD if condition c is true; c should be - either 0 or 1, because it is used directly (for efficiency). If in - doubt on the values c may take, use "(c) ? Cudd_Not(node) : node". -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_Not">Cudd_Not</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Complements a DD by flipping the complement attribute of - the pointer (the least significant bit). -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_NotCond">Cudd_NotCond</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Computes hash function for keys of one operand. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#ddLCHash3">ddLCHash3</a> -<a href="#ddLCHash">ddLCHash</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Computes hash function for keys of three operands. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#ddLCHash2">ddLCHash2</a> -<a href="#ddLCHash">ddLCHash</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Computes hash function for keys of two operands. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#ddLCHash3">ddLCHash3</a> -<a href="#ddLCHash">ddLCHash</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Computes the absolute value of a number. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Computes the hash value for a local cache. Returns the - bucket index. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Computes the maximum of two numbers. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#ddMin">ddMin</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Computes the minimum of two numbers. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#ddMax">ddMax</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Decreases the reference count of node. It is primarily - used in recursive procedures to decrease the ref count of a result - node before returning it. This accomplishes the goal of removing the - protection applied by a previous cuddRef. This being a macro, it is - faster than Cudd_Deref, but it cannot be used in constructs like - cuddDeref(a = b()). -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_Deref">Cudd_Deref</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Enforces DD_MINUS_INF_VAL <= x <= DD_PLUS_INF_VAL. - Furthermore, if x <= DD_MINUS_INF_VAL/2, x is set to - DD_MINUS_INF_VAL. Similarly, if DD_PLUS_INF_VAL/2 <= x, x is set to - DD_PLUS_INF_VAL. Normally this macro is a NOOP. However, if - HAVE_IEEE_754 is not defined, it makes sure that a value does not - get larger than infinity in absolute value, and once it gets to - infinity, stays there. If the value overflows before this macro is - applied, no recovery is possible. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Extract the least significant digit of a double digit. Used - in the manipulation of arbitrary precision integers. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code>DD_MSDIGIT -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Extract the most significant digit of a double digit. Used - in the manipulation of arbitrary precision integers. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code>DD_LSDIGIT -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Fast storage allocation for items in a hash table. The - first 4 bytes of a chunk contain a pointer to the next block; the - rest contains DD_MEM_CHUNK spaces for hash items. Returns a pointer to - a new item if successful; NULL is memory is full. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddAllocNode">cuddAllocNode</a> -<a href="#cuddDynamicAllocNode">cuddDynamicAllocNode</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLCache.c"TARGET="ABSTRACT"><CODE>cuddLCache.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Finds the current position of ZDD variable index in the - order. This macro duplicates the functionality of Cudd_ReadPermZdd, - but it does not check for out-of-bounds indices and it is more - efficient. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_ReadPermZdd">Cudd_ReadPermZdd</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Finds the current position of variable index in the - order. This macro duplicates the functionality of Cudd_ReadPerm, - but it does not check for out-of-bounds indices and it is more - efficient. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_ReadPerm">Cudd_ReadPerm</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Hash function for the cache for functions with two - operands. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#ddHash">ddHash</a> -<a href="#ddCHash">ddCHash</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Hash function for the cache. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#ddHash">ddHash</a> -<a href="#ddCHash2">ddCHash2</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Hash function for the table of a level queue. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#hashInsert">hashInsert</a> -<a href="#hashLookup">hashLookup</a> -<a href="#hashDelete">hashDelete</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddLevelQ.c"TARGET="ABSTRACT"><CODE>cuddLevelQ.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Hash function for the unique table. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#ddCHash">ddCHash</a> -<a href="#ddCHash2">ddCHash2</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Increases the reference count of a node, if it is not - saturated. This being a macro, it is faster than Cudd_Ref, but it - cannot be used in constructs like cuddRef(a = b()). -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_Ref">Cudd_Ref</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Iterates over the cubes of a decision diagram f. - <ul> - <li> DdManager *manager; - <li> DdNode *f; - <li> DdGen *gen; - <li> int *cube; - <li> CUDD_VALUE_TYPE value; - </ul> - Cudd_ForeachCube allocates and frees the generator. Therefore the - application should not try to do that. Also, the cube is freed at the - end of Cudd_ForeachCube and hence is not available outside of the loop.<p> - CAUTION: It is assumed that dynamic reordering will not occur while - there are open generators. It is the user's responsibility to make sure - that dynamic reordering does not occur. As long as new nodes are not created - during generation, and dynamic reordering is not called explicitly, - dynamic reordering will not occur. Alternatively, it is sufficient to - disable dynamic reordering. It is a mistake to dispose of a diagram - on which generation is ongoing. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_ForeachNode">Cudd_ForeachNode</a> -<a href="#Cudd_FirstCube">Cudd_FirstCube</a> -<a href="#Cudd_NextCube">Cudd_NextCube</a> -<a href="#Cudd_GenFree">Cudd_GenFree</a> -<a href="#Cudd_IsGenEmpty">Cudd_IsGenEmpty</a> -<a href="#Cudd_AutodynDisable">Cudd_AutodynDisable</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Iterates over the nodes of a decision diagram f. - <ul> - <li> DdManager *manager; - <li> DdNode *f; - <li> DdGen *gen; - <li> DdNode *node; - </ul> - The nodes are returned in a seemingly random order. - Cudd_ForeachNode allocates and frees the generator. Therefore the - application should not try to do that.<p> - CAUTION: It is assumed that dynamic reordering will not occur while - there are open generators. It is the user's responsibility to make sure - that dynamic reordering does not occur. As long as new nodes are not created - during generation, and dynamic reordering is not called explicitly, - dynamic reordering will not occur. Alternatively, it is sufficient to - disable dynamic reordering. It is a mistake to dispose of a diagram - on which generation is ongoing. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_ForeachCube">Cudd_ForeachCube</a> -<a href="#Cudd_FirstNode">Cudd_FirstNode</a> -<a href="#Cudd_NextNode">Cudd_NextNode</a> -<a href="#Cudd_GenFree">Cudd_GenFree</a> -<a href="#Cudd_IsGenEmpty">Cudd_IsGenEmpty</a> -<a href="#Cudd_AutodynDisable">Cudd_AutodynDisable</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Iterates over the paths of a ZDD f. - <ul> - <li> DdManager *manager; - <li> DdNode *f; - <li> DdGen *gen; - <li> int *path; - </ul> - Cudd_zddForeachPath allocates and frees the generator. Therefore the - application should not try to do that. Also, the path is freed at the - end of Cudd_zddForeachPath and hence is not available outside of the loop.<p> - CAUTION: It is assumed that dynamic reordering will not occur while - there are open generators. It is the user's responsibility to make sure - that dynamic reordering does not occur. As long as new nodes are not created - during generation, and dynamic reordering is not called explicitly, - dynamic reordering will not occur. Alternatively, it is sufficient to - disable dynamic reordering. It is a mistake to dispose of a diagram - on which generation is ongoing. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_zddFirstPath">Cudd_zddFirstPath</a> -<a href="#Cudd_zddNextPath">Cudd_zddNextPath</a> -<a href="#Cudd_GenFree">Cudd_GenFree</a> -<a href="#Cudd_IsGenEmpty">Cudd_IsGenEmpty</a> -<a href="#Cudd_AutodynDisable">Cudd_AutodynDisable</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Iterates over the primes of a Boolean function producing - a prime and irredundant cover. - <ul> - <li> DdManager *manager; - <li> DdNode *l; - <li> DdNode *u; - <li> DdGen *gen; - <li> int *cube; - </ul> - The Boolean function is described by an upper bound and a lower bound. If - the function is completely specified, the two bounds coincide. - Cudd_ForeachPrime allocates and frees the generator. Therefore the - application should not try to do that. Also, the cube is freed at the - end of Cudd_ForeachPrime and hence is not available outside of the loop.<p> - CAUTION: It is a mistake to change a diagram on which generation is ongoing. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_ForeachCube">Cudd_ForeachCube</a> -<a href="#Cudd_FirstPrime">Cudd_FirstPrime</a> -<a href="#Cudd_NextPrime">Cudd_NextPrime</a> -<a href="#Cudd_GenFree">Cudd_GenFree</a> -<a href="#Cudd_IsGenEmpty">Cudd_IsGenEmpty</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Outputs a line of stats if DD_COUNT and DD_STATS are - defined. Increments the number of recursive calls if DD_COUNT is - defined. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Performs the left rotation for red/black trees. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddRotateRight">cuddRotateRight</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Performs the right rotation for red/black trees. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#cuddRotateLeft">cuddRotateLeft</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddTable.c"TARGET="ABSTRACT"><CODE>cuddTable.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns 1 if a pointer is complemented. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_Regular">Cudd_Regular</a> -<a href="#Cudd_Complement">Cudd_Complement</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns 1 if the absolute value of the difference of the two - arguments x and y is less than e. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns 1 if the node is a constant node (rather than an - internal node). All constant nodes have the same index - (CUDD_CONST_INDEX). The pointer passed to Cudd_IsConstant may be either - regular or complemented. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns 1 if the node is a constant node (rather than an - internal node). All constant nodes have the same index - (CUDD_CONST_INDEX). The pointer passed to cuddIsConstant must be regular. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_IsConstant">Cudd_IsConstant</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the arithmetic 0 constant node. This is different - from the logical zero. The latter is obtained by - Cudd_Not(DD_ONE(dd)). -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code>DD_ONE -<a href="#Cudd_Not">Cudd_Not</a> -DD_PLUS_INFINITY -DD_MINUS_INFINITY -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the average fitness of the population. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddGenetic.c"TARGET="ABSTRACT"><CODE>cuddGenetic.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the complemented version of a pointer. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_Regular">Cudd_Regular</a> -<a href="#Cudd_IsComplement">Cudd_IsComplement</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the constant 1 node. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code>DD_ZERO -DD_PLUS_INFINITY -DD_MINUS_INFINITY -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the current position in the order of variable - index. This macro is obsolete and is kept for compatibility. New - applications should use Cudd_ReadPerm instead. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_ReadPerm">Cudd_ReadPerm</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the else child of an internal node. If - <code>node</code> is a constant node, the result is unpredictable. - The pointer passed to cuddE must be regular. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_E">Cudd_E</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the else child of an internal node. If - <code>node</code> is a constant node, the result is unpredictable. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_T">Cudd_T</a> -<a href="#Cudd_V">Cudd_V</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the i-th entry of a bit vector. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#bitVectorSet">bitVectorSet</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the minus infinity constant node. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code>DD_ONE -DD_ZERO -DD_PLUS_INFINITY -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the plus infinity constant node. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code>DD_ONE -DD_ZERO -DD_MINUS_INFINITY -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the regular version of a pointer. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_Complement">Cudd_Complement</a> -<a href="#Cudd_IsComplement">Cudd_IsComplement</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the then child of an internal node. If - <code>node</code> is a constant node, the result is unpredictable. - The pointer passed to cuddT must be regular. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_T">Cudd_T</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the then child of an internal node. If - <code>node</code> is a constant node, the result is unpredictable. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_E">Cudd_E</a> -<a href="#Cudd_V">Cudd_V</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the value of a constant node. If - <code>node</code> is an internal node, the result is unpredictable. - The pointer passed to cuddV must be regular. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_V">Cudd_V</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Returns the value of a constant node. If - <code>node</code> is an internal node, the result is unpredictable. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#Cudd_T">Cudd_T</a> -<a href="#Cudd_E">Cudd_E</a> -</code> - -<DD> <B>Defined in </B> <CODE>cudd.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Saturating decrement operator. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#cuddSatInc">cuddSatInc</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Saturating increment operator. -<p> - -<dd> <b>Side Effects</b> none -<p> - -<dd> <b>See Also</b> <code><a href="#cuddSatDec">cuddSatDec</a> -</code> - -<DD> <B>Defined in </B> <CODE>cuddInt.h</CODE> - -<dt><pre> -<A NAME=""></A> - <I></I> -<B></B>( - <b></b> <i></i> -) -</pre> -<dd> Sets the i-th entry of a bit vector to a value. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="#bitVectorRead">bitVectorRead</a> -</code> - -<DD> <B>Defined in </B> <A HREF="cuddAllFile.html#cuddEssent.c"TARGET="ABSTRACT"><CODE>cuddEssent.c</CODE></A> - - -</DL> -<HR> -Last updated on 20120204 17h33 -</BODY></HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllFile.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllFile.html deleted file mode 100644 index 9293943d3..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddAllFile.html +++ /dev/null @@ -1,4876 +0,0 @@ -<HTML> -<HEAD><TITLE>The cudd package: files</TITLE></HEAD> -<BODY> - -<DL> - <DT> <A HREF="#cuddAddAbs.c"><CODE>cuddAddAbs.c</CODE></A> - <DD> Quantification functions for ADDs. - <DT> <A HREF="#cuddAddApply.c"><CODE>cuddAddApply.c</CODE></A> - <DD> Apply functions for ADDs and their operators. - <DT> <A HREF="#cuddAddFind.c"><CODE>cuddAddFind.c</CODE></A> - <DD> Functions to find maximum and minimum in an ADD and to - extract the i-th bit. - <DT> <A HREF="#cuddAddInv.c"><CODE>cuddAddInv.c</CODE></A> - <DD> Function to compute the scalar inverse of an ADD. - <DT> <A HREF="#cuddAddIte.c"><CODE>cuddAddIte.c</CODE></A> - <DD> ADD ITE function and satellites. - <DT> <A HREF="#cuddAddNeg.c"><CODE>cuddAddNeg.c</CODE></A> - <DD> Function to compute the negation of an ADD. - <DT> <A HREF="#cuddAddWalsh.c"><CODE>cuddAddWalsh.c</CODE></A> - <DD> Functions that generate Walsh matrices and residue - functions in ADD form. - <DT> <A HREF="#cuddAndAbs.c"><CODE>cuddAndAbs.c</CODE></A> - <DD> Combined AND and existential abstraction for BDDs - <DT> <A HREF="#cuddAnneal.c"><CODE>cuddAnneal.c</CODE></A> - <DD> Reordering of DDs based on simulated annealing - <DT> <A HREF="#cuddApa.c"><CODE>cuddApa.c</CODE></A> - <DD> Arbitrary precision arithmetic functions. - <DT> <A HREF="#cuddAPI.c"><CODE>cuddAPI.c</CODE></A> - <DD> Application interface functions. - <DT> <A HREF="#cuddApprox.c"><CODE>cuddApprox.c</CODE></A> - <DD> Procedures to approximate a given BDD. - <DT> <A HREF="#cuddBddAbs.c"><CODE>cuddBddAbs.c</CODE></A> - <DD> Quantification functions for BDDs. - <DT> <A HREF="#cuddBddCorr.c"><CODE>cuddBddCorr.c</CODE></A> - <DD> Correlation between BDDs. - <DT> <A HREF="#cuddBddIte.c"><CODE>cuddBddIte.c</CODE></A> - <DD> BDD ITE function and satellites. - <DT> <A HREF="#cuddBridge.c"><CODE>cuddBridge.c</CODE></A> - <DD> Translation from BDD to ADD and vice versa and transfer between - different managers. - <DT> <A HREF="#cuddCache.c"><CODE>cuddCache.c</CODE></A> - <DD> Functions for cache insertion and lookup. - <DT> <A HREF="#cuddCheck.c"><CODE>cuddCheck.c</CODE></A> - <DD> Functions to check consistency of data structures. - <DT> <A HREF="#cuddClip.c"><CODE>cuddClip.c</CODE></A> - <DD> Clipping functions. - <DT> <A HREF="#cuddCof.c"><CODE>cuddCof.c</CODE></A> - <DD> Cofactoring functions. - <DT> <A HREF="#cuddCompose.c"><CODE>cuddCompose.c</CODE></A> - <DD> Functional composition and variable permutation of DDs. - <DT> <A HREF="#cuddDecomp.c"><CODE>cuddDecomp.c</CODE></A> - <DD> Functions for BDD decomposition. - <DT> <A HREF="#cuddEssent.c"><CODE>cuddEssent.c</CODE></A> - <DD> Functions for the detection of essential variables. - <DT> <A HREF="#cuddExact.c"><CODE>cuddExact.c</CODE></A> - <DD> Functions for exact variable reordering. - <DT> <A HREF="#cuddExport.c"><CODE>cuddExport.c</CODE></A> - <DD> Export functions. - <DT> <A HREF="#cuddGenCof.c"><CODE>cuddGenCof.c</CODE></A> - <DD> Generalized cofactors for BDDs and ADDs. - <DT> <A HREF="#cuddGenetic.c"><CODE>cuddGenetic.c</CODE></A> - <DD> Genetic algorithm for variable reordering. - <DT> <A HREF="#cuddGroup.c"><CODE>cuddGroup.c</CODE></A> - <DD> Functions for group sifting. - <DT> <A HREF="#cuddHarwell.c"><CODE>cuddHarwell.c</CODE></A> - <DD> Function to read a matrix in Harwell format. - <DT> <A HREF="#cuddInit.c"><CODE>cuddInit.c</CODE></A> - <DD> Functions to initialize and shut down the DD manager. - <DT> <A HREF="#cuddInteract.c"><CODE>cuddInteract.c</CODE></A> - <DD> Functions to manipulate the variable interaction matrix. - <DT> <A HREF="#cuddLCache.c"><CODE>cuddLCache.c</CODE></A> - <DD> Functions for local caches. - <DT> <A HREF="#cuddLevelQ.c"><CODE>cuddLevelQ.c</CODE></A> - <DD> Procedure to manage level queues. - <DT> <A HREF="#cuddLinear.c"><CODE>cuddLinear.c</CODE></A> - <DD> Functions for DD reduction by linear transformations. - <DT> <A HREF="#cuddLiteral.c"><CODE>cuddLiteral.c</CODE></A> - <DD> Functions for manipulation of literal sets represented by - BDDs. - <DT> <A HREF="#cuddMatMult.c"><CODE>cuddMatMult.c</CODE></A> - <DD> Matrix multiplication functions. - <DT> <A HREF="#cuddPriority.c"><CODE>cuddPriority.c</CODE></A> - <DD> Priority functions. - <DT> <A HREF="#cuddRead.c"><CODE>cuddRead.c</CODE></A> - <DD> Functions to read in a matrix - <DT> <A HREF="#cuddRef.c"><CODE>cuddRef.c</CODE></A> - <DD> Functions that manipulate the reference counts. - <DT> <A HREF="#cuddReorder.c"><CODE>cuddReorder.c</CODE></A> - <DD> Functions for dynamic variable reordering. - <DT> <A HREF="#cuddSat.c"><CODE>cuddSat.c</CODE></A> - <DD> Functions for the solution of satisfiability related problems. - <DT> <A HREF="#cuddSign.c"><CODE>cuddSign.c</CODE></A> - <DD> Computation of signatures. - <DT> <A HREF="#cuddSolve.c"><CODE>cuddSolve.c</CODE></A> - <DD> Boolean equation solver and related functions. - <DT> <A HREF="#cuddSplit.c"><CODE>cuddSplit.c</CODE></A> - <DD> Returns a subset of minterms from a boolean function. - <DT> <A HREF="#cuddSubsetHB.c"><CODE>cuddSubsetHB.c</CODE></A> - <DD> Procedure to subset the given BDD by choosing the heavier - branches. - <DT> <A HREF="#cuddSubsetSP.c"><CODE>cuddSubsetSP.c</CODE></A> - <DD> Procedure to subset the given BDD choosing the shortest paths - (largest cubes) in the BDD. - <DT> <A HREF="#cuddSymmetry.c"><CODE>cuddSymmetry.c</CODE></A> - <DD> Functions for symmetry-based variable reordering. - <DT> <A HREF="#cuddTable.c"><CODE>cuddTable.c</CODE></A> - <DD> Unique table management functions. - <DT> <A HREF="#cuddUtil.c"><CODE>cuddUtil.c</CODE></A> - <DD> Utility functions. - <DT> <A HREF="#cuddWindow.c"><CODE>cuddWindow.c</CODE></A> - <DD> Functions for variable reordering by window permutation. - <DT> <A HREF="#cuddZddCount.c"><CODE>cuddZddCount.c</CODE></A> - <DD> Procedures to count the number of minterms of a ZDD. - <DT> <A HREF="#cuddZddFuncs.c"><CODE>cuddZddFuncs.c</CODE></A> - <DD> Functions to manipulate covers represented as ZDDs. - <DT> <A HREF="#cuddZddGroup.c"><CODE>cuddZddGroup.c</CODE></A> - <DD> Functions for ZDD group sifting. - <DT> <A HREF="#cuddZddIsop.c"><CODE>cuddZddIsop.c</CODE></A> - <DD> Functions to find irredundant SOP covers as ZDDs from BDDs. - <DT> <A HREF="#cuddZddLin.c"><CODE>cuddZddLin.c</CODE></A> - <DD> Procedures for dynamic variable ordering of ZDDs. - <DT> <A HREF="#cuddZddMisc.c"><CODE>cuddZddMisc.c</CODE></A> - <DD> Miscellaneous utility functions for ZDDs. - <DT> <A HREF="#cuddZddPort.c"><CODE>cuddZddPort.c</CODE></A> - <DD> Functions that translate BDDs to ZDDs. - <DT> <A HREF="#cuddZddReord.c"><CODE>cuddZddReord.c</CODE></A> - <DD> Procedures for dynamic variable ordering of ZDDs. - <DT> <A HREF="#cuddZddSetop.c"><CODE>cuddZddSetop.c</CODE></A> - <DD> Set operations on ZDDs. - <DT> <A HREF="#cuddZddSymm.c"><CODE>cuddZddSymm.c</CODE></A> - <DD> Functions for symmetry-based ZDD variable reordering. - <DT> <A HREF="#cuddZddUtil.c"><CODE>cuddZddUtil.c</CODE></A> - <DD> Utility functions for ZDDs. -</DL><HR> -<A NAME="cuddAddAbs.c"><H1>cuddAddAbs.c</H1></A> -Quantification functions for ADDs. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_addExistAbstract() - <li> Cudd_addUnivAbstract() - <li> Cudd_addOrAbstract() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAddExistAbstractRecur() - <li> cuddAddUnivAbstractRecur() - <li> cuddAddOrAbstractRecur() - </ul> - Static procedures included in this module: - <ul> - <li> addCheckPositiveCube() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addExistAbstract" TARGET="MAIN"><CODE>Cudd_addExistAbstract()</CODE></A> - <DD> Existentially Abstracts all the variables in cube from f. - - <DT> <A HREF="cuddAllDet.html#Cudd_addUnivAbstract" TARGET="MAIN"><CODE>Cudd_addUnivAbstract()</CODE></A> - <DD> Universally Abstracts all the variables in cube from f. - - <DT> <A HREF="cuddAllDet.html#Cudd_addOrAbstract" TARGET="MAIN"><CODE>Cudd_addOrAbstract()</CODE></A> - <DD> Disjunctively abstracts all the variables in cube from the - 0-1 ADD f. - - <DT> <A HREF="cuddAllDet.html#cuddAddExistAbstractRecur" TARGET="MAIN"><CODE>cuddAddExistAbstractRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addExistAbstract. - - <DT> <A HREF="cuddAllDet.html#cuddAddUnivAbstractRecur" TARGET="MAIN"><CODE>cuddAddUnivAbstractRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addUnivAbstract. - - <DT> <A HREF="cuddAllDet.html#cuddAddOrAbstractRecur" TARGET="MAIN"><CODE>cuddAddOrAbstractRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addOrAbstract. - - <DT> <A HREF="cuddAllDet.html#addCheckPositiveCube" TARGET="MAIN"><CODE>addCheckPositiveCube()</CODE></A> - <DD> Checks whether cube is an ADD representing the product - of positive literals. - -</DL> -<HR> -<A NAME="cuddAddApply.c"><H1>cuddAddApply.c</H1></A> -Apply functions for ADDs and their operators. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_addApply() - <li> Cudd_addMonadicApply() - <li> Cudd_addPlus() - <li> Cudd_addTimes() - <li> Cudd_addThreshold() - <li> Cudd_addSetNZ() - <li> Cudd_addDivide() - <li> Cudd_addMinus() - <li> Cudd_addMinimum() - <li> Cudd_addMaximum() - <li> Cudd_addOneZeroMaximum() - <li> Cudd_addDiff() - <li> Cudd_addAgreement() - <li> Cudd_addOr() - <li> Cudd_addNand() - <li> Cudd_addNor() - <li> Cudd_addXor() - <li> Cudd_addXnor() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAddApplyRecur() - <li> cuddAddMonadicApplyRecur() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addApply" TARGET="MAIN"><CODE>Cudd_addApply()</CODE></A> - <DD> Applies op to the corresponding discriminants of f and g. - - <DT> <A HREF="cuddAllDet.html#Cudd_addPlus" TARGET="MAIN"><CODE>Cudd_addPlus()</CODE></A> - <DD> Integer and floating point addition. - - <DT> <A HREF="cuddAllDet.html#Cudd_addTimes" TARGET="MAIN"><CODE>Cudd_addTimes()</CODE></A> - <DD> Integer and floating point multiplication. - - <DT> <A HREF="cuddAllDet.html#Cudd_addThreshold" TARGET="MAIN"><CODE>Cudd_addThreshold()</CODE></A> - <DD> f if f>=g; 0 if f<g. - - <DT> <A HREF="cuddAllDet.html#Cudd_addSetNZ" TARGET="MAIN"><CODE>Cudd_addSetNZ()</CODE></A> - <DD> This operator sets f to the value of g wherever g != 0. - - <DT> <A HREF="cuddAllDet.html#Cudd_addDivide" TARGET="MAIN"><CODE>Cudd_addDivide()</CODE></A> - <DD> Integer and floating point division. - - <DT> <A HREF="cuddAllDet.html#Cudd_addMinus" TARGET="MAIN"><CODE>Cudd_addMinus()</CODE></A> - <DD> Integer and floating point subtraction. - - <DT> <A HREF="cuddAllDet.html#Cudd_addMinimum" TARGET="MAIN"><CODE>Cudd_addMinimum()</CODE></A> - <DD> Integer and floating point min. - - <DT> <A HREF="cuddAllDet.html#Cudd_addMaximum" TARGET="MAIN"><CODE>Cudd_addMaximum()</CODE></A> - <DD> Integer and floating point max. - - <DT> <A HREF="cuddAllDet.html#Cudd_addOneZeroMaximum" TARGET="MAIN"><CODE>Cudd_addOneZeroMaximum()</CODE></A> - <DD> Returns 1 if f > g and 0 otherwise. - - <DT> <A HREF="cuddAllDet.html#Cudd_addDiff" TARGET="MAIN"><CODE>Cudd_addDiff()</CODE></A> - <DD> Returns plusinfinity if f=g; returns min(f,g) if f!=g. - - <DT> <A HREF="cuddAllDet.html#Cudd_addAgreement" TARGET="MAIN"><CODE>Cudd_addAgreement()</CODE></A> - <DD> f if f==g; background if f!=g. - - <DT> <A HREF="cuddAllDet.html#Cudd_addOr" TARGET="MAIN"><CODE>Cudd_addOr()</CODE></A> - <DD> Disjunction of two 0-1 ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_addNand" TARGET="MAIN"><CODE>Cudd_addNand()</CODE></A> - <DD> NAND of two 0-1 ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_addNor" TARGET="MAIN"><CODE>Cudd_addNor()</CODE></A> - <DD> NOR of two 0-1 ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_addXor" TARGET="MAIN"><CODE>Cudd_addXor()</CODE></A> - <DD> XOR of two 0-1 ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_addXnor" TARGET="MAIN"><CODE>Cudd_addXnor()</CODE></A> - <DD> XNOR of two 0-1 ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_addMonadicApply" TARGET="MAIN"><CODE>Cudd_addMonadicApply()</CODE></A> - <DD> Applies op to the discriminants of f. - - <DT> <A HREF="cuddAllDet.html#Cudd_addLog" TARGET="MAIN"><CODE>Cudd_addLog()</CODE></A> - <DD> Natural logarithm of an ADD. - - <DT> <A HREF="cuddAllDet.html#cuddAddApplyRecur" TARGET="MAIN"><CODE>cuddAddApplyRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addApply. - - <DT> <A HREF="cuddAllDet.html#cuddAddMonadicApplyRecur" TARGET="MAIN"><CODE>cuddAddMonadicApplyRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addMonadicApply. - -</DL> -<HR> -<A NAME="cuddAddFind.c"><H1>cuddAddFind.c</H1></A> -Functions to find maximum and minimum in an ADD and to - extract the i-th bit. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_addFindMax() - <li> Cudd_addFindMin() - <li> Cudd_addIthBit() - </ul> - Static functions included in this module: - <ul> - <li> addDoIthBit() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addFindMax" TARGET="MAIN"><CODE>Cudd_addFindMax()</CODE></A> - <DD> Finds the maximum discriminant of f. - - <DT> <A HREF="cuddAllDet.html#Cudd_addFindMin" TARGET="MAIN"><CODE>Cudd_addFindMin()</CODE></A> - <DD> Finds the minimum discriminant of f. - - <DT> <A HREF="cuddAllDet.html#Cudd_addIthBit" TARGET="MAIN"><CODE>Cudd_addIthBit()</CODE></A> - <DD> Extracts the i-th bit from an ADD. - - <DT> <A HREF="cuddAllDet.html#addDoIthBit" TARGET="MAIN"><CODE>addDoIthBit()</CODE></A> - <DD> Performs the recursive step for Cudd_addIthBit. - -</DL> -<HR> -<A NAME="cuddAddInv.c"><H1>cuddAddInv.c</H1></A> -Function to compute the scalar inverse of an ADD. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_addScalarInverse() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAddScalarInverseRecur() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addScalarInverse" TARGET="MAIN"><CODE>Cudd_addScalarInverse()</CODE></A> - <DD> Computes the scalar inverse of an ADD. - - <DT> <A HREF="cuddAllDet.html#cuddAddScalarInverseRecur" TARGET="MAIN"><CODE>cuddAddScalarInverseRecur()</CODE></A> - <DD> Performs the recursive step of addScalarInverse. - -</DL> -<HR> -<A NAME="cuddAddIte.c"><H1>cuddAddIte.c</H1></A> -ADD ITE function and satellites. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_addIte() - <li> Cudd_addIteConstant() - <li> Cudd_addEvalConst() - <li> Cudd_addCmpl() - <li> Cudd_addLeq() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAddIteRecur() - <li> cuddAddCmplRecur() - </ul> - Static procedures included in this module: - <ul> - <li> addVarToConst() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addIte" TARGET="MAIN"><CODE>Cudd_addIte()</CODE></A> - <DD> Implements ITE(f,g,h). - - <DT> <A HREF="cuddAllDet.html#Cudd_addIteConstant" TARGET="MAIN"><CODE>Cudd_addIteConstant()</CODE></A> - <DD> Implements ITEconstant for ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_addEvalConst" TARGET="MAIN"><CODE>Cudd_addEvalConst()</CODE></A> - <DD> Checks whether ADD g is constant whenever ADD f is 1. - - <DT> <A HREF="cuddAllDet.html#Cudd_addCmpl" TARGET="MAIN"><CODE>Cudd_addCmpl()</CODE></A> - <DD> Computes the complement of an ADD a la C language. - - <DT> <A HREF="cuddAllDet.html#Cudd_addLeq" TARGET="MAIN"><CODE>Cudd_addLeq()</CODE></A> - <DD> Determines whether f is less than or equal to g. - - <DT> <A HREF="cuddAllDet.html#cuddAddIteRecur" TARGET="MAIN"><CODE>cuddAddIteRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_addIte(f,g,h). - - <DT> <A HREF="cuddAllDet.html#cuddAddCmplRecur" TARGET="MAIN"><CODE>cuddAddCmplRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addCmpl. - - <DT> <A HREF="cuddAllDet.html#addVarToConst" TARGET="MAIN"><CODE>addVarToConst()</CODE></A> - <DD> Replaces variables with constants if possible (part of - canonical form). - -</DL> -<HR> -<A NAME="cuddAddNeg.c"><H1>cuddAddNeg.c</H1></A> -Function to compute the negation of an ADD. <P> -<B>By: Fabio Somenzi, Balakrishna Kumthekar</B><P> -External procedures included in this module: - <ul> - <li> Cudd_addNegate() - <li> Cudd_addRoundOff() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAddNegateRecur() - <li> cuddAddRoundOffRecur() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addNegate" TARGET="MAIN"><CODE>Cudd_addNegate()</CODE></A> - <DD> Computes the additive inverse of an ADD. - - <DT> <A HREF="cuddAllDet.html#Cudd_addRoundOff" TARGET="MAIN"><CODE>Cudd_addRoundOff()</CODE></A> - <DD> Rounds off the discriminants of an ADD. - - <DT> <A HREF="cuddAllDet.html#cuddAddNegateRecur" TARGET="MAIN"><CODE>cuddAddNegateRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_addNegate. - - <DT> <A HREF="cuddAllDet.html#cuddAddRoundOffRecur" TARGET="MAIN"><CODE>cuddAddRoundOffRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_addRoundOff. - -</DL> -<HR> -<A NAME="cuddAddWalsh.c"><H1>cuddAddWalsh.c</H1></A> -Functions that generate Walsh matrices and residue - functions in ADD form. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_addWalsh() - <li> Cudd_addResidue() - </ul> - Static procedures included in this module: - <ul> - <li> addWalshInt() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addWalsh" TARGET="MAIN"><CODE>Cudd_addWalsh()</CODE></A> - <DD> Generates a Walsh matrix in ADD form. - - <DT> <A HREF="cuddAllDet.html#Cudd_addResidue" TARGET="MAIN"><CODE>Cudd_addResidue()</CODE></A> - <DD> Builds an ADD for the residue modulo m of an n-bit - number. - - <DT> <A HREF="cuddAllDet.html#addWalshInt" TARGET="MAIN"><CODE>addWalshInt()</CODE></A> - <DD> Implements the recursive step of Cudd_addWalsh. - -</DL> -<HR> -<A NAME="cuddAndAbs.c"><H1>cuddAndAbs.c</H1></A> -Combined AND and existential abstraction for BDDs <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_bddAndAbstract() - <li> Cudd_bddAndAbstractLimit() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddAndAbstractRecur() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_bddAndAbstract" TARGET="MAIN"><CODE>Cudd_bddAndAbstract()</CODE></A> - <DD> Takes the AND of two BDDs and simultaneously abstracts the - variables in cube. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddAndAbstractLimit" TARGET="MAIN"><CODE>Cudd_bddAndAbstractLimit()</CODE></A> - <DD> Takes the AND of two BDDs and simultaneously abstracts the - variables in cube. Returns NULL if too many nodes are required. - - <DT> <A HREF="cuddAllDet.html#cuddBddAndAbstractRecur" TARGET="MAIN"><CODE>cuddBddAndAbstractRecur()</CODE></A> - <DD> Takes the AND of two BDDs and simultaneously abstracts the - variables in cube. - -</DL> -<HR> -<A NAME="cuddAnneal.c"><H1>cuddAnneal.c</H1></A> -Reordering of DDs based on simulated annealing <P> -<B>By: Jae-Young Jang, Jorgen Sivesind</B><P> -Internal procedures included in this file: - <ul> - <li> cuddAnnealing() - </ul> - Static procedures included in this file: - <ul> - <li> stopping_criterion() - <li> random_generator() - <li> ddExchange() - <li> ddJumpingAux() - <li> ddJumpingUp() - <li> ddJumpingDown() - <li> siftBackwardProb() - <li> copyOrder() - <li> restoreOrder() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#cuddAnnealing" TARGET="MAIN"><CODE>cuddAnnealing()</CODE></A> - <DD> Get new variable-order by simulated annealing algorithm. - - <DT> <A HREF="cuddAllDet.html#stopping_criterion" TARGET="MAIN"><CODE>stopping_criterion()</CODE></A> - <DD> Checks termination condition. - - <DT> <A HREF="cuddAllDet.html#random_generator" TARGET="MAIN"><CODE>random_generator()</CODE></A> - <DD> Random number generator. - - <DT> <A HREF="cuddAllDet.html#ddExchange" TARGET="MAIN"><CODE>ddExchange()</CODE></A> - <DD> This function is for exchanging two variables, x and y. - - <DT> <A HREF="cuddAllDet.html#ddJumpingAux" TARGET="MAIN"><CODE>ddJumpingAux()</CODE></A> - <DD> Moves a variable to a specified position. - - <DT> <A HREF="cuddAllDet.html#ddJumpingUp" TARGET="MAIN"><CODE>ddJumpingUp()</CODE></A> - <DD> This function is for jumping up. - - <DT> <A HREF="cuddAllDet.html#ddJumpingDown" TARGET="MAIN"><CODE>ddJumpingDown()</CODE></A> - <DD> This function is for jumping down. - - <DT> <A HREF="cuddAllDet.html#siftBackwardProb" TARGET="MAIN"><CODE>siftBackwardProb()</CODE></A> - <DD> Returns the DD to the best position encountered during - sifting if there was improvement. - - <DT> <A HREF="cuddAllDet.html#copyOrder" TARGET="MAIN"><CODE>copyOrder()</CODE></A> - <DD> Copies the current variable order to array. - - <DT> <A HREF="cuddAllDet.html#restoreOrder" TARGET="MAIN"><CODE>restoreOrder()</CODE></A> - <DD> Restores the variable order in array by a series of sifts up. - -</DL> -<HR> -<A NAME="cuddApa.c"><H1>cuddApa.c</H1></A> -Arbitrary precision arithmetic functions. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_ApaNumberOfDigits() - <li> Cudd_NewApaNumber() - <li> Cudd_ApaCopy() - <li> Cudd_ApaAdd() - <li> Cudd_ApaSubtract() - <li> Cudd_ApaShortDivision() - <li> Cudd_ApaIntDivision() - <li> Cudd_ApaShiftRight() - <li> Cudd_ApaSetToLiteral() - <li> Cudd_ApaPowerOfTwo() - <li> Cudd_ApaCompare() - <li> Cudd_ApaCompareRatios() - <li> Cudd_ApaPrintHex() - <li> Cudd_ApaPrintDecimal() - <li> Cudd_ApaPrintExponential() - <li> Cudd_ApaCountMinterm() - <li> Cudd_ApaPrintMinterm() - <li> Cudd_ApaPrintMintermExp() - <li> Cudd_ApaPrintDensity() - </ul> - Static procedures included in this module: - <ul> - <li> cuddApaCountMintermAux() - <li> cuddApaStCountfree() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_ApaNumberOfDigits" TARGET="MAIN"><CODE>Cudd_ApaNumberOfDigits()</CODE></A> - <DD> Finds the number of digits for an arbitrary precision - integer. - - <DT> <A HREF="cuddAllDet.html#Cudd_NewApaNumber" TARGET="MAIN"><CODE>Cudd_NewApaNumber()</CODE></A> - <DD> Allocates memory for an arbitrary precision integer. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaCopy" TARGET="MAIN"><CODE>Cudd_ApaCopy()</CODE></A> - <DD> Makes a copy of an arbitrary precision integer. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaAdd" TARGET="MAIN"><CODE>Cudd_ApaAdd()</CODE></A> - <DD> Adds two arbitrary precision integers. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaSubtract" TARGET="MAIN"><CODE>Cudd_ApaSubtract()</CODE></A> - <DD> Subtracts two arbitrary precision integers. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaShortDivision" TARGET="MAIN"><CODE>Cudd_ApaShortDivision()</CODE></A> - <DD> Divides an arbitrary precision integer by a digit. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaIntDivision" TARGET="MAIN"><CODE>Cudd_ApaIntDivision()</CODE></A> - <DD> Divides an arbitrary precision integer by an integer. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaShiftRight" TARGET="MAIN"><CODE>Cudd_ApaShiftRight()</CODE></A> - <DD> Shifts right an arbitrary precision integer by one binary - place. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaSetToLiteral" TARGET="MAIN"><CODE>Cudd_ApaSetToLiteral()</CODE></A> - <DD> Sets an arbitrary precision integer to a one-digit literal. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaPowerOfTwo" TARGET="MAIN"><CODE>Cudd_ApaPowerOfTwo()</CODE></A> - <DD> Sets an arbitrary precision integer to a power of two. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaCompare" TARGET="MAIN"><CODE>Cudd_ApaCompare()</CODE></A> - <DD> Compares two arbitrary precision integers. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaCompareRatios" TARGET="MAIN"><CODE>Cudd_ApaCompareRatios()</CODE></A> - <DD> Compares the ratios of two arbitrary precision integers to two - unsigned ints. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintHex" TARGET="MAIN"><CODE>Cudd_ApaPrintHex()</CODE></A> - <DD> Prints an arbitrary precision integer in hexadecimal format. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintDecimal" TARGET="MAIN"><CODE>Cudd_ApaPrintDecimal()</CODE></A> - <DD> Prints an arbitrary precision integer in decimal format. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintExponential" TARGET="MAIN"><CODE>Cudd_ApaPrintExponential()</CODE></A> - <DD> Prints an arbitrary precision integer in exponential format. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaCountMinterm" TARGET="MAIN"><CODE>Cudd_ApaCountMinterm()</CODE></A> - <DD> Counts the number of minterms of a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintMinterm" TARGET="MAIN"><CODE>Cudd_ApaPrintMinterm()</CODE></A> - <DD> Prints the number of minterms of a BDD or ADD using - arbitrary precision arithmetic. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintMintermExp" TARGET="MAIN"><CODE>Cudd_ApaPrintMintermExp()</CODE></A> - <DD> Prints the number of minterms of a BDD or ADD in exponential - format using arbitrary precision arithmetic. - - <DT> <A HREF="cuddAllDet.html#Cudd_ApaPrintDensity" TARGET="MAIN"><CODE>Cudd_ApaPrintDensity()</CODE></A> - <DD> Prints the density of a BDD or ADD using - arbitrary precision arithmetic. - - <DT> <A HREF="cuddAllDet.html#cuddApaCountMintermAux" TARGET="MAIN"><CODE>cuddApaCountMintermAux()</CODE></A> - <DD> Performs the recursive step of Cudd_ApaCountMinterm. - - <DT> <A HREF="cuddAllDet.html#cuddApaStCountfree" TARGET="MAIN"><CODE>cuddApaStCountfree()</CODE></A> - <DD> Frees the memory used to store the minterm counts recorded - in the visited table. - -</DL> -<HR> -<A NAME="cuddAPI.c"><H1>cuddAPI.c</H1></A> -Application interface functions. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_addNewVar() - <li> Cudd_addNewVarAtLevel() - <li> Cudd_bddNewVar() - <li> Cudd_bddNewVarAtLevel() - <li> Cudd_addIthVar() - <li> Cudd_bddIthVar() - <li> Cudd_zddIthVar() - <li> Cudd_zddVarsFromBddVars() - <li> Cudd_addConst() - <li> Cudd_IsNonConstant() - <li> Cudd_ReadStartTime() - <li> Cudd_ReadElapsedTime() - <li> Cudd_SetStartTime() - <li> Cudd_ResetStartTime() - <li> Cudd_ReadTimeLimit() - <li> Cudd_SetTimeLimit() - <li> Cudd_UpdateTimeLimit() - <li> Cudd_IncreaseTimeLimit() - <li> Cudd_UnsetTimeLimit() - <li> Cudd_TimeLimited() - <li> Cudd_AutodynEnable() - <li> Cudd_AutodynDisable() - <li> Cudd_ReorderingStatus() - <li> Cudd_AutodynEnableZdd() - <li> Cudd_AutodynDisableZdd() - <li> Cudd_ReorderingStatusZdd() - <li> Cudd_zddRealignmentEnabled() - <li> Cudd_zddRealignEnable() - <li> Cudd_zddRealignDisable() - <li> Cudd_bddRealignmentEnabled() - <li> Cudd_bddRealignEnable() - <li> Cudd_bddRealignDisable() - <li> Cudd_ReadOne() - <li> Cudd_ReadZddOne() - <li> Cudd_ReadZero() - <li> Cudd_ReadLogicZero() - <li> Cudd_ReadPlusInfinity() - <li> Cudd_ReadMinusInfinity() - <li> Cudd_ReadBackground() - <li> Cudd_SetBackground() - <li> Cudd_ReadCacheSlots() - <li> Cudd_ReadCacheUsedSlots() - <li> Cudd_ReadCacheLookUps() - <li> Cudd_ReadCacheHits() - <li> Cudd_ReadMinHit() - <li> Cudd_SetMinHit() - <li> Cudd_ReadLooseUpTo() - <li> Cudd_SetLooseUpTo() - <li> Cudd_ReadMaxCache() - <li> Cudd_ReadMaxCacheHard() - <li> Cudd_SetMaxCacheHard() - <li> Cudd_ReadSize() - <li> Cudd_ReadSlots() - <li> Cudd_ReadUsedSlots() - <li> Cudd_ExpectedUsedSlots() - <li> Cudd_ReadKeys() - <li> Cudd_ReadDead() - <li> Cudd_ReadMinDead() - <li> Cudd_ReadReorderings() - <li> Cudd_ReadMaxReorderings() - <li> Cudd_SetMaxReorderings() - <li> Cudd_ReadReorderingTime() - <li> Cudd_ReadGarbageCollections() - <li> Cudd_ReadGarbageCollectionTime() - <li> Cudd_ReadNodesFreed() - <li> Cudd_ReadNodesDropped() - <li> Cudd_ReadUniqueLookUps() - <li> Cudd_ReadUniqueLinks() - <li> Cudd_ReadSiftMaxVar() - <li> Cudd_SetSiftMaxVar() - <li> Cudd_ReadMaxGrowth() - <li> Cudd_SetMaxGrowth() - <li> Cudd_ReadMaxGrowthAlternate() - <li> Cudd_SetMaxGrowthAlternate() - <li> Cudd_ReadReorderingCycle() - <li> Cudd_SetReorderingCycle() - <li> Cudd_ReadTree() - <li> Cudd_SetTree() - <li> Cudd_FreeTree() - <li> Cudd_ReadZddTree() - <li> Cudd_SetZddTree() - <li> Cudd_FreeZddTree() - <li> Cudd_NodeReadIndex() - <li> Cudd_ReadPerm() - <li> Cudd_ReadInvPerm() - <li> Cudd_ReadVars() - <li> Cudd_ReadEpsilon() - <li> Cudd_SetEpsilon() - <li> Cudd_ReadGroupCheck() - <li> Cudd_SetGroupcheck() - <li> Cudd_GarbageCollectionEnabled() - <li> Cudd_EnableGarbageCollection() - <li> Cudd_DisableGarbageCollection() - <li> Cudd_DeadAreCounted() - <li> Cudd_TurnOnCountDead() - <li> Cudd_TurnOffCountDead() - <li> Cudd_ReadRecomb() - <li> Cudd_SetRecomb() - <li> Cudd_ReadSymmviolation() - <li> Cudd_SetSymmviolation() - <li> Cudd_ReadArcviolation() - <li> Cudd_SetArcviolation() - <li> Cudd_ReadPopulationSize() - <li> Cudd_SetPopulationSize() - <li> Cudd_ReadNumberXovers() - <li> Cudd_SetNumberXovers() - <li> Cudd_ReadOrderRandomization() - <li> Cudd_SetOrderRandomization() - <li> Cudd_ReadMemoryInUse() - <li> Cudd_PrintInfo() - <li> Cudd_ReadPeakNodeCount() - <li> Cudd_ReadPeakLiveNodeCount() - <li> Cudd_ReadNodeCount() - <li> Cudd_zddReadNodeCount() - <li> Cudd_AddHook() - <li> Cudd_RemoveHook() - <li> Cudd_IsInHook() - <li> Cudd_StdPreReordHook() - <li> Cudd_StdPostReordHook() - <li> Cudd_EnableReorderingReporting() - <li> Cudd_DisableReorderingReporting() - <li> Cudd_ReorderingReporting() - <li> Cudd_PrintGroupedOrder() - <li> Cudd_EnableOrderingMonitoring() - <li> Cudd_DisableOrderingMonitoring() - <li> Cudd_OrderingMonitoring() - <li> Cudd_ReadErrorCode() - <li> Cudd_ClearErrorCode() - <li> Cudd_ReadStdout() - <li> Cudd_SetStdout() - <li> Cudd_ReadStderr() - <li> Cudd_SetStderr() - <li> Cudd_ReadNextReordering() - <li> Cudd_SetNextReordering() - <li> Cudd_ReadSwapSteps() - <li> Cudd_ReadMaxLive() - <li> Cudd_SetMaxLive() - <li> Cudd_ReadMaxMemory() - <li> Cudd_SetMaxMemory() - <li> Cudd_bddBindVar() - <li> Cudd_bddUnbindVar() - <li> Cudd_bddVarIsBound() - <li> Cudd_bddSetPiVar() - <li> Cudd_bddSetPsVar() - <li> Cudd_bddSetNsVar() - <li> Cudd_bddIsPiVar() - <li> Cudd_bddIsPsVar() - <li> Cudd_bddIsNsVar() - <li> Cudd_bddSetPairIndex() - <li> Cudd_bddReadPairIndex() - <li> Cudd_bddSetVarToBeGrouped() - <li> Cudd_bddSetVarHardGroup() - <li> Cudd_bddResetVarToBeGrouped() - <li> Cudd_bddIsVarToBeGrouped() - <li> Cudd_bddSetVarToBeUngrouped() - <li> Cudd_bddIsVarToBeUngrouped() - <li> Cudd_bddIsVarHardGroup() - </ul> - Static procedures included in this module: - <ul> - <li> fixVarTree() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addNewVar" TARGET="MAIN"><CODE>Cudd_addNewVar()</CODE></A> - <DD> Returns a new ADD variable. - - <DT> <A HREF="cuddAllDet.html#Cudd_addNewVarAtLevel" TARGET="MAIN"><CODE>Cudd_addNewVarAtLevel()</CODE></A> - <DD> Returns a new ADD variable at a specified level. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddNewVar" TARGET="MAIN"><CODE>Cudd_bddNewVar()</CODE></A> - <DD> Returns a new BDD variable. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddNewVarAtLevel" TARGET="MAIN"><CODE>Cudd_bddNewVarAtLevel()</CODE></A> - <DD> Returns a new BDD variable at a specified level. - - <DT> <A HREF="cuddAllDet.html#Cudd_addIthVar" TARGET="MAIN"><CODE>Cudd_addIthVar()</CODE></A> - <DD> Returns the ADD variable with index i. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIthVar" TARGET="MAIN"><CODE>Cudd_bddIthVar()</CODE></A> - <DD> Returns the BDD variable with index i. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddIthVar" TARGET="MAIN"><CODE>Cudd_zddIthVar()</CODE></A> - <DD> Returns the ZDD variable with index i. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddVarsFromBddVars" TARGET="MAIN"><CODE>Cudd_zddVarsFromBddVars()</CODE></A> - <DD> Creates one or more ZDD variables for each BDD variable. - - <DT> <A HREF="cuddAllDet.html#Cudd_addConst" TARGET="MAIN"><CODE>Cudd_addConst()</CODE></A> - <DD> Returns the ADD for constant c. - - <DT> <A HREF="cuddAllDet.html#Cudd_IsNonConstant" TARGET="MAIN"><CODE>Cudd_IsNonConstant()</CODE></A> - <DD> Returns 1 if a DD node is not constant. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadStartTime" TARGET="MAIN"><CODE>Cudd_ReadStartTime()</CODE></A> - <DD> Returns the start time of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadElapsedTime" TARGET="MAIN"><CODE>Cudd_ReadElapsedTime()</CODE></A> - <DD> Returns the time elapsed since the start time of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetStartTime" TARGET="MAIN"><CODE>Cudd_SetStartTime()</CODE></A> - <DD> Sets the start time of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ResetStartTime" TARGET="MAIN"><CODE>Cudd_ResetStartTime()</CODE></A> - <DD> Resets the start time of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadTimeLimit" TARGET="MAIN"><CODE>Cudd_ReadTimeLimit()</CODE></A> - <DD> Returns the time limit for the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetTimeLimit" TARGET="MAIN"><CODE>Cudd_SetTimeLimit()</CODE></A> - <DD> Sets the time limit for the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_UpdateTimeLimit" TARGET="MAIN"><CODE>Cudd_UpdateTimeLimit()</CODE></A> - <DD> Updates the time limit for the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_IncreaseTimeLimit" TARGET="MAIN"><CODE>Cudd_IncreaseTimeLimit()</CODE></A> - <DD> Increases the time limit for the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_UnsetTimeLimit" TARGET="MAIN"><CODE>Cudd_UnsetTimeLimit()</CODE></A> - <DD> Unsets the time limit for the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_TimeLimited" TARGET="MAIN"><CODE>Cudd_TimeLimited()</CODE></A> - <DD> Returns true if the time limit for the manager is set. - - <DT> <A HREF="cuddAllDet.html#Cudd_AutodynEnable" TARGET="MAIN"><CODE>Cudd_AutodynEnable()</CODE></A> - <DD> Enables automatic dynamic reordering of BDDs and ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_AutodynDisable" TARGET="MAIN"><CODE>Cudd_AutodynDisable()</CODE></A> - <DD> Disables automatic dynamic reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReorderingStatus" TARGET="MAIN"><CODE>Cudd_ReorderingStatus()</CODE></A> - <DD> Reports the status of automatic dynamic reordering of BDDs - and ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_AutodynEnableZdd" TARGET="MAIN"><CODE>Cudd_AutodynEnableZdd()</CODE></A> - <DD> Enables automatic dynamic reordering of ZDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_AutodynDisableZdd" TARGET="MAIN"><CODE>Cudd_AutodynDisableZdd()</CODE></A> - <DD> Disables automatic dynamic reordering of ZDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReorderingStatusZdd" TARGET="MAIN"><CODE>Cudd_ReorderingStatusZdd()</CODE></A> - <DD> Reports the status of automatic dynamic reordering of ZDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddRealignmentEnabled" TARGET="MAIN"><CODE>Cudd_zddRealignmentEnabled()</CODE></A> - <DD> Tells whether the realignment of ZDD order to BDD order is - enabled. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddRealignEnable" TARGET="MAIN"><CODE>Cudd_zddRealignEnable()</CODE></A> - <DD> Enables realignment of ZDD order to BDD order. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddRealignDisable" TARGET="MAIN"><CODE>Cudd_zddRealignDisable()</CODE></A> - <DD> Disables realignment of ZDD order to BDD order. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddRealignmentEnabled" TARGET="MAIN"><CODE>Cudd_bddRealignmentEnabled()</CODE></A> - <DD> Tells whether the realignment of BDD order to ZDD order is - enabled. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddRealignEnable" TARGET="MAIN"><CODE>Cudd_bddRealignEnable()</CODE></A> - <DD> Enables realignment of BDD order to ZDD order. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddRealignDisable" TARGET="MAIN"><CODE>Cudd_bddRealignDisable()</CODE></A> - <DD> Disables realignment of ZDD order to BDD order. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadOne" TARGET="MAIN"><CODE>Cudd_ReadOne()</CODE></A> - <DD> Returns the one constant of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadZddOne" TARGET="MAIN"><CODE>Cudd_ReadZddOne()</CODE></A> - <DD> Returns the ZDD for the constant 1 function. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadZero" TARGET="MAIN"><CODE>Cudd_ReadZero()</CODE></A> - <DD> Returns the zero constant of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadLogicZero" TARGET="MAIN"><CODE>Cudd_ReadLogicZero()</CODE></A> - <DD> Returns the logic zero constant of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadPlusInfinity" TARGET="MAIN"><CODE>Cudd_ReadPlusInfinity()</CODE></A> - <DD> Reads the plus-infinity constant from the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadMinusInfinity" TARGET="MAIN"><CODE>Cudd_ReadMinusInfinity()</CODE></A> - <DD> Reads the minus-infinity constant from the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadBackground" TARGET="MAIN"><CODE>Cudd_ReadBackground()</CODE></A> - <DD> Reads the background constant of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetBackground" TARGET="MAIN"><CODE>Cudd_SetBackground()</CODE></A> - <DD> Sets the background constant of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadCacheSlots" TARGET="MAIN"><CODE>Cudd_ReadCacheSlots()</CODE></A> - <DD> Reads the number of slots in the cache. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadCacheUsedSlots" TARGET="MAIN"><CODE>Cudd_ReadCacheUsedSlots()</CODE></A> - <DD> Reads the fraction of used slots in the cache. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadCacheLookUps" TARGET="MAIN"><CODE>Cudd_ReadCacheLookUps()</CODE></A> - <DD> Returns the number of cache look-ups. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadCacheHits" TARGET="MAIN"><CODE>Cudd_ReadCacheHits()</CODE></A> - <DD> Returns the number of cache hits. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadRecursiveCalls" TARGET="MAIN"><CODE>Cudd_ReadRecursiveCalls()</CODE></A> - <DD> Returns the number of recursive calls. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadMinHit" TARGET="MAIN"><CODE>Cudd_ReadMinHit()</CODE></A> - <DD> Reads the hit rate that causes resizinig of the computed - table. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetMinHit" TARGET="MAIN"><CODE>Cudd_SetMinHit()</CODE></A> - <DD> Sets the hit rate that causes resizinig of the computed - table. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadLooseUpTo" TARGET="MAIN"><CODE>Cudd_ReadLooseUpTo()</CODE></A> - <DD> Reads the looseUpTo parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetLooseUpTo" TARGET="MAIN"><CODE>Cudd_SetLooseUpTo()</CODE></A> - <DD> Sets the looseUpTo parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxCache" TARGET="MAIN"><CODE>Cudd_ReadMaxCache()</CODE></A> - <DD> Returns the soft limit for the cache size. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxCacheHard" TARGET="MAIN"><CODE>Cudd_ReadMaxCacheHard()</CODE></A> - <DD> Reads the maxCacheHard parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetMaxCacheHard" TARGET="MAIN"><CODE>Cudd_SetMaxCacheHard()</CODE></A> - <DD> Sets the maxCacheHard parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadSize" TARGET="MAIN"><CODE>Cudd_ReadSize()</CODE></A> - <DD> Returns the number of BDD variables in existance. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadZddSize" TARGET="MAIN"><CODE>Cudd_ReadZddSize()</CODE></A> - <DD> Returns the number of ZDD variables in existance. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadSlots" TARGET="MAIN"><CODE>Cudd_ReadSlots()</CODE></A> - <DD> Returns the total number of slots of the unique table. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadUsedSlots" TARGET="MAIN"><CODE>Cudd_ReadUsedSlots()</CODE></A> - <DD> Reads the fraction of used slots in the unique table. - - <DT> <A HREF="cuddAllDet.html#Cudd_ExpectedUsedSlots" TARGET="MAIN"><CODE>Cudd_ExpectedUsedSlots()</CODE></A> - <DD> Computes the expected fraction of used slots in the unique - table. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadKeys" TARGET="MAIN"><CODE>Cudd_ReadKeys()</CODE></A> - <DD> Returns the number of nodes in the unique table. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadDead" TARGET="MAIN"><CODE>Cudd_ReadDead()</CODE></A> - <DD> Returns the number of dead nodes in the unique table. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadMinDead" TARGET="MAIN"><CODE>Cudd_ReadMinDead()</CODE></A> - <DD> Reads the minDead parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadReorderings" TARGET="MAIN"><CODE>Cudd_ReadReorderings()</CODE></A> - <DD> Returns the number of times reordering has occurred. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxReorderings" TARGET="MAIN"><CODE>Cudd_ReadMaxReorderings()</CODE></A> - <DD> Returns the maximum number of times reordering may be invoked. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetMaxReorderings" TARGET="MAIN"><CODE>Cudd_SetMaxReorderings()</CODE></A> - <DD> Sets the maximum number of times reordering may be invoked. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadReorderingTime" TARGET="MAIN"><CODE>Cudd_ReadReorderingTime()</CODE></A> - <DD> Returns the time spent in reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadGarbageCollections" TARGET="MAIN"><CODE>Cudd_ReadGarbageCollections()</CODE></A> - <DD> Returns the number of times garbage collection has occurred. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadGarbageCollectionTime" TARGET="MAIN"><CODE>Cudd_ReadGarbageCollectionTime()</CODE></A> - <DD> Returns the time spent in garbage collection. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadNodesFreed" TARGET="MAIN"><CODE>Cudd_ReadNodesFreed()</CODE></A> - <DD> Returns the number of nodes freed. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadNodesDropped" TARGET="MAIN"><CODE>Cudd_ReadNodesDropped()</CODE></A> - <DD> Returns the number of nodes dropped. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadUniqueLookUps" TARGET="MAIN"><CODE>Cudd_ReadUniqueLookUps()</CODE></A> - <DD> Returns the number of look-ups in the unique table. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadUniqueLinks" TARGET="MAIN"><CODE>Cudd_ReadUniqueLinks()</CODE></A> - <DD> Returns the number of links followed in the unique table. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadSiftMaxVar" TARGET="MAIN"><CODE>Cudd_ReadSiftMaxVar()</CODE></A> - <DD> Reads the siftMaxVar parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetSiftMaxVar" TARGET="MAIN"><CODE>Cudd_SetSiftMaxVar()</CODE></A> - <DD> Sets the siftMaxVar parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadSiftMaxSwap" TARGET="MAIN"><CODE>Cudd_ReadSiftMaxSwap()</CODE></A> - <DD> Reads the siftMaxSwap parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetSiftMaxSwap" TARGET="MAIN"><CODE>Cudd_SetSiftMaxSwap()</CODE></A> - <DD> Sets the siftMaxSwap parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxGrowth" TARGET="MAIN"><CODE>Cudd_ReadMaxGrowth()</CODE></A> - <DD> Reads the maxGrowth parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetMaxGrowth" TARGET="MAIN"><CODE>Cudd_SetMaxGrowth()</CODE></A> - <DD> Sets the maxGrowth parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxGrowthAlternate" TARGET="MAIN"><CODE>Cudd_ReadMaxGrowthAlternate()</CODE></A> - <DD> Reads the maxGrowthAlt parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetMaxGrowthAlternate" TARGET="MAIN"><CODE>Cudd_SetMaxGrowthAlternate()</CODE></A> - <DD> Sets the maxGrowthAlt parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadReorderingCycle" TARGET="MAIN"><CODE>Cudd_ReadReorderingCycle()</CODE></A> - <DD> Reads the reordCycle parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetReorderingCycle" TARGET="MAIN"><CODE>Cudd_SetReorderingCycle()</CODE></A> - <DD> Sets the reordCycle parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadTree" TARGET="MAIN"><CODE>Cudd_ReadTree()</CODE></A> - <DD> Returns the variable group tree of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetTree" TARGET="MAIN"><CODE>Cudd_SetTree()</CODE></A> - <DD> Sets the variable group tree of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_FreeTree" TARGET="MAIN"><CODE>Cudd_FreeTree()</CODE></A> - <DD> Frees the variable group tree of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadZddTree" TARGET="MAIN"><CODE>Cudd_ReadZddTree()</CODE></A> - <DD> Returns the variable group tree of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetZddTree" TARGET="MAIN"><CODE>Cudd_SetZddTree()</CODE></A> - <DD> Sets the ZDD variable group tree of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_FreeZddTree" TARGET="MAIN"><CODE>Cudd_FreeZddTree()</CODE></A> - <DD> Frees the variable group tree of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_NodeReadIndex" TARGET="MAIN"><CODE>Cudd_NodeReadIndex()</CODE></A> - <DD> Returns the index of the node. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadPerm" TARGET="MAIN"><CODE>Cudd_ReadPerm()</CODE></A> - <DD> Returns the current position of the i-th variable in the - order. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadPermZdd" TARGET="MAIN"><CODE>Cudd_ReadPermZdd()</CODE></A> - <DD> Returns the current position of the i-th ZDD variable in the - order. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadInvPerm" TARGET="MAIN"><CODE>Cudd_ReadInvPerm()</CODE></A> - <DD> Returns the index of the variable currently in the i-th - position of the order. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadInvPermZdd" TARGET="MAIN"><CODE>Cudd_ReadInvPermZdd()</CODE></A> - <DD> Returns the index of the ZDD variable currently in the i-th - position of the order. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadVars" TARGET="MAIN"><CODE>Cudd_ReadVars()</CODE></A> - <DD> Returns the i-th element of the vars array. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadEpsilon" TARGET="MAIN"><CODE>Cudd_ReadEpsilon()</CODE></A> - <DD> Reads the epsilon parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetEpsilon" TARGET="MAIN"><CODE>Cudd_SetEpsilon()</CODE></A> - <DD> Sets the epsilon parameter of the manager to ep. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadGroupcheck" TARGET="MAIN"><CODE>Cudd_ReadGroupcheck()</CODE></A> - <DD> Reads the groupcheck parameter of the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetGroupcheck" TARGET="MAIN"><CODE>Cudd_SetGroupcheck()</CODE></A> - <DD> Sets the parameter groupcheck of the manager to gc. - - <DT> <A HREF="cuddAllDet.html#Cudd_GarbageCollectionEnabled" TARGET="MAIN"><CODE>Cudd_GarbageCollectionEnabled()</CODE></A> - <DD> Tells whether garbage collection is enabled. - - <DT> <A HREF="cuddAllDet.html#Cudd_EnableGarbageCollection" TARGET="MAIN"><CODE>Cudd_EnableGarbageCollection()</CODE></A> - <DD> Enables garbage collection. - - <DT> <A HREF="cuddAllDet.html#Cudd_DisableGarbageCollection" TARGET="MAIN"><CODE>Cudd_DisableGarbageCollection()</CODE></A> - <DD> Disables garbage collection. - - <DT> <A HREF="cuddAllDet.html#Cudd_DeadAreCounted" TARGET="MAIN"><CODE>Cudd_DeadAreCounted()</CODE></A> - <DD> Tells whether dead nodes are counted towards triggering - reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_TurnOnCountDead" TARGET="MAIN"><CODE>Cudd_TurnOnCountDead()</CODE></A> - <DD> Causes the dead nodes to be counted towards triggering - reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_TurnOffCountDead" TARGET="MAIN"><CODE>Cudd_TurnOffCountDead()</CODE></A> - <DD> Causes the dead nodes not to be counted towards triggering - reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadRecomb" TARGET="MAIN"><CODE>Cudd_ReadRecomb()</CODE></A> - <DD> Returns the current value of the recombination parameter used - in group sifting. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetRecomb" TARGET="MAIN"><CODE>Cudd_SetRecomb()</CODE></A> - <DD> Sets the value of the recombination parameter used in group - sifting. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadSymmviolation" TARGET="MAIN"><CODE>Cudd_ReadSymmviolation()</CODE></A> - <DD> Returns the current value of the symmviolation parameter used - in group sifting. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetSymmviolation" TARGET="MAIN"><CODE>Cudd_SetSymmviolation()</CODE></A> - <DD> Sets the value of the symmviolation parameter used - in group sifting. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadArcviolation" TARGET="MAIN"><CODE>Cudd_ReadArcviolation()</CODE></A> - <DD> Returns the current value of the arcviolation parameter used - in group sifting. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetArcviolation" TARGET="MAIN"><CODE>Cudd_SetArcviolation()</CODE></A> - <DD> Sets the value of the arcviolation parameter used - in group sifting. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadPopulationSize" TARGET="MAIN"><CODE>Cudd_ReadPopulationSize()</CODE></A> - <DD> Reads the current size of the population used by the - genetic algorithm for reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetPopulationSize" TARGET="MAIN"><CODE>Cudd_SetPopulationSize()</CODE></A> - <DD> Sets the size of the population used by the - genetic algorithm for reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadNumberXovers" TARGET="MAIN"><CODE>Cudd_ReadNumberXovers()</CODE></A> - <DD> Reads the current number of crossovers used by the - genetic algorithm for reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetNumberXovers" TARGET="MAIN"><CODE>Cudd_SetNumberXovers()</CODE></A> - <DD> Sets the number of crossovers used by the - genetic algorithm for reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadOrderRandomization" TARGET="MAIN"><CODE>Cudd_ReadOrderRandomization()</CODE></A> - <DD> Returns the order randomization factor. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetOrderRandomization" TARGET="MAIN"><CODE>Cudd_SetOrderRandomization()</CODE></A> - <DD> Sets the order randomization factor. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadMemoryInUse" TARGET="MAIN"><CODE>Cudd_ReadMemoryInUse()</CODE></A> - <DD> Returns the memory in use by the manager measured in bytes. - - <DT> <A HREF="cuddAllDet.html#Cudd_PrintInfo" TARGET="MAIN"><CODE>Cudd_PrintInfo()</CODE></A> - <DD> Prints out statistics and settings for a CUDD manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadPeakNodeCount" TARGET="MAIN"><CODE>Cudd_ReadPeakNodeCount()</CODE></A> - <DD> Reports the peak number of nodes. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadPeakLiveNodeCount" TARGET="MAIN"><CODE>Cudd_ReadPeakLiveNodeCount()</CODE></A> - <DD> Reports the peak number of live nodes. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadNodeCount" TARGET="MAIN"><CODE>Cudd_ReadNodeCount()</CODE></A> - <DD> Reports the number of nodes in BDDs and ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddReadNodeCount" TARGET="MAIN"><CODE>Cudd_zddReadNodeCount()</CODE></A> - <DD> Reports the number of nodes in ZDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_AddHook" TARGET="MAIN"><CODE>Cudd_AddHook()</CODE></A> - <DD> Adds a function to a hook. - - <DT> <A HREF="cuddAllDet.html#Cudd_RemoveHook" TARGET="MAIN"><CODE>Cudd_RemoveHook()</CODE></A> - <DD> Removes a function from a hook. - - <DT> <A HREF="cuddAllDet.html#Cudd_IsInHook" TARGET="MAIN"><CODE>Cudd_IsInHook()</CODE></A> - <DD> Checks whether a function is in a hook. - - <DT> <A HREF="cuddAllDet.html#Cudd_StdPreReordHook" TARGET="MAIN"><CODE>Cudd_StdPreReordHook()</CODE></A> - <DD> Sample hook function to call before reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_StdPostReordHook" TARGET="MAIN"><CODE>Cudd_StdPostReordHook()</CODE></A> - <DD> Sample hook function to call after reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_EnableReorderingReporting" TARGET="MAIN"><CODE>Cudd_EnableReorderingReporting()</CODE></A> - <DD> Enables reporting of reordering stats. - - <DT> <A HREF="cuddAllDet.html#Cudd_DisableReorderingReporting" TARGET="MAIN"><CODE>Cudd_DisableReorderingReporting()</CODE></A> - <DD> Disables reporting of reordering stats. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReorderingReporting" TARGET="MAIN"><CODE>Cudd_ReorderingReporting()</CODE></A> - <DD> Returns 1 if reporting of reordering stats is enabled. - - <DT> <A HREF="cuddAllDet.html#Cudd_PrintGroupedOrder" TARGET="MAIN"><CODE>Cudd_PrintGroupedOrder()</CODE></A> - <DD> Hook function to print the current variable order. - - <DT> <A HREF="cuddAllDet.html#Cudd_EnableOrderingMonitoring" TARGET="MAIN"><CODE>Cudd_EnableOrderingMonitoring()</CODE></A> - <DD> Enables monitoring of ordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_DisableOrderingMonitoring" TARGET="MAIN"><CODE>Cudd_DisableOrderingMonitoring()</CODE></A> - <DD> Disables monitoring of ordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_OrderingMonitoring" TARGET="MAIN"><CODE>Cudd_OrderingMonitoring()</CODE></A> - <DD> Returns 1 if monitoring of ordering is enabled. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadErrorCode" TARGET="MAIN"><CODE>Cudd_ReadErrorCode()</CODE></A> - <DD> Returns the code of the last error. - - <DT> <A HREF="cuddAllDet.html#Cudd_ClearErrorCode" TARGET="MAIN"><CODE>Cudd_ClearErrorCode()</CODE></A> - <DD> Clear the error code of a manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadStdout" TARGET="MAIN"><CODE>Cudd_ReadStdout()</CODE></A> - <DD> Reads the stdout of a manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetStdout" TARGET="MAIN"><CODE>Cudd_SetStdout()</CODE></A> - <DD> Sets the stdout of a manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadStderr" TARGET="MAIN"><CODE>Cudd_ReadStderr()</CODE></A> - <DD> Reads the stderr of a manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetStderr" TARGET="MAIN"><CODE>Cudd_SetStderr()</CODE></A> - <DD> Sets the stderr of a manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadNextReordering" TARGET="MAIN"><CODE>Cudd_ReadNextReordering()</CODE></A> - <DD> Returns the threshold for the next dynamic reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetNextReordering" TARGET="MAIN"><CODE>Cudd_SetNextReordering()</CODE></A> - <DD> Sets the threshold for the next dynamic reordering. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadSwapSteps" TARGET="MAIN"><CODE>Cudd_ReadSwapSteps()</CODE></A> - <DD> Reads the number of elementary reordering steps. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxLive" TARGET="MAIN"><CODE>Cudd_ReadMaxLive()</CODE></A> - <DD> Reads the maximum allowed number of live nodes. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetMaxLive" TARGET="MAIN"><CODE>Cudd_SetMaxLive()</CODE></A> - <DD> Sets the maximum allowed number of live nodes. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadMaxMemory" TARGET="MAIN"><CODE>Cudd_ReadMaxMemory()</CODE></A> - <DD> Reads the maximum allowed memory. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetMaxMemory" TARGET="MAIN"><CODE>Cudd_SetMaxMemory()</CODE></A> - <DD> Sets the maximum allowed memory. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddBindVar" TARGET="MAIN"><CODE>Cudd_bddBindVar()</CODE></A> - <DD> Prevents sifting of a variable. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddUnbindVar" TARGET="MAIN"><CODE>Cudd_bddUnbindVar()</CODE></A> - <DD> Allows the sifting of a variable. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddVarIsBound" TARGET="MAIN"><CODE>Cudd_bddVarIsBound()</CODE></A> - <DD> Tells whether a variable can be sifted. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddSetPiVar" TARGET="MAIN"><CODE>Cudd_bddSetPiVar()</CODE></A> - <DD> Sets a variable type to primary input. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddSetPsVar" TARGET="MAIN"><CODE>Cudd_bddSetPsVar()</CODE></A> - <DD> Sets a variable type to present state. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddSetNsVar" TARGET="MAIN"><CODE>Cudd_bddSetNsVar()</CODE></A> - <DD> Sets a variable type to next state. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIsPiVar" TARGET="MAIN"><CODE>Cudd_bddIsPiVar()</CODE></A> - <DD> Checks whether a variable is primary input. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIsPsVar" TARGET="MAIN"><CODE>Cudd_bddIsPsVar()</CODE></A> - <DD> Checks whether a variable is present state. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIsNsVar" TARGET="MAIN"><CODE>Cudd_bddIsNsVar()</CODE></A> - <DD> Checks whether a variable is next state. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddSetPairIndex" TARGET="MAIN"><CODE>Cudd_bddSetPairIndex()</CODE></A> - <DD> Sets a corresponding pair index for a given index. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddReadPairIndex" TARGET="MAIN"><CODE>Cudd_bddReadPairIndex()</CODE></A> - <DD> Reads a corresponding pair index for a given index. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddSetVarToBeGrouped" TARGET="MAIN"><CODE>Cudd_bddSetVarToBeGrouped()</CODE></A> - <DD> Sets a variable to be grouped. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddSetVarHardGroup" TARGET="MAIN"><CODE>Cudd_bddSetVarHardGroup()</CODE></A> - <DD> Sets a variable to be a hard group. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddResetVarToBeGrouped" TARGET="MAIN"><CODE>Cudd_bddResetVarToBeGrouped()</CODE></A> - <DD> Resets a variable not to be grouped. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIsVarToBeGrouped" TARGET="MAIN"><CODE>Cudd_bddIsVarToBeGrouped()</CODE></A> - <DD> Checks whether a variable is set to be grouped. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddSetVarToBeUngrouped" TARGET="MAIN"><CODE>Cudd_bddSetVarToBeUngrouped()</CODE></A> - <DD> Sets a variable to be ungrouped. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIsVarToBeUngrouped" TARGET="MAIN"><CODE>Cudd_bddIsVarToBeUngrouped()</CODE></A> - <DD> Checks whether a variable is set to be ungrouped. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIsVarHardGroup" TARGET="MAIN"><CODE>Cudd_bddIsVarHardGroup()</CODE></A> - <DD> Checks whether a variable is set to be in a hard group. - - <DT> <A HREF="cuddAllDet.html#fixVarTree" TARGET="MAIN"><CODE>fixVarTree()</CODE></A> - <DD> Fixes a variable group tree. - - <DT> <A HREF="cuddAllDet.html#addMultiplicityGroups" TARGET="MAIN"><CODE>addMultiplicityGroups()</CODE></A> - <DD> Adds multiplicity groups to a ZDD variable group tree. - -</DL> -<HR> -<A NAME="cuddApprox.c"><H1>cuddApprox.c</H1></A> -Procedures to approximate a given BDD. <P> -<B>By: Fabio Somenzi</B><P> -External procedures provided by this module: - <ul> - <li> Cudd_UnderApprox() - <li> Cudd_OverApprox() - <li> Cudd_RemapUnderApprox() - <li> Cudd_RemapOverApprox() - <li> Cudd_BiasedUnderApprox() - <li> Cudd_BiasedOverApprox() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddUnderApprox() - <li> cuddRemapUnderApprox() - <li> cuddBiasedUnderApprox() - </ul> - Static procedures included in this module: - <ul> - <li> updateParity() - <li> gatherInfoAux() - <li> gatherInfo() - <li> computeSavings() - <li> updateRefs() - <li> UAmarkNodes() - <li> UAbuildSubset() - <li> RAmarkNodes() - <li> BAmarkNodes() - <li> RAbuildSubset() - <li> BAapplyBias() - </ul> <P> -<P><B>See Also</B><A HREF="#cuddSubsetHB.c"><CODE>cuddSubsetHB.c</CODE></A> -<A HREF="#cuddSubsetSP.c"><CODE>cuddSubsetSP.c</CODE></A> -<A HREF="#cuddGenCof.c"><CODE>cuddGenCof.c</CODE></A> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_UnderApprox" TARGET="MAIN"><CODE>Cudd_UnderApprox()</CODE></A> - <DD> Extracts a dense subset from a BDD with Shiple's - underapproximation method. - - <DT> <A HREF="cuddAllDet.html#Cudd_OverApprox" TARGET="MAIN"><CODE>Cudd_OverApprox()</CODE></A> - <DD> Extracts a dense superset from a BDD with Shiple's - underapproximation method. - - <DT> <A HREF="cuddAllDet.html#Cudd_RemapUnderApprox" TARGET="MAIN"><CODE>Cudd_RemapUnderApprox()</CODE></A> - <DD> Extracts a dense subset from a BDD with the remapping - underapproximation method. - - <DT> <A HREF="cuddAllDet.html#Cudd_RemapOverApprox" TARGET="MAIN"><CODE>Cudd_RemapOverApprox()</CODE></A> - <DD> Extracts a dense superset from a BDD with the remapping - underapproximation method. - - <DT> <A HREF="cuddAllDet.html#Cudd_BiasedUnderApprox" TARGET="MAIN"><CODE>Cudd_BiasedUnderApprox()</CODE></A> - <DD> Extracts a dense subset from a BDD with the biased - underapproximation method. - - <DT> <A HREF="cuddAllDet.html#Cudd_BiasedOverApprox" TARGET="MAIN"><CODE>Cudd_BiasedOverApprox()</CODE></A> - <DD> Extracts a dense superset from a BDD with the biased - underapproximation method. - - <DT> <A HREF="cuddAllDet.html#cuddUnderApprox" TARGET="MAIN"><CODE>cuddUnderApprox()</CODE></A> - <DD> Applies Tom Shiple's underappoximation algorithm. - - <DT> <A HREF="cuddAllDet.html#cuddRemapUnderApprox" TARGET="MAIN"><CODE>cuddRemapUnderApprox()</CODE></A> - <DD> Applies the remapping underappoximation algorithm. - - <DT> <A HREF="cuddAllDet.html#cuddBiasedUnderApprox" TARGET="MAIN"><CODE>cuddBiasedUnderApprox()</CODE></A> - <DD> Applies the biased remapping underappoximation algorithm. - - <DT> <A HREF="cuddAllDet.html#updateParity" TARGET="MAIN"><CODE>updateParity()</CODE></A> - <DD> Recursively update the parity of the paths reaching a node. - - <DT> <A HREF="cuddAllDet.html#gatherInfoAux" TARGET="MAIN"><CODE>gatherInfoAux()</CODE></A> - <DD> Recursively counts minterms and computes reference counts - of each node in the BDD. - - <DT> <A HREF="cuddAllDet.html#gatherInfo" TARGET="MAIN"><CODE>gatherInfo()</CODE></A> - <DD> Gathers information about each node. - - <DT> <A HREF="cuddAllDet.html#computeSavings" TARGET="MAIN"><CODE>computeSavings()</CODE></A> - <DD> Counts the nodes that would be eliminated if a given node - were replaced by zero. - - <DT> <A HREF="cuddAllDet.html#updateRefs" TARGET="MAIN"><CODE>updateRefs()</CODE></A> - <DD> Update function reference counts. - - <DT> <A HREF="cuddAllDet.html#UAmarkNodes" TARGET="MAIN"><CODE>UAmarkNodes()</CODE></A> - <DD> Marks nodes for replacement by zero. - - <DT> <A HREF="cuddAllDet.html#UAbuildSubset" TARGET="MAIN"><CODE>UAbuildSubset()</CODE></A> - <DD> Builds the subset BDD. - - <DT> <A HREF="cuddAllDet.html#RAmarkNodes" TARGET="MAIN"><CODE>RAmarkNodes()</CODE></A> - <DD> Marks nodes for remapping. - - <DT> <A HREF="cuddAllDet.html#BAmarkNodes" TARGET="MAIN"><CODE>BAmarkNodes()</CODE></A> - <DD> Marks nodes for remapping. - - <DT> <A HREF="cuddAllDet.html#RAbuildSubset" TARGET="MAIN"><CODE>RAbuildSubset()</CODE></A> - <DD> Builds the subset BDD for cuddRemapUnderApprox. - - <DT> <A HREF="cuddAllDet.html#BAapplyBias" TARGET="MAIN"><CODE>BAapplyBias()</CODE></A> - <DD> Finds don't care nodes. - -</DL> -<HR> -<A NAME="cuddBddAbs.c"><H1>cuddBddAbs.c</H1></A> -Quantification functions for BDDs. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_bddExistAbstract() - <li> Cudd_bddExistAbstractLimit() - <li> Cudd_bddXorExistAbstract() - <li> Cudd_bddUnivAbstract() - <li> Cudd_bddBooleanDiff() - <li> Cudd_bddVarIsDependent() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddExistAbstractRecur() - <li> cuddBddXorExistAbstractRecur() - <li> cuddBddBooleanDiffRecur() - </ul> - Static procedures included in this module: - <ul> - <li> bddCheckPositiveCube() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_bddExistAbstract" TARGET="MAIN"><CODE>Cudd_bddExistAbstract()</CODE></A> - <DD> Existentially abstracts all the variables in cube from f. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddExistAbstractLimit" TARGET="MAIN"><CODE>Cudd_bddExistAbstractLimit()</CODE></A> - <DD> Existentially abstracts all the variables in cube from f. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddXorExistAbstract" TARGET="MAIN"><CODE>Cudd_bddXorExistAbstract()</CODE></A> - <DD> Takes the exclusive OR of two BDDs and simultaneously abstracts the - variables in cube. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddUnivAbstract" TARGET="MAIN"><CODE>Cudd_bddUnivAbstract()</CODE></A> - <DD> Universally abstracts all the variables in cube from f. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddBooleanDiff" TARGET="MAIN"><CODE>Cudd_bddBooleanDiff()</CODE></A> - <DD> Computes the boolean difference of f with respect to x. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddVarIsDependent" TARGET="MAIN"><CODE>Cudd_bddVarIsDependent()</CODE></A> - <DD> Checks whether a variable is dependent on others in a - function. - - <DT> <A HREF="cuddAllDet.html#cuddBddExistAbstractRecur" TARGET="MAIN"><CODE>cuddBddExistAbstractRecur()</CODE></A> - <DD> Performs the recursive steps of Cudd_bddExistAbstract. - - <DT> <A HREF="cuddAllDet.html#cuddBddXorExistAbstractRecur" TARGET="MAIN"><CODE>cuddBddXorExistAbstractRecur()</CODE></A> - <DD> Takes the exclusive OR of two BDDs and simultaneously abstracts the - variables in cube. - - <DT> <A HREF="cuddAllDet.html#cuddBddBooleanDiffRecur" TARGET="MAIN"><CODE>cuddBddBooleanDiffRecur()</CODE></A> - <DD> Performs the recursive steps of Cudd_bddBoleanDiff. - - <DT> <A HREF="cuddAllDet.html#bddCheckPositiveCube" TARGET="MAIN"><CODE>bddCheckPositiveCube()</CODE></A> - <DD> Checks whether cube is an BDD representing the product of - positive literals. - -</DL> -<HR> -<A NAME="cuddBddCorr.c"><H1>cuddBddCorr.c</H1></A> -Correlation between BDDs. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_bddCorrelation() - <li> Cudd_bddCorrelationWeights() - </ul> - Static procedures included in this module: - <ul> - <li> bddCorrelationAux() - <li> bddCorrelationWeightsAux() - <li> CorrelCompare() - <li> CorrelHash() - <li> CorrelCleanUp() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_bddCorrelation" TARGET="MAIN"><CODE>Cudd_bddCorrelation()</CODE></A> - <DD> Computes the correlation of f and g. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddCorrelationWeights" TARGET="MAIN"><CODE>Cudd_bddCorrelationWeights()</CODE></A> - <DD> Computes the correlation of f and g for given input - probabilities. - - <DT> <A HREF="cuddAllDet.html#bddCorrelationAux" TARGET="MAIN"><CODE>bddCorrelationAux()</CODE></A> - <DD> Performs the recursive step of Cudd_bddCorrelation. - - <DT> <A HREF="cuddAllDet.html#bddCorrelationWeightsAux" TARGET="MAIN"><CODE>bddCorrelationWeightsAux()</CODE></A> - <DD> Performs the recursive step of Cudd_bddCorrelationWeigths. - - <DT> <A HREF="cuddAllDet.html#CorrelCompare" TARGET="MAIN"><CODE>CorrelCompare()</CODE></A> - <DD> Compares two hash table entries. - - <DT> <A HREF="cuddAllDet.html#CorrelHash" TARGET="MAIN"><CODE>CorrelHash()</CODE></A> - <DD> Hashes a hash table entry. - - <DT> <A HREF="cuddAllDet.html#CorrelCleanUp" TARGET="MAIN"><CODE>CorrelCleanUp()</CODE></A> - <DD> Frees memory associated with hash table. - -</DL> -<HR> -<A NAME="cuddBddIte.c"><H1>cuddBddIte.c</H1></A> -BDD ITE function and satellites. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_bddIte() - <li> Cudd_bddIteLimit() - <li> Cudd_bddIteConstant() - <li> Cudd_bddIntersect() - <li> Cudd_bddAnd() - <li> Cudd_bddAndLimit() - <li> Cudd_bddOr() - <li> Cudd_bddOrLimit() - <li> Cudd_bddNand() - <li> Cudd_bddNor() - <li> Cudd_bddXor() - <li> Cudd_bddXnor() - <li> Cudd_bddXnorLimit() - <li> Cudd_bddLeq() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddIteRecur() - <li> cuddBddIntersectRecur() - <li> cuddBddAndRecur() - <li> cuddBddXorRecur() - </ul> - Static procedures included in this module: - <ul> - <li> bddVarToConst() - <li> bddVarToCanonical() - <li> bddVarToCanonicalSimple() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_bddIte" TARGET="MAIN"><CODE>Cudd_bddIte()</CODE></A> - <DD> Implements ITE(f,g,h). - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIteLimit" TARGET="MAIN"><CODE>Cudd_bddIteLimit()</CODE></A> - <DD> Implements ITE(f,g,h). Returns - NULL if too many nodes are required. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIteConstant" TARGET="MAIN"><CODE>Cudd_bddIteConstant()</CODE></A> - <DD> Implements ITEconstant(f,g,h). - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIntersect" TARGET="MAIN"><CODE>Cudd_bddIntersect()</CODE></A> - <DD> Returns a function included in the intersection of f and g. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddAnd" TARGET="MAIN"><CODE>Cudd_bddAnd()</CODE></A> - <DD> Computes the conjunction of two BDDs f and g. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddAndLimit" TARGET="MAIN"><CODE>Cudd_bddAndLimit()</CODE></A> - <DD> Computes the conjunction of two BDDs f and g. Returns - NULL if too many nodes are required. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddOr" TARGET="MAIN"><CODE>Cudd_bddOr()</CODE></A> - <DD> Computes the disjunction of two BDDs f and g. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddOrLimit" TARGET="MAIN"><CODE>Cudd_bddOrLimit()</CODE></A> - <DD> Computes the disjunction of two BDDs f and g. Returns - NULL if too many nodes are required. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddNand" TARGET="MAIN"><CODE>Cudd_bddNand()</CODE></A> - <DD> Computes the NAND of two BDDs f and g. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddNor" TARGET="MAIN"><CODE>Cudd_bddNor()</CODE></A> - <DD> Computes the NOR of two BDDs f and g. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddXor" TARGET="MAIN"><CODE>Cudd_bddXor()</CODE></A> - <DD> Computes the exclusive OR of two BDDs f and g. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddXnor" TARGET="MAIN"><CODE>Cudd_bddXnor()</CODE></A> - <DD> Computes the exclusive NOR of two BDDs f and g. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddXnorLimit" TARGET="MAIN"><CODE>Cudd_bddXnorLimit()</CODE></A> - <DD> Computes the exclusive NOR of two BDDs f and g. Returns - NULL if too many nodes are required. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddLeq" TARGET="MAIN"><CODE>Cudd_bddLeq()</CODE></A> - <DD> Determines whether f is less than or equal to g. - - <DT> <A HREF="cuddAllDet.html#cuddBddIteRecur" TARGET="MAIN"><CODE>cuddBddIteRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_bddIte. - - <DT> <A HREF="cuddAllDet.html#cuddBddIntersectRecur" TARGET="MAIN"><CODE>cuddBddIntersectRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_bddIntersect. - - <DT> <A HREF="cuddAllDet.html#cuddBddAndRecur" TARGET="MAIN"><CODE>cuddBddAndRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_bddAnd. - - <DT> <A HREF="cuddAllDet.html#cuddBddXorRecur" TARGET="MAIN"><CODE>cuddBddXorRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_bddXor. - - <DT> <A HREF="cuddAllDet.html#bddVarToConst" TARGET="MAIN"><CODE>bddVarToConst()</CODE></A> - <DD> Replaces variables with constants if possible. - - <DT> <A HREF="cuddAllDet.html#bddVarToCanonical" TARGET="MAIN"><CODE>bddVarToCanonical()</CODE></A> - <DD> Picks unique member from equiv expressions. - - <DT> <A HREF="cuddAllDet.html#bddVarToCanonicalSimple" TARGET="MAIN"><CODE>bddVarToCanonicalSimple()</CODE></A> - <DD> Picks unique member from equiv expressions. - -</DL> -<HR> -<A NAME="cuddBridge.c"><H1>cuddBridge.c</H1></A> -Translation from BDD to ADD and vice versa and transfer between - different managers. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this file: - <ul> - <li> Cudd_addBddThreshold() - <li> Cudd_addBddStrictThreshold() - <li> Cudd_addBddInterval() - <li> Cudd_addBddIthBit() - <li> Cudd_BddToAdd() - <li> Cudd_addBddPattern() - <li> Cudd_bddTransfer() - </ul> - Internal procedures included in this file: - <ul> - <li> cuddBddTransfer() - <li> cuddAddBddDoPattern() - </ul> - Static procedures included in this file: - <ul> - <li> addBddDoThreshold() - <li> addBddDoStrictThreshold() - <li> addBddDoInterval() - <li> addBddDoIthBit() - <li> ddBddToAddRecur() - <li> cuddBddTransferRecur() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addBddThreshold" TARGET="MAIN"><CODE>Cudd_addBddThreshold()</CODE></A> - <DD> Converts an ADD to a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_addBddStrictThreshold" TARGET="MAIN"><CODE>Cudd_addBddStrictThreshold()</CODE></A> - <DD> Converts an ADD to a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_addBddInterval" TARGET="MAIN"><CODE>Cudd_addBddInterval()</CODE></A> - <DD> Converts an ADD to a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_addBddIthBit" TARGET="MAIN"><CODE>Cudd_addBddIthBit()</CODE></A> - <DD> Converts an ADD to a BDD by extracting the i-th bit from - the leaves. - - <DT> <A HREF="cuddAllDet.html#Cudd_BddToAdd" TARGET="MAIN"><CODE>Cudd_BddToAdd()</CODE></A> - <DD> Converts a BDD to a 0-1 ADD. - - <DT> <A HREF="cuddAllDet.html#Cudd_addBddPattern" TARGET="MAIN"><CODE>Cudd_addBddPattern()</CODE></A> - <DD> Converts an ADD to a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddTransfer" TARGET="MAIN"><CODE>Cudd_bddTransfer()</CODE></A> - <DD> Convert a BDD from a manager to another one. - - <DT> <A HREF="cuddAllDet.html#cuddBddTransfer" TARGET="MAIN"><CODE>cuddBddTransfer()</CODE></A> - <DD> Convert a BDD from a manager to another one. - - <DT> <A HREF="cuddAllDet.html#cuddAddBddDoPattern" TARGET="MAIN"><CODE>cuddAddBddDoPattern()</CODE></A> - <DD> Performs the recursive step for Cudd_addBddPattern. - - <DT> <A HREF="cuddAllDet.html#addBddDoThreshold" TARGET="MAIN"><CODE>addBddDoThreshold()</CODE></A> - <DD> Performs the recursive step for Cudd_addBddThreshold. - - <DT> <A HREF="cuddAllDet.html#addBddDoStrictThreshold" TARGET="MAIN"><CODE>addBddDoStrictThreshold()</CODE></A> - <DD> Performs the recursive step for Cudd_addBddStrictThreshold. - - <DT> <A HREF="cuddAllDet.html#addBddDoInterval" TARGET="MAIN"><CODE>addBddDoInterval()</CODE></A> - <DD> Performs the recursive step for Cudd_addBddInterval. - - <DT> <A HREF="cuddAllDet.html#addBddDoIthBit" TARGET="MAIN"><CODE>addBddDoIthBit()</CODE></A> - <DD> Performs the recursive step for Cudd_addBddIthBit. - - <DT> <A HREF="cuddAllDet.html#ddBddToAddRecur" TARGET="MAIN"><CODE>ddBddToAddRecur()</CODE></A> - <DD> Performs the recursive step for Cudd_BddToAdd. - - <DT> <A HREF="cuddAllDet.html#cuddBddTransferRecur" TARGET="MAIN"><CODE>cuddBddTransferRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_bddTransfer. - -</DL> -<HR> -<A NAME="cuddCache.c"><H1>cuddCache.c</H1></A> -Functions for cache insertion and lookup. <P> -<B>By: Fabio Somenzi</B><P> -Internal procedures included in this module: - <ul> - <li> cuddInitCache() - <li> cuddCacheInsert() - <li> cuddCacheInsert2() - <li> cuddCacheLookup() - <li> cuddCacheLookupZdd() - <li> cuddCacheLookup2() - <li> cuddCacheLookup2Zdd() - <li> cuddConstantLookup() - <li> cuddCacheProfile() - <li> cuddCacheResize() - <li> cuddCacheFlush() - <li> cuddComputeFloorLog2() - </ul> - Static procedures included in this module: - <ul> - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#cuddInitCache" TARGET="MAIN"><CODE>cuddInitCache()</CODE></A> - <DD> Initializes the computed table. - - <DT> <A HREF="cuddAllDet.html#cuddCacheInsert" TARGET="MAIN"><CODE>cuddCacheInsert()</CODE></A> - <DD> Inserts a result in the cache for a function with three - operands. - - <DT> <A HREF="cuddAllDet.html#cuddCacheInsert2" TARGET="MAIN"><CODE>cuddCacheInsert2()</CODE></A> - <DD> Inserts a result in the cache for a function with two - operands. - - <DT> <A HREF="cuddAllDet.html#cuddCacheInsert1" TARGET="MAIN"><CODE>cuddCacheInsert1()</CODE></A> - <DD> Inserts a result in the cache for a function with two - operands. - - <DT> <A HREF="cuddAllDet.html#cuddCacheLookup" TARGET="MAIN"><CODE>cuddCacheLookup()</CODE></A> - <DD> Looks up in the cache for the result of op applied to f, - g, and h. - - <DT> <A HREF="cuddAllDet.html#cuddCacheLookupZdd" TARGET="MAIN"><CODE>cuddCacheLookupZdd()</CODE></A> - <DD> Looks up in the cache for the result of op applied to f, - g, and h. - - <DT> <A HREF="cuddAllDet.html#cuddCacheLookup2" TARGET="MAIN"><CODE>cuddCacheLookup2()</CODE></A> - <DD> Looks up in the cache for the result of op applied to f - and g. - - <DT> <A HREF="cuddAllDet.html#cuddCacheLookup1" TARGET="MAIN"><CODE>cuddCacheLookup1()</CODE></A> - <DD> Looks up in the cache for the result of op applied to f. - - <DT> <A HREF="cuddAllDet.html#cuddCacheLookup2Zdd" TARGET="MAIN"><CODE>cuddCacheLookup2Zdd()</CODE></A> - <DD> Looks up in the cache for the result of op applied to f - and g. - - <DT> <A HREF="cuddAllDet.html#cuddCacheLookup1Zdd" TARGET="MAIN"><CODE>cuddCacheLookup1Zdd()</CODE></A> - <DD> Looks up in the cache for the result of op applied to f. - - <DT> <A HREF="cuddAllDet.html#cuddConstantLookup" TARGET="MAIN"><CODE>cuddConstantLookup()</CODE></A> - <DD> Looks up in the cache for the result of op applied to f, - g, and h. - - <DT> <A HREF="cuddAllDet.html#cuddCacheProfile" TARGET="MAIN"><CODE>cuddCacheProfile()</CODE></A> - <DD> Computes and prints a profile of the cache usage. - - <DT> <A HREF="cuddAllDet.html#cuddCacheResize" TARGET="MAIN"><CODE>cuddCacheResize()</CODE></A> - <DD> Resizes the cache. - - <DT> <A HREF="cuddAllDet.html#cuddCacheFlush" TARGET="MAIN"><CODE>cuddCacheFlush()</CODE></A> - <DD> Flushes the cache. - - <DT> <A HREF="cuddAllDet.html#cuddComputeFloorLog2" TARGET="MAIN"><CODE>cuddComputeFloorLog2()</CODE></A> - <DD> Returns the floor of the logarithm to the base 2. - -</DL> -<HR> -<A NAME="cuddCheck.c"><H1>cuddCheck.c</H1></A> -Functions to check consistency of data structures. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_DebugCheck() - <li> Cudd_CheckKeys() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddHeapProfile() - <li> cuddPrintNode() - <li> cuddPrintVarGroups() - </ul> - Static procedures included in this module: - <ul> - <li> debugFindParent() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_DebugCheck" TARGET="MAIN"><CODE>Cudd_DebugCheck()</CODE></A> - <DD> Checks for inconsistencies in the DD heap. - - <DT> <A HREF="cuddAllDet.html#Cudd_CheckKeys" TARGET="MAIN"><CODE>Cudd_CheckKeys()</CODE></A> - <DD> Checks for several conditions that should not occur. - - <DT> <A HREF="cuddAllDet.html#cuddHeapProfile" TARGET="MAIN"><CODE>cuddHeapProfile()</CODE></A> - <DD> Prints information about the heap. - - <DT> <A HREF="cuddAllDet.html#cuddPrintNode" TARGET="MAIN"><CODE>cuddPrintNode()</CODE></A> - <DD> Prints out information on a node. - - <DT> <A HREF="cuddAllDet.html#cuddPrintVarGroups" TARGET="MAIN"><CODE>cuddPrintVarGroups()</CODE></A> - <DD> Prints the variable groups as a parenthesized list. - - <DT> <A HREF="cuddAllDet.html#debugFindParent" TARGET="MAIN"><CODE>debugFindParent()</CODE></A> - <DD> Searches the subtables above node for its parents. - - <DT> <A HREF="cuddAllDet.html#debugCheckParent" TARGET="MAIN"><CODE>debugCheckParent()</CODE></A> - <DD> Reports an error if a (dead) node has a non-dead parent. - -</DL> -<HR> -<A NAME="cuddClip.c"><H1>cuddClip.c</H1></A> -Clipping functions. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_bddClippingAnd() - <li> Cudd_bddClippingAndAbstract() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddClippingAnd() - <li> cuddBddClippingAndAbstract() - </ul> - Static procedures included in this module: - <ul> - <li> cuddBddClippingAndRecur() - <li> cuddBddClipAndAbsRecur() - </ul> - - SeeAlso [ <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_bddClippingAnd" TARGET="MAIN"><CODE>Cudd_bddClippingAnd()</CODE></A> - <DD> Approximates the conjunction of two BDDs f and g. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddClippingAndAbstract" TARGET="MAIN"><CODE>Cudd_bddClippingAndAbstract()</CODE></A> - <DD> Approximates the conjunction of two BDDs f and g and - simultaneously abstracts the variables in cube. - - <DT> <A HREF="cuddAllDet.html#cuddBddClippingAnd" TARGET="MAIN"><CODE>cuddBddClippingAnd()</CODE></A> - <DD> Approximates the conjunction of two BDDs f and g. - - <DT> <A HREF="cuddAllDet.html#cuddBddClippingAndAbstract" TARGET="MAIN"><CODE>cuddBddClippingAndAbstract()</CODE></A> - <DD> Approximates the conjunction of two BDDs f and g and - simultaneously abstracts the variables in cube. - - <DT> <A HREF="cuddAllDet.html#cuddBddClippingAndRecur" TARGET="MAIN"><CODE>cuddBddClippingAndRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_bddClippingAnd. - - <DT> <A HREF="cuddAllDet.html#cuddBddClipAndAbsRecur" TARGET="MAIN"><CODE>cuddBddClipAndAbsRecur()</CODE></A> - <DD> Approximates the AND of two BDDs and simultaneously abstracts the - variables in cube. - -</DL> -<HR> -<A NAME="cuddCof.c"><H1>cuddCof.c</H1></A> -Cofactoring functions. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_Cofactor() - <li> Cudd_CheckCube() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddGetBranches() - <li> cuddCofactorRecur() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_Cofactor" TARGET="MAIN"><CODE>Cudd_Cofactor()</CODE></A> - <DD> Computes the cofactor of f with respect to g. - - <DT> <A HREF="cuddAllDet.html#Cudd_CheckCube" TARGET="MAIN"><CODE>Cudd_CheckCube()</CODE></A> - <DD> Checks whether g is the BDD of a cube. - - <DT> <A HREF="cuddAllDet.html#cuddGetBranches" TARGET="MAIN"><CODE>cuddGetBranches()</CODE></A> - <DD> Computes the children of g. - - <DT> <A HREF="cuddAllDet.html#cuddCofactorRecur" TARGET="MAIN"><CODE>cuddCofactorRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_Cofactor. - -</DL> -<HR> -<A NAME="cuddCompose.c"><H1>cuddCompose.c</H1></A> -Functional composition and variable permutation of DDs. <P> -<B>By: Fabio Somenzi and Kavita Ravi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_bddCompose() - <li> Cudd_addCompose() - <li> Cudd_addPermute() - <li> Cudd_addSwapVariables() - <li> Cudd_bddPermute() - <li> Cudd_bddVarMap() - <li> Cudd_SetVarMap() - <li> Cudd_bddSwapVariables() - <li> Cudd_bddAdjPermuteX() - <li> Cudd_addVectorCompose() - <li> Cudd_addGeneralVectorCompose() - <li> Cudd_addNonSimCompose() - <li> Cudd_bddVectorCompose() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddComposeRecur() - <li> cuddAddComposeRecur() - </ul> - Static procedures included in this module: - <ul> - <li> cuddAddPermuteRecur() - <li> cuddBddPermuteRecur() - <li> cuddBddVarMapRecur() - <li> cuddAddVectorComposeRecur() - <li> cuddAddGeneralVectorComposeRecur() - <li> cuddAddNonSimComposeRecur() - <li> cuddBddVectorComposeRecur() - <li> ddIsIthAddVar() - <li> ddIsIthAddVarPair() - </ul> - The permutation functions use a local cache because the results to - be remembered depend on the permutation being applied. Since the - permutation is just an array, it cannot be stored in the global - cache. There are different procedured for BDDs and ADDs. This is - because bddPermuteRecur uses cuddBddIteRecur. If this were changed, - the procedures could be merged. <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_bddCompose" TARGET="MAIN"><CODE>Cudd_bddCompose()</CODE></A> - <DD> Substitutes g for x_v in the BDD for f. - - <DT> <A HREF="cuddAllDet.html#Cudd_addCompose" TARGET="MAIN"><CODE>Cudd_addCompose()</CODE></A> - <DD> Substitutes g for x_v in the ADD for f. - - <DT> <A HREF="cuddAllDet.html#Cudd_addPermute" TARGET="MAIN"><CODE>Cudd_addPermute()</CODE></A> - <DD> Permutes the variables of an ADD. - - <DT> <A HREF="cuddAllDet.html#Cudd_addSwapVariables" TARGET="MAIN"><CODE>Cudd_addSwapVariables()</CODE></A> - <DD> Swaps two sets of variables of the same size (x and y) in - the ADD f. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddPermute" TARGET="MAIN"><CODE>Cudd_bddPermute()</CODE></A> - <DD> Permutes the variables of a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddVarMap" TARGET="MAIN"><CODE>Cudd_bddVarMap()</CODE></A> - <DD> Remaps the variables of a BDD using the default variable map. - - <DT> <A HREF="cuddAllDet.html#Cudd_SetVarMap" TARGET="MAIN"><CODE>Cudd_SetVarMap()</CODE></A> - <DD> Registers a variable mapping with the manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddSwapVariables" TARGET="MAIN"><CODE>Cudd_bddSwapVariables()</CODE></A> - <DD> Swaps two sets of variables of the same size (x and y) in - the BDD f. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddAdjPermuteX" TARGET="MAIN"><CODE>Cudd_bddAdjPermuteX()</CODE></A> - <DD> Rearranges a set of variables in the BDD B. - - <DT> <A HREF="cuddAllDet.html#Cudd_addVectorCompose" TARGET="MAIN"><CODE>Cudd_addVectorCompose()</CODE></A> - <DD> Composes an ADD with a vector of 0-1 ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_addGeneralVectorCompose" TARGET="MAIN"><CODE>Cudd_addGeneralVectorCompose()</CODE></A> - <DD> Composes an ADD with a vector of ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_addNonSimCompose" TARGET="MAIN"><CODE>Cudd_addNonSimCompose()</CODE></A> - <DD> Composes an ADD with a vector of 0-1 ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddVectorCompose" TARGET="MAIN"><CODE>Cudd_bddVectorCompose()</CODE></A> - <DD> Composes a BDD with a vector of BDDs. - - <DT> <A HREF="cuddAllDet.html#cuddBddComposeRecur" TARGET="MAIN"><CODE>cuddBddComposeRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_bddCompose. - - <DT> <A HREF="cuddAllDet.html#cuddAddComposeRecur" TARGET="MAIN"><CODE>cuddAddComposeRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addCompose. - - <DT> <A HREF="cuddAllDet.html#cuddAddPermuteRecur" TARGET="MAIN"><CODE>cuddAddPermuteRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_addPermute. - - <DT> <A HREF="cuddAllDet.html#cuddBddPermuteRecur" TARGET="MAIN"><CODE>cuddBddPermuteRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_bddPermute. - - <DT> <A HREF="cuddAllDet.html#cuddBddVarMapRecur" TARGET="MAIN"><CODE>cuddBddVarMapRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_bddVarMap. - - <DT> <A HREF="cuddAllDet.html#cuddAddVectorComposeRecur" TARGET="MAIN"><CODE>cuddAddVectorComposeRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addVectorCompose. - - <DT> <A HREF="cuddAllDet.html#cuddAddGeneralVectorComposeRecur" TARGET="MAIN"><CODE>cuddAddGeneralVectorComposeRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addGeneralVectorCompose. - - <DT> <A HREF="cuddAllDet.html#cuddAddNonSimComposeRecur" TARGET="MAIN"><CODE>cuddAddNonSimComposeRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addNonSimCompose. - - <DT> <A HREF="cuddAllDet.html#cuddBddVectorComposeRecur" TARGET="MAIN"><CODE>cuddBddVectorComposeRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_bddVectorCompose. - - <DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> - <DD> Comparison of a function to the i-th ADD variable. - - <DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> - <DD> Comparison of a pair of functions to the i-th ADD variable. - -</DL> -<HR> -<A NAME="cuddDecomp.c"><H1>cuddDecomp.c</H1></A> -Functions for BDD decomposition. <P> -<B>By: Kavita Ravi, Fabio Somenzi</B><P> -External procedures included in this file: - <ul> - <li> Cudd_bddApproxConjDecomp() - <li> Cudd_bddApproxDisjDecomp() - <li> Cudd_bddIterConjDecomp() - <li> Cudd_bddIterDisjDecomp() - <li> Cudd_bddGenConjDecomp() - <li> Cudd_bddGenDisjDecomp() - <li> Cudd_bddVarConjDecomp() - <li> Cudd_bddVarDisjDecomp() - </ul> - Static procedures included in this module: - <ul> - <li> cuddConjunctsAux() - <li> CreateBotDist() - <li> BuildConjuncts() - <li> ConjunctsFree() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_bddApproxConjDecomp" TARGET="MAIN"><CODE>Cudd_bddApproxConjDecomp()</CODE></A> - <DD> Performs two-way conjunctive decomposition of a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddApproxDisjDecomp" TARGET="MAIN"><CODE>Cudd_bddApproxDisjDecomp()</CODE></A> - <DD> Performs two-way disjunctive decomposition of a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIterConjDecomp" TARGET="MAIN"><CODE>Cudd_bddIterConjDecomp()</CODE></A> - <DD> Performs two-way conjunctive decomposition of a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIterDisjDecomp" TARGET="MAIN"><CODE>Cudd_bddIterDisjDecomp()</CODE></A> - <DD> Performs two-way disjunctive decomposition of a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddGenConjDecomp" TARGET="MAIN"><CODE>Cudd_bddGenConjDecomp()</CODE></A> - <DD> Performs two-way conjunctive decomposition of a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddGenDisjDecomp" TARGET="MAIN"><CODE>Cudd_bddGenDisjDecomp()</CODE></A> - <DD> Performs two-way disjunctive decomposition of a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddVarConjDecomp" TARGET="MAIN"><CODE>Cudd_bddVarConjDecomp()</CODE></A> - <DD> Performs two-way conjunctive decomposition of a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddVarDisjDecomp" TARGET="MAIN"><CODE>Cudd_bddVarDisjDecomp()</CODE></A> - <DD> Performs two-way disjunctive decomposition of a BDD. - - <DT> <A HREF="cuddAllDet.html#CreateBotDist" TARGET="MAIN"><CODE>CreateBotDist()</CODE></A> - <DD> Get longest distance of node from constant. - - <DT> <A HREF="cuddAllDet.html#CountMinterms" TARGET="MAIN"><CODE>CountMinterms()</CODE></A> - <DD> Count the number of minterms of each node ina a BDD and - store it in a hash table. - - <DT> <A HREF="cuddAllDet.html#ConjunctsFree" TARGET="MAIN"><CODE>ConjunctsFree()</CODE></A> - <DD> Free factors structure - - <DT> <A HREF="cuddAllDet.html#PairInTables" TARGET="MAIN"><CODE>PairInTables()</CODE></A> - <DD> Check whether the given pair is in the tables. - - <DT> <A HREF="cuddAllDet.html#CheckTablesCacheAndReturn" TARGET="MAIN"><CODE>CheckTablesCacheAndReturn()</CODE></A> - <DD> Check the tables for the existence of pair and return one - combination, cache the result. - - <DT> <A HREF="cuddAllDet.html#PickOnePair" TARGET="MAIN"><CODE>PickOnePair()</CODE></A> - <DD> Check the tables for the existence of pair and return one - combination, store in cache. - - <DT> <A HREF="cuddAllDet.html#CheckInTables" TARGET="MAIN"><CODE>CheckInTables()</CODE></A> - <DD> Check if the two pairs exist in the table, If any of the - conjuncts do exist, store in the cache and return the corresponding pair. - - <DT> <A HREF="cuddAllDet.html#ZeroCase" TARGET="MAIN"><CODE>ZeroCase()</CODE></A> - <DD> If one child is zero, do explicitly what Restrict does or better - - <DT> <A HREF="cuddAllDet.html#BuildConjuncts" TARGET="MAIN"><CODE>BuildConjuncts()</CODE></A> - <DD> Builds the conjuncts recursively, bottom up. - - <DT> <A HREF="cuddAllDet.html#cuddConjunctsAux" TARGET="MAIN"><CODE>cuddConjunctsAux()</CODE></A> - <DD> Procedure to compute two conjunctive factors of f and place in *c1 and *c2. - -</DL> -<HR> -<A NAME="cuddEssent.c"><H1>cuddEssent.c</H1></A> -Functions for the detection of essential variables. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this file: - <ul> - <li> Cudd_FindEssential() - <li> Cudd_bddIsVarEssential() - <li> Cudd_FindTwoLiteralClauses() - <li> Cudd_ReadIthClause() - <li> Cudd_PrintTwoLiteralClauses() - <li> Cudd_tlcInfoFree() - </ul> - Static procedures included in this module: - <ul> - <li> ddFindEssentialRecur() - <li> ddFindTwoLiteralClausesRecur() - <li> computeClauses() - <li> computeClausesWithUniverse() - <li> emptyClauseSet() - <li> sentinelp() - <li> equalp() - <li> beforep() - <li> oneliteralp() - <li> impliedp() - <li> bitVectorAlloc() - <li> bitVectorClear() - <li> bitVectorFree() - <li> bitVectorRead() - <li> bitVectorSet() - <li> tlcInfoAlloc() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_FindEssential" TARGET="MAIN"><CODE>Cudd_FindEssential()</CODE></A> - <DD> Finds the essential variables of a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIsVarEssential" TARGET="MAIN"><CODE>Cudd_bddIsVarEssential()</CODE></A> - <DD> Determines whether a given variable is essential with a - given phase in a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_FindTwoLiteralClauses" TARGET="MAIN"><CODE>Cudd_FindTwoLiteralClauses()</CODE></A> - <DD> Finds the two literal clauses of a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadIthClause" TARGET="MAIN"><CODE>Cudd_ReadIthClause()</CODE></A> - <DD> Accesses the i-th clause of a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_PrintTwoLiteralClauses" TARGET="MAIN"><CODE>Cudd_PrintTwoLiteralClauses()</CODE></A> - <DD> Prints the two literal clauses of a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_tlcInfoFree" TARGET="MAIN"><CODE>Cudd_tlcInfoFree()</CODE></A> - <DD> Frees a DdTlcInfo Structure. - - <DT> <A HREF="cuddAllDet.html#ddFindEssentialRecur" TARGET="MAIN"><CODE>ddFindEssentialRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_FindEssential. - - <DT> <A HREF="cuddAllDet.html#ddFindTwoLiteralClausesRecur" TARGET="MAIN"><CODE>ddFindTwoLiteralClausesRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_FindTwoLiteralClauses. - - <DT> <A HREF="cuddAllDet.html#computeClauses" TARGET="MAIN"><CODE>computeClauses()</CODE></A> - <DD> Computes the two-literal clauses for a node. - - <DT> <A HREF="cuddAllDet.html#computeClausesWithUniverse" TARGET="MAIN"><CODE>computeClausesWithUniverse()</CODE></A> - <DD> Computes the two-literal clauses for a node. - - <DT> <A HREF="cuddAllDet.html#emptyClauseSet" TARGET="MAIN"><CODE>emptyClauseSet()</CODE></A> - <DD> Returns an enpty set of clauses. - - <DT> <A HREF="cuddAllDet.html#sentinelp" TARGET="MAIN"><CODE>sentinelp()</CODE></A> - <DD> Returns true iff the argument is the sentinel clause. - - <DT> <A HREF="cuddAllDet.html#equalp" TARGET="MAIN"><CODE>equalp()</CODE></A> - <DD> Returns true iff the two arguments are identical clauses. - - <DT> <A HREF="cuddAllDet.html#beforep" TARGET="MAIN"><CODE>beforep()</CODE></A> - <DD> Returns true iff the first argument precedes the second in - the clause order. - - <DT> <A HREF="cuddAllDet.html#oneliteralp" TARGET="MAIN"><CODE>oneliteralp()</CODE></A> - <DD> Returns true iff the argument is a one-literal clause. - - <DT> <A HREF="cuddAllDet.html#impliedp" TARGET="MAIN"><CODE>impliedp()</CODE></A> - <DD> Returns true iff either literal of a clause is in a set of - literals. - - <DT> <A HREF="cuddAllDet.html#bitVectorAlloc" TARGET="MAIN"><CODE>bitVectorAlloc()</CODE></A> - <DD> Allocates a bit vector. - - <DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> - <DD> Clears a bit vector. - - <DT> <A HREF="cuddAllDet.html#bitVectorFree" TARGET="MAIN"><CODE>bitVectorFree()</CODE></A> - <DD> Frees a bit vector. - - <DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> - <DD> Returns the i-th entry of a bit vector. - - <DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> - <DD> Sets the i-th entry of a bit vector to a value. - - <DT> <A HREF="cuddAllDet.html#tlcInfoAlloc" TARGET="MAIN"><CODE>tlcInfoAlloc()</CODE></A> - <DD> Allocates a DdTlcInfo Structure. - -</DL> -<HR> -<A NAME="cuddExact.c"><H1>cuddExact.c</H1></A> -Functions for exact variable reordering. <P> -<B>By: Cheng Hua, Fabio Somenzi</B><P> -External procedures included in this file: - <ul> - </ul> - Internal procedures included in this module: - <ul> - <li> cuddExact() - </ul> - Static procedures included in this module: - <ul> - <li> getMaxBinomial() - <li> gcd() - <li> getMatrix() - <li> freeMatrix() - <li> getLevelKeys() - <li> ddShuffle() - <li> ddSiftUp() - <li> updateUB() - <li> ddCountRoots() - <li> ddClearGlobal() - <li> computeLB() - <li> updateEntry() - <li> pushDown() - <li> initSymmInfo() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#cuddExact" TARGET="MAIN"><CODE>cuddExact()</CODE></A> - <DD> Exact variable ordering algorithm. - - <DT> <A HREF="cuddAllDet.html#getMaxBinomial" TARGET="MAIN"><CODE>getMaxBinomial()</CODE></A> - <DD> Returns the maximum value of (n choose k) for a given n. - - <DT> <A HREF="cuddAllDet.html#gcd" TARGET="MAIN"><CODE>gcd()</CODE></A> - <DD> Returns the gcd of two integers. - - <DT> <A HREF="cuddAllDet.html#getMatrix" TARGET="MAIN"><CODE>getMatrix()</CODE></A> - <DD> Allocates a two-dimensional matrix of ints. - - <DT> <A HREF="cuddAllDet.html#freeMatrix" TARGET="MAIN"><CODE>freeMatrix()</CODE></A> - <DD> Frees a two-dimensional matrix allocated by getMatrix. - - <DT> <A HREF="cuddAllDet.html#getLevelKeys" TARGET="MAIN"><CODE>getLevelKeys()</CODE></A> - <DD> Returns the number of nodes at one level of a unique table. - - <DT> <A HREF="cuddAllDet.html#ddShuffle" TARGET="MAIN"><CODE>ddShuffle()</CODE></A> - <DD> Reorders variables according to a given permutation. - - <DT> <A HREF="cuddAllDet.html#ddSiftUp" TARGET="MAIN"><CODE>ddSiftUp()</CODE></A> - <DD> Moves one variable up. - - <DT> <A HREF="cuddAllDet.html#updateUB" TARGET="MAIN"><CODE>updateUB()</CODE></A> - <DD> Updates the upper bound and saves the best order seen so far. - - <DT> <A HREF="cuddAllDet.html#ddCountRoots" TARGET="MAIN"><CODE>ddCountRoots()</CODE></A> - <DD> Counts the number of roots. - - <DT> <A HREF="cuddAllDet.html#ddClearGlobal" TARGET="MAIN"><CODE>ddClearGlobal()</CODE></A> - <DD> Scans the DD and clears the LSB of the next pointers. - - <DT> <A HREF="cuddAllDet.html#computeLB" TARGET="MAIN"><CODE>computeLB()</CODE></A> - <DD> Computes a lower bound on the size of a BDD. - - <DT> <A HREF="cuddAllDet.html#updateEntry" TARGET="MAIN"><CODE>updateEntry()</CODE></A> - <DD> Updates entry for a subset. - - <DT> <A HREF="cuddAllDet.html#pushDown" TARGET="MAIN"><CODE>pushDown()</CODE></A> - <DD> Pushes a variable in the order down to position "level." - - <DT> <A HREF="cuddAllDet.html#initSymmInfo" TARGET="MAIN"><CODE>initSymmInfo()</CODE></A> - <DD> Gathers symmetry information. - - <DT> <A HREF="cuddAllDet.html#checkSymmInfo" TARGET="MAIN"><CODE>checkSymmInfo()</CODE></A> - <DD> Check symmetry condition. - -</DL> -<HR> -<A NAME="cuddExport.c"><H1>cuddExport.c</H1></A> -Export functions. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_DumpBlif() - <li> Cudd_DumpBlifBody() - <li> Cudd_DumpDot() - <li> Cudd_DumpDaVinci() - <li> Cudd_DumpDDcal() - <li> Cudd_DumpFactoredForm() - </ul> - Internal procedures included in this module: - <ul> - </ul> - Static procedures included in this module: - <ul> - <li> ddDoDumpBlif() - <li> ddDoDumpDaVinci() - <li> ddDoDumpDDcal() - <li> ddDoDumpFactoredForm() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_DumpBlif" TARGET="MAIN"><CODE>Cudd_DumpBlif()</CODE></A> - <DD> Writes a blif file representing the argument BDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_DumpBlifBody" TARGET="MAIN"><CODE>Cudd_DumpBlifBody()</CODE></A> - <DD> Writes a blif body representing the argument BDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_DumpDot" TARGET="MAIN"><CODE>Cudd_DumpDot()</CODE></A> - <DD> Writes a dot file representing the argument DDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_DumpDaVinci" TARGET="MAIN"><CODE>Cudd_DumpDaVinci()</CODE></A> - <DD> Writes a daVinci file representing the argument BDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_DumpDDcal" TARGET="MAIN"><CODE>Cudd_DumpDDcal()</CODE></A> - <DD> Writes a DDcal file representing the argument BDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_DumpFactoredForm" TARGET="MAIN"><CODE>Cudd_DumpFactoredForm()</CODE></A> - <DD> Writes factored forms representing the argument BDDs. - - <DT> <A HREF="cuddAllDet.html#ddDoDumpBlif" TARGET="MAIN"><CODE>ddDoDumpBlif()</CODE></A> - <DD> Performs the recursive step of Cudd_DumpBlif. - - <DT> <A HREF="cuddAllDet.html#ddDoDumpDaVinci" TARGET="MAIN"><CODE>ddDoDumpDaVinci()</CODE></A> - <DD> Performs the recursive step of Cudd_DumpDaVinci. - - <DT> <A HREF="cuddAllDet.html#ddDoDumpDDcal" TARGET="MAIN"><CODE>ddDoDumpDDcal()</CODE></A> - <DD> Performs the recursive step of Cudd_DumpDDcal. - - <DT> <A HREF="cuddAllDet.html#ddDoDumpFactoredForm" TARGET="MAIN"><CODE>ddDoDumpFactoredForm()</CODE></A> - <DD> Performs the recursive step of Cudd_DumpFactoredForm. - -</DL> -<HR> -<A NAME="cuddGenCof.c"><H1>cuddGenCof.c</H1></A> -Generalized cofactors for BDDs and ADDs. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_bddConstrain() - <li> Cudd_bddRestrict() - <li> Cudd_bddNPAnd() - <li> Cudd_addConstrain() - <li> Cudd_bddConstrainDecomp() - <li> Cudd_addRestrict() - <li> Cudd_bddCharToVect() - <li> Cudd_bddLICompaction() - <li> Cudd_bddSqueeze() - <li> Cudd_bddMinimize() - <li> Cudd_SubsetCompress() - <li> Cudd_SupersetCompress() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddConstrainRecur() - <li> cuddBddRestrictRecur() - <li> cuddBddNPAndRecur() - <li> cuddAddConstrainRecur() - <li> cuddAddRestrictRecur() - <li> cuddBddLICompaction() - </ul> - Static procedures included in this module: - <ul> - <li> cuddBddConstrainDecomp() - <li> cuddBddCharToVect() - <li> cuddBddLICMarkEdges() - <li> cuddBddLICBuildResult() - <li> MarkCacheHash() - <li> MarkCacheCompare() - <li> MarkCacheCleanUp() - <li> cuddBddSqueeze() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_bddConstrain" TARGET="MAIN"><CODE>Cudd_bddConstrain()</CODE></A> - <DD> Computes f constrain c. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddRestrict" TARGET="MAIN"><CODE>Cudd_bddRestrict()</CODE></A> - <DD> BDD restrict according to Coudert and Madre's algorithm - (ICCAD90). - - <DT> <A HREF="cuddAllDet.html#Cudd_bddNPAnd" TARGET="MAIN"><CODE>Cudd_bddNPAnd()</CODE></A> - <DD> Computes f non-polluting-and g. - - <DT> <A HREF="cuddAllDet.html#Cudd_addConstrain" TARGET="MAIN"><CODE>Cudd_addConstrain()</CODE></A> - <DD> Computes f constrain c for ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddConstrainDecomp" TARGET="MAIN"><CODE>Cudd_bddConstrainDecomp()</CODE></A> - <DD> BDD conjunctive decomposition as in McMillan's CAV96 paper. - - <DT> <A HREF="cuddAllDet.html#Cudd_addRestrict" TARGET="MAIN"><CODE>Cudd_addRestrict()</CODE></A> - <DD> ADD restrict according to Coudert and Madre's algorithm - (ICCAD90). - - <DT> <A HREF="cuddAllDet.html#Cudd_bddCharToVect" TARGET="MAIN"><CODE>Cudd_bddCharToVect()</CODE></A> - <DD> Computes a vector whose image equals a non-zero function. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddLICompaction" TARGET="MAIN"><CODE>Cudd_bddLICompaction()</CODE></A> - <DD> Performs safe minimization of a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddSqueeze" TARGET="MAIN"><CODE>Cudd_bddSqueeze()</CODE></A> - <DD> Finds a small BDD in a function interval. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddMinimize" TARGET="MAIN"><CODE>Cudd_bddMinimize()</CODE></A> - <DD> Finds a small BDD that agrees with <code>f</code> over - <code>c</code>. - - <DT> <A HREF="cuddAllDet.html#Cudd_SubsetCompress" TARGET="MAIN"><CODE>Cudd_SubsetCompress()</CODE></A> - <DD> Find a dense subset of BDD <code>f</code>. - - <DT> <A HREF="cuddAllDet.html#Cudd_SupersetCompress" TARGET="MAIN"><CODE>Cudd_SupersetCompress()</CODE></A> - <DD> Find a dense superset of BDD <code>f</code>. - - <DT> <A HREF="cuddAllDet.html#cuddBddConstrainRecur" TARGET="MAIN"><CODE>cuddBddConstrainRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_bddConstrain. - - <DT> <A HREF="cuddAllDet.html#cuddBddRestrictRecur" TARGET="MAIN"><CODE>cuddBddRestrictRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_bddRestrict. - - <DT> <A HREF="cuddAllDet.html#cuddBddNPAndRecur" TARGET="MAIN"><CODE>cuddBddNPAndRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_bddAnd. - - <DT> <A HREF="cuddAllDet.html#cuddAddConstrainRecur" TARGET="MAIN"><CODE>cuddAddConstrainRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addConstrain. - - <DT> <A HREF="cuddAllDet.html#cuddAddRestrictRecur" TARGET="MAIN"><CODE>cuddAddRestrictRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addRestrict. - - <DT> <A HREF="cuddAllDet.html#cuddBddLICompaction" TARGET="MAIN"><CODE>cuddBddLICompaction()</CODE></A> - <DD> Performs safe minimization of a BDD. - - <DT> <A HREF="cuddAllDet.html#cuddBddConstrainDecomp" TARGET="MAIN"><CODE>cuddBddConstrainDecomp()</CODE></A> - <DD> Performs the recursive step of Cudd_bddConstrainDecomp. - - <DT> <A HREF="cuddAllDet.html#cuddBddCharToVect" TARGET="MAIN"><CODE>cuddBddCharToVect()</CODE></A> - <DD> Performs the recursive step of Cudd_bddCharToVect. - - <DT> <A HREF="cuddAllDet.html#cuddBddLICMarkEdges" TARGET="MAIN"><CODE>cuddBddLICMarkEdges()</CODE></A> - <DD> Performs the edge marking step of Cudd_bddLICompaction. - - <DT> <A HREF="cuddAllDet.html#cuddBddLICBuildResult" TARGET="MAIN"><CODE>cuddBddLICBuildResult()</CODE></A> - <DD> Builds the result of Cudd_bddLICompaction. - - <DT> <A HREF="cuddAllDet.html#MarkCacheHash" TARGET="MAIN"><CODE>MarkCacheHash()</CODE></A> - <DD> Hash function for the computed table of cuddBddLICMarkEdges. - - <DT> <A HREF="cuddAllDet.html#MarkCacheCompare" TARGET="MAIN"><CODE>MarkCacheCompare()</CODE></A> - <DD> Comparison function for the computed table of - cuddBddLICMarkEdges. - - <DT> <A HREF="cuddAllDet.html#MarkCacheCleanUp" TARGET="MAIN"><CODE>MarkCacheCleanUp()</CODE></A> - <DD> Frees memory associated with computed table of - cuddBddLICMarkEdges. - - <DT> <A HREF="cuddAllDet.html#cuddBddSqueeze" TARGET="MAIN"><CODE>cuddBddSqueeze()</CODE></A> - <DD> Performs the recursive step of Cudd_bddSqueeze. - -</DL> -<HR> -<A NAME="cuddGenetic.c"><H1>cuddGenetic.c</H1></A> -Genetic algorithm for variable reordering. <P> -<B>By: Curt Musfeldt, Alan Shuler, Fabio Somenzi</B><P> -Internal procedures included in this file: - <ul> - <li> cuddGa() - </ul> - Static procedures included in this module: - <ul> - <li> make_random() - <li> sift_up() - <li> build_dd() - <li> largest() - <li> rand_int() - <li> array_hash() - <li> array_compare() - <li> find_best() - <li> find_average_fitness() - <li> PMX() - <li> roulette() - </ul> - - The genetic algorithm implemented here is as follows. We start with - the current DD order. We sift this order and use this as the - reference DD. We only keep 1 DD around for the entire process and - simply rearrange the order of this DD, storing the various orders - and their corresponding DD sizes. We generate more random orders to - build an initial population. This initial population is 3 times the - number of variables, with a maximum of 120. Each random order is - built (from the reference DD) and its size stored. Each random - order is also sifted to keep the DD sizes fairly small. Then a - crossover is performed between two orders (picked randomly) and the - two resulting DDs are built and sifted. For each new order, if its - size is smaller than any DD in the population, it is inserted into - the population and the DD with the largest number of nodes is thrown - out. The crossover process happens up to 50 times, and at this point - the DD in the population with the smallest size is chosen as the - result. This DD must then be built from the reference DD. <P> -<DL> - <DT> <A HREF="cuddAllDet.html#cuddGa" TARGET="MAIN"><CODE>cuddGa()</CODE></A> - <DD> Genetic algorithm for DD reordering. - - <DT> <A HREF="cuddAllDet.html#make_random" TARGET="MAIN"><CODE>make_random()</CODE></A> - <DD> Generates the random sequences for the initial population. - - <DT> <A HREF="cuddAllDet.html#sift_up" TARGET="MAIN"><CODE>sift_up()</CODE></A> - <DD> Moves one variable up. - - <DT> <A HREF="cuddAllDet.html#build_dd" TARGET="MAIN"><CODE>build_dd()</CODE></A> - <DD> Builds a DD from a given order. - - <DT> <A HREF="cuddAllDet.html#largest" TARGET="MAIN"><CODE>largest()</CODE></A> - <DD> Finds the largest DD in the population. - - <DT> <A HREF="cuddAllDet.html#rand_int" TARGET="MAIN"><CODE>rand_int()</CODE></A> - <DD> Generates a random number between 0 and the integer a. - - <DT> <A HREF="cuddAllDet.html#array_hash" TARGET="MAIN"><CODE>array_hash()</CODE></A> - <DD> Hash function for the computed table. - - <DT> <A HREF="cuddAllDet.html#array_compare" TARGET="MAIN"><CODE>array_compare()</CODE></A> - <DD> Comparison function for the computed table. - - <DT> <A HREF="cuddAllDet.html#find_best" TARGET="MAIN"><CODE>find_best()</CODE></A> - <DD> Returns the index of the fittest individual. - - <DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> - <DD> Returns the average fitness of the population. - - <DT> <A HREF="cuddAllDet.html#PMX" TARGET="MAIN"><CODE>PMX()</CODE></A> - <DD> Performs the crossover between two parents. - - <DT> <A HREF="cuddAllDet.html#roulette" TARGET="MAIN"><CODE>roulette()</CODE></A> - <DD> Selects two parents with the roulette wheel method. - -</DL> -<HR> -<A NAME="cuddGroup.c"><H1>cuddGroup.c</H1></A> -Functions for group sifting. <P> -<B>By: Shipra Panda, Fabio Somenzi</B><P> -External procedures included in this file: - <ul> - <li> Cudd_MakeTreeNode() - </ul> - Internal procedures included in this file: - <ul> - <li> cuddTreeSifting() - </ul> - Static procedures included in this module: - <ul> - <li> ddTreeSiftingAux() - <li> ddCountInternalMtrNodes() - <li> ddReorderChildren() - <li> ddFindNodeHiLo() - <li> ddUniqueCompareGroup() - <li> ddGroupSifting() - <li> ddCreateGroup() - <li> ddGroupSiftingAux() - <li> ddGroupSiftingUp() - <li> ddGroupSiftingDown() - <li> ddGroupMove() - <li> ddGroupMoveBackward() - <li> ddGroupSiftingBackward() - <li> ddMergeGroups() - <li> ddDissolveGroup() - <li> ddNoCheck() - <li> ddSecDiffCheck() - <li> ddExtSymmCheck() - <li> ddVarGroupCheck() - <li> ddSetVarHandled() - <li> ddResetVarHandled() - <li> ddIsVarHandled() - <li> ddFixTree() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_MakeTreeNode" TARGET="MAIN"><CODE>Cudd_MakeTreeNode()</CODE></A> - <DD> Creates a new variable group. - - <DT> <A HREF="cuddAllDet.html#cuddTreeSifting" TARGET="MAIN"><CODE>cuddTreeSifting()</CODE></A> - <DD> Tree sifting algorithm. - - <DT> <A HREF="cuddAllDet.html#ddTreeSiftingAux" TARGET="MAIN"><CODE>ddTreeSiftingAux()</CODE></A> - <DD> Visits the group tree and reorders each group. - - <DT> <A HREF="cuddAllDet.html#ddCountInternalMtrNodes" TARGET="MAIN"><CODE>ddCountInternalMtrNodes()</CODE></A> - <DD> Counts the number of internal nodes of the group tree. - - <DT> <A HREF="cuddAllDet.html#ddReorderChildren" TARGET="MAIN"><CODE>ddReorderChildren()</CODE></A> - <DD> Reorders the children of a group tree node according to - the options. - - <DT> <A HREF="cuddAllDet.html#ddFindNodeHiLo" TARGET="MAIN"><CODE>ddFindNodeHiLo()</CODE></A> - <DD> Finds the lower and upper bounds of the group represented - by treenode. - - <DT> <A HREF="cuddAllDet.html#ddUniqueCompareGroup" TARGET="MAIN"><CODE>ddUniqueCompareGroup()</CODE></A> - <DD> Comparison function used by qsort. - - <DT> <A HREF="cuddAllDet.html#ddGroupSifting" TARGET="MAIN"><CODE>ddGroupSifting()</CODE></A> - <DD> Sifts from treenode->low to treenode->high. - - <DT> <A HREF="cuddAllDet.html#ddCreateGroup" TARGET="MAIN"><CODE>ddCreateGroup()</CODE></A> - <DD> Creates a group encompassing variables from x to y in the - DD table. - - <DT> <A HREF="cuddAllDet.html#ddGroupSiftingAux" TARGET="MAIN"><CODE>ddGroupSiftingAux()</CODE></A> - <DD> Sifts one variable up and down until it has taken all - positions. Checks for aggregation. - - <DT> <A HREF="cuddAllDet.html#ddGroupSiftingUp" TARGET="MAIN"><CODE>ddGroupSiftingUp()</CODE></A> - <DD> Sifts up a variable until either it reaches position xLow - or the size of the DD heap increases too much. - - <DT> <A HREF="cuddAllDet.html#ddGroupSiftingDown" TARGET="MAIN"><CODE>ddGroupSiftingDown()</CODE></A> - <DD> Sifts down a variable until it reaches position xHigh. - - <DT> <A HREF="cuddAllDet.html#ddGroupMove" TARGET="MAIN"><CODE>ddGroupMove()</CODE></A> - <DD> Swaps two groups and records the move. - - <DT> <A HREF="cuddAllDet.html#ddGroupMoveBackward" TARGET="MAIN"><CODE>ddGroupMoveBackward()</CODE></A> - <DD> Undoes the swap two groups. - - <DT> <A HREF="cuddAllDet.html#ddGroupSiftingBackward" TARGET="MAIN"><CODE>ddGroupSiftingBackward()</CODE></A> - <DD> Determines the best position for a variables and returns - it there. - - <DT> <A HREF="cuddAllDet.html#ddMergeGroups" TARGET="MAIN"><CODE>ddMergeGroups()</CODE></A> - <DD> Merges groups in the DD table. - - <DT> <A HREF="cuddAllDet.html#ddDissolveGroup" TARGET="MAIN"><CODE>ddDissolveGroup()</CODE></A> - <DD> Dissolves a group in the DD table. - - <DT> <A HREF="cuddAllDet.html#ddNoCheck" TARGET="MAIN"><CODE>ddNoCheck()</CODE></A> - <DD> Pretends to check two variables for aggregation. - - <DT> <A HREF="cuddAllDet.html#ddSecDiffCheck" TARGET="MAIN"><CODE>ddSecDiffCheck()</CODE></A> - <DD> Checks two variables for aggregation. - - <DT> <A HREF="cuddAllDet.html#ddExtSymmCheck" TARGET="MAIN"><CODE>ddExtSymmCheck()</CODE></A> - <DD> Checks for extended symmetry of x and y. - - <DT> <A HREF="cuddAllDet.html#ddVarGroupCheck" TARGET="MAIN"><CODE>ddVarGroupCheck()</CODE></A> - <DD> Checks for grouping of x and y. - - <DT> <A HREF="cuddAllDet.html#ddSetVarHandled" TARGET="MAIN"><CODE>ddSetVarHandled()</CODE></A> - <DD> Sets a variable to already handled. - - <DT> <A HREF="cuddAllDet.html#ddResetVarHandled" TARGET="MAIN"><CODE>ddResetVarHandled()</CODE></A> - <DD> Resets a variable to be processed. - - <DT> <A HREF="cuddAllDet.html#ddIsVarHandled" TARGET="MAIN"><CODE>ddIsVarHandled()</CODE></A> - <DD> Checks whether a variables is already handled. - -</DL> -<HR> -<A NAME="cuddHarwell.c"><H1>cuddHarwell.c</H1></A> -Function to read a matrix in Harwell format. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_addHarwell() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addHarwell" TARGET="MAIN"><CODE>Cudd_addHarwell()</CODE></A> - <DD> Reads in a matrix in the format of the Harwell-Boeing - benchmark suite. - -</DL> -<HR> -<A NAME="cuddInit.c"><H1>cuddInit.c</H1></A> -Functions to initialize and shut down the DD manager. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_Init() - <li> Cudd_Quit() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddInitUniv() - <li> cuddZddFreeUniv() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_Init" TARGET="MAIN"><CODE>Cudd_Init()</CODE></A> - <DD> Creates a new DD manager. - - <DT> <A HREF="cuddAllDet.html#Cudd_Quit" TARGET="MAIN"><CODE>Cudd_Quit()</CODE></A> - <DD> Deletes resources associated with a DD manager. - - <DT> <A HREF="cuddAllDet.html#cuddZddInitUniv" TARGET="MAIN"><CODE>cuddZddInitUniv()</CODE></A> - <DD> Initializes the ZDD universe. - - <DT> <A HREF="cuddAllDet.html#cuddZddFreeUniv" TARGET="MAIN"><CODE>cuddZddFreeUniv()</CODE></A> - <DD> Frees the ZDD universe. - -</DL> -<HR> -<A NAME="cuddInteract.c"><H1>cuddInteract.c</H1></A> -Functions to manipulate the variable interaction matrix. <P> -<B>By: Fabio Somenzi</B><P> -Internal procedures included in this file: - <ul> - <li> cuddSetInteract() - <li> cuddTestInteract() - <li> cuddInitInteract() - </ul> - Static procedures included in this file: - <ul> - <li> ddSuppInteract() - <li> ddClearLocal() - <li> ddUpdateInteract() - <li> ddClearGlobal() - </ul> - The interaction matrix tells whether two variables are - both in the support of some function of the DD. The main use of the - interaction matrix is in the in-place swapping. Indeed, if two - variables do not interact, there is no arc connecting the two layers; - therefore, the swap can be performed in constant time, without - scanning the subtables. Another use of the interaction matrix is in - the computation of the lower bounds for sifting. Finally, the - interaction matrix can be used to speed up aggregation checks in - symmetric and group sifting.<p> - The computation of the interaction matrix is done with a series of - depth-first searches. The searches start from those nodes that have - only external references. The matrix is stored as a packed array of bits; - since it is symmetric, only the upper triangle is kept in memory. - As a final remark, we note that there may be variables that do - interact, but that for a given variable order have no arc connecting - their layers when they are adjacent. For instance, in ite(a,b,c) with - the order a<b<c, b and c interact, but are not connected. <P> -<DL> - <DT> <A HREF="cuddAllDet.html#cuddSetInteract" TARGET="MAIN"><CODE>cuddSetInteract()</CODE></A> - <DD> Set interaction matrix entries. - - <DT> <A HREF="cuddAllDet.html#cuddTestInteract" TARGET="MAIN"><CODE>cuddTestInteract()</CODE></A> - <DD> Test interaction matrix entries. - - <DT> <A HREF="cuddAllDet.html#cuddInitInteract" TARGET="MAIN"><CODE>cuddInitInteract()</CODE></A> - <DD> Initializes the interaction matrix. - - <DT> <A HREF="cuddAllDet.html#ddSuppInteract" TARGET="MAIN"><CODE>ddSuppInteract()</CODE></A> - <DD> Find the support of f. - - <DT> <A HREF="cuddAllDet.html#ddClearLocal" TARGET="MAIN"><CODE>ddClearLocal()</CODE></A> - <DD> Performs a DFS from f, clearing the LSB of the then pointers. - - <DT> <A HREF="cuddAllDet.html#ddUpdateInteract" TARGET="MAIN"><CODE>ddUpdateInteract()</CODE></A> - <DD> Marks as interacting all pairs of variables that appear in - support. - - <DT> <A HREF="cuddAllDet.html#ddClearGlobal" TARGET="MAIN"><CODE>ddClearGlobal()</CODE></A> - <DD> Scans the DD and clears the LSB of the next pointers. - -</DL> -<HR> -<A NAME="cuddLCache.c"><H1>cuddLCache.c</H1></A> -Functions for local caches. <P> -<B>By: Fabio Somenzi</B><P> -Internal procedures included in this module: - <ul> - <li> cuddLocalCacheInit() - <li> cuddLocalCacheQuit() - <li> cuddLocalCacheInsert() - <li> cuddLocalCacheLookup() - <li> cuddLocalCacheClearDead() - <li> cuddLocalCacheClearAll() - <li> cuddLocalCacheProfile() - <li> cuddHashTableInit() - <li> cuddHashTableQuit() - <li> cuddHashTableGenericQuit() - <li> cuddHashTableInsert() - <li> cuddHashTableLookup() - <li> cuddHashTableGenericInsert() - <li> cuddHashTableGenericLookup() - <li> cuddHashTableInsert2() - <li> cuddHashTableLookup2() - <li> cuddHashTableInsert3() - <li> cuddHashTableLookup3() - </ul> - Static procedures included in this module: - <ul> - <li> cuddLocalCacheResize() - <li> ddLCHash() - <li> cuddLocalCacheAddToList() - <li> cuddLocalCacheRemoveFromList() - <li> cuddHashTableResize() - <li> cuddHashTableAlloc() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#cuddLocalCacheInit" TARGET="MAIN"><CODE>cuddLocalCacheInit()</CODE></A> - <DD> Initializes a local computed table. - - <DT> <A HREF="cuddAllDet.html#cuddLocalCacheQuit" TARGET="MAIN"><CODE>cuddLocalCacheQuit()</CODE></A> - <DD> Shuts down a local computed table. - - <DT> <A HREF="cuddAllDet.html#cuddLocalCacheInsert" TARGET="MAIN"><CODE>cuddLocalCacheInsert()</CODE></A> - <DD> Inserts a result in a local cache. - - <DT> <A HREF="cuddAllDet.html#cuddLocalCacheLookup" TARGET="MAIN"><CODE>cuddLocalCacheLookup()</CODE></A> - <DD> Looks up in a local cache. - - <DT> <A HREF="cuddAllDet.html#cuddLocalCacheClearDead" TARGET="MAIN"><CODE>cuddLocalCacheClearDead()</CODE></A> - <DD> Clears the dead entries of the local caches of a manager. - - <DT> <A HREF="cuddAllDet.html#cuddLocalCacheClearAll" TARGET="MAIN"><CODE>cuddLocalCacheClearAll()</CODE></A> - <DD> Clears the local caches of a manager. - - <DT> <A HREF="cuddAllDet.html#cuddLocalCacheProfile" TARGET="MAIN"><CODE>cuddLocalCacheProfile()</CODE></A> - <DD> Computes and prints a profile of a local cache usage. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableInit" TARGET="MAIN"><CODE>cuddHashTableInit()</CODE></A> - <DD> Initializes a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableQuit" TARGET="MAIN"><CODE>cuddHashTableQuit()</CODE></A> - <DD> Shuts down a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableGenericQuit" TARGET="MAIN"><CODE>cuddHashTableGenericQuit()</CODE></A> - <DD> Shuts down a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableInsert" TARGET="MAIN"><CODE>cuddHashTableInsert()</CODE></A> - <DD> Inserts an item in a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableLookup" TARGET="MAIN"><CODE>cuddHashTableLookup()</CODE></A> - <DD> Looks up a key in a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableInsert1" TARGET="MAIN"><CODE>cuddHashTableInsert1()</CODE></A> - <DD> Inserts an item in a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableLookup1" TARGET="MAIN"><CODE>cuddHashTableLookup1()</CODE></A> - <DD> Looks up a key consisting of one pointer in a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableGenericInsert" TARGET="MAIN"><CODE>cuddHashTableGenericInsert()</CODE></A> - <DD> Inserts an item in a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableGenericLookup" TARGET="MAIN"><CODE>cuddHashTableGenericLookup()</CODE></A> - <DD> Looks up a key consisting of one pointer in a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableInsert2" TARGET="MAIN"><CODE>cuddHashTableInsert2()</CODE></A> - <DD> Inserts an item in a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableLookup2" TARGET="MAIN"><CODE>cuddHashTableLookup2()</CODE></A> - <DD> Looks up a key consisting of two pointers in a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableInsert3" TARGET="MAIN"><CODE>cuddHashTableInsert3()</CODE></A> - <DD> Inserts an item in a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableLookup3" TARGET="MAIN"><CODE>cuddHashTableLookup3()</CODE></A> - <DD> Looks up a key consisting of three pointers in a hash table. - - <DT> <A HREF="cuddAllDet.html#cuddLocalCacheResize" TARGET="MAIN"><CODE>cuddLocalCacheResize()</CODE></A> - <DD> Resizes a local cache. - - <DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> - <DD> Computes the hash value for a local cache. - - <DT> <A HREF="cuddAllDet.html#cuddLocalCacheAddToList" TARGET="MAIN"><CODE>cuddLocalCacheAddToList()</CODE></A> - <DD> Inserts a local cache in the manager list. - - <DT> <A HREF="cuddAllDet.html#cuddLocalCacheRemoveFromList" TARGET="MAIN"><CODE>cuddLocalCacheRemoveFromList()</CODE></A> - <DD> Removes a local cache from the manager list. - - <DT> <A HREF="cuddAllDet.html#cuddHashTableResize" TARGET="MAIN"><CODE>cuddHashTableResize()</CODE></A> - <DD> Resizes a hash table. - - <DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> - <DD> Fast storage allocation for items in a hash table. - -</DL> -<HR> -<A NAME="cuddLevelQ.c"><H1>cuddLevelQ.c</H1></A> -Procedure to manage level queues. <P> -<B>By: Fabio Somenzi</B><P> -The functions in this file allow an application to - easily manipulate a queue where nodes are prioritized by level. The - emphasis is on efficiency. Therefore, the queue items can have - variable size. If the application does not need to attach - information to the nodes, it can declare the queue items to be of - type DdQueueItem. Otherwise, it can declare them to be of a - structure type such that the first three fields are data - pointers. The third pointer points to the node. The first two - pointers are used by the level queue functions. The remaining fields - are initialized to 0 when a new item is created, and are then left - to the exclusive use of the application. On the DEC Alphas the three - pointers must be 32-bit pointers when CUDD is compiled with 32-bit - pointers. The level queue functions make sure that each node - appears at most once in the queue. They do so by keeping a hash - table where the node is used as key. Queue items are recycled via a - free list for efficiency. - - Internal procedures provided by this module: - <ul> - <li> cuddLevelQueueInit() - <li> cuddLevelQueueQuit() - <li> cuddLevelQueueEnqueue() - <li> cuddLevelQueueDequeue() - </ul> - Static procedures included in this module: - <ul> - <li> hashLookup() - <li> hashInsert() - <li> hashDelete() - <li> hashResize() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#cuddLevelQueueInit" TARGET="MAIN"><CODE>cuddLevelQueueInit()</CODE></A> - <DD> Initializes a level queue. - - <DT> <A HREF="cuddAllDet.html#cuddLevelQueueQuit" TARGET="MAIN"><CODE>cuddLevelQueueQuit()</CODE></A> - <DD> Shuts down a level queue. - - <DT> <A HREF="cuddAllDet.html#cuddLevelQueueEnqueue" TARGET="MAIN"><CODE>cuddLevelQueueEnqueue()</CODE></A> - <DD> Inserts a new key in a level queue. - - <DT> <A HREF="cuddAllDet.html#cuddLevelQueueFirst" TARGET="MAIN"><CODE>cuddLevelQueueFirst()</CODE></A> - <DD> Inserts the first key in a level queue. - - <DT> <A HREF="cuddAllDet.html#cuddLevelQueueDequeue" TARGET="MAIN"><CODE>cuddLevelQueueDequeue()</CODE></A> - <DD> Remove an item from the front of a level queue. - - <DT> <A HREF="cuddAllDet.html#hashLookup" TARGET="MAIN"><CODE>hashLookup()</CODE></A> - <DD> Looks up a key in the hash table of a level queue. - - <DT> <A HREF="cuddAllDet.html#hashInsert" TARGET="MAIN"><CODE>hashInsert()</CODE></A> - <DD> Inserts an item in the hash table of a level queue. - - <DT> <A HREF="cuddAllDet.html#hashDelete" TARGET="MAIN"><CODE>hashDelete()</CODE></A> - <DD> Removes an item from the hash table of a level queue. - - <DT> <A HREF="cuddAllDet.html#hashResize" TARGET="MAIN"><CODE>hashResize()</CODE></A> - <DD> Resizes the hash table of a level queue. - -</DL> -<HR> -<A NAME="cuddLinear.c"><H1>cuddLinear.c</H1></A> -Functions for DD reduction by linear transformations. <P> -<B>By: Fabio Somenzi</B><P> -Internal procedures included in this module: - <ul> - <li> cuddLinearAndSifting() - <li> cuddLinearInPlace() - <li> cuddUpdateInteractionMatrix() - <li> cuddInitLinear() - <li> cuddResizeLinear() - </ul> - Static procedures included in this module: - <ul> - <li> ddLinearUniqueCompare() - <li> ddLinearAndSiftingAux() - <li> ddLinearAndSiftingUp() - <li> ddLinearAndSiftingDown() - <li> ddLinearAndSiftingBackward() - <li> ddUndoMoves() - <li> cuddXorLinear() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_PrintLinear" TARGET="MAIN"><CODE>Cudd_PrintLinear()</CODE></A> - <DD> Prints the linear transform matrix. - - <DT> <A HREF="cuddAllDet.html#Cudd_ReadLinear" TARGET="MAIN"><CODE>Cudd_ReadLinear()</CODE></A> - <DD> Reads an entry of the linear transform matrix. - - <DT> <A HREF="cuddAllDet.html#cuddLinearAndSifting" TARGET="MAIN"><CODE>cuddLinearAndSifting()</CODE></A> - <DD> BDD reduction based on combination of sifting and linear - transformations. - - <DT> <A HREF="cuddAllDet.html#cuddLinearInPlace" TARGET="MAIN"><CODE>cuddLinearInPlace()</CODE></A> - <DD> Linearly combines two adjacent variables. - - <DT> <A HREF="cuddAllDet.html#cuddUpdateInteractionMatrix" TARGET="MAIN"><CODE>cuddUpdateInteractionMatrix()</CODE></A> - <DD> Updates the interaction matrix. - - <DT> <A HREF="cuddAllDet.html#cuddInitLinear" TARGET="MAIN"><CODE>cuddInitLinear()</CODE></A> - <DD> Initializes the linear transform matrix. - - <DT> <A HREF="cuddAllDet.html#cuddResizeLinear" TARGET="MAIN"><CODE>cuddResizeLinear()</CODE></A> - <DD> Resizes the linear transform matrix. - - <DT> <A HREF="cuddAllDet.html#ddLinearUniqueCompare" TARGET="MAIN"><CODE>ddLinearUniqueCompare()</CODE></A> - <DD> Comparison function used by qsort. - - <DT> <A HREF="cuddAllDet.html#ddLinearAndSiftingAux" TARGET="MAIN"><CODE>ddLinearAndSiftingAux()</CODE></A> - <DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - - <DT> <A HREF="cuddAllDet.html#ddLinearAndSiftingUp" TARGET="MAIN"><CODE>ddLinearAndSiftingUp()</CODE></A> - <DD> Sifts a variable up and applies linear transformations. - - <DT> <A HREF="cuddAllDet.html#ddLinearAndSiftingDown" TARGET="MAIN"><CODE>ddLinearAndSiftingDown()</CODE></A> - <DD> Sifts a variable down and applies linear transformations. - - <DT> <A HREF="cuddAllDet.html#ddLinearAndSiftingBackward" TARGET="MAIN"><CODE>ddLinearAndSiftingBackward()</CODE></A> - <DD> Given a set of moves, returns the DD heap to the order - giving the minimum size. - - <DT> <A HREF="cuddAllDet.html#ddUndoMoves" TARGET="MAIN"><CODE>ddUndoMoves()</CODE></A> - <DD> Given a set of moves, returns the DD heap to the order - in effect before the moves. - - <DT> <A HREF="cuddAllDet.html#cuddXorLinear" TARGET="MAIN"><CODE>cuddXorLinear()</CODE></A> - <DD> XORs two rows of the linear transform matrix. - -</DL> -<HR> -<A NAME="cuddLiteral.c"><H1>cuddLiteral.c</H1></A> -Functions for manipulation of literal sets represented by - BDDs. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this file: - <ul> - <li> Cudd_bddLiteralSetIntersection() - </ul> - Internal procedures included in this file: - <ul> - <li> cuddBddLiteralSetIntersectionRecur() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_bddLiteralSetIntersection" TARGET="MAIN"><CODE>Cudd_bddLiteralSetIntersection()</CODE></A> - <DD> Computes the intesection of two sets of literals - represented as BDDs. - - <DT> <A HREF="cuddAllDet.html#cuddBddLiteralSetIntersectionRecur" TARGET="MAIN"><CODE>cuddBddLiteralSetIntersectionRecur()</CODE></A> - <DD> Performs the recursive step of - Cudd_bddLiteralSetIntersection. - -</DL> -<HR> -<A NAME="cuddMatMult.c"><H1>cuddMatMult.c</H1></A> -Matrix multiplication functions. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_addMatrixMultiply() - <li> Cudd_addTimesPlus() - <li> Cudd_addTriangle() - <li> Cudd_addOuterSum() - </ul> - Static procedures included in this module: - <ul> - <li> addMMRecur() - <li> addTriangleRecur() - <li> cuddAddOuterSumRecur() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addMatrixMultiply" TARGET="MAIN"><CODE>Cudd_addMatrixMultiply()</CODE></A> - <DD> Calculates the product of two matrices represented as - ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_addTimesPlus" TARGET="MAIN"><CODE>Cudd_addTimesPlus()</CODE></A> - <DD> Calculates the product of two matrices represented as - ADDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_addTriangle" TARGET="MAIN"><CODE>Cudd_addTriangle()</CODE></A> - <DD> Performs the triangulation step for the shortest path - computation. - - <DT> <A HREF="cuddAllDet.html#Cudd_addOuterSum" TARGET="MAIN"><CODE>Cudd_addOuterSum()</CODE></A> - <DD> Takes the minimum of a matrix and the outer sum of two vectors. - - <DT> <A HREF="cuddAllDet.html#addMMRecur" TARGET="MAIN"><CODE>addMMRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addMatrixMultiply. - - <DT> <A HREF="cuddAllDet.html#addTriangleRecur" TARGET="MAIN"><CODE>addTriangleRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addTriangle. - - <DT> <A HREF="cuddAllDet.html#cuddAddOuterSumRecur" TARGET="MAIN"><CODE>cuddAddOuterSumRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_addOuterSum. - -</DL> -<HR> -<A NAME="cuddPriority.c"><H1>cuddPriority.c</H1></A> -Priority functions. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this file: - <ul> - <li> Cudd_PrioritySelect() - <li> Cudd_Xgty() - <li> Cudd_Xeqy() - <li> Cudd_addXeqy() - <li> Cudd_Dxygtdxz() - <li> Cudd_Dxygtdyz() - <li> Cudd_Inequality() - <li> Cudd_Disequality() - <li> Cudd_bddInterval() - <li> Cudd_CProjection() - <li> Cudd_addHamming() - <li> Cudd_MinHammingDist() - <li> Cudd_bddClosestCube() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddCProjectionRecur() - <li> cuddBddClosestCube() - </ul> - Static procedures included in this module: - <ul> - <li> cuddMinHammingDistRecur() - <li> separateCube() - <li> createResult() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_PrioritySelect" TARGET="MAIN"><CODE>Cudd_PrioritySelect()</CODE></A> - <DD> Selects pairs from R using a priority function. - - <DT> <A HREF="cuddAllDet.html#Cudd_Xgty" TARGET="MAIN"><CODE>Cudd_Xgty()</CODE></A> - <DD> Generates a BDD for the function x > y. - - <DT> <A HREF="cuddAllDet.html#Cudd_Xeqy" TARGET="MAIN"><CODE>Cudd_Xeqy()</CODE></A> - <DD> Generates a BDD for the function x==y. - - <DT> <A HREF="cuddAllDet.html#Cudd_addXeqy" TARGET="MAIN"><CODE>Cudd_addXeqy()</CODE></A> - <DD> Generates an ADD for the function x==y. - - <DT> <A HREF="cuddAllDet.html#Cudd_Dxygtdxz" TARGET="MAIN"><CODE>Cudd_Dxygtdxz()</CODE></A> - <DD> Generates a BDD for the function d(x,y) > d(x,z). - - <DT> <A HREF="cuddAllDet.html#Cudd_Dxygtdyz" TARGET="MAIN"><CODE>Cudd_Dxygtdyz()</CODE></A> - <DD> Generates a BDD for the function d(x,y) > d(y,z). - - <DT> <A HREF="cuddAllDet.html#Cudd_Inequality" TARGET="MAIN"><CODE>Cudd_Inequality()</CODE></A> - <DD> Generates a BDD for the function x - y ≥ c. - - <DT> <A HREF="cuddAllDet.html#Cudd_Disequality" TARGET="MAIN"><CODE>Cudd_Disequality()</CODE></A> - <DD> Generates a BDD for the function x - y != c. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddInterval" TARGET="MAIN"><CODE>Cudd_bddInterval()</CODE></A> - <DD> Generates a BDD for the function lowerB ≤ x ≤ upperB. - - <DT> <A HREF="cuddAllDet.html#Cudd_CProjection" TARGET="MAIN"><CODE>Cudd_CProjection()</CODE></A> - <DD> Computes the compatible projection of R w.r.t. cube Y. - - <DT> <A HREF="cuddAllDet.html#Cudd_addHamming" TARGET="MAIN"><CODE>Cudd_addHamming()</CODE></A> - <DD> Computes the Hamming distance ADD. - - <DT> <A HREF="cuddAllDet.html#Cudd_MinHammingDist" TARGET="MAIN"><CODE>Cudd_MinHammingDist()</CODE></A> - <DD> Returns the minimum Hamming distance between f and minterm. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddClosestCube" TARGET="MAIN"><CODE>Cudd_bddClosestCube()</CODE></A> - <DD> Finds a cube of f at minimum Hamming distance from g. - - <DT> <A HREF="cuddAllDet.html#cuddCProjectionRecur" TARGET="MAIN"><CODE>cuddCProjectionRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_CProjection. - - <DT> <A HREF="cuddAllDet.html#cuddBddClosestCube" TARGET="MAIN"><CODE>cuddBddClosestCube()</CODE></A> - <DD> Performs the recursive step of Cudd_bddClosestCube. - - <DT> <A HREF="cuddAllDet.html#cuddMinHammingDistRecur" TARGET="MAIN"><CODE>cuddMinHammingDistRecur()</CODE></A> - <DD> Performs the recursive step of Cudd_MinHammingDist. - - <DT> <A HREF="cuddAllDet.html#separateCube" TARGET="MAIN"><CODE>separateCube()</CODE></A> - <DD> Separates cube from distance. - - <DT> <A HREF="cuddAllDet.html#createResult" TARGET="MAIN"><CODE>createResult()</CODE></A> - <DD> Builds a result for cache storage. - -</DL> -<HR> -<A NAME="cuddRead.c"><H1>cuddRead.c</H1></A> -Functions to read in a matrix <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_addRead() - <li> Cudd_bddRead() - </ul> <P> -<P><B>See Also</B><A HREF="#cudd_addHarwell.c"><CODE>cudd_addHarwell.c</CODE></A> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_addRead" TARGET="MAIN"><CODE>Cudd_addRead()</CODE></A> - <DD> Reads in a sparse matrix. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddRead" TARGET="MAIN"><CODE>Cudd_bddRead()</CODE></A> - <DD> Reads in a graph (without labels) given as a list of arcs. - -</DL> -<HR> -<A NAME="cuddRef.c"><H1>cuddRef.c</H1></A> -Functions that manipulate the reference counts. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_Ref() - <li> Cudd_RecursiveDeref() - <li> Cudd_IterDerefBdd() - <li> Cudd_DelayedDerefBdd() - <li> Cudd_RecursiveDerefZdd() - <li> Cudd_Deref() - <li> Cudd_CheckZeroRef() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddReclaim() - <li> cuddReclaimZdd() - <li> cuddClearDeathRow() - <li> cuddShrinkDeathRow() - <li> cuddIsInDeathRow() - <li> cuddTimesInDeathRow() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_Ref" TARGET="MAIN"><CODE>Cudd_Ref()</CODE></A> - <DD> Increases the reference count of a node, if it is not - saturated. - - <DT> <A HREF="cuddAllDet.html#Cudd_RecursiveDeref" TARGET="MAIN"><CODE>Cudd_RecursiveDeref()</CODE></A> - <DD> Decreases the reference count of node n. - - <DT> <A HREF="cuddAllDet.html#Cudd_IterDerefBdd" TARGET="MAIN"><CODE>Cudd_IterDerefBdd()</CODE></A> - <DD> Decreases the reference count of BDD node n. - - <DT> <A HREF="cuddAllDet.html#Cudd_DelayedDerefBdd" TARGET="MAIN"><CODE>Cudd_DelayedDerefBdd()</CODE></A> - <DD> Decreases the reference count of BDD node n. - - <DT> <A HREF="cuddAllDet.html#Cudd_RecursiveDerefZdd" TARGET="MAIN"><CODE>Cudd_RecursiveDerefZdd()</CODE></A> - <DD> Decreases the reference count of ZDD node n. - - <DT> <A HREF="cuddAllDet.html#Cudd_Deref" TARGET="MAIN"><CODE>Cudd_Deref()</CODE></A> - <DD> Decreases the reference count of node. - - <DT> <A HREF="cuddAllDet.html#Cudd_CheckZeroRef" TARGET="MAIN"><CODE>Cudd_CheckZeroRef()</CODE></A> - <DD> Checks the unique table for nodes with non-zero reference - counts. - - <DT> <A HREF="cuddAllDet.html#cuddReclaim" TARGET="MAIN"><CODE>cuddReclaim()</CODE></A> - <DD> Brings children of a dead node back. - - <DT> <A HREF="cuddAllDet.html#cuddReclaimZdd" TARGET="MAIN"><CODE>cuddReclaimZdd()</CODE></A> - <DD> Brings children of a dead ZDD node back. - - <DT> <A HREF="cuddAllDet.html#cuddShrinkDeathRow" TARGET="MAIN"><CODE>cuddShrinkDeathRow()</CODE></A> - <DD> Shrinks the death row. - - <DT> <A HREF="cuddAllDet.html#cuddClearDeathRow" TARGET="MAIN"><CODE>cuddClearDeathRow()</CODE></A> - <DD> Clears the death row. - - <DT> <A HREF="cuddAllDet.html#cuddIsInDeathRow" TARGET="MAIN"><CODE>cuddIsInDeathRow()</CODE></A> - <DD> Checks whether a node is in the death row. - - <DT> <A HREF="cuddAllDet.html#cuddTimesInDeathRow" TARGET="MAIN"><CODE>cuddTimesInDeathRow()</CODE></A> - <DD> Counts how many times a node is in the death row. - -</DL> -<HR> -<A NAME="cuddReorder.c"><H1>cuddReorder.c</H1></A> -Functions for dynamic variable reordering. <P> -<B>By: Shipra Panda, Bernard Plessier, Fabio Somenzi</B><P> -External procedures included in this file: - <ul> - <li> Cudd_ReduceHeap() - <li> Cudd_ShuffleHeap() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddDynamicAllocNode() - <li> cuddSifting() - <li> cuddSwapping() - <li> cuddNextHigh() - <li> cuddNextLow() - <li> cuddSwapInPlace() - <li> cuddBddAlignToZdd() - </ul> - Static procedures included in this module: - <ul> - <li> ddUniqueCompare() - <li> ddSwapAny() - <li> ddSiftingAux() - <li> ddSiftingUp() - <li> ddSiftingDown() - <li> ddSiftingBackward() - <li> ddReorderPreprocess() - <li> ddReorderPostprocess() - <li> ddShuffle() - <li> ddSiftUp() - <li> bddFixTree() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_ReduceHeap" TARGET="MAIN"><CODE>Cudd_ReduceHeap()</CODE></A> - <DD> Main dynamic reordering routine. - - <DT> <A HREF="cuddAllDet.html#Cudd_ShuffleHeap" TARGET="MAIN"><CODE>Cudd_ShuffleHeap()</CODE></A> - <DD> Reorders variables according to given permutation. - - <DT> <A HREF="cuddAllDet.html#cuddDynamicAllocNode" TARGET="MAIN"><CODE>cuddDynamicAllocNode()</CODE></A> - <DD> Dynamically allocates a Node. - - <DT> <A HREF="cuddAllDet.html#cuddSifting" TARGET="MAIN"><CODE>cuddSifting()</CODE></A> - <DD> Implementation of Rudell's sifting algorithm. - - <DT> <A HREF="cuddAllDet.html#cuddSwapping" TARGET="MAIN"><CODE>cuddSwapping()</CODE></A> - <DD> Reorders variables by a sequence of (non-adjacent) swaps. - - <DT> <A HREF="cuddAllDet.html#cuddNextHigh" TARGET="MAIN"><CODE>cuddNextHigh()</CODE></A> - <DD> Finds the next subtable with a larger index. - - <DT> <A HREF="cuddAllDet.html#cuddNextLow" TARGET="MAIN"><CODE>cuddNextLow()</CODE></A> - <DD> Finds the next subtable with a smaller index. - - <DT> <A HREF="cuddAllDet.html#cuddSwapInPlace" TARGET="MAIN"><CODE>cuddSwapInPlace()</CODE></A> - <DD> Swaps two adjacent variables. - - <DT> <A HREF="cuddAllDet.html#cuddBddAlignToZdd" TARGET="MAIN"><CODE>cuddBddAlignToZdd()</CODE></A> - <DD> Reorders BDD variables according to the order of the ZDD - variables. - - <DT> <A HREF="cuddAllDet.html#ddUniqueCompare" TARGET="MAIN"><CODE>ddUniqueCompare()</CODE></A> - <DD> Comparison function used by qsort. - - <DT> <A HREF="cuddAllDet.html#ddSwapAny" TARGET="MAIN"><CODE>ddSwapAny()</CODE></A> - <DD> Swaps any two variables. - - <DT> <A HREF="cuddAllDet.html#ddSiftingAux" TARGET="MAIN"><CODE>ddSiftingAux()</CODE></A> - <DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - - <DT> <A HREF="cuddAllDet.html#ddSiftingUp" TARGET="MAIN"><CODE>ddSiftingUp()</CODE></A> - <DD> Sifts a variable up. - - <DT> <A HREF="cuddAllDet.html#ddSiftingDown" TARGET="MAIN"><CODE>ddSiftingDown()</CODE></A> - <DD> Sifts a variable down. - - <DT> <A HREF="cuddAllDet.html#ddSiftingBackward" TARGET="MAIN"><CODE>ddSiftingBackward()</CODE></A> - <DD> Given a set of moves, returns the DD heap to the position - giving the minimum size. - - <DT> <A HREF="cuddAllDet.html#ddReorderPreprocess" TARGET="MAIN"><CODE>ddReorderPreprocess()</CODE></A> - <DD> Prepares the DD heap for dynamic reordering. - - <DT> <A HREF="cuddAllDet.html#ddReorderPostprocess" TARGET="MAIN"><CODE>ddReorderPostprocess()</CODE></A> - <DD> Cleans up at the end of reordering. - - <DT> <A HREF="cuddAllDet.html#ddShuffle" TARGET="MAIN"><CODE>ddShuffle()</CODE></A> - <DD> Reorders variables according to a given permutation. - - <DT> <A HREF="cuddAllDet.html#ddSiftUp" TARGET="MAIN"><CODE>ddSiftUp()</CODE></A> - <DD> Moves one variable up. - - <DT> <A HREF="cuddAllDet.html#bddFixTree" TARGET="MAIN"><CODE>bddFixTree()</CODE></A> - <DD> Fixes the BDD variable group tree after a shuffle. - - <DT> <A HREF="cuddAllDet.html#ddUpdateMtrTree" TARGET="MAIN"><CODE>ddUpdateMtrTree()</CODE></A> - <DD> Updates the BDD variable group tree before a shuffle. - - <DT> <A HREF="cuddAllDet.html#ddCheckPermuation" TARGET="MAIN"><CODE>ddCheckPermuation()</CODE></A> - <DD> Checks the BDD variable group tree before a shuffle. - -</DL> -<HR> -<A NAME="cuddSat.c"><H1>cuddSat.c</H1></A> -Functions for the solution of satisfiability related problems. <P> -<B>By: Seh-Woong Jeong, Fabio Somenzi</B><P> -External procedures included in this file: - <ul> - <li> Cudd_Eval() - <li> Cudd_ShortestPath() - <li> Cudd_LargestCube() - <li> Cudd_ShortestLength() - <li> Cudd_Decreasing() - <li> Cudd_Increasing() - <li> Cudd_EquivDC() - <li> Cudd_bddLeqUnless() - <li> Cudd_EqualSupNorm() - <li> Cudd_bddMakePrime() - <li> Cudd_bddMaximallyExpand() - <li> Cudd_bddLargestPrimeUnate() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddMakePrime() - </ul> - Static procedures included in this module: - <ul> - <li> freePathPair() - <li> getShortest() - <li> getPath() - <li> getLargest() - <li> getCube() - <li> ddBddMaximallyExpand() - <li> ddShortestPathUnate() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_Eval" TARGET="MAIN"><CODE>Cudd_Eval()</CODE></A> - <DD> Returns the value of a DD for a given variable assignment. - - <DT> <A HREF="cuddAllDet.html#Cudd_ShortestPath" TARGET="MAIN"><CODE>Cudd_ShortestPath()</CODE></A> - <DD> Finds a shortest path in a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_LargestCube" TARGET="MAIN"><CODE>Cudd_LargestCube()</CODE></A> - <DD> Finds a largest cube in a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_ShortestLength" TARGET="MAIN"><CODE>Cudd_ShortestLength()</CODE></A> - <DD> Find the length of the shortest path(s) in a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_Decreasing" TARGET="MAIN"><CODE>Cudd_Decreasing()</CODE></A> - <DD> Determines whether a BDD is negative unate in a - variable. - - <DT> <A HREF="cuddAllDet.html#Cudd_Increasing" TARGET="MAIN"><CODE>Cudd_Increasing()</CODE></A> - <DD> Determines whether a BDD is positive unate in a - variable. - - <DT> <A HREF="cuddAllDet.html#Cudd_EquivDC" TARGET="MAIN"><CODE>Cudd_EquivDC()</CODE></A> - <DD> Tells whether F and G are identical wherever D is 0. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddLeqUnless" TARGET="MAIN"><CODE>Cudd_bddLeqUnless()</CODE></A> - <DD> Tells whether f is less than of equal to G unless D is 1. - - <DT> <A HREF="cuddAllDet.html#Cudd_EqualSupNorm" TARGET="MAIN"><CODE>Cudd_EqualSupNorm()</CODE></A> - <DD> Compares two ADDs for equality within tolerance. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddMakePrime" TARGET="MAIN"><CODE>Cudd_bddMakePrime()</CODE></A> - <DD> Expands cube to a prime implicant of f. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddMaximallyExpand" TARGET="MAIN"><CODE>Cudd_bddMaximallyExpand()</CODE></A> - <DD> Expands lb to prime implicants of (f and ub). - - <DT> <A HREF="cuddAllDet.html#Cudd_bddLargestPrimeUnate" TARGET="MAIN"><CODE>Cudd_bddLargestPrimeUnate()</CODE></A> - <DD> Find a largest prime of a unate function. - - <DT> <A HREF="cuddAllDet.html#cuddBddMakePrime" TARGET="MAIN"><CODE>cuddBddMakePrime()</CODE></A> - <DD> Performs the recursive step of Cudd_bddMakePrime. - - <DT> <A HREF="cuddAllDet.html#freePathPair" TARGET="MAIN"><CODE>freePathPair()</CODE></A> - <DD> Frees the entries of the visited symbol table. - - <DT> <A HREF="cuddAllDet.html#getShortest" TARGET="MAIN"><CODE>getShortest()</CODE></A> - <DD> Finds the length of the shortest path(s) in a DD. - - <DT> <A HREF="cuddAllDet.html#getPath" TARGET="MAIN"><CODE>getPath()</CODE></A> - <DD> Build a BDD for a shortest path of f. - - <DT> <A HREF="cuddAllDet.html#getLargest" TARGET="MAIN"><CODE>getLargest()</CODE></A> - <DD> Finds the size of the largest cube(s) in a DD. - - <DT> <A HREF="cuddAllDet.html#getCube" TARGET="MAIN"><CODE>getCube()</CODE></A> - <DD> Build a BDD for a largest cube of f. - - <DT> <A HREF="cuddAllDet.html#ddBddMaximallyExpand" TARGET="MAIN"><CODE>ddBddMaximallyExpand()</CODE></A> - <DD> Performs the recursive step of Cudd_bddMaximallyExpand. - - <DT> <A HREF="cuddAllDet.html#ddBddShortestPathUnate" TARGET="MAIN"><CODE>ddBddShortestPathUnate()</CODE></A> - <DD> Performs shortest path computation on a unate function. - - <DT> <A HREF="cuddAllDet.html#ddGetLargestCubeUnate" TARGET="MAIN"><CODE>ddGetLargestCubeUnate()</CODE></A> - <DD> Extracts largest prime of a unate function. - -</DL> -<HR> -<A NAME="cuddSign.c"><H1>cuddSign.c</H1></A> -Computation of signatures. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_CofMinterm(); - </ul> - Static procedures included in this module: - <ul> - <li> ddCofMintermAux() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_CofMinterm" TARGET="MAIN"><CODE>Cudd_CofMinterm()</CODE></A> - <DD> Computes the fraction of minterms in the on-set of all the - positive cofactors of a BDD or ADD. - - <DT> <A HREF="cuddAllDet.html#ddCofMintermAux" TARGET="MAIN"><CODE>ddCofMintermAux()</CODE></A> - <DD> Recursive Step for Cudd_CofMinterm function. - -</DL> -<HR> -<A NAME="cuddSolve.c"><H1>cuddSolve.c</H1></A> -Boolean equation solver and related functions. <P> -<B>By: Balakrishna Kumthekar</B><P> -External functions included in this modoule: - <ul> - <li> Cudd_SolveEqn() - <li> Cudd_VerifySol() - </ul> - Internal functions included in this module: - <ul> - <li> cuddSolveEqnRecur() - <li> cuddVerifySol() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_SolveEqn" TARGET="MAIN"><CODE>Cudd_SolveEqn()</CODE></A> - <DD> Implements the solution of F(x,y) = 0. - - <DT> <A HREF="cuddAllDet.html#Cudd_VerifySol" TARGET="MAIN"><CODE>Cudd_VerifySol()</CODE></A> - <DD> Checks the solution of F(x,y) = 0. - - <DT> <A HREF="cuddAllDet.html#cuddSolveEqnRecur" TARGET="MAIN"><CODE>cuddSolveEqnRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_SolveEqn. - - <DT> <A HREF="cuddAllDet.html#cuddVerifySol" TARGET="MAIN"><CODE>cuddVerifySol()</CODE></A> - <DD> Implements the recursive step of Cudd_VerifySol. - -</DL> -<HR> -<A NAME="cuddSplit.c"><H1>cuddSplit.c</H1></A> -Returns a subset of minterms from a boolean function. <P> -<B>By: Balakrishna Kumthekar</B><P> -External functions included in this modoule: - <ul> - <li> Cudd_SplitSet() - </ul> - Internal functions included in this module: - <ul> - <li> cuddSplitSetRecur() - </u> - Static functions included in this module: - <ul> - <li> selectMintermsFromUniverse() - <li> mintermsFromUniverse() - <li> bddAnnotateMintermCount() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_SplitSet" TARGET="MAIN"><CODE>Cudd_SplitSet()</CODE></A> - <DD> Returns m minterms from a BDD. - - <DT> <A HREF="cuddAllDet.html#cuddSplitSetRecur" TARGET="MAIN"><CODE>cuddSplitSetRecur()</CODE></A> - <DD> Implements the recursive step of Cudd_SplitSet. - - <DT> <A HREF="cuddAllDet.html#selectMintermsFromUniverse" TARGET="MAIN"><CODE>selectMintermsFromUniverse()</CODE></A> - <DD> This function prepares an array of variables which have not been - encountered so far when traversing the procedure cuddSplitSetRecur. - - <DT> <A HREF="cuddAllDet.html#mintermsFromUniverse" TARGET="MAIN"><CODE>mintermsFromUniverse()</CODE></A> - <DD> Recursive procedure to extract n mintems from constant 1. - - <DT> <A HREF="cuddAllDet.html#bddAnnotateMintermCount" TARGET="MAIN"><CODE>bddAnnotateMintermCount()</CODE></A> - <DD> Annotates every node in the BDD node with its minterm count. - -</DL> -<HR> -<A NAME="cuddSubsetHB.c"><H1>cuddSubsetHB.c</H1></A> -Procedure to subset the given BDD by choosing the heavier - branches. <P> -<B>By: Kavita Ravi</B><P> -External procedures provided by this module: - <ul> - <li> Cudd_SubsetHeavyBranch() - <li> Cudd_SupersetHeavyBranch() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddSubsetHeavyBranch() - </ul> - Static procedures included in this module: - <ul> - <li> ResizeCountMintermPages(); - <li> ResizeNodeDataPages() - <li> ResizeCountNodePages() - <li> SubsetCountMintermAux() - <li> SubsetCountMinterm() - <li> SubsetCountNodesAux() - <li> SubsetCountNodes() - <li> BuildSubsetBdd() - </ul> <P> -<P><B>See Also</B><A HREF="#cuddSubsetSP.c"><CODE>cuddSubsetSP.c</CODE></A> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_SubsetHeavyBranch" TARGET="MAIN"><CODE>Cudd_SubsetHeavyBranch()</CODE></A> - <DD> Extracts a dense subset from a BDD with the heavy branch - heuristic. - - <DT> <A HREF="cuddAllDet.html#Cudd_SupersetHeavyBranch" TARGET="MAIN"><CODE>Cudd_SupersetHeavyBranch()</CODE></A> - <DD> Extracts a dense superset from a BDD with the heavy branch - heuristic. - - <DT> <A HREF="cuddAllDet.html#cuddSubsetHeavyBranch" TARGET="MAIN"><CODE>cuddSubsetHeavyBranch()</CODE></A> - <DD> The main procedure that returns a subset by choosing the heavier - branch in the BDD. - - <DT> <A HREF="cuddAllDet.html#ResizeNodeDataPages" TARGET="MAIN"><CODE>ResizeNodeDataPages()</CODE></A> - <DD> Resize the number of pages allocated to store the node data. - - <DT> <A HREF="cuddAllDet.html#ResizeCountMintermPages" TARGET="MAIN"><CODE>ResizeCountMintermPages()</CODE></A> - <DD> Resize the number of pages allocated to store the minterm - counts. - - <DT> <A HREF="cuddAllDet.html#ResizeCountNodePages" TARGET="MAIN"><CODE>ResizeCountNodePages()</CODE></A> - <DD> Resize the number of pages allocated to store the node counts. - - <DT> <A HREF="cuddAllDet.html#SubsetCountMintermAux" TARGET="MAIN"><CODE>SubsetCountMintermAux()</CODE></A> - <DD> Recursively counts minterms of each node in the DAG. - - <DT> <A HREF="cuddAllDet.html#SubsetCountMinterm" TARGET="MAIN"><CODE>SubsetCountMinterm()</CODE></A> - <DD> Counts minterms of each node in the DAG - - <DT> <A HREF="cuddAllDet.html#SubsetCountNodesAux" TARGET="MAIN"><CODE>SubsetCountNodesAux()</CODE></A> - <DD> Recursively counts the number of nodes under the dag. - Also counts the number of nodes under the lighter child of - this node. - - <DT> <A HREF="cuddAllDet.html#SubsetCountNodes" TARGET="MAIN"><CODE>SubsetCountNodes()</CODE></A> - <DD> Counts the nodes under the current node and its lighter child - - <DT> <A HREF="cuddAllDet.html#StoreNodes" TARGET="MAIN"><CODE>StoreNodes()</CODE></A> - <DD> Procedure to recursively store nodes that are retained in the subset. - - <DT> <A HREF="cuddAllDet.html#BuildSubsetBdd" TARGET="MAIN"><CODE>BuildSubsetBdd()</CODE></A> - <DD> Builds the subset BDD using the heavy branch method. - -</DL> -<HR> -<A NAME="cuddSubsetSP.c"><H1>cuddSubsetSP.c</H1></A> -Procedure to subset the given BDD choosing the shortest paths - (largest cubes) in the BDD. <P> -<B>By: Kavita Ravi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_SubsetShortPaths() - <li> Cudd_SupersetShortPaths() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddSubsetShortPaths() - </ul> - Static procedures included in this module: - <ul> - <li> BuildSubsetBdd() - <li> CreatePathTable() - <li> AssessPathLength() - <li> CreateTopDist() - <li> CreateBotDist() - <li> ResizeNodeDistPages() - <li> ResizeQueuePages() - <li> stPathTableDdFree() - </ul> <P> -<P><B>See Also</B><A HREF="#cuddSubsetHB.c"><CODE>cuddSubsetHB.c</CODE></A> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_SubsetShortPaths" TARGET="MAIN"><CODE>Cudd_SubsetShortPaths()</CODE></A> - <DD> Extracts a dense subset from a BDD with the shortest paths - heuristic. - - <DT> <A HREF="cuddAllDet.html#Cudd_SupersetShortPaths" TARGET="MAIN"><CODE>Cudd_SupersetShortPaths()</CODE></A> - <DD> Extracts a dense superset from a BDD with the shortest paths - heuristic. - - <DT> <A HREF="cuddAllDet.html#cuddSubsetShortPaths" TARGET="MAIN"><CODE>cuddSubsetShortPaths()</CODE></A> - <DD> The outermost procedure to return a subset of the given BDD - with the shortest path lengths. - - <DT> <A HREF="cuddAllDet.html#ResizeNodeDistPages" TARGET="MAIN"><CODE>ResizeNodeDistPages()</CODE></A> - <DD> Resize the number of pages allocated to store the distances - related to each node. - - <DT> <A HREF="cuddAllDet.html#ResizeQueuePages" TARGET="MAIN"><CODE>ResizeQueuePages()</CODE></A> - <DD> Resize the number of pages allocated to store nodes in the BFS - traversal of the Bdd . - - <DT> <A HREF="cuddAllDet.html#CreateTopDist" TARGET="MAIN"><CODE>CreateTopDist()</CODE></A> - <DD> Labels each node with its shortest distance from the root - - <DT> <A HREF="cuddAllDet.html#CreateBotDist" TARGET="MAIN"><CODE>CreateBotDist()</CODE></A> - <DD> Labels each node with the shortest distance from the constant. - - <DT> <A HREF="cuddAllDet.html#CreatePathTable" TARGET="MAIN"><CODE>CreatePathTable()</CODE></A> - <DD> The outer procedure to label each node with its shortest - distance from the root and constant - - <DT> <A HREF="cuddAllDet.html#AssessPathLength" TARGET="MAIN"><CODE>AssessPathLength()</CODE></A> - <DD> Chooses the maximum allowable path length of nodes under the - threshold. - - <DT> <A HREF="cuddAllDet.html#BuildSubsetBdd" TARGET="MAIN"><CODE>BuildSubsetBdd()</CODE></A> - <DD> Builds the BDD with nodes labeled with path length less than or equal to maxpath - - <DT> <A HREF="cuddAllDet.html#stPathTableDdFree" TARGET="MAIN"><CODE>stPathTableDdFree()</CODE></A> - <DD> Procedure to free te result dds stored in the NodeDist pages. - -</DL> -<HR> -<A NAME="cuddSymmetry.c"><H1>cuddSymmetry.c</H1></A> -Functions for symmetry-based variable reordering. <P> -<B>By: Shipra Panda, Fabio Somenzi</B><P> -External procedures included in this file: - <ul> - <li> Cudd_SymmProfile() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddSymmCheck() - <li> cuddSymmSifting() - <li> cuddSymmSiftingConv() - </ul> - Static procedures included in this module: - <ul> - <li> ddSymmUniqueCompare() - <li> ddSymmSiftingAux() - <li> ddSymmSiftingConvAux() - <li> ddSymmSiftingUp() - <li> ddSymmSiftingDown() - <li> ddSymmGroupMove() - <li> ddSymmGroupMoveBackward() - <li> ddSymmSiftingBackward() - <li> ddSymmSummary() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_SymmProfile" TARGET="MAIN"><CODE>Cudd_SymmProfile()</CODE></A> - <DD> Prints statistics on symmetric variables. - - <DT> <A HREF="cuddAllDet.html#cuddSymmCheck" TARGET="MAIN"><CODE>cuddSymmCheck()</CODE></A> - <DD> Checks for symmetry of x and y. - - <DT> <A HREF="cuddAllDet.html#cuddSymmSifting" TARGET="MAIN"><CODE>cuddSymmSifting()</CODE></A> - <DD> Symmetric sifting algorithm. - - <DT> <A HREF="cuddAllDet.html#cuddSymmSiftingConv" TARGET="MAIN"><CODE>cuddSymmSiftingConv()</CODE></A> - <DD> Symmetric sifting to convergence algorithm. - - <DT> <A HREF="cuddAllDet.html#ddSymmUniqueCompare" TARGET="MAIN"><CODE>ddSymmUniqueCompare()</CODE></A> - <DD> Comparison function used by qsort. - - <DT> <A HREF="cuddAllDet.html#ddSymmSiftingAux" TARGET="MAIN"><CODE>ddSymmSiftingAux()</CODE></A> - <DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - - <DT> <A HREF="cuddAllDet.html#ddSymmSiftingConvAux" TARGET="MAIN"><CODE>ddSymmSiftingConvAux()</CODE></A> - <DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - - <DT> <A HREF="cuddAllDet.html#ddSymmSiftingUp" TARGET="MAIN"><CODE>ddSymmSiftingUp()</CODE></A> - <DD> Moves x up until either it reaches the bound (xLow) or - the size of the DD heap increases too much. - - <DT> <A HREF="cuddAllDet.html#ddSymmSiftingDown" TARGET="MAIN"><CODE>ddSymmSiftingDown()</CODE></A> - <DD> Moves x down until either it reaches the bound (xHigh) or - the size of the DD heap increases too much. - - <DT> <A HREF="cuddAllDet.html#ddSymmGroupMove" TARGET="MAIN"><CODE>ddSymmGroupMove()</CODE></A> - <DD> Swaps two groups. - - <DT> <A HREF="cuddAllDet.html#ddSymmGroupMoveBackward" TARGET="MAIN"><CODE>ddSymmGroupMoveBackward()</CODE></A> - <DD> Undoes the swap of two groups. - - <DT> <A HREF="cuddAllDet.html#ddSymmSiftingBackward" TARGET="MAIN"><CODE>ddSymmSiftingBackward()</CODE></A> - <DD> Given a set of moves, returns the DD heap to the position - giving the minimum size. - - <DT> <A HREF="cuddAllDet.html#ddSymmSummary" TARGET="MAIN"><CODE>ddSymmSummary()</CODE></A> - <DD> Counts numbers of symmetric variables and symmetry - groups. - -</DL> -<HR> -<A NAME="cuddTable.c"><H1>cuddTable.c</H1></A> -Unique table management functions. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_Prime() - <li> Cudd_Reserve() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAllocNode() - <li> cuddInitTable() - <li> cuddFreeTable() - <li> cuddGarbageCollect() - <li> cuddZddGetNode() - <li> cuddZddGetNodeIVO() - <li> cuddUniqueInter() - <li> cuddUniqueInterIVO() - <li> cuddUniqueInterZdd() - <li> cuddUniqueConst() - <li> cuddRehash() - <li> cuddShrinkSubtable() - <li> cuddInsertSubtables() - <li> cuddDestroySubtables() - <li> cuddResizeTableZdd() - <li> cuddSlowTableGrowth() - </ul> - Static procedures included in this module: - <ul> - <li> ddRehashZdd() - <li> ddResizeTable() - <li> cuddFindParent() - <li> cuddOrderedInsert() - <li> cuddOrderedThread() - <li> cuddRotateLeft() - <li> cuddRotateRight() - <li> cuddDoRebalance() - <li> cuddCheckCollisionOrdering() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_Prime" TARGET="MAIN"><CODE>Cudd_Prime()</CODE></A> - <DD> Returns the next prime >= p. - - <DT> <A HREF="cuddAllDet.html#Cudd_Reserve" TARGET="MAIN"><CODE>Cudd_Reserve()</CODE></A> - <DD> Expand manager without creating variables. - - <DT> <A HREF="cuddAllDet.html#cuddAllocNode" TARGET="MAIN"><CODE>cuddAllocNode()</CODE></A> - <DD> Fast storage allocation for DdNodes in the table. - - <DT> <A HREF="cuddAllDet.html#cuddInitTable" TARGET="MAIN"><CODE>cuddInitTable()</CODE></A> - <DD> Creates and initializes the unique table. - - <DT> <A HREF="cuddAllDet.html#cuddFreeTable" TARGET="MAIN"><CODE>cuddFreeTable()</CODE></A> - <DD> Frees the resources associated to a unique table. - - <DT> <A HREF="cuddAllDet.html#cuddGarbageCollect" TARGET="MAIN"><CODE>cuddGarbageCollect()</CODE></A> - <DD> Performs garbage collection on the unique tables. - - <DT> <A HREF="cuddAllDet.html#cuddZddGetNode" TARGET="MAIN"><CODE>cuddZddGetNode()</CODE></A> - <DD> Wrapper for cuddUniqueInterZdd. - - <DT> <A HREF="cuddAllDet.html#cuddZddGetNodeIVO" TARGET="MAIN"><CODE>cuddZddGetNodeIVO()</CODE></A> - <DD> Wrapper for cuddUniqueInterZdd that is independent of variable - ordering. - - <DT> <A HREF="cuddAllDet.html#cuddUniqueInter" TARGET="MAIN"><CODE>cuddUniqueInter()</CODE></A> - <DD> Checks the unique table for the existence of an internal node. - - <DT> <A HREF="cuddAllDet.html#cuddUniqueInterIVO" TARGET="MAIN"><CODE>cuddUniqueInterIVO()</CODE></A> - <DD> Wrapper for cuddUniqueInter that is independent of variable - ordering. - - <DT> <A HREF="cuddAllDet.html#cuddUniqueInterZdd" TARGET="MAIN"><CODE>cuddUniqueInterZdd()</CODE></A> - <DD> Checks the unique table for the existence of an internal - ZDD node. - - <DT> <A HREF="cuddAllDet.html#cuddUniqueConst" TARGET="MAIN"><CODE>cuddUniqueConst()</CODE></A> - <DD> Checks the unique table for the existence of a constant node. - - <DT> <A HREF="cuddAllDet.html#cuddRehash" TARGET="MAIN"><CODE>cuddRehash()</CODE></A> - <DD> Rehashes a unique subtable. - - <DT> <A HREF="cuddAllDet.html#cuddShrinkSubtable" TARGET="MAIN"><CODE>cuddShrinkSubtable()</CODE></A> - <DD> Shrinks a subtable. - - <DT> <A HREF="cuddAllDet.html#cuddInsertSubtables" TARGET="MAIN"><CODE>cuddInsertSubtables()</CODE></A> - <DD> Inserts n new subtables in a unique table at level. - - <DT> <A HREF="cuddAllDet.html#cuddDestroySubtables" TARGET="MAIN"><CODE>cuddDestroySubtables()</CODE></A> - <DD> Destroys the n most recently created subtables in a unique table. - - <DT> <A HREF="cuddAllDet.html#cuddResizeTableZdd" TARGET="MAIN"><CODE>cuddResizeTableZdd()</CODE></A> - <DD> Increases the number of ZDD subtables in a unique table so - that it meets or exceeds index. - - <DT> <A HREF="cuddAllDet.html#cuddSlowTableGrowth" TARGET="MAIN"><CODE>cuddSlowTableGrowth()</CODE></A> - <DD> Adjusts parameters of a table to slow down its growth. - - <DT> <A HREF="cuddAllDet.html#ddRehashZdd" TARGET="MAIN"><CODE>ddRehashZdd()</CODE></A> - <DD> Rehashes a ZDD unique subtable. - - <DT> <A HREF="cuddAllDet.html#ddResizeTable" TARGET="MAIN"><CODE>ddResizeTable()</CODE></A> - <DD> Increases the number of subtables in a unique table so - that it meets or exceeds index. - - <DT> <A HREF="cuddAllDet.html#cuddFindParent" TARGET="MAIN"><CODE>cuddFindParent()</CODE></A> - <DD> Searches the subtables above node for a parent. - - <DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> - <DD> Adjusts the values of table limits. - - <DT> <A HREF="cuddAllDet.html#cuddOrderedInsert" TARGET="MAIN"><CODE>cuddOrderedInsert()</CODE></A> - <DD> Inserts a DdNode in a red/black search tree. - - <DT> <A HREF="cuddAllDet.html#cuddOrderedThread" TARGET="MAIN"><CODE>cuddOrderedThread()</CODE></A> - <DD> Threads all the nodes of a search tree into a linear list. - - <DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> - <DD> Performs the left rotation for red/black trees. - - <DT> <A HREF="cuddAllDet.html#" TARGET="MAIN"><CODE>()</CODE></A> - <DD> Performs the right rotation for red/black trees. - - <DT> <A HREF="cuddAllDet.html#cuddDoRebalance" TARGET="MAIN"><CODE>cuddDoRebalance()</CODE></A> - <DD> Rebalances a red/black tree. - - <DT> <A HREF="cuddAllDet.html#ddPatchTree" TARGET="MAIN"><CODE>ddPatchTree()</CODE></A> - <DD> Fixes a variable tree after the insertion of new subtables. - - <DT> <A HREF="cuddAllDet.html#cuddCheckCollisionOrdering" TARGET="MAIN"><CODE>cuddCheckCollisionOrdering()</CODE></A> - <DD> Checks whether a collision list is ordered. - - <DT> <A HREF="cuddAllDet.html#ddReportRefMess" TARGET="MAIN"><CODE>ddReportRefMess()</CODE></A> - <DD> Reports problem in garbage collection. - -</DL> -<HR> -<A NAME="cuddUtil.c"><H1>cuddUtil.c</H1></A> -Utility functions. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_PrintMinterm() - <li> Cudd_bddPrintCover() - <li> Cudd_PrintDebug() - <li> Cudd_DagSize() - <li> Cudd_EstimateCofactor() - <li> Cudd_EstimateCofactorSimple() - <li> Cudd_SharingSize() - <li> Cudd_CountMinterm() - <li> Cudd_EpdCountMinterm() - <li> Cudd_CountPath() - <li> Cudd_CountPathsToNonZero() - <li> Cudd_SupportIndices() - <li> Cudd_Support() - <li> Cudd_SupportIndex() - <li> Cudd_SupportSize() - <li> Cudd_VectorSupportIndices() - <li> Cudd_VectorSupport() - <li> Cudd_VectorSupportIndex() - <li> Cudd_VectorSupportSize() - <li> Cudd_ClassifySupport() - <li> Cudd_CountLeaves() - <li> Cudd_bddPickOneCube() - <li> Cudd_bddPickOneMinterm() - <li> Cudd_bddPickArbitraryMinterms() - <li> Cudd_SubsetWithMaskVars() - <li> Cudd_FirstCube() - <li> Cudd_NextCube() - <li> Cudd_bddComputeCube() - <li> Cudd_addComputeCube() - <li> Cudd_FirstNode() - <li> Cudd_NextNode() - <li> Cudd_GenFree() - <li> Cudd_IsGenEmpty() - <li> Cudd_IndicesToCube() - <li> Cudd_PrintVersion() - <li> Cudd_AverageDistance() - <li> Cudd_Random() - <li> Cudd_Srandom() - <li> Cudd_Density() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddP() - <li> cuddStCountfree() - <li> cuddCollectNodes() - <li> cuddNodeArray() - </ul> - Static procedures included in this module: - <ul> - <li> dp2() - <li> ddPrintMintermAux() - <li> ddDagInt() - <li> ddCountMintermAux() - <li> ddEpdCountMintermAux() - <li> ddCountPathAux() - <li> ddSupportStep() - <li> ddClearFlag() - <li> ddLeavesInt() - <li> ddPickArbitraryMinterms() - <li> ddPickRepresentativeCube() - <li> ddEpdFree() - <li> ddFindSupport() - <li> ddClearVars() - <li> indexCompare() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_PrintMinterm" TARGET="MAIN"><CODE>Cudd_PrintMinterm()</CODE></A> - <DD> Prints a disjoint sum of products. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddPrintCover" TARGET="MAIN"><CODE>Cudd_bddPrintCover()</CODE></A> - <DD> Prints a sum of prime implicants of a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_PrintDebug" TARGET="MAIN"><CODE>Cudd_PrintDebug()</CODE></A> - <DD> Prints to the standard output a DD and its statistics. - - <DT> <A HREF="cuddAllDet.html#Cudd_DagSize" TARGET="MAIN"><CODE>Cudd_DagSize()</CODE></A> - <DD> Counts the number of nodes in a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_EstimateCofactor" TARGET="MAIN"><CODE>Cudd_EstimateCofactor()</CODE></A> - <DD> Estimates the number of nodes in a cofactor of a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_EstimateCofactorSimple" TARGET="MAIN"><CODE>Cudd_EstimateCofactorSimple()</CODE></A> - <DD> Estimates the number of nodes in a cofactor of a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_SharingSize" TARGET="MAIN"><CODE>Cudd_SharingSize()</CODE></A> - <DD> Counts the number of nodes in an array of DDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_CountMinterm" TARGET="MAIN"><CODE>Cudd_CountMinterm()</CODE></A> - <DD> Counts the number of minterms of a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_CountPath" TARGET="MAIN"><CODE>Cudd_CountPath()</CODE></A> - <DD> Counts the number of paths of a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_EpdCountMinterm" TARGET="MAIN"><CODE>Cudd_EpdCountMinterm()</CODE></A> - <DD> Counts the number of minterms of a DD with extended precision. - - <DT> <A HREF="cuddAllDet.html#Cudd_CountPathsToNonZero" TARGET="MAIN"><CODE>Cudd_CountPathsToNonZero()</CODE></A> - <DD> Counts the number of paths to a non-zero terminal of a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_SupportIndices" TARGET="MAIN"><CODE>Cudd_SupportIndices()</CODE></A> - <DD> Finds the variables on which a DD depends. - - <DT> <A HREF="cuddAllDet.html#Cudd_Support" TARGET="MAIN"><CODE>Cudd_Support()</CODE></A> - <DD> Finds the variables on which a DD depends. - - <DT> <A HREF="cuddAllDet.html#Cudd_SupportIndex" TARGET="MAIN"><CODE>Cudd_SupportIndex()</CODE></A> - <DD> Finds the variables on which a DD depends. - - <DT> <A HREF="cuddAllDet.html#Cudd_SupportSize" TARGET="MAIN"><CODE>Cudd_SupportSize()</CODE></A> - <DD> Counts the variables on which a DD depends. - - <DT> <A HREF="cuddAllDet.html#Cudd_VectorSupportIndices" TARGET="MAIN"><CODE>Cudd_VectorSupportIndices()</CODE></A> - <DD> Finds the variables on which a set of DDs depends. - - <DT> <A HREF="cuddAllDet.html#Cudd_VectorSupport" TARGET="MAIN"><CODE>Cudd_VectorSupport()</CODE></A> - <DD> Finds the variables on which a set of DDs depends. - - <DT> <A HREF="cuddAllDet.html#Cudd_VectorSupportIndex" TARGET="MAIN"><CODE>Cudd_VectorSupportIndex()</CODE></A> - <DD> Finds the variables on which a set of DDs depends. - - <DT> <A HREF="cuddAllDet.html#Cudd_VectorSupportSize" TARGET="MAIN"><CODE>Cudd_VectorSupportSize()</CODE></A> - <DD> Counts the variables on which a set of DDs depends. - - <DT> <A HREF="cuddAllDet.html#Cudd_ClassifySupport" TARGET="MAIN"><CODE>Cudd_ClassifySupport()</CODE></A> - <DD> Classifies the variables in the support of two DDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_CountLeaves" TARGET="MAIN"><CODE>Cudd_CountLeaves()</CODE></A> - <DD> Counts the number of leaves in a DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddPickOneCube" TARGET="MAIN"><CODE>Cudd_bddPickOneCube()</CODE></A> - <DD> Picks one on-set cube randomly from the given DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddPickOneMinterm" TARGET="MAIN"><CODE>Cudd_bddPickOneMinterm()</CODE></A> - <DD> Picks one on-set minterm randomly from the given DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddPickArbitraryMinterms" TARGET="MAIN"><CODE>Cudd_bddPickArbitraryMinterms()</CODE></A> - <DD> Picks k on-set minterms evenly distributed from given DD. - - <DT> <A HREF="cuddAllDet.html#Cudd_SubsetWithMaskVars" TARGET="MAIN"><CODE>Cudd_SubsetWithMaskVars()</CODE></A> - <DD> Extracts a subset from a BDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_FirstCube" TARGET="MAIN"><CODE>Cudd_FirstCube()</CODE></A> - <DD> Finds the first cube of a decision diagram. - - <DT> <A HREF="cuddAllDet.html#Cudd_NextCube" TARGET="MAIN"><CODE>Cudd_NextCube()</CODE></A> - <DD> Generates the next cube of a decision diagram onset. - - <DT> <A HREF="cuddAllDet.html#Cudd_FirstPrime" TARGET="MAIN"><CODE>Cudd_FirstPrime()</CODE></A> - <DD> Finds the first prime of a Boolean function. - - <DT> <A HREF="cuddAllDet.html#Cudd_NextPrime" TARGET="MAIN"><CODE>Cudd_NextPrime()</CODE></A> - <DD> Generates the next prime of a Boolean function. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddComputeCube" TARGET="MAIN"><CODE>Cudd_bddComputeCube()</CODE></A> - <DD> Computes the cube of an array of BDD variables. - - <DT> <A HREF="cuddAllDet.html#Cudd_addComputeCube" TARGET="MAIN"><CODE>Cudd_addComputeCube()</CODE></A> - <DD> Computes the cube of an array of ADD variables. - - <DT> <A HREF="cuddAllDet.html#Cudd_CubeArrayToBdd" TARGET="MAIN"><CODE>Cudd_CubeArrayToBdd()</CODE></A> - <DD> Builds the BDD of a cube from a positional array. - - <DT> <A HREF="cuddAllDet.html#Cudd_BddToCubeArray" TARGET="MAIN"><CODE>Cudd_BddToCubeArray()</CODE></A> - <DD> Builds a positional array from the BDD of a cube. - - <DT> <A HREF="cuddAllDet.html#Cudd_FirstNode" TARGET="MAIN"><CODE>Cudd_FirstNode()</CODE></A> - <DD> Finds the first node of a decision diagram. - - <DT> <A HREF="cuddAllDet.html#Cudd_NextNode" TARGET="MAIN"><CODE>Cudd_NextNode()</CODE></A> - <DD> Finds the next node of a decision diagram. - - <DT> <A HREF="cuddAllDet.html#Cudd_GenFree" TARGET="MAIN"><CODE>Cudd_GenFree()</CODE></A> - <DD> Frees a CUDD generator. - - <DT> <A HREF="cuddAllDet.html#Cudd_IsGenEmpty" TARGET="MAIN"><CODE>Cudd_IsGenEmpty()</CODE></A> - <DD> Queries the status of a generator. - - <DT> <A HREF="cuddAllDet.html#Cudd_IndicesToCube" TARGET="MAIN"><CODE>Cudd_IndicesToCube()</CODE></A> - <DD> Builds a cube of BDD variables from an array of indices. - - <DT> <A HREF="cuddAllDet.html#Cudd_PrintVersion" TARGET="MAIN"><CODE>Cudd_PrintVersion()</CODE></A> - <DD> Prints the package version number. - - <DT> <A HREF="cuddAllDet.html#Cudd_AverageDistance" TARGET="MAIN"><CODE>Cudd_AverageDistance()</CODE></A> - <DD> Computes the average distance between adjacent nodes. - - <DT> <A HREF="cuddAllDet.html#Cudd_Random" TARGET="MAIN"><CODE>Cudd_Random()</CODE></A> - <DD> Portable random number generator. - - <DT> <A HREF="cuddAllDet.html#Cudd_Srandom" TARGET="MAIN"><CODE>Cudd_Srandom()</CODE></A> - <DD> Initializer for the portable random number generator. - - <DT> <A HREF="cuddAllDet.html#Cudd_Density" TARGET="MAIN"><CODE>Cudd_Density()</CODE></A> - <DD> Computes the density of a BDD or ADD. - - <DT> <A HREF="cuddAllDet.html#Cudd_OutOfMem" TARGET="MAIN"><CODE>Cudd_OutOfMem()</CODE></A> - <DD> Warns that a memory allocation failed. - - <DT> <A HREF="cuddAllDet.html#cuddP" TARGET="MAIN"><CODE>cuddP()</CODE></A> - <DD> Prints a DD to the standard output. One line per node is - printed. - - <DT> <A HREF="cuddAllDet.html#cuddStCountfree" TARGET="MAIN"><CODE>cuddStCountfree()</CODE></A> - <DD> Frees the memory used to store the minterm counts recorded - in the visited table. - - <DT> <A HREF="cuddAllDet.html#cuddCollectNodes" TARGET="MAIN"><CODE>cuddCollectNodes()</CODE></A> - <DD> Recursively collects all the nodes of a DD in a symbol - table. - - <DT> <A HREF="cuddAllDet.html#cuddNodeArray" TARGET="MAIN"><CODE>cuddNodeArray()</CODE></A> - <DD> Recursively collects all the nodes of a DD in an array. - - <DT> <A HREF="cuddAllDet.html#dp2" TARGET="MAIN"><CODE>dp2()</CODE></A> - <DD> Performs the recursive step of cuddP. - - <DT> <A HREF="cuddAllDet.html#ddPrintMintermAux" TARGET="MAIN"><CODE>ddPrintMintermAux()</CODE></A> - <DD> Performs the recursive step of Cudd_PrintMinterm. - - <DT> <A HREF="cuddAllDet.html#ddDagInt" TARGET="MAIN"><CODE>ddDagInt()</CODE></A> - <DD> Performs the recursive step of Cudd_DagSize. - - <DT> <A HREF="cuddAllDet.html#cuddNodeArrayRecur" TARGET="MAIN"><CODE>cuddNodeArrayRecur()</CODE></A> - <DD> Performs the recursive step of cuddNodeArray. - - <DT> <A HREF="cuddAllDet.html#cuddEstimateCofactor" TARGET="MAIN"><CODE>cuddEstimateCofactor()</CODE></A> - <DD> Performs the recursive step of Cudd_CofactorEstimate. - - <DT> <A HREF="cuddAllDet.html#cuddUniqueLookup" TARGET="MAIN"><CODE>cuddUniqueLookup()</CODE></A> - <DD> Checks the unique table for the existence of an internal node. - - <DT> <A HREF="cuddAllDet.html#cuddEstimateCofactorSimple" TARGET="MAIN"><CODE>cuddEstimateCofactorSimple()</CODE></A> - <DD> Performs the recursive step of Cudd_CofactorEstimateSimple. - - <DT> <A HREF="cuddAllDet.html#ddCountMintermAux" TARGET="MAIN"><CODE>ddCountMintermAux()</CODE></A> - <DD> Performs the recursive step of Cudd_CountMinterm. - - <DT> <A HREF="cuddAllDet.html#ddCountPathAux" TARGET="MAIN"><CODE>ddCountPathAux()</CODE></A> - <DD> Performs the recursive step of Cudd_CountPath. - - <DT> <A HREF="cuddAllDet.html#ddEpdCountMintermAux" TARGET="MAIN"><CODE>ddEpdCountMintermAux()</CODE></A> - <DD> Performs the recursive step of Cudd_EpdCountMinterm. - - <DT> <A HREF="cuddAllDet.html#ddCountPathsToNonZero" TARGET="MAIN"><CODE>ddCountPathsToNonZero()</CODE></A> - <DD> Performs the recursive step of Cudd_CountPathsToNonZero. - - <DT> <A HREF="cuddAllDet.html#ddSupportStep" TARGET="MAIN"><CODE>ddSupportStep()</CODE></A> - <DD> Performs the recursive step of Cudd_Support. - - <DT> <A HREF="cuddAllDet.html#ddClearFlag" TARGET="MAIN"><CODE>ddClearFlag()</CODE></A> - <DD> Performs a DFS from f, clearing the LSB of the next - pointers. - - <DT> <A HREF="cuddAllDet.html#ddLeavesInt" TARGET="MAIN"><CODE>ddLeavesInt()</CODE></A> - <DD> Performs the recursive step of Cudd_CountLeaves. - - <DT> <A HREF="cuddAllDet.html#ddPickArbitraryMinterms" TARGET="MAIN"><CODE>ddPickArbitraryMinterms()</CODE></A> - <DD> Performs the recursive step of Cudd_bddPickArbitraryMinterms. - - <DT> <A HREF="cuddAllDet.html#ddPickRepresentativeCube" TARGET="MAIN"><CODE>ddPickRepresentativeCube()</CODE></A> - <DD> Finds a representative cube of a BDD. - - <DT> <A HREF="cuddAllDet.html#ddEpdFree" TARGET="MAIN"><CODE>ddEpdFree()</CODE></A> - <DD> Frees the memory used to store the minterm counts recorded - in the visited table. - - <DT> <A HREF="cuddAllDet.html#ddFindSupport" TARGET="MAIN"><CODE>ddFindSupport()</CODE></A> - <DD> Recursively find the support of f. - - <DT> <A HREF="cuddAllDet.html#ddClearVars" TARGET="MAIN"><CODE>ddClearVars()</CODE></A> - <DD> Clears visited flags for variables. - - <DT> <A HREF="cuddAllDet.html#indexCompare" TARGET="MAIN"><CODE>indexCompare()</CODE></A> - <DD> Compares indices for qsort. - -</DL> -<HR> -<A NAME="cuddWindow.c"><H1>cuddWindow.c</H1></A> -Functions for variable reordering by window permutation. <P> -<B>By: Fabio Somenzi</B><P> -Internal procedures included in this module: - <ul> - <li> cuddWindowReorder() - </ul> - Static procedures included in this module: - <ul> - <li> ddWindow2() - <li> ddWindowConv2() - <li> ddPermuteWindow3() - <li> ddWindow3() - <li> ddWindowConv3() - <li> ddPermuteWindow4() - <li> ddWindow4() - <li> ddWindowConv4() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#cuddWindowReorder" TARGET="MAIN"><CODE>cuddWindowReorder()</CODE></A> - <DD> Reorders by applying the method of the sliding window. - - <DT> <A HREF="cuddAllDet.html#ddWindow2" TARGET="MAIN"><CODE>ddWindow2()</CODE></A> - <DD> Reorders by applying a sliding window of width 2. - - <DT> <A HREF="cuddAllDet.html#ddWindowConv2" TARGET="MAIN"><CODE>ddWindowConv2()</CODE></A> - <DD> Reorders by repeatedly applying a sliding window of width 2. - - <DT> <A HREF="cuddAllDet.html#ddPermuteWindow3" TARGET="MAIN"><CODE>ddPermuteWindow3()</CODE></A> - <DD> Tries all the permutations of the three variables between - x and x+2 and retains the best. - - <DT> <A HREF="cuddAllDet.html#ddWindow3" TARGET="MAIN"><CODE>ddWindow3()</CODE></A> - <DD> Reorders by applying a sliding window of width 3. - - <DT> <A HREF="cuddAllDet.html#ddWindowConv3" TARGET="MAIN"><CODE>ddWindowConv3()</CODE></A> - <DD> Reorders by repeatedly applying a sliding window of width 3. - - <DT> <A HREF="cuddAllDet.html#ddPermuteWindow4" TARGET="MAIN"><CODE>ddPermuteWindow4()</CODE></A> - <DD> Tries all the permutations of the four variables between w - and w+3 and retains the best. - - <DT> <A HREF="cuddAllDet.html#ddWindow4" TARGET="MAIN"><CODE>ddWindow4()</CODE></A> - <DD> Reorders by applying a sliding window of width 4. - - <DT> <A HREF="cuddAllDet.html#ddWindowConv4" TARGET="MAIN"><CODE>ddWindowConv4()</CODE></A> - <DD> Reorders by repeatedly applying a sliding window of width 4. - -</DL> -<HR> -<A NAME="cuddZddCount.c"><H1>cuddZddCount.c</H1></A> -Procedures to count the number of minterms of a ZDD. <P> -<B>By: Hyong-Kyoon Shin, In-Ho Moon</B><P> -External procedures included in this module: - <ul> - <li> Cudd_zddCount(); - <li> Cudd_zddCountDouble(); - </ul> - Internal procedures included in this module: - <ul> - </ul> - Static procedures included in this module: - <ul> - <li> cuddZddCountStep(); - <li> cuddZddCountDoubleStep(); - <li> st_zdd_count_dbl_free() - <li> st_zdd_countfree() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_zddCount" TARGET="MAIN"><CODE>Cudd_zddCount()</CODE></A> - <DD> Counts the number of minterms in a ZDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddCountDouble" TARGET="MAIN"><CODE>Cudd_zddCountDouble()</CODE></A> - <DD> Counts the number of minterms of a ZDD. - - <DT> <A HREF="cuddAllDet.html#cuddZddCountStep" TARGET="MAIN"><CODE>cuddZddCountStep()</CODE></A> - <DD> Performs the recursive step of Cudd_zddCount. - - <DT> <A HREF="cuddAllDet.html#cuddZddCountDoubleStep" TARGET="MAIN"><CODE>cuddZddCountDoubleStep()</CODE></A> - <DD> Performs the recursive step of Cudd_zddCountDouble. - - <DT> <A HREF="cuddAllDet.html#st_zdd_countfree" TARGET="MAIN"><CODE>st_zdd_countfree()</CODE></A> - <DD> Frees the memory associated with the computed table of - Cudd_zddCount. - - <DT> <A HREF="cuddAllDet.html#st_zdd_count_dbl_free" TARGET="MAIN"><CODE>st_zdd_count_dbl_free()</CODE></A> - <DD> Frees the memory associated with the computed table of - Cudd_zddCountDouble. - -</DL> -<HR> -<A NAME="cuddZddFuncs.c"><H1>cuddZddFuncs.c</H1></A> -Functions to manipulate covers represented as ZDDs. <P> -<B>By: In-Ho Moon</B><P> -External procedures included in this module: - <ul> - <li> Cudd_zddProduct(); - <li> Cudd_zddUnateProduct(); - <li> Cudd_zddWeakDiv(); - <li> Cudd_zddWeakDivF(); - <li> Cudd_zddDivide(); - <li> Cudd_zddDivideF(); - <li> Cudd_zddComplement(); - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddProduct(); - <li> cuddZddUnateProduct(); - <li> cuddZddWeakDiv(); - <li> cuddZddWeakDivF(); - <li> cuddZddDivide(); - <li> cuddZddDivideF(); - <li> cuddZddGetCofactors3() - <li> cuddZddGetCofactors2() - <li> cuddZddComplement(); - <li> cuddZddGetPosVarIndex(); - <li> cuddZddGetNegVarIndex(); - <li> cuddZddGetPosVarLevel(); - <li> cuddZddGetNegVarLevel(); - </ul> - Static procedures included in this module: - <ul> - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_zddProduct" TARGET="MAIN"><CODE>Cudd_zddProduct()</CODE></A> - <DD> Computes the product of two covers represented by ZDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddUnateProduct" TARGET="MAIN"><CODE>Cudd_zddUnateProduct()</CODE></A> - <DD> Computes the product of two unate covers. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddWeakDiv" TARGET="MAIN"><CODE>Cudd_zddWeakDiv()</CODE></A> - <DD> Applies weak division to two covers. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddDivide" TARGET="MAIN"><CODE>Cudd_zddDivide()</CODE></A> - <DD> Computes the quotient of two unate covers. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddWeakDivF" TARGET="MAIN"><CODE>Cudd_zddWeakDivF()</CODE></A> - <DD> Modified version of Cudd_zddWeakDiv. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddDivideF" TARGET="MAIN"><CODE>Cudd_zddDivideF()</CODE></A> - <DD> Modified version of Cudd_zddDivide. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddComplement" TARGET="MAIN"><CODE>Cudd_zddComplement()</CODE></A> - <DD> Computes a complement cover for a ZDD node. - - <DT> <A HREF="cuddAllDet.html#cuddZddProduct" TARGET="MAIN"><CODE>cuddZddProduct()</CODE></A> - <DD> Performs the recursive step of Cudd_zddProduct. - - <DT> <A HREF="cuddAllDet.html#cuddZddUnateProduct" TARGET="MAIN"><CODE>cuddZddUnateProduct()</CODE></A> - <DD> Performs the recursive step of Cudd_zddUnateProduct. - - <DT> <A HREF="cuddAllDet.html#cuddZddWeakDiv" TARGET="MAIN"><CODE>cuddZddWeakDiv()</CODE></A> - <DD> Performs the recursive step of Cudd_zddWeakDiv. - - <DT> <A HREF="cuddAllDet.html#cuddZddWeakDivF" TARGET="MAIN"><CODE>cuddZddWeakDivF()</CODE></A> - <DD> Performs the recursive step of Cudd_zddWeakDivF. - - <DT> <A HREF="cuddAllDet.html#cuddZddDivide" TARGET="MAIN"><CODE>cuddZddDivide()</CODE></A> - <DD> Performs the recursive step of Cudd_zddDivide. - - <DT> <A HREF="cuddAllDet.html#cuddZddDivideF" TARGET="MAIN"><CODE>cuddZddDivideF()</CODE></A> - <DD> Performs the recursive step of Cudd_zddDivideF. - - <DT> <A HREF="cuddAllDet.html#cuddZddGetCofactors3" TARGET="MAIN"><CODE>cuddZddGetCofactors3()</CODE></A> - <DD> Computes the three-way decomposition of f w.r.t. v. - - <DT> <A HREF="cuddAllDet.html#cuddZddGetCofactors2" TARGET="MAIN"><CODE>cuddZddGetCofactors2()</CODE></A> - <DD> Computes the two-way decomposition of f w.r.t. v. - - <DT> <A HREF="cuddAllDet.html#cuddZddComplement" TARGET="MAIN"><CODE>cuddZddComplement()</CODE></A> - <DD> Computes a complement of a ZDD node. - - <DT> <A HREF="cuddAllDet.html#cuddZddGetPosVarIndex" TARGET="MAIN"><CODE>cuddZddGetPosVarIndex()</CODE></A> - <DD> Returns the index of positive ZDD variable. - - <DT> <A HREF="cuddAllDet.html#cuddZddGetNegVarIndex" TARGET="MAIN"><CODE>cuddZddGetNegVarIndex()</CODE></A> - <DD> Returns the index of negative ZDD variable. - - <DT> <A HREF="cuddAllDet.html#cuddZddGetPosVarLevel" TARGET="MAIN"><CODE>cuddZddGetPosVarLevel()</CODE></A> - <DD> Returns the level of positive ZDD variable. - - <DT> <A HREF="cuddAllDet.html#cuddZddGetNegVarLevel" TARGET="MAIN"><CODE>cuddZddGetNegVarLevel()</CODE></A> - <DD> Returns the level of negative ZDD variable. - -</DL> -<HR> -<A NAME="cuddZddGroup.c"><H1>cuddZddGroup.c</H1></A> -Functions for ZDD group sifting. <P> -<B>By: Fabio Somenzi</B><P> -External procedures included in this file: - <ul> - <li> Cudd_MakeZddTreeNode() - </ul> - Internal procedures included in this file: - <ul> - <li> cuddZddTreeSifting() - </ul> - Static procedures included in this module: - <ul> - <li> zddTreeSiftingAux() - <li> zddCountInternalMtrNodes() - <li> zddReorderChildren() - <li> zddFindNodeHiLo() - <li> zddUniqueCompareGroup() - <li> zddGroupSifting() - <li> zddGroupSiftingAux() - <li> zddGroupSiftingUp() - <li> zddGroupSiftingDown() - <li> zddGroupMove() - <li> zddGroupMoveBackward() - <li> zddGroupSiftingBackward() - <li> zddMergeGroups() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_MakeZddTreeNode" TARGET="MAIN"><CODE>Cudd_MakeZddTreeNode()</CODE></A> - <DD> Creates a new ZDD variable group. - - <DT> <A HREF="cuddAllDet.html#cuddZddTreeSifting" TARGET="MAIN"><CODE>cuddZddTreeSifting()</CODE></A> - <DD> Tree sifting algorithm for ZDDs. - - <DT> <A HREF="cuddAllDet.html#zddTreeSiftingAux" TARGET="MAIN"><CODE>zddTreeSiftingAux()</CODE></A> - <DD> Visits the group tree and reorders each group. - - <DT> <A HREF="cuddAllDet.html#zddCountInternalMtrNodes" TARGET="MAIN"><CODE>zddCountInternalMtrNodes()</CODE></A> - <DD> Counts the number of internal nodes of the group tree. - - <DT> <A HREF="cuddAllDet.html#zddReorderChildren" TARGET="MAIN"><CODE>zddReorderChildren()</CODE></A> - <DD> Reorders the children of a group tree node according to - the options. - - <DT> <A HREF="cuddAllDet.html#zddFindNodeHiLo" TARGET="MAIN"><CODE>zddFindNodeHiLo()</CODE></A> - <DD> Finds the lower and upper bounds of the group represented - by treenode. - - <DT> <A HREF="cuddAllDet.html#zddUniqueCompareGroup" TARGET="MAIN"><CODE>zddUniqueCompareGroup()</CODE></A> - <DD> Comparison function used by qsort. - - <DT> <A HREF="cuddAllDet.html#zddGroupSifting" TARGET="MAIN"><CODE>zddGroupSifting()</CODE></A> - <DD> Sifts from treenode->low to treenode->high. - - <DT> <A HREF="cuddAllDet.html#zddGroupSiftingAux" TARGET="MAIN"><CODE>zddGroupSiftingAux()</CODE></A> - <DD> Sifts one variable up and down until it has taken all - positions. Checks for aggregation. - - <DT> <A HREF="cuddAllDet.html#zddGroupSiftingUp" TARGET="MAIN"><CODE>zddGroupSiftingUp()</CODE></A> - <DD> Sifts up a variable until either it reaches position xLow - or the size of the DD heap increases too much. - - <DT> <A HREF="cuddAllDet.html#zddGroupSiftingDown" TARGET="MAIN"><CODE>zddGroupSiftingDown()</CODE></A> - <DD> Sifts down a variable until it reaches position xHigh. - - <DT> <A HREF="cuddAllDet.html#zddGroupMove" TARGET="MAIN"><CODE>zddGroupMove()</CODE></A> - <DD> Swaps two groups and records the move. - - <DT> <A HREF="cuddAllDet.html#zddGroupMoveBackward" TARGET="MAIN"><CODE>zddGroupMoveBackward()</CODE></A> - <DD> Undoes the swap two groups. - - <DT> <A HREF="cuddAllDet.html#zddGroupSiftingBackward" TARGET="MAIN"><CODE>zddGroupSiftingBackward()</CODE></A> - <DD> Determines the best position for a variables and returns - it there. - - <DT> <A HREF="cuddAllDet.html#zddMergeGroups" TARGET="MAIN"><CODE>zddMergeGroups()</CODE></A> - <DD> Merges groups in the DD table. - -</DL> -<HR> -<A NAME="cuddZddIsop.c"><H1>cuddZddIsop.c</H1></A> -Functions to find irredundant SOP covers as ZDDs from BDDs. <P> -<B>By: In-Ho Moon</B><P> -External procedures included in this module: - <ul> - <li> Cudd_bddIsop() - <li> Cudd_zddIsop() - <li> Cudd_MakeBddFromZddCover() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddIsop() - <li> cuddZddIsop() - <li> cuddMakeBddFromZddCover() - </ul> - Static procedures included in this module: - <ul> - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_zddIsop" TARGET="MAIN"><CODE>Cudd_zddIsop()</CODE></A> - <DD> Computes an ISOP in ZDD form from BDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_bddIsop" TARGET="MAIN"><CODE>Cudd_bddIsop()</CODE></A> - <DD> Computes a BDD in the interval between L and U with a - simple sum-of-product cover. - - <DT> <A HREF="cuddAllDet.html#Cudd_MakeBddFromZddCover" TARGET="MAIN"><CODE>Cudd_MakeBddFromZddCover()</CODE></A> - <DD> Converts a ZDD cover to a BDD. - - <DT> <A HREF="cuddAllDet.html#cuddZddIsop" TARGET="MAIN"><CODE>cuddZddIsop()</CODE></A> - <DD> Performs the recursive step of Cudd_zddIsop. - - <DT> <A HREF="cuddAllDet.html#cuddBddIsop" TARGET="MAIN"><CODE>cuddBddIsop()</CODE></A> - <DD> Performs the recursive step of Cudd_bddIsop. - - <DT> <A HREF="cuddAllDet.html#cuddMakeBddFromZddCover" TARGET="MAIN"><CODE>cuddMakeBddFromZddCover()</CODE></A> - <DD> Converts a ZDD cover to a BDD. - -</DL> -<HR> -<A NAME="cuddZddLin.c"><H1>cuddZddLin.c</H1></A> -Procedures for dynamic variable ordering of ZDDs. <P> -<B>By: Fabio Somenzi</B><P> -Internal procedures included in this module: - <ul> - <li> cuddZddLinearSifting() - </ul> - Static procedures included in this module: - <ul> - <li> cuddZddLinearInPlace() - <li> cuddZddLinerAux() - <li> cuddZddLinearUp() - <li> cuddZddLinearDown() - <li> cuddZddLinearBackward() - <li> cuddZddUndoMoves() - </ul> <P> -<P><B>See Also</B><A HREF="#cuddLinear.c"><CODE>cuddLinear.c</CODE></A> -<A HREF="#cuddZddReord.c"><CODE>cuddZddReord.c</CODE></A> -<DL> - <DT> <A HREF="cuddAllDet.html#cuddZddLinearSifting" TARGET="MAIN"><CODE>cuddZddLinearSifting()</CODE></A> - <DD> Implementation of the linear sifting algorithm for ZDDs. - - <DT> <A HREF="cuddAllDet.html#cuddZddLinearInPlace" TARGET="MAIN"><CODE>cuddZddLinearInPlace()</CODE></A> - <DD> Linearly combines two adjacent variables. - - <DT> <A HREF="cuddAllDet.html#cuddZddLinearAux" TARGET="MAIN"><CODE>cuddZddLinearAux()</CODE></A> - <DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - - <DT> <A HREF="cuddAllDet.html#cuddZddLinearUp" TARGET="MAIN"><CODE>cuddZddLinearUp()</CODE></A> - <DD> Sifts a variable up applying the XOR transformation. - - <DT> <A HREF="cuddAllDet.html#cuddZddLinearDown" TARGET="MAIN"><CODE>cuddZddLinearDown()</CODE></A> - <DD> Sifts a variable down and applies the XOR transformation. - - <DT> <A HREF="cuddAllDet.html#cuddZddLinearBackward" TARGET="MAIN"><CODE>cuddZddLinearBackward()</CODE></A> - <DD> Given a set of moves, returns the ZDD heap to the position - giving the minimum size. - - <DT> <A HREF="cuddAllDet.html#cuddZddUndoMoves" TARGET="MAIN"><CODE>cuddZddUndoMoves()</CODE></A> - <DD> Given a set of moves, returns the ZDD heap to the order - in effect before the moves. - -</DL> -<HR> -<A NAME="cuddZddMisc.c"><H1>cuddZddMisc.c</H1></A> -Miscellaneous utility functions for ZDDs. <P> -<B>By: Hyong-Kyoon Shin, In-Ho Moon</B><P> -External procedures included in this module: - <ul> - <li> Cudd_zddDagSize() - <li> Cudd_zddCountMinterm() - <li> Cudd_zddPrintSubtable() - </ul> - Internal procedures included in this module: - <ul> - </ul> - Static procedures included in this module: - <ul> - <li> cuddZddDagInt() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_zddDagSize" TARGET="MAIN"><CODE>Cudd_zddDagSize()</CODE></A> - <DD> Counts the number of nodes in a ZDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddCountMinterm" TARGET="MAIN"><CODE>Cudd_zddCountMinterm()</CODE></A> - <DD> Counts the number of minterms of a ZDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddPrintSubtable" TARGET="MAIN"><CODE>Cudd_zddPrintSubtable()</CODE></A> - <DD> Prints the ZDD table. - - <DT> <A HREF="cuddAllDet.html#cuddZddDagInt" TARGET="MAIN"><CODE>cuddZddDagInt()</CODE></A> - <DD> Performs the recursive step of Cudd_zddDagSize. - -</DL> -<HR> -<A NAME="cuddZddPort.c"><H1>cuddZddPort.c</H1></A> -Functions that translate BDDs to ZDDs. <P> -<B>By: Hyong-kyoon Shin, In-Ho Moon</B><P> -External procedures included in this module: - <ul> - <li> Cudd_zddPortFromBdd() - <li> Cudd_zddPortToBdd() - </ul> - Internal procedures included in this module: - <ul> - </ul> - Static procedures included in this module: - <ul> - <li> zddPortFromBddStep() - <li> zddPortToBddStep() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_zddPortFromBdd" TARGET="MAIN"><CODE>Cudd_zddPortFromBdd()</CODE></A> - <DD> Converts a BDD into a ZDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddPortToBdd" TARGET="MAIN"><CODE>Cudd_zddPortToBdd()</CODE></A> - <DD> Converts a ZDD into a BDD. - - <DT> <A HREF="cuddAllDet.html#zddPortFromBddStep" TARGET="MAIN"><CODE>zddPortFromBddStep()</CODE></A> - <DD> Performs the recursive step of Cudd_zddPortFromBdd. - - <DT> <A HREF="cuddAllDet.html#zddPortToBddStep" TARGET="MAIN"><CODE>zddPortToBddStep()</CODE></A> - <DD> Performs the recursive step of Cudd_zddPortToBdd. - -</DL> -<HR> -<A NAME="cuddZddReord.c"><H1>cuddZddReord.c</H1></A> -Procedures for dynamic variable ordering of ZDDs. <P> -<B>By: Hyong-Kyoon Shin, In-Ho Moon</B><P> -External procedures included in this module: - <ul> - <li> Cudd_zddReduceHeap() - <li> Cudd_zddShuffleHeap() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddAlignToBdd() - <li> cuddZddNextHigh() - <li> cuddZddNextLow() - <li> cuddZddUniqueCompare() - <li> cuddZddSwapInPlace() - <li> cuddZddSwapping() - <li> cuddZddSifting() - </ul> - Static procedures included in this module: - <ul> - <li> zddSwapAny() - <li> cuddZddSiftingAux() - <li> cuddZddSiftingUp() - <li> cuddZddSiftingDown() - <li> cuddZddSiftingBackward() - <li> zddReorderPreprocess() - <li> zddReorderPostprocess() - <li> zddShuffle() - <li> zddSiftUp() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_zddReduceHeap" TARGET="MAIN"><CODE>Cudd_zddReduceHeap()</CODE></A> - <DD> Main dynamic reordering routine for ZDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddShuffleHeap" TARGET="MAIN"><CODE>Cudd_zddShuffleHeap()</CODE></A> - <DD> Reorders ZDD variables according to given permutation. - - <DT> <A HREF="cuddAllDet.html#cuddZddAlignToBdd" TARGET="MAIN"><CODE>cuddZddAlignToBdd()</CODE></A> - <DD> Reorders ZDD variables according to the order of the BDD - variables. - - <DT> <A HREF="cuddAllDet.html#cuddZddNextHigh" TARGET="MAIN"><CODE>cuddZddNextHigh()</CODE></A> - <DD> Finds the next subtable with a larger index. - - <DT> <A HREF="cuddAllDet.html#cuddZddNextLow" TARGET="MAIN"><CODE>cuddZddNextLow()</CODE></A> - <DD> Finds the next subtable with a smaller index. - - <DT> <A HREF="cuddAllDet.html#cuddZddUniqueCompare" TARGET="MAIN"><CODE>cuddZddUniqueCompare()</CODE></A> - <DD> Comparison function used by qsort. - - <DT> <A HREF="cuddAllDet.html#cuddZddSwapInPlace" TARGET="MAIN"><CODE>cuddZddSwapInPlace()</CODE></A> - <DD> Swaps two adjacent variables. - - <DT> <A HREF="cuddAllDet.html#cuddZddSwapping" TARGET="MAIN"><CODE>cuddZddSwapping()</CODE></A> - <DD> Reorders variables by a sequence of (non-adjacent) swaps. - - <DT> <A HREF="cuddAllDet.html#cuddZddSifting" TARGET="MAIN"><CODE>cuddZddSifting()</CODE></A> - <DD> Implementation of Rudell's sifting algorithm. - - <DT> <A HREF="cuddAllDet.html#zddSwapAny" TARGET="MAIN"><CODE>zddSwapAny()</CODE></A> - <DD> Swaps any two variables. - - <DT> <A HREF="cuddAllDet.html#cuddZddSiftingAux" TARGET="MAIN"><CODE>cuddZddSiftingAux()</CODE></A> - <DD> Given xLow <= x <= xHigh moves x up and down between the - boundaries. - - <DT> <A HREF="cuddAllDet.html#cuddZddSiftingUp" TARGET="MAIN"><CODE>cuddZddSiftingUp()</CODE></A> - <DD> Sifts a variable up. - - <DT> <A HREF="cuddAllDet.html#cuddZddSiftingDown" TARGET="MAIN"><CODE>cuddZddSiftingDown()</CODE></A> - <DD> Sifts a variable down. - - <DT> <A HREF="cuddAllDet.html#cuddZddSiftingBackward" TARGET="MAIN"><CODE>cuddZddSiftingBackward()</CODE></A> - <DD> Given a set of moves, returns the ZDD heap to the position - giving the minimum size. - - <DT> <A HREF="cuddAllDet.html#zddReorderPreprocess" TARGET="MAIN"><CODE>zddReorderPreprocess()</CODE></A> - <DD> Prepares the ZDD heap for dynamic reordering. - - <DT> <A HREF="cuddAllDet.html#zddReorderPostprocess" TARGET="MAIN"><CODE>zddReorderPostprocess()</CODE></A> - <DD> Shrinks almost empty ZDD subtables at the end of reordering - to guarantee that they have a reasonable load factor. - - <DT> <A HREF="cuddAllDet.html#zddShuffle" TARGET="MAIN"><CODE>zddShuffle()</CODE></A> - <DD> Reorders ZDD variables according to a given permutation. - - <DT> <A HREF="cuddAllDet.html#zddSiftUp" TARGET="MAIN"><CODE>zddSiftUp()</CODE></A> - <DD> Moves one ZDD variable up. - - <DT> <A HREF="cuddAllDet.html#zddFixTree" TARGET="MAIN"><CODE>zddFixTree()</CODE></A> - <DD> Fixes the ZDD variable group tree after a shuffle. - -</DL> -<HR> -<A NAME="cuddZddSetop.c"><H1>cuddZddSetop.c</H1></A> -Set operations on ZDDs. <P> -<B>By: Hyong-Kyoon Shin, In-Ho Moon</B><P> -External procedures included in this module: - <ul> - <li> Cudd_zddIte() - <li> Cudd_zddUnion() - <li> Cudd_zddIntersect() - <li> Cudd_zddDiff() - <li> Cudd_zddDiffConst() - <li> Cudd_zddSubset1() - <li> Cudd_zddSubset0() - <li> Cudd_zddChange() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddIte() - <li> cuddZddUnion() - <li> cuddZddIntersect() - <li> cuddZddDiff() - <li> cuddZddChangeAux() - <li> cuddZddSubset1() - <li> cuddZddSubset0() - </ul> - Static procedures included in this module: - <ul> - <li> zdd_subset1_aux() - <li> zdd_subset0_aux() - <li> zddVarToConst() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_zddIte" TARGET="MAIN"><CODE>Cudd_zddIte()</CODE></A> - <DD> Computes the ITE of three ZDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddUnion" TARGET="MAIN"><CODE>Cudd_zddUnion()</CODE></A> - <DD> Computes the union of two ZDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddIntersect" TARGET="MAIN"><CODE>Cudd_zddIntersect()</CODE></A> - <DD> Computes the intersection of two ZDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddDiff" TARGET="MAIN"><CODE>Cudd_zddDiff()</CODE></A> - <DD> Computes the difference of two ZDDs. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddDiffConst" TARGET="MAIN"><CODE>Cudd_zddDiffConst()</CODE></A> - <DD> Performs the inclusion test for ZDDs (P implies Q). - - <DT> <A HREF="cuddAllDet.html#Cudd_zddSubset1" TARGET="MAIN"><CODE>Cudd_zddSubset1()</CODE></A> - <DD> Computes the positive cofactor of a ZDD w.r.t. a variable. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddSubset0" TARGET="MAIN"><CODE>Cudd_zddSubset0()</CODE></A> - <DD> Computes the negative cofactor of a ZDD w.r.t. a variable. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddChange" TARGET="MAIN"><CODE>Cudd_zddChange()</CODE></A> - <DD> Substitutes a variable with its complement in a ZDD. - - <DT> <A HREF="cuddAllDet.html#cuddZddIte" TARGET="MAIN"><CODE>cuddZddIte()</CODE></A> - <DD> Performs the recursive step of Cudd_zddIte. - - <DT> <A HREF="cuddAllDet.html#cuddZddUnion" TARGET="MAIN"><CODE>cuddZddUnion()</CODE></A> - <DD> Performs the recursive step of Cudd_zddUnion. - - <DT> <A HREF="cuddAllDet.html#cuddZddIntersect" TARGET="MAIN"><CODE>cuddZddIntersect()</CODE></A> - <DD> Performs the recursive step of Cudd_zddIntersect. - - <DT> <A HREF="cuddAllDet.html#cuddZddDiff" TARGET="MAIN"><CODE>cuddZddDiff()</CODE></A> - <DD> Performs the recursive step of Cudd_zddDiff. - - <DT> <A HREF="cuddAllDet.html#cuddZddChangeAux" TARGET="MAIN"><CODE>cuddZddChangeAux()</CODE></A> - <DD> Performs the recursive step of Cudd_zddChange. - - <DT> <A HREF="cuddAllDet.html#cuddZddSubset1" TARGET="MAIN"><CODE>cuddZddSubset1()</CODE></A> - <DD> Computes the positive cofactor of a ZDD w.r.t. a variable. - - <DT> <A HREF="cuddAllDet.html#cuddZddSubset0" TARGET="MAIN"><CODE>cuddZddSubset0()</CODE></A> - <DD> Computes the negative cofactor of a ZDD w.r.t. a variable. - - <DT> <A HREF="cuddAllDet.html#cuddZddChange" TARGET="MAIN"><CODE>cuddZddChange()</CODE></A> - <DD> Substitutes a variable with its complement in a ZDD. - - <DT> <A HREF="cuddAllDet.html#zdd_subset1_aux" TARGET="MAIN"><CODE>zdd_subset1_aux()</CODE></A> - <DD> Performs the recursive step of Cudd_zddSubset1. - - <DT> <A HREF="cuddAllDet.html#zdd_subset0_aux" TARGET="MAIN"><CODE>zdd_subset0_aux()</CODE></A> - <DD> Performs the recursive step of Cudd_zddSubset0. - - <DT> <A HREF="cuddAllDet.html#zddVarToConst" TARGET="MAIN"><CODE>zddVarToConst()</CODE></A> - <DD> Replaces variables with constants if possible (part of - canonical form). - -</DL> -<HR> -<A NAME="cuddZddSymm.c"><H1>cuddZddSymm.c</H1></A> -Functions for symmetry-based ZDD variable reordering. <P> -<B>By: Hyong-Kyoon Shin, In-Ho Moon</B><P> -External procedures included in this module: - <ul> - <li> Cudd_zddSymmProfile() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddSymmCheck() - <li> cuddZddSymmSifting() - <li> cuddZddSymmSiftingConv() - </ul> - Static procedures included in this module: - <ul> - <li> cuddZddUniqueCompare() - <li> cuddZddSymmSiftingAux() - <li> cuddZddSymmSiftingConvAux() - <li> cuddZddSymmSifting_up() - <li> cuddZddSymmSifting_down() - <li> zdd_group_move() - <li> cuddZddSymmSiftingBackward() - <li> zdd_group_move_backward() - </ul> <P> -<P><B>See Also</B><A HREF="#cuddSymmetry.c"><CODE>cuddSymmetry.c</CODE></A> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_zddSymmProfile" TARGET="MAIN"><CODE>Cudd_zddSymmProfile()</CODE></A> - <DD> Prints statistics on symmetric ZDD variables. - - <DT> <A HREF="cuddAllDet.html#cuddZddSymmCheck" TARGET="MAIN"><CODE>cuddZddSymmCheck()</CODE></A> - <DD> Checks for symmetry of x and y. - - <DT> <A HREF="cuddAllDet.html#cuddZddSymmSifting" TARGET="MAIN"><CODE>cuddZddSymmSifting()</CODE></A> - <DD> Symmetric sifting algorithm for ZDDs. - - <DT> <A HREF="cuddAllDet.html#cuddZddSymmSiftingConv" TARGET="MAIN"><CODE>cuddZddSymmSiftingConv()</CODE></A> - <DD> Symmetric sifting to convergence algorithm for ZDDs. - - <DT> <A HREF="cuddAllDet.html#cuddZddSymmSiftingAux" TARGET="MAIN"><CODE>cuddZddSymmSiftingAux()</CODE></A> - <DD> Given x_low <= x <= x_high moves x up and down between the - boundaries. - - <DT> <A HREF="cuddAllDet.html#cuddZddSymmSiftingConvAux" TARGET="MAIN"><CODE>cuddZddSymmSiftingConvAux()</CODE></A> - <DD> Given x_low <= x <= x_high moves x up and down between the - boundaries. - - <DT> <A HREF="cuddAllDet.html#cuddZddSymmSifting_up" TARGET="MAIN"><CODE>cuddZddSymmSifting_up()</CODE></A> - <DD> Moves x up until either it reaches the bound (x_low) or - the size of the ZDD heap increases too much. - - <DT> <A HREF="cuddAllDet.html#cuddZddSymmSifting_down" TARGET="MAIN"><CODE>cuddZddSymmSifting_down()</CODE></A> - <DD> Moves x down until either it reaches the bound (x_high) or - the size of the ZDD heap increases too much. - - <DT> <A HREF="cuddAllDet.html#cuddZddSymmSiftingBackward" TARGET="MAIN"><CODE>cuddZddSymmSiftingBackward()</CODE></A> - <DD> Given a set of moves, returns the ZDD heap to the position - giving the minimum size. - - <DT> <A HREF="cuddAllDet.html#zdd_group_move" TARGET="MAIN"><CODE>zdd_group_move()</CODE></A> - <DD> Swaps two groups. - - <DT> <A HREF="cuddAllDet.html#zdd_group_move_backward" TARGET="MAIN"><CODE>zdd_group_move_backward()</CODE></A> - <DD> Undoes the swap of two groups. - - <DT> <A HREF="cuddAllDet.html#cuddZddSymmSummary" TARGET="MAIN"><CODE>cuddZddSymmSummary()</CODE></A> - <DD> Counts numbers of symmetric variables and symmetry - groups. - -</DL> -<HR> -<A NAME="cuddZddUtil.c"><H1>cuddZddUtil.c</H1></A> -Utility functions for ZDDs. <P> -<B>By: Hyong-Kyoon Shin, In-Ho Moon, Fabio Somenzi</B><P> -External procedures included in this module: - <ul> - <li> Cudd_zddPrintMinterm() - <li> Cudd_zddPrintCover() - <li> Cudd_zddPrintDebug() - <li> Cudd_zddFirstPath() - <li> Cudd_zddNextPath() - <li> Cudd_zddCoverPathToString() - <li> Cudd_zddSupport() - <li> Cudd_zddDumpDot() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddP() - </ul> - Static procedures included in this module: - <ul> - <li> zp2() - <li> zdd_print_minterm_aux() - <li> zddPrintCoverAux() - <li> zddSupportStep() - <li> zddClearFlag() - </ul> <P> -<DL> - <DT> <A HREF="cuddAllDet.html#Cudd_zddPrintMinterm" TARGET="MAIN"><CODE>Cudd_zddPrintMinterm()</CODE></A> - <DD> Prints a disjoint sum of product form for a ZDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddPrintCover" TARGET="MAIN"><CODE>Cudd_zddPrintCover()</CODE></A> - <DD> Prints a sum of products from a ZDD representing a cover. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddPrintDebug" TARGET="MAIN"><CODE>Cudd_zddPrintDebug()</CODE></A> - <DD> Prints to the standard output a ZDD and its statistics. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddFirstPath" TARGET="MAIN"><CODE>Cudd_zddFirstPath()</CODE></A> - <DD> Finds the first path of a ZDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddNextPath" TARGET="MAIN"><CODE>Cudd_zddNextPath()</CODE></A> - <DD> Generates the next path of a ZDD. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddCoverPathToString" TARGET="MAIN"><CODE>Cudd_zddCoverPathToString()</CODE></A> - <DD> Converts a path of a ZDD representing a cover to a string. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddSupport" TARGET="MAIN"><CODE>Cudd_zddSupport()</CODE></A> - <DD> Finds the variables on which a ZDD depends. - - <DT> <A HREF="cuddAllDet.html#Cudd_zddDumpDot" TARGET="MAIN"><CODE>Cudd_zddDumpDot()</CODE></A> - <DD> Writes a dot file representing the argument ZDDs. - - <DT> <A HREF="cuddAllDet.html#cuddZddP" TARGET="MAIN"><CODE>cuddZddP()</CODE></A> - <DD> Prints a ZDD to the standard output. One line per node is - printed. - - <DT> <A HREF="cuddAllDet.html#zp2" TARGET="MAIN"><CODE>zp2()</CODE></A> - <DD> Performs the recursive step of cuddZddP. - - <DT> <A HREF="cuddAllDet.html#zdd_print_minterm_aux" TARGET="MAIN"><CODE>zdd_print_minterm_aux()</CODE></A> - <DD> Performs the recursive step of Cudd_zddPrintMinterm. - - <DT> <A HREF="cuddAllDet.html#zddPrintCoverAux" TARGET="MAIN"><CODE>zddPrintCoverAux()</CODE></A> - <DD> Performs the recursive step of Cudd_zddPrintCover. - - <DT> <A HREF="cuddAllDet.html#zddSupportStep" TARGET="MAIN"><CODE>zddSupportStep()</CODE></A> - <DD> Performs the recursive step of Cudd_zddSupport. - - <DT> <A HREF="cuddAllDet.html#zddClearFlag" TARGET="MAIN"><CODE>zddClearFlag()</CODE></A> - <DD> Performs a DFS from f, clearing the LSB of the next - pointers. - -</DL> -<HR> -Last updated on 20120204 17h33 -</BODY></HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddDesc.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddDesc.html deleted file mode 100644 index 5f27bf530..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddDesc.html +++ /dev/null @@ -1,33 +0,0 @@ -<HTML> -<HEAD><TITLE>The cudd package: Overview</TITLE></HEAD> -<BODY> - -<H1>The cudd package</H1> -<H2>The University of Colorado decision diagram package.</H2> -<H3>By Fabio Somenzi</H3> - -<UL> - <LI> <A HREF="cuddExt.html" TARGET="_top"> - Information for programmers</A> - <LI> <A HREF="cuddAllByFunc.html" TARGET="_top"> - Information for developers sorted by function</A> - <LI> <A HREF="cuddAllByFile.html" TARGET="_top"> - Information for developers sorted by file</A> -</UL> - -<HR> - -External functions and data strucures of the CUDD package. - <ul> - <li> To turn on the gathering of statistics, define DD_STATS. - <li> To link with mis, define DD_MIS. - </ul> - Modified by Abelardo Pardo to interface it to VIS. - -<HR> - -Last updated on 20120204 17h33 - -</BODY> -</HTML> -writing ./cuddExt.html diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddExt.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddExt.html deleted file mode 100644 index 24b63634a..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddExt.html +++ /dev/null @@ -1,14 +0,0 @@ -<HTML> -<HEAD><TITLE>The cudd Package for Programmers</TITLE></HEAD> - -<FRAMESET ROWS="5%,90%,5%"> - <FRAME SRC="cuddTitle.html"> - <FRAMESET COLS="40%,60%"> - <FRAME SRC="cuddExtAbs.html" NAME="ABSTRACT"> - <FRAME SRC="cuddExtDet.html" NAME="MAIN"> - </FRAMESET> - <FRAME SRC="credit.html"> -</FRAMESET> - -</HTML> -writing ./cuddAllByFunc.html diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddExtAbs.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddExtAbs.html deleted file mode 100644 index a476db7b1..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddExtAbs.html +++ /dev/null @@ -1,1415 +0,0 @@ -<html> -<head><title>cudd package abstract</title></head> -<body> - - -<!-- Function Abstracts --> - -<dl> -<dt> <a href="cuddAllDet.html#Cudd_AddHook" TARGET="MAIN"><code>Cudd_AddHook()</code></a> -<dd> Adds a function to a hook. - -<dt> <a href="cuddAllDet.html#Cudd_ApaAdd" TARGET="MAIN"><code>Cudd_ApaAdd()</code></a> -<dd> Adds two arbitrary precision integers. - -<dt> <a href="cuddAllDet.html#Cudd_ApaCompareRatios" TARGET="MAIN"><code>Cudd_ApaCompareRatios()</code></a> -<dd> Compares the ratios of two arbitrary precision integers to two - unsigned ints. - -<dt> <a href="cuddAllDet.html#Cudd_ApaCompare" TARGET="MAIN"><code>Cudd_ApaCompare()</code></a> -<dd> Compares two arbitrary precision integers. - -<dt> <a href="cuddAllDet.html#Cudd_ApaCopy" TARGET="MAIN"><code>Cudd_ApaCopy()</code></a> -<dd> Makes a copy of an arbitrary precision integer. - -<dt> <a href="cuddAllDet.html#Cudd_ApaCountMinterm" TARGET="MAIN"><code>Cudd_ApaCountMinterm()</code></a> -<dd> Counts the number of minterms of a DD. - -<dt> <a href="cuddAllDet.html#Cudd_ApaIntDivision" TARGET="MAIN"><code>Cudd_ApaIntDivision()</code></a> -<dd> Divides an arbitrary precision integer by an integer. - -<dt> <a href="cuddAllDet.html#Cudd_ApaNumberOfDigits" TARGET="MAIN"><code>Cudd_ApaNumberOfDigits()</code></a> -<dd> Finds the number of digits for an arbitrary precision - integer. - -<dt> <a href="cuddAllDet.html#Cudd_ApaPowerOfTwo" TARGET="MAIN"><code>Cudd_ApaPowerOfTwo()</code></a> -<dd> Sets an arbitrary precision integer to a power of two. - -<dt> <a href="cuddAllDet.html#Cudd_ApaPrintDecimal" TARGET="MAIN"><code>Cudd_ApaPrintDecimal()</code></a> -<dd> Prints an arbitrary precision integer in decimal format. - -<dt> <a href="cuddAllDet.html#Cudd_ApaPrintDensity" TARGET="MAIN"><code>Cudd_ApaPrintDensity()</code></a> -<dd> Prints the density of a BDD or ADD using - arbitrary precision arithmetic. - -<dt> <a href="cuddAllDet.html#Cudd_ApaPrintExponential" TARGET="MAIN"><code>Cudd_ApaPrintExponential()</code></a> -<dd> Prints an arbitrary precision integer in exponential format. - -<dt> <a href="cuddAllDet.html#Cudd_ApaPrintHex" TARGET="MAIN"><code>Cudd_ApaPrintHex()</code></a> -<dd> Prints an arbitrary precision integer in hexadecimal format. - -<dt> <a href="cuddAllDet.html#Cudd_ApaPrintMintermExp" TARGET="MAIN"><code>Cudd_ApaPrintMintermExp()</code></a> -<dd> Prints the number of minterms of a BDD or ADD in exponential - format using arbitrary precision arithmetic. - -<dt> <a href="cuddAllDet.html#Cudd_ApaPrintMinterm" TARGET="MAIN"><code>Cudd_ApaPrintMinterm()</code></a> -<dd> Prints the number of minterms of a BDD or ADD using - arbitrary precision arithmetic. - -<dt> <a href="cuddAllDet.html#Cudd_ApaSetToLiteral" TARGET="MAIN"><code>Cudd_ApaSetToLiteral()</code></a> -<dd> Sets an arbitrary precision integer to a one-digit literal. - -<dt> <a href="cuddAllDet.html#Cudd_ApaShiftRight" TARGET="MAIN"><code>Cudd_ApaShiftRight()</code></a> -<dd> Shifts right an arbitrary precision integer by one binary - place. - -<dt> <a href="cuddAllDet.html#Cudd_ApaShortDivision" TARGET="MAIN"><code>Cudd_ApaShortDivision()</code></a> -<dd> Divides an arbitrary precision integer by a digit. - -<dt> <a href="cuddAllDet.html#Cudd_ApaSubtract" TARGET="MAIN"><code>Cudd_ApaSubtract()</code></a> -<dd> Subtracts two arbitrary precision integers. - -<dt> <a href="cuddAllDet.html#Cudd_AutodynDisableZdd" TARGET="MAIN"><code>Cudd_AutodynDisableZdd()</code></a> -<dd> Disables automatic dynamic reordering of ZDDs. - -<dt> <a href="cuddAllDet.html#Cudd_AutodynDisable" TARGET="MAIN"><code>Cudd_AutodynDisable()</code></a> -<dd> Disables automatic dynamic reordering. - -<dt> <a href="cuddAllDet.html#Cudd_AutodynEnableZdd" TARGET="MAIN"><code>Cudd_AutodynEnableZdd()</code></a> -<dd> Enables automatic dynamic reordering of ZDDs. - -<dt> <a href="cuddAllDet.html#Cudd_AutodynEnable" TARGET="MAIN"><code>Cudd_AutodynEnable()</code></a> -<dd> Enables automatic dynamic reordering of BDDs and ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_AverageDistance" TARGET="MAIN"><code>Cudd_AverageDistance()</code></a> -<dd> Computes the average distance between adjacent nodes. - -<dt> <a href="cuddAllDet.html#Cudd_BddToAdd" TARGET="MAIN"><code>Cudd_BddToAdd()</code></a> -<dd> Converts a BDD to a 0-1 ADD. - -<dt> <a href="cuddAllDet.html#Cudd_BddToCubeArray" TARGET="MAIN"><code>Cudd_BddToCubeArray()</code></a> -<dd> Builds a positional array from the BDD of a cube. - -<dt> <a href="cuddAllDet.html#Cudd_BiasedOverApprox" TARGET="MAIN"><code>Cudd_BiasedOverApprox()</code></a> -<dd> Extracts a dense superset from a BDD with the biased - underapproximation method. - -<dt> <a href="cuddAllDet.html#Cudd_BiasedUnderApprox" TARGET="MAIN"><code>Cudd_BiasedUnderApprox()</code></a> -<dd> Extracts a dense subset from a BDD with the biased - underapproximation method. - -<dt> <a href="cuddAllDet.html#Cudd_CProjection" TARGET="MAIN"><code>Cudd_CProjection()</code></a> -<dd> Computes the compatible projection of R w.r.t. cube Y. - -<dt> <a href="cuddAllDet.html#Cudd_CheckCube" TARGET="MAIN"><code>Cudd_CheckCube()</code></a> -<dd> Checks whether g is the BDD of a cube. - -<dt> <a href="cuddAllDet.html#Cudd_CheckKeys" TARGET="MAIN"><code>Cudd_CheckKeys()</code></a> -<dd> Checks for several conditions that should not occur. - -<dt> <a href="cuddAllDet.html#Cudd_CheckZeroRef" TARGET="MAIN"><code>Cudd_CheckZeroRef()</code></a> -<dd> Checks the unique table for nodes with non-zero reference - counts. - -<dt> <a href="cuddAllDet.html#Cudd_ClassifySupport" TARGET="MAIN"><code>Cudd_ClassifySupport()</code></a> -<dd> Classifies the variables in the support of two DDs. - -<dt> <a href="cuddAllDet.html#Cudd_ClearErrorCode" TARGET="MAIN"><code>Cudd_ClearErrorCode()</code></a> -<dd> Clear the error code of a manager. - -<dt> <a href="cuddAllDet.html#Cudd_CofMinterm" TARGET="MAIN"><code>Cudd_CofMinterm()</code></a> -<dd> Computes the fraction of minterms in the on-set of all the - positive cofactors of a BDD or ADD. - -<dt> <a href="cuddAllDet.html#Cudd_Cofactor" TARGET="MAIN"><code>Cudd_Cofactor()</code></a> -<dd> Computes the cofactor of f with respect to g. - -<dt> <a href="cuddAllDet.html#Cudd_CountLeaves" TARGET="MAIN"><code>Cudd_CountLeaves()</code></a> -<dd> Counts the number of leaves in a DD. - -<dt> <a href="cuddAllDet.html#Cudd_CountMinterm" TARGET="MAIN"><code>Cudd_CountMinterm()</code></a> -<dd> Counts the number of minterms of a DD. - -<dt> <a href="cuddAllDet.html#Cudd_CountPathsToNonZero" TARGET="MAIN"><code>Cudd_CountPathsToNonZero()</code></a> -<dd> Counts the number of paths to a non-zero terminal of a DD. - -<dt> <a href="cuddAllDet.html#Cudd_CountPath" TARGET="MAIN"><code>Cudd_CountPath()</code></a> -<dd> Counts the number of paths of a DD. - -<dt> <a href="cuddAllDet.html#Cudd_CubeArrayToBdd" TARGET="MAIN"><code>Cudd_CubeArrayToBdd()</code></a> -<dd> Builds the BDD of a cube from a positional array. - -<dt> <a href="cuddAllDet.html#Cudd_DagSize" TARGET="MAIN"><code>Cudd_DagSize()</code></a> -<dd> Counts the number of nodes in a DD. - -<dt> <a href="cuddAllDet.html#Cudd_DeadAreCounted" TARGET="MAIN"><code>Cudd_DeadAreCounted()</code></a> -<dd> Tells whether dead nodes are counted towards triggering - reordering. - -<dt> <a href="cuddAllDet.html#Cudd_DebugCheck" TARGET="MAIN"><code>Cudd_DebugCheck()</code></a> -<dd> Checks for inconsistencies in the DD heap. - -<dt> <a href="cuddAllDet.html#Cudd_Decreasing" TARGET="MAIN"><code>Cudd_Decreasing()</code></a> -<dd> Determines whether a BDD is negative unate in a - variable. - -<dt> <a href="cuddAllDet.html#Cudd_DelayedDerefBdd" TARGET="MAIN"><code>Cudd_DelayedDerefBdd()</code></a> -<dd> Decreases the reference count of BDD node n. - -<dt> <a href="cuddAllDet.html#Cudd_Density" TARGET="MAIN"><code>Cudd_Density()</code></a> -<dd> Computes the density of a BDD or ADD. - -<dt> <a href="cuddAllDet.html#Cudd_Deref" TARGET="MAIN"><code>Cudd_Deref()</code></a> -<dd> Decreases the reference count of node. - -<dt> <a href="cuddAllDet.html#Cudd_DisableGarbageCollection" TARGET="MAIN"><code>Cudd_DisableGarbageCollection()</code></a> -<dd> Disables garbage collection. - -<dt> <a href="cuddAllDet.html#Cudd_DisableOrderingMonitoring" TARGET="MAIN"><code>Cudd_DisableOrderingMonitoring()</code></a> -<dd> Disables monitoring of ordering. - -<dt> <a href="cuddAllDet.html#Cudd_DisableReorderingReporting" TARGET="MAIN"><code>Cudd_DisableReorderingReporting()</code></a> -<dd> Disables reporting of reordering stats. - -<dt> <a href="cuddAllDet.html#Cudd_Disequality" TARGET="MAIN"><code>Cudd_Disequality()</code></a> -<dd> Generates a BDD for the function x - y != c. - -<dt> <a href="cuddAllDet.html#Cudd_DumpBlifBody" TARGET="MAIN"><code>Cudd_DumpBlifBody()</code></a> -<dd> Writes a blif body representing the argument BDDs. - -<dt> <a href="cuddAllDet.html#Cudd_DumpBlif" TARGET="MAIN"><code>Cudd_DumpBlif()</code></a> -<dd> Writes a blif file representing the argument BDDs. - -<dt> <a href="cuddAllDet.html#Cudd_DumpDDcal" TARGET="MAIN"><code>Cudd_DumpDDcal()</code></a> -<dd> Writes a DDcal file representing the argument BDDs. - -<dt> <a href="cuddAllDet.html#Cudd_DumpDaVinci" TARGET="MAIN"><code>Cudd_DumpDaVinci()</code></a> -<dd> Writes a daVinci file representing the argument BDDs. - -<dt> <a href="cuddAllDet.html#Cudd_DumpDot" TARGET="MAIN"><code>Cudd_DumpDot()</code></a> -<dd> Writes a dot file representing the argument DDs. - -<dt> <a href="cuddAllDet.html#Cudd_DumpFactoredForm" TARGET="MAIN"><code>Cudd_DumpFactoredForm()</code></a> -<dd> Writes factored forms representing the argument BDDs. - -<dt> <a href="cuddAllDet.html#Cudd_Dxygtdxz" TARGET="MAIN"><code>Cudd_Dxygtdxz()</code></a> -<dd> Generates a BDD for the function d(x,y) > d(x,z). - -<dt> <a href="cuddAllDet.html#Cudd_Dxygtdyz" TARGET="MAIN"><code>Cudd_Dxygtdyz()</code></a> -<dd> Generates a BDD for the function d(x,y) > d(y,z). - -<dt> <a href="cuddAllDet.html#Cudd_EnableGarbageCollection" TARGET="MAIN"><code>Cudd_EnableGarbageCollection()</code></a> -<dd> Enables garbage collection. - -<dt> <a href="cuddAllDet.html#Cudd_EnableOrderingMonitoring" TARGET="MAIN"><code>Cudd_EnableOrderingMonitoring()</code></a> -<dd> Enables monitoring of ordering. - -<dt> <a href="cuddAllDet.html#Cudd_EnableReorderingReporting" TARGET="MAIN"><code>Cudd_EnableReorderingReporting()</code></a> -<dd> Enables reporting of reordering stats. - -<dt> <a href="cuddAllDet.html#Cudd_EpdCountMinterm" TARGET="MAIN"><code>Cudd_EpdCountMinterm()</code></a> -<dd> Counts the number of minterms of a DD with extended precision. - -<dt> <a href="cuddAllDet.html#Cudd_EqualSupNorm" TARGET="MAIN"><code>Cudd_EqualSupNorm()</code></a> -<dd> Compares two ADDs for equality within tolerance. - -<dt> <a href="cuddAllDet.html#Cudd_EquivDC" TARGET="MAIN"><code>Cudd_EquivDC()</code></a> -<dd> Tells whether F and G are identical wherever D is 0. - -<dt> <a href="cuddAllDet.html#Cudd_EstimateCofactorSimple" TARGET="MAIN"><code>Cudd_EstimateCofactorSimple()</code></a> -<dd> Estimates the number of nodes in a cofactor of a DD. - -<dt> <a href="cuddAllDet.html#Cudd_EstimateCofactor" TARGET="MAIN"><code>Cudd_EstimateCofactor()</code></a> -<dd> Estimates the number of nodes in a cofactor of a DD. - -<dt> <a href="cuddAllDet.html#Cudd_Eval" TARGET="MAIN"><code>Cudd_Eval()</code></a> -<dd> Returns the value of a DD for a given variable assignment. - -<dt> <a href="cuddAllDet.html#Cudd_ExpectedUsedSlots" TARGET="MAIN"><code>Cudd_ExpectedUsedSlots()</code></a> -<dd> Computes the expected fraction of used slots in the unique - table. - -<dt> <a href="cuddAllDet.html#Cudd_FindEssential" TARGET="MAIN"><code>Cudd_FindEssential()</code></a> -<dd> Finds the essential variables of a DD. - -<dt> <a href="cuddAllDet.html#Cudd_FindTwoLiteralClauses" TARGET="MAIN"><code>Cudd_FindTwoLiteralClauses()</code></a> -<dd> Finds the two literal clauses of a DD. - -<dt> <a href="cuddAllDet.html#Cudd_FirstCube" TARGET="MAIN"><code>Cudd_FirstCube()</code></a> -<dd> Finds the first cube of a decision diagram. - -<dt> <a href="cuddAllDet.html#Cudd_FirstNode" TARGET="MAIN"><code>Cudd_FirstNode()</code></a> -<dd> Finds the first node of a decision diagram. - -<dt> <a href="cuddAllDet.html#Cudd_FirstPrime" TARGET="MAIN"><code>Cudd_FirstPrime()</code></a> -<dd> Finds the first prime of a Boolean function. - -<dt> <a href="cuddAllDet.html#Cudd_FreeTree" TARGET="MAIN"><code>Cudd_FreeTree()</code></a> -<dd> Frees the variable group tree of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_FreeZddTree" TARGET="MAIN"><code>Cudd_FreeZddTree()</code></a> -<dd> Frees the variable group tree of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_GarbageCollectionEnabled" TARGET="MAIN"><code>Cudd_GarbageCollectionEnabled()</code></a> -<dd> Tells whether garbage collection is enabled. - -<dt> <a href="cuddAllDet.html#Cudd_GenFree" TARGET="MAIN"><code>Cudd_GenFree()</code></a> -<dd> Frees a CUDD generator. - -<dt> <a href="cuddAllDet.html#Cudd_IncreaseTimeLimit" TARGET="MAIN"><code>Cudd_IncreaseTimeLimit()</code></a> -<dd> Increases the time limit for the manager. - -<dt> <a href="cuddAllDet.html#Cudd_Increasing" TARGET="MAIN"><code>Cudd_Increasing()</code></a> -<dd> Determines whether a BDD is positive unate in a - variable. - -<dt> <a href="cuddAllDet.html#Cudd_IndicesToCube" TARGET="MAIN"><code>Cudd_IndicesToCube()</code></a> -<dd> Builds a cube of BDD variables from an array of indices. - -<dt> <a href="cuddAllDet.html#Cudd_Inequality" TARGET="MAIN"><code>Cudd_Inequality()</code></a> -<dd> Generates a BDD for the function x - y ≥ c. - -<dt> <a href="cuddAllDet.html#Cudd_Init" TARGET="MAIN"><code>Cudd_Init()</code></a> -<dd> Creates a new DD manager. - -<dt> <a href="cuddAllDet.html#Cudd_IsGenEmpty" TARGET="MAIN"><code>Cudd_IsGenEmpty()</code></a> -<dd> Queries the status of a generator. - -<dt> <a href="cuddAllDet.html#Cudd_IsInHook" TARGET="MAIN"><code>Cudd_IsInHook()</code></a> -<dd> Checks whether a function is in a hook. - -<dt> <a href="cuddAllDet.html#Cudd_IsNonConstant" TARGET="MAIN"><code>Cudd_IsNonConstant()</code></a> -<dd> Returns 1 if a DD node is not constant. - -<dt> <a href="cuddAllDet.html#Cudd_IterDerefBdd" TARGET="MAIN"><code>Cudd_IterDerefBdd()</code></a> -<dd> Decreases the reference count of BDD node n. - -<dt> <a href="cuddAllDet.html#Cudd_LargestCube" TARGET="MAIN"><code>Cudd_LargestCube()</code></a> -<dd> Finds a largest cube in a DD. - -<dt> <a href="cuddAllDet.html#Cudd_MakeBddFromZddCover" TARGET="MAIN"><code>Cudd_MakeBddFromZddCover()</code></a> -<dd> Converts a ZDD cover to a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_MakeTreeNode" TARGET="MAIN"><code>Cudd_MakeTreeNode()</code></a> -<dd> Creates a new variable group. - -<dt> <a href="cuddAllDet.html#Cudd_MakeZddTreeNode" TARGET="MAIN"><code>Cudd_MakeZddTreeNode()</code></a> -<dd> Creates a new ZDD variable group. - -<dt> <a href="cuddAllDet.html#Cudd_MinHammingDist" TARGET="MAIN"><code>Cudd_MinHammingDist()</code></a> -<dd> Returns the minimum Hamming distance between f and minterm. - -<dt> <a href="cuddAllDet.html#Cudd_NewApaNumber" TARGET="MAIN"><code>Cudd_NewApaNumber()</code></a> -<dd> Allocates memory for an arbitrary precision integer. - -<dt> <a href="cuddAllDet.html#Cudd_NextCube" TARGET="MAIN"><code>Cudd_NextCube()</code></a> -<dd> Generates the next cube of a decision diagram onset. - -<dt> <a href="cuddAllDet.html#Cudd_NextNode" TARGET="MAIN"><code>Cudd_NextNode()</code></a> -<dd> Finds the next node of a decision diagram. - -<dt> <a href="cuddAllDet.html#Cudd_NextPrime" TARGET="MAIN"><code>Cudd_NextPrime()</code></a> -<dd> Generates the next prime of a Boolean function. - -<dt> <a href="cuddAllDet.html#Cudd_NodeReadIndex" TARGET="MAIN"><code>Cudd_NodeReadIndex()</code></a> -<dd> Returns the index of the node. - -<dt> <a href="cuddAllDet.html#Cudd_OrderingMonitoring" TARGET="MAIN"><code>Cudd_OrderingMonitoring()</code></a> -<dd> Returns 1 if monitoring of ordering is enabled. - -<dt> <a href="cuddAllDet.html#Cudd_OutOfMem" TARGET="MAIN"><code>Cudd_OutOfMem()</code></a> -<dd> Warns that a memory allocation failed. - -<dt> <a href="cuddAllDet.html#Cudd_OverApprox" TARGET="MAIN"><code>Cudd_OverApprox()</code></a> -<dd> Extracts a dense superset from a BDD with Shiple's - underapproximation method. - -<dt> <a href="cuddAllDet.html#Cudd_Prime" TARGET="MAIN"><code>Cudd_Prime()</code></a> -<dd> Returns the next prime >= p. - -<dt> <a href="cuddAllDet.html#Cudd_PrintDebug" TARGET="MAIN"><code>Cudd_PrintDebug()</code></a> -<dd> Prints to the standard output a DD and its statistics. - -<dt> <a href="cuddAllDet.html#Cudd_PrintGroupedOrder" TARGET="MAIN"><code>Cudd_PrintGroupedOrder()</code></a> -<dd> Hook function to print the current variable order. - -<dt> <a href="cuddAllDet.html#Cudd_PrintInfo" TARGET="MAIN"><code>Cudd_PrintInfo()</code></a> -<dd> Prints out statistics and settings for a CUDD manager. - -<dt> <a href="cuddAllDet.html#Cudd_PrintLinear" TARGET="MAIN"><code>Cudd_PrintLinear()</code></a> -<dd> Prints the linear transform matrix. - -<dt> <a href="cuddAllDet.html#Cudd_PrintMinterm" TARGET="MAIN"><code>Cudd_PrintMinterm()</code></a> -<dd> Prints a disjoint sum of products. - -<dt> <a href="cuddAllDet.html#Cudd_PrintTwoLiteralClauses" TARGET="MAIN"><code>Cudd_PrintTwoLiteralClauses()</code></a> -<dd> Prints the two literal clauses of a DD. - -<dt> <a href="cuddAllDet.html#Cudd_PrintVersion" TARGET="MAIN"><code>Cudd_PrintVersion()</code></a> -<dd> Prints the package version number. - -<dt> <a href="cuddAllDet.html#Cudd_PrioritySelect" TARGET="MAIN"><code>Cudd_PrioritySelect()</code></a> -<dd> Selects pairs from R using a priority function. - -<dt> <a href="cuddAllDet.html#Cudd_Quit" TARGET="MAIN"><code>Cudd_Quit()</code></a> -<dd> Deletes resources associated with a DD manager. - -<dt> <a href="cuddAllDet.html#Cudd_Random" TARGET="MAIN"><code>Cudd_Random()</code></a> -<dd> Portable random number generator. - -<dt> <a href="cuddAllDet.html#Cudd_ReadArcviolation" TARGET="MAIN"><code>Cudd_ReadArcviolation()</code></a> -<dd> Returns the current value of the arcviolation parameter used - in group sifting. - -<dt> <a href="cuddAllDet.html#Cudd_ReadBackground" TARGET="MAIN"><code>Cudd_ReadBackground()</code></a> -<dd> Reads the background constant of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadCacheHits" TARGET="MAIN"><code>Cudd_ReadCacheHits()</code></a> -<dd> Returns the number of cache hits. - -<dt> <a href="cuddAllDet.html#Cudd_ReadCacheLookUps" TARGET="MAIN"><code>Cudd_ReadCacheLookUps()</code></a> -<dd> Returns the number of cache look-ups. - -<dt> <a href="cuddAllDet.html#Cudd_ReadCacheSlots" TARGET="MAIN"><code>Cudd_ReadCacheSlots()</code></a> -<dd> Reads the number of slots in the cache. - -<dt> <a href="cuddAllDet.html#Cudd_ReadCacheUsedSlots" TARGET="MAIN"><code>Cudd_ReadCacheUsedSlots()</code></a> -<dd> Reads the fraction of used slots in the cache. - -<dt> <a href="cuddAllDet.html#Cudd_ReadDead" TARGET="MAIN"><code>Cudd_ReadDead()</code></a> -<dd> Returns the number of dead nodes in the unique table. - -<dt> <a href="cuddAllDet.html#Cudd_ReadElapsedTime" TARGET="MAIN"><code>Cudd_ReadElapsedTime()</code></a> -<dd> Returns the time elapsed since the start time of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadEpsilon" TARGET="MAIN"><code>Cudd_ReadEpsilon()</code></a> -<dd> Reads the epsilon parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadErrorCode" TARGET="MAIN"><code>Cudd_ReadErrorCode()</code></a> -<dd> Returns the code of the last error. - -<dt> <a href="cuddAllDet.html#Cudd_ReadGarbageCollectionTime" TARGET="MAIN"><code>Cudd_ReadGarbageCollectionTime()</code></a> -<dd> Returns the time spent in garbage collection. - -<dt> <a href="cuddAllDet.html#Cudd_ReadGarbageCollections" TARGET="MAIN"><code>Cudd_ReadGarbageCollections()</code></a> -<dd> Returns the number of times garbage collection has occurred. - -<dt> <a href="cuddAllDet.html#Cudd_ReadGroupcheck" TARGET="MAIN"><code>Cudd_ReadGroupcheck()</code></a> -<dd> Reads the groupcheck parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadInvPermZdd" TARGET="MAIN"><code>Cudd_ReadInvPermZdd()</code></a> -<dd> Returns the index of the ZDD variable currently in the i-th - position of the order. - -<dt> <a href="cuddAllDet.html#Cudd_ReadInvPerm" TARGET="MAIN"><code>Cudd_ReadInvPerm()</code></a> -<dd> Returns the index of the variable currently in the i-th - position of the order. - -<dt> <a href="cuddAllDet.html#Cudd_ReadIthClause" TARGET="MAIN"><code>Cudd_ReadIthClause()</code></a> -<dd> Accesses the i-th clause of a DD. - -<dt> <a href="cuddAllDet.html#Cudd_ReadKeys" TARGET="MAIN"><code>Cudd_ReadKeys()</code></a> -<dd> Returns the number of nodes in the unique table. - -<dt> <a href="cuddAllDet.html#Cudd_ReadLinear" TARGET="MAIN"><code>Cudd_ReadLinear()</code></a> -<dd> Reads an entry of the linear transform matrix. - -<dt> <a href="cuddAllDet.html#Cudd_ReadLogicZero" TARGET="MAIN"><code>Cudd_ReadLogicZero()</code></a> -<dd> Returns the logic zero constant of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadLooseUpTo" TARGET="MAIN"><code>Cudd_ReadLooseUpTo()</code></a> -<dd> Reads the looseUpTo parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadMaxCacheHard" TARGET="MAIN"><code>Cudd_ReadMaxCacheHard()</code></a> -<dd> Reads the maxCacheHard parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadMaxCache" TARGET="MAIN"><code>Cudd_ReadMaxCache()</code></a> -<dd> Returns the soft limit for the cache size. - -<dt> <a href="cuddAllDet.html#Cudd_ReadMaxGrowthAlternate" TARGET="MAIN"><code>Cudd_ReadMaxGrowthAlternate()</code></a> -<dd> Reads the maxGrowthAlt parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadMaxGrowth" TARGET="MAIN"><code>Cudd_ReadMaxGrowth()</code></a> -<dd> Reads the maxGrowth parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadMaxLive" TARGET="MAIN"><code>Cudd_ReadMaxLive()</code></a> -<dd> Reads the maximum allowed number of live nodes. - -<dt> <a href="cuddAllDet.html#Cudd_ReadMaxMemory" TARGET="MAIN"><code>Cudd_ReadMaxMemory()</code></a> -<dd> Reads the maximum allowed memory. - -<dt> <a href="cuddAllDet.html#Cudd_ReadMaxReorderings" TARGET="MAIN"><code>Cudd_ReadMaxReorderings()</code></a> -<dd> Returns the maximum number of times reordering may be invoked. - -<dt> <a href="cuddAllDet.html#Cudd_ReadMemoryInUse" TARGET="MAIN"><code>Cudd_ReadMemoryInUse()</code></a> -<dd> Returns the memory in use by the manager measured in bytes. - -<dt> <a href="cuddAllDet.html#Cudd_ReadMinDead" TARGET="MAIN"><code>Cudd_ReadMinDead()</code></a> -<dd> Reads the minDead parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadMinHit" TARGET="MAIN"><code>Cudd_ReadMinHit()</code></a> -<dd> Reads the hit rate that causes resizinig of the computed - table. - -<dt> <a href="cuddAllDet.html#Cudd_ReadMinusInfinity" TARGET="MAIN"><code>Cudd_ReadMinusInfinity()</code></a> -<dd> Reads the minus-infinity constant from the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadNextReordering" TARGET="MAIN"><code>Cudd_ReadNextReordering()</code></a> -<dd> Returns the threshold for the next dynamic reordering. - -<dt> <a href="cuddAllDet.html#Cudd_ReadNodeCount" TARGET="MAIN"><code>Cudd_ReadNodeCount()</code></a> -<dd> Reports the number of nodes in BDDs and ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_ReadNodesDropped" TARGET="MAIN"><code>Cudd_ReadNodesDropped()</code></a> -<dd> Returns the number of nodes dropped. - -<dt> <a href="cuddAllDet.html#Cudd_ReadNodesFreed" TARGET="MAIN"><code>Cudd_ReadNodesFreed()</code></a> -<dd> Returns the number of nodes freed. - -<dt> <a href="cuddAllDet.html#Cudd_ReadNumberXovers" TARGET="MAIN"><code>Cudd_ReadNumberXovers()</code></a> -<dd> Reads the current number of crossovers used by the - genetic algorithm for reordering. - -<dt> <a href="cuddAllDet.html#Cudd_ReadOne" TARGET="MAIN"><code>Cudd_ReadOne()</code></a> -<dd> Returns the one constant of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadOrderRandomization" TARGET="MAIN"><code>Cudd_ReadOrderRandomization()</code></a> -<dd> Returns the order randomization factor. - -<dt> <a href="cuddAllDet.html#Cudd_ReadPeakLiveNodeCount" TARGET="MAIN"><code>Cudd_ReadPeakLiveNodeCount()</code></a> -<dd> Reports the peak number of live nodes. - -<dt> <a href="cuddAllDet.html#Cudd_ReadPeakNodeCount" TARGET="MAIN"><code>Cudd_ReadPeakNodeCount()</code></a> -<dd> Reports the peak number of nodes. - -<dt> <a href="cuddAllDet.html#Cudd_ReadPermZdd" TARGET="MAIN"><code>Cudd_ReadPermZdd()</code></a> -<dd> Returns the current position of the i-th ZDD variable in the - order. - -<dt> <a href="cuddAllDet.html#Cudd_ReadPerm" TARGET="MAIN"><code>Cudd_ReadPerm()</code></a> -<dd> Returns the current position of the i-th variable in the - order. - -<dt> <a href="cuddAllDet.html#Cudd_ReadPlusInfinity" TARGET="MAIN"><code>Cudd_ReadPlusInfinity()</code></a> -<dd> Reads the plus-infinity constant from the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadPopulationSize" TARGET="MAIN"><code>Cudd_ReadPopulationSize()</code></a> -<dd> Reads the current size of the population used by the - genetic algorithm for reordering. - -<dt> <a href="cuddAllDet.html#Cudd_ReadRecomb" TARGET="MAIN"><code>Cudd_ReadRecomb()</code></a> -<dd> Returns the current value of the recombination parameter used - in group sifting. - -<dt> <a href="cuddAllDet.html#Cudd_ReadRecursiveCalls" TARGET="MAIN"><code>Cudd_ReadRecursiveCalls()</code></a> -<dd> Returns the number of recursive calls. - -<dt> <a href="cuddAllDet.html#Cudd_ReadReorderingCycle" TARGET="MAIN"><code>Cudd_ReadReorderingCycle()</code></a> -<dd> Reads the reordCycle parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadReorderingTime" TARGET="MAIN"><code>Cudd_ReadReorderingTime()</code></a> -<dd> Returns the time spent in reordering. - -<dt> <a href="cuddAllDet.html#Cudd_ReadReorderings" TARGET="MAIN"><code>Cudd_ReadReorderings()</code></a> -<dd> Returns the number of times reordering has occurred. - -<dt> <a href="cuddAllDet.html#Cudd_ReadSiftMaxSwap" TARGET="MAIN"><code>Cudd_ReadSiftMaxSwap()</code></a> -<dd> Reads the siftMaxSwap parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadSiftMaxVar" TARGET="MAIN"><code>Cudd_ReadSiftMaxVar()</code></a> -<dd> Reads the siftMaxVar parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadSize" TARGET="MAIN"><code>Cudd_ReadSize()</code></a> -<dd> Returns the number of BDD variables in existance. - -<dt> <a href="cuddAllDet.html#Cudd_ReadSlots" TARGET="MAIN"><code>Cudd_ReadSlots()</code></a> -<dd> Returns the total number of slots of the unique table. - -<dt> <a href="cuddAllDet.html#Cudd_ReadStartTime" TARGET="MAIN"><code>Cudd_ReadStartTime()</code></a> -<dd> Returns the start time of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadStderr" TARGET="MAIN"><code>Cudd_ReadStderr()</code></a> -<dd> Reads the stderr of a manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadStdout" TARGET="MAIN"><code>Cudd_ReadStdout()</code></a> -<dd> Reads the stdout of a manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadSwapSteps" TARGET="MAIN"><code>Cudd_ReadSwapSteps()</code></a> -<dd> Reads the number of elementary reordering steps. - -<dt> <a href="cuddAllDet.html#Cudd_ReadSymmviolation" TARGET="MAIN"><code>Cudd_ReadSymmviolation()</code></a> -<dd> Returns the current value of the symmviolation parameter used - in group sifting. - -<dt> <a href="cuddAllDet.html#Cudd_ReadTimeLimit" TARGET="MAIN"><code>Cudd_ReadTimeLimit()</code></a> -<dd> Returns the time limit for the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadTree" TARGET="MAIN"><code>Cudd_ReadTree()</code></a> -<dd> Returns the variable group tree of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadUniqueLinks" TARGET="MAIN"><code>Cudd_ReadUniqueLinks()</code></a> -<dd> Returns the number of links followed in the unique table. - -<dt> <a href="cuddAllDet.html#Cudd_ReadUniqueLookUps" TARGET="MAIN"><code>Cudd_ReadUniqueLookUps()</code></a> -<dd> Returns the number of look-ups in the unique table. - -<dt> <a href="cuddAllDet.html#Cudd_ReadUsedSlots" TARGET="MAIN"><code>Cudd_ReadUsedSlots()</code></a> -<dd> Reads the fraction of used slots in the unique table. - -<dt> <a href="cuddAllDet.html#Cudd_ReadVars" TARGET="MAIN"><code>Cudd_ReadVars()</code></a> -<dd> Returns the i-th element of the vars array. - -<dt> <a href="cuddAllDet.html#Cudd_ReadZddOne" TARGET="MAIN"><code>Cudd_ReadZddOne()</code></a> -<dd> Returns the ZDD for the constant 1 function. - -<dt> <a href="cuddAllDet.html#Cudd_ReadZddSize" TARGET="MAIN"><code>Cudd_ReadZddSize()</code></a> -<dd> Returns the number of ZDD variables in existance. - -<dt> <a href="cuddAllDet.html#Cudd_ReadZddTree" TARGET="MAIN"><code>Cudd_ReadZddTree()</code></a> -<dd> Returns the variable group tree of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_ReadZero" TARGET="MAIN"><code>Cudd_ReadZero()</code></a> -<dd> Returns the zero constant of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_RecursiveDerefZdd" TARGET="MAIN"><code>Cudd_RecursiveDerefZdd()</code></a> -<dd> Decreases the reference count of ZDD node n. - -<dt> <a href="cuddAllDet.html#Cudd_RecursiveDeref" TARGET="MAIN"><code>Cudd_RecursiveDeref()</code></a> -<dd> Decreases the reference count of node n. - -<dt> <a href="cuddAllDet.html#Cudd_ReduceHeap" TARGET="MAIN"><code>Cudd_ReduceHeap()</code></a> -<dd> Main dynamic reordering routine. - -<dt> <a href="cuddAllDet.html#Cudd_Ref" TARGET="MAIN"><code>Cudd_Ref()</code></a> -<dd> Increases the reference count of a node, if it is not - saturated. - -<dt> <a href="cuddAllDet.html#Cudd_RemapOverApprox" TARGET="MAIN"><code>Cudd_RemapOverApprox()</code></a> -<dd> Extracts a dense superset from a BDD with the remapping - underapproximation method. - -<dt> <a href="cuddAllDet.html#Cudd_RemapUnderApprox" TARGET="MAIN"><code>Cudd_RemapUnderApprox()</code></a> -<dd> Extracts a dense subset from a BDD with the remapping - underapproximation method. - -<dt> <a href="cuddAllDet.html#Cudd_RemoveHook" TARGET="MAIN"><code>Cudd_RemoveHook()</code></a> -<dd> Removes a function from a hook. - -<dt> <a href="cuddAllDet.html#Cudd_ReorderingReporting" TARGET="MAIN"><code>Cudd_ReorderingReporting()</code></a> -<dd> Returns 1 if reporting of reordering stats is enabled. - -<dt> <a href="cuddAllDet.html#Cudd_ReorderingStatusZdd" TARGET="MAIN"><code>Cudd_ReorderingStatusZdd()</code></a> -<dd> Reports the status of automatic dynamic reordering of ZDDs. - -<dt> <a href="cuddAllDet.html#Cudd_ReorderingStatus" TARGET="MAIN"><code>Cudd_ReorderingStatus()</code></a> -<dd> Reports the status of automatic dynamic reordering of BDDs - and ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_Reserve" TARGET="MAIN"><code>Cudd_Reserve()</code></a> -<dd> Expand manager without creating variables. - -<dt> <a href="cuddAllDet.html#Cudd_ResetStartTime" TARGET="MAIN"><code>Cudd_ResetStartTime()</code></a> -<dd> Resets the start time of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetArcviolation" TARGET="MAIN"><code>Cudd_SetArcviolation()</code></a> -<dd> Sets the value of the arcviolation parameter used - in group sifting. - -<dt> <a href="cuddAllDet.html#Cudd_SetBackground" TARGET="MAIN"><code>Cudd_SetBackground()</code></a> -<dd> Sets the background constant of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetEpsilon" TARGET="MAIN"><code>Cudd_SetEpsilon()</code></a> -<dd> Sets the epsilon parameter of the manager to ep. - -<dt> <a href="cuddAllDet.html#Cudd_SetGroupcheck" TARGET="MAIN"><code>Cudd_SetGroupcheck()</code></a> -<dd> Sets the parameter groupcheck of the manager to gc. - -<dt> <a href="cuddAllDet.html#Cudd_SetLooseUpTo" TARGET="MAIN"><code>Cudd_SetLooseUpTo()</code></a> -<dd> Sets the looseUpTo parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetMaxCacheHard" TARGET="MAIN"><code>Cudd_SetMaxCacheHard()</code></a> -<dd> Sets the maxCacheHard parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetMaxGrowthAlternate" TARGET="MAIN"><code>Cudd_SetMaxGrowthAlternate()</code></a> -<dd> Sets the maxGrowthAlt parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetMaxGrowth" TARGET="MAIN"><code>Cudd_SetMaxGrowth()</code></a> -<dd> Sets the maxGrowth parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetMaxLive" TARGET="MAIN"><code>Cudd_SetMaxLive()</code></a> -<dd> Sets the maximum allowed number of live nodes. - -<dt> <a href="cuddAllDet.html#Cudd_SetMaxMemory" TARGET="MAIN"><code>Cudd_SetMaxMemory()</code></a> -<dd> Sets the maximum allowed memory. - -<dt> <a href="cuddAllDet.html#Cudd_SetMaxReorderings" TARGET="MAIN"><code>Cudd_SetMaxReorderings()</code></a> -<dd> Sets the maximum number of times reordering may be invoked. - -<dt> <a href="cuddAllDet.html#Cudd_SetMinHit" TARGET="MAIN"><code>Cudd_SetMinHit()</code></a> -<dd> Sets the hit rate that causes resizinig of the computed - table. - -<dt> <a href="cuddAllDet.html#Cudd_SetNextReordering" TARGET="MAIN"><code>Cudd_SetNextReordering()</code></a> -<dd> Sets the threshold for the next dynamic reordering. - -<dt> <a href="cuddAllDet.html#Cudd_SetNumberXovers" TARGET="MAIN"><code>Cudd_SetNumberXovers()</code></a> -<dd> Sets the number of crossovers used by the - genetic algorithm for reordering. - -<dt> <a href="cuddAllDet.html#Cudd_SetOrderRandomization" TARGET="MAIN"><code>Cudd_SetOrderRandomization()</code></a> -<dd> Sets the order randomization factor. - -<dt> <a href="cuddAllDet.html#Cudd_SetPopulationSize" TARGET="MAIN"><code>Cudd_SetPopulationSize()</code></a> -<dd> Sets the size of the population used by the - genetic algorithm for reordering. - -<dt> <a href="cuddAllDet.html#Cudd_SetRecomb" TARGET="MAIN"><code>Cudd_SetRecomb()</code></a> -<dd> Sets the value of the recombination parameter used in group - sifting. - -<dt> <a href="cuddAllDet.html#Cudd_SetReorderingCycle" TARGET="MAIN"><code>Cudd_SetReorderingCycle()</code></a> -<dd> Sets the reordCycle parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetSiftMaxSwap" TARGET="MAIN"><code>Cudd_SetSiftMaxSwap()</code></a> -<dd> Sets the siftMaxSwap parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetSiftMaxVar" TARGET="MAIN"><code>Cudd_SetSiftMaxVar()</code></a> -<dd> Sets the siftMaxVar parameter of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetStartTime" TARGET="MAIN"><code>Cudd_SetStartTime()</code></a> -<dd> Sets the start time of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetStderr" TARGET="MAIN"><code>Cudd_SetStderr()</code></a> -<dd> Sets the stderr of a manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetStdout" TARGET="MAIN"><code>Cudd_SetStdout()</code></a> -<dd> Sets the stdout of a manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetSymmviolation" TARGET="MAIN"><code>Cudd_SetSymmviolation()</code></a> -<dd> Sets the value of the symmviolation parameter used - in group sifting. - -<dt> <a href="cuddAllDet.html#Cudd_SetTimeLimit" TARGET="MAIN"><code>Cudd_SetTimeLimit()</code></a> -<dd> Sets the time limit for the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetTree" TARGET="MAIN"><code>Cudd_SetTree()</code></a> -<dd> Sets the variable group tree of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetVarMap" TARGET="MAIN"><code>Cudd_SetVarMap()</code></a> -<dd> Registers a variable mapping with the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SetZddTree" TARGET="MAIN"><code>Cudd_SetZddTree()</code></a> -<dd> Sets the ZDD variable group tree of the manager. - -<dt> <a href="cuddAllDet.html#Cudd_SharingSize" TARGET="MAIN"><code>Cudd_SharingSize()</code></a> -<dd> Counts the number of nodes in an array of DDs. - -<dt> <a href="cuddAllDet.html#Cudd_ShortestLength" TARGET="MAIN"><code>Cudd_ShortestLength()</code></a> -<dd> Find the length of the shortest path(s) in a DD. - -<dt> <a href="cuddAllDet.html#Cudd_ShortestPath" TARGET="MAIN"><code>Cudd_ShortestPath()</code></a> -<dd> Finds a shortest path in a DD. - -<dt> <a href="cuddAllDet.html#Cudd_ShuffleHeap" TARGET="MAIN"><code>Cudd_ShuffleHeap()</code></a> -<dd> Reorders variables according to given permutation. - -<dt> <a href="cuddAllDet.html#Cudd_SolveEqn" TARGET="MAIN"><code>Cudd_SolveEqn()</code></a> -<dd> Implements the solution of F(x,y) = 0. - -<dt> <a href="cuddAllDet.html#Cudd_SplitSet" TARGET="MAIN"><code>Cudd_SplitSet()</code></a> -<dd> Returns m minterms from a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_Srandom" TARGET="MAIN"><code>Cudd_Srandom()</code></a> -<dd> Initializer for the portable random number generator. - -<dt> <a href="cuddAllDet.html#Cudd_StdPostReordHook" TARGET="MAIN"><code>Cudd_StdPostReordHook()</code></a> -<dd> Sample hook function to call after reordering. - -<dt> <a href="cuddAllDet.html#Cudd_StdPreReordHook" TARGET="MAIN"><code>Cudd_StdPreReordHook()</code></a> -<dd> Sample hook function to call before reordering. - -<dt> <a href="cuddAllDet.html#Cudd_SubsetCompress" TARGET="MAIN"><code>Cudd_SubsetCompress()</code></a> -<dd> Find a dense subset of BDD <code>f</code>. - -<dt> <a href="cuddAllDet.html#Cudd_SubsetHeavyBranch" TARGET="MAIN"><code>Cudd_SubsetHeavyBranch()</code></a> -<dd> Extracts a dense subset from a BDD with the heavy branch - heuristic. - -<dt> <a href="cuddAllDet.html#Cudd_SubsetShortPaths" TARGET="MAIN"><code>Cudd_SubsetShortPaths()</code></a> -<dd> Extracts a dense subset from a BDD with the shortest paths - heuristic. - -<dt> <a href="cuddAllDet.html#Cudd_SubsetWithMaskVars" TARGET="MAIN"><code>Cudd_SubsetWithMaskVars()</code></a> -<dd> Extracts a subset from a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_SupersetCompress" TARGET="MAIN"><code>Cudd_SupersetCompress()</code></a> -<dd> Find a dense superset of BDD <code>f</code>. - -<dt> <a href="cuddAllDet.html#Cudd_SupersetHeavyBranch" TARGET="MAIN"><code>Cudd_SupersetHeavyBranch()</code></a> -<dd> Extracts a dense superset from a BDD with the heavy branch - heuristic. - -<dt> <a href="cuddAllDet.html#Cudd_SupersetShortPaths" TARGET="MAIN"><code>Cudd_SupersetShortPaths()</code></a> -<dd> Extracts a dense superset from a BDD with the shortest paths - heuristic. - -<dt> <a href="cuddAllDet.html#Cudd_SupportIndex" TARGET="MAIN"><code>Cudd_SupportIndex()</code></a> -<dd> Finds the variables on which a DD depends. - -<dt> <a href="cuddAllDet.html#Cudd_SupportIndices" TARGET="MAIN"><code>Cudd_SupportIndices()</code></a> -<dd> Finds the variables on which a DD depends. - -<dt> <a href="cuddAllDet.html#Cudd_SupportSize" TARGET="MAIN"><code>Cudd_SupportSize()</code></a> -<dd> Counts the variables on which a DD depends. - -<dt> <a href="cuddAllDet.html#Cudd_Support" TARGET="MAIN"><code>Cudd_Support()</code></a> -<dd> Finds the variables on which a DD depends. - -<dt> <a href="cuddAllDet.html#Cudd_SymmProfile" TARGET="MAIN"><code>Cudd_SymmProfile()</code></a> -<dd> Prints statistics on symmetric variables. - -<dt> <a href="cuddAllDet.html#Cudd_TimeLimited" TARGET="MAIN"><code>Cudd_TimeLimited()</code></a> -<dd> Returns true if the time limit for the manager is set. - -<dt> <a href="cuddAllDet.html#Cudd_TurnOffCountDead" TARGET="MAIN"><code>Cudd_TurnOffCountDead()</code></a> -<dd> Causes the dead nodes not to be counted towards triggering - reordering. - -<dt> <a href="cuddAllDet.html#Cudd_TurnOnCountDead" TARGET="MAIN"><code>Cudd_TurnOnCountDead()</code></a> -<dd> Causes the dead nodes to be counted towards triggering - reordering. - -<dt> <a href="cuddAllDet.html#Cudd_UnderApprox" TARGET="MAIN"><code>Cudd_UnderApprox()</code></a> -<dd> Extracts a dense subset from a BDD with Shiple's - underapproximation method. - -<dt> <a href="cuddAllDet.html#Cudd_UnsetTimeLimit" TARGET="MAIN"><code>Cudd_UnsetTimeLimit()</code></a> -<dd> Unsets the time limit for the manager. - -<dt> <a href="cuddAllDet.html#Cudd_UpdateTimeLimit" TARGET="MAIN"><code>Cudd_UpdateTimeLimit()</code></a> -<dd> Updates the time limit for the manager. - -<dt> <a href="cuddAllDet.html#Cudd_VectorSupportIndex" TARGET="MAIN"><code>Cudd_VectorSupportIndex()</code></a> -<dd> Finds the variables on which a set of DDs depends. - -<dt> <a href="cuddAllDet.html#Cudd_VectorSupportIndices" TARGET="MAIN"><code>Cudd_VectorSupportIndices()</code></a> -<dd> Finds the variables on which a set of DDs depends. - -<dt> <a href="cuddAllDet.html#Cudd_VectorSupportSize" TARGET="MAIN"><code>Cudd_VectorSupportSize()</code></a> -<dd> Counts the variables on which a set of DDs depends. - -<dt> <a href="cuddAllDet.html#Cudd_VectorSupport" TARGET="MAIN"><code>Cudd_VectorSupport()</code></a> -<dd> Finds the variables on which a set of DDs depends. - -<dt> <a href="cuddAllDet.html#Cudd_VerifySol" TARGET="MAIN"><code>Cudd_VerifySol()</code></a> -<dd> Checks the solution of F(x,y) = 0. - -<dt> <a href="cuddAllDet.html#Cudd_Xeqy" TARGET="MAIN"><code>Cudd_Xeqy()</code></a> -<dd> Generates a BDD for the function x==y. - -<dt> <a href="cuddAllDet.html#Cudd_Xgty" TARGET="MAIN"><code>Cudd_Xgty()</code></a> -<dd> Generates a BDD for the function x > y. - -<dt> <a href="cuddAllDet.html#Cudd_addAgreement" TARGET="MAIN"><code>Cudd_addAgreement()</code></a> -<dd> f if f==g; background if f!=g. - -<dt> <a href="cuddAllDet.html#Cudd_addApply" TARGET="MAIN"><code>Cudd_addApply()</code></a> -<dd> Applies op to the corresponding discriminants of f and g. - -<dt> <a href="cuddAllDet.html#Cudd_addBddInterval" TARGET="MAIN"><code>Cudd_addBddInterval()</code></a> -<dd> Converts an ADD to a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_addBddIthBit" TARGET="MAIN"><code>Cudd_addBddIthBit()</code></a> -<dd> Converts an ADD to a BDD by extracting the i-th bit from - the leaves. - -<dt> <a href="cuddAllDet.html#Cudd_addBddPattern" TARGET="MAIN"><code>Cudd_addBddPattern()</code></a> -<dd> Converts an ADD to a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_addBddStrictThreshold" TARGET="MAIN"><code>Cudd_addBddStrictThreshold()</code></a> -<dd> Converts an ADD to a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_addBddThreshold" TARGET="MAIN"><code>Cudd_addBddThreshold()</code></a> -<dd> Converts an ADD to a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_addCmpl" TARGET="MAIN"><code>Cudd_addCmpl()</code></a> -<dd> Computes the complement of an ADD a la C language. - -<dt> <a href="cuddAllDet.html#Cudd_addCompose" TARGET="MAIN"><code>Cudd_addCompose()</code></a> -<dd> Substitutes g for x_v in the ADD for f. - -<dt> <a href="cuddAllDet.html#Cudd_addComputeCube" TARGET="MAIN"><code>Cudd_addComputeCube()</code></a> -<dd> Computes the cube of an array of ADD variables. - -<dt> <a href="cuddAllDet.html#Cudd_addConstrain" TARGET="MAIN"><code>Cudd_addConstrain()</code></a> -<dd> Computes f constrain c for ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_addConst" TARGET="MAIN"><code>Cudd_addConst()</code></a> -<dd> Returns the ADD for constant c. - -<dt> <a href="cuddAllDet.html#Cudd_addDiff" TARGET="MAIN"><code>Cudd_addDiff()</code></a> -<dd> Returns plusinfinity if f=g; returns min(f,g) if f!=g. - -<dt> <a href="cuddAllDet.html#Cudd_addDivide" TARGET="MAIN"><code>Cudd_addDivide()</code></a> -<dd> Integer and floating point division. - -<dt> <a href="cuddAllDet.html#Cudd_addEvalConst" TARGET="MAIN"><code>Cudd_addEvalConst()</code></a> -<dd> Checks whether ADD g is constant whenever ADD f is 1. - -<dt> <a href="cuddAllDet.html#Cudd_addExistAbstract" TARGET="MAIN"><code>Cudd_addExistAbstract()</code></a> -<dd> Existentially Abstracts all the variables in cube from f. - -<dt> <a href="cuddAllDet.html#Cudd_addFindMax" TARGET="MAIN"><code>Cudd_addFindMax()</code></a> -<dd> Finds the maximum discriminant of f. - -<dt> <a href="cuddAllDet.html#Cudd_addFindMin" TARGET="MAIN"><code>Cudd_addFindMin()</code></a> -<dd> Finds the minimum discriminant of f. - -<dt> <a href="cuddAllDet.html#Cudd_addGeneralVectorCompose" TARGET="MAIN"><code>Cudd_addGeneralVectorCompose()</code></a> -<dd> Composes an ADD with a vector of ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_addHamming" TARGET="MAIN"><code>Cudd_addHamming()</code></a> -<dd> Computes the Hamming distance ADD. - -<dt> <a href="cuddAllDet.html#Cudd_addHarwell" TARGET="MAIN"><code>Cudd_addHarwell()</code></a> -<dd> Reads in a matrix in the format of the Harwell-Boeing - benchmark suite. - -<dt> <a href="cuddAllDet.html#Cudd_addIteConstant" TARGET="MAIN"><code>Cudd_addIteConstant()</code></a> -<dd> Implements ITEconstant for ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_addIte" TARGET="MAIN"><code>Cudd_addIte()</code></a> -<dd> Implements ITE(f,g,h). - -<dt> <a href="cuddAllDet.html#Cudd_addIthBit" TARGET="MAIN"><code>Cudd_addIthBit()</code></a> -<dd> Extracts the i-th bit from an ADD. - -<dt> <a href="cuddAllDet.html#Cudd_addIthVar" TARGET="MAIN"><code>Cudd_addIthVar()</code></a> -<dd> Returns the ADD variable with index i. - -<dt> <a href="cuddAllDet.html#Cudd_addLeq" TARGET="MAIN"><code>Cudd_addLeq()</code></a> -<dd> Determines whether f is less than or equal to g. - -<dt> <a href="cuddAllDet.html#Cudd_addLog" TARGET="MAIN"><code>Cudd_addLog()</code></a> -<dd> Natural logarithm of an ADD. - -<dt> <a href="cuddAllDet.html#Cudd_addMatrixMultiply" TARGET="MAIN"><code>Cudd_addMatrixMultiply()</code></a> -<dd> Calculates the product of two matrices represented as - ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_addMaximum" TARGET="MAIN"><code>Cudd_addMaximum()</code></a> -<dd> Integer and floating point max. - -<dt> <a href="cuddAllDet.html#Cudd_addMinimum" TARGET="MAIN"><code>Cudd_addMinimum()</code></a> -<dd> Integer and floating point min. - -<dt> <a href="cuddAllDet.html#Cudd_addMinus" TARGET="MAIN"><code>Cudd_addMinus()</code></a> -<dd> Integer and floating point subtraction. - -<dt> <a href="cuddAllDet.html#Cudd_addMonadicApply" TARGET="MAIN"><code>Cudd_addMonadicApply()</code></a> -<dd> Applies op to the discriminants of f. - -<dt> <a href="cuddAllDet.html#Cudd_addNand" TARGET="MAIN"><code>Cudd_addNand()</code></a> -<dd> NAND of two 0-1 ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_addNegate" TARGET="MAIN"><code>Cudd_addNegate()</code></a> -<dd> Computes the additive inverse of an ADD. - -<dt> <a href="cuddAllDet.html#Cudd_addNewVarAtLevel" TARGET="MAIN"><code>Cudd_addNewVarAtLevel()</code></a> -<dd> Returns a new ADD variable at a specified level. - -<dt> <a href="cuddAllDet.html#Cudd_addNewVar" TARGET="MAIN"><code>Cudd_addNewVar()</code></a> -<dd> Returns a new ADD variable. - -<dt> <a href="cuddAllDet.html#Cudd_addNonSimCompose" TARGET="MAIN"><code>Cudd_addNonSimCompose()</code></a> -<dd> Composes an ADD with a vector of 0-1 ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_addNor" TARGET="MAIN"><code>Cudd_addNor()</code></a> -<dd> NOR of two 0-1 ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_addOneZeroMaximum" TARGET="MAIN"><code>Cudd_addOneZeroMaximum()</code></a> -<dd> Returns 1 if f > g and 0 otherwise. - -<dt> <a href="cuddAllDet.html#Cudd_addOrAbstract" TARGET="MAIN"><code>Cudd_addOrAbstract()</code></a> -<dd> Disjunctively abstracts all the variables in cube from the - 0-1 ADD f. - -<dt> <a href="cuddAllDet.html#Cudd_addOr" TARGET="MAIN"><code>Cudd_addOr()</code></a> -<dd> Disjunction of two 0-1 ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_addOuterSum" TARGET="MAIN"><code>Cudd_addOuterSum()</code></a> -<dd> Takes the minimum of a matrix and the outer sum of two vectors. - -<dt> <a href="cuddAllDet.html#Cudd_addPermute" TARGET="MAIN"><code>Cudd_addPermute()</code></a> -<dd> Permutes the variables of an ADD. - -<dt> <a href="cuddAllDet.html#Cudd_addPlus" TARGET="MAIN"><code>Cudd_addPlus()</code></a> -<dd> Integer and floating point addition. - -<dt> <a href="cuddAllDet.html#Cudd_addRead" TARGET="MAIN"><code>Cudd_addRead()</code></a> -<dd> Reads in a sparse matrix. - -<dt> <a href="cuddAllDet.html#Cudd_addResidue" TARGET="MAIN"><code>Cudd_addResidue()</code></a> -<dd> Builds an ADD for the residue modulo m of an n-bit - number. - -<dt> <a href="cuddAllDet.html#Cudd_addRestrict" TARGET="MAIN"><code>Cudd_addRestrict()</code></a> -<dd> ADD restrict according to Coudert and Madre's algorithm - (ICCAD90). - -<dt> <a href="cuddAllDet.html#Cudd_addRoundOff" TARGET="MAIN"><code>Cudd_addRoundOff()</code></a> -<dd> Rounds off the discriminants of an ADD. - -<dt> <a href="cuddAllDet.html#Cudd_addScalarInverse" TARGET="MAIN"><code>Cudd_addScalarInverse()</code></a> -<dd> Computes the scalar inverse of an ADD. - -<dt> <a href="cuddAllDet.html#Cudd_addSetNZ" TARGET="MAIN"><code>Cudd_addSetNZ()</code></a> -<dd> This operator sets f to the value of g wherever g != 0. - -<dt> <a href="cuddAllDet.html#Cudd_addSwapVariables" TARGET="MAIN"><code>Cudd_addSwapVariables()</code></a> -<dd> Swaps two sets of variables of the same size (x and y) in - the ADD f. - -<dt> <a href="cuddAllDet.html#Cudd_addThreshold" TARGET="MAIN"><code>Cudd_addThreshold()</code></a> -<dd> f if f>=g; 0 if f<g. - -<dt> <a href="cuddAllDet.html#Cudd_addTimesPlus" TARGET="MAIN"><code>Cudd_addTimesPlus()</code></a> -<dd> Calculates the product of two matrices represented as - ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_addTimes" TARGET="MAIN"><code>Cudd_addTimes()</code></a> -<dd> Integer and floating point multiplication. - -<dt> <a href="cuddAllDet.html#Cudd_addTriangle" TARGET="MAIN"><code>Cudd_addTriangle()</code></a> -<dd> Performs the triangulation step for the shortest path - computation. - -<dt> <a href="cuddAllDet.html#Cudd_addUnivAbstract" TARGET="MAIN"><code>Cudd_addUnivAbstract()</code></a> -<dd> Universally Abstracts all the variables in cube from f. - -<dt> <a href="cuddAllDet.html#Cudd_addVectorCompose" TARGET="MAIN"><code>Cudd_addVectorCompose()</code></a> -<dd> Composes an ADD with a vector of 0-1 ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_addWalsh" TARGET="MAIN"><code>Cudd_addWalsh()</code></a> -<dd> Generates a Walsh matrix in ADD form. - -<dt> <a href="cuddAllDet.html#Cudd_addXeqy" TARGET="MAIN"><code>Cudd_addXeqy()</code></a> -<dd> Generates an ADD for the function x==y. - -<dt> <a href="cuddAllDet.html#Cudd_addXnor" TARGET="MAIN"><code>Cudd_addXnor()</code></a> -<dd> XNOR of two 0-1 ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_addXor" TARGET="MAIN"><code>Cudd_addXor()</code></a> -<dd> XOR of two 0-1 ADDs. - -<dt> <a href="cuddAllDet.html#Cudd_bddAdjPermuteX" TARGET="MAIN"><code>Cudd_bddAdjPermuteX()</code></a> -<dd> Rearranges a set of variables in the BDD B. - -<dt> <a href="cuddAllDet.html#Cudd_bddAndAbstractLimit" TARGET="MAIN"><code>Cudd_bddAndAbstractLimit()</code></a> -<dd> Takes the AND of two BDDs and simultaneously abstracts the - variables in cube. Returns NULL if too many nodes are required. - -<dt> <a href="cuddAllDet.html#Cudd_bddAndAbstract" TARGET="MAIN"><code>Cudd_bddAndAbstract()</code></a> -<dd> Takes the AND of two BDDs and simultaneously abstracts the - variables in cube. - -<dt> <a href="cuddAllDet.html#Cudd_bddAndLimit" TARGET="MAIN"><code>Cudd_bddAndLimit()</code></a> -<dd> Computes the conjunction of two BDDs f and g. Returns - NULL if too many nodes are required. - -<dt> <a href="cuddAllDet.html#Cudd_bddAnd" TARGET="MAIN"><code>Cudd_bddAnd()</code></a> -<dd> Computes the conjunction of two BDDs f and g. - -<dt> <a href="cuddAllDet.html#Cudd_bddApproxConjDecomp" TARGET="MAIN"><code>Cudd_bddApproxConjDecomp()</code></a> -<dd> Performs two-way conjunctive decomposition of a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddApproxDisjDecomp" TARGET="MAIN"><code>Cudd_bddApproxDisjDecomp()</code></a> -<dd> Performs two-way disjunctive decomposition of a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddBindVar" TARGET="MAIN"><code>Cudd_bddBindVar()</code></a> -<dd> Prevents sifting of a variable. - -<dt> <a href="cuddAllDet.html#Cudd_bddBooleanDiff" TARGET="MAIN"><code>Cudd_bddBooleanDiff()</code></a> -<dd> Computes the boolean difference of f with respect to x. - -<dt> <a href="cuddAllDet.html#Cudd_bddCharToVect" TARGET="MAIN"><code>Cudd_bddCharToVect()</code></a> -<dd> Computes a vector whose image equals a non-zero function. - -<dt> <a href="cuddAllDet.html#Cudd_bddClippingAndAbstract" TARGET="MAIN"><code>Cudd_bddClippingAndAbstract()</code></a> -<dd> Approximates the conjunction of two BDDs f and g and - simultaneously abstracts the variables in cube. - -<dt> <a href="cuddAllDet.html#Cudd_bddClippingAnd" TARGET="MAIN"><code>Cudd_bddClippingAnd()</code></a> -<dd> Approximates the conjunction of two BDDs f and g. - -<dt> <a href="cuddAllDet.html#Cudd_bddClosestCube" TARGET="MAIN"><code>Cudd_bddClosestCube()</code></a> -<dd> Finds a cube of f at minimum Hamming distance from g. - -<dt> <a href="cuddAllDet.html#Cudd_bddCompose" TARGET="MAIN"><code>Cudd_bddCompose()</code></a> -<dd> Substitutes g for x_v in the BDD for f. - -<dt> <a href="cuddAllDet.html#Cudd_bddComputeCube" TARGET="MAIN"><code>Cudd_bddComputeCube()</code></a> -<dd> Computes the cube of an array of BDD variables. - -<dt> <a href="cuddAllDet.html#Cudd_bddConstrainDecomp" TARGET="MAIN"><code>Cudd_bddConstrainDecomp()</code></a> -<dd> BDD conjunctive decomposition as in McMillan's CAV96 paper. - -<dt> <a href="cuddAllDet.html#Cudd_bddConstrain" TARGET="MAIN"><code>Cudd_bddConstrain()</code></a> -<dd> Computes f constrain c. - -<dt> <a href="cuddAllDet.html#Cudd_bddCorrelationWeights" TARGET="MAIN"><code>Cudd_bddCorrelationWeights()</code></a> -<dd> Computes the correlation of f and g for given input - probabilities. - -<dt> <a href="cuddAllDet.html#Cudd_bddCorrelation" TARGET="MAIN"><code>Cudd_bddCorrelation()</code></a> -<dd> Computes the correlation of f and g. - -<dt> <a href="cuddAllDet.html#Cudd_bddExistAbstractLimit" TARGET="MAIN"><code>Cudd_bddExistAbstractLimit()</code></a> -<dd> Existentially abstracts all the variables in cube from f. - -<dt> <a href="cuddAllDet.html#Cudd_bddExistAbstract" TARGET="MAIN"><code>Cudd_bddExistAbstract()</code></a> -<dd> Existentially abstracts all the variables in cube from f. - -<dt> <a href="cuddAllDet.html#Cudd_bddGenConjDecomp" TARGET="MAIN"><code>Cudd_bddGenConjDecomp()</code></a> -<dd> Performs two-way conjunctive decomposition of a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddGenDisjDecomp" TARGET="MAIN"><code>Cudd_bddGenDisjDecomp()</code></a> -<dd> Performs two-way disjunctive decomposition of a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddIntersect" TARGET="MAIN"><code>Cudd_bddIntersect()</code></a> -<dd> Returns a function included in the intersection of f and g. - -<dt> <a href="cuddAllDet.html#Cudd_bddInterval" TARGET="MAIN"><code>Cudd_bddInterval()</code></a> -<dd> Generates a BDD for the function lowerB ≤ x ≤ upperB. - -<dt> <a href="cuddAllDet.html#Cudd_bddIsNsVar" TARGET="MAIN"><code>Cudd_bddIsNsVar()</code></a> -<dd> Checks whether a variable is next state. - -<dt> <a href="cuddAllDet.html#Cudd_bddIsPiVar" TARGET="MAIN"><code>Cudd_bddIsPiVar()</code></a> -<dd> Checks whether a variable is primary input. - -<dt> <a href="cuddAllDet.html#Cudd_bddIsPsVar" TARGET="MAIN"><code>Cudd_bddIsPsVar()</code></a> -<dd> Checks whether a variable is present state. - -<dt> <a href="cuddAllDet.html#Cudd_bddIsVarEssential" TARGET="MAIN"><code>Cudd_bddIsVarEssential()</code></a> -<dd> Determines whether a given variable is essential with a - given phase in a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddIsVarHardGroup" TARGET="MAIN"><code>Cudd_bddIsVarHardGroup()</code></a> -<dd> Checks whether a variable is set to be in a hard group. - -<dt> <a href="cuddAllDet.html#Cudd_bddIsVarToBeGrouped" TARGET="MAIN"><code>Cudd_bddIsVarToBeGrouped()</code></a> -<dd> Checks whether a variable is set to be grouped. - -<dt> <a href="cuddAllDet.html#Cudd_bddIsVarToBeUngrouped" TARGET="MAIN"><code>Cudd_bddIsVarToBeUngrouped()</code></a> -<dd> Checks whether a variable is set to be ungrouped. - -<dt> <a href="cuddAllDet.html#Cudd_bddIsop" TARGET="MAIN"><code>Cudd_bddIsop()</code></a> -<dd> Computes a BDD in the interval between L and U with a - simple sum-of-product cover. - -<dt> <a href="cuddAllDet.html#Cudd_bddIteConstant" TARGET="MAIN"><code>Cudd_bddIteConstant()</code></a> -<dd> Implements ITEconstant(f,g,h). - -<dt> <a href="cuddAllDet.html#Cudd_bddIteLimit" TARGET="MAIN"><code>Cudd_bddIteLimit()</code></a> -<dd> Implements ITE(f,g,h). Returns - NULL if too many nodes are required. - -<dt> <a href="cuddAllDet.html#Cudd_bddIterConjDecomp" TARGET="MAIN"><code>Cudd_bddIterConjDecomp()</code></a> -<dd> Performs two-way conjunctive decomposition of a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddIterDisjDecomp" TARGET="MAIN"><code>Cudd_bddIterDisjDecomp()</code></a> -<dd> Performs two-way disjunctive decomposition of a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddIte" TARGET="MAIN"><code>Cudd_bddIte()</code></a> -<dd> Implements ITE(f,g,h). - -<dt> <a href="cuddAllDet.html#Cudd_bddIthVar" TARGET="MAIN"><code>Cudd_bddIthVar()</code></a> -<dd> Returns the BDD variable with index i. - -<dt> <a href="cuddAllDet.html#Cudd_bddLICompaction" TARGET="MAIN"><code>Cudd_bddLICompaction()</code></a> -<dd> Performs safe minimization of a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddLargestPrimeUnate" TARGET="MAIN"><code>Cudd_bddLargestPrimeUnate()</code></a> -<dd> Find a largest prime of a unate function. - -<dt> <a href="cuddAllDet.html#Cudd_bddLeqUnless" TARGET="MAIN"><code>Cudd_bddLeqUnless()</code></a> -<dd> Tells whether f is less than of equal to G unless D is 1. - -<dt> <a href="cuddAllDet.html#Cudd_bddLeq" TARGET="MAIN"><code>Cudd_bddLeq()</code></a> -<dd> Determines whether f is less than or equal to g. - -<dt> <a href="cuddAllDet.html#Cudd_bddLiteralSetIntersection" TARGET="MAIN"><code>Cudd_bddLiteralSetIntersection()</code></a> -<dd> Computes the intesection of two sets of literals - represented as BDDs. - -<dt> <a href="cuddAllDet.html#Cudd_bddMakePrime" TARGET="MAIN"><code>Cudd_bddMakePrime()</code></a> -<dd> Expands cube to a prime implicant of f. - -<dt> <a href="cuddAllDet.html#Cudd_bddMaximallyExpand" TARGET="MAIN"><code>Cudd_bddMaximallyExpand()</code></a> -<dd> Expands lb to prime implicants of (f and ub). - -<dt> <a href="cuddAllDet.html#Cudd_bddMinimize" TARGET="MAIN"><code>Cudd_bddMinimize()</code></a> -<dd> Finds a small BDD that agrees with <code>f</code> over - <code>c</code>. - -<dt> <a href="cuddAllDet.html#Cudd_bddNPAnd" TARGET="MAIN"><code>Cudd_bddNPAnd()</code></a> -<dd> Computes f non-polluting-and g. - -<dt> <a href="cuddAllDet.html#Cudd_bddNand" TARGET="MAIN"><code>Cudd_bddNand()</code></a> -<dd> Computes the NAND of two BDDs f and g. - -<dt> <a href="cuddAllDet.html#Cudd_bddNewVarAtLevel" TARGET="MAIN"><code>Cudd_bddNewVarAtLevel()</code></a> -<dd> Returns a new BDD variable at a specified level. - -<dt> <a href="cuddAllDet.html#Cudd_bddNewVar" TARGET="MAIN"><code>Cudd_bddNewVar()</code></a> -<dd> Returns a new BDD variable. - -<dt> <a href="cuddAllDet.html#Cudd_bddNor" TARGET="MAIN"><code>Cudd_bddNor()</code></a> -<dd> Computes the NOR of two BDDs f and g. - -<dt> <a href="cuddAllDet.html#Cudd_bddOrLimit" TARGET="MAIN"><code>Cudd_bddOrLimit()</code></a> -<dd> Computes the disjunction of two BDDs f and g. Returns - NULL if too many nodes are required. - -<dt> <a href="cuddAllDet.html#Cudd_bddOr" TARGET="MAIN"><code>Cudd_bddOr()</code></a> -<dd> Computes the disjunction of two BDDs f and g. - -<dt> <a href="cuddAllDet.html#Cudd_bddPermute" TARGET="MAIN"><code>Cudd_bddPermute()</code></a> -<dd> Permutes the variables of a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddPickArbitraryMinterms" TARGET="MAIN"><code>Cudd_bddPickArbitraryMinterms()</code></a> -<dd> Picks k on-set minterms evenly distributed from given DD. - -<dt> <a href="cuddAllDet.html#Cudd_bddPickOneCube" TARGET="MAIN"><code>Cudd_bddPickOneCube()</code></a> -<dd> Picks one on-set cube randomly from the given DD. - -<dt> <a href="cuddAllDet.html#Cudd_bddPickOneMinterm" TARGET="MAIN"><code>Cudd_bddPickOneMinterm()</code></a> -<dd> Picks one on-set minterm randomly from the given DD. - -<dt> <a href="cuddAllDet.html#Cudd_bddPrintCover" TARGET="MAIN"><code>Cudd_bddPrintCover()</code></a> -<dd> Prints a sum of prime implicants of a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddReadPairIndex" TARGET="MAIN"><code>Cudd_bddReadPairIndex()</code></a> -<dd> Reads a corresponding pair index for a given index. - -<dt> <a href="cuddAllDet.html#Cudd_bddRead" TARGET="MAIN"><code>Cudd_bddRead()</code></a> -<dd> Reads in a graph (without labels) given as a list of arcs. - -<dt> <a href="cuddAllDet.html#Cudd_bddRealignDisable" TARGET="MAIN"><code>Cudd_bddRealignDisable()</code></a> -<dd> Disables realignment of ZDD order to BDD order. - -<dt> <a href="cuddAllDet.html#Cudd_bddRealignEnable" TARGET="MAIN"><code>Cudd_bddRealignEnable()</code></a> -<dd> Enables realignment of BDD order to ZDD order. - -<dt> <a href="cuddAllDet.html#Cudd_bddRealignmentEnabled" TARGET="MAIN"><code>Cudd_bddRealignmentEnabled()</code></a> -<dd> Tells whether the realignment of BDD order to ZDD order is - enabled. - -<dt> <a href="cuddAllDet.html#Cudd_bddResetVarToBeGrouped" TARGET="MAIN"><code>Cudd_bddResetVarToBeGrouped()</code></a> -<dd> Resets a variable not to be grouped. - -<dt> <a href="cuddAllDet.html#Cudd_bddRestrict" TARGET="MAIN"><code>Cudd_bddRestrict()</code></a> -<dd> BDD restrict according to Coudert and Madre's algorithm - (ICCAD90). - -<dt> <a href="cuddAllDet.html#Cudd_bddSetNsVar" TARGET="MAIN"><code>Cudd_bddSetNsVar()</code></a> -<dd> Sets a variable type to next state. - -<dt> <a href="cuddAllDet.html#Cudd_bddSetPairIndex" TARGET="MAIN"><code>Cudd_bddSetPairIndex()</code></a> -<dd> Sets a corresponding pair index for a given index. - -<dt> <a href="cuddAllDet.html#Cudd_bddSetPiVar" TARGET="MAIN"><code>Cudd_bddSetPiVar()</code></a> -<dd> Sets a variable type to primary input. - -<dt> <a href="cuddAllDet.html#Cudd_bddSetPsVar" TARGET="MAIN"><code>Cudd_bddSetPsVar()</code></a> -<dd> Sets a variable type to present state. - -<dt> <a href="cuddAllDet.html#Cudd_bddSetVarHardGroup" TARGET="MAIN"><code>Cudd_bddSetVarHardGroup()</code></a> -<dd> Sets a variable to be a hard group. - -<dt> <a href="cuddAllDet.html#Cudd_bddSetVarToBeGrouped" TARGET="MAIN"><code>Cudd_bddSetVarToBeGrouped()</code></a> -<dd> Sets a variable to be grouped. - -<dt> <a href="cuddAllDet.html#Cudd_bddSetVarToBeUngrouped" TARGET="MAIN"><code>Cudd_bddSetVarToBeUngrouped()</code></a> -<dd> Sets a variable to be ungrouped. - -<dt> <a href="cuddAllDet.html#Cudd_bddSqueeze" TARGET="MAIN"><code>Cudd_bddSqueeze()</code></a> -<dd> Finds a small BDD in a function interval. - -<dt> <a href="cuddAllDet.html#Cudd_bddSwapVariables" TARGET="MAIN"><code>Cudd_bddSwapVariables()</code></a> -<dd> Swaps two sets of variables of the same size (x and y) in - the BDD f. - -<dt> <a href="cuddAllDet.html#Cudd_bddTransfer" TARGET="MAIN"><code>Cudd_bddTransfer()</code></a> -<dd> Convert a BDD from a manager to another one. - -<dt> <a href="cuddAllDet.html#Cudd_bddUnbindVar" TARGET="MAIN"><code>Cudd_bddUnbindVar()</code></a> -<dd> Allows the sifting of a variable. - -<dt> <a href="cuddAllDet.html#Cudd_bddUnivAbstract" TARGET="MAIN"><code>Cudd_bddUnivAbstract()</code></a> -<dd> Universally abstracts all the variables in cube from f. - -<dt> <a href="cuddAllDet.html#Cudd_bddVarConjDecomp" TARGET="MAIN"><code>Cudd_bddVarConjDecomp()</code></a> -<dd> Performs two-way conjunctive decomposition of a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddVarDisjDecomp" TARGET="MAIN"><code>Cudd_bddVarDisjDecomp()</code></a> -<dd> Performs two-way disjunctive decomposition of a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_bddVarIsBound" TARGET="MAIN"><code>Cudd_bddVarIsBound()</code></a> -<dd> Tells whether a variable can be sifted. - -<dt> <a href="cuddAllDet.html#Cudd_bddVarIsDependent" TARGET="MAIN"><code>Cudd_bddVarIsDependent()</code></a> -<dd> Checks whether a variable is dependent on others in a - function. - -<dt> <a href="cuddAllDet.html#Cudd_bddVarMap" TARGET="MAIN"><code>Cudd_bddVarMap()</code></a> -<dd> Remaps the variables of a BDD using the default variable map. - -<dt> <a href="cuddAllDet.html#Cudd_bddVectorCompose" TARGET="MAIN"><code>Cudd_bddVectorCompose()</code></a> -<dd> Composes a BDD with a vector of BDDs. - -<dt> <a href="cuddAllDet.html#Cudd_bddXnorLimit" TARGET="MAIN"><code>Cudd_bddXnorLimit()</code></a> -<dd> Computes the exclusive NOR of two BDDs f and g. Returns - NULL if too many nodes are required. - -<dt> <a href="cuddAllDet.html#Cudd_bddXnor" TARGET="MAIN"><code>Cudd_bddXnor()</code></a> -<dd> Computes the exclusive NOR of two BDDs f and g. - -<dt> <a href="cuddAllDet.html#Cudd_bddXorExistAbstract" TARGET="MAIN"><code>Cudd_bddXorExistAbstract()</code></a> -<dd> Takes the exclusive OR of two BDDs and simultaneously abstracts the - variables in cube. - -<dt> <a href="cuddAllDet.html#Cudd_bddXor" TARGET="MAIN"><code>Cudd_bddXor()</code></a> -<dd> Computes the exclusive OR of two BDDs f and g. - -<dt> <a href="cuddAllDet.html#Cudd_tlcInfoFree" TARGET="MAIN"><code>Cudd_tlcInfoFree()</code></a> -<dd> Frees a DdTlcInfo Structure. - -<dt> <a href="cuddAllDet.html#Cudd_zddChange" TARGET="MAIN"><code>Cudd_zddChange()</code></a> -<dd> Substitutes a variable with its complement in a ZDD. - -<dt> <a href="cuddAllDet.html#Cudd_zddComplement" TARGET="MAIN"><code>Cudd_zddComplement()</code></a> -<dd> Computes a complement cover for a ZDD node. - -<dt> <a href="cuddAllDet.html#Cudd_zddCountDouble" TARGET="MAIN"><code>Cudd_zddCountDouble()</code></a> -<dd> Counts the number of minterms of a ZDD. - -<dt> <a href="cuddAllDet.html#Cudd_zddCountMinterm" TARGET="MAIN"><code>Cudd_zddCountMinterm()</code></a> -<dd> Counts the number of minterms of a ZDD. - -<dt> <a href="cuddAllDet.html#Cudd_zddCount" TARGET="MAIN"><code>Cudd_zddCount()</code></a> -<dd> Counts the number of minterms in a ZDD. - -<dt> <a href="cuddAllDet.html#Cudd_zddCoverPathToString" TARGET="MAIN"><code>Cudd_zddCoverPathToString()</code></a> -<dd> Converts a path of a ZDD representing a cover to a string. - -<dt> <a href="cuddAllDet.html#Cudd_zddDagSize" TARGET="MAIN"><code>Cudd_zddDagSize()</code></a> -<dd> Counts the number of nodes in a ZDD. - -<dt> <a href="cuddAllDet.html#Cudd_zddDiffConst" TARGET="MAIN"><code>Cudd_zddDiffConst()</code></a> -<dd> Performs the inclusion test for ZDDs (P implies Q). - -<dt> <a href="cuddAllDet.html#Cudd_zddDiff" TARGET="MAIN"><code>Cudd_zddDiff()</code></a> -<dd> Computes the difference of two ZDDs. - -<dt> <a href="cuddAllDet.html#Cudd_zddDivideF" TARGET="MAIN"><code>Cudd_zddDivideF()</code></a> -<dd> Modified version of Cudd_zddDivide. - -<dt> <a href="cuddAllDet.html#Cudd_zddDivide" TARGET="MAIN"><code>Cudd_zddDivide()</code></a> -<dd> Computes the quotient of two unate covers. - -<dt> <a href="cuddAllDet.html#Cudd_zddDumpDot" TARGET="MAIN"><code>Cudd_zddDumpDot()</code></a> -<dd> Writes a dot file representing the argument ZDDs. - -<dt> <a href="cuddAllDet.html#Cudd_zddFirstPath" TARGET="MAIN"><code>Cudd_zddFirstPath()</code></a> -<dd> Finds the first path of a ZDD. - -<dt> <a href="cuddAllDet.html#Cudd_zddIntersect" TARGET="MAIN"><code>Cudd_zddIntersect()</code></a> -<dd> Computes the intersection of two ZDDs. - -<dt> <a href="cuddAllDet.html#Cudd_zddIsop" TARGET="MAIN"><code>Cudd_zddIsop()</code></a> -<dd> Computes an ISOP in ZDD form from BDDs. - -<dt> <a href="cuddAllDet.html#Cudd_zddIte" TARGET="MAIN"><code>Cudd_zddIte()</code></a> -<dd> Computes the ITE of three ZDDs. - -<dt> <a href="cuddAllDet.html#Cudd_zddIthVar" TARGET="MAIN"><code>Cudd_zddIthVar()</code></a> -<dd> Returns the ZDD variable with index i. - -<dt> <a href="cuddAllDet.html#Cudd_zddNextPath" TARGET="MAIN"><code>Cudd_zddNextPath()</code></a> -<dd> Generates the next path of a ZDD. - -<dt> <a href="cuddAllDet.html#Cudd_zddPortFromBdd" TARGET="MAIN"><code>Cudd_zddPortFromBdd()</code></a> -<dd> Converts a BDD into a ZDD. - -<dt> <a href="cuddAllDet.html#Cudd_zddPortToBdd" TARGET="MAIN"><code>Cudd_zddPortToBdd()</code></a> -<dd> Converts a ZDD into a BDD. - -<dt> <a href="cuddAllDet.html#Cudd_zddPrintCover" TARGET="MAIN"><code>Cudd_zddPrintCover()</code></a> -<dd> Prints a sum of products from a ZDD representing a cover. - -<dt> <a href="cuddAllDet.html#Cudd_zddPrintDebug" TARGET="MAIN"><code>Cudd_zddPrintDebug()</code></a> -<dd> Prints to the standard output a ZDD and its statistics. - -<dt> <a href="cuddAllDet.html#Cudd_zddPrintMinterm" TARGET="MAIN"><code>Cudd_zddPrintMinterm()</code></a> -<dd> Prints a disjoint sum of product form for a ZDD. - -<dt> <a href="cuddAllDet.html#Cudd_zddPrintSubtable" TARGET="MAIN"><code>Cudd_zddPrintSubtable()</code></a> -<dd> Prints the ZDD table. - -<dt> <a href="cuddAllDet.html#Cudd_zddProduct" TARGET="MAIN"><code>Cudd_zddProduct()</code></a> -<dd> Computes the product of two covers represented by ZDDs. - -<dt> <a href="cuddAllDet.html#Cudd_zddReadNodeCount" TARGET="MAIN"><code>Cudd_zddReadNodeCount()</code></a> -<dd> Reports the number of nodes in ZDDs. - -<dt> <a href="cuddAllDet.html#Cudd_zddRealignDisable" TARGET="MAIN"><code>Cudd_zddRealignDisable()</code></a> -<dd> Disables realignment of ZDD order to BDD order. - -<dt> <a href="cuddAllDet.html#Cudd_zddRealignEnable" TARGET="MAIN"><code>Cudd_zddRealignEnable()</code></a> -<dd> Enables realignment of ZDD order to BDD order. - -<dt> <a href="cuddAllDet.html#Cudd_zddRealignmentEnabled" TARGET="MAIN"><code>Cudd_zddRealignmentEnabled()</code></a> -<dd> Tells whether the realignment of ZDD order to BDD order is - enabled. - -<dt> <a href="cuddAllDet.html#Cudd_zddReduceHeap" TARGET="MAIN"><code>Cudd_zddReduceHeap()</code></a> -<dd> Main dynamic reordering routine for ZDDs. - -<dt> <a href="cuddAllDet.html#Cudd_zddShuffleHeap" TARGET="MAIN"><code>Cudd_zddShuffleHeap()</code></a> -<dd> Reorders ZDD variables according to given permutation. - -<dt> <a href="cuddAllDet.html#Cudd_zddSubset0" TARGET="MAIN"><code>Cudd_zddSubset0()</code></a> -<dd> Computes the negative cofactor of a ZDD w.r.t. a variable. - -<dt> <a href="cuddAllDet.html#Cudd_zddSubset1" TARGET="MAIN"><code>Cudd_zddSubset1()</code></a> -<dd> Computes the positive cofactor of a ZDD w.r.t. a variable. - -<dt> <a href="cuddAllDet.html#Cudd_zddSupport" TARGET="MAIN"><code>Cudd_zddSupport()</code></a> -<dd> Finds the variables on which a ZDD depends. - -<dt> <a href="cuddAllDet.html#Cudd_zddSymmProfile" TARGET="MAIN"><code>Cudd_zddSymmProfile()</code></a> -<dd> Prints statistics on symmetric ZDD variables. - -<dt> <a href="cuddAllDet.html#Cudd_zddUnateProduct" TARGET="MAIN"><code>Cudd_zddUnateProduct()</code></a> -<dd> Computes the product of two unate covers. - -<dt> <a href="cuddAllDet.html#Cudd_zddUnion" TARGET="MAIN"><code>Cudd_zddUnion()</code></a> -<dd> Computes the union of two ZDDs. - -<dt> <a href="cuddAllDet.html#Cudd_zddVarsFromBddVars" TARGET="MAIN"><code>Cudd_zddVarsFromBddVars()</code></a> -<dd> Creates one or more ZDD variables for each BDD variable. - -<dt> <a href="cuddAllDet.html#Cudd_zddWeakDivF" TARGET="MAIN"><code>Cudd_zddWeakDivF()</code></a> -<dd> Modified version of Cudd_zddWeakDiv. - -<dt> <a href="cuddAllDet.html#Cudd_zddWeakDiv" TARGET="MAIN"><code>Cudd_zddWeakDiv()</code></a> -<dd> Applies weak division to two covers. - -</dl> - -<hr> - -Last updated on 20120204 17h33 -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddExtDet.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddExtDet.html deleted file mode 100644 index f23e11e4f..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddExtDet.html +++ /dev/null @@ -1,4450 +0,0 @@ -<HTML> -<HEAD><TITLE>The cudd package</TITLE></HEAD> -<BODY> - -<DL> -<dt><pre> -<A NAME="CUDD_VALUE_TYPE *�value�"></A> - <I></I> -<B>CUDD_VALUE_TYPE *�value�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE *�value�"></A> - <I></I> -<B>CUDD_VALUE_TYPE *�value�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE �c�"></A> - <I></I> -<B>CUDD_VALUE_TYPE �c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE �ep�"></A> - <I></I> -<B>CUDD_VALUE_TYPE �ep�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE �upper�"></A> - <I></I> -<B>CUDD_VALUE_TYPE �upper�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE �value�"></A> - <I></I> -<B>CUDD_VALUE_TYPE �value�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="CUDD_VALUE_TYPE �value�"></A> - <I></I> -<B>CUDD_VALUE_TYPE �value�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_AggregationType �gc�"></A> - <I></I> -<B>Cudd_AggregationType �gc�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_HookType �where�"></A> - <I></I> -<B>Cudd_HookType �where�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_HookType �where�"></A> - <I></I> -<B>Cudd_HookType �where�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_HookType �where�"></A> - <I></I> -<B>Cudd_HookType �where�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_ReorderingType *�method�"></A> - <I></I> -<B>Cudd_ReorderingType *�method�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_ReorderingType *�method�"></A> - <I></I> -<B>Cudd_ReorderingType *�method�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_ReorderingType �method�"></A> - <I></I> -<B>Cudd_ReorderingType �method�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="Cudd_ReorderingType �method�"></A> - <I></I> -<B>Cudd_ReorderingType �method�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DD_PRFP �Pifunc�function used to build Pi if it is NULL"></A> - <I></I> -<B>DD_PRFP �Pifunc�function used to build Pi if it is NULL</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaDigit �literal�"></A> - <I></I> -<B>DdApaDigit �literal�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �b�"></A> - <I></I> -<B>DdApaNumber �b�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �dest�"></A> - <I></I> -<B>DdApaNumber �dest�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �diff�"></A> - <I></I> -<B>DdApaNumber �diff�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �number�"></A> - <I></I> -<B>DdApaNumber �number�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �number�"></A> - <I></I> -<B>DdApaNumber �number�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �quotient�"></A> - <I></I> -<B>DdApaNumber �quotient�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �quotient�"></A> - <I></I> -<B>DdApaNumber �quotient�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �second�"></A> - <I></I> -<B>DdApaNumber �second�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdApaNumber �sum�"></A> - <I></I> -<B>DdApaNumber �sum�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdGen *�gen�"></A> - <I></I> -<B>DdGen *�gen�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdGen *�gen�"></A> - <I></I> -<B>DdGen *�gen�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�dd�"></A> - <I></I> -<B>DdManager *�dd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�manager�"></A> - <I></I> -<B>DdManager *�manager�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�table�"></A> - <I></I> -<B>DdManager *�table�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�table�"></A> - <I></I> -<B>DdManager *�table�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�table�"></A> - <I></I> -<B>DdManager *�table�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�table�"></A> - <I></I> -<B>DdManager *�table�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdManager *�unique�"></A> - <I></I> -<B>DdManager *�unique�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�conjuncts�address of the array of conjuncts"></A> - <I></I> -<B>DdNode ***�conjuncts�address of the array of conjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�conjuncts�address of the array of conjuncts"></A> - <I></I> -<B>DdNode ***�conjuncts�address of the array of conjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�conjuncts�address of the array of conjuncts"></A> - <I></I> -<B>DdNode ***�conjuncts�address of the array of conjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�conjuncts�address of the first factor"></A> - <I></I> -<B>DdNode ***�conjuncts�address of the first factor</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�disjuncts�address of the array of the disjuncts"></A> - <I></I> -<B>DdNode ***�disjuncts�address of the array of the disjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�disjuncts�address of the array of the disjuncts"></A> - <I></I> -<B>DdNode ***�disjuncts�address of the array of the disjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�disjuncts�address of the array of the disjuncts"></A> - <I></I> -<B>DdNode ***�disjuncts�address of the array of the disjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode ***�disjuncts�address of the array of the disjuncts"></A> - <I></I> -<B>DdNode ***�disjuncts�address of the array of the disjuncts</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�g�"></A> - <I></I> -<B>DdNode **�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�node�"></A> - <I></I> -<B>DdNode **�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�node�"></A> - <I></I> -<B>DdNode **�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�onlyG�cube of variables only in g"></A> - <I></I> -<B>DdNode **�onlyG�cube of variables only in g</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�vectorOff�"></A> - <I></I> -<B>DdNode **�vectorOff�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�vector�"></A> - <I></I> -<B>DdNode **�vector�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�vector�"></A> - <I></I> -<B>DdNode **�vector�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�vector�"></A> - <I></I> -<B>DdNode **�vector�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�y�array of y variables"></A> - <I></I> -<B>DdNode **�y�array of y variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�y�array of y variables"></A> - <I></I> -<B>DdNode **�y�array of y variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�y�array of y variables"></A> - <I></I> -<B>DdNode **�y�array of y variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�y�array of y variables"></A> - <I></I> -<B>DdNode **�y�array of y variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�y�array of y variables"></A> - <I></I> -<B>DdNode **�y�array of y variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�zdd_I�"></A> - <I></I> -<B>DdNode **�zdd_I�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�z�array of z variables"></A> - <I></I> -<B>DdNode **�z�array of z variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode **�z�array of z variables"></A> - <I></I> -<B>DdNode **�z�array of z variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�B�"></A> - <I></I> -<B>DdNode *�B�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�B�"></A> - <I></I> -<B>DdNode *�B�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�D�"></A> - <I></I> -<B>DdNode *�D�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�D�"></A> - <I></I> -<B>DdNode *�D�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�P�"></A> - <I></I> -<B>DdNode *�P�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�P�"></A> - <I></I> -<B>DdNode *�P�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�Q�"></A> - <I></I> -<B>DdNode *�Q�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�Q�"></A> - <I></I> -<B>DdNode *�Q�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�Q�"></A> - <I></I> -<B>DdNode *�Q�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�Q�"></A> - <I></I> -<B>DdNode *�Q�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�U�"></A> - <I></I> -<B>DdNode *�U�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�Y�"></A> - <I></I> -<B>DdNode *�Y�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�bck�"></A> - <I></I> -<B>DdNode *�bck�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�cube�"></A> - <I></I> -<B>DdNode *�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�"></A> - <I></I> -<B>DdNode *�c�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�c�constraint (care set)"></A> - <I></I> -<B>DdNode *�c�constraint (care set)</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�epsilon�"></A> - <I></I> -<B>DdNode *�epsilon�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�"></A> - <I></I> -<B>DdNode *�f�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�DD whose support is sought"></A> - <I></I> -<B>DdNode *�f�DD whose support is sought</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�DD whose support is sought"></A> - <I></I> -<B>DdNode *�f�DD whose support is sought</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�DD whose support size is sought"></A> - <I></I> -<B>DdNode *�f�DD whose support size is sought</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�ZDD whose support is sought"></A> - <I></I> -<B>DdNode *�f�ZDD whose support is sought</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�function against which to expand"></A> - <I></I> -<B>DdNode *�f�function against which to expand</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�function in which to remap variables"></A> - <I></I> -<B>DdNode *�f�function in which to remap variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�f�function of which the cube is to be made a prime"></A> - <I></I> -<B>DdNode *�f�function of which the cube is to be made a prime</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�"></A> - <I></I> -<B>DdNode *�g�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�g�second operand"></A> - <I></I> -<B>DdNode *�g�second operand</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�h�"></A> - <I></I> -<B>DdNode *�h�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�h�"></A> - <I></I> -<B>DdNode *�h�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�h�"></A> - <I></I> -<B>DdNode *�h�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�h�"></A> - <I></I> -<B>DdNode *�h�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�h�"></A> - <I></I> -<B>DdNode *�h�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�node�"></A> - <I></I> -<B>DdNode *�node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�n�"></A> - <I></I> -<B>DdNode *�n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�n�"></A> - <I></I> -<B>DdNode *�n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�n�"></A> - <I></I> -<B>DdNode *�n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�n�"></A> - <I></I> -<B>DdNode *�n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�n�"></A> - <I></I> -<B>DdNode *�n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�p_node�"></A> - <I></I> -<B>DdNode *�p_node�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�phaseBdd�cube of the phases"></A> - <I></I> -<B>DdNode *�phaseBdd�cube of the phases</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�u�"></A> - <I></I> -<B>DdNode *�u�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�u�upper bound"></A> - <I></I> -<B>DdNode *�u�upper bound</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdNode *�var�variable"></A> - <I></I> -<B>DdNode *�var�variable</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="DdTlcInfo *�t�"></A> - <I></I> -<B>DdTlcInfo *�t�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="EpDouble *�epd�"></A> - <I></I> -<B>EpDouble *�epd�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�"></A> - <I></I> -<B>FILE *�fp�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�"></A> - <I></I> -<B>FILE *�fp�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�"></A> - <I></I> -<B>FILE *�fp�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�"></A> - <I></I> -<B>FILE *�fp�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�"></A> - <I></I> -<B>FILE *�fp�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�pointer to the dump file"></A> - <I></I> -<B>FILE *�fp�pointer to the dump file</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�pointer to the dump file"></A> - <I></I> -<B>FILE *�fp�pointer to the dump file</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�pointer to the dump file"></A> - <I></I> -<B>FILE *�fp�pointer to the dump file</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�pointer to the dump file"></A> - <I></I> -<B>FILE *�fp�pointer to the dump file</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="FILE *�fp�pointer to the dump file"></A> - <I></I> -<B>FILE *�fp�pointer to the dump file</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="MtrNode *�tree�"></A> - <I></I> -<B>MtrNode *�tree�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="MtrNode *�tree�"></A> - <I></I> -<B>MtrNode *�tree�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="char *�string�"></A> - <I></I> -<B>char *�string�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="char *�str�pointer to string to use if != NULL"></A> - <I></I> -<B>char *�str�pointer to string to use if != NULL</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double *�prob�"></A> - <I></I> -<B>double *�prob�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �mg�"></A> - <I></I> -<B>double �mg�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �mg�"></A> - <I></I> -<B>double �mg�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �m�"></A> - <I></I> -<B>double �m�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality0�minimum improvement for accepted changes when b=0"></A> - <I></I> -<B>double �quality0�minimum improvement for accepted changes when b=0</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality0�minimum improvement for accepted changes when b=0"></A> - <I></I> -<B>double �quality0�minimum improvement for accepted changes when b=0</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality�minimum improvement for accepted changes"></A> - <I></I> -<B>double �quality�minimum improvement for accepted changes</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality�minimum improvement for accepted changes"></A> - <I></I> -<B>double �quality�minimum improvement for accepted changes</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality�minimum improvement for accepted changes"></A> - <I></I> -<B>double �quality�minimum improvement for accepted changes</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="double �quality�minimum improvement for accepted changes"></A> - <I></I> -<B>double �quality�minimum improvement for accepted changes</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int **�cube�"></A> - <I></I> -<B>int **�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int **�cube�"></A> - <I></I> -<B>int **�cube�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int **�indices�array containing (on return) the indices"></A> - <I></I> -<B>int **�indices�array containing (on return) the indices</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int **�indices�array containing (on return) the indices"></A> - <I></I> -<B>int **�indices�array containing (on return) the indices</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int **�path�"></A> - <I></I> -<B>int **�path�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int **�path�"></A> - <I></I> -<B>int **�path�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�array�"></A> - <I></I> -<B>int *�array�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�array�"></A> - <I></I> -<B>int *�array�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�digits�"></A> - <I></I> -<B>int *�digits�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�distance�"></A> - <I></I> -<B>int *�distance�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�inputs�"></A> - <I></I> -<B>int *�inputs�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�length�"></A> - <I></I> -<B>int *�length�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�length�"></A> - <I></I> -<B>int *�length�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�permutation�required variable permutation"></A> - <I></I> -<B>int *�permutation�required variable permutation</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�permutation�required variable permutation"></A> - <I></I> -<B>int *�permutation�required variable permutation</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�permut�"></A> - <I></I> -<B>int *�permut�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�permut�"></A> - <I></I> -<B>int *�permut�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�phase2�"></A> - <I></I> -<B>int *�phase2�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int *�weight�"></A> - <I></I> -<B>int *�weight�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �N�"></A> - <I></I> -<B>int �N�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �amount�"></A> - <I></I> -<B>int �amount�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �arcviolation�"></A> - <I></I> -<B>int �arcviolation�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �binaryDigits�"></A> - <I></I> -<B>int �binaryDigits�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �bit�"></A> - <I></I> -<B>int �bit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �bit�"></A> - <I></I> -<B>int �bit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �cycle�"></A> - <I></I> -<B>int �cycle�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �digits�"></A> - <I></I> -<B>int �digits�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �direction�under (0) or over (1) approximation"></A> - <I></I> -<B>int �direction�under (0) or over (1) approximation</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �direction�under (0) or over (1) approximation"></A> - <I></I> -<B>int �direction�under (0) or over (1) approximation</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �hardlimit�flag: 1 if threshold is a hard limit"></A> - <I></I> -<B>int �hardlimit�flag: 1 if threshold is a hard limit</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �hardlimit�flag: 1 if threshold is a hard limit"></A> - <I></I> -<B>int �hardlimit�flag: 1 if threshold is a hard limit</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�"></A> - <I></I> -<B>int �index�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �index�variable index"></A> - <I></I> -<B>int �index�variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �i�"></A> - <I></I> -<B>int �i�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �k�number of minterms to find"></A> - <I></I> -<B>int �k�number of minterms to find</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �level�"></A> - <I></I> -<B>int �level�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �level�"></A> - <I></I> -<B>int �level�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �minsize�bound below which no reordering occurs"></A> - <I></I> -<B>int �minsize�bound below which no reordering occurs</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �minsize�bound below which no reordering occurs"></A> - <I></I> -<B>int �minsize�bound below which no reordering occurs</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �multiplicity�how many ZDD variables are created for each BDD variable"></A> - <I></I> -<B>int �multiplicity�how many ZDD variables are created for each BDD variable</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �mvars�size of <code>maskVars</code>"></A> - <I></I> -<B>int �mvars�size of <code>maskVars</code></B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �mv�0: blif, 1: blif-MV"></A> - <I></I> -<B>int �mv�0: blif, 1: blif-MV</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �mv�0: blif, 1: blif-MV"></A> - <I></I> -<B>int �mv�0: blif, 1: blif-MV</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nVars�"></A> - <I></I> -<B>int �nVars�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �numberXovers�"></A> - <I></I> -<B>int �numberXovers�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nvars�"></A> - <I></I> -<B>int �nvars�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nvars�"></A> - <I></I> -<B>int �nvars�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nvars�"></A> - <I></I> -<B>int �nvars�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nvars�size of the support of f"></A> - <I></I> -<B>int �nvars�size of the support of f</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nz�"></A> - <I></I> -<B>int �nz�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nz�"></A> - <I></I> -<B>int �nz�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �nz�"></A> - <I></I> -<B>int �nz�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�"></A> - <I></I> -<B>int �n�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�length of both arrays"></A> - <I></I> -<B>int �n�length of both arrays</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�numbers of unknowns"></A> - <I></I> -<B>int �n�numbers of unknowns</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�numbers of unknowns"></A> - <I></I> -<B>int �n�numbers of unknowns</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�size of <code>vars</code>"></A> - <I></I> -<B>int �n�size of <code>vars</code></B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�size of the array"></A> - <I></I> -<B>int �n�size of the array</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�size of the array"></A> - <I></I> -<B>int �n�size of the array</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �n�size of the array"></A> - <I></I> -<B>int �n�size of the array</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �pairIndex�corresponding variable index"></A> - <I></I> -<B>int �pairIndex�corresponding variable index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �path�"></A> - <I></I> -<B>int �path�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �phase�"></A> - <I></I> -<B>int �phase�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �phase�1: positive; 0: negative"></A> - <I></I> -<B>int �phase�1: positive; 0: negative</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �populationSize�"></A> - <I></I> -<B>int �populationSize�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �power�"></A> - <I></I> -<B>int �power�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �precision�"></A> - <I></I> -<B>int �precision�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �precision�"></A> - <I></I> -<B>int �precision�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �pr�"></A> - <I></I> -<B>int �pr�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �pr�"></A> - <I></I> -<B>int �pr�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �pr�verbosity level"></A> - <I></I> -<B>int �pr�verbosity level</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �pr�verbosity level"></A> - <I></I> -<B>int �pr�verbosity level</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �recomb�"></A> - <I></I> -<B>int �recomb�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �sms�"></A> - <I></I> -<B>int �sms�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �smv�"></A> - <I></I> -<B>int �smv�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �symmviolation�"></A> - <I></I> -<B>int �symmviolation�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �sy�step of column variables"></A> - <I></I> -<B>int �sy�step of column variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �sy�step of column variables"></A> - <I></I> -<B>int �sy�step of column variables</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �threshold�maximum number of nodes in the subset"></A> - <I></I> -<B>int �threshold�maximum number of nodes in the subset</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �threshold�maximum number of nodes in the subset"></A> - <I></I> -<B>int �threshold�maximum number of nodes in the subset</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �threshold�maximum number of nodes in the superset"></A> - <I></I> -<B>int �threshold�maximum number of nodes in the superset</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �threshold�maximum number of nodes in the superset"></A> - <I></I> -<B>int �threshold�maximum number of nodes in the superset</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �top�index of top variable"></A> - <I></I> -<B>int �top�index of top variable</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �upperBound�distance above which an approximate answer is OK"></A> - <I></I> -<B>int �upperBound�distance above which an approximate answer is OK</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �upper�"></A> - <I></I> -<B>int �upper�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �upper�"></A> - <I></I> -<B>int �upper�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �var�"></A> - <I></I> -<B>int �var�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �var�"></A> - <I></I> -<B>int �var�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �var�"></A> - <I></I> -<B>int �var�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �v�"></A> - <I></I> -<B>int �v�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �v�"></A> - <I></I> -<B>int �v�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �x�"></A> - <I></I> -<B>int �x�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="int �y�column index"></A> - <I></I> -<B>int �y�column index</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="long �seed�"></A> - <I></I> -<B>long �seed�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="long �size�size of the allocation that failed"></A> - <I></I> -<B>long �size�size of the allocation that failed</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �factor�"></A> - <I></I> -<B>unsigned int �factor�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �hr�"></A> - <I></I> -<B>unsigned int �hr�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �limit�"></A> - <I></I> -<B>unsigned int �limit�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �lut�"></A> - <I></I> -<B>unsigned int �lut�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �maxLive�"></A> - <I></I> -<B>unsigned int �maxLive�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �mc�"></A> - <I></I> -<B>unsigned int �mc�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �mr�"></A> - <I></I> -<B>unsigned int �mr�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �next�"></A> - <I></I> -<B>unsigned int �next�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �p�"></A> - <I></I> -<B>unsigned int �p�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �secondDen�"></A> - <I></I> -<B>unsigned int �secondDen�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �type�MTR_DEFAULT or MTR_FIXED"></A> - <I></I> -<B>unsigned int �type�MTR_DEFAULT or MTR_FIXED</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �type�MTR_DEFAULT or MTR_FIXED"></A> - <I></I> -<B>unsigned int �type�MTR_DEFAULT or MTR_FIXED</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned int �upperB�upper bound"></A> - <I></I> -<B>unsigned int �upperB�upper bound</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned long �increase�"></A> - <I></I> -<B>unsigned long �increase�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned long �maxMemory�"></A> - <I></I> -<B>unsigned long �maxMemory�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned long �maxMemory�target maximum memory occupation"></A> - <I></I> -<B>unsigned long �maxMemory�target maximum memory occupation</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned long �st�"></A> - <I></I> -<B>unsigned long �st�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="unsigned long �tl�"></A> - <I></I> -<B>unsigned long �tl�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="void *�data�"></A> - <I></I> -<B>void *�data�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="void *�data�"></A> - <I></I> -<B>void *�data�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="void *�data�"></A> - <I></I> -<B>void *�data�</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - -<dt><pre> -<A NAME="��"></A> - <I></I> -<B>��</B>( - <b></b> <i></i> -) -</pre> -<dd> -<p> - - -</DL> -<HR> -Last updated on 20120204 17h33 -</BODY></HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddIntro.css b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddIntro.css deleted file mode 100644 index d1824aff4..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddIntro.css +++ /dev/null @@ -1,30 +0,0 @@ -/* Century Schoolbook font is very similar to Computer Modern Math: cmmi */ -.MATH { font-family: "Century Schoolbook", serif; } -.MATH I { font-family: "Century Schoolbook", serif; font-style: italic } -.BOLDMATH { font-family: "Century Schoolbook", serif; font-weight: bold } - -/* implement both fixed-size and relative sizes */ -SMALL.XTINY { font-size : xx-small } -SMALL.TINY { font-size : x-small } -SMALL.SCRIPTSIZE { font-size : smaller } -SMALL.FOOTNOTESIZE { font-size : small } -SMALL.SMALL { } -BIG.LARGE { } -BIG.XLARGE { font-size : large } -BIG.XXLARGE { font-size : x-large } -BIG.HUGE { font-size : larger } -BIG.XHUGE { font-size : xx-large } - -/* heading styles */ -H1 { } -H2 { } -H3 { } -H4 { } -H5 { } - -/* mathematics styles */ -DIV.displaymath { } /* math displays */ -TD.eqno { } /* equation-number cells */ - - -/* document-specific styles come next */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddIntro.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddIntro.html deleted file mode 100644 index e74c4fff5..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddIntro.html +++ /dev/null @@ -1,219 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> - -<!--Converted with LaTeX2HTML 2008 (1.71) -original version by: Nikos Drakos, CBLU, University of Leeds -* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan -* with significant contributions from: - Jens Lippmann, Marek Rouchal, Martin Wilck and others --> -<HTML> -<HEAD> -<TITLE>CUDD: CU Decision Diagram Package -Release 2.5.0</TITLE> -<META NAME="description" CONTENT="CUDD: CU Decision Diagram Package -Release 2.5.0"> -<META NAME="keywords" CONTENT="cuddIntro"> -<META NAME="resource-type" CONTENT="document"> -<META NAME="distribution" CONTENT="global"> - -<META NAME="Generator" CONTENT="LaTeX2HTML v2008"> -<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> - -<LINK REL="STYLESHEET" HREF="cuddIntro.css"> - -<LINK REL="next" HREF="node1.html"> -</HEAD> - -<BODY > -<!--Navigation Panel--> -<A NAME="tex2html14" - HREF="node1.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up_g.png"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev_g.png"> -<A NAME="tex2html12" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html15" - HREF="node1.html">Introduction</A> - <B> <A NAME="tex2html13" - HREF="node8.html">Index</A></B> -<BR> -<BR> -<!--End of Navigation Panel--> - -<H1 ALIGN="CENTER">CUDD: CU Decision Diagram Package -<BR> -Release 2.5.0</H1> -<DIV> - -<P ALIGN="CENTER"><STRONG>Fabio Somenzi</STRONG></P> -<P ALIGN="CENTER"><I>Department of Electrical, Computer, and Energy Engineering</I></P> -<P ALIGN="LEFT"><SMALL>University of Colorado at Boulder</SMALL></P> -</DIV> - -<P> -<BR><HR> -<!--Table of Child-Links--> -<A NAME="CHILD_LINKS"></A> - -<UL> -<LI><A NAME="tex2html16" - HREF="node1.html">Introduction</A> -<LI><A NAME="tex2html17" - HREF="node2.html">How to Get CUDD</A> -<UL> -<LI><A NAME="tex2html18" - HREF="node2.html#SECTION00021000000000000000">The CUDD Package</A> -<LI><A NAME="tex2html19" - HREF="node2.html#SECTION00022000000000000000">CUDD Friends</A> -</UL> -<BR> -<LI><A NAME="tex2html20" - HREF="node3.html">User's Manual</A> -<UL> -<LI><A NAME="tex2html21" - HREF="node3.html#SECTION00031000000000000000">Compiling and Linking</A> -<LI><A NAME="tex2html22" - HREF="node3.html#SECTION00032000000000000000">Basic Data Structures</A> -<UL> -<LI><A NAME="tex2html23" - HREF="node3.html#SECTION00032100000000000000">Nodes</A> -<LI><A NAME="tex2html24" - HREF="node3.html#SECTION00032200000000000000">The Manager</A> -<LI><A NAME="tex2html25" - HREF="node3.html#SECTION00032300000000000000">Cache</A> -</UL> -<LI><A NAME="tex2html26" - HREF="node3.html#SECTION00033000000000000000">Initializing and Shutting Down a DdManager</A> -<LI><A NAME="tex2html27" - HREF="node3.html#SECTION00034000000000000000">Setting Parameters</A> -<LI><A NAME="tex2html28" - HREF="node3.html#SECTION00035000000000000000">Constant Functions</A> -<UL> -<LI><A NAME="tex2html29" - HREF="node3.html#SECTION00035100000000000000">One, Logic Zero, and Arithmetic Zero</A> -<LI><A NAME="tex2html30" - HREF="node3.html#SECTION00035200000000000000">Predefined Constants</A> -<LI><A NAME="tex2html31" - HREF="node3.html#SECTION00035300000000000000">Background</A> -<LI><A NAME="tex2html32" - HREF="node3.html#SECTION00035400000000000000">New Constants</A> -</UL> -<LI><A NAME="tex2html33" - HREF="node3.html#SECTION00036000000000000000">Creating Variables</A> -<UL> -<LI><A NAME="tex2html34" - HREF="node3.html#SECTION00036100000000000000">New BDD and ADD Variables</A> -<LI><A NAME="tex2html35" - HREF="node3.html#SECTION00036200000000000000">New ZDD Variables</A> -</UL> -<LI><A NAME="tex2html36" - HREF="node3.html#SECTION00037000000000000000">Basic BDD Manipulation</A> -<LI><A NAME="tex2html37" - HREF="node3.html#SECTION00038000000000000000">Basic ADD Manipulation</A> -<LI><A NAME="tex2html38" - HREF="node3.html#SECTION00039000000000000000">Basic ZDD Manipulation</A> -<LI><A NAME="tex2html39" - HREF="node3.html#SECTION000310000000000000000">Converting ADDs to BDDs and Vice Versa</A> -<LI><A NAME="tex2html40" - HREF="node3.html#SECTION000311000000000000000">Converting BDDs to ZDDs and Vice Versa</A> -<LI><A NAME="tex2html41" - HREF="node3.html#SECTION000312000000000000000">Variable Reordering for BDDs and ADDs</A> -<LI><A NAME="tex2html42" - HREF="node3.html#SECTION000313000000000000000">Grouping Variables</A> -<LI><A NAME="tex2html43" - HREF="node3.html#SECTION000314000000000000000">Variable Reordering for ZDDs</A> -<LI><A NAME="tex2html44" - HREF="node3.html#SECTION000315000000000000000">Keeping Consistent Variable Orders for BDDs and ZDDs</A> -<LI><A NAME="tex2html45" - HREF="node3.html#SECTION000316000000000000000">Hooks</A> -<LI><A NAME="tex2html46" - HREF="node3.html#SECTION000317000000000000000">Timeouts and Limits</A> -<LI><A NAME="tex2html47" - HREF="node3.html#SECTION000318000000000000000">The SIS/VIS Interface</A> -<UL> -<LI><A NAME="tex2html48" - HREF="node3.html#SECTION000318100000000000000">Using the CUDD Package in SIS</A> -</UL> -<LI><A NAME="tex2html49" - HREF="node3.html#SECTION000319000000000000000">Writing Decision Diagrams to a File</A> -<LI><A NAME="tex2html50" - HREF="node3.html#SECTION000320000000000000000">Saving and Restoring BDDs</A> -</UL> -<BR> -<LI><A NAME="tex2html51" - HREF="node4.html">Programmer's Manual</A> -<UL> -<LI><A NAME="tex2html52" - HREF="node4.html#SECTION00041000000000000000">Compiling and Linking</A> -<LI><A NAME="tex2html53" - HREF="node4.html#SECTION00042000000000000000">Reference Counts</A> -<UL> -<LI><A NAME="tex2html54" - HREF="node4.html#SECTION00042100000000000000">NULL Return Values</A> -<LI><A NAME="tex2html55" - HREF="node4.html#SECTION00042200000000000000"><I>Cudd_RecursiveDeref</I> vs. <I>Cudd_Deref</I></A> -<LI><A NAME="tex2html56" - HREF="node4.html#SECTION00042300000000000000">When Increasing the Reference Count is Unnecessary</A> -<LI><A NAME="tex2html57" - HREF="node4.html#SECTION00042400000000000000">Saturating Increments and Decrements</A> -</UL> -<LI><A NAME="tex2html58" - HREF="node4.html#SECTION00043000000000000000">Complement Arcs</A> -<LI><A NAME="tex2html59" - HREF="node4.html#SECTION00044000000000000000">The Cache</A> -<UL> -<LI><A NAME="tex2html60" - HREF="node4.html#SECTION00044100000000000000">Cache Sizing</A> -<LI><A NAME="tex2html61" - HREF="node4.html#SECTION00044200000000000000">Local Caches</A> -</UL> -<LI><A NAME="tex2html62" - HREF="node4.html#SECTION00045000000000000000">The Unique Table</A> -<LI><A NAME="tex2html63" - HREF="node4.html#SECTION00046000000000000000">Allowing Asynchronous Reordering</A> -<LI><A NAME="tex2html64" - HREF="node4.html#SECTION00047000000000000000">Debugging</A> -<LI><A NAME="tex2html65" - HREF="node4.html#SECTION00048000000000000000">Gathering and Interpreting Statistics</A> -<UL> -<LI><A NAME="tex2html66" - HREF="node4.html#SECTION00048100000000000000">Non Modifiable Parameters</A> -<LI><A NAME="tex2html67" - HREF="node4.html#SECTION00048200000000000000">Modifiable Parameters</A> -<LI><A NAME="tex2html68" - HREF="node4.html#SECTION00048300000000000000">Extended Statistics and Reporting</A> -</UL> -<LI><A NAME="tex2html69" - HREF="node4.html#SECTION00049000000000000000">Guidelines for Documentation</A> -</UL> -<BR> -<LI><A NAME="tex2html70" - HREF="node5.html">The C++ Interface</A> -<UL> -<LI><A NAME="tex2html71" - HREF="node5.html#SECTION00051000000000000000">Compiling and Linking</A> -<LI><A NAME="tex2html72" - HREF="node5.html#SECTION00052000000000000000">Basic Manipulation</A> -</UL> -<BR> -<LI><A NAME="tex2html73" - HREF="node6.html">Acknowledgments</A> -<LI><A NAME="tex2html74" - HREF="node7.html">Bibliography</A> -<LI><A NAME="tex2html75" - HREF="node8.html">Index</A> -</UL> -<!--End of Table of Child-Links--> -<BR><HR> -<ADDRESS> -Fabio Somenzi -2012-02-04 -</ADDRESS> -</BODY> -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddTitle.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddTitle.html deleted file mode 100644 index de29df000..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/cuddTitle.html +++ /dev/null @@ -1,18 +0,0 @@ -<HTML> -<HEAD><TITLE>The cudd package: Title</TITLE></HEAD> -<BODY> - -<TABLE BORDER WIDTH="100%"> - <TR> - <TD ALIGN=center> <A HREF="cuddExt.html" TARGET="_top"> - Programmer view</A> </TD> - <TD ALIGN=center> <A HREF="cuddAllByFunc.html" TARGET="_top"> - Maintainer by function</A> </TD> - <TD ALIGN=center> <A HREF="cuddAllByFile.html" TARGET="_top"> - Maintainer by file</A> </TD> - </TR> -</TABLE> - -</BODY> -</HTML> -writing ./cuddDesc.html diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/footnode.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/footnode.html deleted file mode 100644 index 985c42271..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/footnode.html +++ /dev/null @@ -1,109 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> - -<!--Converted with LaTeX2HTML 2008 (1.71) -original version by: Nikos Drakos, CBLU, University of Leeds -* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan -* with significant contributions from: - Jens Lippmann, Marek Rouchal, Martin Wilck and others --> -<HTML> -<HEAD> -<TITLE>Footnotes</TITLE> -<META NAME="description" CONTENT="Footnotes"> -<META NAME="keywords" CONTENT="cuddIntro"> -<META NAME="resource-type" CONTENT="document"> -<META NAME="distribution" CONTENT="global"> - -<META NAME="Generator" CONTENT="LaTeX2HTML v2008"> -<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> - -<LINK REL="STYLESHEET" HREF="cuddIntro.css"> - -<LINK REL="previous" HREF="node7.html"> -<LINK REL="up" HREF="cuddIntro.html"> -</HEAD> - -<BODY > - -<DL> -<DT><A NAME="foot139">... application.</A><A - HREF="node3.html#tex2html3"><SUP>1</SUP></A></DT> -<DD>The - global statistical counters are used locally; hence they are - compatible with the use of multiple managers. - -<PRE>. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -</PRE> -</DD> -<DT><A NAME="foot1083">... -node.</A><A - HREF="node3.html#tex2html4"><SUP>2</SUP></A></DT> -<DD>When the variables in a group are reordered, the - association between the <I>low</I> field and the index of the first - variable in the group is lost. The package updates the tree to keep - track of the changes. However, the application cannot rely on - <I>low</I> to determine the position of variables. - -<PRE>. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -. -</PRE> -</DD> -</DL> -</BODY> -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/blueball.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/blueball.png deleted file mode 100644 index 9720c2950..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/blueball.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_beg_r.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_beg_r.png deleted file mode 100644 index 807941a2d..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_beg_r.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_begin.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_begin.png deleted file mode 100644 index 0b3a6e230..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_begin.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_del_r.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_del_r.png deleted file mode 100644 index d5ae8e51b..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_del_r.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_delet.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_delet.png deleted file mode 100644 index d5ae8e51b..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_delet.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_end.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_end.png deleted file mode 100644 index 1f8f91c76..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_end.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_end_r.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_end_r.png deleted file mode 100644 index 3059c9342..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/ch_end_r.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/contents.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/contents.png deleted file mode 100644 index 0c752c66c..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/contents.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/crossref.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/crossref.png deleted file mode 100644 index 7dd2dddf5..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/crossref.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/footnote.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/footnote.png deleted file mode 100644 index 4591c0eca..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/footnote.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/greenball.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/greenball.png deleted file mode 100644 index a4d714533..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/greenball.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/image.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/image.png deleted file mode 100644 index 05ffff5d2..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/image.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/index.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/index.png deleted file mode 100644 index 698f09cae..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/index.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/next.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/next.png deleted file mode 100644 index 1628652aa..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/next.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/next_g.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/next_g.png deleted file mode 100644 index 9d3f59121..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/next_g.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/nx_grp.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/nx_grp.png deleted file mode 100644 index 4ec914a47..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/nx_grp.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/nx_grp_g.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/nx_grp_g.png deleted file mode 100644 index b2277a1d5..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/nx_grp_g.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/orangeball.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/orangeball.png deleted file mode 100644 index 10249c668..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/orangeball.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/pinkball.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/pinkball.png deleted file mode 100644 index 5b9232570..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/pinkball.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/prev.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/prev.png deleted file mode 100644 index e60b8b407..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/prev.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/prev_g.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/prev_g.png deleted file mode 100644 index 476d9568c..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/prev_g.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/purpleball.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/purpleball.png deleted file mode 100644 index d6d63fb82..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/purpleball.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/pv_grp.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/pv_grp.png deleted file mode 100644 index b9dec59c5..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/pv_grp.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/pv_grp_g.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/pv_grp_g.png deleted file mode 100644 index ab9893b16..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/pv_grp_g.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/redball.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/redball.png deleted file mode 100644 index 2e442bac4..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/redball.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/up.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/up.png deleted file mode 100644 index 3937e168f..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/up.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/up_g.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/up_g.png deleted file mode 100644 index 54ceb6830..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/up_g.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/whiteball.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/whiteball.png deleted file mode 100644 index 9d3056253..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/whiteball.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/yellowball.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/yellowball.png deleted file mode 100644 index ede8fc97f..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/icons/yellowball.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img1.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img1.png deleted file mode 100644 index 6082d1b9a..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img1.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img10.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img10.png deleted file mode 100644 index dc2db1eb1..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img10.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img11.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img11.png deleted file mode 100644 index 9509b94b9..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img11.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img12.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img12.png deleted file mode 100644 index 057fa666a..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img12.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img13.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img13.png deleted file mode 100644 index 409e371de..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img13.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img14.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img14.png deleted file mode 100644 index 969306d0b..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img14.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img15.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img15.png deleted file mode 100644 index 014311fa8..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img15.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img16.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img16.png deleted file mode 100644 index 2a761cec1..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img16.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img17.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img17.png deleted file mode 100644 index d1c485028..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img17.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img18.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img18.png deleted file mode 100644 index c08507b88..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img18.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img19.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img19.png deleted file mode 100644 index 1b152d483..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img19.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img2.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img2.png deleted file mode 100644 index 022cc6a0b..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img2.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img20.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img20.png deleted file mode 100644 index fbd4c942b..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img20.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img21.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img21.png deleted file mode 100644 index 49c39a277..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img21.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img22.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img22.png deleted file mode 100644 index 1c2624889..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img22.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img3.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img3.png deleted file mode 100644 index d7c99f4e7..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img3.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img4.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img4.png deleted file mode 100644 index a709c3fd2..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img4.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img5.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img5.png deleted file mode 100644 index b4ca4354c..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img5.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img6.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img6.png deleted file mode 100644 index 732c33402..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img6.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img7.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img7.png deleted file mode 100644 index bf71952cd..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img7.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img8.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img8.png deleted file mode 100644 index 8d3389035..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img8.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img9.png b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img9.png deleted file mode 100644 index 1a46e4c82..000000000 Binary files a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/img9.png and /dev/null differ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/index.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/index.html deleted file mode 100644 index e74c4fff5..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/index.html +++ /dev/null @@ -1,219 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> - -<!--Converted with LaTeX2HTML 2008 (1.71) -original version by: Nikos Drakos, CBLU, University of Leeds -* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan -* with significant contributions from: - Jens Lippmann, Marek Rouchal, Martin Wilck and others --> -<HTML> -<HEAD> -<TITLE>CUDD: CU Decision Diagram Package -Release 2.5.0</TITLE> -<META NAME="description" CONTENT="CUDD: CU Decision Diagram Package -Release 2.5.0"> -<META NAME="keywords" CONTENT="cuddIntro"> -<META NAME="resource-type" CONTENT="document"> -<META NAME="distribution" CONTENT="global"> - -<META NAME="Generator" CONTENT="LaTeX2HTML v2008"> -<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> - -<LINK REL="STYLESHEET" HREF="cuddIntro.css"> - -<LINK REL="next" HREF="node1.html"> -</HEAD> - -<BODY > -<!--Navigation Panel--> -<A NAME="tex2html14" - HREF="node1.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up_g.png"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev_g.png"> -<A NAME="tex2html12" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html15" - HREF="node1.html">Introduction</A> - <B> <A NAME="tex2html13" - HREF="node8.html">Index</A></B> -<BR> -<BR> -<!--End of Navigation Panel--> - -<H1 ALIGN="CENTER">CUDD: CU Decision Diagram Package -<BR> -Release 2.5.0</H1> -<DIV> - -<P ALIGN="CENTER"><STRONG>Fabio Somenzi</STRONG></P> -<P ALIGN="CENTER"><I>Department of Electrical, Computer, and Energy Engineering</I></P> -<P ALIGN="LEFT"><SMALL>University of Colorado at Boulder</SMALL></P> -</DIV> - -<P> -<BR><HR> -<!--Table of Child-Links--> -<A NAME="CHILD_LINKS"></A> - -<UL> -<LI><A NAME="tex2html16" - HREF="node1.html">Introduction</A> -<LI><A NAME="tex2html17" - HREF="node2.html">How to Get CUDD</A> -<UL> -<LI><A NAME="tex2html18" - HREF="node2.html#SECTION00021000000000000000">The CUDD Package</A> -<LI><A NAME="tex2html19" - HREF="node2.html#SECTION00022000000000000000">CUDD Friends</A> -</UL> -<BR> -<LI><A NAME="tex2html20" - HREF="node3.html">User's Manual</A> -<UL> -<LI><A NAME="tex2html21" - HREF="node3.html#SECTION00031000000000000000">Compiling and Linking</A> -<LI><A NAME="tex2html22" - HREF="node3.html#SECTION00032000000000000000">Basic Data Structures</A> -<UL> -<LI><A NAME="tex2html23" - HREF="node3.html#SECTION00032100000000000000">Nodes</A> -<LI><A NAME="tex2html24" - HREF="node3.html#SECTION00032200000000000000">The Manager</A> -<LI><A NAME="tex2html25" - HREF="node3.html#SECTION00032300000000000000">Cache</A> -</UL> -<LI><A NAME="tex2html26" - HREF="node3.html#SECTION00033000000000000000">Initializing and Shutting Down a DdManager</A> -<LI><A NAME="tex2html27" - HREF="node3.html#SECTION00034000000000000000">Setting Parameters</A> -<LI><A NAME="tex2html28" - HREF="node3.html#SECTION00035000000000000000">Constant Functions</A> -<UL> -<LI><A NAME="tex2html29" - HREF="node3.html#SECTION00035100000000000000">One, Logic Zero, and Arithmetic Zero</A> -<LI><A NAME="tex2html30" - HREF="node3.html#SECTION00035200000000000000">Predefined Constants</A> -<LI><A NAME="tex2html31" - HREF="node3.html#SECTION00035300000000000000">Background</A> -<LI><A NAME="tex2html32" - HREF="node3.html#SECTION00035400000000000000">New Constants</A> -</UL> -<LI><A NAME="tex2html33" - HREF="node3.html#SECTION00036000000000000000">Creating Variables</A> -<UL> -<LI><A NAME="tex2html34" - HREF="node3.html#SECTION00036100000000000000">New BDD and ADD Variables</A> -<LI><A NAME="tex2html35" - HREF="node3.html#SECTION00036200000000000000">New ZDD Variables</A> -</UL> -<LI><A NAME="tex2html36" - HREF="node3.html#SECTION00037000000000000000">Basic BDD Manipulation</A> -<LI><A NAME="tex2html37" - HREF="node3.html#SECTION00038000000000000000">Basic ADD Manipulation</A> -<LI><A NAME="tex2html38" - HREF="node3.html#SECTION00039000000000000000">Basic ZDD Manipulation</A> -<LI><A NAME="tex2html39" - HREF="node3.html#SECTION000310000000000000000">Converting ADDs to BDDs and Vice Versa</A> -<LI><A NAME="tex2html40" - HREF="node3.html#SECTION000311000000000000000">Converting BDDs to ZDDs and Vice Versa</A> -<LI><A NAME="tex2html41" - HREF="node3.html#SECTION000312000000000000000">Variable Reordering for BDDs and ADDs</A> -<LI><A NAME="tex2html42" - HREF="node3.html#SECTION000313000000000000000">Grouping Variables</A> -<LI><A NAME="tex2html43" - HREF="node3.html#SECTION000314000000000000000">Variable Reordering for ZDDs</A> -<LI><A NAME="tex2html44" - HREF="node3.html#SECTION000315000000000000000">Keeping Consistent Variable Orders for BDDs and ZDDs</A> -<LI><A NAME="tex2html45" - HREF="node3.html#SECTION000316000000000000000">Hooks</A> -<LI><A NAME="tex2html46" - HREF="node3.html#SECTION000317000000000000000">Timeouts and Limits</A> -<LI><A NAME="tex2html47" - HREF="node3.html#SECTION000318000000000000000">The SIS/VIS Interface</A> -<UL> -<LI><A NAME="tex2html48" - HREF="node3.html#SECTION000318100000000000000">Using the CUDD Package in SIS</A> -</UL> -<LI><A NAME="tex2html49" - HREF="node3.html#SECTION000319000000000000000">Writing Decision Diagrams to a File</A> -<LI><A NAME="tex2html50" - HREF="node3.html#SECTION000320000000000000000">Saving and Restoring BDDs</A> -</UL> -<BR> -<LI><A NAME="tex2html51" - HREF="node4.html">Programmer's Manual</A> -<UL> -<LI><A NAME="tex2html52" - HREF="node4.html#SECTION00041000000000000000">Compiling and Linking</A> -<LI><A NAME="tex2html53" - HREF="node4.html#SECTION00042000000000000000">Reference Counts</A> -<UL> -<LI><A NAME="tex2html54" - HREF="node4.html#SECTION00042100000000000000">NULL Return Values</A> -<LI><A NAME="tex2html55" - HREF="node4.html#SECTION00042200000000000000"><I>Cudd_RecursiveDeref</I> vs. <I>Cudd_Deref</I></A> -<LI><A NAME="tex2html56" - HREF="node4.html#SECTION00042300000000000000">When Increasing the Reference Count is Unnecessary</A> -<LI><A NAME="tex2html57" - HREF="node4.html#SECTION00042400000000000000">Saturating Increments and Decrements</A> -</UL> -<LI><A NAME="tex2html58" - HREF="node4.html#SECTION00043000000000000000">Complement Arcs</A> -<LI><A NAME="tex2html59" - HREF="node4.html#SECTION00044000000000000000">The Cache</A> -<UL> -<LI><A NAME="tex2html60" - HREF="node4.html#SECTION00044100000000000000">Cache Sizing</A> -<LI><A NAME="tex2html61" - HREF="node4.html#SECTION00044200000000000000">Local Caches</A> -</UL> -<LI><A NAME="tex2html62" - HREF="node4.html#SECTION00045000000000000000">The Unique Table</A> -<LI><A NAME="tex2html63" - HREF="node4.html#SECTION00046000000000000000">Allowing Asynchronous Reordering</A> -<LI><A NAME="tex2html64" - HREF="node4.html#SECTION00047000000000000000">Debugging</A> -<LI><A NAME="tex2html65" - HREF="node4.html#SECTION00048000000000000000">Gathering and Interpreting Statistics</A> -<UL> -<LI><A NAME="tex2html66" - HREF="node4.html#SECTION00048100000000000000">Non Modifiable Parameters</A> -<LI><A NAME="tex2html67" - HREF="node4.html#SECTION00048200000000000000">Modifiable Parameters</A> -<LI><A NAME="tex2html68" - HREF="node4.html#SECTION00048300000000000000">Extended Statistics and Reporting</A> -</UL> -<LI><A NAME="tex2html69" - HREF="node4.html#SECTION00049000000000000000">Guidelines for Documentation</A> -</UL> -<BR> -<LI><A NAME="tex2html70" - HREF="node5.html">The C++ Interface</A> -<UL> -<LI><A NAME="tex2html71" - HREF="node5.html#SECTION00051000000000000000">Compiling and Linking</A> -<LI><A NAME="tex2html72" - HREF="node5.html#SECTION00052000000000000000">Basic Manipulation</A> -</UL> -<BR> -<LI><A NAME="tex2html73" - HREF="node6.html">Acknowledgments</A> -<LI><A NAME="tex2html74" - HREF="node7.html">Bibliography</A> -<LI><A NAME="tex2html75" - HREF="node8.html">Index</A> -</UL> -<!--End of Table of Child-Links--> -<BR><HR> -<ADDRESS> -Fabio Somenzi -2012-02-04 -</ADDRESS> -</BODY> -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node1.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node1.html deleted file mode 100644 index 2398d3652..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node1.html +++ /dev/null @@ -1,174 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> - -<!--Converted with LaTeX2HTML 2008 (1.71) -original version by: Nikos Drakos, CBLU, University of Leeds -* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan -* with significant contributions from: - Jens Lippmann, Marek Rouchal, Martin Wilck and others --> -<HTML> -<HEAD> -<TITLE>Introduction</TITLE> -<META NAME="description" CONTENT="Introduction"> -<META NAME="keywords" CONTENT="cuddIntro"> -<META NAME="resource-type" CONTENT="document"> -<META NAME="distribution" CONTENT="global"> - -<META NAME="Generator" CONTENT="LaTeX2HTML v2008"> -<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> - -<LINK REL="STYLESHEET" HREF="cuddIntro.css"> - -<LINK REL="next" HREF="node2.html"> -<LINK REL="previous" HREF="cuddIntro.html"> -<LINK REL="up" HREF="cuddIntro.html"> -<LINK REL="next" HREF="node2.html"> -</HEAD> - -<BODY > -<!--Navigation Panel--> -<A NAME="tex2html86" - HREF="node2.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html82" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html76" - HREF="cuddIntro.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html84" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html87" - HREF="node2.html">How to Get CUDD</A> -<B> Up:</B> <A NAME="tex2html83" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html77" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> - <B> <A NAME="tex2html85" - HREF="node8.html">Index</A></B> -<BR> -<BR> -<!--End of Navigation Panel--> - -<H1><A NAME="SECTION00010000000000000000"></A> -<A NAME="sec:intro"></A> -<BR> -Introduction -</H1> - -<P> -The CUDD package provides functions to manipulate Binary Decision -Diagrams<A NAME="14"></A> (BDDs) [<A - HREF="node7.html#BDD">5</A>,<A - HREF="node7.html#BBR">3</A>], -Algebraic Decision Diagrams<A NAME="16"></A> (ADDs) -[<A - HREF="node7.html#Bahar93">1</A>], and Zero-suppressed Binary Decision -Diagrams<A NAME="18"></A> (ZDDs) -[<A - HREF="node7.html#Minato93">12</A>]. BDDs are used to represent -switching<A NAME="20"></A> functions; ADDs are used to -represent function from <IMG - WIDTH="56" HEIGHT="35" ALIGN="MIDDLE" BORDER="0" - SRC="img3.png" - ALT="$\{0,1\}^n$"> to an arbitrary set. ZDDs -represent switching<A NAME="21"></A> functions like BDDs; -however, they are much more efficient than BDDs when the functions to -be represented are characteristic<A NAME="22"></A> -functions of cube<A NAME="23"></A> sets, or in general, when the -ON-set<A NAME="24"></A> of the function to be represented is -very sparse. They are inferior to BDDs in other cases. - -<P> -The package provides a large set of operations on BDDs, ADDs, and -ZDDs, functions to convert BDDs into ADDs or ZDDs and vice versa, and -a large assortment of variable reordering<A NAME="25"></A> methods. - -<P> -The CUDD package can be used in three ways: - -<UL> -<LI>As a black box<A NAME="27"></A>. In this case, the application - program that needs to manipulate decision diagrams only uses the - exported functions of the package. The rich set of functions - included in the CUDD package allows many applications to be written - in this way. Section <A HREF="node3.html#sec:user">3</A> describes how to use the - exported functions of the package. An application written in terms - of the exported functions of the package needs not concern itself - with the details of variable reordering<A NAME="29"></A>, which may - take place behind the scenes. -Click <A NAME="tex2html1" - HREF="cuddExtAbs.html">here</A> -for a list of the - exported functions. -</LI> -<LI>As a clear box<A NAME="32"></A>. When writing a sophisticated - application based on decision diagrams, efficiency often dictates - that some functions be implemented as direct recursive manipulation - of the diagrams, instead of being written in terms of existing - primitive functions. Section <A HREF="node4.html#sec:prog">4</A> explains how to add new - functions to the CUDD package. It also details how to write a - recursive function that can be interrupted by - dynamic<A NAME="34"></A> variable reordering. -Click <A NAME="tex2html2" - HREF="cuddAllAbs.html">here</A> -for a list of the - exported and internal functions. -</LI> -<LI>Through an interface. Object-oriented languages like C++ and - Perl5 can free the programmer from the burden of memory management. - A C++ interface is included in the distribution of CUDD. It - automatically frees decision diagrams that are no longer used by the - application and overloads operators. Almost all the functionality - provided by the CUDD exported functions is available through the C++ - interface, which is especially recommended for fast prototyping. - Section <A HREF="node5.html#sec:cpp">5</A> explains how to use the interface. A Perl5 - interface also exists and is ditributed separately. (See - Section <A HREF="node2.html#sec:getFriends">2.2</A>.) Some applications define their own - interfaces. See for example Section <A HREF="node3.html#sec:sis-vis">3.18</A>. -</LI> -</UL> -In the following, the reader is supposed to be familiar with the basic -ideas about decision diagrams, as found, for instance, in [<A - HREF="node7.html#BBR">3</A>]. - -<P> -<HR> -<!--Navigation Panel--> -<A NAME="tex2html86" - HREF="node2.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html82" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html76" - HREF="cuddIntro.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html84" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html87" - HREF="node2.html">How to Get CUDD</A> -<B> Up:</B> <A NAME="tex2html83" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html77" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> - <B> <A NAME="tex2html85" - HREF="node8.html">Index</A></B> -<!--End of Navigation Panel--> -<ADDRESS> -Fabio Somenzi -2012-02-04 -</ADDRESS> -</BODY> -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node2.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node2.html deleted file mode 100644 index f36d7ec2a..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node2.html +++ /dev/null @@ -1,175 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> - -<!--Converted with LaTeX2HTML 2008 (1.71) -original version by: Nikos Drakos, CBLU, University of Leeds -* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan -* with significant contributions from: - Jens Lippmann, Marek Rouchal, Martin Wilck and others --> -<HTML> -<HEAD> -<TITLE>How to Get CUDD</TITLE> -<META NAME="description" CONTENT="How to Get CUDD"> -<META NAME="keywords" CONTENT="cuddIntro"> -<META NAME="resource-type" CONTENT="document"> -<META NAME="distribution" CONTENT="global"> - -<META NAME="Generator" CONTENT="LaTeX2HTML v2008"> -<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> - -<LINK REL="STYLESHEET" HREF="cuddIntro.css"> - -<LINK REL="next" HREF="node3.html"> -<LINK REL="previous" HREF="node1.html"> -<LINK REL="up" HREF="cuddIntro.html"> -<LINK REL="next" HREF="node3.html"> -</HEAD> - -<BODY > -<!--Navigation Panel--> -<A NAME="tex2html98" - HREF="node3.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html94" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html88" - HREF="node1.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html96" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html99" - HREF="node3.html">User's Manual</A> -<B> Up:</B> <A NAME="tex2html95" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html89" - HREF="node1.html">Introduction</A> - <B> <A NAME="tex2html97" - HREF="node8.html">Index</A></B> -<BR> -<BR> -<!--End of Navigation Panel--> -<!--Table of Child-Links--> -<A NAME="CHILD_LINKS"><STRONG>Subsections</STRONG></A> - -<UL> -<LI><A NAME="tex2html100" - HREF="node2.html#SECTION00021000000000000000">The CUDD Package</A> -<LI><A NAME="tex2html101" - HREF="node2.html#SECTION00022000000000000000">CUDD Friends</A> -</UL> -<!--End of Table of Child-Links--> -<HR> - -<H1><A NAME="SECTION00020000000000000000"></A> -<A NAME="sec:getting"></A> -<BR> -How to Get CUDD -</H1> - -<P> - -<H2><A NAME="SECTION00021000000000000000"></A> -<A NAME="sec:getCUDD"></A> -<BR> -The CUDD Package -</H2> - -<P> -The CUDD package is available via anonymous FTP<A NAME="46"></A> from -vlsi.Colorado.EDU. A compressed tar file named -<TT>cudd-2.5.0.tar.gz</TT> can be found in directory <TT>pub</TT>. -Once you have this file, -<BLOCKQUOTE> -<TT>gzip<A NAME="50"></A> -dc cudd-2.5.0.tar.gz | tar xvf - - -</TT></BLOCKQUOTE> -will create directory <TT>cudd-2.5.0</TT> and its subdirectories. -These directories contain the decision diagram package, a few support -libraries<A NAME="53"></A>, and a toy application based on the -decision diagram package. There is a README<A NAME="54"></A> file -with instructions on configuration<A NAME="55"></A> and -installation<A NAME="56"></A> in <TT>cudd-2.5.0</TT>. You can use -a compiler for either ANSI C or C++. - -<P> -Once you have made the libraries and program, you can type: -<BLOCKQUOTE> -<TT>cd nanotrav<A NAME="59"></A> -<BR> -nanotrav -p 1 -autodyn -reordering sifting -trav mult32a.blif - -</TT></BLOCKQUOTE> -This will run a simple-minded FSM traversal program. (On a 2.4 GHz -Pentium 4<A NAME="61"></A> (TM), it takes about 0.5 s.) The -output produced by the program can be checked against -<TT>cudd-2.5.0/nanotrav/mult32a.out</TT>. More information on the -<TT>nanotrav<A NAME="63"></A></TT> program can be found in -<TT>cudd-2.5.0/nanotrav/README<A NAME="64"></A></TT>. - -<P> -If you want to be notified of new releases of the CUDD package, send a -message to <TT>Fabio@Colorado.EDU</TT>. - -<P> - -<H2><A NAME="SECTION00022000000000000000"></A> -<A NAME="sec:getFriends"></A> -<BR> -CUDD Friends -</H2> - -<P> -Two CUDD extensions are available via anonymous FTP<A NAME="68"></A> from -vlsi.Colorado.EDU. - -<UL> -<LI><I>PerlDD</I> is an object-oriented Perl5 interface to CUDD. It - is organized as a standard Perl extension module. The Perl interface - is at a somewhat higher level than the C++ interface, but it is not - as complete. -</LI> -<LI><I>DDcal</I> is a graphic BDD calculator based on CUDD, Perl-Tk, - and dot. (See Section <A HREF="node3.html#sec:dump">3.19</A> for information on <I>dot</I>.) - -<P> -</LI> -</UL><HR> -<!--Navigation Panel--> -<A NAME="tex2html98" - HREF="node3.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html94" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html88" - HREF="node1.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html96" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html99" - HREF="node3.html">User's Manual</A> -<B> Up:</B> <A NAME="tex2html95" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html89" - HREF="node1.html">Introduction</A> - <B> <A NAME="tex2html97" - HREF="node8.html">Index</A></B> -<!--End of Navigation Panel--> -<ADDRESS> -Fabio Somenzi -2012-02-04 -</ADDRESS> -</BODY> -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node3.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node3.html deleted file mode 100644 index d91378b2e..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node3.html +++ /dev/null @@ -1,1637 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> - -<!--Converted with LaTeX2HTML 2008 (1.71) -original version by: Nikos Drakos, CBLU, University of Leeds -* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan -* with significant contributions from: - Jens Lippmann, Marek Rouchal, Martin Wilck and others --> -<HTML> -<HEAD> -<TITLE>User's Manual</TITLE> -<META NAME="description" CONTENT="User's Manual"> -<META NAME="keywords" CONTENT="cuddIntro"> -<META NAME="resource-type" CONTENT="document"> -<META NAME="distribution" CONTENT="global"> - -<META NAME="Generator" CONTENT="LaTeX2HTML v2008"> -<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> - -<LINK REL="STYLESHEET" HREF="cuddIntro.css"> - -<LINK REL="next" HREF="node4.html"> -<LINK REL="previous" HREF="node2.html"> -<LINK REL="up" HREF="cuddIntro.html"> -<LINK REL="next" HREF="node4.html"> -</HEAD> - -<BODY > -<!--Navigation Panel--> -<A NAME="tex2html112" - HREF="node4.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html108" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html102" - HREF="node2.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html110" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html113" - HREF="node4.html">Programmer's Manual</A> -<B> Up:</B> <A NAME="tex2html109" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html103" - HREF="node2.html">How to Get CUDD</A> - <B> <A NAME="tex2html111" - HREF="node8.html">Index</A></B> -<BR> -<BR> -<!--End of Navigation Panel--> -<!--Table of Child-Links--> -<A NAME="CHILD_LINKS"><STRONG>Subsections</STRONG></A> - -<UL> -<LI><A NAME="tex2html114" - HREF="node3.html#SECTION00031000000000000000">Compiling and Linking</A> -<LI><A NAME="tex2html115" - HREF="node3.html#SECTION00032000000000000000">Basic Data Structures</A> -<UL> -<LI><A NAME="tex2html116" - HREF="node3.html#SECTION00032100000000000000">Nodes</A> -<LI><A NAME="tex2html117" - HREF="node3.html#SECTION00032200000000000000">The Manager</A> -<LI><A NAME="tex2html118" - HREF="node3.html#SECTION00032300000000000000">Cache</A> -</UL> -<BR> -<LI><A NAME="tex2html119" - HREF="node3.html#SECTION00033000000000000000">Initializing and Shutting Down a DdManager</A> -<LI><A NAME="tex2html120" - HREF="node3.html#SECTION00034000000000000000">Setting Parameters</A> -<LI><A NAME="tex2html121" - HREF="node3.html#SECTION00035000000000000000">Constant Functions</A> -<UL> -<LI><A NAME="tex2html122" - HREF="node3.html#SECTION00035100000000000000">One, Logic Zero, and Arithmetic Zero</A> -<LI><A NAME="tex2html123" - HREF="node3.html#SECTION00035200000000000000">Predefined Constants</A> -<LI><A NAME="tex2html124" - HREF="node3.html#SECTION00035300000000000000">Background</A> -<LI><A NAME="tex2html125" - HREF="node3.html#SECTION00035400000000000000">New Constants</A> -</UL> -<BR> -<LI><A NAME="tex2html126" - HREF="node3.html#SECTION00036000000000000000">Creating Variables</A> -<UL> -<LI><A NAME="tex2html127" - HREF="node3.html#SECTION00036100000000000000">New BDD and ADD Variables</A> -<LI><A NAME="tex2html128" - HREF="node3.html#SECTION00036200000000000000">New ZDD Variables</A> -</UL> -<BR> -<LI><A NAME="tex2html129" - HREF="node3.html#SECTION00037000000000000000">Basic BDD Manipulation</A> -<LI><A NAME="tex2html130" - HREF="node3.html#SECTION00038000000000000000">Basic ADD Manipulation</A> -<LI><A NAME="tex2html131" - HREF="node3.html#SECTION00039000000000000000">Basic ZDD Manipulation</A> -<LI><A NAME="tex2html132" - HREF="node3.html#SECTION000310000000000000000">Converting ADDs to BDDs and Vice Versa</A> -<LI><A NAME="tex2html133" - HREF="node3.html#SECTION000311000000000000000">Converting BDDs to ZDDs and Vice Versa</A> -<LI><A NAME="tex2html134" - HREF="node3.html#SECTION000312000000000000000">Variable Reordering for BDDs and ADDs</A> -<LI><A NAME="tex2html135" - HREF="node3.html#SECTION000313000000000000000">Grouping Variables</A> -<LI><A NAME="tex2html136" - HREF="node3.html#SECTION000314000000000000000">Variable Reordering for ZDDs</A> -<LI><A NAME="tex2html137" - HREF="node3.html#SECTION000315000000000000000">Keeping Consistent Variable Orders for BDDs and ZDDs</A> -<LI><A NAME="tex2html138" - HREF="node3.html#SECTION000316000000000000000">Hooks</A> -<LI><A NAME="tex2html139" - HREF="node3.html#SECTION000317000000000000000">Timeouts and Limits</A> -<LI><A NAME="tex2html140" - HREF="node3.html#SECTION000318000000000000000">The SIS/VIS Interface</A> -<UL> -<LI><A NAME="tex2html141" - HREF="node3.html#SECTION000318100000000000000">Using the CUDD Package in SIS</A> -</UL> -<BR> -<LI><A NAME="tex2html142" - HREF="node3.html#SECTION000319000000000000000">Writing Decision Diagrams to a File</A> -<LI><A NAME="tex2html143" - HREF="node3.html#SECTION000320000000000000000">Saving and Restoring BDDs</A> -</UL> -<!--End of Table of Child-Links--> -<HR> - -<H1><A NAME="SECTION00030000000000000000"></A> -<A NAME="sec:user"></A> -<BR> -User's Manual -</H1> - -<P> -This section describes the use of the CUDD package as a black box. - -<P> - -<H2><A NAME="SECTION00031000000000000000"></A> -<A NAME="sec:compileExt"></A><A NAME="79"></A> -<BR> -Compiling and Linking -</H2> - -<P> -To build an application that uses the CUDD package, you should add -<PRE> -#include "util.h" -#include "cudd.h" -</PRE> -<A NAME="82"></A> -to your source files, and should link -<code>libcudd.a</code><A NAME="83"></A>, -<code>libmtr.a</code><A NAME="84"></A>, -<code>libst.a</code><A NAME="85"></A>, and -<code>libutil.a</code><A NAME="86"></A> to your executable. (All these -libraries are part of the distribution.) Some -platforms require specific compiler and linker flags. Refer to the -<TT>Makefile<A NAME="87"></A></TT> in the top level directory of the -distribution. - -<P> -Keep in mind that whatever flags affect the size of data -structures--for instance the flags used to use 64-bit pointers where -available--must be specified when compiling both CUDD and the files -that include its header files. - -<P> - -<H2><A NAME="SECTION00032000000000000000"></A> -<A NAME="sec:struct"></A> -<BR> -Basic Data Structures -</H2> - -<P> - -<H3><A NAME="SECTION00032100000000000000"></A> -<A NAME="sec:nodes"></A> -<BR> -Nodes -</H3> - -<P> -BDDs, ADDs, and ZDDs are made of DdNode's. A DdNode<A NAME="92"></A> -(node<A NAME="93"></A> for short) is a structure with several fields. Those -that are of interest to the application that uses the CUDD package as -a black box are the variable index<A NAME="94"></A>, the -reference<A NAME="95"></A> count, and the value. The -remaining fields are pointers that connect nodes among themselves and -that are used to implement the unique<A NAME="96"></A> table. (See -Section <A HREF="#sec:manager">3.2.2</A>.) - -<P> -The <I>index</I> field holds the name of the variable that labels the -node. The index of a variable is a permanent attribute that reflects -the order<A NAME="99"></A> of creation. Index 0 corresponds to -the variable created first. On a machine with 32-bit pointers, the -maximum number of variables is the largest value that can be stored in -an unsigned short integer minus 1. The largest index is reserved for -the constant<A NAME="100"></A> nodes. When 64-bit pointers are -used, the maximum number of variables is the largest value that can be -stored in an unsigned integer minus 1. - -<P> -When variables are reordered to reduce the size of the decision -diagrams, the variables may shift in the order, but they retain their -indices. The package keeps track of the variable -permutation<A NAME="101"></A> (and its inverse). The -application is not affected by variable reordering<A NAME="102"></A>, -except in the following cases. - -<UL> -<LI>If the application uses generators<A NAME="104"></A> - (<I>Cudd_ForeachCube</I> <A NAME="1108"></A> and - <I>Cudd_ForeachNode</I><A NAME="1110"></A>) and reordering is - enabled, then it must take care not to call any operation that may - create new nodes (and hence possibly trigger reordering). This is - because the cubes (i.e., paths) and nodes of a diagram change as a - result of reordering. -</LI> -<LI>If the application uses - <I>Cudd_bddConstrain</I><A NAME="1112"></A> and reordering - takes place, then the property of <I>Cudd_bddConstrain</I> of - being an image restrictor is lost. -</LI> -</UL> - -<P> -The CUDD package relies on garbage<A NAME="113"></A> -collection to reclaim the memory used by diagrams that are no longer -in use. The scheme employed for garbage collection is based on keeping -a reference<A NAME="114"></A> count for each node. The -references that are counted are both the internal references -(references from other nodes) and external references (typically -references from the calling environment). When an application creates -a new BDD<A NAME="115"></A>, ADD<A NAME="116"></A>, or ZDD<A NAME="117"></A>, it must -increase its reference count explicitly, through a call to -<I>Cudd_Ref</I><A NAME="1114"></A>. Similarly, when a diagram is no -longer needed, the application must call -<I>Cudd_RecursiveDeref</I><A NAME="1116"></A> (for BDDs and -ADDs) or <I>Cudd_RecursiveDerefZdd</I><A NAME="1118"></A> -(for ZDDs) to ``recycle<A NAME="124"></A>'' the nodes of the -diagram. - -<P> -Terminal<A NAME="125"></A> nodes carry a value. This is especially -important for ADDs. By default, the value is a double<A NAME="126"></A>. -To change to something different (e.g., an integer), the -package must be modified and recompiled. Support for this process is -currently very rudimentary. - -<P> - -<H3><A NAME="SECTION00032200000000000000"></A> -<A NAME="128"></A><A NAME="sec:manager"></A> -<BR> -The Manager -</H3> - -<P> -All nodes used in BDDs, ADDs, and ZDDs are kept in special -hash<A NAME="130"></A> tables called the -<I>unique<A NAME="131"></A> tables</I>. Specifically, BDDs and ADDs -share the same unique table, whereas ZDDs have their own table. As -the name implies, the main purpose of the unique table is to guarantee -that each node is unique; that is, there is no other node labeled by -the same variable and with the same children. This uniqueness -property makes decision diagrams canonical<A NAME="132"></A>. The -unique<A NAME="133"></A> tables and some auxiliary data structures -make up the DdManager<A NAME="134"></A> (manager<A NAME="135"></A> for -short). Though the application that uses only the exported functions -needs not be concerned with most details of the manager, it has to -deal with the manager in the following sense. The application must -initialize the manager by calling an appropriate function. (See -Section <A HREF="#sec:init">3.3</A>.) Subsequently, it must pass a pointer to the -manager to all the functions that operate on decision diagrams. - -<P> -With the exception of a few statistical counters<A NAME="137"></A>, there are no global<A NAME="138"></A> variables in -the CUDD package. Therefore, it is quite possible to have multiple -managers simultaneously active in the same application.<A NAME="tex2html3" - HREF="footnode.html#foot139"><SUP>1</SUP></A> It is the pointers to -the managers that tell the functions on what data they should operate. - -<P> - -<H3><A NAME="SECTION00032300000000000000"></A> -<A NAME="141"></A><A NAME="sec:memoize"></A> -<BR> -Cache -</H3> - -<P> -Efficient recursive manipulation of decision diagrams requires the use -of a table to store computed results. This table<A NAME="143"></A> -is called here the <I>cache<A NAME="144"></A></I> because it is -effectively handled like a cache of variable but limited capacity. The -CUDD package starts by default with a small cache, and increases its -size until either no further benefit is achieved, or a limit size is -reached. The user can influence this policy by choosing initial and -limit values for the cache size. - -<P> -Too small a cache will cause frequent overwriting of useful results. -Too large a cache will cause overhead, because the whole cache is -scanned every time garbage<A NAME="145"></A> collection takes -place. The optimal parameters depend on the specific application. The -default parameters work reasonably well for a large spectrum of -applications. - -<P> -The cache<A NAME="146"></A> of the CUDD package is used by most recursive -functions of the package, and can be used by user-supplied functions -as well. (See Section <A HREF="node4.html#sec:cache">4.4</A>.) - -<P> - -<H2><A NAME="SECTION00033000000000000000"></A> -<A NAME="149"></A><A NAME="sec:init"></A> -<BR> -Initializing and Shutting Down a DdManager -</H2> - -<P> -To use the functions in the CUDD package, one has first to initialize -the package itself by calling <I>Cudd_Init</I><A NAME="1120"></A>. -This function takes four parameters: - -<UL> -<LI>numVars<A NAME="154"></A>: It is the initial number of variables - for BDDs and ADDs. If the total number of variables needed by the - application is known, then it is slightly more efficient to create a - manager with that number of variables. If the number is unknown, it - can be set to 0, or to any other lower bound on the number of - variables. Requesting more variables than are actually needed is - not incorrect, but is not efficient. -</LI> -<LI>numVarsZ<A NAME="155"></A>: It is the initial number of variables - for ZDDs. See Sections <A HREF="#sec:basicZDD">3.9</A> and <A HREF="#sec:convertZ">3.11</A> for - a discussion of the value of this argument. -</LI> -<LI>numSlots<A NAME="158"></A>: Determines the initial size of each - subtable<A NAME="159"></A> of the unique<A NAME="160"></A> table. - There is a subtable for each variable. The size of each subtable is - dynamically adjusted to reflect the number of nodes. It is normally - O.K. to use the default value for this parameter, which is - CUDD_UNIQUE_SLOTS<A NAME="161"></A>. -</LI> -<LI>cacheSize<A NAME="162"></A>: It is the initial size (number of - entries) of the cache<A NAME="163"></A>. Its default value is - CUDD_CACHE_SLOTS<A NAME="164"></A>. -</LI> -<LI>maxMemory<A NAME="165"></A>: It is the target value for the - maximum memory occupation (in bytes). The package uses this value to - decide two parameters. - -<UL> -<LI>the maximum size to which the cache will grow, regardless of - the hit rate or the size of the unique<A NAME="167"></A> table. -</LI> -<LI>the maximum size to which growth of the unique table will be - preferred to garbage collection. - -</LI> -</UL> - If maxMemory is set to 0, CUDD tries to guess a good value based on - the available memory. -</LI> -</UL> -A typical call to <I>Cudd_Init</I><A NAME="1122"></A> may look -like this: -<PRE> - manager = Cudd_Init(0,0,CUDD_UNIQUE_SLOTS,CUDD_CACHE_SLOTS,0); -</PRE> -To reclaim all the memory associated with a manager, an application -must call <I>Cudd_Quit</I><A NAME="1124"></A>. This is normally -done before exiting. - -<P> - -<H2><A NAME="SECTION00034000000000000000"></A> -<A NAME="sec:params"></A> -<BR> -Setting Parameters -</H2> - -<P> -The package provides several functions to set the parameters that -control various functions. For instance, the package has an automatic -way of determining whether a larger unique<A NAME="178"></A> table -would make the application run faster. In that case, the package -enters a ``fast growth<A NAME="179"></A>'' mode in which resizing of -the unique subtables is favored over garbage<A NAME="180"></A> -collection. When the unique table reaches a given size, however, the -package returns to the normal ``slow growth'' mode, even though the -conditions that caused the transition to fast growth still prevail. -The limit size for fast growth<A NAME="181"></A> can be read by -<I>Cudd_ReadLooseUpTo</I><A NAME="1126"></A> and changed by -<I>Cudd_SetLooseUpTo</I><A NAME="1128"></A>. Similar pairs of -functions exist for several other parameters. See also -Section <A HREF="node4.html#sec:stats">4.8</A>. - -<P> - -<H2><A NAME="SECTION00035000000000000000"></A> -<A NAME="188"></A><A NAME="sec:const"></A> -<BR> -Constant Functions -</H2> - -<P> -The CUDD Package defines several constant functions. These functions -are created when the manager<A NAME="190"></A> is initialized, and are accessible -through the manager itself. - -<P> - -<H3><A NAME="SECTION00035100000000000000"></A> -<A NAME="192"></A><A NAME="193"></A><A NAME="sec:zero"></A> -<BR> -One, Logic Zero, and Arithmetic Zero -</H3> - -<P> -The constant<A NAME="195"></A> 1 (returned by -<I>Cudd_ReadOne</I><A NAME="1130"></A>) is common to BDDs, ADDs, and -ZDDs. However, its meaning is different for ADDs and BDDs, on the one -hand, and ZDDs, on the other hand. The diagram consisting of the -constant 1 node only represents the constant 1 function for ADDs and -BDDs. For ZDDs, its meaning depends on the number of variables: It is -the conjunction of the complements of all variables. Conversely, the -representation of the constant 1 function depends on the number of -variables. The constant 1 function of <IMG - WIDTH="15" HEIGHT="15" ALIGN="BOTTOM" BORDER="0" - SRC="img4.png" - ALT="$n$"> variables is returned by -<I>Cudd_ReadZddOne</I><A NAME="1132"></A>. - -<P> -The constant 0 is common to ADDs and ZDDs, but not to BDDs. The -BDD<A NAME="200"></A> logic 0 is <B>not</B> associated with the constant 0 -function: It is obtained by complementation -(<I>Cudd_Not</I><A NAME="1134"></A>) of the constant 1. (It is also -returned by <I>Cudd_ReadLogicZero</I><A NAME="1136"></A>.) -All other constants are specific to ADDs. - -<P> - -<H3><A NAME="SECTION00035200000000000000"></A> -<A NAME="sec:predef-const"></A> -<BR> -Predefined Constants -</H3> - -<P> -Besides 0 (returned by <I>Cudd_ReadZero</I><A NAME="1138"></A>) -and 1, the following constant<A NAME="210"></A> functions are -created at initialization time. - -<OL> -<LI>PlusInfinity<A NAME="212"></A> and - MinusInfinity<A NAME="213"></A>: On computers implementing the - IEEE<A NAME="214"></A> standard 754 for - floating-point<A NAME="215"></A> arithmetic, these two constants - are set to the signed infinities<A NAME="216"></A>. On the DEC - Alphas<A NAME="217"></A>, the option <code>-ieee_with_no_inexact</code> or - <code>-ieee_with_inexact</code> must be passed to the DEC compiler to get - support of the IEEE standard. (The compiler still produces a - warning, but it can be ignored.) Compiling<A NAME="218"></A> with - those options may cause substantial performance degradation on the - Evolution IV CPUs. (Especially if the application does use the - infinities.) The problem is reportedly solved in the Evolution V - CPUs. If <TT>gcc<A NAME="219"></A></TT> is used to compile CUDD on the - Alphas, the symbol <TT>HAVE_IEEE_754<A NAME="220"></A></TT> - must be undefined. (See the Makefile<A NAME="221"></A> for the - details.) The values of these constants are returned by - <I>Cudd_ReadPlusInfinity</I><A NAME="1140"></A> and - <I>Cudd_ReadMinusInfinity</I><A NAME="1142"></A>. -</LI> -<LI>Epsilon<A NAME="226"></A>: This constant, initially set to - <IMG - WIDTH="47" HEIGHT="18" ALIGN="BOTTOM" BORDER="0" - SRC="img5.png" - ALT="$10^{-12}$">, is used in comparing floating point values for equality. - Its value is returned by - <I>Cudd_ReadEpsilon</I><A NAME="1144"></A>, and it can be - modified by calling <I>Cudd_SetEpsilon</I><A NAME="1146"></A>. - Unlike the other constants, it does not correspond to a node. -</LI> -</OL> - -<P> - -<H3><A NAME="SECTION00035300000000000000"></A> -<A NAME="234"></A><A NAME="sec:background"></A> -<BR> -Background -</H3> - -<P> -The background value is a constant<A NAME="236"></A> typically used -to represent non-existing arcs in graphs. Consider a shortest path -problem. Two nodes that are not connected by an arc can be regarded as -being joined by an arc<A NAME="237"></A> of infinite length. In -shortest path problems, it is therefore convenient to set the -background value to PlusInfinity<A NAME="238"></A>. In network flow -problems, on the other hand, two nodes not connected by an arc can be -regarded as joined by an arc<A NAME="239"></A> of 0 capacity. -For these problems, therefore, it is more convenient to set the -background value to 0. In general, when representing -sparse<A NAME="240"></A> matrices, the background value is the value that -is assumed implicitly. - -<P> -At initialization, the background value is set to 0. It can be read -with <I>Cudd_ReadBackground</I><A NAME="1148"></A>, and -modified with <I>Cudd_SetBackground</I>. The background value -affects procedures that read sparse matrices/graphs -(<I>Cudd_addRead</I><A NAME="1150"></A> and -<I>Cudd_addHarwell</I><A NAME="1152"></A>), procedures that print -out sum-of-product<A NAME="248"></A> expressions for -ADDs (<I>Cudd_PrintMinterm</I><A NAME="1154"></A>), generators -of cubes (<I>Cudd_ForeachCube</I><A NAME="1156"></A>), and -procedures that count minterms<A NAME="253"></A> -(<I>Cudd_CountMinterm</I><A NAME="1158"></A>). - -<P> - -<H3><A NAME="SECTION00035400000000000000"></A> -<A NAME="sec:newconst"></A> -<BR> -New Constants -</H3> - -<P> -New constant<A NAME="258"></A> can be created by calling -<I>Cudd_addConst</I><A NAME="1160"></A>. This function will -retrieve the ADD<A NAME="261"></A> for the desired constant, if it already -exist, or it will create a new one. Obviously, new constants should -only be used when manipulating ADDs. - -<P> - -<H2><A NAME="SECTION00036000000000000000"></A> -<A NAME="sec:newvar"></A> -<BR> -Creating Variables -</H2> - -<P> -Decision diagrams are typically created by combining simpler decision -diagrams. The simplest decision diagrams, of course, cannot be -created in that way. Constant functions have been discussed in -Section <A HREF="#sec:const">3.5</A>. In this section we discuss the simple -variable functions, also known as <I>projection<A NAME="265"></A> functions</I>. - -<P> - -<H3><A NAME="SECTION00036100000000000000"></A> -<A NAME="sec:BDDADDvar"></A> -<BR> -New BDD and ADD Variables -</H3> - -<P> -The projection<A NAME="268"></A> functions are distinct for -BDDs and ADDs. A projection function for BDDs consists of an internal -node with both outgoing arcs pointing to the constant 1. The -<I>else</I> arc<A NAME="270"></A> is complemented. - -<P> -An ADD projection function, on the other hand, has the <I>else</I> -pointer directed to the arithmetic<A NAME="272"></A> zero -function. One should never mix the two types of variables. BDD -variables should be used when manipulating BDDs, and ADD variables -should be used when manipulating ADDs. Three functions are provided -to create BDD variables: - -<UL> -<LI><I>Cudd_bddIthVar</I><A NAME="1162"></A>: Returns - the projection<A NAME="276"></A> function with index <IMG - WIDTH="10" HEIGHT="15" ALIGN="BOTTOM" BORDER="0" - SRC="img6.png" - ALT="$i$">. - If the function does not exist, it is created. -</LI> -<LI><I>Cudd_bddNewVar</I><A NAME="1164"></A>: Returns a - new projection<A NAME="279"></A> function, whose index is - the largest index in use at the time of the call, plus 1. -</LI> -<LI><I>Cudd_bddNewVarAtLevel</I><A NAME="1166"></A>: - Similar to <I>Cudd_bddNewVar</I><A NAME="1168"></A>. In - addition it allows to specify the position in the variable - order<A NAME="284"></A> at which the new variable should be - inserted. In contrast, <I>Cudd_bddNewVar</I><A NAME="1170"></A> - adds the new variable at the end of the order. -</LI> -</UL> -The analogous functions for ADDs are -<I>Cudd_addIthVar</I><A NAME="1172"></A>, -<I>Cudd_addNewVar</I><A NAME="1174"></A>, and -<I>Cudd_addNewVarAtLevel</I><A NAME="1176"></A>. - -<P> - -<H3><A NAME="SECTION00036200000000000000"></A> -<A NAME="295"></A><A NAME="sec:ZDDvars"></A> -<BR> -New ZDD Variables -</H3> - -<P> -Unlike the projection functions of BDDs and ADDs, the -projection<A NAME="297"></A> functions of ZDDs have diagrams -with <IMG - WIDTH="45" HEIGHT="32" ALIGN="MIDDLE" BORDER="0" - SRC="img7.png" - ALT="$n+1$"> nodes, where <IMG - WIDTH="15" HEIGHT="15" ALIGN="BOTTOM" BORDER="0" - SRC="img4.png" - ALT="$n$"> is the number of variables. Therefore the -ZDDs of the projection functions change when new variables are added. -This will be discussed in Section <A HREF="#sec:basicZDD">3.9</A>. Here we assume -that the number of variables is fixed. The ZDD of the <IMG - WIDTH="10" HEIGHT="15" ALIGN="BOTTOM" BORDER="0" - SRC="img6.png" - ALT="$i$">-th -projection function is returned by -<I>Cudd_zddIthVar</I><A NAME="1178"></A>. - -<P> - -<H2><A NAME="SECTION00037000000000000000"></A> -<A NAME="302"></A><A NAME="sec:basicBDD"></A> -<BR> -Basic BDD Manipulation -</H2> - -<P> -Common manipulations of BDDs can be accomplished by calling -<I>Cudd_bddIte</I>. This function takes three BDDs, <IMG - WIDTH="15" HEIGHT="33" ALIGN="MIDDLE" BORDER="0" - SRC="img8.png" - ALT="$f$">, <IMG - WIDTH="13" HEIGHT="32" ALIGN="MIDDLE" BORDER="0" - SRC="img9.png" - ALT="$g$">, and -<IMG - WIDTH="14" HEIGHT="15" ALIGN="BOTTOM" BORDER="0" - SRC="img10.png" - ALT="$h$">, as arguments and computes <!-- MATH - $f\cdot g + f'\cdot h$ - --> -<IMG - WIDTH="95" HEIGHT="35" ALIGN="MIDDLE" BORDER="0" - SRC="img11.png" - ALT="$f\cdot g + f'\cdot h$">. Like all the -functions that create new BDDs or ADDs, <I>Cudd_bddIte</I><A NAME="1180"></A> returns a result that must be -explicitly referenced by the caller. <I>Cudd_bddIte</I> can be used -to implement all two-argument boolean functions. However, the package -also provides <I>Cudd_bddAnd</I><A NAME="1182"></A> as well as the -other two-operand boolean functions, which are slightly more efficient -when a two-operand function is called for. The following fragment of -code illustrates how to build the BDD for the function <!-- MATH - $f = -x_0'x_1'x_2'x_3'$ - --> -<IMG - WIDTH="108" HEIGHT="35" ALIGN="MIDDLE" BORDER="0" - SRC="img12.png" - ALT="$f = -x_0'x_1'x_2'x_3'$">. -<PRE> - DdManager *manager; - DdNode *f, *var, *tmp; - int i; - - ... - - f = Cudd_ReadOne(manager); - Cudd_Ref(f); - for (i = 3; i >= 0; i--) { - var = Cudd_bddIthVar(manager,i); - tmp = Cudd_bddAnd(manager,Cudd_Not(var),f); - Cudd_Ref(tmp); - Cudd_RecursiveDeref(manager,f); - f = tmp; - } -</PRE> -This example illustrates the following points: - -<UL> -<LI>Intermediate results must be ``referenced'' and - ``dereferenced.'' However, <TT>var</TT> is a - projection<A NAME="314"></A> function, and its - reference<A NAME="315"></A> count is always greater than - 0. Therefore, there is no call to <I>Cudd_Ref</I><A NAME="1184"></A>. -</LI> -<LI>The new <TT>f</TT> must be assigned to a temporary variable - (<TT>tmp</TT> in this example). If the result of - <I>Cudd_bddAnd</I><A NAME="1186"></A> were assigned directly to - <TT>f</TT>, the old <TT>f</TT> would be lost, and there would be no - way to free its nodes. -</LI> -<LI>The statement <TT>f = tmp</TT> has the same effect as: -<PRE> - f = tmp; - Cudd_Ref(f); - Cudd_RecursiveDeref(manager,tmp); -</PRE> - but is more efficient. The reference<A NAME="327"></A> is - ``passed'' from <TT>tmp</TT> to <TT>f</TT>, and <TT>tmp</TT> is now - ready to be reutilized. -</LI> -<LI>It is normally more efficient to build BDDs ``bottom-up.'' This - is why the loop goes from 3 to 0. Notice, however, that after - variable reordering, higher index does not necessarily mean ``closer - to the bottom.'' Of course, in this simple example, efficiency is - not a concern. -</LI> -<LI>Had we wanted to conjoin the variables in a bottom-up fashion - even after reordering, we should have used - <I>Cudd_ReadInvPerm</I><A NAME="1188"></A>. One has to be - careful, though, to fix the order of conjunction before entering the - loop. Otherwise, if reordering takes place, it is possible to use - one variable twice and skip another variable. -</LI> -</UL> - -<P> - -<H2><A NAME="SECTION00038000000000000000"></A> -<A NAME="335"></A><A NAME="sec:basicADD"></A> -<BR> -Basic ADD Manipulation -</H2> - -<P> -The most common way to manipulate ADDs is via -<I>Cudd_addApply</I><A NAME="1190"></A>. This function can apply a -wide variety of operators to a pair of ADDs. Among the available -operators are addition, multiplication, division, minimum, maximum, -and boolean operators that work on ADDs whose leaves are restricted to -0 and 1 (0-1 ADDs). - -<P> -The following fragment of code illustrates how to build the ADD for -the function <!-- MATH - $f = 5x_0x_1x_2x_3$ - --> -<IMG - WIDTH="117" HEIGHT="33" ALIGN="MIDDLE" BORDER="0" - SRC="img13.png" - ALT="$f = 5x_0x_1x_2x_3$">. -<PRE> - DdManager *manager; - DdNode *f, *var, *tmp; - int i; - - ... - - f = Cudd_addConst(manager,5); - Cudd_Ref(f); - for (i = 3; i >= 0; i--) { - var = Cudd_addIthVar(manager,i); - Cudd_Ref(var); - tmp = Cudd_addApply(manager,Cudd_addTimes,var,f); - Cudd_Ref(tmp); - Cudd_RecursiveDeref(manager,f); - Cudd_RecursiveDeref(manager,var); - f = tmp; - } -</PRE> -This example, contrasted to the example of BDD manipulation, -illustrates the following points: - -<UL> -<LI>The ADD projection<A NAME="342"></A> function are not - maintained by the manager. It is therefore necessary to - reference<A NAME="343"></A> and - dereference<A NAME="344"></A> them. -</LI> -<LI>The product of two ADDs is computed by calling - <I>Cudd_addApply</I><A NAME="1192"></A> with - <I>Cudd_addTimes</I><A NAME="1194"></A> as parameter. There is - no ``apply'' function for BDDs, because - <I>Cudd_bddAnd</I><A NAME="1196"></A> and - <I>Cudd_bddXor</I><A NAME="1198"></A> plus complementation are - sufficient to implement all two-argument boolean functions. -</LI> -</UL> - -<P> - -<H2><A NAME="SECTION00039000000000000000"></A> -<A NAME="355"></A><A NAME="sec:basicZDD"></A> -<BR> -Basic ZDD Manipulation -</H2> - -<P> -ZDDs are often generated by converting<A NAME="357"></A> -existing BDDs. (See Section <A HREF="#sec:convertZ">3.11</A>.) However, it is also -possible to build ZDDs by applying boolean operators to other ZDDs, -starting from constants and projection<A NAME="359"></A> -functions. The following fragment of code illustrates how to build -the ZDD for the function <!-- MATH - $f = x_0'+x_1'+x_2'+x_3'$ - --> -<IMG - WIDTH="172" HEIGHT="35" ALIGN="MIDDLE" BORDER="0" - SRC="img14.png" - ALT="$f = x_0'+x_1'+x_2'+x_3'$">. We assume that the -four variables already exist in the manager when the ZDD for <IMG - WIDTH="15" HEIGHT="33" ALIGN="MIDDLE" BORDER="0" - SRC="img8.png" - ALT="$f$"> is -built. Note the use of De Morgan's law. -<PRE> - DdManager *manager; - DdNode *f, *var, *tmp; - int i; - - manager = Cudd_Init(0,4,CUDD_UNIQUE_SLOTS, - CUDD_CACHE_SLOTS,0); - ... - - tmp = Cudd_ReadZddOne(manager,0); - Cudd_Ref(tmp); - for (i = 3; i >= 0; i--) { - var = Cudd_zddIthVar(manager,i); - Cudd_Ref(var); - f = Cudd_zddIntersect(manager,var,tmp); - Cudd_Ref(f); - Cudd_RecursiveDerefZdd(manager,tmp); - Cudd_RecursiveDerefZdd(manager,var); - tmp = f; - } - f = Cudd_zddDiff(manager,Cudd_ReadZddOne(manager,0),tmp); - Cudd_Ref(f); - Cudd_RecursiveDerefZdd(manager,tmp); -</PRE> -This example illustrates the following points: - -<UL> -<LI>The projection<A NAME="363"></A> functions are - referenced, because they are not maintained by the manager. -</LI> -<LI>Complementation is obtained by subtracting from the constant 1 - function. -</LI> -<LI>The result of <I>Cudd_ReadZddOne</I><A NAME="1200"></A> - does not require referencing. -</LI> -</UL> -CUDD provides functions for the manipulation of -covers<A NAME="367"></A> represented by ZDDs. For instance, -<I>Cudd_zddIsop</I><A NAME="1202"></A> builds a ZDD representing an -irredundant<A NAME="370"></A> sum of products for the -incompletely specified function defined by the two BDDs <IMG - WIDTH="16" HEIGHT="15" ALIGN="BOTTOM" BORDER="0" - SRC="img15.png" - ALT="$L$"> and <IMG - WIDTH="18" HEIGHT="15" ALIGN="BOTTOM" BORDER="0" - SRC="img16.png" - ALT="$U$">. -<I>Cudd_zddWeakDiv</I><A NAME="1204"></A> performs the weak -division of two covers given as ZDDs. These functions expect the two -ZDD variables corresponding to the two literals of the function -variable to be adjacent. One has to create variable groups (see -Section <A HREF="#sec:reordZ">3.14</A>) for reordering<A NAME="374"></A> of -the ZDD variables to work. BDD automatic reordering is safe even -without groups: If realignment of ZDD and ADD/BDD variables is -requested (see Section <A HREF="#sec:consist">3.15</A>) groups will be kept -adjacent. - -<P> - -<H2><A NAME="SECTION000310000000000000000"></A> -<A NAME="377"></A> -<A NAME="378"></A><A NAME="sec:convert"></A> -<BR> -Converting ADDs to BDDs and Vice Versa -</H2> - -<P> -Several procedures are provided to convert ADDs to BDDs, according to -different criteria. -(<I>Cudd_addBddPattern</I><A NAME="1206"></A>, -<I>Cudd_addBddInterval</I><A NAME="1208"></A>, and -<I>Cudd_addBddThreshold</I><A NAME="1210"></A>.) The -conversion from BDDs to ADDs -(<I>Cudd_BddToAdd</I><A NAME="1212"></A>) is based on the simple -principle of mapping the logical 0<A NAME="388"></A> and 1 on the -arithmetic<A NAME="389"></A> 0 and 1. It is also possible to -convert an ADD with integer values (more precisely, floating point -numbers with 0 fractional part) to an array of BDDs by repeatedly -calling <I>Cudd_addIthBit</I><A NAME="1214"></A>. - -<P> - -<H2><A NAME="SECTION000311000000000000000"></A> -<A NAME="393"></A> -<A NAME="394"></A><A NAME="sec:convertZ"></A> -<BR> -Converting BDDs to ZDDs and Vice Versa -</H2> - -<P> -Many applications first build a set of BDDs and then derive ZDDs from -the BDDs. These applications should create the manager with 0 -ZDD<A NAME="396"></A> variables and create the BDDs. Then they should call -<I>Cudd_zddVarsFromBddVars</I><A NAME="1216"></A> to -create the necessary ZDD variables--whose number is likely to be -known once the BDDs are available. This approach eliminates the -difficulties that arise when the number of ZDD variables changes while -ZDDs are being built. - -<P> -The simplest conversion from BDDs to ZDDs is a simple change of -representation, which preserves the functions. Simply put, given a BDD -for <IMG - WIDTH="15" HEIGHT="33" ALIGN="MIDDLE" BORDER="0" - SRC="img8.png" - ALT="$f$">, a ZDD for <IMG - WIDTH="15" HEIGHT="33" ALIGN="MIDDLE" BORDER="0" - SRC="img8.png" - ALT="$f$"> is requested. In this case the correspondence -between the BDD variables and ZDD variables is one-to-one. Hence, -<I>Cudd_zddVarsFromBddVars</I> should be called with the -<I>multiplicity</I> parameter equal to 1. The conversion proper can -then be performed by calling -<I>Cudd_zddPortFromBdd</I><A NAME="1218"></A>. The inverse -transformation is performed by -<I>Cudd_zddPortToBdd</I><A NAME="1220"></A>. - -<P> -ZDDs are quite often used for the representation of -<I>covers</I><A NAME="406"></A>. This is normally done by -associating two ZDD variables to each variable of the function. (And -hence, typically, to each BDD variable.) One ZDD variable is -associated with the positive literal of the BDD variable, while the -other ZDD variable is associated with the negative literal. A call to -<I>Cudd_zddVarsFromBddVars</I><A NAME="1222"></A> with -<I>multiplicity</I> equal to 2 will associate to BDD variable <IMG - WIDTH="10" HEIGHT="15" ALIGN="BOTTOM" BORDER="0" - SRC="img6.png" - ALT="$i$"> the -two ZDD variables <IMG - WIDTH="19" HEIGHT="15" ALIGN="BOTTOM" BORDER="0" - SRC="img17.png" - ALT="$2i$"> and <IMG - WIDTH="49" HEIGHT="32" ALIGN="MIDDLE" BORDER="0" - SRC="img18.png" - ALT="$2i+1$">. - -<P> -If a BDD variable group tree exists when -<I>Cudd_zddVarsFromBddVars</I> is called (see -Section <A HREF="#sec:group">3.13</A>) the function generates a ZDD variable group -tree consistent to it. In any case, all the ZDD variables derived -from the same BDD variable are clustered into a group. - -<P> -If the ZDD for <IMG - WIDTH="15" HEIGHT="33" ALIGN="MIDDLE" BORDER="0" - SRC="img8.png" - ALT="$f$"> is created and later a new ZDD variable is added to -the manager, the function represented by the existing ZDD changes. -Suppose, for instance, that two variables are initially created, and -that the ZDD for <IMG - WIDTH="94" HEIGHT="33" ALIGN="MIDDLE" BORDER="0" - SRC="img19.png" - ALT="$f = x_0 + x_1$"> is built. If a third variable is -added, say <IMG - WIDTH="22" HEIGHT="32" ALIGN="MIDDLE" BORDER="0" - SRC="img20.png" - ALT="$x_2$">, then the ZDD represents <!-- MATH - $g = (x_0 + x_1) x_2'$ - --> -<IMG - WIDTH="124" HEIGHT="35" ALIGN="MIDDLE" BORDER="0" - SRC="img21.png" - ALT="$g = (x_0 + x_1) x_2'$"> -instead. This change in function obviously applies regardless of what -use is made of the ZDD. However, if the ZDD is used to represent a -cover<A NAME="412"></A>, the cover itself is not changed by the -addition of new variable. (What changes is the -characteristic<A NAME="413"></A> function of the cover.) - -<P> - -<H2><A NAME="SECTION000312000000000000000"></A> -<A NAME="415"></A><A NAME="sec:reorder"></A> -<BR> -Variable Reordering for BDDs and ADDs -</H2> - -<P> -The CUDD package provides a rich set of -dynamic<A NAME="417"></A> reordering algorithms. Some of them -are slight variations of existing techniques -[<A - HREF="node7.html#Rudell93">16</A>,<A - HREF="node7.html#Drechs95">6</A>,<A - HREF="node7.html#Bollig95">2</A>,<A - HREF="node7.html#Ishiur91">10</A>,<A - HREF="node7.html#Plessi93">15</A>,<A - HREF="node7.html#Jeong93">11</A>]; some -others have been developed specifically for this package -[<A - HREF="node7.html#Panda94">14</A>,<A - HREF="node7.html#Panda95b">13</A>]. - -<P> -Reordering affects a unique<A NAME="420"></A> table. This means that -BDDs and ADDs, which share the same unique table are simultaneously -reordered. ZDDs, on the other hand, are reordered separately. In the -following we discuss the reordering of BDDs and ADDs. Reordering for -ZDDs is the subject of Section <A HREF="#sec:reordZ">3.14</A>. - -<P> -Reordering of the variables can be invoked directly by the application -by calling <I>Cudd_ReduceHeap</I><A NAME="1224"></A>. Or it can -be automatically triggered by the package when the number of nodes has -reached a given threshold<A NAME="424"></A>. (The threshold -is initialized and automatically adjusted after each reordering by the -package.) To enable automatic dynamic reordering (also called -<I>asynchronous<A NAME="425"></A></I> dynamic reordering -in this document) the application must call -<I>Cudd_AutodynEnable</I><A NAME="1226"></A>. Automatic -dynamic reordering can subsequently be disabled by calling -<I>Cudd_AutodynDisable</I><A NAME="1228"></A>. - -<P> -All reordering methods are available in both the case of direct call -to <I>Cudd_ReduceHeap</I><A NAME="1230"></A> and the case of -automatic invocation. For many methods, the reordering procedure is -iterated until no further improvement is obtained. We call these -methods the <I>converging<A NAME="432"></A></I> methods. -When constraints are imposed on the relative position of variables -(see Section <A HREF="#sec:group">3.13</A>) the reordering methods apply inside the -groups. The groups<A NAME="434"></A> themselves are reordered -by sifting<A NAME="435"></A>. Each method is identified by a -constant of the enumerated type -<I>Cudd_ReorderingType<A NAME="436"></A></I> -defined in <I>cudd.h<A NAME="437"></A></I> (the external -header<A NAME="438"></A> file of the CUDD package): - -<P> -<DL> -<DT><STRONG>CUDD_REORDER_NONE<A NAME="440"></A>:</STRONG></DT> -<DD>This method - causes no reordering. -</DD> -<DT><STRONG>CUDD_REORDER_SAME<A NAME="441"></A>:</STRONG></DT> -<DD>If passed to - <I>Cudd_AutodynEnable</I><A NAME="1232"></A>, this - method leaves the current method for automatic reordering unchanged. - If passed to <I>Cudd_ReduceHeap</I><A NAME="1234"></A>, - this method causes the current method for automatic reordering to be - used. -</DD> -<DT><STRONG>CUDD_REORDER_RANDOM<A NAME="446"></A>:</STRONG></DT> -<DD>Pairs of - variables are randomly chosen, and swapped in the order. The swap is - performed by a series of swaps of adjacent variables. The best order - among those obtained by the series of swaps is retained. The number - of pairs chosen for swapping<A NAME="447"></A> equals the - number of variables in the diagram. -</DD> -<DT><STRONG>CUDD_REORDER_RANDOM_PIVOT<A NAME="448"></A>:</STRONG></DT> -<DD>Same as CUDD_REORDER_RANDOM, but the two variables are chosen so - that the first is above the variable with the largest number of - nodes, and the second is below that variable. In case there are - several variables tied for the maximum number of nodes, the one - closest to the root is used. -</DD> -<DT><STRONG>CUDD_REORDER_SIFT<A NAME="449"></A>:</STRONG></DT> -<DD>This method is - an implementation of Rudell's sifting<A NAME="450"></A> - algorithm [<A - HREF="node7.html#Rudell93">16</A>]. A simplified description of sifting is as - follows: Each variable is considered in turn. A variable is moved up - and down in the order so that it takes all possible positions. The - best position is identified and the variable is returned to that - position. - -<P> -In reality, things are a bit more complicated. For instance, there - is a limit on the number of variables that will be sifted. This - limit can be read with - <I>Cudd_ReadSiftMaxVar</I><A NAME="1236"></A> and set with - <I>Cudd_SetSiftMaxVar</I><A NAME="1238"></A>. In addition, - if the diagram grows too much while moving a variable up or down, - that movement is terminated before the variable has reached one end - of the order. The maximum ratio by which the diagram is allowed to - grow while a variable is being sifted can be read with - <I>Cudd_ReadMaxGrowth</I><A NAME="1240"></A> and set with - <I>Cudd_SetMaxGrowth</I><A NAME="1242"></A>. -</DD> -<DT><STRONG>CUDD_REORDER_SIFT_CONVERGE<A NAME="460"></A>:</STRONG></DT> -<DD>This is the converging<A NAME="461"></A> variant of - CUDD_REORDER_SIFT. -</DD> -<DT><STRONG>CUDD_REORDER_SYMM_SIFT<A NAME="462"></A>:</STRONG></DT> -<DD>This method is an implementation of - symmetric<A NAME="463"></A> sifting [<A - HREF="node7.html#Panda94">14</A>]. It is - similar to sifting, with one addition: Variables that become - adjacent during sifting are tested for symmetry<A NAME="465"></A>. If - they are symmetric, they are linked in a group. Sifting then - continues with a group being moved, instead of a single variable. - After symmetric sifting has been run, - <I>Cudd_SymmProfile</I><A NAME="1244"></A> can be called to - report on the symmetry groups found. (Both positive and negative - symmetries are reported.) -</DD> -<DT><STRONG>CUDD_REORDER_SYMM_SIFT_CONV<A NAME="468"></A>:</STRONG></DT> -<DD>This is the converging<A NAME="469"></A> variant of - CUDD_REORDER_SYMM_SIFT. -</DD> -<DT><STRONG>CUDD_REORDER_GROUP_SIFT<A NAME="470"></A>:</STRONG></DT> -<DD>This method is an implementation of group<A NAME="471"></A> - sifting [<A - HREF="node7.html#Panda95b">13</A>]. It is similar to symmetric sifting, but - aggregation<A NAME="473"></A> is not restricted to symmetric - variables. -</DD> -<DT><STRONG>CUDD_REORDER_GROUP_SIFT_CONV<A NAME="474"></A>:</STRONG></DT> -<DD>This method repeats until convergence the combination of - CUDD_REORDER_GROUP_SIFT and CUDD_REORDER_WINDOW4. -</DD> -<DT><STRONG>CUDD_REORDER_WINDOW2<A NAME="475"></A>:</STRONG></DT> -<DD>This - method implements the window<A NAME="476"></A> permutation - approach of Fujita [<A - HREF="node7.html#Fujita91b">8</A>] and Ishiura [<A - HREF="node7.html#Ishiur91">10</A>]. - The size of the window is 2. -</DD> -<DT><STRONG>CUDD_REORDER_WINDOW3<A NAME="479"></A>:</STRONG></DT> -<DD>Similar - to CUDD_REORDER_WINDOW2, but with a window of size 3. -</DD> -<DT><STRONG>CUDD_REORDER_WINDOW4<A NAME="480"></A>:</STRONG></DT> -<DD>Similar - to CUDD_REORDER_WINDOW2, but with a window of size 4. -</DD> -<DT><STRONG>CUDD_REORDER_WINDOW2_CONV<A NAME="481"></A>:</STRONG></DT> -<DD>This is the converging<A NAME="482"></A> variant of - CUDD_REORDER_WINDOW2. -</DD> -<DT><STRONG>CUDD_REORDER_WINDOW3_CONV<A NAME="483"></A>:</STRONG></DT> -<DD>This is the converging variant of CUDD_REORDER_WINDOW3. -</DD> -<DT><STRONG>CUDD_REORDER_WINDOW4_CONV<A NAME="484"></A>:</STRONG></DT> -<DD>This is the converging variant of CUDD_REORDER_WINDOW4. -</DD> -<DT><STRONG>CUDD_REORDER_ANNEALING<A NAME="485"></A>:</STRONG></DT> -<DD>This - method is an implementation of simulated - annealing<A NAME="486"></A> for variable - ordering, vaguely resemblant of the algorithm of [<A - HREF="node7.html#Bollig95">2</A>]. - This method is potentially very slow. -</DD> -<DT><STRONG>CUDD_REORDER_GENETIC:<A NAME="488"></A></STRONG></DT> -<DD>This - method is an implementation of a genetic<A NAME="489"></A> - algorithm for variable ordering, inspired by the work of Drechsler - [<A - HREF="node7.html#Drechs95">6</A>]. This method is potentially very slow. -</DD> -<DT><STRONG>CUDD_REORDER_EXACT<A NAME="491"></A>:</STRONG></DT> -<DD>This method - implements a dynamic programming approach to - exact<A NAME="492"></A> reordering - [<A - HREF="node7.html#Held62">9</A>,<A - HREF="node7.html#Friedman90">7</A>,<A - HREF="node7.html#Ishiur91">10</A>], with improvements described in - [<A - HREF="node7.html#Jeong93">11</A>]. It only stores one BDD at the time. Therefore, it is - relatively efficient in terms of memory. Compared to other - reordering strategies, it is very slow, and is not recommended for - more than 16 variables. -</DD> -</DL> -So far we have described methods whereby the package selects an order -automatically. A given order of the variables can also be imposed by -calling <I>Cudd_ShuffleHeap</I><A NAME="1246"></A>. - -<P> - -<H2><A NAME="SECTION000313000000000000000"></A> -<A NAME="499"></A><A NAME="sec:group"></A> -<BR> -Grouping Variables -</H2> - -<P> -CUDD allows the application to specify constraints on the positions of -group of variables. It is possible to request that a group of -contiguous variables be kept contiguous by the reordering procedures. -It is also possible to request that the relative order of some groups -of variables be left unchanged. The constraints on the order are -specified by means of a tree<A NAME="501"></A>, which is created in -one of two ways: - -<UL> -<LI>By calling <I>Cudd_MakeTreeNode</I><A NAME="1248"></A>. -</LI> -<LI>By calling the functions of the MTR<A NAME="505"></A> library - (part of the distribution), and by registering the result with the - manager using <I>Cudd_SetTree</I><A NAME="1250"></A>. The current - tree registered with the manager can be read with - <I>Cudd_ReadTree</I><A NAME="1252"></A>. -</LI> -</UL> - -<P> -Each node in the tree represents a range of variables. The lower bound -of the range is given by the <I>low</I> field of the node, and the -size of the group is given by the <I>size</I> field of the -node.<A NAME="tex2html4" - HREF="footnode.html#foot1083"><SUP>2</SUP></A> The variables -in each range are kept contiguous. Furthermore, if a node is marked -with the MTR_FIXED<A NAME="515"></A> flag, then the relative order of -the variable ranges associated to its children is not changed. As an -example, suppose the initial variable order is: -<PRE> - x0, y0, z0, x1, y1, z1, ... , x9, y9, z9. -</PRE> -Suppose we want to keep each group of three variables with the same -index (e.g., <code>x3, y3, z3</code>) contiguous, while allowing the package -to change the order of the groups. We can accomplish this with the -following code: -<PRE> - for (i = 0; i < 10; i++) { - (void) Cudd_MakeTreeNode(manager,i*3,3,MTR_DEFAULT); - } -</PRE> -If we want to keep the order within each group of variables -fixed (i.e., <code>x</code> before <code>y</code> before <code>z</code>) we need to -change MTR_DEFAULT<A NAME="520"></A> into MTR_FIXED. - -<P> -The <I>low</I> parameter passed to -<I>Cudd_MakeTreeNode</I><A NAME="1254"></A> is the index of a -variable (as opposed to its level or position in the order). The -group tree<A NAME="524"></A> can be created at any time. The -result obviously depends on the variable order in effect at creation -time. - -<P> -It is possible to create a variable group tree also before the -variables themselves are created. The package assumes in this case -that the index of the variables not yet in existence will equal their -position in the order when they are created. Therefore, applications -that rely on -<I>Cudd_bddNewVarAtLevel</I><A NAME="1256"></A> or -<I>Cudd_addNewVarAtLevel</I><A NAME="1258"></A> to create -new variables have to create the variables before they group them. - -<P> -The reordering procedure will skip all groups whose variables are not -yet in existence. For groups that are only partially in existence, the -reordering procedure will try to reorder the variables already -instantiated, without violating the adjacency constraints. - -<P> - -<H2><A NAME="SECTION000314000000000000000"></A> -<A NAME="530"></A><A NAME="sec:reordZ"></A> -<BR> -Variable Reordering for ZDDs -</H2> - -<P> -Reordering of ZDDs is done in much the same way as the reordering of -BDDs and ADDs. The functions corresponding to <I>Cudd_ReduceHeap</I> -and <I>Cudd_ShuffleHeap</I> are -<I>Cudd_zddReduceHeap</I><A NAME="1260"></A> and -<I>Cudd_zddShuffleHeap</I><A NAME="1262"></A>. To enable -dynamic<A NAME="538"></A> reordering, the application must -call <I>Cudd_AutodynEnableZdd</I><A NAME="1264"></A>, and -to disable dynamic reordering, it must call -<I>Cudd_AutodynDisableZdd</I><A NAME="1266"></A>. In the -current implementation, however, the choice of reordering methods for -ZDDs is more limited. Specifically, these methods are available: - -<P> -<DL> -<DT><STRONG>CUDD_REORDER_NONE<A NAME="544"></A>;</STRONG></DT> -<DD> -</DD> -<DT><STRONG>CUDD_REORDER_SAME<A NAME="545"></A>;</STRONG></DT> -<DD> -</DD> -<DT><STRONG>CUDD_REORDER_RANDOM<A NAME="546"></A>;</STRONG></DT> -<DD> -</DD> -<DT><STRONG>CUDD_REORDER_RANDOM_PIVOT<A NAME="547"></A>;</STRONG></DT> -<DD> -</DD> -<DT><STRONG>CUDD_REORDER_SIFT<A NAME="548"></A>;</STRONG></DT> -<DD> -</DD> -<DT><STRONG>CUDD_REORDER_SIFT_CONVERGE<A NAME="549"></A>;</STRONG></DT> -<DD> -</DD> -<DT><STRONG>CUDD_REORDER_SYMM_SIFT<A NAME="550"></A>;</STRONG></DT> -<DD> -</DD> -<DT><STRONG>CUDD_REORDER_SYMM_SIFT_CONV<A NAME="551"></A>.</STRONG></DT> -<DD> -</DD> -</DL> - -<P> -To create ZDD variable groups, the application calls -<I>Cudd_MakeZddTreeNode</I><A NAME="1268"></A>. - -<P> - -<H2><A NAME="SECTION000315000000000000000"></A> -<A NAME="sec:consist"></A> -<BR> -Keeping Consistent Variable Orders for BDDs and ZDDs -</H2> - -<P> -Several applications that manipulate both BDDs and ZDDs benefit from -keeping a fixed correspondence between the order of the BDD variables -and the order of the ZDD variables. If each BDD variable corresponds -to a group of ZDD variables, then it is often desirable that the -groups of ZDD variables be in the same order as the corresponding BDD -variables. CUDD allows the ZDD order to track the BDD order and vice -versa. To have the ZDD order track the BDD order, the application -calls <I>Cudd_zddRealignEnable</I><A NAME="1270"></A>. The -effect of this call can be reversed by calling -<I>Cudd_zddRealignDisable</I><A NAME="1272"></A>. When -ZDD realignment is in effect, automatic reordering of ZDDs should be -disabled. - -<P> - -<H2><A NAME="SECTION000316000000000000000"></A> -<A NAME="562"></A><A NAME="sec:hooks"></A> -<BR> -Hooks -</H2> - -<P> -Hooks in CUDD are lists of application-specified functions to be run on -certain occasions. Each hook is identified by a constant of the -enumerated type <I>Cudd_HookType</I><A NAME="1274"></A>. In Version -2.5.0 hooks are defined for these occasions: - -<UL> -<LI>before garbage collection (CUDD_PRE_GC_HOOK); -</LI> -<LI>after garbage collection (CUDD_POST_GC_HOOK); -</LI> -<LI>before variable reordering (CUDD_PRE_REORDERING_HOOK); -</LI> -<LI>after variable reordering (CUDD_POST_REORDERING_HOOK). -</LI> -</UL> -The current implementation of hooks is experimental. A function added -to a hook receives a pointer to the manager, a pointer to a constant -string, and a pointer to void as arguments; it must return 1 if -successful; 0 otherwise. The second argument is one of ``DD,'' -``BDD,'' and ``ZDD.'' This allows the hook functions to tell the type -of diagram for which reordering or garbage collection takes place. The -third argument varies depending on the hook. The hook functions called -before or after garbage collection<A NAME="568"></A> do -not use it. The hook functions called before -reordering<A NAME="569"></A> are passed, in addition to the -pointer to the manager, also the method used for reordering. The hook -functions called after reordering are passed the start time. To add a -function to a hook, one uses <I>Cudd_AddHook</I><A NAME="1276"></A>. -The function of a given hook -are called in the order in which they were added to the hook. For -sample hook functions, one may look at -<I>Cudd_StdPreReordHook</I><A NAME="1278"></A> and -<I>Cudd_StdPostReordHook</I><A NAME="1280"></A>. - -<P> - -<H2><A NAME="SECTION000317000000000000000"></A> -<A NAME="577"></A><A NAME="sec:timeouts"></A> -<BR> -Timeouts and Limits -</H2> - -<P> -It is possible to set a time limit for a manger with -<I>Cudd_SetTimeLimit</I><A NAME="1282"></A>. Once set, the -time available to the manager can be modified through other API -functions. CUDD checks for expiration periodically. When time has -expired, it returns NULL from the call in progress, but it leaves the -manager in a consistent state. The invoking application must be -designed to handle the NULL values returned. - -<P> -When reordering, if a timout is approaching, CUDD will quit reordering -to give the application a chance to finish some computation. - -<P> -It is also possible to invoke some functions that return NULL if they -cannot complete without creating more than a set number of nodes. -See, for instance, <I>Cudd_bddAndLimit</I><A NAME="1284"></A>. - -<P> - -<H2><A NAME="SECTION000318000000000000000"></A> -<A NAME="584"></A><A NAME="585"></A><A NAME="sec:sis-vis"></A> -<BR> -The SIS/VIS Interface -</H2> - -<P> -The CUDD package contains interface functions that emulate the -behavior of the original BDD package used in SIS [<A - HREF="node7.html#Sentov92">17</A>] and -in the newer -<A NAME="tex2html5" - HREF="http://vlsi.Colorado.EDU/~vis/">VIS</A> -[<A - HREF="node7.html#VIS">4</A>]. How to build VIS with CUDD is described -in the installation documents of VIS. (Version 1.1 and later.) - -<P> - -<H3><A NAME="SECTION000318100000000000000"></A> -<A NAME="592"></A><A NAME="sec:sis"></A> -<BR> -Using the CUDD Package in SIS -</H3> - -<P> -This section describes how to build SIS with the CUDD package. Let -<TT>SISDIR<A NAME="594"></A></TT> designate the root of the directory -hierarchy where the sources for SIS reside. Let -<TT>CUDDDIR<A NAME="595"></A></TT> be the root of the directory hierarchy -where the distribution of the CUDD package resides. To build SIS with -the CUDD package, follow these steps. - -<OL> -<LI>Create directories <TT>SISDIR/sis/cudd</TT> and - <TT>SISDIR/sis/mtr</TT>. -</LI> -<LI>Copy all files from <TT>CUDDDIR/cudd</TT> and - <TT>CUDDDIR/sis</TT> to <TT>SISDIR/sis/cudd</TT> and all files from - <TT>CUDDDIR/mtr</TT> to <TT>SISDIR/sis/mtr</TT>. -</LI> -<LI>Copy <TT>CUDDDIR/cudd/doc/cudd.doc</TT> to - <TT>SISDIR/sis/cudd</TT>; also copy <TT>CUDDDIR/mtr/doc/mtr.doc</TT> - to <TT>SISDIR/sis/mtr</TT>. -</LI> -<LI>In <TT>SISDIR/sis/cudd</TT> make <TT>bdd.h</TT> a symbolic link - to <TT>cuddBdd.h</TT>. (That is: <TT>ln -s cuddBdd.h bdd.h</TT>.) -</LI> -<LI>In <TT>SISDIR/sis/cudd</TT> delete <TT>Makefile</TT> and rename - <TT>Makefile.sis</TT> as <TT>Makefile</TT>. Do the same in - <TT>SISDIR/sis/mtr</TT>. -</LI> -<LI>Copy <TT>CUDDDIR/sis/st.[ch]</TT> and <TT>CUDDDIR/st/doc/st.doc</TT> - to <TT>SISDIR/sis/st</TT>. (This will overwrite the original files: You - may want to save them beforehand.) -</LI> -<LI>From <TT>CUDDDIR/util</TT> copy <TT>datalimit.c</TT> to - <TT>SISDIR/sis/util</TT>. Update <TT>util.h</TT> and - <TT>Makefile</TT> in <TT>SISDIR/sis/util</TT>. Specifically, add the - declaration <TT>EXTERN long getSoftDataLimit();</TT> to - <TT>util.h</TT> and add <TT>datalimit.c</TT> to the list of source - files (PSRC) in <TT>Makefile</TT>. -</LI> -<LI>In <TT>SISDIR/sis</TT> remove the link from <TT>bdd</TT> to - <TT>bdd_cmu</TT> or <TT>bdd_ucb</TT> (that is, <TT>rm bdd</TT>) - and make <TT>bdd</TT> a symbolic link to <TT>cudd</TT>. (That is: - <TT>ln -s cudd bdd</TT>.) -</LI> -<LI>Still in <TT>SISDIR/sis</TT>, edit <TT>Makefile</TT>, <TT>Makefile.oct</TT>, and <TT>Makefile.nooct</TT>. In all three files add - mtr to the list of directories to be made (DIRS). -</LI> -<LI>In <TT>SISDIR/sis/include</TT> make <TT>mtr.h</TT> a symbolic - link to <TT>../mtr/mtr.h</TT>. -</LI> -<LI>In <TT>SISDIR/sis/doc</TT> make <TT>cudd.doc</TT> a symbolic - link to <TT>../cudd/cudd.doc</TT> and <TT>mtr.doc</TT> a symbolic - link to <TT>../mtr/mtr.doc</TT>. (That is: <TT>ln -s - ../cudd/cudd.doc .; ln -s ../mtr/mtr.doc .</TT>.) -</LI> -<LI>From <TT>SISDIR</TT> do <TT>make clean</TT> followed by - <TT>make -i</TT>. This should create a working copy of SIS that - uses the CUDD package. -</LI> -</OL> - -<P> -The replacement for the <TT>st</TT> library is because the version -shipped with the CUDD package tests for out-of-memory conditions. -Notice that the version of the <TT>st</TT> library to be used for -replacement is not the one used for the normal build, because the -latter has been modified for C++ compatibility. The above installation -procedure has been tested on SIS 1.3. SIS can be obtained via -anonymous FTP<A NAME="657"></A> from -<A NAME="tex2html6" - HREF="ftp://ic.eecs.berkeley.edu"><TT>ic.eecs.berkeley.edu</TT></A>. -To build SIS 1.3, you need <TT>sis-1.2.tar.Z</TT> and -<TT>sis-1.2.patch1.Z</TT>. When compiling on a DEC Alpha<A NAME="662"></A>, you should add the <TT>-ieee_with_no_inexact</TT> flag. -(See Section <A HREF="#sec:predef-const">3.5.2</A>.) Refer to the <TT>Makefile</TT> -in the top level directory of the distribution for how to compile with -32-bit pointers. - -<P> - -<H2><A NAME="SECTION000319000000000000000"></A> -<A NAME="sec:dump"></A> -<BR> -Writing Decision Diagrams to a File -</H2> - -<P> -The CUDD package provides several functions to write decision diagrams -to a file. <I>Cudd_DumpBlif</I><A NAME="1286"></A> writes a -file in <I>blif</I> format. It is restricted to BDDs. The diagrams -are written as a network of multiplexers, one multiplexer for each -internal node of the BDD. - -<P> -<I>Cudd_DumpDot</I><A NAME="1288"></A> produces input suitable to -the graph-drawing<A NAME="673"></A> program -<A NAME="tex2html8" - HREF="http://www.research.att.com/sw/tools/graphviz"><I>dot</I></A> -written by Eleftherios Koutsofios and Stephen C. North. An example of -drawing produced by dot from the output of <I>Cudd_DumpDot</I> is -shown in Figure <A HREF="#fi:phase">1</A>. It is restricted to BDDs and ADDs. - -<DIV ALIGN="CENTER"><A NAME="fi:phase"></A><A NAME="1089"></A> -<TABLE> -<CAPTION ALIGN="BOTTOM"><STRONG>Figure 1:</STRONG> -A BDD representing a phase constraint for the optimization of - fixed-polarity Reed-Muller forms. The label of each node is the - unique part of the node address. All nodes on the same level - correspond to the same variable, whose name is shown at the left of - the diagram. Dotted lines indicate complement<A NAME="680"></A> - arcs. Dashed lines indicate regular<A NAME="681"></A> ``else'' - arcs.</CAPTION> -<TR><TD> -<DIV ALIGN="CENTER"> -<IMG - WIDTH="429" HEIGHT="701" ALIGN="BOTTOM" BORDER="0" - SRC="img22.png" - ALT="\includegraphics[height=15.5cm]{phase.ps}"></DIV></TD></TR> -</TABLE> -</DIV> - -<I>Cudd_zddDumpDot</I><A NAME="1290"></A> is the analog of -<I>Cudd_DumpDot</I> for ZDDs. - -<P> -<I>Cudd_DumpDaVinci</I><A NAME="1292"></A> produces input -suitable to the graph-drawing<A NAME="689"></A> program -<A NAME="tex2html9" - HREF="ftp://ftp.uni-bremen.de/pub/graphics/daVinci"><I>daVinci</I></A> -developed at the University of Bremen. It is restricted to BDDs and -ADDs. - -<P> -Functions are also available to produce the input format of -<I>DDcal</I> (see Section <A HREF="node2.html#sec:getFriends">2.2</A>) and factored forms. - -<P> - -<H2><A NAME="SECTION000320000000000000000"></A> -<A NAME="sec:save-restore"></A> -<BR> -Saving and Restoring BDDs -</H2> - -<P> -The -<A NAME="tex2html10" - HREF="ftp://ftp.polito.it/pub/research/dddmp/"><I>dddmp</I></A> -library<A NAME="698"></A> by Gianpiero Cabodi and Stefano Quer -allows a CUDD application to save BDDs to disk in compact form for -later retrieval. See the library's own documentation for the details. - -<P> -<HR> -<!--Navigation Panel--> -<A NAME="tex2html112" - HREF="node4.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html108" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html102" - HREF="node2.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html110" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html113" - HREF="node4.html">Programmer's Manual</A> -<B> Up:</B> <A NAME="tex2html109" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html103" - HREF="node2.html">How to Get CUDD</A> - <B> <A NAME="tex2html111" - HREF="node8.html">Index</A></B> -<!--End of Navigation Panel--> -<ADDRESS> -Fabio Somenzi -2012-02-04 -</ADDRESS> -</BODY> -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node4.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node4.html deleted file mode 100644 index e1697b331..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node4.html +++ /dev/null @@ -1,1165 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> - -<!--Converted with LaTeX2HTML 2008 (1.71) -original version by: Nikos Drakos, CBLU, University of Leeds -* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan -* with significant contributions from: - Jens Lippmann, Marek Rouchal, Martin Wilck and others --> -<HTML> -<HEAD> -<TITLE>Programmer's Manual</TITLE> -<META NAME="description" CONTENT="Programmer's Manual"> -<META NAME="keywords" CONTENT="cuddIntro"> -<META NAME="resource-type" CONTENT="document"> -<META NAME="distribution" CONTENT="global"> - -<META NAME="Generator" CONTENT="LaTeX2HTML v2008"> -<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> - -<LINK REL="STYLESHEET" HREF="cuddIntro.css"> - -<LINK REL="next" HREF="node5.html"> -<LINK REL="previous" HREF="node3.html"> -<LINK REL="up" HREF="cuddIntro.html"> -<LINK REL="next" HREF="node5.html"> -</HEAD> - -<BODY > -<!--Navigation Panel--> -<A NAME="tex2html154" - HREF="node5.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html150" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html144" - HREF="node3.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html152" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html155" - HREF="node5.html">The C++ Interface</A> -<B> Up:</B> <A NAME="tex2html151" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html145" - HREF="node3.html">User's Manual</A> - <B> <A NAME="tex2html153" - HREF="node8.html">Index</A></B> -<BR> -<BR> -<!--End of Navigation Panel--> -<!--Table of Child-Links--> -<A NAME="CHILD_LINKS"><STRONG>Subsections</STRONG></A> - -<UL> -<LI><A NAME="tex2html156" - HREF="node4.html#SECTION00041000000000000000">Compiling and Linking</A> -<LI><A NAME="tex2html157" - HREF="node4.html#SECTION00042000000000000000">Reference Counts</A> -<UL> -<LI><A NAME="tex2html158" - HREF="node4.html#SECTION00042100000000000000">NULL Return Values</A> -<LI><A NAME="tex2html159" - HREF="node4.html#SECTION00042200000000000000"><I>Cudd_RecursiveDeref</I> vs. <I>Cudd_Deref</I></A> -<LI><A NAME="tex2html160" - HREF="node4.html#SECTION00042300000000000000">When Increasing the Reference Count is Unnecessary</A> -<LI><A NAME="tex2html161" - HREF="node4.html#SECTION00042400000000000000">Saturating Increments and Decrements</A> -</UL> -<BR> -<LI><A NAME="tex2html162" - HREF="node4.html#SECTION00043000000000000000">Complement Arcs</A> -<LI><A NAME="tex2html163" - HREF="node4.html#SECTION00044000000000000000">The Cache</A> -<UL> -<LI><A NAME="tex2html164" - HREF="node4.html#SECTION00044100000000000000">Cache Sizing</A> -<LI><A NAME="tex2html165" - HREF="node4.html#SECTION00044200000000000000">Local Caches</A> -</UL> -<BR> -<LI><A NAME="tex2html166" - HREF="node4.html#SECTION00045000000000000000">The Unique Table</A> -<LI><A NAME="tex2html167" - HREF="node4.html#SECTION00046000000000000000">Allowing Asynchronous Reordering</A> -<LI><A NAME="tex2html168" - HREF="node4.html#SECTION00047000000000000000">Debugging</A> -<LI><A NAME="tex2html169" - HREF="node4.html#SECTION00048000000000000000">Gathering and Interpreting Statistics</A> -<UL> -<LI><A NAME="tex2html170" - HREF="node4.html#SECTION00048100000000000000">Non Modifiable Parameters</A> -<LI><A NAME="tex2html171" - HREF="node4.html#SECTION00048200000000000000">Modifiable Parameters</A> -<LI><A NAME="tex2html172" - HREF="node4.html#SECTION00048300000000000000">Extended Statistics and Reporting</A> -</UL> -<BR> -<LI><A NAME="tex2html173" - HREF="node4.html#SECTION00049000000000000000">Guidelines for Documentation</A> -</UL> -<!--End of Table of Child-Links--> -<HR> - -<H1><A NAME="SECTION00040000000000000000"></A> -<A NAME="sec:prog"></A> -<BR> -Programmer's Manual -</H1> - -<P> -This section provides additional detail on the working of the CUDD -package and on the programming conventions followed in its writing. -The additional detail should help those who want to write procedures -that directly manipulate the CUDD data structures. - -<P> - -<H2><A NAME="SECTION00041000000000000000"></A> -<A NAME="702"></A><A NAME="sec:compileInt"></A> -<BR> -Compiling and Linking -</H2> - -<P> -If you plan to use the CUDD package as a clear box<A NAME="704"></A> -(for instance, you want to write a procedure that traverses a decision -diagram) you need to add -<PRE> -#include "cuddInt.h" -</PRE> -to your source files. In addition, you should link <code>libcudd.a</code> to -your executable. Some platforms require specific compiler and linker -flags. Refer to the <TT>Makefile</TT> in the top level directory of -the distribution. - -<P> - -<H2><A NAME="SECTION00042000000000000000"></A> -<A NAME="709"></A><A NAME="sec:ref"></A> -<BR> -Reference Counts -</H2> - -<P> -Garbage<A NAME="711"></A> collection in the CUDD package is -based on reference counts. Each node stores the sum of the external -references and internal references. An internal BDD or ADD node is -created by a call to <I>cuddUniqueInter</I><A NAME="1294"></A>, an -internal ZDD node is created by a call to -<I>cuddUniqueInterZdd</I><A NAME="1296"></A>, and a -terminal<A NAME="716"></A> node is created by a call to -<I>cuddUniqueConst</I><A NAME="1298"></A>. If the node returned by -these functions is new, its reference count is zero. The function -that calls <I>cuddUniqueInter</I><A NAME="1300"></A>, -<I>cuddUniqueInterZdd</I><A NAME="1302"></A>, or -<I>cuddUniqueConst</I><A NAME="1304"></A> is responsible for -increasing the reference count of the node. This is accomplished by -calling <I>Cudd_Ref</I><A NAME="1306"></A>. - -<P> -When a function is no longer needed by an application, the memory used -by its diagram can be recycled by calling -<I>Cudd_RecursiveDeref</I><A NAME="1308"></A> (BDDs and ADDs) -or <I>Cudd_RecursiveDerefZdd</I><A NAME="1310"></A> -(ZDDs). These functions decrease the reference <A NAME="731"></A> count of the node passed to them. If the reference count -becomes 0, then two things happen: - -<OL> -<LI>The node is declared ``dead<A NAME="733"></A>;'' this entails - increasing the counters<A NAME="734"></A> of the dead - nodes. (One counter for the subtable<A NAME="735"></A> to which the - node belongs, and one global counter for the - unique<A NAME="736"></A> table to which the node belongs.) The - node itself is not affected. -</LI> -<LI>The function is recursively called on the two children of the - node. -</LI> -</OL> -For instance, if the diagram of a function does not share any nodes -with other diagrams, then calling -<I>Cudd_RecursiveDeref</I><A NAME="1312"></A> or -<I>Cudd_RecursiveDerefZdd</I><A NAME="1314"></A> on its -root will cause all the nodes of the diagram to become dead. - -<P> -When the number of dead nodes reaches a given level (dynamically -determined by the package) garbage collection takes place. During -garbage<A NAME="742"></A> collection dead nodes are returned -to the node free list<A NAME="743"></A>. - -<P> -When a new node is created, it is important to increase its -reference<A NAME="744"></A> count before one of the two -following events occurs: - -<OL> -<LI>A call to <I>cuddUniqueInter</I><A NAME="1316"></A>, - to <I>cuddUniqueInterZdd</I><A NAME="1318"></A>, to - <I>cuddUniqueConst</I><A NAME="1320"></A>, or to a - function that may eventually cause a call to them. -</LI> -<LI>A call to - <I>Cudd_RecursiveDeref</I><A NAME="1322"></A>, to - <I>Cudd_RecursiveDerefZdd</I><A NAME="1324"></A>, or to - a function that may eventually cause a call to them. -</LI> -</OL> -In practice, it is recommended to increase the reference count as soon -as the returned pointer has been tested for not being NULL. - -<P> - -<H3><A NAME="SECTION00042100000000000000"></A> -<A NAME="sec:null"></A> -<BR> -NULL Return Values -</H3> - -<P> -The interface to the memory management functions (e.g., malloc) used -by CUDD intercepts NULL return values and calls a handler. The -default handler exits with an error message. If the application does -not install another handler, therefore, a NULL return value from an -exported function of CUDD signals an internal error. - -<P> -If the aplication, however, installs another handler that lets -execution continue, a NULL pointer returned by an exported function -typically indicates that the process has run out of memory. -<I>Cudd_ReadErrorCode</I><A NAME="1326"></A> can be used to -ascertain the nature of the problem. - -<P> -An application that tests for the result being NULL can try some -remedial action, if it runs out of memory. For instance, it may free -some memory that is not strictly necessary, or try a slower algorithm -that takes less space. As an example, CUDD overrides the default -handler when trying to enlarge the cache or increase the number of -slots of the unique table. If the allocation fails, the package prints -out a message and continues without resizing the cache. - -<P> - -<H3><A NAME="SECTION00042200000000000000"></A> -<A NAME="sec:deref"></A> -<BR> -<I>Cudd_RecursiveDeref</I> vs. <I>Cudd_Deref</I> -</H3> - -<P> -It is often the case that a recursive procedure has to protect the -result it is going to return, while it disposes of intermediate -results. (See the previous discussion on when to increase reference -counts.) Once the intermediate results have been properly disposed -of, the final result must be returned to its pristine state, in which -the root node may have a reference count of 0. One cannot use -<I>Cudd_RecursiveDeref</I><A NAME="1328"></A> (or -<I>Cudd_RecursiveDerefZdd</I>) for this purpose, because it may -erroneously make some nodes dead. Therefore, the package provides a -different function: <I>Cudd_Deref</I><A NAME="1330"></A>. This -function is not recursive, and does not change the dead node counts. -Its use is almost exclusively the one just described: Decreasing the -reference count of the root of the final result before returning from -a recursive procedure. - -<P> - -<H3><A NAME="SECTION00042300000000000000"></A> -<A NAME="770"></A><A NAME="sec:noref"></A> -<BR> -When Increasing the Reference Count is Unnecessary -</H3> - -<P> -When a copy of a predefined constant<A NAME="772"></A> or of a -simple BDD variable is needed for comparison purposes, then calling -<I>Cudd_Ref</I><A NAME="1332"></A> is not necessary, because these -simple functions are guaranteed to have reference counts greater than -0 at all times. If no call to <I>Cudd_Ref</I> is made, then no -attempt to free the diagram by calling -<I>Cudd_RecursiveDeref</I><A NAME="1334"></A> or -<I>Cudd_RecursiveDerefZdd</I><A NAME="1336"></A> should be -made. - -<P> - -<H3><A NAME="SECTION00042400000000000000"></A> -<A NAME="781"></A><A NAME="782"></A><A NAME="sec:satur"></A> -<BR> -Saturating Increments and Decrements -</H3> - -<P> -On 32-bit machines, the CUDD package stores the -reference<A NAME="784"></A> counts in unsigned short int's. -For large diagrams, it is possible for some reference counts to exceed -the capacity of an unsigned short int. Therefore, increments and -decrements of reference counts are <I>saturating</I>. This means that -once a reference count has reached the maximum possible value, it is -no longer changed by calls to <I>Cudd_Ref</I>, -<I>Cudd_RecursiveDeref</I><A NAME="1338"></A>, -<I>Cudd_RecursiveDerefZdd</I><A NAME="1340"></A>, or -<I>Cudd_Deref</I><A NAME="1342"></A>. As a consequence, some nodes -that have no references may not be declared dead. This may result in a -small waste of memory, which is normally more than offset by the -reduction in size of the node structure. - -<P> -When using 64-bit pointers, there is normally no memory advantage from -using short int's instead of int's in a DdNode. Therefore, increments -and decrements are not saturating in that case. What option is in -effect depends on two macros, SIZEOF_VOID_P<A NAME="793"></A> -and SIZEOF_INT<A NAME="794"></A>, defined in the external -header<A NAME="795"></A> file (<I>cudd.h</I><A NAME="797"></A>). The -increments and decrements of the reference counts are performed using -two macros: <I>cuddSatInc</I><A NAME="1344"></A> and -<I>cuddSatDec</I><A NAME="1346"></A>, whose definitions depend on -SIZEOF_VOID_P<A NAME="802"></A> and -SIZEOF_INT<A NAME="803"></A>. - -<P> - -<H2><A NAME="SECTION00043000000000000000"></A> -<A NAME="805"></A><A NAME="sec:compl"></A> -<BR> -Complement Arcs -</H2> - -<P> -If ADDs are restricted to use only the constants 0 and 1, they behave -like BDDs without complement arcs. It is normally easier to write code -that manipulates 0-1 ADDs, than to write code for BDDs. However, -complementation is trivial with complement arcs, and is not trivial -without. As a consequence, with complement arcs it is possible to -check for more terminal cases and it is possible to apply De Morgan's -laws to reduce problems that are essentially identical to a standard -form. This in turn increases the utilization of the cache<A NAME="807"></A>. - -<P> -The complement attribute is stored in the least significant bit of the -``else'' pointer of each node. An external pointer to a function can -also be complemented. The ``then'' pointer to a node, on the other -hand, is always <I>regular<A NAME="808"></A></I>. It is a mistake to -use a complement<A NAME="809"></A> pointer as it is to address -memory. Instead, it is always necessary to obtain a regular version -of it. This is normally done by calling -<I>Cudd_Regular</I><A NAME="1348"></A>. It is also a mistake to -call <I>cuddUniqueInter</I><A NAME="1350"></A> with a complemented -``then'' child as argument. The calling procedure must apply De -Morgan's laws by complementing both pointers passed to -<I>cuddUniqueInter</I><A NAME="1352"></A> and then taking the -complement of the result. - -<P> - -<H2><A NAME="SECTION00044000000000000000"></A> -<A NAME="817"></A><A NAME="sec:cache"></A> -<BR> -The Cache -</H2> - -<P> -Each entry of the cache consists of five fields: The operator, three -pointers to operands and a pointer to the result. The operator and the -three pointers to the operands are combined to form three words. The -combination relies on two facts: - -<UL> -<LI>Most operations have one or two operands. A few bits are - sufficient to discriminate all three-operands operations. -</LI> -<LI>All nodes are aligned to 16-byte boundaries. (32-byte boundaries - if 64-bit pointers are used.) Hence, there are a few bits available - to distinguish the three-operand operations from te others and to - assign unique codes to them. -</LI> -</UL> - -<P> -The cache does not contribute to the reference -<A NAME="821"></A> -counts of the nodes. The fact that the cache contains a -pointer to a node does not imply that the node is alive. Instead, when -garbage<A NAME="822"></A> collection takes place, all entries -of the cache pointing to dead<A NAME="823"></A> nodes are cleared. - -<P> -The cache is also cleared (of all entries) when dynamic -reordering<A NAME="824"></A> takes place. In both cases, the entries -removed from the cache are about to become invalid. - -<P> -All operands and results in a cache entry must be pointers to -DdNodes<A NAME="825"></A>. If a function produces more than one result, -or uses more than three arguments, there are currently two solutions: - -<UL> -<LI>Build a separate, local, cache<A NAME="827"></A>. (Using, for - instance, the <I>st</I> library<A NAME="829"></A>.) -</LI> -<LI>Combine multiple results, or multiple operands, into a single - diagram, by building a ``multiplexing structure'' with reserved - variables. -</LI> -</UL> -Support of the former solution is under development. (See -<TT>cuddLCache.c</TT>..) Support for the latter solution may be -provided in future versions of the package. - -<P> -There are three sets of interface<A NAME="832"></A> functions to -the cache. The first set is for functions with three operands: -<I>cuddCacheInsert</I><A NAME="1354"></A> and -<I>cuddCacheLookup</I><A NAME="1356"></A>. The second set is for -functions with two operands: -<I>cuddCacheInsert2</I><A NAME="1358"></A> and -<I>cuddCacheLookup2</I><A NAME="1360"></A>. The second set is for -functions with one operand: -<I>cuddCacheInsert1</I><A NAME="1362"></A> and -<I>cuddCacheLookup1</I><A NAME="1364"></A>. The second set is -slightly faster than the first, and the third set is slightly faster -than the second. - -<P> - -<H3><A NAME="SECTION00044100000000000000"></A> -<A NAME="846"></A><A NAME="sec:cache-sizing"></A> -<BR> -Cache Sizing -</H3> - -<P> -The size of the cache can increase during the execution of an -application. (There is currently no way to decrease the size of the -cache, though it would not be difficult to do it.) When a cache miss -occurs, the package uses the following criteria to decide whether to -resize the cache: - -<OL> -<LI>If the cache already exceeds the limit given by the - <TT>maxCache<A NAME="849"></A></TT> field of the manager, no resizing - takes place. The limit is the minimum of two values: a value set at - initialization time and possibly modified by the application, which - constitutes the hard limit beyond which the cache will never grow; - and a number that depends on the current total number of slots in - the unique<A NAME="850"></A> table. -</LI> -<LI>If the cache is not too large already, resizing is decided based - on the hit rate. The policy adopted by the CUDD package is - ``reward-based<A NAME="851"></A>.'' If the cache hit - rate is high, then it is worthwhile to increase the size of the - cache. -</LI> -</OL> -When resizing takes place, the statistical counters <A NAME="853"></A> used to compute the hit rate are reinitialized so as to -prevent immediate resizing. The number of entries is doubled. - -<P> -The rationale for the ``reward-based<A NAME="854"></A>'' -policy is as follows. In many BDD/ADD applications the hit rate is -not very sensitive to the size of the cache: It is primarily a -function of the problem instance at hand. If a large hit rate is -observed, chances are that by using a large cache, the results of -large problems (those that would take longer to solve) will survive in -the cache without being overwritten long enough to cause a valuable -cache hit. Notice that when a large problem is solved more than once, -so are its recursively generated subproblems. If the hit rate is -low, the probability of large problems being solved more than once is -low. - -<P> -The other observation about the cache sizing policy is that there is -little point in keeping a cache which is much larger than the unique -table. Every time the unique table ``fills up,'' garbage collection is -invoked and the cache is cleared of all dead entries. A cache that is -much larger than the unique<A NAME="855"></A> table is therefore -less than fully utilized. - -<P> - -<H3><A NAME="SECTION00044200000000000000"></A> -<A NAME="857"></A><A NAME="sec:local-caches"></A> -<BR> -Local Caches -</H3> - -<P> -Sometimes it may be necessary or convenient to use a local cache. A -local cache can be lossless<A NAME="859"></A> (no results are ever -overwritten), or it may store objects for which -canonical<A NAME="860"></A> representations are not available. One -important fact to keep in mind when using a local cache is that local -caches are not cleared during garbage<A NAME="861"></A> -collection or before reordering. Therefore, it is necessary to -increment the reference<A NAME="862"></A> count of all nodes -pointed by a local cache. (Unless their reference counts are -guaranteed positive in some other way. One such way is by including -all partial results in the global result.) Before disposing of the -local cache, all elements stored in it must be passed to -<I>Cudd_RecursiveDeref</I><A NAME="1366"></A>. As consequence -of the fact that all results in a local cache are referenced, it is -generally convenient to store in the local cache also the result of -trivial problems, which are not usually stored in the global cache. -Otherwise, after a recursive call, it is difficult to tell whether the -result is in the cache, and therefore referenced, or not in the cache, -and therefore not referenced. - -<P> -An alternative approach to referencing the results in the local caches -is to install hook functions (see Section <A HREF="node3.html#sec:hooks">3.16</A>) to be -executed before garbage collection. - -<P> - -<H2><A NAME="SECTION00045000000000000000"></A> -<A NAME="867"></A><A NAME="sec:unique"></A> -<BR> -The Unique Table -</H2> - -<P> -A recursive procedure typically splits the operands by expanding with -respect to the topmost variable. Topmost in this context refers to the -variable that is closest to the roots in the current variable order. -The nodes, on the other hand, hold the index, which is invariant with -reordering. Therefore, when splitting, one must use the -permutation<A NAME="869"></A> array maintained by the -package to get the right level. Access to the permutation array is -provided by the macro <I>cuddI</I><A NAME="1368"></A> for BDDs and ADDs, -and by the macro <I>cuddIZ</I><A NAME="1370"></A> for ZDDs. - -<P> -The unique table consists of as many hash<A NAME="874"></A> tables as -there are variables in use. These has tables are called <I>unique - subtables</I>. The sizes of the unique subtables are determined by two -criteria: - -<OL> -<LI>The collision<A NAME="877"></A> lists should be short - to keep access time down. -</LI> -<LI>There should be enough room for dead<A NAME="878"></A> nodes, to - prevent too frequent garbage<A NAME="879"></A> collections. -</LI> -</OL> -While the first criterion is fairly straightforward to implement, the -second leaves more room to creativity. The CUDD package tries to -figure out whether more dead node should be allowed to increase -performance. (See also Section <A HREF="node3.html#sec:params">3.4</A>.) There are two -reasons for not doing garbage collection too often. The obvious one is -that it is expensive. The second is that dead nodes may be -reclaimed<A NAME="882"></A>, if they are the result of a -successful cache lookup. Hence dead nodes may provide a substantial -speed-up if they are kept around long enough. The usefulness of -keeping many dead nodes around varies from application to application, -and from problem instance to problem instance. As in the sizing of the -cache, the CUDD package adopts a -``reward-based<A NAME="883"></A>'' policy to -decide how much room should be used for the unique table. If the -number of dead nodes reclaimed is large compared to the number of -nodes directly requested from the memory manager, then the CUDD -package assumes that it will be beneficial to allow more room for the -subtables, thereby reducing the frequency of garbage collection. The -package does so by switching between two modes of operation: - -<OL> -<LI>Fast growth<A NAME="885"></A>: In this mode, the - ratio of dead nodes to total nodes required for garbage collection - is higher than in the slow growth mode to favor resizing - of the subtables. -</LI> -<LI>Slow growth<A NAME="886"></A>: In this - mode keeping many dead nodes around is not as important as - keeping memory requirements low. -</LI> -</OL> -Switching from one mode to the other is based on the following -criteria: - -<OL> -<LI>If the unique table is already large, only slow growth is - possible. -</LI> -<LI>If the table is small and many dead nodes are being reclaimed, - then fast growth is selected. -</LI> -</OL> -This policy is especially effective when the diagrams being -manipulated have lots of recombination. Notice the interplay of the -cache sizing and unique sizing: Fast growth normally occurs when the -cache hit rate is large. The cache and the unique table then grow in -concert, preserving a healthy balance between their sizes. - -<P> - -<H2><A NAME="SECTION00046000000000000000"></A> -<A NAME="891"></A><A NAME="sec:async"></A> -<BR> -Allowing Asynchronous Reordering -</H2> - -<P> -Asynchronous reordering is the reordering that is triggered -automatically by the increase of the number of nodes. Asynchronous -reordering takes place when a new internal node must be created, and -the number of nodes has reached a given -threshold<A NAME="893"></A>. (The threshold is adjusted by -the package every time reordering takes place.) - -<P> -Those procedures that do not create new nodes (e.g., procedures that -count the number of nodes or minterms<A NAME="894"></A>) need -not worry about asynchronous reordering: No special precaution is -necessary in writing them. - -<P> -Procedures that only manipulate decision diagrams through the exported -functions of the CUDD package also need not concern themselves with -asynchronous reordering. (See Section <A HREF="node3.html#sec:nodes">3.2.1</A> for the -exceptions.) - -<P> -The remaining class of procedures is composed of functions that visit -the diagrams and may create new nodes. All such procedures in the CUDD -package are written so that they can be interrupted by dynamic -reordering. The general approach followed goes under the name of -``abort and retry<A NAME="896"></A>.'' As the name -implies, a computation that is interrupted by dynamic reordering is -aborted and tried again. - -<P> -A recursive procedure that can be interrupted by dynamic reordering -(an interruptible<A NAME="897"></A> procedure -from now on) is composed of two functions. One is responsible for the -real computation. The other is a simple -wrapper<A NAME="898"></A>, which tests whether -reordering occurred and restarts the computation if it did. - -<P> -Asynchronous reordering of BDDs and ADDs can only be triggered inside -<I>cuddUniqueInter</I><A NAME="1372"></A>, when a new node is about -to be created. Likewise, asynchronous reordering of ZDDs can only be -triggered inside <I>cuddUniqueInterZdd</I><A NAME="1374"></A>. -When reordering is triggered, three things happen: - -<OL> -<LI><I>cuddUniqueInter</I><A NAME="1376"></A> returns a NULL - value; -</LI> -<LI>The flag <I>reordered</I> of the manager is set to 1. (0 means - no reordering, while 2 indicates an error occurred during - reordering.) -</LI> -<LI>The counter <I>reorderings</I> of the manager is incremented. - The counter is initialized to 0 when the manager is started and can - be accessed by calling - <I>Cudd_ReadReorderings</I><A NAME="1378"></A>. By taking - two readings of the counter, an application can determine if - variable reordering has taken place between the first and the second - reading. The package itself, however, does not make use of the - counter: It is mentioned here for completeness. -</LI> -</OL> - -<P> -The recursive procedure that receives a NULL value from -<I>cuddUniqueInter</I><A NAME="1380"></A> must free all -intermediate results that it may have computed before, and return NULL -in its turn. - -<P> -The wrapper<A NAME="913"></A> function does not -decide whether reordering occurred based on the NULL return value, -because the NULL value may be the result of lack of memory. Instead, -it checks the <I>reordered</I> flag. - -<P> -When a recursive procedure calls another recursive procedure that may -cause reordering, it should bypass the wrapper and call the recursive -procedure directly. Otherwise, the calling procedure will not know -whether reordering occurred, and will not be able to restart. This is -the main reason why most recursive procedures are internal, rather -than static. (The wrappers, on the other hand, are mostly exported.) - -<P> - -<H2><A NAME="SECTION00047000000000000000"></A> -<A NAME="916"></A><A NAME="sec:debug"></A> -<BR> -Debugging -</H2> - -<P> -By defining the symbol DD_DEBUG<A NAME="918"></A> during compilation, -numerous checks are added to the code. In addition, the procedures -<I>Cudd_DebugCheck</I><A NAME="1382"></A>, -<I>Cudd_CheckKeys</I><A NAME="1384"></A>, and -<I>cuddHeapProfile</I><A NAME="1386"></A> can be called at any -point to verify the consistency of the data structure. -(<I>cuddHeapProfile</I> is an internal procedure. It is declared in -<I>cuddInt.h</I><A NAME="927"></A>.) Procedures -<I>Cudd_DebugCheck</I> and <I>Cudd_CheckKeys</I> are especially -useful when CUDD reports that during garbage collection the number of -nodes actually deleted from the unique table is different from the -count of dead nodes kept by the manager. The error causing the -discrepancy may have occurred much earlier than it is discovered. A -few strategicaly placed calls to the debugging procedures can -considerably narrow down the search for the source of the problem. -(For instance, a call to <I>Cudd_RecursiveDeref</I> where one to -<I>Cudd_Deref</I> was required may be identified in this way.) - -<P> -One of the most common problems encountered in debugging code based on -the CUDD package is a missing call to -<I>Cudd_RecursiveDeref</I><A NAME="1388"></A>. To help -identify this type of problems, the package provides a function called -<I>Cudd_CheckZeroRef</I><A NAME="1390"></A>. This function -should be called immediately before shutting down the manager. -<I>Cudd_CheckZeroRef</I> checks that the only nodes left with -non-zero reference<A NAME="937"></A> counts are the -predefined constants, the BDD projection<A NAME="938"></A> -functions, and nodes whose reference counts are -saturated<A NAME="939"></A>. - -<P> -For this function to be effective the application must explicitly -dispose of all diagrams to which it has pointers before calling it. - -<P> - -<H2><A NAME="SECTION00048000000000000000"></A> -<A NAME="941"></A><A NAME="sec:stats"></A> -<BR> -Gathering and Interpreting Statistics -</H2> - -<P> -Function <I>Cudd_PrintInfo</I><A NAME="1392"></A> can be called to -print out the values of parameters and statistics for a manager. The -output of <I>Cudd_PrintInfo</I> is divided in two sections. The -first reports the values of parameters that are under the application -control. The second reports the values of statistical counters and -other non-modifiable parameters. A quick guide to the interpretation -of all these quantities follows. For ease of exposition, we reverse -the order and describe the non-modifiable parameters first. We'll use -a sample run as example. There is nothing special about this run. - -<P> - -<H3><A NAME="SECTION00048100000000000000"></A> -<A NAME="sec:nonModPar"></A> -<BR> -Non Modifiable Parameters -</H3> - -<P> -The list of non-modifiable parameters starts with: -<PRE> - **** CUDD non-modifiable parameters **** - Memory in use: 32544220 -</PRE> -This is the memory used by CUDD for three things mainly: Unique table -(including all DD nodes in use), node free list, and computed table. -This number almost never decreases in the lifetime of a CUDD manager, -because CUDD does not release memory when it frees nodes. Rather, it -puts the nodes on its own free list. This number is in bytes. It does -not represent the peak memory occupation, because it does not include -the size of data structures created temporarily by some functions (e.g., -local look-up tables). - -<P> -<PRE> - Peak number of nodes: 837018 -</PRE> -This number is the number of nodes that the manager has allocated. -This is not the largest size of the BDDs, because the manager will -normally have some dead nodes and some nodes on the free list. - -<P> -<PRE> - Peak number of live nodes: 836894 -</PRE> -This is the largest number of live nodes that the manager has held -since its creation. - -<P> -<PRE> - Number of BDD variables: 198 - Number of ZDD variables: 0 -</PRE> -These numbers tell us this run was not using ZDDs. - -<P> -<PRE> - Number of cache entries: 1048576 -</PRE> -Current number of slots of the computed table. If one has a -performance problem, this is one of the numbers to look at. The cache -size is always a power of 2. - -<P> -<PRE> - Number of cache look-ups: 2996536 - Number of cache hits: 1187087 -</PRE> -These numbers give an indication of the hit rate in the computed -table. It is not unlikely for model checking runs to get -hit rates even higher than this one (39.62%). - -<P> -<PRE> - Number of cache insertions: 1809473 - Number of cache collisions: 961208 - Number of cache deletions: 0 -</PRE> -A collision<A NAME="962"></A> occurs when a cache entry is -overwritten. A deletion<A NAME="963"></A> -occurs when a cache entry is invalidated (e.g., during garbage -collection). If the number of deletions is high compared to the -number of collisions, it means that garbage collection occurs too -often. In this case there were no garbage collections; hence, no -deletions. - -<P> -<PRE> - Cache used slots = 80.90% (expected 82.19%) -</PRE> -Percentage of cache slots that contain a valid entry. If this -number is small, it may signal one of three conditions: - -<OL> -<LI>The cache may have been recently resized and it is still filling - up. -</LI> -<LI>The cache is too large for the BDDs. This should not happen if - the size of the cache is determined by CUDD. -</LI> -<LI>The hash function is not working properly. This is accompanied - by a degradation in performance. Conversely, a degradation in - performance may be due to bad hash function behavior. -</LI> -</OL> -The expected value is computed assuming a uniformly random -distribution of the accesses. If the difference between the measured -value and the expected value is large (unlike this case), the cache is -not working properly. - -<P> -<PRE> - Soft limit for cache size: 1318912 -</PRE> -This number says how large the cache can grow. This limit is based on -the size of the unique table. CUDD uses a reward-based policy for -growing the cache. (See Section <A HREF="#sec:cache-sizing">4.4.1</A>.) The default -hit rate for resizing is 30% and the value in effect is reported -among the modifiable parameters. - -<P> -<PRE> - Number of buckets in unique table: 329728 -</PRE> -This number is exactly one quarter of the one above. This is indeed -how the soft limit is determined currently, unless the computed table -hits the specified hard limit. (See below.) - -<P> -<PRE> - Used buckets in unique table: 87.96% (expected 87.93%) -</PRE> -Percentage of unique table buckets that contain at least one -node. Remarks analogous to those made about the used cache slots apply. - -<P> -<PRE> - Number of BDD and ADD nodes: 836894 - Number of ZDD nodes: 0 -</PRE> -How many nodes are currently in the unique table, either alive or dead. - -<P> -<PRE> - Number of dead BDD and ADD nodes: 0 - Number of dead ZDD nodes: 0 -</PRE> -Subtract these numbers from those above to get the number of live -nodes. In this case there are no dead nodes because the application -uses delayed dereferencing -<I>Cudd_DelayedDerefBdd</I><A NAME="1394"></A>. - -<P> -<PRE> - Total number of nodes allocated: 836894 -</PRE> -This is the total number of nodes that were requested and obtained -from the free list. It never decreases, and is not an indication of -memory occupation after the first garbage collection. Rather, it is a -measure of the package activity. - -<P> -<PRE> - Total number of nodes reclaimed: 0 -</PRE> -These are the nodes that were resuscitated from the dead. If they are -many more than the allocated nodes, and the total -number of slots is low relative to the number of nodes, then one may -want to increase the limit for fast unique table growth. In this case, -the number is 0 because of delayed dereferencing. - -<P> -<PRE> - Garbage collections so far: 0 - Time for garbage collections: 0.00 sec - Reorderings so far: 0 - Time for reordering: 0.00 sec -</PRE> -There is a GC for each reordering. Hence the first count will always be -at least as large as the second. - -<P> -<PRE> - Node swaps in reordering: 0 -</PRE> -This is the number of elementary reordering steps. Each step consists -of the re-expression of one node while swapping two adjacent -variables. This number is a good measure of the amount of work done in -reordering. - -<P> - -<H3><A NAME="SECTION00048200000000000000"></A> -<A NAME="sec:modPar"></A> -<BR> -Modifiable Parameters -</H3> - -<P> -Let us now consider the modifiable parameters, that is, those settings on -which the application or the user has control. - -<P> -<PRE> - **** CUDD modifiable parameters **** - Hard limit for cache size: 8388608 -</PRE> -This number counts entries. Each entry is 16 bytes if CUDD is compiled -to use 32-bit pointers. Two important observations are in order: - -<OL> -<LI>If the datasize limit is set, CUDD will use it to determine this - number automatically. On a Unix system, one can type ``limit'' or - ``ulimit'' to verify if this value is set. If the datasize limit is - not set, CUDD uses a default which is rather small. If you have - enough memory (say 64MB or more) you should seriously consider - <I>not</I> using the default. So, either set the datasize limit, or - override the default with - <I>Cudd_SetMaxCacheHard</I><A NAME="1396"></A>. -</LI> -<LI>If a process seems to be going nowhere, a small value for - this parameter may be the culprit. One cannot overemphasize the - importance of the computed table in BDD algorithms. -</LI> -</OL> -In this case the limit was automatically set for a target maximum -memory occupation of 104 MB. - -<P> -<PRE> - Cache hit threshold for resizing: 15% -</PRE> -This number can be changed if one suspects performance is hindered by -the small size of the cache, and the cache is not growing towards the -soft limit sufficiently fast. In such a case one can change the -default 30% to 15% (as in this case) or even 1%. - -<P> -<PRE> - Garbage collection enabled: yes -</PRE> -One can disable it, but there are few good reasons for doing -so. It is normally preferable to raise the limit for fast unique table -growth. (See below.) - -<P> -<PRE> - Limit for fast unique table growth: 1363148 -</PRE> -See Section <A HREF="#sec:unique">4.5</A> and the comments above about reclaimed -nodes and hard limit for the cache size. This value was chosen -automatically by CUDD for a datasize limit of 1 GB. - -<P> -<PRE> - Maximum number of variables sifted per reordering: 1000 - Maximum number of variable swaps per reordering: 2000000 - Maximum growth while sifting a variable: 1.2 -</PRE> -Lowering these numbers will cause reordering to be less accurate and -faster. Results are somewhat unpredictable, because larger BDDs after one -reordering do not necessarily mean the process will go faster or slower. - -<P> -<PRE> - Dynamic reordering of BDDs enabled: yes - Default BDD reordering method: 4 - Dynamic reordering of ZDDs enabled: no - Default ZDD reordering method: 4 -</PRE> -These lines tell whether automatic reordering can take place and what -method would be used. The mapping from numbers to methods is in -<TT>cudd.h</TT>. One may want to try different BDD reordering -methods. If variable groups are used, however, one should not expect -to see big differences, because CUDD uses the reported method only to -reorder each leaf variable group (typically corresponding present and -next state variables). For the relative order of the groups, it -always uses the same algorithm, which is effectively sifting. - -<P> -As for enabling dynamic reordering or not, a sensible recommendation is the -following: Unless the circuit is rather small or one has a pretty good -idea of what the order should be, reordering should be enabled. - -<P> -<PRE> - Realignment of ZDDs to BDDs enabled: no - Realignment of BDDs to ZDDs enabled: no - Dead nodes counted in triggering reordering: no - Group checking criterion: 7 - Recombination threshold: 0 - Symmetry violation threshold: 0 - Arc violation threshold: 0 - GA population size: 0 - Number of crossovers for GA: 0 -</PRE> -Parameters for reordering. See the documentation of the functions used -to control these parameters for the details. - -<P> -<PRE> - Next reordering threshold: 100000 -</PRE> -When the number of nodes crosses this threshold, reordering will be -triggered. (If enabled; in this case it is not.) This parameter is -updated by the package whenever reordering takes place. The -application can change it, for instance at start-up. Another -possibility is to use a hook function (see Section <A HREF="node3.html#sec:hooks">3.16</A>) to -override the default updating policy. - -<P> - -<H3><A NAME="SECTION00048300000000000000"></A> -<A NAME="sec:extendedStats"></A> -<BR> -Extended Statistics and Reporting -</H3> - -<P> -The following symbols can be defined during compilation to increase -the amount of statistics gathered and the number of messages produced -by the package: - -<UL> -<LI>DD_STATS<A NAME="1018"></A>; -</LI> -<LI>DD_CACHE_PROFILE<A NAME="1019"></A>; -</LI> -<LI>DD_UNIQUE_PROFILE<A NAME="1020"></A>. -</LI> -<LI>DD_VERBOSE<A NAME="1021"></A>; -</LI> -</UL> -Defining DD_CACHE_PROFILE causes each entry of the cache to include -an access counter, which is used to compute simple statistics on the -distribution of the keys. - -<P> - -<H2><A NAME="SECTION00049000000000000000"></A> -<A NAME="sec:doc"></A><A NAME="1025"></A> -<BR> -Guidelines for Documentation -</H2> - -<P> -The documentation of the CUDD functions is extracted automatically -from the sources by Stephen Edwards's extdoc. (The Ext system is -available via anonymous FTP<A NAME="1026"></A> from -<A NAME="tex2html11" - HREF="ftp://ic.eecs.berkeley.edu"><TT>ic.eecs.berkeley.edu</TT></A>.) -The following guidelines are followed in CUDD to insure consistent and -effective use of automatic extraction. It is recommended that -extensions to CUDD follow the same documentation guidelines. - -<UL> -<LI>The documentation of an exported procedure should be sufficient - to allow one to use it without reading the code. It is not necessary - to explain how the procedure works; only what it does. -</LI> -<LI>The <I>SeeAlso</I><A NAME="1096"></A> - fields should be space-separated lists of function names. The - <I>SeeAlso</I> field of an exported procedure should only reference - other exported procedures. The <I>SeeAlso</I> field of an internal - procedure may reference other internal procedures as well as - exported procedures, but no static procedures. -</LI> -<LI>The return values are detailed in the - <I>Description</I><A NAME="1097"></A> - field, not in the - <I>Synopsis</I><A NAME="1098"></A> field. -</LI> -<LI>The parameters are documented alongside their declarations. - Further comments may appear in the <I>Description</I> field. -</LI> -<LI>If the <I>Description</I> field is non-empty--which is the - normal case for an exported procedure--then the synopsis is - repeated--possibly slightly changed--at the beginning of the - <I>Description</I> field. This is so because extdoc will not put the - synopsis in the same HTML file<A NAME="1041"></A> as - the description. -</LI> -<LI>The <I>Synopsis</I> field should be about one line long. -</LI> -</UL> - -<P> -<HR> -<!--Navigation Panel--> -<A NAME="tex2html154" - HREF="node5.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html150" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html144" - HREF="node3.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html152" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html155" - HREF="node5.html">The C++ Interface</A> -<B> Up:</B> <A NAME="tex2html151" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html145" - HREF="node3.html">User's Manual</A> - <B> <A NAME="tex2html153" - HREF="node8.html">Index</A></B> -<!--End of Navigation Panel--> -<ADDRESS> -Fabio Somenzi -2012-02-04 -</ADDRESS> -</BODY> -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node5.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node5.html deleted file mode 100644 index b519a2f97..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node5.html +++ /dev/null @@ -1,130 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> - -<!--Converted with LaTeX2HTML 2008 (1.71) -original version by: Nikos Drakos, CBLU, University of Leeds -* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan -* with significant contributions from: - Jens Lippmann, Marek Rouchal, Martin Wilck and others --> -<HTML> -<HEAD> -<TITLE>The C++ Interface</TITLE> -<META NAME="description" CONTENT="The C++ Interface"> -<META NAME="keywords" CONTENT="cuddIntro"> -<META NAME="resource-type" CONTENT="document"> -<META NAME="distribution" CONTENT="global"> - -<META NAME="Generator" CONTENT="LaTeX2HTML v2008"> -<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> - -<LINK REL="STYLESHEET" HREF="cuddIntro.css"> - -<LINK REL="next" HREF="node6.html"> -<LINK REL="previous" HREF="node4.html"> -<LINK REL="up" HREF="cuddIntro.html"> -<LINK REL="next" HREF="node6.html"> -</HEAD> - -<BODY > -<!--Navigation Panel--> -<A NAME="tex2html184" - HREF="node6.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html180" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html174" - HREF="node4.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html182" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html185" - HREF="node6.html">Acknowledgments</A> -<B> Up:</B> <A NAME="tex2html181" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html175" - HREF="node4.html">Programmer's Manual</A> - <B> <A NAME="tex2html183" - HREF="node8.html">Index</A></B> -<BR> -<BR> -<!--End of Navigation Panel--> -<!--Table of Child-Links--> -<A NAME="CHILD_LINKS"><STRONG>Subsections</STRONG></A> - -<UL> -<LI><A NAME="tex2html186" - HREF="node5.html#SECTION00051000000000000000">Compiling and Linking</A> -<LI><A NAME="tex2html187" - HREF="node5.html#SECTION00052000000000000000">Basic Manipulation</A> -</UL> -<!--End of Table of Child-Links--> -<HR> - -<H1><A NAME="SECTION00050000000000000000"></A> -<A NAME="sec:cpp"></A> -<BR> -The C++ Interface -</H1> - -<P> - -<H2><A NAME="SECTION00051000000000000000"></A> -<A NAME="sec:compileCpp"></A> -<BR> -Compiling and Linking -</H2> - -<P> -To build an application that uses the CUDD C++ interface, you should -add -<PRE> -#include "cuddObj.hh" -</PRE> -to your source files. In addition to the normal CUDD libraries (see -Section <A HREF="node3.html#sec:compileExt">3.1</A>) you should link -<code>libobj.a</code><A NAME="1051"></A> to your executable. Refer to the -<TT>Makefile<A NAME="1052"></A></TT> in the top level directory of the -distribution for further details. - -<P> - -<H2><A NAME="SECTION00052000000000000000"></A> -<A NAME="sec:basicCpp"></A> -<BR> -Basic Manipulation -</H2> - -<P> -The following fragment of code illustrates some simple operations on -BDDs using the C++ interface. -<PRE> - Cudd mgr(0,0); - BDD x = mgr.bddVar(); - BDD y = mgr.bddVar(); - BDD f = x * y; - BDD g = y + !x; - cout << "f is" << (f <= g ? "" : " not") - << " less than or equal to g\n"; -</PRE> -This code creates a manager called <code>mgr</code> and two variables in it. -It then defines two functions <code>f</code> and <code>g</code> in terms of the -variables. Finally, it prints a message based on the comparison of the -two functions. No explicit referencing or dereferencing is required. -The operators are overloaded in the intuitive way. BDDs are freed when -execution leaves the scope in which they are defined or when the -variables referring to them are overwritten. - -<P> -<BR><HR> -<ADDRESS> -Fabio Somenzi -2012-02-04 -</ADDRESS> -</BODY> -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node6.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node6.html deleted file mode 100644 index 1f42c860e..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node6.html +++ /dev/null @@ -1,132 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> - -<!--Converted with LaTeX2HTML 2008 (1.71) -original version by: Nikos Drakos, CBLU, University of Leeds -* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan -* with significant contributions from: - Jens Lippmann, Marek Rouchal, Martin Wilck and others --> -<HTML> -<HEAD> -<TITLE>Acknowledgments</TITLE> -<META NAME="description" CONTENT="Acknowledgments"> -<META NAME="keywords" CONTENT="cuddIntro"> -<META NAME="resource-type" CONTENT="document"> -<META NAME="distribution" CONTENT="global"> - -<META NAME="Generator" CONTENT="LaTeX2HTML v2008"> -<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> - -<LINK REL="STYLESHEET" HREF="cuddIntro.css"> - -<LINK REL="next" HREF="node7.html"> -<LINK REL="previous" HREF="node5.html"> -<LINK REL="up" HREF="cuddIntro.html"> -<LINK REL="next" HREF="node7.html"> -</HEAD> - -<BODY > -<!--Navigation Panel--> -<A NAME="tex2html198" - HREF="node7.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html194" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html188" - HREF="node5.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html196" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html199" - HREF="node7.html">Bibliography</A> -<B> Up:</B> <A NAME="tex2html195" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html189" - HREF="node5.html">The C++ Interface</A> - <B> <A NAME="tex2html197" - HREF="node8.html">Index</A></B> -<BR> -<BR> -<!--End of Navigation Panel--> - -<H1><A NAME="SECTION00060000000000000000"></A> -<A NAME="sec:ack"></A> -<BR> -Acknowledgments -</H1> - -<P> -The contributors: Iris Bahar, Hyunwoo Cho, Erica Frohm, Charlie Gaona, -Cheng Hua, Jae-Young Jang, Seh-Woong Jeong, Balakrishna Kumthekar, -Enrico Macii, Bobbie Manne, In-Ho Moon, Curt Musfeldt, Shipra Panda, -Abelardo Pardo, Bernard Plessier, Kavita Ravi, Hyongkyoon Shin, Alan -Shuler, Arun Sivakumaran, Jorgen Sivesind. - -<P> -The early adopters: Gianpiero Cabodi, Jordi Cortadella, Mario Escobar, -Gayani Gamage, Gary Hachtel, Mariano Hermida, Woohyuk Lee, Enric -Pastor, Massimo Poncino, Ellen Sentovich, the students of ECEN5139. - -<P> -I am also particularly indebted to the following people for in-depth -discussions on BDDs: Armin Biere, Olivier Coudert, Arie Gurfinkel, -Geert Janssen, Don Knuth, David Long, Jean Christophe Madre, Ken -McMillan, Shin-Ichi Minato, Jaehong Park, Rajeev Ranjan, Rick Rudell, -Ellen Sentovich, Tom Shiple, Christian Stangier, and Bwolen Yang. - -<P> -Special thanks to Norris Ip for guiding my faltering steps -in the design of the C++ interface. -Gianpiero Cabodi and Stefano Quer have graciously agreed to let me -distribute their dddmp library with CUDD. - -<P> -Masahiro Fujita, Gary Hachtel, and Carl Pixley have provided -encouragement and advice. - -<P> -The National Science Foundation and the Semiconductor Research -Corporation have supported in part the development of this package. - -<P> - -<HR> -<!--Navigation Panel--> -<A NAME="tex2html198" - HREF="node7.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html194" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html188" - HREF="node5.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html196" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html199" - HREF="node7.html">Bibliography</A> -<B> Up:</B> <A NAME="tex2html195" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html189" - HREF="node5.html">The C++ Interface</A> - <B> <A NAME="tex2html197" - HREF="node8.html">Index</A></B> -<!--End of Navigation Panel--> -<ADDRESS> -Fabio Somenzi -2012-02-04 -</ADDRESS> -</BODY> -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node7.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node7.html deleted file mode 100644 index d7e967ef5..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node7.html +++ /dev/null @@ -1,195 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> - -<!--Converted with LaTeX2HTML 2008 (1.71) -original version by: Nikos Drakos, CBLU, University of Leeds -* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan -* with significant contributions from: - Jens Lippmann, Marek Rouchal, Martin Wilck and others --> -<HTML> -<HEAD> -<TITLE>Bibliography</TITLE> -<META NAME="description" CONTENT="Bibliography"> -<META NAME="keywords" CONTENT="cuddIntro"> -<META NAME="resource-type" CONTENT="document"> -<META NAME="distribution" CONTENT="global"> - -<META NAME="Generator" CONTENT="LaTeX2HTML v2008"> -<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> - -<LINK REL="STYLESHEET" HREF="cuddIntro.css"> - -<LINK REL="next" HREF="node8.html"> -<LINK REL="previous" HREF="node6.html"> -<LINK REL="up" HREF="cuddIntro.html"> -<LINK REL="next" HREF="node8.html"> -</HEAD> - -<BODY > -<!--Navigation Panel--> -<A NAME="tex2html210" - HREF="node8.html"> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next.png"></A> -<A NAME="tex2html206" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html200" - HREF="node6.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<A NAME="tex2html208" - HREF="node8.html"> -<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" - SRC="icons/index.png"></A> -<BR> -<B> Next:</B> <A NAME="tex2html211" - HREF="node8.html">Index</A> -<B> Up:</B> <A NAME="tex2html207" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html201" - HREF="node6.html">Acknowledgments</A> - <B> <A NAME="tex2html209" - HREF="node8.html">Index</A></B> -<BR><BR> -<!--End of Navigation Panel--> - -<H2><A NAME="SECTION00070000000000000000"> -Bibliography</A> -</H2><DL COMPACT><DD><P></P><DT><A NAME="Bahar93">1</A> -<DD> -R. I. Bahar, E. A. Frohm, C. M. Gaona, G. D. Hachtel, E. Macii, A. Pardo, and - F. Somenzi. -<BR>Algebraic decision diagrams and their applications. -<BR>In <EM>Proceedings of the International Conference on Computer-Aided - Design</EM>, pages 188-191, Santa Clara, CA, November 1993. - -<P></P><DT><A NAME="Bollig95">2</A> -<DD> -B. Bollig, M. Löbbing, and I. Wegener. -<BR>Simulated annealing to improve variable orderings for OBDDs. -<BR>Presented at the International Workshop on Logic Synthesis, - Granlibakken, CA, May 1995. - -<P></P><DT><A NAME="BBR">3</A> -<DD> -K. S. Brace, R. L. Rudell, and R. E. Bryant. -<BR>Efficient implementation of a BDD package. -<BR>In <EM>Proceedings of the 27th Design Automation Conference</EM>, pages - 40-45, Orlando, FL, June 1990. - -<P></P><DT><A NAME="VIS">4</A> -<DD> -R. K. Brayton et al. -<BR>VIS: A system for verification and synthesis. -<BR>Technical Report UCB/ERL M95/104, Electronics Research Lab, Univ. of - California, December 1995. - -<P></P><DT><A NAME="BDD">5</A> -<DD> -R. E. Bryant. -<BR>Graph-based algorithms for Boolean function manipulation. -<BR><EM>IEEE Transactions on Computers</EM>, C-35(8):677-691, August 1986. - -<P></P><DT><A NAME="Drechs95">6</A> -<DD> -R. Drechsler, B. Becker, and N. Göckel. -<BR>A genetic algorithm for variable ordering of OBDDs. -<BR>Presented at the International Workshop on Logic Synthesis, - Granlibakken, CA, May 1995. - -<P></P><DT><A NAME="Friedman90">7</A> -<DD> -S. J. Friedman and K. J. Supowit. -<BR>Finding the optimal variable ordering for binary decision diagrams. -<BR><EM>IEEE Transactions on Computers</EM>, 39(5):710-713, May 1990. - -<P></P><DT><A NAME="Fujita91b">8</A> -<DD> -M. Fujita, Y. Matsunaga, and T. Kakuda. -<BR>On variable ordering of binary decision diagrams for the application - of multi-level logic synthesis. -<BR>In <EM>Proceedings of the European Conference on Design Automation</EM>, - pages 50-54, Amsterdam, February 1991. - -<P></P><DT><A NAME="Held62">9</A> -<DD> -M. Held and R. M. Karp. -<BR>A dynamic programming approach to sequencing problems. -<BR><EM>J. SIAM</EM>, 10(1):196-210, 1962. - -<P></P><DT><A NAME="Ishiur91">10</A> -<DD> -N. Ishiura, H. Sawada, and S. Yajima. -<BR>Minimization of binary decision diagrams based on exchanges of - variables. -<BR>In <EM>Proceedings of the International Conference on Computer-Aided - Design</EM>, pages 472-475, Santa Clara, CA, November 1991. - -<P></P><DT><A NAME="Jeong93">11</A> -<DD> -S.-W. Jeong, T.-S. Kim, and F. Somenzi. -<BR>An efficient method for optimal BDD ordering computation. -<BR>In <EM>International Conference on VLSI and CAD (ICVC'93)</EM>, Taejon, - Korea, November 1993. - -<P></P><DT><A NAME="Minato93">12</A> -<DD> -S.-I. Minato. -<BR>Zero-suppressed BDDs for set manipulation in combinatorial - problems. -<BR>In <EM>Proceedings of the Design Automation Conference</EM>, pages - 272-277, Dallas, TX, June 1993. - -<P></P><DT><A NAME="Panda95b">13</A> -<DD> -S. Panda and F. Somenzi. -<BR>Who are the variables in your neighborhood. -<BR>In <EM>Proceedings of the International Conference on Computer-Aided - Design</EM>, pages 74-77, San Jose, CA, November 1995. - -<P></P><DT><A NAME="Panda94">14</A> -<DD> -S. Panda, F. Somenzi, and B. F. Plessier. -<BR>Symmetry detection and dynamic variable ordering of decision - diagrams. -<BR>In <EM>Proceedings of the International Conference on Computer-Aided - Design</EM>, pages 628-631, San Jose, CA, November 1994. - -<P></P><DT><A NAME="Plessi93">15</A> -<DD> -B. F. Plessier. -<BR><EM>A General Framework for Verification of Sequential Circuits</EM>. -<BR>PhD thesis, University of Colorado at Boulder, Dept. of Electrical - and Computer Engineering, 1993. - -<P></P><DT><A NAME="Rudell93">16</A> -<DD> -R. Rudell. -<BR>Dynamic variable ordering for ordered binary decision diagrams. -<BR>In <EM>Proceedings of the International Conference on Computer-Aided - Design</EM>, pages 42-47, Santa Clara, CA, November 1993. - -<P></P><DT><A NAME="Sentov92">17</A> -<DD> -E. M. Sentovich, K. J. Singh, C. Moon, H. Savoj, R. K. Brayton, and - A. Sangiovanni-Vincentelli. -<BR>Sequential circuit design using synthesis and optimization. -<BR>In <EM>Proceedings of the International Conference on Computer - Design</EM>, pages 328-333, Cambridge, MA, October 1992. -</DL> -<A NAME="1101"></A> -<A NAME="1102"></A> -<A NAME="1103"></A> -<A NAME="1104"></A> -<A NAME="1105"></A> -<A NAME="1106"></A> - -<P> -<BR><HR> -<ADDRESS> -Fabio Somenzi -2012-02-04 -</ADDRESS> -</BODY> -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node8.html b/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node8.html deleted file mode 100644 index a723fa181..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/doc/node8.html +++ /dev/null @@ -1,848 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> - -<!--Converted with LaTeX2HTML 2008 (1.71) -original version by: Nikos Drakos, CBLU, University of Leeds -* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan -* with significant contributions from: - Jens Lippmann, Marek Rouchal, Martin Wilck and others --> -<HTML> -<HEAD> -<TITLE>Index</TITLE> -<META NAME="description" CONTENT="Index"> -<META NAME="keywords" CONTENT="cuddIntro"> -<META NAME="resource-type" CONTENT="document"> -<META NAME="distribution" CONTENT="global"> - -<META NAME="Generator" CONTENT="LaTeX2HTML v2008"> -<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> - -<LINK REL="STYLESHEET" HREF="cuddIntro.css"> - -<LINK REL="previous" HREF="node7.html"> -<LINK REL="up" HREF="cuddIntro.html"> -</HEAD> - -<BODY > -<!--Navigation Panel--> -<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" - SRC="icons/next_g.png"> -<A NAME="tex2html216" - HREF="cuddIntro.html"> -<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" - SRC="icons/up.png"></A> -<A NAME="tex2html212" - HREF="node7.html"> -<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" - SRC="icons/prev.png"></A> -<BR> -<B> Up:</B> <A NAME="tex2html217" - HREF="cuddIntro.html">CUDD: CU Decision Diagram</A> -<B> Previous:</B> <A NAME="tex2html213" - HREF="node7.html">Bibliography</A> -<BR> -<BR> -<!--End of Navigation Panel--> -<BR> - -<H2><A NAME="SECTION00080000000000000000"> -Index</A> -</H2><DL COMPACT> -<DT><STRONG>ADD</STRONG> -<DD><A HREF="node1.html#16">Introduction</A> - | <A HREF="node3.html#116">Nodes</A> - | <A HREF="node3.html#261">New Constants</A> - | <A HREF="node3.html#335">Basic ADD Manipulation</A> -<DT><STRONG>aggregation</STRONG> -<DD><A HREF="node3.html#473">Variable Reordering for BDDs</A> -<DT><STRONG>Algebraic Decision Diagram</STRONG> -<DD><i>see </i> ADD -<DT><STRONG>arc</STRONG> -<DD><DL COMPACT> -<DT><STRONG>complement</STRONG> -<DD><A HREF="node3.html#270">New BDD and ADD</A> - | <A HREF="node3.html#680">Writing Decision Diagrams to</A> - | <A HREF="node3.html#680">Writing Decision Diagrams to</A> - | <A HREF="node4.html#805">Complement Arcs</A> - | <A HREF="node4.html#809">Complement Arcs</A> -<DT><STRONG>regular</STRONG> -<DD><A HREF="node3.html#681">Writing Decision Diagrams to</A> - | <A HREF="node3.html#681">Writing Decision Diagrams to</A> - | <A HREF="node4.html#808">Complement Arcs</A> -</DL> -<DT><STRONG>background value</STRONG> -<DD><A HREF="node3.html#234">Background</A> -<DT><STRONG>BDD</STRONG> -<DD><A HREF="node1.html#14">Introduction</A> - | <A HREF="node3.html#115">Nodes</A> - | <A HREF="node3.html#200">One, Logic Zero, and</A> - | <A HREF="node3.html#302">Basic BDD Manipulation</A> -<DT><STRONG>Binary Decision Diagram</STRONG> -<DD><i>see </i> BDD -<DT><STRONG>box</STRONG> -<DD><DL COMPACT> -<DT><STRONG>black</STRONG> -<DD><A HREF="node1.html#27">Introduction</A> -<DT><STRONG>clear</STRONG> -<DD><A HREF="node1.html#32">Introduction</A> - | <A HREF="node4.html#704">Compiling and Linking</A> -</DL> -<DT><STRONG>cache</STRONG> -<DD><A HREF="node3.html#141">Cache</A> - | <A HREF="node3.html#144">Cache</A> - | <A HREF="node3.html#146">Cache</A> - | <A HREF="node3.html#163">Initializing and Shutting Down</A> - | <A HREF="node4.html#807">Complement Arcs</A> - | <A HREF="node4.html#817">The Cache</A> -<DL COMPACT> -<DT><STRONG>collision</STRONG> -<DD><A HREF="node4.html#962">Non Modifiable Parameters</A> -<DT><STRONG>collision list</STRONG> -<DD><A HREF="node4.html#877">The Unique Table</A> -<DT><STRONG>deletion</STRONG> -<DD><A HREF="node4.html#963">Non Modifiable Parameters</A> -<DT><STRONG>local</STRONG> -<DD><A HREF="node4.html#827">The Cache</A> - | <A HREF="node4.html#857">Local Caches</A> -<DT><STRONG>lossless</STRONG> -<DD><A HREF="node4.html#859">Local Caches</A> -<DT><STRONG>reward-based resizing</STRONG> -<DD><A HREF="node4.html#851">Cache Sizing</A> - | <A HREF="node4.html#854">Cache Sizing</A> -<DT><STRONG>sizing</STRONG> -<DD><A HREF="node4.html#846">Cache Sizing</A> -</DL> -<DT><STRONG>cacheSize</STRONG> -<DD><A HREF="node3.html#162">Initializing and Shutting Down</A> -<DT><STRONG>canonical</STRONG> -<DD><A HREF="node3.html#132">The Manager</A> - | <A HREF="node4.html#860">Local Caches</A> -<DT><STRONG>compiling</STRONG> -<DD><A HREF="node3.html#79">Compiling and Linking</A> - | <A HREF="node3.html#218">Predefined Constants</A> - | <A HREF="node4.html#702">Compiling and Linking</A> -<DT><STRONG>configuration</STRONG> -<DD><A HREF="node2.html#55">The CUDD Package</A> -<DT><STRONG>conversion</STRONG> -<DD><DL COMPACT> -<DT><STRONG>of ADDs to BDDs</STRONG> -<DD><A HREF="node3.html#377">Converting ADDs to BDDs</A> -<DT><STRONG>of BDDs to ADDs</STRONG> -<DD><A HREF="node3.html#378">Converting ADDs to BDDs</A> -<DT><STRONG>of BDDs to ZDDs</STRONG> -<DD><A HREF="node3.html#357">Basic ZDD Manipulation</A> - | <A HREF="node3.html#394">Converting BDDs to ZDDs</A> -<DT><STRONG>of ZDDs to BDDs</STRONG> -<DD><A HREF="node3.html#393">Converting BDDs to ZDDs</A> -</DL> -<DT><STRONG>cube sets</STRONG> -<DD><A HREF="node1.html#23">Introduction</A> -<DT><STRONG>cudd.h</STRONG> -<DD><A HREF="node3.html#82">Compiling and Linking</A> - | <A HREF="node3.html#437">Variable Reordering for BDDs</A> - | <A HREF="node4.html#797">Saturating Increments and Decrements</A> -<DT><STRONG><I>Cudd_addApply</I></STRONG> -<DD><A HREF="node3.html#1190">Basic ADD Manipulation</A> - | <A HREF="node3.html#1192">Basic ADD Manipulation</A> -<DT><STRONG><I>Cudd_addBddInterval</I></STRONG> -<DD><A HREF="node3.html#1208">Converting ADDs to BDDs</A> -<DT><STRONG><I>Cudd_addBddPattern</I></STRONG> -<DD><A HREF="node3.html#1206">Converting ADDs to BDDs</A> -<DT><STRONG><I>Cudd_addBddThreshold</I></STRONG> -<DD><A HREF="node3.html#1210">Converting ADDs to BDDs</A> -<DT><STRONG><I>Cudd_addConst</I></STRONG> -<DD><A HREF="node3.html#1160">New Constants</A> -<DT><STRONG><I>Cudd_addHarwell</I></STRONG> -<DD><A HREF="node3.html#1152">Background</A> -<DT><STRONG><I>Cudd_AddHook</I></STRONG> -<DD><A HREF="node3.html#1276">Hooks</A> -<DT><STRONG><I>Cudd_addIthBit</I></STRONG> -<DD><A HREF="node3.html#1214">Converting ADDs to BDDs</A> -<DT><STRONG><I>Cudd_addIthVar</I></STRONG> -<DD><A HREF="node3.html#1172">New BDD and ADD</A> -<DT><STRONG><I>Cudd_addNewVar</I></STRONG> -<DD><A HREF="node3.html#1174">New BDD and ADD</A> -<DT><STRONG><I>Cudd_addNewVarAtLevel</I></STRONG> -<DD><A HREF="node3.html#1176">New BDD and ADD</A> - | <A HREF="node3.html#1258">Grouping Variables</A> -<DT><STRONG><I>Cudd_addRead</I></STRONG> -<DD><A HREF="node3.html#1150">Background</A> -<DT><STRONG><I>Cudd_addTimes</I></STRONG> -<DD><A HREF="node3.html#1194">Basic ADD Manipulation</A> -<DT><STRONG><I>Cudd_AutodynDisable</I></STRONG> -<DD><A HREF="node3.html#1228">Variable Reordering for BDDs</A> -<DT><STRONG><I>Cudd_AutodynDisableZdd</I></STRONG> -<DD><A HREF="node3.html#1266">Variable Reordering for ZDDs</A> -<DT><STRONG><I>Cudd_AutodynEnable</I></STRONG> -<DD><A HREF="node3.html#1226">Variable Reordering for BDDs</A> - | <A HREF="node3.html#1232">Variable Reordering for BDDs</A> -<DT><STRONG><I>Cudd_AutodynEnableZdd</I></STRONG> -<DD><A HREF="node3.html#1264">Variable Reordering for ZDDs</A> -<DT><STRONG><I>Cudd_bddAnd</I></STRONG> -<DD><A HREF="node3.html#1182">Basic BDD Manipulation</A> - | <A HREF="node3.html#1186">Basic BDD Manipulation</A> - | <A HREF="node3.html#1196">Basic ADD Manipulation</A> -<DT><STRONG><I>Cudd_bddAndLimit</I></STRONG> -<DD><A HREF="node3.html#1284">Timeouts and Limits</A> -<DT><STRONG><I>Cudd_bddConstrain</I></STRONG> -<DD><A HREF="node3.html#1112">Nodes</A> -<DT><STRONG><I>Cudd_bddIte</I></STRONG> -<DD><A HREF="node3.html#1180">Basic BDD Manipulation</A> -<DT><STRONG><I>Cudd_bddIthVar</I></STRONG> -<DD><A HREF="node3.html#1162">New BDD and ADD</A> -<DT><STRONG><I>Cudd_bddNewVar</I></STRONG> -<DD><A HREF="node3.html#1164">New BDD and ADD</A> - | <A HREF="node3.html#1168">New BDD and ADD</A> - | <A HREF="node3.html#1170">New BDD and ADD</A> -<DT><STRONG><I>Cudd_bddNewVarAtLevel</I></STRONG> -<DD><A HREF="node3.html#1166">New BDD and ADD</A> - | <A HREF="node3.html#1256">Grouping Variables</A> -<DT><STRONG><I>Cudd_BddToAdd</I></STRONG> -<DD><A HREF="node3.html#1212">Converting ADDs to BDDs</A> -<DT><STRONG><I>Cudd_bddXor</I></STRONG> -<DD><A HREF="node3.html#1198">Basic ADD Manipulation</A> -<DT><STRONG>CUDD_CACHE_SLOTS</STRONG> -<DD><A HREF="node3.html#164">Initializing and Shutting Down</A> -<DT><STRONG><I>Cudd_CheckKeys</I></STRONG> -<DD><A HREF="node4.html#1384">Debugging</A> -<DT><STRONG><I>Cudd_CheckZeroRef</I></STRONG> -<DD><A HREF="node4.html#1390">Debugging</A> -<DT><STRONG><I>Cudd_CountMinterm</I></STRONG> -<DD><A HREF="node3.html#1158">Background</A> -<DT><STRONG><I>Cudd_DebugCheck</I></STRONG> -<DD><A HREF="node4.html#1382">Debugging</A> -<DT><STRONG><I>Cudd_DelayedDerefBdd</I></STRONG> -<DD><A HREF="node4.html#1394">Non Modifiable Parameters</A> -<DT><STRONG><I>Cudd_Deref</I></STRONG> -<DD><A HREF="node4.html#1330"><I>Cudd_RecursiveDeref</I> vs. <I>Cudd_Deref</I></A> - | <A HREF="node4.html#1342">Saturating Increments and Decrements</A> -<DT><STRONG><I>Cudd_DumpBlif</I></STRONG> -<DD><A HREF="node3.html#1286">Writing Decision Diagrams to</A> -<DT><STRONG><I>Cudd_DumpDaVinci</I></STRONG> -<DD><A HREF="node3.html#1292">Writing Decision Diagrams to</A> -<DT><STRONG><I>Cudd_DumpDot</I></STRONG> -<DD><A HREF="node3.html#1288">Writing Decision Diagrams to</A> -<DT><STRONG><I>Cudd_ForeachCube</I></STRONG> -<DD><A HREF="node3.html#1108">Nodes</A> - | <A HREF="node3.html#1156">Background</A> -<DT><STRONG><I>Cudd_ForeachNode</I></STRONG> -<DD><A HREF="node3.html#1110">Nodes</A> -<DT><STRONG><I>Cudd_HookType</I></STRONG> -<DD><A HREF="node3.html#1274">Hooks</A> -<DT><STRONG><I>Cudd_Init</I></STRONG> -<DD><A HREF="node3.html#1120">Initializing and Shutting Down</A> - | <A HREF="node3.html#1122">Initializing and Shutting Down</A> -<DT><STRONG><I>Cudd_MakeTreeNode</I></STRONG> -<DD><A HREF="node3.html#1248">Grouping Variables</A> - | <A HREF="node3.html#1254">Grouping Variables</A> -<DT><STRONG><I>Cudd_MakeZddTreeNode</I></STRONG> -<DD><A HREF="node3.html#1268">Variable Reordering for ZDDs</A> -<DT><STRONG><I>Cudd_Not</I></STRONG> -<DD><A HREF="node3.html#1134">One, Logic Zero, and</A> -<DT><STRONG><I>Cudd_PrintInfo</I></STRONG> -<DD><A HREF="node4.html#1392">Gathering and Interpreting Statistics</A> -<DT><STRONG><I>Cudd_PrintMinterm</I></STRONG> -<DD><A HREF="node3.html#1154">Background</A> -<DT><STRONG><I>Cudd_Quit</I></STRONG> -<DD><A HREF="node3.html#1124">Initializing and Shutting Down</A> -<DT><STRONG><I>Cudd_ReadBackground</I></STRONG> -<DD><A HREF="node3.html#1148">Background</A> -<DT><STRONG><I>Cudd_ReadEpsilon</I></STRONG> -<DD><A HREF="node3.html#1144">Predefined Constants</A> -<DT><STRONG><I>Cudd_ReadErrorCode</I></STRONG> -<DD><A HREF="node4.html#1326">NULL Return Values</A> -<DT><STRONG><I>Cudd_ReadInvPerm</I></STRONG> -<DD><A HREF="node3.html#1188">Basic BDD Manipulation</A> -<DT><STRONG><I>Cudd_ReadLogicZero</I></STRONG> -<DD><A HREF="node3.html#1136">One, Logic Zero, and</A> -<DT><STRONG><I>Cudd_ReadLooseUpto</I></STRONG> -<DD><A HREF="node3.html#1126">Setting Parameters</A> -<DT><STRONG><I>Cudd_ReadMaxGrowth</I></STRONG> -<DD><A HREF="node3.html#1240">Variable Reordering for BDDs</A> -<DT><STRONG><I>Cudd_ReadMinusInfinity</I></STRONG> -<DD><A HREF="node3.html#1142">Predefined Constants</A> -<DT><STRONG><I>Cudd_ReadOne</I></STRONG> -<DD><A HREF="node3.html#1130">One, Logic Zero, and</A> -<DT><STRONG><I>Cudd_ReadPlusInfinity</I></STRONG> -<DD><A HREF="node3.html#1140">Predefined Constants</A> -<DT><STRONG><I>Cudd_ReadReorderings</I></STRONG> -<DD><A HREF="node4.html#1378">Allowing Asynchronous Reordering</A> -<DT><STRONG><I>Cudd_ReadSiftMaxVar</I></STRONG> -<DD><A HREF="node3.html#1236">Variable Reordering for BDDs</A> -<DT><STRONG><I>Cudd_ReadTree</I></STRONG> -<DD><A HREF="node3.html#1252">Grouping Variables</A> -<DT><STRONG><I>Cudd_ReadZddOne</I></STRONG> -<DD><A HREF="node3.html#1132">One, Logic Zero, and</A> - | <A HREF="node3.html#1200">Basic ZDD Manipulation</A> -<DT><STRONG><I>Cudd_ReadZero</I></STRONG> -<DD><A HREF="node3.html#1138">Predefined Constants</A> -<DT><STRONG><I>Cudd_RecursiveDeref</I></STRONG> -<DD><A HREF="node3.html#1116">Nodes</A> - | <A HREF="node4.html#1308">Reference Counts</A> - | <A HREF="node4.html#1312">Reference Counts</A> - | <A HREF="node4.html#1322">Reference Counts</A> - | <A HREF="node4.html#1328"><I>Cudd_RecursiveDeref</I> vs. <I>Cudd_Deref</I></A> - | <A HREF="node4.html#1334">When Increasing the Reference</A> - | <A HREF="node4.html#1338">Saturating Increments and Decrements</A> - | <A HREF="node4.html#1366">Local Caches</A> - | <A HREF="node4.html#1388">Debugging</A> -<DT><STRONG><I>Cudd_RecursiveDerefZdd</I></STRONG> -<DD><A HREF="node3.html#1118">Nodes</A> - | <A HREF="node4.html#1310">Reference Counts</A> - | <A HREF="node4.html#1314">Reference Counts</A> - | <A HREF="node4.html#1324">Reference Counts</A> - | <A HREF="node4.html#1336">When Increasing the Reference</A> - | <A HREF="node4.html#1340">Saturating Increments and Decrements</A> -<DT><STRONG><I>Cudd_ReduceHeap</I></STRONG> -<DD><A HREF="node3.html#1224">Variable Reordering for BDDs</A> - | <A HREF="node3.html#1230">Variable Reordering for BDDs</A> - | <A HREF="node3.html#1234">Variable Reordering for BDDs</A> -<DT><STRONG><I>Cudd_Ref</I></STRONG> -<DD><A HREF="node3.html#1114">Nodes</A> - | <A HREF="node3.html#1184">Basic BDD Manipulation</A> - | <A HREF="node4.html#1306">Reference Counts</A> - | <A HREF="node4.html#1332">When Increasing the Reference</A> -<DT><STRONG><I>Cudd_Regular</I></STRONG> -<DD><A HREF="node4.html#1348">Complement Arcs</A> -<DT><STRONG>CUDD_REORDER_ANNEALING</STRONG> -<DD><A HREF="node3.html#485">Variable Reordering for BDDs</A> -<DT><STRONG>CUDD_REORDER_EXACT</STRONG> -<DD><A HREF="node3.html#491">Variable Reordering for BDDs</A> -<DT><STRONG>CUDD_REORDER_GENETIC</STRONG> -<DD><A HREF="node3.html#488">Variable Reordering for BDDs</A> -<DT><STRONG>CUDD_REORDER_GROUP_SIFT</STRONG> -<DD><A HREF="node3.html#470">Variable Reordering for BDDs</A> -<DT><STRONG>CUDD_REORDER_GROUP_SIFT_CONV</STRONG> -<DD><A HREF="node3.html#474">Variable Reordering for BDDs</A> -<DT><STRONG>CUDD_REORDER_NONE</STRONG> -<DD><A HREF="node3.html#440">Variable Reordering for BDDs</A> - | <A HREF="node3.html#544">Variable Reordering for ZDDs</A> -<DT><STRONG>CUDD_REORDER_RANDOM</STRONG> -<DD><A HREF="node3.html#446">Variable Reordering for BDDs</A> - | <A HREF="node3.html#546">Variable Reordering for ZDDs</A> -<DT><STRONG>CUDD_REORDER_RANDOM_PIVOT</STRONG> -<DD><A HREF="node3.html#448">Variable Reordering for BDDs</A> - | <A HREF="node3.html#547">Variable Reordering for ZDDs</A> -<DT><STRONG>CUDD_REORDER_SAME</STRONG> -<DD><A HREF="node3.html#441">Variable Reordering for BDDs</A> - | <A HREF="node3.html#545">Variable Reordering for ZDDs</A> -<DT><STRONG>CUDD_REORDER_SIFT</STRONG> -<DD><A HREF="node3.html#449">Variable Reordering for BDDs</A> - | <A HREF="node3.html#548">Variable Reordering for ZDDs</A> -<DT><STRONG>CUDD_REORDER_SIFT_CONVERGE</STRONG> -<DD><A HREF="node3.html#460">Variable Reordering for BDDs</A> - | <A HREF="node3.html#549">Variable Reordering for ZDDs</A> -<DT><STRONG>CUDD_REORDER_SYMM_SIFT</STRONG> -<DD><A HREF="node3.html#462">Variable Reordering for BDDs</A> - | <A HREF="node3.html#550">Variable Reordering for ZDDs</A> -<DT><STRONG>CUDD_REORDER_SYMM_SIFT_CONV</STRONG> -<DD><A HREF="node3.html#468">Variable Reordering for BDDs</A> - | <A HREF="node3.html#551">Variable Reordering for ZDDs</A> -<DT><STRONG>CUDD_REORDER_WINDOW2</STRONG> -<DD><A HREF="node3.html#475">Variable Reordering for BDDs</A> -<DT><STRONG>CUDD_REORDER_WINDOW2_CONV</STRONG> -<DD><A HREF="node3.html#481">Variable Reordering for BDDs</A> -<DT><STRONG>CUDD_REORDER_WINDOW3</STRONG> -<DD><A HREF="node3.html#479">Variable Reordering for BDDs</A> -<DT><STRONG>CUDD_REORDER_WINDOW3_CONV</STRONG> -<DD><A HREF="node3.html#483">Variable Reordering for BDDs</A> -<DT><STRONG>CUDD_REORDER_WINDOW4</STRONG> -<DD><A HREF="node3.html#480">Variable Reordering for BDDs</A> -<DT><STRONG>CUDD_REORDER_WINDOW4_CONV</STRONG> -<DD><A HREF="node3.html#484">Variable Reordering for BDDs</A> -<DT><STRONG><I>Cudd_SetEpsilon</I></STRONG> -<DD><A HREF="node3.html#1146">Predefined Constants</A> -<DT><STRONG><I>Cudd_SetLooseUpTo</I></STRONG> -<DD><A HREF="node3.html#1128">Setting Parameters</A> -<DT><STRONG><I>Cudd_SetMaxCacheHard</I></STRONG> -<DD><A HREF="node4.html#1396">Modifiable Parameters</A> -<DT><STRONG><I>Cudd_SetMaxGrowth</I></STRONG> -<DD><A HREF="node3.html#1242">Variable Reordering for BDDs</A> -<DT><STRONG><I>Cudd_SetSiftMaxVar</I></STRONG> -<DD><A HREF="node3.html#1238">Variable Reordering for BDDs</A> -<DT><STRONG><I>Cudd_SetTimeLimit</I></STRONG> -<DD><A HREF="node3.html#1282">Timeouts and Limits</A> -<DT><STRONG><I>Cudd_SetTree</I></STRONG> -<DD><A HREF="node3.html#1250">Grouping Variables</A> -<DT><STRONG><I>Cudd_ShuffleHeap</I></STRONG> -<DD><A HREF="node3.html#1246">Variable Reordering for BDDs</A> -<DT><STRONG><I>Cudd_StdPostReordHook</I></STRONG> -<DD><A HREF="node3.html#1280">Hooks</A> -<DT><STRONG><I>Cudd_StdPreReordHook</I></STRONG> -<DD><A HREF="node3.html#1278">Hooks</A> -<DT><STRONG><I>Cudd_SymmProfile</I></STRONG> -<DD><A HREF="node3.html#1244">Variable Reordering for BDDs</A> -<DT><STRONG>CUDD_UNIQUE_SLOTS</STRONG> -<DD><A HREF="node3.html#161">Initializing and Shutting Down</A> -<DT><STRONG><I>Cudd_zddDumpDot</I></STRONG> -<DD><A HREF="node3.html#1290">Writing Decision Diagrams to</A> -<DT><STRONG><I>Cudd_zddIsop</I></STRONG> -<DD><A HREF="node3.html#1202">Basic ZDD Manipulation</A> -<DT><STRONG><I>Cudd_zddIthVar</I></STRONG> -<DD><A HREF="node3.html#1178">New ZDD Variables</A> -<DT><STRONG><I>Cudd_zddPortFromBdd</I></STRONG> -<DD><A HREF="node3.html#1218">Converting BDDs to ZDDs</A> -<DT><STRONG><I>Cudd_zddPortToBdd</I></STRONG> -<DD><A HREF="node3.html#1220">Converting BDDs to ZDDs</A> -<DT><STRONG><I>Cudd_zddRealignDisable</I></STRONG> -<DD><A HREF="node3.html#1272">Keeping Consistent Variable Orders</A> -<DT><STRONG><I>Cudd_zddRealignEnable</I></STRONG> -<DD><A HREF="node3.html#1270">Keeping Consistent Variable Orders</A> -<DT><STRONG><I>Cudd_zddReduceHeap</I></STRONG> -<DD><A HREF="node3.html#1260">Variable Reordering for ZDDs</A> -<DT><STRONG><I>Cudd_zddShuffleHeap</I></STRONG> -<DD><A HREF="node3.html#1262">Variable Reordering for ZDDs</A> -<DT><STRONG><I>Cudd_zddVarsFromBddVars</I></STRONG> -<DD><A HREF="node3.html#1216">Converting BDDs to ZDDs</A> - | <A HREF="node3.html#1222">Converting BDDs to ZDDs</A> -<DT><STRONG><I>Cudd_zddWeakDiv</I></STRONG> -<DD><A HREF="node3.html#1204">Basic ZDD Manipulation</A> -<DT><STRONG><I>cuddCacheInsert</I></STRONG> -<DD><A HREF="node4.html#1354">The Cache</A> -<DT><STRONG><I>cuddCacheInsert1</I></STRONG> -<DD><A HREF="node4.html#1362">The Cache</A> -<DT><STRONG><I>cuddCacheInsert2</I></STRONG> -<DD><A HREF="node4.html#1358">The Cache</A> -<DT><STRONG><I>cuddCacheLookup</I></STRONG> -<DD><A HREF="node4.html#1356">The Cache</A> -<DT><STRONG><I>cuddCacheLookup1</I></STRONG> -<DD><A HREF="node4.html#1364">The Cache</A> -<DT><STRONG><I>cuddCacheLookup2</I></STRONG> -<DD><A HREF="node4.html#1360">The Cache</A> -<DT><STRONG>CUDDDIR</STRONG> -<DD><A HREF="node3.html#595">Using the CUDD Package</A> -<DT><STRONG><I>cuddHeapProfile</I></STRONG> -<DD><A HREF="node4.html#1386">Debugging</A> -<DT><STRONG><I>cuddI</I></STRONG> -<DD><A HREF="node4.html#1368">The Unique Table</A> -<DT><STRONG>cuddInt.h</STRONG> -<DD><A HREF="node4.html#927">Debugging</A> -<DT><STRONG><I>cuddIZ</I></STRONG> -<DD><A HREF="node4.html#1370">The Unique Table</A> -<DT><STRONG><I>cuddSatDec</I></STRONG> -<DD><A HREF="node4.html#1346">Saturating Increments and Decrements</A> -<DT><STRONG><I>cuddSatInc</I></STRONG> -<DD><A HREF="node4.html#1344">Saturating Increments and Decrements</A> -<DT><STRONG><I>cuddUniqueConst</I></STRONG> -<DD><A HREF="node4.html#1298">Reference Counts</A> - | <A HREF="node4.html#1304">Reference Counts</A> - | <A HREF="node4.html#1320">Reference Counts</A> -<DT><STRONG><I>cuddUniqueInter</I></STRONG> -<DD><A HREF="node4.html#1294">Reference Counts</A> - | <A HREF="node4.html#1300">Reference Counts</A> - | <A HREF="node4.html#1316">Reference Counts</A> - | <A HREF="node4.html#1350">Complement Arcs</A> - | <A HREF="node4.html#1352">Complement Arcs</A> - | <A HREF="node4.html#1372">Allowing Asynchronous Reordering</A> - | <A HREF="node4.html#1376">Allowing Asynchronous Reordering</A> - | <A HREF="node4.html#1380">Allowing Asynchronous Reordering</A> -<DT><STRONG><I>cuddUniqueInterZdd</I></STRONG> -<DD><A HREF="node4.html#1296">Reference Counts</A> - | <A HREF="node4.html#1302">Reference Counts</A> - | <A HREF="node4.html#1318">Reference Counts</A> - | <A HREF="node4.html#1374">Allowing Asynchronous Reordering</A> -<DT><STRONG>DD_CACHE_PROFILE</STRONG> -<DD><A HREF="node4.html#1019">Extended Statistics and Reporting</A> -<DT><STRONG>DD_DEBUG</STRONG> -<DD><A HREF="node4.html#918">Debugging</A> -<DT><STRONG>DD_STATS</STRONG> -<DD><A HREF="node4.html#1018">Extended Statistics and Reporting</A> -<DT><STRONG>DD_UNIQUE_PROFILE</STRONG> -<DD><A HREF="node4.html#1020">Extended Statistics and Reporting</A> -<DT><STRONG>DD_VERBOSE</STRONG> -<DD><A HREF="node4.html#1021">Extended Statistics and Reporting</A> -<DT><STRONG>DdManager</STRONG> -<DD><A HREF="node3.html#134">The Manager</A> - | <A HREF="node3.html#149">Initializing and Shutting Down</A> -<DT><STRONG>DdNode</STRONG> -<DD><A HREF="node3.html#92">Nodes</A> - | <A HREF="node4.html#825">The Cache</A> -<DT><STRONG>debugging</STRONG> -<DD><A HREF="node4.html#916">Debugging</A> -<DT><STRONG>DEC Alpha</STRONG> -<DD><A HREF="node3.html#217">Predefined Constants</A> - | <A HREF="node3.html#662">Using the CUDD Package</A> -<DT><STRONG>documentation</STRONG> -<DD><A HREF="node4.html#1025">Guidelines for Documentation</A> -<DL COMPACT> -<DT><STRONG><I>Description</I></STRONG> -<DD><A HREF="node4.html#1097">Guidelines for Documentation</A> -<DT><STRONG>HTML files</STRONG> -<DD><A HREF="node4.html#1041">Guidelines for Documentation</A> -<DT><STRONG><I>SeeAlso</I></STRONG> -<DD><A HREF="node4.html#1096">Guidelines for Documentation</A> -<DT><STRONG><I>Synopsis</I></STRONG> -<DD><A HREF="node4.html#1098">Guidelines for Documentation</A> -</DL> -<DT><STRONG>dot</STRONG> -<DD><i>see </i> graph, drawing -<DT><STRONG>Epsilon</STRONG> -<DD><A HREF="node3.html#226">Predefined Constants</A> -<DT><STRONG>extdoc</STRONG> -<DD><i>see </i> documentation -<DT><STRONG>floating point</STRONG> -<DD><A HREF="node3.html#215">Predefined Constants</A> -<DL COMPACT> -<DT><STRONG>double (C type)</STRONG> -<DD><A HREF="node3.html#126">Nodes</A> -<DT><STRONG>IEEE Standard 754</STRONG> -<DD><A HREF="node3.html#214">Predefined Constants</A> -</DL> -<DT><STRONG>free list</STRONG> -<DD><A HREF="node4.html#743">Reference Counts</A> -<DT><STRONG>FTP</STRONG> -<DD><A HREF="node2.html#46">The CUDD Package</A> - | <A HREF="node2.html#68">CUDD Friends</A> - | <A HREF="node3.html#657">Using the CUDD Package</A> - | <A HREF="node4.html#1026">Guidelines for Documentation</A> -<DT><STRONG>function</STRONG> -<DD><DL COMPACT> -<DT><STRONG>characteristic</STRONG> -<DD><A HREF="node1.html#22">Introduction</A> - | <A HREF="node3.html#413">Converting BDDs to ZDDs</A> -<DT><STRONG>cover</STRONG> -<DD><A HREF="node3.html#367">Basic ZDD Manipulation</A> - | <A HREF="node3.html#406">Converting BDDs to ZDDs</A> - | <A HREF="node3.html#412">Converting BDDs to ZDDs</A> -<DD><DL COMPACT> -<DT><STRONG>irredundant</STRONG> -<DD><A HREF="node3.html#370">Basic ZDD Manipulation</A> -</DL> -<DT><STRONG>minterms</STRONG> -<DD><A HREF="node3.html#253">Background</A> - | <A HREF="node4.html#894">Allowing Asynchronous Reordering</A> -<DT><STRONG>ON-set</STRONG> -<DD><A HREF="node1.html#24">Introduction</A> -<DT><STRONG>sum of products</STRONG> -<DD><A HREF="node3.html#248">Background</A> -<DT><STRONG>switching</STRONG> -<DD><A HREF="node1.html#20">Introduction</A> - | <A HREF="node1.html#21">Introduction</A> -</DL> -<DT><STRONG>garbage collection</STRONG> -<DD><A HREF="node3.html#113">Nodes</A> - | <A HREF="node3.html#145">Cache</A> - | <A HREF="node3.html#180">Setting Parameters</A> - | <A HREF="node4.html#711">Reference Counts</A> - | <A HREF="node4.html#742">Reference Counts</A> - | <A HREF="node4.html#822">The Cache</A> - | <A HREF="node4.html#861">Local Caches</A> - | <A HREF="node4.html#879">The Unique Table</A> -<DL COMPACT> -<DT><STRONG>hooks</STRONG> -<DD><A HREF="node3.html#568">Hooks</A> -</DL> -<DT><STRONG>gcc</STRONG> -<DD><A HREF="node3.html#219">Predefined Constants</A> -<DT><STRONG>generator</STRONG> -<DD><A HREF="node3.html#104">Nodes</A> -<DT><STRONG>global variables</STRONG> -<DD><A HREF="node3.html#138">The Manager</A> -<DT><STRONG>graph</STRONG> -<DD><DL COMPACT> -<DT><STRONG>arc capacity</STRONG> -<DD><A HREF="node3.html#239">Background</A> -<DT><STRONG>arc length</STRONG> -<DD><A HREF="node3.html#237">Background</A> -<DT><STRONG>drawing</STRONG> -<DD><A HREF="node3.html#673">Writing Decision Diagrams to</A> - | <A HREF="node3.html#689">Writing Decision Diagrams to</A> -</DL> -<DT><STRONG>growth</STRONG> -<DD><A HREF="node3.html#181">Setting Parameters</A> -<DT><STRONG>gzip</STRONG> -<DD><A HREF="node2.html#50">The CUDD Package</A> -<DT><STRONG>HAVE_IEEE_754</STRONG> -<DD><A HREF="node3.html#220">Predefined Constants</A> -<DT><STRONG>header files</STRONG> -<DD><A HREF="node3.html#438">Variable Reordering for BDDs</A> - | <A HREF="node4.html#795">Saturating Increments and Decrements</A> -<DT><STRONG>hook</STRONG> -<DD><A HREF="node3.html#562">Hooks</A> -<DT><STRONG>infinities</STRONG> -<DD><A HREF="node3.html#216">Predefined Constants</A> -<DT><STRONG>installation</STRONG> -<DD><A HREF="node2.html#56">The CUDD Package</A> -<DT><STRONG>Intel Pentium 4</STRONG> -<DD><A HREF="node2.html#61">The CUDD Package</A> -<DT><STRONG>interface</STRONG> -<DD><DL COMPACT> -<DT><STRONG>cache</STRONG> -<DD><A HREF="node4.html#832">The Cache</A> -<DT><STRONG>SIS</STRONG> -<DD><A HREF="node3.html#584">The SIS/VIS Interface</A> - | <A HREF="node3.html#592">Using the CUDD Package</A> -<DT><STRONG>VIS</STRONG> -<DD><A HREF="node3.html#585">The SIS/VIS Interface</A> -</DL> -<DT><STRONG>libraries</STRONG> -<DD><A HREF="node2.html#53">The CUDD Package</A> -<DL COMPACT> -<DT><STRONG>cudd</STRONG> -<DD><A HREF="node3.html#83">Compiling and Linking</A> -<DT><STRONG>dddmp</STRONG> -<DD><A HREF="node3.html#698">Saving and Restoring BDDs</A> -<DT><STRONG>mtr</STRONG> -<DD><A HREF="node3.html#84">Compiling and Linking</A> - | <A HREF="node3.html#505">Grouping Variables</A> -<DT><STRONG>obj</STRONG> -<DD><A HREF="node5.html#1051">Compiling and Linking</A> -<DT><STRONG>st</STRONG> -<DD><A HREF="node3.html#85">Compiling and Linking</A> - | <A HREF="node4.html#829">The Cache</A> -<DT><STRONG>util</STRONG> -<DD><A HREF="node3.html#86">Compiling and Linking</A> -</DL> -<DT><STRONG>Makefile</STRONG> -<DD><A HREF="node3.html#87">Compiling and Linking</A> - | <A HREF="node3.html#221">Predefined Constants</A> - | <A HREF="node5.html#1052">Compiling and Linking</A> -<DT><STRONG>manager</STRONG> -<DD><A HREF="node3.html#128">The Manager</A> - | <A HREF="node3.html#135">The Manager</A> - | <A HREF="node3.html#190">Constant Functions</A> -<DT><STRONG>matrix</STRONG> -<DD><DL COMPACT> -<DT><STRONG>sparse</STRONG> -<DD><A HREF="node3.html#240">Background</A> -</DL> -<DT><STRONG>maxCache</STRONG> -<DD><A HREF="node4.html#849">Cache Sizing</A> -<DT><STRONG>maxMemory</STRONG> -<DD><A HREF="node3.html#165">Initializing and Shutting Down</A> -<DT><STRONG>MinusInfinity</STRONG> -<DD><A HREF="node3.html#213">Predefined Constants</A> -<DT><STRONG>MTR_DEFAULT</STRONG> -<DD><A HREF="node3.html#520">Grouping Variables</A> -<DT><STRONG>MTR_FIXED</STRONG> -<DD><A HREF="node3.html#515">Grouping Variables</A> -<DT><STRONG>nanotrav</STRONG> -<DD><A HREF="node2.html#59">The CUDD Package</A> - | <A HREF="node2.html#63">The CUDD Package</A> -<DT><STRONG>node</STRONG> -<DD><A HREF="node3.html#93">Nodes</A> -<DL COMPACT> -<DT><STRONG>constant</STRONG> -<DD><A HREF="node3.html#100">Nodes</A> - | <A HREF="node3.html#188">Constant Functions</A> - | <A HREF="node3.html#195">One, Logic Zero, and</A> - | <A HREF="node3.html#210">Predefined Constants</A> - | <A HREF="node3.html#236">Background</A> - | <A HREF="node3.html#258">New Constants</A> - | <A HREF="node4.html#716">Reference Counts</A> - | <A HREF="node4.html#772">When Increasing the Reference</A> -<DD><DL COMPACT> -<DT><STRONG>value</STRONG> -<DD><A HREF="node3.html#125">Nodes</A> -</DL> -<DT><STRONG>dead</STRONG> -<DD><A HREF="node4.html#733">Reference Counts</A> - | <A HREF="node4.html#823">The Cache</A> - | <A HREF="node4.html#878">The Unique Table</A> -<DT><STRONG>dereference</STRONG> -<DD><A HREF="node3.html#344">Basic ADD Manipulation</A> -<DT><STRONG>reclaimed</STRONG> -<DD><A HREF="node4.html#882">The Unique Table</A> -<DT><STRONG>recycling</STRONG> -<DD><A HREF="node3.html#124">Nodes</A> -<DT><STRONG>reference</STRONG> -<DD><A HREF="node3.html#343">Basic ADD Manipulation</A> -<DT><STRONG>reference count</STRONG> -<DD><A HREF="node3.html#95">Nodes</A> - | <A HREF="node3.html#114">Nodes</A> - | <A HREF="node3.html#315">Basic BDD Manipulation</A> - | <A HREF="node3.html#327">Basic BDD Manipulation</A> - | <A HREF="node4.html#709">Reference Counts</A> - | <A HREF="node4.html#731">Reference Counts</A> - | <A HREF="node4.html#744">Reference Counts</A> - | <A HREF="node4.html#770">When Increasing the Reference</A> - | <A HREF="node4.html#784">Saturating Increments and Decrements</A> - | <A HREF="node4.html#821">The Cache</A> - | <A HREF="node4.html#862">Local Caches</A> - | <A HREF="node4.html#937">Debugging</A> -<DD><DL COMPACT> -<DT><STRONG>saturated</STRONG> -<DD><A HREF="node4.html#939">Debugging</A> -</DL> -<DT><STRONG>terminal</STRONG> -<DD><i>see </i> node, constant -<DT><STRONG>variable index</STRONG> -<DD><A HREF="node3.html#94">Nodes</A> -</DL> -<DT><STRONG>numSlots</STRONG> -<DD><A HREF="node3.html#158">Initializing and Shutting Down</A> -<DT><STRONG>numVars</STRONG> -<DD><A HREF="node3.html#154">Initializing and Shutting Down</A> -<DT><STRONG>numVarsZ</STRONG> -<DD><A HREF="node3.html#155">Initializing and Shutting Down</A> -<DT><STRONG>PlusInfinity</STRONG> -<DD><A HREF="node3.html#212">Predefined Constants</A> - | <A HREF="node3.html#238">Background</A> -<DT><STRONG>projection functions</STRONG> -<DD><A HREF="node3.html#265">Creating Variables</A> - | <A HREF="node3.html#268">New BDD and ADD</A> - | <A HREF="node3.html#276">New BDD and ADD</A> - | <A HREF="node3.html#279">New BDD and ADD</A> - | <A HREF="node3.html#297">New ZDD Variables</A> - | <A HREF="node3.html#314">Basic BDD Manipulation</A> - | <A HREF="node3.html#342">Basic ADD Manipulation</A> - | <A HREF="node3.html#359">Basic ZDD Manipulation</A> - | <A HREF="node3.html#363">Basic ZDD Manipulation</A> - | <A HREF="node4.html#938">Debugging</A> -<DT><STRONG>README file</STRONG> -<DD><A HREF="node2.html#64">The CUDD Package</A> - | <A HREF="node2.html#54">The CUDD Package</A> -<DT><STRONG>reordering</STRONG> -<DD><A HREF="node1.html#25">Introduction</A> - | <A HREF="node1.html#29">Introduction</A> - | <A HREF="node3.html#102">Nodes</A> - | <A HREF="node4.html#824">The Cache</A> -<DL COMPACT> -<DT><STRONG>abort and retry</STRONG> -<DD><A HREF="node4.html#896">Allowing Asynchronous Reordering</A> -<DT><STRONG>asynchronous</STRONG> -<DD><A HREF="node3.html#425">Variable Reordering for BDDs</A> - | <A HREF="node4.html#891">Allowing Asynchronous Reordering</A> -<DT><STRONG>converging</STRONG> -<DD><A HREF="node3.html#432">Variable Reordering for BDDs</A> - | <A HREF="node3.html#461">Variable Reordering for BDDs</A> - | <A HREF="node3.html#469">Variable Reordering for BDDs</A> - | <A HREF="node3.html#482">Variable Reordering for BDDs</A> -<DT><STRONG>Cudd_ReorderingType</STRONG> -<DD><A HREF="node3.html#436">Variable Reordering for BDDs</A> -<DT><STRONG>dynamic</STRONG> -<DD><A HREF="node1.html#34">Introduction</A> - | <A HREF="node3.html#417">Variable Reordering for BDDs</A> - | <A HREF="node3.html#538">Variable Reordering for ZDDs</A> -<DT><STRONG>exact</STRONG> -<DD><A HREF="node3.html#492">Variable Reordering for BDDs</A> -<DT><STRONG>function wrapper</STRONG> -<DD><A HREF="node4.html#898">Allowing Asynchronous Reordering</A> - | <A HREF="node4.html#913">Allowing Asynchronous Reordering</A> -<DT><STRONG>genetic</STRONG> -<DD><A HREF="node3.html#489">Variable Reordering for BDDs</A> -<DT><STRONG>group</STRONG> -<DD><A HREF="node3.html#434">Variable Reordering for BDDs</A> - | <A HREF="node3.html#471">Variable Reordering for BDDs</A> -<DT><STRONG>hooks</STRONG> -<DD><A HREF="node3.html#569">Hooks</A> -<DT><STRONG>interruptible procedure</STRONG> -<DD><A HREF="node4.html#897">Allowing Asynchronous Reordering</A> -<DT><STRONG>of BDDs and ADDs</STRONG> -<DD><A HREF="node3.html#415">Variable Reordering for BDDs</A> -<DT><STRONG>of ZDDs</STRONG> -<DD><A HREF="node3.html#374">Basic ZDD Manipulation</A> - | <A HREF="node3.html#530">Variable Reordering for ZDDs</A> -<DT><STRONG>random</STRONG> -<DD><A HREF="node3.html#447">Variable Reordering for BDDs</A> -<DT><STRONG>sifting</STRONG> -<DD><A HREF="node3.html#435">Variable Reordering for BDDs</A> - | <A HREF="node3.html#450">Variable Reordering for BDDs</A> -<DT><STRONG>simulated annealing</STRONG> -<DD><A HREF="node3.html#486">Variable Reordering for BDDs</A> -<DT><STRONG>symmetric</STRONG> -<DD><A HREF="node3.html#463">Variable Reordering for BDDs</A> -<DT><STRONG>threshold</STRONG> -<DD><A HREF="node3.html#424">Variable Reordering for BDDs</A> - | <A HREF="node4.html#893">Allowing Asynchronous Reordering</A> -<DT><STRONG>window</STRONG> -<DD><A HREF="node3.html#476">Variable Reordering for BDDs</A> -</DL> -<DT><STRONG>saturating</STRONG> -<DD><DL COMPACT> -<DT><STRONG>decrements</STRONG> -<DD><A HREF="node4.html#782">Saturating Increments and Decrements</A> -<DT><STRONG>increments</STRONG> -<DD><A HREF="node4.html#781">Saturating Increments and Decrements</A> -</DL> -<DT><STRONG>SISDIR</STRONG> -<DD><A HREF="node3.html#594">Using the CUDD Package</A> -<DT><STRONG>SIZEOF_INT</STRONG> -<DD><A HREF="node4.html#794">Saturating Increments and Decrements</A> - | <A HREF="node4.html#803">Saturating Increments and Decrements</A> -<DT><STRONG>SIZEOF_VOID_P</STRONG> -<DD><A HREF="node4.html#793">Saturating Increments and Decrements</A> - | <A HREF="node4.html#802">Saturating Increments and Decrements</A> -<DT><STRONG>statistical counters</STRONG> -<DD><A HREF="node3.html#137">The Manager</A> - | <A HREF="node4.html#734">Reference Counts</A> - | <A HREF="node4.html#853">Cache Sizing</A> -<DT><STRONG>statistics</STRONG> -<DD><A HREF="node4.html#941">Gathering and Interpreting Statistics</A> -<DT><STRONG>subtable</STRONG> -<DD><A HREF="node3.html#159">Initializing and Shutting Down</A> - | <A HREF="node4.html#735">Reference Counts</A> -<DT><STRONG>symmetry</STRONG> -<DD><A HREF="node3.html#465">Variable Reordering for BDDs</A> -<DT><STRONG>table</STRONG> -<DD><DL COMPACT> -<DT><STRONG>computed</STRONG> -<DD><A HREF="node3.html#143">Cache</A> -<DT><STRONG>growth</STRONG> -<DD><A HREF="node3.html#179">Setting Parameters</A> -<DT><STRONG>hash</STRONG> -<DD><A HREF="node3.html#130">The Manager</A> - | <A HREF="node4.html#874">The Unique Table</A> -<DT><STRONG>unique</STRONG> -<DD><A HREF="node3.html#96">Nodes</A> - | <A HREF="node3.html#131">The Manager</A> - | <A HREF="node3.html#133">The Manager</A> - | <A HREF="node3.html#160">Initializing and Shutting Down</A> - | <A HREF="node3.html#167">Initializing and Shutting Down</A> - | <A HREF="node3.html#178">Setting Parameters</A> - | <A HREF="node3.html#420">Variable Reordering for BDDs</A> - | <A HREF="node4.html#736">Reference Counts</A> - | <A HREF="node4.html#850">Cache Sizing</A> - | <A HREF="node4.html#855">Cache Sizing</A> - | <A HREF="node4.html#867">The Unique Table</A> -<DD><DL COMPACT> -<DT><STRONG>fast growth</STRONG> -<DD><A HREF="node4.html#885">The Unique Table</A> -<DT><STRONG>reward-based resizing</STRONG> -<DD><A HREF="node4.html#883">The Unique Table</A> -<DT><STRONG>slow growth</STRONG> -<DD><A HREF="node4.html#886">The Unique Table</A> -</DL> -</DL> -<DT><STRONG>timeout</STRONG> -<DD><A HREF="node3.html#577">Timeouts and Limits</A> -<DT><STRONG>variable</STRONG> -<DD><DL COMPACT> -<DT><STRONG>groups</STRONG> -<DD><A HREF="node3.html#499">Grouping Variables</A> -<DT><STRONG>order</STRONG> -<DD><A HREF="node3.html#99">Nodes</A> - | <A HREF="node3.html#284">New BDD and ADD</A> -<DT><STRONG>permutation</STRONG> -<DD><A HREF="node3.html#101">Nodes</A> - | <A HREF="node4.html#869">The Unique Table</A> -<DT><STRONG>tree</STRONG> -<DD><A HREF="node3.html#501">Grouping Variables</A> - | <A HREF="node3.html#524">Grouping Variables</A> -</DL> -<DT><STRONG>ZDD</STRONG> -<DD><A HREF="node1.html#18">Introduction</A> - | <A HREF="node3.html#117">Nodes</A> - | <A HREF="node3.html#295">New ZDD Variables</A> - | <A HREF="node3.html#355">Basic ZDD Manipulation</A> - | <A HREF="node3.html#396">Converting BDDs to ZDDs</A> -<DT><STRONG>zero</STRONG> -<DD><DL COMPACT> -<DT><STRONG>arithmetic</STRONG> -<DD><A HREF="node3.html#193">One, Logic Zero, and</A> - | <A HREF="node3.html#272">New BDD and ADD</A> - | <A HREF="node3.html#389">Converting ADDs to BDDs</A> -<DT><STRONG>logical</STRONG> -<DD><A HREF="node3.html#192">One, Logic Zero, and</A> - | <A HREF="node3.html#388">Converting ADDs to BDDs</A> -</DL> -<DT><STRONG>Zero-suppressed Binary Decision Diagram</STRONG> -<DD><i>see </i> ZDD - -</DL> -<BR><HR> -<ADDRESS> -Fabio Somenzi -2012-02-04 -</ADDRESS> -</BODY> -</HTML> diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/r7x8.1.out b/resources/3rdparty/cudd-2.5.0/src/cudd/r7x8.1.out deleted file mode 100644 index 4dc72222d..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/r7x8.1.out +++ /dev/null @@ -1,396 +0,0 @@ -# TestCudd Version #1.0, Release date 3/17/01 -# ./testcudd -p2 r7x8.1.mat -:name: r7x8.1.mat: 7 rows 9 columns -:1: M: 63 nodes 5 leaves 52 minterms -000000-- 1 -000001-0 1 -000001-1 4 -000010-0 4 -000010-1 3 -000011-0 2 -000011-1 4 -000100-- 3 -000101-0 3 -000110-0 1 -000110-1 2 -000111-0 4 -001000-- 1 -001001-0 4 -001010-0 2 -001010-1 1 -001011-1 4 -001100-0 2 -001100-1 3 -001101-0 3 -001110-0 4 -001110-1 1 -0100-0-0 3 -011000-0 3 -011010-0 1 -100000-0 2 -100000-1 3 -100001-0 2 -100001-1 4 -100010-- 3 -100011-- 4 -100100-- 1 -100101-0 2 -100110-0 1 -100110-1 3 -100111-0 3 -101000-1 1 -101001-0 1 -101001-1 4 -101100-0 2 -101100-1 4 -101101-0 4 -110000-0 2 -110010-0 4 -111000-0 2 - -:2: time to read the matrix = 0.00 sec -:3: C: 22 nodes 1 leaves 52 minterms -0000---- 1 -0001-0-- 1 -0001-1-0 1 -001000-- 1 -001001-0 1 -001010-- 1 -001011-1 1 -001100-- 1 -001101-0 1 -001110-- 1 -01-0-0-0 1 -1000---- 1 -1001-0-- 1 -1001-1-0 1 -101000-1 1 -101001-- 1 -101100-- 1 -101101-0 1 -1100-0-0 1 -111000-0 1 - -Testing iterator on cubes: -000000-- 1 -000001-0 1 -000001-1 4 -000010-0 4 -000010-1 3 -000011-0 2 -000011-1 4 -000100-- 3 -000101-0 3 -000110-0 1 -000110-1 2 -000111-0 4 -001000-- 1 -001001-0 4 -001010-0 2 -001010-1 1 -001011-1 4 -001100-0 2 -001100-1 3 -001101-0 3 -001110-0 4 -001110-1 1 -0100-0-0 3 -011000-0 3 -011010-0 1 -100000-0 2 -100000-1 3 -100001-0 2 -100001-1 4 -100010-- 3 -100011-- 4 -100100-- 1 -100101-0 2 -100110-0 1 -100110-1 3 -100111-0 3 -101000-1 1 -101001-0 1 -101001-1 4 -101100-0 2 -101100-1 4 -101101-0 4 -110000-0 2 -110010-0 4 -111000-0 2 - -Testing prime expansion of cubes: --000---- 1 --00--0-- 1 -0--0-0-0 1 ---00-0-0 1 --0-100-- 1 -10-001-- 1 --00----0 1 -00---0-- 1 --1-000-0 1 --0--01-0 1 --0--00-1 1 -00-01--1 1 - -Testing iterator on primes (CNF): --0-0---- 1 --0---0-- 1 -0-0-0--- 1 --0-----0 1 ----0-0-0 1 -0101-1-1 1 ---0-00-1 1 -1-0-10-0 1 - -Cache used slots = 58.06% (expected 58.94%) -xor1: 14 nodes 1 leaves 28 minterms -000--1-1 1 -001-11-1 1 -01---0-0 1 -100--1-1 1 -101-00-0 1 -101-01-1 1 -110--0-0 1 -111-00-0 1 - -Chosen minterm for Hamming distance test: : 9 nodes 1 leaves 1 minterms -11110010 1 - -Minimum Hamming distance = 1 -ycube: 5 nodes 1 leaves 8 minterms --0-0-0-0 1 - -CP: 11 nodes 1 leaves 7 minterms -00-0-0-0 1 -1000-0-0 1 -101000-1 1 - -:4: ineq: 10 nodes 1 leaves 42 minterms -001000-- 1 -00101--- 1 -1000---- 1 -100100-- 1 -10011--- 1 -101----- 1 -111000-- 1 -11101--- 1 - -10------ 1 --01----- 1 -1-1----- 1 --0-0---- 1 -1--0---- 1 --0--10-- 1 ---1010-- 1 -1---10-- 1 - -:4: ess: 1 nodes 1 leaves 128 minterms --------- 1 - -:5: shortP: 7 nodes 1 leaves 2 minterms -000000-- 1 - -:5b: largest: 4 nodes 1 leaves 16 minterms -01-1---- 1 - -The value of M along the chosen shortest path is 1 -:6: shortP: 5 nodes 1 leaves 8 minterms -0000---- 1 - -Support of f: : 8 nodes 1 leaves 2 minterms -111111-1 1 - -Size of the support of f: 7 -Size of the support of f: 7 -Support of f and g: : 8 nodes 1 leaves 2 minterms -111111-1 1 - -Size of the support of f and g: 7 -Size of the support of f and g: 7 -Support common to f and g: : 5 nodes 1 leaves 16 minterms --1-1-1-1 1 - -Support private to f: : 4 nodes 1 leaves 32 minterms -1-1-1--- 1 - -Support private to g: : 1 nodes 1 leaves 256 minterms --------- 1 - -Average distance: 4138.57 -Number of variables = 8 Number of slots = 2304 -Number of keys = 999 Number of min dead = 9216 -walsh1: 16 nodes 2 leaves 256 minterms --0--0--0--0- 1 --0--0--0--10 1 --0--0--0--11 -1 --0--0--10-0- 1 --0--0--10-10 1 --0--0--10-11 -1 --0--0--11-0- -1 --0--0--11-10 -1 --0--0--11-11 1 --0--10-0--0- 1 --0--10-0--10 1 --0--10-0--11 -1 --0--10-10-0- 1 --0--10-10-10 1 --0--10-10-11 -1 --0--10-11-0- -1 --0--10-11-10 -1 --0--10-11-11 1 --0--11-0--0- -1 --0--11-0--10 -1 --0--11-0--11 1 --0--11-10-0- -1 --0--11-10-10 -1 --0--11-10-11 1 --0--11-11-0- 1 --0--11-11-10 1 --0--11-11-11 -1 --10-0--0--0- 1 --10-0--0--10 1 --10-0--0--11 -1 --10-0--10-0- 1 --10-0--10-10 1 --10-0--10-11 -1 --10-0--11-0- -1 --10-0--11-10 -1 --10-0--11-11 1 --10-10-0--0- 1 --10-10-0--10 1 --10-10-0--11 -1 --10-10-10-0- 1 --10-10-10-10 1 --10-10-10-11 -1 --10-10-11-0- -1 --10-10-11-10 -1 --10-10-11-11 1 --10-11-0--0- -1 --10-11-0--10 -1 --10-11-0--11 1 --10-11-10-0- -1 --10-11-10-10 -1 --10-11-10-11 1 --10-11-11-0- 1 --10-11-11-10 1 --10-11-11-11 -1 --11-0--0--0- -1 --11-0--0--10 -1 --11-0--0--11 1 --11-0--10-0- -1 --11-0--10-10 -1 --11-0--10-11 1 --11-0--11-0- 1 --11-0--11-10 1 --11-0--11-11 -1 --11-10-0--0- -1 --11-10-0--10 -1 --11-10-0--11 1 --11-10-10-0- -1 --11-10-10-10 -1 --11-10-10-11 1 --11-10-11-0- 1 --11-10-11-10 1 --11-10-11-11 -1 --11-11-0--0- 1 --11-11-0--10 1 --11-11-0--11 -1 --11-11-10-0- 1 --11-11-10-10 1 --11-11-10-11 -1 --11-11-11-0- -1 --11-11-11-10 -1 --11-11-11-11 1 - -wtw: 14 nodes 2 leaves 16 minterms -0-00-00-00-0 16 -0-00-00-01-1 16 -0-00-01-10-0 16 -0-00-01-11-1 16 -0-01-10-00-0 16 -0-01-10-01-1 16 -0-01-11-10-0 16 -0-01-11-11-1 16 -1-10-00-00-0 16 -1-10-00-01-1 16 -1-10-01-10-0 16 -1-10-01-11-1 16 -1-11-10-00-0 16 -1-11-10-01-1 16 -1-11-11-10-0 16 -1-11-11-11-1 16 - -Average length of non-empty lists = 1 -**** CUDD modifiable parameters **** -Hard limit for cache size: 7645866 -Cache hit threshold for resizing: 30% -Garbage collection enabled: yes -Limit for fast unique table growth: 4587520 -Maximum number of variables sifted per reordering: 1000 -Maximum number of variable swaps per reordering: 2000000 -Maximum growth while sifting a variable: 1.2 -Dynamic reordering of BDDs enabled: no -Default BDD reordering method: 4 -Dynamic reordering of ZDDs enabled: no -Default ZDD reordering method: 4 -Realignment of ZDDs to BDDs enabled: no -Realignment of BDDs to ZDDs enabled: no -Dead nodes counted in triggering reordering: no -Group checking criterion: 7 -Recombination threshold: 0 -Symmetry violation threshold: 0 -Arc violation threshold: 0 -GA population size: 0 -Number of crossovers for GA: 0 -Next reordering threshold: 4004 -**** CUDD non-modifiable parameters **** -Memory in use: 4274508 -Peak number of nodes: 2044 -Peak number of live nodes: 119 -Number of BDD variables: 9 -Number of ZDD variables: 0 -Number of cache entries: 2048 -Number of cache look-ups: 2864 -Number of cache hits: 729 -Number of cache insertions: 2301 -Number of cache collisions: 947 -Number of cache deletions: 1351 -Cache used slots = 66.11% (expected 67.49%) -Soft limit for cache size: 13312 -Number of buckets in unique table: 2560 -Used buckets in unique table: 0.51% (expected 0.51%) -Number of BDD and ADD nodes: 13 -Number of ZDD nodes: 0 -Number of dead BDD and ADD nodes: 0 -Number of dead ZDD nodes: 0 -Total number of nodes allocated: 1095 -Total number of nodes reclaimed: 967 -Garbage collections so far: 1 -Time for garbage collection: 0.00 sec -Reorderings so far: 0 -Time for reordering: 0.00 sec -total time = 0.00 sec -Runtime Statistics ------------------- -Machine name: jobim.colorado.edu -User time 0.0 seconds -System time 0.0 seconds - -Average resident text size = 0K -Average resident data+stack size = 0K -Maximum resident size = 0K - -Virtual text size = 131653K -Virtual data size = 152K - data size initialized = 18K - data size uninitialized = 1K - data size sbrk = 133K -Virtual memory limit = 358400K (4194304K) - -Major page faults = 0 -Minor page faults = 1330 -Swaps = 0 -Input blocks = 0 -Output blocks = 16 -Context switch (voluntary) = 0 -Context switch (involuntary) = 1 diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/Makefile b/resources/3rdparty/cudd-2.5.0/src/dddmp/Makefile deleted file mode 100644 index d84881a16..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/Makefile +++ /dev/null @@ -1,243 +0,0 @@ -#----------------------------------------------------------------------------# -# Makefile for the dddmp distribution kit # -# dddmp: Decision Diagram DuMP # -# (storage and retrieval of BDDs, ADDs and CNF formulas) # -# Revision: Version 2.0.2, February 01, 2004 # -#----------------------------------------------------------------------------# - -# Commands Available: -# make -# it makes the library libdddmp.a -# make testdddmp -# it makes the testdddmp program, which allows to test the dddmp -# package -# make clean -# it cleans dddmp -# make distclean -# it cleans dddmp (as clean) with libraries and executable -# files - -#----------------------------------------------------------------------------# -# Configuration Section # -# uncomment the desired options/sections # -#----------------------------------------------------------------------------# - -#--------------------# -# Define Directories # -#--------------------# - -# Cudd directory -WHERE = .. -#WHERE = ../cudd-2.4.0 - -# Include directory (Cudd include files) -INCLUDE = $(WHERE)/include - -#------------------------# -# Define C Compiler Used # -#------------------------# - -CC = gcc -#CC = g++ -#CC = cc -#CC = icc -#CC = ecc -#CC = /usr/ucb/cc -#CC = c89 - -.SUFFIXES: .o .c .u - -#---------------# -# Define ranlib # -#---------------# - -# For machines with ranlib and you think it is needed -RANLIB = ranlib -# For machines which either do not have ranlib or can do without it -#RANLIB = : - -#----------------------------------# -# Define Machine Independent Flags # -#----------------------------------# - -# Settings for cc -#ICFLAGS = -#ICFLAGS = -g -#ICFLAGS = -O -# Settings for optimized code with gcc -#ICFLAGS = -g -Wall -#ICFLAGS = -g -O3 -Wall -ICFLAGS = -g -O6 -Wall - -#--------------------------------# -# Define Machine Dependent Flags # -#--------------------------------# - -# When no special flags are needed -#XCFLAGS = -DHAVE_IEEE_754 -DBSD -# Linux with Gcc 2.8.1 or higher on i686. -#XCFLAGS = -mcpu=pentiumpro -malign-double -DHAVE_IEEE_754 -DBSD -# Gcc 3.3.2 or higher on i686. -XCFLAGS = -mcpu=pentium4 -malign-double -DHAVE_IEEE_754 -DBSD -# For Solaris, BSD should not be replaced by UNIX100. -#XCFLAGS = -DHAVE_IEEE_754 -DUNIX100 -DEPD_BIG_ENDIAN -# New native compiler for the Alphas; 64-bit pointers. -#XCFLAGS = -g3 -O4 -std -DBSD -DHAVE_IEEE_754 -ieee_with_no_inexact -tune host -DSIZEOF_VOID_P=8 -DSIZEOF_LONG=8 -# New native compiler for the Alphas; 32-bit pointers. -#XCFLAGS = -g3 -O4 -std -DBSD -DHAVE_IEEE_754 -ieee_with_no_inexact -tune host -xtaso -DSIZEOF_LONG=8 -# Windows95/98/NT/XP with Cygwin tools -#XCFLAGS = -mcpu=pentiumpro -malign-double -DHAVE_IEEE_754 -DHAVE_GETRLIMIT=0 -DRLIMIT_DATA_DEFAULT=67108864 - -#---------------------------------------------# -# Define Level of Self-Checking and Verbosity # -#---------------------------------------------# - -# ... for the CUDD package -#DDDEBUG = -DDD_DEBUG -DDD_VERBOSE -DDD_STATS -DDD_CACHE_PROFILE -DDD_UNIQUE_PROFILE -DDD_COUNT -DDDEBUG = - -# ... for the MTR package -#MTRDEBUG = -DMTR_DEBUG -MTRDEBUG = - -# ... for the DDDMP package -#DDDMPDEBUG = -DDDDMP_DEBUG -DDDMPDEBUG = - -#-----------------------# -# Define Loader Options # -#-----------------------# - -LDFLAGS = -# This may produce faster code on the DECstations. -#LDFLAGS = -jmpopt -Olimit 1000 -# This may be necessary under some old versions of Linux. -#LDFLAGS = -static -# This normally makes the program faster on the DEC Alphas. -#LDFLAGS = -non_shared -om -# This is for 32-bit pointers on the DEC Alphas. -#LDFLAGS = -non_shared -om -taso -#LDFLAGS = -non_shared -taso - -#-------------# -# Define PURE # -#-------------# - -PURE = -# ... as purify to link with purify. -#PURE = purify -# ... as quantify to link with quantify. -#PURE = quantify - -#------------# -# Define EXE # -#------------# - -EXE = -# ... as .exe for MS-DOS and derivatives. -#EXE = .exe - -#----------------------------------------------------------------------------# -# Files for the Package # -#----------------------------------------------------------------------------# - -P = dddmp -PSRC = dddmpStoreBdd.c dddmpStoreAdd.c dddmpStoreCnf.c \ - dddmpLoad.c dddmpLoadCnf.c \ - dddmpNodeBdd.c dddmpNodeAdd.c dddmpNodeCnf.c \ - dddmpStoreMisc.c dddmpUtil.c dddmpBinary.c dddmpConvert.c \ - dddmpDbg.c -PHDR = dddmp.h dddmpInt.h $(INCLUDE)/cudd.h $(INCLUDE)/cuddInt.h -POBJ = $(PSRC:.c=.o) -PUBJ = $(PSRC:.c=.u) -TARGET = test$(P)$(EXE) -TARGETu = test$(P)-u - -# files for the test program -SRC = test$(P).c -OBJ = $(SRC:.c=.o) -UBJ = $(SRC:.c=.u) - -#----------------------------------------------------------------------------# -# Rules to compile and build libraries and executables # -#----------------------------------------------------------------------------# - -#MFLAG = -MFLAG = -DMNEMOSYNE -MNEMLIB = ../mnemosyne/libmnem.a - -# This is to create the lint library -LINTFLAGS = -u -n -LINTSWITCH = -o - -LIBS = ./libdddmp.a $(WHERE)/cudd/libcudd.a $(WHERE)/mtr/libmtr.a \ - $(WHERE)/st/libst.a $(WHERE)/util/libutil.a $(WHERE)/epd/libepd.a - -MNEMLIB = - -BLIBS = -kL. -kldddmp -kL$(WHERE)/cudd -klcudd -kL$(WHERE)/mtr -klmtr \ - -kL$(WHERE)/st -klst -kL$(WHERE)/util -klutil - -LINTLIBS = ./llib-ldddmp.ln $(WHERE)/cudd/llib-lcudd.ln \ - $(WHERE)/mtr/llib-lmtr.ln $(WHERE)/st/llib-lst.ln \ - $(WHERE)/util/llib-lutil.ln - -lib$(P).a: $(POBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.o: $(PHDR) - $(CC) -c $< -I$(INCLUDE) $(ICFLAGS) $(XCFLAGS) $(DDDEBUG) $(MTRDEBUG) $(DDDMPDEBUG) $(LDFLAGS) - -optimize_dec: lib$(P).b - -lib$(P).b: $(PUBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.u: $(PHDR) - cc -c $< -I$(INCLUDE) $(CFLAGS) - -# if the header files change, recompile -$(POBJ): $(PHDR) -$(PUBJ): $(PHDR) -$(OBJ): $(PHDR) -$(UBJ): $(PHDR) - -$(TARGET): $(SRC) $(OBJ) $(PHDR) $(LIBS) $(MNEMLIB) - $(PURE) $(CC) $(ICFLAGS) $(XCFLAGS) $(DDDEBUG) $(MTRDEBUG) $(DDDMPDEBUG) $(LDFLAGS) -o $@ $(OBJ) $(LIBS) $(MNEMLIB) -lm - -# optimize (DECstations and Alphas only: uses u-code) -$(TARGETu): $(SRC) $(UBJ) $(PHDR) $(LIBS:.a=.b) - cc -O3 -Olimit 1000 $(XCFLAGS) $(LDFLAGS) -o $@ $(UBJ) $(BLIBS) -lm - -lint: llib-l$(P).ln - -llib-l$(P).ln: $(PSRC) $(PHDR) - lint $(LINTFLAGS) $(LINTSWITCH)$(P) -I$(INCLUDE) $(PSRC) - -lintpgm: lint - lint $(LINTFLAGS) -I$(INCLUDE) $(SRC) $(LINTLIBS) - -tags: $(PSRC) $(PHDR) - ctags $(PSRC) $(PHDR) - -all: lib$(P).a lib$(P).b llib-l$(P).ln tags - -programs: $(TARGET) $(TARGETu) lintpgm - -#----------------------------------------------------------------------------# -# Clean the Package # -#----------------------------------------------------------------------------# - -clean: - rm -f *.o *.u mon.out gmon.out *.pixie *.Addrs *.Counts mnem.* \ - .pure core *.warnings - -distclean: clean - rm -f $(TARGET) $(TARGETu) lib*.a lib$(P).b llib-l$(P).ln \ - *.bak *~ tags .gdb_history *.qv *.qx - - - - diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpDdNodeBdd.c b/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpDdNodeBdd.c deleted file mode 100644 index 443ef5dbf..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpDdNodeBdd.c +++ /dev/null @@ -1,455 +0,0 @@ -/**CFile********************************************************************** - - FileName [dddmpDdNodeBdd.c] - - PackageName [dddmp] - - Synopsis [Functions to handle BDD node infos and numbering] - - Description [Functions to handle BDD node infos and numbering. - ] - - Author [Gianpiero Cabodi and Stefano Quer] - - Copyright [ - Copyright (c) 2004 by Politecnico di Torino. - All Rights Reserved. This software is for educational purposes only. - Permission is given to academic institutions to use, copy, and modify - this software and its documentation provided that this introductory - message is not removed, that this software and its documentation is - used for the institutions' internal research and educational purposes, - and that no monies are exchanged. No guarantee is expressed or implied - by the distribution of this code. - Send bug-reports and/or questions to: - {gianpiero.cabodi,stefano.quer}@polito.it. - ] - -******************************************************************************/ - -#include "dddmpInt.h" - -/*---------------------------------------------------------------------------*/ -/* Stucture declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Type declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Variable declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Macro declarations */ -/*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ - -/*---------------------------------------------------------------------------*/ -/* Static function prototypes */ -/*---------------------------------------------------------------------------*/ - -static int NumberNodeRecur(DdNode *f, int id); -static void RemoveFromUniqueRecur(DdManager *ddMgr, DdNode *f); -static void RestoreInUniqueRecur(DdManager *ddMgr, DdNode *f); - -/**AutomaticEnd***************************************************************/ - -/*---------------------------------------------------------------------------*/ -/* Definition of exported functions */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Definition of internal functions */ -/*---------------------------------------------------------------------------*/ - -/**Function******************************************************************** - - Synopsis [Removes nodes from unique table and number them] - - Description [Node numbering is required to convert pointers to integers. - Since nodes are removed from unique table, no new nodes should - be generated before re-inserting nodes in the unique table - (DddmpUnnumberDdNodes()). - ] - - SideEffects [Nodes are temporarily removed from unique table] - - SeeAlso [RemoveFromUniqueRecur(), NumberNodeRecur(), - DddmpUnnumberDdNodes()] - -******************************************************************************/ - -int -DddmpNumberDdNodes ( - DdManager *ddMgr /* IN: DD Manager */, - DdNode **f /* IN: array of BDDs */, - int n /* IN: number of BDD roots in the array of BDDs */ - ) -{ - int id=0, i; - - for (i=0; i<n; i++) { - RemoveFromUniqueRecur (ddMgr, f[i]); - } - - for (i=0; i<n; i++) { - id = NumberNodeRecur (f[i], id); - } - - return (id); -} - - -/**Function******************************************************************** - - Synopsis [Restores nodes in unique table, loosing numbering] - - Description [Node indexes are no more needed. Nodes are re-linked in the - unique table. - ] - - SideEffects [None] - - SeeAlso [DddmpNumberDdNode()] - -******************************************************************************/ - -void -DddmpUnnumberDdNodes( - DdManager *ddMgr /* IN: DD Manager */, - DdNode **f /* IN: array of BDDs */, - int n /* IN: number of BDD roots in the array of BDDs */ - ) -{ - int i; - - for (i=0; i<n; i++) { - RestoreInUniqueRecur (ddMgr, f[i]); - } - - return; -} - -/**Function******************************************************************** - - Synopsis [Write index to node] - - Description [The index of the node is written in the "next" field of - a DdNode struct. LSB is not used (set to 0). It is used as - "visited" flag in DD traversals. - ] - - SideEffects [None] - - SeeAlso [DddmpReadNodeIndex(), DddmpSetVisited (), DddmpVisited ()] - -******************************************************************************/ - -void -DddmpWriteNodeIndex ( - DdNode *f /* IN: BDD node */, - int id /* IN: index to be written */ - ) -{ -#if 0 - if (1 || !Cudd_IsConstant (f)) { -#else - if (!Cudd_IsConstant (f)) { -#endif - f->next = (struct DdNode *)((ptruint)((id)<<1)); - } - - return; -} - -/**Function******************************************************************** - - Synopsis [Reads the index of a node] - - Description [Reads the index of a node. LSB is skipped (used as visited - flag). - ] - - SideEffects [None] - - SeeAlso [DddmpWriteNodeIndex(), DddmpSetVisited (), DddmpVisited ()] - -******************************************************************************/ - -int -DddmpReadNodeIndex ( - DdNode *f /* IN: BDD node */ - ) -{ - -#if 0 - if (1 || !Cudd_IsConstant (f)) { -#else - if (!Cudd_IsConstant (f)) { -#endif - return ((int)(((ptruint)(f->next))>>1)); - } else { - return (1); - } -} - -/**Function******************************************************************** - - Synopsis [Returns true if node is visited] - - Description [Returns true if node is visited] - - SideEffects [None] - - SeeAlso [DddmpSetVisited (), DddmpClearVisited ()] - -******************************************************************************/ - -int -DddmpVisited ( - DdNode *f /* IN: BDD node to be tested */ - ) -{ - f = Cudd_Regular(f); - return ((int)((ptruint)(f->next)) & (01)); -} - -/**Function******************************************************************** - - Synopsis [Marks a node as visited] - - Description [Marks a node as visited] - - SideEffects [None] - - SeeAlso [DddmpVisited (), DddmpClearVisited ()] - -******************************************************************************/ - -void -DddmpSetVisited ( - DdNode *f /* IN: BDD node to be marked (as visited) */ - ) -{ - f = Cudd_Regular(f); - - f->next = (DdNode *)(ptruint)((int)((ptruint)(f->next))|01); - - return; -} - -/**Function******************************************************************** - - Synopsis [Marks a node as not visited] - - Description [Marks a node as not visited] - - SideEffects [None] - - SeeAlso [DddmpVisited (), DddmpSetVisited ()] - -******************************************************************************/ - -void -DddmpClearVisited ( - DdNode *f /* IN: BDD node to be marked (as not visited) */ - ) -{ - f = Cudd_Regular (f); - - f->next = (DdNode *)(ptruint)((int)((ptruint)(f->next)) & (~01)); - - return; -} - -/*---------------------------------------------------------------------------*/ -/* Definition of static functions */ -/*---------------------------------------------------------------------------*/ - -/**Function******************************************************************** - - Synopsis [Number nodes recursively in post-order] - - Description [Number nodes recursively in post-order. - The "visited" flag is used with inverse polarity, because all nodes - were set "visited" when removing them from unique. - ] - - SideEffects ["visited" flags are reset.] - - SeeAlso [] - -******************************************************************************/ - -static int -NumberNodeRecur( - DdNode *f /* IN: root of the BDD to be numbered */, - int id /* IN/OUT: index to be assigned to the node */ - ) -{ - f = Cudd_Regular(f); - - if (!DddmpVisited (f)) { - return (id); - } - - if (!cuddIsConstant (f)) { - id = NumberNodeRecur (cuddT (f), id); - id = NumberNodeRecur (cuddE (f), id); - } - - DddmpWriteNodeIndex (f, ++id); - DddmpClearVisited (f); - - return (id); -} - -/**Function******************************************************************** - - Synopsis [Removes a node from unique table] - - Description [Removes a node from the unique table by locating the proper - subtable and unlinking the node from it. It recurs on the - children of the node. - ] - - SideEffects [Nodes are left with the "visited" flag true.] - - SeeAlso [RestoreInUniqueRecur()] - -******************************************************************************/ - -static void -RemoveFromUniqueRecur ( - DdManager *ddMgr /* IN: DD Manager */, - DdNode *f /* IN: root of the BDD to be extracted */ - ) -{ - DdNode *node, *last, *next; - DdNode *sentinel = &(ddMgr->sentinel); - DdNodePtr *nodelist; - DdSubtable *subtable; - int pos, level; - - f = Cudd_Regular (f); - - if (DddmpVisited (f)) { - return; - } - - if (!cuddIsConstant (f)) { - - RemoveFromUniqueRecur (ddMgr, cuddT (f)); - RemoveFromUniqueRecur (ddMgr, cuddE (f)); - - level = ddMgr->perm[f->index]; - subtable = &(ddMgr->subtables[level]); - - nodelist = subtable->nodelist; - - pos = ddHash (cuddT (f), cuddE (f), subtable->shift); - node = nodelist[pos]; - last = NULL; - while (node != sentinel) { - next = node->next; - if (node == f) { - if (last != NULL) - last->next = next; - else - nodelist[pos] = next; - break; - } else { - last = node; - node = next; - } - } - - f->next = NULL; - - } - - DddmpSetVisited (f); - - return; -} - -/**Function******************************************************************** - - Synopsis [Restores a node in unique table] - - Description [Restores a node in unique table (recursively)] - - SideEffects [Nodes are not restored in the same order as before removal] - - SeeAlso [RemoveFromUnique()] - -******************************************************************************/ - -static void -RestoreInUniqueRecur ( - DdManager *ddMgr /* IN: DD Manager */, - DdNode *f /* IN: root of the BDD to be restored */ - ) -{ - DdNodePtr *nodelist; - DdNode *T, *E, *looking; - DdNodePtr *previousP; - DdSubtable *subtable; - int pos, level; -#ifdef DDDMP_DEBUG - DdNode *node; - DdNode *sentinel = &(ddMgr->sentinel); -#endif - - f = Cudd_Regular(f); - - if (!Cudd_IsComplement (f->next)) { - return; - } - - if (cuddIsConstant (f)) { - DddmpClearVisited (f); - /*f->next = NULL;*/ - return; - } - - RestoreInUniqueRecur (ddMgr, cuddT (f)); - RestoreInUniqueRecur (ddMgr, cuddE (f)); - - level = ddMgr->perm[f->index]; - subtable = &(ddMgr->subtables[level]); - - nodelist = subtable->nodelist; - - pos = ddHash (cuddT (f), cuddE (f), subtable->shift); - -#ifdef DDDMP_DEBUG - /* verify uniqueness to avoid duplicate nodes in unique table */ - for (node=nodelist[pos]; node != sentinel; node=node->next) - assert(node!=f); -#endif - - T = cuddT (f); - E = cuddE (f); - previousP = &(nodelist[pos]); - looking = *previousP; - - while (T < cuddT (looking)) { - previousP = &(looking->next); - looking = *previousP; - } - - while (T == cuddT (looking) && E < cuddE (looking)) { - previousP = &(looking->next); - looking = *previousP; - } - - f->next = *previousP; - *previousP = f; - - return; -} - - diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpDdNodeCnf.c b/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpDdNodeCnf.c deleted file mode 100644 index 0b7395494..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpDdNodeCnf.c +++ /dev/null @@ -1,944 +0,0 @@ -/**CFile********************************************************************** - - FileName [dddmpDdNodeCnf.c] - - PackageName [dddmp] - - Synopsis [Functions to handle BDD node infos and numbering - while storing a CNF formula from a BDD or an array of BDDs] - - Description [Functions to handle BDD node infos and numbering - while storing a CNF formula from a BDD or an array of BDDs. - ] - - Author [Gianpiero Cabodi and Stefano Quer] - - Copyright [ - Copyright (c) 2004 by Politecnico di Torino. - All Rights Reserved. This software is for educational purposes only. - Permission is given to academic institutions to use, copy, and modify - this software and its documentation provided that this introductory - message is not removed, that this software and its documentation is - used for the institutions' internal research and educational purposes, - and that no monies are exchanged. No guarantee is expressed or implied - by the distribution of this code. - Send bug-reports and/or questions to: - {gianpiero.cabodi,stefano.quer}@polito.it. - ] - -******************************************************************************/ - -#include "dddmpInt.h" - -/*---------------------------------------------------------------------------*/ -/* Stucture declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Type declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Variable declarations */ -/*---------------------------------------------------------------------------*/ - -#define DDDMP_DEBUG_CNF 0 - -/*---------------------------------------------------------------------------*/ -/* Macro declarations */ -/*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ - -/*---------------------------------------------------------------------------*/ -/* Static function prototypes */ -/*---------------------------------------------------------------------------*/ - -int DddmpWriteNodeIndexCnf(DdNode *f, int *cnfIds, int id); -int DddmpReadNodeIndexCnf(DdNode *f); -static int DddmpClearVisitedCnfRecur(DdNode *f); -int DddmpVisitedCnf(DdNode *f); -void DddmpSetVisitedCnf(DdNode *f); -static void DddmpClearVisitedCnf(DdNode *f); -static int NumberNodeRecurCnf(DdNode *f, int *cnfIds, int id); -static void DddmpDdNodesCheckIncomingAndScanPath(DdNode *f, int pathLengthCurrent, int edgeInTh, int pathLengthTh); -static int DddmpDdNodesNumberEdgesRecur(DdNode *f, int *cnfIds, int id); -static int DddmpDdNodesResetCountRecur(DdNode *f); -static int DddmpDdNodesCountEdgesRecur(DdNode *f); -static void RemoveFromUniqueRecurCnf(DdManager *ddMgr, DdNode *f); -static void RestoreInUniqueRecurCnf(DdManager *ddMgr, DdNode *f); -static int DddmpPrintBddAndNextRecur(DdManager *ddMgr, DdNode *f); - -/**AutomaticEnd***************************************************************/ - -/*---------------------------------------------------------------------------*/ -/* Definition of exported functions */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Definition of internal functions */ -/*---------------------------------------------------------------------------*/ - -/**Function******************************************************************** - - Synopsis [Removes nodes from unique table and numbers them] - - Description [Node numbering is required to convert pointers to integers. - Since nodes are removed from unique table, no new nodes should - be generated before re-inserting nodes in the unique table - (DddmpUnnumberDdNodesCnf()). - ] - - SideEffects [Nodes are temporarily removed from unique table] - - SeeAlso [RemoveFromUniqueRecurCnf(), NumberNodeRecurCnf(), - DddmpUnnumberDdNodesCnf()] - -******************************************************************************/ - -int -DddmpNumberDdNodesCnf ( - DdManager *ddMgr /* IN: DD Manager */, - DdNode **f /* IN: array of BDDs */, - int rootN /* IN: number of BDD roots in the array of BDDs */, - int *cnfIds /* OUT: CNF identifiers for variables */, - int id /* OUT: number of Temporary Variables Introduced */ - ) -{ - int i; - - for (i=0; i<rootN; i++) { - RemoveFromUniqueRecurCnf (ddMgr, f[i]); - } - - for (i=0; i<rootN; i++) { - id = NumberNodeRecurCnf (f[i], cnfIds, id); - } - - return (id); -} - -/**Function******************************************************************** - - Synopsis [Removes nodes from unique table and numbers each node according - to the number of its incoming BDD edges. - ] - - Description [Removes nodes from unique table and numbers each node according - to the number of its incoming BDD edges. - ] - - SideEffects [Nodes are temporarily removed from unique table] - - SeeAlso [RemoveFromUniqueRecurCnf()] - -******************************************************************************/ - -int -DddmpDdNodesCountEdgesAndNumber ( - DdManager *ddMgr /* IN: DD Manager */, - DdNode **f /* IN: Array of BDDs */, - int rootN /* IN: Number of BDD roots in the array of BDDs */, - int edgeInTh /* IN: Max # In-Edges, after a Insert Cut Point */, - int pathLengthTh /* IN: Max Path Length (after, Insert a Cut Point) */, - int *cnfIds /* OUT: CNF identifiers for variables */, - int id /* OUT: Number of Temporary Variables Introduced */ - ) -{ - int retValue, i; - - /*-------------------------- Remove From Unique ---------------------------*/ - - for (i=0; i<rootN; i++) { - RemoveFromUniqueRecurCnf (ddMgr, f[i]); - } - - /*-------------------- Reset Counter and Reset Visited --------------------*/ - - for (i=0; i<rootN; i++) { - retValue = DddmpDdNodesResetCountRecur (f[i]); - } - - /* Here we must have: - * cnfIndex = 0 - * visitedFlag = 0 - * FOR ALL nodes - */ - -#if DDDMP_DEBUG_CNF - fprintf (stdout, "###---> BDDs After Count Reset:\n"); - DddmpPrintBddAndNext (ddMgr, f, rootN); -#endif - - /*----------------------- Count Incoming Edges ----------------------------*/ - - for (i=0; i<rootN; i++) { - retValue = DddmpDdNodesCountEdgesRecur (f[i]); - } - - /* Here we must have: - * cnfIndex = incoming edge count - * visitedFlag = 0 (AGAIN ... remains untouched) - * FOR ALL nodes - */ - -#if DDDMP_DEBUG_CNF - fprintf (stdout, "###---> BDDs After Count Recur:\n"); - DddmpPrintBddAndNext (ddMgr, f, rootN); -#endif - - /*------------------------- Count Path Length ----------------------------*/ - - for (i=0; i<rootN; i++) { - DddmpDdNodesCheckIncomingAndScanPath (f[i], 0, edgeInTh, - pathLengthTh); - } - - /* Here we must have: - * cnfIndex = 1 if we want to insert there a cut point - * 0 if we do NOT want to insert there a cut point - * visitedFlag = 1 - * FOR ALL nodes - */ - -#if DDDMP_DEBUG_CNF - fprintf (stdout, "###---> BDDs After Check Incoming And Scan Path:\n"); - DddmpPrintBddAndNext (ddMgr, f, rootN); -#endif - - /*-------------------- Number Nodes and Set Visited -----------------------*/ - - for (i=0; i<rootN; i++) { - id = DddmpDdNodesNumberEdgesRecur (f[i], cnfIds, id); - } - - /* Here we must have: - * cnfIndex = CNF auxiliary variable enumeration - * visitedFlag = 0 - * FOR ALL nodes - */ - -#if DDDMP_DEBUG_CNF - fprintf (stdout, "###---> BDDs After Count Edges Recur:\n"); - DddmpPrintBddAndNext (ddMgr, f, rootN); -#endif - - /*---------------------------- Clear Visited ------------------------------*/ - -#if DDDMP_DEBUG_CNF - for (i=0; i<rootN; i++) { - retValue = DddmpClearVisitedCnfRecur (f[i]); - } - -#if DDDMP_DEBUG_CNF - fprintf (stdout, "###---> BDDs After All Numbering Process:\n"); - DddmpPrintBddAndNext (ddMgr, f, rootN); -#endif -#endif - - return (id); -} - -/**Function******************************************************************** - - Synopsis [Restores nodes in unique table, loosing numbering] - - Description [Node indexes are no more needed. Nodes are re-linked in the - unique table. - ] - - SideEffects [None] - - SeeAlso [DddmpNumberDdNode()] - -******************************************************************************/ - -void -DddmpUnnumberDdNodesCnf( - DdManager *ddMgr /* IN: DD Manager */, - DdNode **f /* IN: array of BDDs */, - int rootN /* IN: number of BDD roots in the array of BDDs */ - ) -{ - int i; - - for (i=0; i<rootN; i++) { - RestoreInUniqueRecurCnf (ddMgr, f[i]); - } - - return; -} - -/**Function******************************************************************** - - Synopsis [Prints debug information] - - Description [Prints debug information for an array of BDDs on the screen] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ - -int -DddmpPrintBddAndNext ( - DdManager *ddMgr /* IN: DD Manager */, - DdNode **f /* IN: Array of BDDs to be displayed */, - int rootN /* IN: Number of BDD roots in the array of BDDs */ - ) -{ - int i; - - for (i=0; i<rootN; i++) { - fprintf (stdout, "---> Bdd %d:\n", i); - fflush (stdout); - DddmpPrintBddAndNextRecur (ddMgr, f[i]); - } - - return (DDDMP_SUCCESS); -} - -/**Function******************************************************************** - - Synopsis [Write index to node] - - Description [The index of the node is written in the "next" field of - a DdNode struct. LSB is not used (set to 0). It is used as - "visited" flag in DD traversals. - ] - - SideEffects [None] - - SeeAlso [DddmpReadNodeIndexCnf(), DddmpSetVisitedCnf (), - DddmpVisitedCnf () - ] - -******************************************************************************/ - -int -DddmpWriteNodeIndexCnfBis ( - DdNode *f /* IN: BDD node */, - int id /* IN: index to be written */ - ) -{ - if (!Cudd_IsConstant (f)) { - f->next = (struct DdNode *)((ptruint)((id)<<1)); - } - - return (DDDMP_SUCCESS); -} - -/*---------------------------------------------------------------------------*/ -/* Definition of static functions */ -/*---------------------------------------------------------------------------*/ - -/**Function******************************************************************** - - Synopsis [Write index to node] - - Description [The index of the node is written in the "next" field of - a DdNode struct. LSB is not used (set to 0). It is used as - "visited" flag in DD traversals. The index corresponds to - the BDD node variable if both the node's children are a - constant node, otherwise a new CNF variable is used. - ] - - SideEffects [None] - - SeeAlso [DddmpReadNodeIndexCnf(), DddmpSetVisitedCnf (), - DddmpVisitedCnf ()] - -*****************************************************************************/ - -int -DddmpWriteNodeIndexCnf ( - DdNode *f /* IN: BDD node */, - int *cnfIds /* IN: possible source for the index to be written */, - int id /* IN: possible source for the index to be written */ - ) -{ - if (!Cudd_IsConstant (f)) { - if (Cudd_IsConstant (cuddT (f)) && Cudd_IsConstant (cuddE (f))) { - /* If Variable SET ID as Variable ID */ - f->next = (struct DdNode *)((ptruint)((cnfIds[f->index])<<1)); - } else { - f->next = (struct DdNode *)((ptruint)((id)<<1)); - id++; - } - } - - return(id); -} - -/**Function******************************************************************** - - Synopsis [Reads the index of a node] - - Description [Reads the index of a node. LSB is skipped (used as visited - flag). - ] - - SideEffects [None] - - SeeAlso [DddmpWriteNodeIndexCnf(), DddmpSetVisitedCnf (), - DddmpVisitedCnf ()] - -******************************************************************************/ - -int -DddmpReadNodeIndexCnf ( - DdNode *f /* IN: BDD node */ - ) -{ - if (!Cudd_IsConstant (f)) { - return ((int)(((ptruint)(f->next))>>1)); - } else { - return (1); - } -} - -/**Function******************************************************************** - - Synopsis [Mark ALL nodes as not visited] - - Description [Mark ALL nodes as not visited (it recurs on the node children)] - - SideEffects [None] - - SeeAlso [DddmpVisitedCnf (), DddmpSetVisitedCnf ()] - -******************************************************************************/ - -static int -DddmpClearVisitedCnfRecur ( - DdNode *f /* IN: root of the BDD to be marked */ - ) -{ - int retValue; - - f = Cudd_Regular(f); - - if (cuddIsConstant (f)) { - return (DDDMP_SUCCESS); - } - - if (!DddmpVisitedCnf (f)) { - return (DDDMP_SUCCESS); - } - - retValue = DddmpClearVisitedCnfRecur (cuddT (f)); - retValue = DddmpClearVisitedCnfRecur (cuddE (f)); - - DddmpClearVisitedCnf (f); - - return (DDDMP_SUCCESS); -} - -/**Function******************************************************************** - - Synopsis [Returns true if node is visited] - - Description [Returns true if node is visited] - - SideEffects [None] - - SeeAlso [DddmpSetVisitedCnf (), DddmpClearVisitedCnf ()] - -******************************************************************************/ - -int -DddmpVisitedCnf ( - DdNode *f /* IN: BDD node to be tested */ - ) -{ - f = Cudd_Regular(f); - - return ((int)((ptruint)(f->next)) & (01)); -} - -/**Function******************************************************************** - - Synopsis [Marks a node as visited] - - Description [Marks a node as visited] - - SideEffects [None] - - SeeAlso [DddmpVisitedCnf (), DddmpClearVisitedCnf ()] - -******************************************************************************/ - -void -DddmpSetVisitedCnf ( - DdNode *f /* IN: BDD node to be marked (as visited) */ - ) -{ - f = Cudd_Regular(f); - - f->next = (DdNode *)(ptruint)((int)((ptruint)(f->next))|01); - - return; -} - -/**Function******************************************************************** - - Synopsis [Marks a node as not visited] - - Description [Marks a node as not visited] - - SideEffects [None] - - SeeAlso [DddmpVisitedCnf (), DddmpSetVisitedCnf ()] - -******************************************************************************/ - -static void -DddmpClearVisitedCnf ( - DdNode *f /* IN: BDD node to be marked (as not visited) */ - ) -{ - f = Cudd_Regular (f); - - f->next = (DdNode *)(ptruint)((int)((ptruint)(f->next)) & (~01)); - - return; -} - -/**Function******************************************************************** - - Synopsis [Number nodes recursively in post-order] - - Description [Number nodes recursively in post-order. - The "visited" flag is used with inverse polarity, because all nodes - were set "visited" when removing them from unique. - ] - - SideEffects ["visited" flags are reset.] - - SeeAlso [] - -******************************************************************************/ - -static int -NumberNodeRecurCnf( - DdNode *f /* IN: root of the BDD to be numbered */, - int *cnfIds /* IN: possible source for numbering */, - int id /* IN/OUT: possible source for numbering */ - ) -{ - f = Cudd_Regular(f); - - if (!DddmpVisitedCnf (f)) { - return (id); - } - - if (!cuddIsConstant (f)) { - id = NumberNodeRecurCnf (cuddT (f), cnfIds, id); - id = NumberNodeRecurCnf (cuddE (f), cnfIds, id); - } - - id = DddmpWriteNodeIndexCnf (f, cnfIds, id); - DddmpClearVisitedCnf (f); - - return (id); -} - -/**Function******************************************************************** - - Synopsis [Number nodes recursively in post-order] - - Description [Number nodes recursively in post-order. - The "visited" flag is used with the right polarity. - The node is assigned to a new CNF variable only if it is a "shared" - node (i.e. the number of its incoming edges is greater than 1). - ] - - SideEffects ["visited" flags are set.] - - SeeAlso [] - -******************************************************************************/ - -static void -DddmpDdNodesCheckIncomingAndScanPath ( - DdNode *f /* IN: BDD node to be numbered */, - int pathLengthCurrent /* IN: Current Path Length */, - int edgeInTh /* IN: Max # In-Edges, after a Insert Cut Point */, - int pathLengthTh /* IN: Max Path Length (after, Insert a Cut Point) */ - ) -{ - int retValue; - - f = Cudd_Regular(f); - - if (DddmpVisitedCnf (f)) { - return; - } - - if (cuddIsConstant (f)) { - return; - } - - pathLengthCurrent++; - retValue = DddmpReadNodeIndexCnf (f); - - if ( ((edgeInTh >= 0) && (retValue > edgeInTh)) || - ((pathLengthTh >= 0) && (pathLengthCurrent > pathLengthTh)) - ) { - DddmpWriteNodeIndexCnfBis (f, 1); - pathLengthCurrent = 0; - } else { - DddmpWriteNodeIndexCnfBis (f, 0); - } - - DddmpDdNodesCheckIncomingAndScanPath (cuddT (f), pathLengthCurrent, - edgeInTh, pathLengthTh); - DddmpDdNodesCheckIncomingAndScanPath (cuddE (f), pathLengthCurrent, - edgeInTh, pathLengthTh); - - DddmpSetVisitedCnf (f); - - return; -} - -/**Function******************************************************************** - - Synopsis [Number nodes recursively in post-order] - - Description [Number nodes recursively in post-order. - The "visited" flag is used with the inverse polarity. - Numbering follows the subsequent strategy: - * if the index = 0 it remains so - * if the index >= 1 it gets enumerated. - This implies that the node is assigned to a new CNF variable only if - it is not a terminal node otherwise it is assigned the index of - the BDD variable. - ] - - SideEffects ["visited" flags are reset.] - - SeeAlso [] - -******************************************************************************/ - -static int -DddmpDdNodesNumberEdgesRecur ( - DdNode *f /* IN: BDD node to be numbered */, - int *cnfIds /* IN: possible source for numbering */, - int id /* IN/OUT: possible source for numbering */ - ) -{ - int retValue; - - f = Cudd_Regular(f); - - if (!DddmpVisitedCnf (f)) { - return (id); - } - - if (cuddIsConstant (f)) { - return (id); - } - - id = DddmpDdNodesNumberEdgesRecur (cuddT (f), cnfIds, id); - id = DddmpDdNodesNumberEdgesRecur (cuddE (f), cnfIds, id); - - retValue = DddmpReadNodeIndexCnf (f); - if (retValue >= 1) { - id = DddmpWriteNodeIndexCnf (f, cnfIds, id); - } else { - DddmpWriteNodeIndexCnfBis (f, 0); - } - - DddmpClearVisitedCnf (f); - - return (id); -} - -/**Function******************************************************************** - - Synopsis [Resets counter and visited flag for ALL nodes of a BDD] - - Description [Resets counter and visited flag for ALL nodes of a BDD (it - recurs on the node children). The index field of the node is - used as counter. - ] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ - -static int -DddmpDdNodesResetCountRecur ( - DdNode *f /* IN: root of the BDD whose counters are reset */ - ) -{ - int retValue; - - f = Cudd_Regular (f); - - if (!DddmpVisitedCnf (f)) { - return (DDDMP_SUCCESS); - } - - if (!cuddIsConstant (f)) { - retValue = DddmpDdNodesResetCountRecur (cuddT (f)); - retValue = DddmpDdNodesResetCountRecur (cuddE (f)); - } - - DddmpWriteNodeIndexCnfBis (f, 0); - DddmpClearVisitedCnf (f); - - return (DDDMP_SUCCESS); -} - -/**Function******************************************************************** - - Synopsis [Counts the number of incoming edges for each node of a BDD] - - Description [Counts (recursively) the number of incoming edges for each - node of a BDD. This number is stored in the index field. - ] - - SideEffects ["visited" flags remain untouched.] - - SeeAlso [] - -******************************************************************************/ - -static int -DddmpDdNodesCountEdgesRecur ( - DdNode *f /* IN: root of the BDD */ - ) -{ - int indexValue, retValue; - - f = Cudd_Regular (f); - - if (cuddIsConstant (f)) { - return (DDDMP_SUCCESS); - } - - if (Cudd_IsConstant (cuddT (f)) && Cudd_IsConstant (cuddE (f))) { - return (DDDMP_SUCCESS); - } - - indexValue = DddmpReadNodeIndexCnf (f); - - /* IF (first time) THEN recur */ - if (indexValue == 0) { - retValue = DddmpDdNodesCountEdgesRecur (cuddT (f)); - retValue = DddmpDdNodesCountEdgesRecur (cuddE (f)); - } - - /* Increment Incoming-Edge Count Flag */ - indexValue++; - DddmpWriteNodeIndexCnfBis (f, indexValue); - - return (DDDMP_SUCCESS); -} - -/**Function******************************************************************** - - Synopsis [Removes a node from unique table] - - Description [Removes a node from the unique table by locating the proper - subtable and unlinking the node from it. It recurs on son nodes. - ] - - SideEffects [Nodes are left with the "visited" flag true.] - - SeeAlso [RestoreInUniqueRecurCnf()] - -******************************************************************************/ - -static void -RemoveFromUniqueRecurCnf ( - DdManager *ddMgr /* IN: DD Manager */, - DdNode *f /* IN: root of the BDD to be extracted */ - ) -{ - DdNode *node, *last, *next; - DdNode *sentinel = &(ddMgr->sentinel); - DdNodePtr *nodelist; - DdSubtable *subtable; - int pos, level; - - f = Cudd_Regular (f); - - if (DddmpVisitedCnf (f)) { - return; - } - - if (!cuddIsConstant (f)) { - - RemoveFromUniqueRecurCnf (ddMgr, cuddT (f)); - RemoveFromUniqueRecurCnf (ddMgr, cuddE (f)); - - level = ddMgr->perm[f->index]; - subtable = &(ddMgr->subtables[level]); - - nodelist = subtable->nodelist; - - pos = ddHash (cuddT (f), cuddE (f), subtable->shift); - node = nodelist[pos]; - last = NULL; - while (node != sentinel) { - next = node->next; - if (node == f) { - if (last != NULL) - last->next = next; - else - nodelist[pos] = next; - break; - } else { - last = node; - node = next; - } - } - - f->next = NULL; - - } - - DddmpSetVisitedCnf (f); - - return; -} - -/**Function******************************************************************** - - Synopsis [Restores a node in unique table] - - Description [Restores a node in unique table (recursive)] - - SideEffects [Nodes are not restored in the same order as before removal] - - SeeAlso [RemoveFromUnique()] - -******************************************************************************/ - -static void -RestoreInUniqueRecurCnf ( - DdManager *ddMgr /* IN: DD Manager */, - DdNode *f /* IN: root of the BDD to be restored */ - ) -{ - DdNodePtr *nodelist; - DdNode *T, *E, *looking; - DdNodePtr *previousP; - DdSubtable *subtable; - int pos, level; -#ifdef DDDMP_DEBUG - DdNode *node; - DdNode *sentinel = &(ddMgr->sentinel); -#endif - - f = Cudd_Regular(f); - - if (!Cudd_IsComplement (f->next)) { - return; - } - - if (cuddIsConstant (f)) { - DddmpClearVisitedCnf (f); - /*f->next = NULL;*/ - return; - } - - RestoreInUniqueRecurCnf (ddMgr, cuddT (f)); - RestoreInUniqueRecurCnf (ddMgr, cuddE (f)); - - level = ddMgr->perm[f->index]; - subtable = &(ddMgr->subtables[level]); - - nodelist = subtable->nodelist; - - pos = ddHash (cuddT (f), cuddE (f), subtable->shift); - -#ifdef DDDMP_DEBUG - /* verify uniqueness to avoid duplicate nodes in unique table */ - for (node=nodelist[pos]; node != sentinel; node=node->next) - assert(node!=f); -#endif - - T = cuddT (f); - E = cuddE (f); - previousP = &(nodelist[pos]); - looking = *previousP; - - while (T < cuddT (looking)) { - previousP = &(looking->next); - looking = *previousP; - } - - while (T == cuddT (looking) && E < cuddE (looking)) { - previousP = &(looking->next); - looking = *previousP; - } - f->next = *previousP; - *previousP = f; - - return; -} - -/**Function******************************************************************** - - Synopsis [Prints debug info] - - Description [Prints debug info for a BDD on the screen. It recurs on - node's children. - ] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ - -static int -DddmpPrintBddAndNextRecur ( - DdManager *ddMgr /* IN: DD Manager */, - DdNode *f /* IN: root of the BDD to be displayed */ - ) -{ - int retValue; - DdNode *fPtr, *tPtr, *ePtr; - - fPtr = Cudd_Regular (f); - - if (Cudd_IsComplement (f)) { - fprintf (stdout, "sign=- ptr=%ld ", ((long int) fPtr)); - } else { - fprintf (stdout, "sign=+ ptr=%ld ", ((long int) fPtr)); - } - - if (cuddIsConstant (fPtr)) { - fprintf (stdout, "one\n"); - fflush (stdout); - return (DDDMP_SUCCESS); - } - - fprintf (stdout, - "thenPtr=%ld elsePtr=%ld BddId=%d CnfId=%d Visited=%d\n", - ((long int) cuddT (fPtr)), ((long int) cuddE (fPtr)), - fPtr->index, DddmpReadNodeIndexCnf (fPtr), - DddmpVisitedCnf (fPtr)); - - tPtr = cuddT (fPtr); - ePtr = cuddE (fPtr); - if (Cudd_IsComplement (f)) { - tPtr = Cudd_Not (tPtr); - ePtr = Cudd_Not (ePtr); - } - - retValue = DddmpPrintBddAndNextRecur (ddMgr, tPtr); - retValue = DddmpPrintBddAndNextRecur (ddMgr, ePtr); - - return (DDDMP_SUCCESS); -} - - diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/runAllTest.out b/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/runAllTest.out deleted file mode 100644 index 321532e3c..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/runAllTest.out +++ /dev/null @@ -1,269 +0,0 @@ ---------------------------------------------------------------------------- ---------------------- TESTING Load and Write Header ----------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> DD TYPE: DDDMP_BDD -Number of variables: 50 -Number of support variables: 15 -suppVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 -orderedVarNames: V1 V2 V3 V4 V5 V6 V7 V8 V9 V10 V11 V12 V13 V14 V15 V16 V17 V18 V19 V20 V21 V22 V23 V24 V25 V26 V27 V28 V29 V30 V31 V32 V33 V34 V35 V36 V37 V38 V39 V40 V41 V42 V43 V44 V45 V46 V47 V48 V49 V50 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -varAuxIds: 3 5 15 17 19 23 43 45 47 73 75 77 95 97 99 -varAuxIds for ALL Manager Variables: -1 3 5 -1 -1 -1 -1 15 17 19 -1 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 43 45 47 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 73 75 77 -1 -1 -1 -1 -1 -1 -1 -1 95 97 99 -Number of roots: 1 -TestDddmp> File : TestDddmp> DD TYPE: DDDMP_ADD -Number of variables: 3 -Number of support variables: 2 -suppVarNames: DUMMY1 DUMMY2 -orderedVarNames: DUMMY0 DUMMY1 DUMMY2 -varIds: 1 2 -varIds for ALL Manager Variables: -1 1 2 -varComposeIds: 1 2 -varComposeIds for ALL Manager Variables: -1 1 2 -varAuxIds: 1 2 -varAuxIds for ALL Manager Variables: -1 1 2 -Number of roots: 1 -TestDddmp> File : TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 50 -Number of support variables: 15 -suppVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 -orderedVarNames: V1 V2 V3 V4 V5 V6 V7 V8 V9 V10 V11 V12 V13 V14 V15 V16 V17 V18 V19 V20 V21 V22 V23 V24 V25 V26 V27 V28 V29 V30 V31 V32 V33 V34 V35 V36 V37 V38 V39 V40 V41 V42 V43 V44 V45 V46 V47 V48 V49 V50 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -Number of roots: 1 -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. --------------------------------- ... END ---------------------------------- -rm: No match. ---------------------------------------------------------------------------- --------------------- TESTING Load BDD from DDDMP-1.0 ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> DD TYPE: DDDMP_BDD -Number of variables: 10 -Number of support variables: 7 -suppVarNames: G0 G1 G2 G3 G5 G6 G7 -orderedVarNames: G0 G1 G2 G3 G5 G6 G7 DUMMY7 DUMMY8 DUMMY9 -varIds: 0 1 2 3 4 5 6 -varIds for ALL Manager Variables: 0 1 2 3 4 5 6 -1 -1 -1 -varComposeIds: 0 1 2 3 4 6 8 -varComposeIds for ALL Manager Variables: 0 1 2 3 4 6 8 -1 -1 -1 -varAuxIds: 0 1 2 3 4 5 6 -varAuxIds for ALL Manager Variables: 0 1 2 3 4 5 6 -1 -1 -1 -Number of roots: 3 -TestDddmp> File : Which Array of BDDs [0..19]: TestDddmp> File : Which Array of BDDs [0..19]: Storing Array of BDDs in file s27deltaDddmp1.bdd.tmp ... -done. -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- -rm: No match. ---------------------------------------------------------------------------- ------------------------ TESTING basic Load/Store ... ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 0.bdd ... -TestDddmp> File : Which BDDs [0..19]: Loading 1.bdd ... -TestDddmp> Operation [or,and,xor,!,buf(=)] : Source1 [0..19]: Source2 [0..19]: Destination [0..19]: TestDddmp> File : Which BDDs [0..19]: Storing 0or1.bdd.tmp ... -TestDddmp> File : Which BDDs [0..19]: Loading 2.bdd ... -TestDddmp> File : Which BDDs [0..19]: Loading 3.bdd ... -TestDddmp> Operation [or,and,xor,!,buf(=)] : Source1 [0..19]: Source2 [0..19]: Destination [0..19]: TestDddmp> File : Which BDDs [0..19]: Storing 2and3.bdd.tmp ... -TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.bdd ... -TestDddmp> File : Which BDDs [0..19]: Loading 5.bdd ... -TestDddmp> Operation [or,and,xor,!,buf(=)] : Source1 [0..19]: Source2 [0..19]: Destination [0..19]: TestDddmp> File : Which BDDs [0..19]: Storing 4xor5.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- -rm: No match. ---------------------------------------------------------------------------- ----------- TESTING Load/Store with sifting, varnames & varauxids ---------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.bdd ... -TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Storing 4a.bdd.tmp ... -TestDddmp> Reordering Approach (1..17): TestDddmp> File : Which BDDs [0..19]: Storing 4b.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. -------------------------- ... END PHASE 1 ... ----------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> Variable matchmode: -Match IDs (1) -Match permIDs (2) -Match names (must have been loaded) (3) -Match auxids (must have been loaded) (4) -Match composeids (must have been loaded) (5) -Your choice: TestDddmp> File : Which BDDs [0..19]: Loading 4b.bdd.tmp ... -TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Storing 4c.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- -rm: No match. ---------------------------------------------------------------------------- ---------------------- TESTING Load ADD and Store ADD ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 0.add ... -Load: --01 2 --1- 1 -TestDddmp> File : Which BDDs [0..19]: Storing 0.add.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 1.add ... -Load: --0001--------------------------------------------- 1 --0010--------------------------------------------- 2 --0100--------------------------------------------- 1 --0101--------------------------------------------- 2 --0111--------------------------------------------- 1 --1000--------------------------------------------- 2 --1010--------------------------------------------- 1 --1011--------------------------------------------- 2 --1101--------------------------------------------- 1 --1110--------------------------------------------- 2 -TestDddmp> File : Which BDDs [0..19]: Storing 1.add.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- -rm: No match. ---------------------------------------------------------------------------- ---------------------- TESTING Load BDD and Store CNF ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.bdd ... -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Initial ID : Storing 4.cnf.tmp ... -Number of Clauses Stored = 108 -Number of New Variable Created Storing = 31 -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ---------------------- TESTING Load CNF and Store BDD ---------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.cnf.tmp ... -TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 150 -Number of support variables: 15 -suppVarNames: V3 V8 V23 V24 V37 V39 DUMMY21 DUMMY22 DUMMY23 DUMMY36 DUMMY37 DUMMY38 DUMMY47 DUMMY48 DUMMY49 -orderedVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 DUMMY15 DUMMY16 DUMMY17 DUMMY18 DUMMY19 DUMMY20 DUMMY21 DUMMY22 DUMMY23 DUMMY24 DUMMY25 DUMMY26 DUMMY27 DUMMY28 DUMMY29 DUMMY30 DUMMY31 DUMMY32 DUMMY33 DUMMY34 DUMMY35 DUMMY36 DUMMY37 DUMMY38 DUMMY39 DUMMY40 DUMMY41 DUMMY42 DUMMY43 DUMMY44 DUMMY45 DUMMY46 DUMMY47 DUMMY48 DUMMY49 DUMMY50 DUMMY51 DUMMY52 DUMMY53 DUMMY54 DUMMY55 DUMMY56 DUMMY57 DUMMY58 DUMMY59 DUMMY60 DUMMY61 DUMMY62 DUMMY63 DUMMY64 DUMMY65 DUMMY66 DUMMY67 DUMMY68 DUMMY69 DUMMY70 DUMMY71 DUMMY72 DUMMY73 DUMMY74 DUMMY75 DUMMY76 DUMMY77 DUMMY78 DUMMY79 DUMMY80 DUMMY81 DUMMY82 DUMMY83 DUMMY84 DUMMY85 DUMMY86 DUMMY87 DUMMY88 DUMMY89 DUMMY90 DUMMY91 DUMMY92 DUMMY93 DUMMY94 DUMMY95 DUMMY96 DUMMY97 DUMMY98 DUMMY99 DUMMY100 DUMMY101 DUMMY102 DUMMY103 DUMMY104 DUMMY105 DUMMY106 DUMMY107 DUMMY108 DUMMY109 DUMMY110 DUMMY111 DUMMY112 DUMMY113 DUMMY114 DUMMY115 DUMMY116 DUMMY117 DUMMY118 DUMMY119 DUMMY120 DUMMY121 DUMMY122 DUMMY123 DUMMY124 DUMMY125 DUMMY126 DUMMY127 DUMMY128 DUMMY129 DUMMY130 DUMMY131 DUMMY132 DUMMY133 DUMMY134 DUMMY135 DUMMY136 DUMMY137 DUMMY138 DUMMY139 DUMMY140 DUMMY141 DUMMY142 DUMMY143 DUMMY144 DUMMY145 DUMMY146 DUMMY147 DUMMY148 DUMMY149 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -Number of roots: 1 -TestDddmp> File : Which BDDs [0..19]: Storing 4.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- -rm: No match. ---------------------------------------------------------------------------- ---------------------- TESTING Load BDD and Store CNF ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.bdd ... -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Initial ID : Storing 4.node1.tmp ... -Number of Clauses Stored = 108 -Number of New Variable Created Storing = 31 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Initial ID : Storing 4.max1.tmp ... -Number of Clauses Stored = 103 -Number of New Variable Created Storing = 0 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Max Number of Edges (Insert cut-point from there on) : Max BDD-Path Length (Insert cut-point from there on) : Initial ID : Storing 4.node2.tmp ... -Number of Clauses Stored = 114 -Number of New Variable Created Storing = 31 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Max Number of Edges (Insert cut-point from there on) : Max BDD-Path Length (Insert cut-point from there on) : Initial ID : Storing 4.node3.tmp ... -Number of Clauses Stored = 108 -Number of New Variable Created Storing = 31 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Max Number of Edges (Insert cut-point from there on) : Max BDD-Path Length (Insert cut-point from there on) : Initial ID : Storing 4.max2.tmp ... -Number of Clauses Stored = 103 -Number of New Variable Created Storing = 0 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Max Number of Edges (Insert cut-point from there on) : Max BDD-Path Length (Insert cut-point from there on) : Initial ID : Storing 4.best1.tmp ... -Number of Clauses Stored = 53 -Number of New Variable Created Storing = 7 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Max Number of Edges (Insert cut-point from there on) : Max BDD-Path Length (Insert cut-point from there on) : Initial ID : Storing 4.best2.tmp ... -Number of Clauses Stored = 69 -Number of New Variable Created Storing = 12 -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ---------------------------------------------------------------------------- ---------------------- TESTING Load CNF and Store BDD ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.node2.tmp ... -TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 150 -Number of support variables: 15 -suppVarNames: V3 V8 V23 V24 V37 V39 DUMMY21 DUMMY22 DUMMY23 DUMMY36 DUMMY37 DUMMY38 DUMMY47 DUMMY48 DUMMY49 -orderedVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 DUMMY15 DUMMY16 DUMMY17 DUMMY18 DUMMY19 DUMMY20 DUMMY21 DUMMY22 DUMMY23 DUMMY24 DUMMY25 DUMMY26 DUMMY27 DUMMY28 DUMMY29 DUMMY30 DUMMY31 DUMMY32 DUMMY33 DUMMY34 DUMMY35 DUMMY36 DUMMY37 DUMMY38 DUMMY39 DUMMY40 DUMMY41 DUMMY42 DUMMY43 DUMMY44 DUMMY45 DUMMY46 DUMMY47 DUMMY48 DUMMY49 DUMMY50 DUMMY51 DUMMY52 DUMMY53 DUMMY54 DUMMY55 DUMMY56 DUMMY57 DUMMY58 DUMMY59 DUMMY60 DUMMY61 DUMMY62 DUMMY63 DUMMY64 DUMMY65 DUMMY66 DUMMY67 DUMMY68 DUMMY69 DUMMY70 DUMMY71 DUMMY72 DUMMY73 DUMMY74 DUMMY75 DUMMY76 DUMMY77 DUMMY78 DUMMY79 DUMMY80 DUMMY81 DUMMY82 DUMMY83 DUMMY84 DUMMY85 DUMMY86 DUMMY87 DUMMY88 DUMMY89 DUMMY90 DUMMY91 DUMMY92 DUMMY93 DUMMY94 DUMMY95 DUMMY96 DUMMY97 DUMMY98 DUMMY99 DUMMY100 DUMMY101 DUMMY102 DUMMY103 DUMMY104 DUMMY105 DUMMY106 DUMMY107 DUMMY108 DUMMY109 DUMMY110 DUMMY111 DUMMY112 DUMMY113 DUMMY114 DUMMY115 DUMMY116 DUMMY117 DUMMY118 DUMMY119 DUMMY120 DUMMY121 DUMMY122 DUMMY123 DUMMY124 DUMMY125 DUMMY126 DUMMY127 DUMMY128 DUMMY129 DUMMY130 DUMMY131 DUMMY132 DUMMY133 DUMMY134 DUMMY135 DUMMY136 DUMMY137 DUMMY138 DUMMY139 DUMMY140 DUMMY141 DUMMY142 DUMMY143 DUMMY144 DUMMY145 DUMMY146 DUMMY147 DUMMY148 DUMMY149 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -Number of roots: 1 -TestDddmp> File : Which BDDs [0..19]: Storing 4.node2.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.node3.tmp ... -TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 150 -Number of support variables: 15 -suppVarNames: V3 V8 V23 V24 V37 V39 DUMMY21 DUMMY22 DUMMY23 DUMMY36 DUMMY37 DUMMY38 DUMMY47 DUMMY48 DUMMY49 -orderedVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 DUMMY15 DUMMY16 DUMMY17 DUMMY18 DUMMY19 DUMMY20 DUMMY21 DUMMY22 DUMMY23 DUMMY24 DUMMY25 DUMMY26 DUMMY27 DUMMY28 DUMMY29 DUMMY30 DUMMY31 DUMMY32 DUMMY33 DUMMY34 DUMMY35 DUMMY36 DUMMY37 DUMMY38 DUMMY39 DUMMY40 DUMMY41 DUMMY42 DUMMY43 DUMMY44 DUMMY45 DUMMY46 DUMMY47 DUMMY48 DUMMY49 DUMMY50 DUMMY51 DUMMY52 DUMMY53 DUMMY54 DUMMY55 DUMMY56 DUMMY57 DUMMY58 DUMMY59 DUMMY60 DUMMY61 DUMMY62 DUMMY63 DUMMY64 DUMMY65 DUMMY66 DUMMY67 DUMMY68 DUMMY69 DUMMY70 DUMMY71 DUMMY72 DUMMY73 DUMMY74 DUMMY75 DUMMY76 DUMMY77 DUMMY78 DUMMY79 DUMMY80 DUMMY81 DUMMY82 DUMMY83 DUMMY84 DUMMY85 DUMMY86 DUMMY87 DUMMY88 DUMMY89 DUMMY90 DUMMY91 DUMMY92 DUMMY93 DUMMY94 DUMMY95 DUMMY96 DUMMY97 DUMMY98 DUMMY99 DUMMY100 DUMMY101 DUMMY102 DUMMY103 DUMMY104 DUMMY105 DUMMY106 DUMMY107 DUMMY108 DUMMY109 DUMMY110 DUMMY111 DUMMY112 DUMMY113 DUMMY114 DUMMY115 DUMMY116 DUMMY117 DUMMY118 DUMMY119 DUMMY120 DUMMY121 DUMMY122 DUMMY123 DUMMY124 DUMMY125 DUMMY126 DUMMY127 DUMMY128 DUMMY129 DUMMY130 DUMMY131 DUMMY132 DUMMY133 DUMMY134 DUMMY135 DUMMY136 DUMMY137 DUMMY138 DUMMY139 DUMMY140 DUMMY141 DUMMY142 DUMMY143 DUMMY144 DUMMY145 DUMMY146 DUMMY147 DUMMY148 DUMMY149 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -Number of roots: 1 -TestDddmp> File : Which BDDs [0..19]: Storing 4.node3.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.best1.tmp ... -TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 150 -Number of support variables: 15 -suppVarNames: V3 V8 V23 V24 V37 V39 DUMMY21 DUMMY22 DUMMY23 DUMMY36 DUMMY37 DUMMY38 DUMMY47 DUMMY48 DUMMY49 -orderedVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 DUMMY15 DUMMY16 DUMMY17 DUMMY18 DUMMY19 DUMMY20 DUMMY21 DUMMY22 DUMMY23 DUMMY24 DUMMY25 DUMMY26 DUMMY27 DUMMY28 DUMMY29 DUMMY30 DUMMY31 DUMMY32 DUMMY33 DUMMY34 DUMMY35 DUMMY36 DUMMY37 DUMMY38 DUMMY39 DUMMY40 DUMMY41 DUMMY42 DUMMY43 DUMMY44 DUMMY45 DUMMY46 DUMMY47 DUMMY48 DUMMY49 DUMMY50 DUMMY51 DUMMY52 DUMMY53 DUMMY54 DUMMY55 DUMMY56 DUMMY57 DUMMY58 DUMMY59 DUMMY60 DUMMY61 DUMMY62 DUMMY63 DUMMY64 DUMMY65 DUMMY66 DUMMY67 DUMMY68 DUMMY69 DUMMY70 DUMMY71 DUMMY72 DUMMY73 DUMMY74 DUMMY75 DUMMY76 DUMMY77 DUMMY78 DUMMY79 DUMMY80 DUMMY81 DUMMY82 DUMMY83 DUMMY84 DUMMY85 DUMMY86 DUMMY87 DUMMY88 DUMMY89 DUMMY90 DUMMY91 DUMMY92 DUMMY93 DUMMY94 DUMMY95 DUMMY96 DUMMY97 DUMMY98 DUMMY99 DUMMY100 DUMMY101 DUMMY102 DUMMY103 DUMMY104 DUMMY105 DUMMY106 DUMMY107 DUMMY108 DUMMY109 DUMMY110 DUMMY111 DUMMY112 DUMMY113 DUMMY114 DUMMY115 DUMMY116 DUMMY117 DUMMY118 DUMMY119 DUMMY120 DUMMY121 DUMMY122 DUMMY123 DUMMY124 DUMMY125 DUMMY126 DUMMY127 DUMMY128 DUMMY129 DUMMY130 DUMMY131 DUMMY132 DUMMY133 DUMMY134 DUMMY135 DUMMY136 DUMMY137 DUMMY138 DUMMY139 DUMMY140 DUMMY141 DUMMY142 DUMMY143 DUMMY144 DUMMY145 DUMMY146 DUMMY147 DUMMY148 DUMMY149 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -Number of roots: 1 -TestDddmp> File : Which BDDs [0..19]: Storing 4.best1.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.best2.tmp ... -TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 150 -Number of support variables: 15 -suppVarNames: V3 V8 V23 V24 V37 V39 DUMMY21 DUMMY22 DUMMY23 DUMMY36 DUMMY37 DUMMY38 DUMMY47 DUMMY48 DUMMY49 -orderedVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 DUMMY15 DUMMY16 DUMMY17 DUMMY18 DUMMY19 DUMMY20 DUMMY21 DUMMY22 DUMMY23 DUMMY24 DUMMY25 DUMMY26 DUMMY27 DUMMY28 DUMMY29 DUMMY30 DUMMY31 DUMMY32 DUMMY33 DUMMY34 DUMMY35 DUMMY36 DUMMY37 DUMMY38 DUMMY39 DUMMY40 DUMMY41 DUMMY42 DUMMY43 DUMMY44 DUMMY45 DUMMY46 DUMMY47 DUMMY48 DUMMY49 DUMMY50 DUMMY51 DUMMY52 DUMMY53 DUMMY54 DUMMY55 DUMMY56 DUMMY57 DUMMY58 DUMMY59 DUMMY60 DUMMY61 DUMMY62 DUMMY63 DUMMY64 DUMMY65 DUMMY66 DUMMY67 DUMMY68 DUMMY69 DUMMY70 DUMMY71 DUMMY72 DUMMY73 DUMMY74 DUMMY75 DUMMY76 DUMMY77 DUMMY78 DUMMY79 DUMMY80 DUMMY81 DUMMY82 DUMMY83 DUMMY84 DUMMY85 DUMMY86 DUMMY87 DUMMY88 DUMMY89 DUMMY90 DUMMY91 DUMMY92 DUMMY93 DUMMY94 DUMMY95 DUMMY96 DUMMY97 DUMMY98 DUMMY99 DUMMY100 DUMMY101 DUMMY102 DUMMY103 DUMMY104 DUMMY105 DUMMY106 DUMMY107 DUMMY108 DUMMY109 DUMMY110 DUMMY111 DUMMY112 DUMMY113 DUMMY114 DUMMY115 DUMMY116 DUMMY117 DUMMY118 DUMMY119 DUMMY120 DUMMY121 DUMMY122 DUMMY123 DUMMY124 DUMMY125 DUMMY126 DUMMY127 DUMMY128 DUMMY129 DUMMY130 DUMMY131 DUMMY132 DUMMY133 DUMMY134 DUMMY135 DUMMY136 DUMMY137 DUMMY138 DUMMY139 DUMMY140 DUMMY141 DUMMY142 DUMMY143 DUMMY144 DUMMY145 DUMMY146 DUMMY147 DUMMY148 DUMMY149 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -Number of roots: 1 -TestDddmp> File : Which BDDs [0..19]: Storing 4.best2.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/runAllTest.script b/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/runAllTest.script deleted file mode 100644 index 8d792ef42..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/runAllTest.script +++ /dev/null @@ -1,11 +0,0 @@ -# !/bin/sh -# -# Run All Test Files -# -./test1.script -./test2.script -./test3.script -./test4.script -./test5.script -./test6.script -./test7.script diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test1.out b/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test1.out deleted file mode 100644 index 96b2a3ac3..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test1.out +++ /dev/null @@ -1,44 +0,0 @@ -rm: No match. ---------------------------------------------------------------------------- ---------------------- TESTING Load and Write Header ----------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> DD TYPE: DDDMP_BDD -Number of variables: 50 -Number of support variables: 15 -suppVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 -orderedVarNames: V1 V2 V3 V4 V5 V6 V7 V8 V9 V10 V11 V12 V13 V14 V15 V16 V17 V18 V19 V20 V21 V22 V23 V24 V25 V26 V27 V28 V29 V30 V31 V32 V33 V34 V35 V36 V37 V38 V39 V40 V41 V42 V43 V44 V45 V46 V47 V48 V49 V50 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -varAuxIds: 3 5 15 17 19 23 43 45 47 73 75 77 95 97 99 -varAuxIds for ALL Manager Variables: -1 3 5 -1 -1 -1 -1 15 17 19 -1 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 43 45 47 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 73 75 77 -1 -1 -1 -1 -1 -1 -1 -1 95 97 99 -Number of roots: 1 -TestDddmp> File : TestDddmp> DD TYPE: DDDMP_ADD -Number of variables: 3 -Number of support variables: 2 -suppVarNames: DUMMY1 DUMMY2 -orderedVarNames: DUMMY0 DUMMY1 DUMMY2 -varIds: 1 2 -varIds for ALL Manager Variables: -1 1 2 -varComposeIds: 1 2 -varComposeIds for ALL Manager Variables: -1 1 2 -varAuxIds: 1 2 -varAuxIds for ALL Manager Variables: -1 1 2 -Number of roots: 1 -TestDddmp> File : TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 50 -Number of support variables: 15 -suppVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 -orderedVarNames: V1 V2 V3 V4 V5 V6 V7 V8 V9 V10 V11 V12 V13 V14 V15 V16 V17 V18 V19 V20 V21 V22 V23 V24 V25 V26 V27 V28 V29 V30 V31 V32 V33 V34 V35 V36 V37 V38 V39 V40 V41 V42 V43 V44 V45 V46 V47 V48 V49 V50 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -Number of roots: 1 -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. --------------------------------- ... END ---------------------------------- diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test2.out b/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test2.out deleted file mode 100644 index 22d6e39d1..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test2.out +++ /dev/null @@ -1,23 +0,0 @@ -rm: No match. ---------------------------------------------------------------------------- --------------------- TESTING Load BDD from DDDMP-1.0 ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> DD TYPE: DDDMP_BDD -Number of variables: 10 -Number of support variables: 7 -suppVarNames: G0 G1 G2 G3 G5 G6 G7 -orderedVarNames: G0 G1 G2 G3 G5 G6 G7 DUMMY7 DUMMY8 DUMMY9 -varIds: 0 1 2 3 4 5 6 -varIds for ALL Manager Variables: 0 1 2 3 4 5 6 -1 -1 -1 -varComposeIds: 0 1 2 3 4 6 8 -varComposeIds for ALL Manager Variables: 0 1 2 3 4 6 8 -1 -1 -1 -varAuxIds: 0 1 2 3 4 5 6 -varAuxIds for ALL Manager Variables: 0 1 2 3 4 5 6 -1 -1 -1 -Number of roots: 3 -TestDddmp> File : Which Array of BDDs [0..19]: TestDddmp> File : Which Array of BDDs [0..19]: Storing Array of BDDs in file s27deltaDddmp1.bdd.tmp ... -done. -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test3.out b/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test3.out deleted file mode 100644 index 0c296c095..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test3.out +++ /dev/null @@ -1,18 +0,0 @@ -rm: No match. ---------------------------------------------------------------------------- ------------------------ TESTING basic Load/Store ... ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 0.bdd ... -TestDddmp> File : Which BDDs [0..19]: Loading 1.bdd ... -TestDddmp> Operation [or,and,xor,!,buf(=)] : Source1 [0..19]: Source2 [0..19]: Destination [0..19]: TestDddmp> File : Which BDDs [0..19]: Storing 0or1.bdd.tmp ... -TestDddmp> File : Which BDDs [0..19]: Loading 2.bdd ... -TestDddmp> File : Which BDDs [0..19]: Loading 3.bdd ... -TestDddmp> Operation [or,and,xor,!,buf(=)] : Source1 [0..19]: Source2 [0..19]: Destination [0..19]: TestDddmp> File : Which BDDs [0..19]: Storing 2and3.bdd.tmp ... -TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.bdd ... -TestDddmp> File : Which BDDs [0..19]: Loading 5.bdd ... -TestDddmp> Operation [or,and,xor,!,buf(=)] : Source1 [0..19]: Source2 [0..19]: Destination [0..19]: TestDddmp> File : Which BDDs [0..19]: Storing 4xor5.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test3.script b/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test3.script deleted file mode 100644 index 408496c2d..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test3.script +++ /dev/null @@ -1,69 +0,0 @@ -# !/bin/sh -# -# BDD check: -# Load BDDs -# Make some operations -# Store BDDs -# -rm -f *.*.tmp -echo "---------------------------------------------------------------------------" -echo "----------------------- TESTING basic Load/Store ... ----------------------" -echo "---------------------------------------------------------------------------" -./../testdddmp << END -mi -50 -hlb -0or1.bdd -bl -0.bdd -0 -bl -1.bdd -1 -op -or -0 -1 -2 -bs -0or1.bdd.tmp -2 -bl -2.bdd -2 -bl -3.bdd -3 -op -and -2 -3 -4 -bs -2and3.bdd.tmp -4 -hlb -4xor5.bdd -bl -4.bdd -4 -bl -5.bdd -5 -op -xor -4 -5 -6 -bs -4xor5.bdd.tmp -6 -mq -quit -END -echo "----------------------------- ... RESULTS ... -----------------------------" -diff --brief 0or1.bdd 0or1.bdd.tmp -diff --brief 2and3.bdd 2and3.bdd.tmp -diff --brief 4xor5.bdd 4xor5.bdd.tmp -echo "-------------------------------- ... END ----------------------------------" -rm -f *.*.tmp diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test4.out b/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test4.out deleted file mode 100644 index 367602d90..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test4.out +++ /dev/null @@ -1,24 +0,0 @@ -rm: No match. ---------------------------------------------------------------------------- ----------- TESTING Load/Store with sifting, varnames & varauxids ---------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.bdd ... -TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Storing 4a.bdd.tmp ... -TestDddmp> Reordering Approach (1..17): TestDddmp> File : Which BDDs [0..19]: Storing 4b.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. -------------------------- ... END PHASE 1 ... ----------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> Variable matchmode: -Match IDs (1) -Match permIDs (2) -Match names (must have been loaded) (3) -Match auxids (must have been loaded) (4) -Match composeids (must have been loaded) (5) -Your choice: TestDddmp> File : Which BDDs [0..19]: Loading 4b.bdd.tmp ... -TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Storing 4c.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test5.out b/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test5.out deleted file mode 100644 index a883f515f..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test5.out +++ /dev/null @@ -1,28 +0,0 @@ -rm: No match. ---------------------------------------------------------------------------- ---------------------- TESTING Load ADD and Store ADD ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 0.add ... -Load: --01 2 --1- 1 -TestDddmp> File : Which BDDs [0..19]: Storing 0.add.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 1.add ... -Load: --0001--------------------------------------------- 1 --0010--------------------------------------------- 2 --0100--------------------------------------------- 1 --0101--------------------------------------------- 2 --0111--------------------------------------------- 1 --1000--------------------------------------------- 2 --1010--------------------------------------------- 1 --1011--------------------------------------------- 2 --1101--------------------------------------------- 1 --1110--------------------------------------------- 2 -TestDddmp> File : Which BDDs [0..19]: Storing 1.add.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test6.out b/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test6.out deleted file mode 100644 index f10b48490..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test6.out +++ /dev/null @@ -1,31 +0,0 @@ -rm: No match. ---------------------------------------------------------------------------- ---------------------- TESTING Load BDD and Store CNF ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.bdd ... -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Initial ID : Storing 4.cnf.tmp ... -Number of Clauses Stored = 108 -Number of New Variable Created Storing = 31 -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ---------------------- TESTING Load CNF and Store BDD ---------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.cnf.tmp ... -TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 150 -Number of support variables: 15 -suppVarNames: V3 V8 V23 V24 V37 V39 DUMMY21 DUMMY22 DUMMY23 DUMMY36 DUMMY37 DUMMY38 DUMMY47 DUMMY48 DUMMY49 -orderedVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 DUMMY15 DUMMY16 DUMMY17 DUMMY18 DUMMY19 DUMMY20 DUMMY21 DUMMY22 DUMMY23 DUMMY24 DUMMY25 DUMMY26 DUMMY27 DUMMY28 DUMMY29 DUMMY30 DUMMY31 DUMMY32 DUMMY33 DUMMY34 DUMMY35 DUMMY36 DUMMY37 DUMMY38 DUMMY39 DUMMY40 DUMMY41 DUMMY42 DUMMY43 DUMMY44 DUMMY45 DUMMY46 DUMMY47 DUMMY48 DUMMY49 DUMMY50 DUMMY51 DUMMY52 DUMMY53 DUMMY54 DUMMY55 DUMMY56 DUMMY57 DUMMY58 DUMMY59 DUMMY60 DUMMY61 DUMMY62 DUMMY63 DUMMY64 DUMMY65 DUMMY66 DUMMY67 DUMMY68 DUMMY69 DUMMY70 DUMMY71 DUMMY72 DUMMY73 DUMMY74 DUMMY75 DUMMY76 DUMMY77 DUMMY78 DUMMY79 DUMMY80 DUMMY81 DUMMY82 DUMMY83 DUMMY84 DUMMY85 DUMMY86 DUMMY87 DUMMY88 DUMMY89 DUMMY90 DUMMY91 DUMMY92 DUMMY93 DUMMY94 DUMMY95 DUMMY96 DUMMY97 DUMMY98 DUMMY99 DUMMY100 DUMMY101 DUMMY102 DUMMY103 DUMMY104 DUMMY105 DUMMY106 DUMMY107 DUMMY108 DUMMY109 DUMMY110 DUMMY111 DUMMY112 DUMMY113 DUMMY114 DUMMY115 DUMMY116 DUMMY117 DUMMY118 DUMMY119 DUMMY120 DUMMY121 DUMMY122 DUMMY123 DUMMY124 DUMMY125 DUMMY126 DUMMY127 DUMMY128 DUMMY129 DUMMY130 DUMMY131 DUMMY132 DUMMY133 DUMMY134 DUMMY135 DUMMY136 DUMMY137 DUMMY138 DUMMY139 DUMMY140 DUMMY141 DUMMY142 DUMMY143 DUMMY144 DUMMY145 DUMMY146 DUMMY147 DUMMY148 DUMMY149 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -Number of roots: 1 -TestDddmp> File : Which BDDs [0..19]: Storing 4.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test7.out b/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test7.out deleted file mode 100644 index d5cd7d3e0..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test7.out +++ /dev/null @@ -1,102 +0,0 @@ -rm: No match. ---------------------------------------------------------------------------- ---------------------- TESTING Load BDD and Store CNF ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.bdd ... -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Initial ID : Storing 4.node1.tmp ... -Number of Clauses Stored = 108 -Number of New Variable Created Storing = 31 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Initial ID : Storing 4.max1.tmp ... -Number of Clauses Stored = 103 -Number of New Variable Created Storing = 0 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Max Number of Edges (Insert cut-point from there on) : Max BDD-Path Length (Insert cut-point from there on) : Initial ID : Storing 4.node2.tmp ... -Number of Clauses Stored = 114 -Number of New Variable Created Storing = 31 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Max Number of Edges (Insert cut-point from there on) : Max BDD-Path Length (Insert cut-point from there on) : Initial ID : Storing 4.node3.tmp ... -Number of Clauses Stored = 108 -Number of New Variable Created Storing = 31 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Max Number of Edges (Insert cut-point from there on) : Max BDD-Path Length (Insert cut-point from there on) : Initial ID : Storing 4.max2.tmp ... -Number of Clauses Stored = 103 -Number of New Variable Created Storing = 0 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Max Number of Edges (Insert cut-point from there on) : Max BDD-Path Length (Insert cut-point from there on) : Initial ID : Storing 4.best1.tmp ... -Number of Clauses Stored = 53 -Number of New Variable Created Storing = 7 -TestDddmp> File : Which BDDs [0..19]: Format (Node=N, Maxterm=M, Best=B) : Max Number of Edges (Insert cut-point from there on) : Max BDD-Path Length (Insert cut-point from there on) : Initial ID : Storing 4.best2.tmp ... -Number of Clauses Stored = 69 -Number of New Variable Created Storing = 12 -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ---------------------------------------------------------------------------- ---------------------- TESTING Load CNF and Store BDD ---------------------- ---------------------------------------------------------------------------- -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.node2.tmp ... -TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 150 -Number of support variables: 15 -suppVarNames: V3 V8 V23 V24 V37 V39 DUMMY21 DUMMY22 DUMMY23 DUMMY36 DUMMY37 DUMMY38 DUMMY47 DUMMY48 DUMMY49 -orderedVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 DUMMY15 DUMMY16 DUMMY17 DUMMY18 DUMMY19 DUMMY20 DUMMY21 DUMMY22 DUMMY23 DUMMY24 DUMMY25 DUMMY26 DUMMY27 DUMMY28 DUMMY29 DUMMY30 DUMMY31 DUMMY32 DUMMY33 DUMMY34 DUMMY35 DUMMY36 DUMMY37 DUMMY38 DUMMY39 DUMMY40 DUMMY41 DUMMY42 DUMMY43 DUMMY44 DUMMY45 DUMMY46 DUMMY47 DUMMY48 DUMMY49 DUMMY50 DUMMY51 DUMMY52 DUMMY53 DUMMY54 DUMMY55 DUMMY56 DUMMY57 DUMMY58 DUMMY59 DUMMY60 DUMMY61 DUMMY62 DUMMY63 DUMMY64 DUMMY65 DUMMY66 DUMMY67 DUMMY68 DUMMY69 DUMMY70 DUMMY71 DUMMY72 DUMMY73 DUMMY74 DUMMY75 DUMMY76 DUMMY77 DUMMY78 DUMMY79 DUMMY80 DUMMY81 DUMMY82 DUMMY83 DUMMY84 DUMMY85 DUMMY86 DUMMY87 DUMMY88 DUMMY89 DUMMY90 DUMMY91 DUMMY92 DUMMY93 DUMMY94 DUMMY95 DUMMY96 DUMMY97 DUMMY98 DUMMY99 DUMMY100 DUMMY101 DUMMY102 DUMMY103 DUMMY104 DUMMY105 DUMMY106 DUMMY107 DUMMY108 DUMMY109 DUMMY110 DUMMY111 DUMMY112 DUMMY113 DUMMY114 DUMMY115 DUMMY116 DUMMY117 DUMMY118 DUMMY119 DUMMY120 DUMMY121 DUMMY122 DUMMY123 DUMMY124 DUMMY125 DUMMY126 DUMMY127 DUMMY128 DUMMY129 DUMMY130 DUMMY131 DUMMY132 DUMMY133 DUMMY134 DUMMY135 DUMMY136 DUMMY137 DUMMY138 DUMMY139 DUMMY140 DUMMY141 DUMMY142 DUMMY143 DUMMY144 DUMMY145 DUMMY146 DUMMY147 DUMMY148 DUMMY149 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -Number of roots: 1 -TestDddmp> File : Which BDDs [0..19]: Storing 4.node2.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.node3.tmp ... -TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 150 -Number of support variables: 15 -suppVarNames: V3 V8 V23 V24 V37 V39 DUMMY21 DUMMY22 DUMMY23 DUMMY36 DUMMY37 DUMMY38 DUMMY47 DUMMY48 DUMMY49 -orderedVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 DUMMY15 DUMMY16 DUMMY17 DUMMY18 DUMMY19 DUMMY20 DUMMY21 DUMMY22 DUMMY23 DUMMY24 DUMMY25 DUMMY26 DUMMY27 DUMMY28 DUMMY29 DUMMY30 DUMMY31 DUMMY32 DUMMY33 DUMMY34 DUMMY35 DUMMY36 DUMMY37 DUMMY38 DUMMY39 DUMMY40 DUMMY41 DUMMY42 DUMMY43 DUMMY44 DUMMY45 DUMMY46 DUMMY47 DUMMY48 DUMMY49 DUMMY50 DUMMY51 DUMMY52 DUMMY53 DUMMY54 DUMMY55 DUMMY56 DUMMY57 DUMMY58 DUMMY59 DUMMY60 DUMMY61 DUMMY62 DUMMY63 DUMMY64 DUMMY65 DUMMY66 DUMMY67 DUMMY68 DUMMY69 DUMMY70 DUMMY71 DUMMY72 DUMMY73 DUMMY74 DUMMY75 DUMMY76 DUMMY77 DUMMY78 DUMMY79 DUMMY80 DUMMY81 DUMMY82 DUMMY83 DUMMY84 DUMMY85 DUMMY86 DUMMY87 DUMMY88 DUMMY89 DUMMY90 DUMMY91 DUMMY92 DUMMY93 DUMMY94 DUMMY95 DUMMY96 DUMMY97 DUMMY98 DUMMY99 DUMMY100 DUMMY101 DUMMY102 DUMMY103 DUMMY104 DUMMY105 DUMMY106 DUMMY107 DUMMY108 DUMMY109 DUMMY110 DUMMY111 DUMMY112 DUMMY113 DUMMY114 DUMMY115 DUMMY116 DUMMY117 DUMMY118 DUMMY119 DUMMY120 DUMMY121 DUMMY122 DUMMY123 DUMMY124 DUMMY125 DUMMY126 DUMMY127 DUMMY128 DUMMY129 DUMMY130 DUMMY131 DUMMY132 DUMMY133 DUMMY134 DUMMY135 DUMMY136 DUMMY137 DUMMY138 DUMMY139 DUMMY140 DUMMY141 DUMMY142 DUMMY143 DUMMY144 DUMMY145 DUMMY146 DUMMY147 DUMMY148 DUMMY149 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -Number of roots: 1 -TestDddmp> File : Which BDDs [0..19]: Storing 4.node3.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.best1.tmp ... -TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 150 -Number of support variables: 15 -suppVarNames: V3 V8 V23 V24 V37 V39 DUMMY21 DUMMY22 DUMMY23 DUMMY36 DUMMY37 DUMMY38 DUMMY47 DUMMY48 DUMMY49 -orderedVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 DUMMY15 DUMMY16 DUMMY17 DUMMY18 DUMMY19 DUMMY20 DUMMY21 DUMMY22 DUMMY23 DUMMY24 DUMMY25 DUMMY26 DUMMY27 DUMMY28 DUMMY29 DUMMY30 DUMMY31 DUMMY32 DUMMY33 DUMMY34 DUMMY35 DUMMY36 DUMMY37 DUMMY38 DUMMY39 DUMMY40 DUMMY41 DUMMY42 DUMMY43 DUMMY44 DUMMY45 DUMMY46 DUMMY47 DUMMY48 DUMMY49 DUMMY50 DUMMY51 DUMMY52 DUMMY53 DUMMY54 DUMMY55 DUMMY56 DUMMY57 DUMMY58 DUMMY59 DUMMY60 DUMMY61 DUMMY62 DUMMY63 DUMMY64 DUMMY65 DUMMY66 DUMMY67 DUMMY68 DUMMY69 DUMMY70 DUMMY71 DUMMY72 DUMMY73 DUMMY74 DUMMY75 DUMMY76 DUMMY77 DUMMY78 DUMMY79 DUMMY80 DUMMY81 DUMMY82 DUMMY83 DUMMY84 DUMMY85 DUMMY86 DUMMY87 DUMMY88 DUMMY89 DUMMY90 DUMMY91 DUMMY92 DUMMY93 DUMMY94 DUMMY95 DUMMY96 DUMMY97 DUMMY98 DUMMY99 DUMMY100 DUMMY101 DUMMY102 DUMMY103 DUMMY104 DUMMY105 DUMMY106 DUMMY107 DUMMY108 DUMMY109 DUMMY110 DUMMY111 DUMMY112 DUMMY113 DUMMY114 DUMMY115 DUMMY116 DUMMY117 DUMMY118 DUMMY119 DUMMY120 DUMMY121 DUMMY122 DUMMY123 DUMMY124 DUMMY125 DUMMY126 DUMMY127 DUMMY128 DUMMY129 DUMMY130 DUMMY131 DUMMY132 DUMMY133 DUMMY134 DUMMY135 DUMMY136 DUMMY137 DUMMY138 DUMMY139 DUMMY140 DUMMY141 DUMMY142 DUMMY143 DUMMY144 DUMMY145 DUMMY146 DUMMY147 DUMMY148 DUMMY149 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -Number of roots: 1 -TestDddmp> File : Which BDDs [0..19]: Storing 4.best1.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. -#./../testdddmp Version 2.0.2 (use command help) -TestDddmp> Number of Variables: TestDddmp> File : TestDddmp> File : Which BDDs [0..19]: Loading 4.best2.tmp ... -TestDddmp> DD TYPE: DDDMP_CNF -Number of variables: 150 -Number of support variables: 15 -suppVarNames: V3 V8 V23 V24 V37 V39 DUMMY21 DUMMY22 DUMMY23 DUMMY36 DUMMY37 DUMMY38 DUMMY47 DUMMY48 DUMMY49 -orderedVarNames: V2 V3 V8 V9 V10 V12 V22 V23 V24 V37 V38 V39 V48 V49 V50 DUMMY15 DUMMY16 DUMMY17 DUMMY18 DUMMY19 DUMMY20 DUMMY21 DUMMY22 DUMMY23 DUMMY24 DUMMY25 DUMMY26 DUMMY27 DUMMY28 DUMMY29 DUMMY30 DUMMY31 DUMMY32 DUMMY33 DUMMY34 DUMMY35 DUMMY36 DUMMY37 DUMMY38 DUMMY39 DUMMY40 DUMMY41 DUMMY42 DUMMY43 DUMMY44 DUMMY45 DUMMY46 DUMMY47 DUMMY48 DUMMY49 DUMMY50 DUMMY51 DUMMY52 DUMMY53 DUMMY54 DUMMY55 DUMMY56 DUMMY57 DUMMY58 DUMMY59 DUMMY60 DUMMY61 DUMMY62 DUMMY63 DUMMY64 DUMMY65 DUMMY66 DUMMY67 DUMMY68 DUMMY69 DUMMY70 DUMMY71 DUMMY72 DUMMY73 DUMMY74 DUMMY75 DUMMY76 DUMMY77 DUMMY78 DUMMY79 DUMMY80 DUMMY81 DUMMY82 DUMMY83 DUMMY84 DUMMY85 DUMMY86 DUMMY87 DUMMY88 DUMMY89 DUMMY90 DUMMY91 DUMMY92 DUMMY93 DUMMY94 DUMMY95 DUMMY96 DUMMY97 DUMMY98 DUMMY99 DUMMY100 DUMMY101 DUMMY102 DUMMY103 DUMMY104 DUMMY105 DUMMY106 DUMMY107 DUMMY108 DUMMY109 DUMMY110 DUMMY111 DUMMY112 DUMMY113 DUMMY114 DUMMY115 DUMMY116 DUMMY117 DUMMY118 DUMMY119 DUMMY120 DUMMY121 DUMMY122 DUMMY123 DUMMY124 DUMMY125 DUMMY126 DUMMY127 DUMMY128 DUMMY129 DUMMY130 DUMMY131 DUMMY132 DUMMY133 DUMMY134 DUMMY135 DUMMY136 DUMMY137 DUMMY138 DUMMY139 DUMMY140 DUMMY141 DUMMY142 DUMMY143 DUMMY144 DUMMY145 DUMMY146 DUMMY147 DUMMY148 DUMMY149 -varIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varComposeIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varComposeIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -varAuxIds: 1 2 7 8 9 11 21 22 23 36 37 38 47 48 49 -varAuxIds for ALL Manager Variables: -1 1 2 -1 -1 -1 -1 7 8 9 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 21 22 23 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 36 37 38 -1 -1 -1 -1 -1 -1 -1 -1 47 48 49 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -Number of roots: 1 -TestDddmp> File : Which BDDs [0..19]: Storing 4.best2.bdd.tmp ... -TestDddmp> Quitting CUDD Manager. -TestDddmp> End of test. ------------------------------ ... RESULTS ... ----------------------------- --------------------------------- ... END ---------------------------------- diff --git a/resources/3rdparty/cudd-2.5.0/src/epd/Makefile b/resources/3rdparty/cudd-2.5.0/src/epd/Makefile deleted file mode 100644 index 3b26bc9a9..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/epd/Makefile +++ /dev/null @@ -1,64 +0,0 @@ -# $Id$ -# -# epd -- extended precision -#--------------------------------------------------------------------------- -.SUFFIXES: .c .o .u - -CC = gcc -RANLIB = ranlib - -MFLAG = -ICFLAGS = -g -O6 -Wall -CFLAGS = $(ICFLAGS) $(MFLAG) $(XCFLAGS) - -LINTFLAGS = -u -n - -# this is to create the lint library -LINTSWITCH = -o - -P = epd -PSRC = epd.c -PHDR = epd.h -POBJ = $(PSRC:.c=.o) -PUBJ = $(PSRC:.c=.u) - -WHERE = .. -INCLUDE = $(WHERE)/include - -#--------------------------- - -lib$(P).a: $(POBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.o: $(PSRC) $(PHDR) - $(CC) -c $< -I$(INCLUDE) $(CFLAGS) - -optimize_dec: lib$(P).b - -lib$(P).b: $(PUBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.u: $(PSRC) $(PHDR) - cc -j $< -I$(INCLUDE) $(XCFLAGS) - -# if the header files change, recompile -$(POBJ): $(PHDR) -$(PUBJ): $(PHDR) - -lint: llib-l$(P).ln - -llib-l$(P).ln: $(PSRC) $(PHDR) - lint $(LINTFLAGS) $(LINTSWITCH)$(P) -I$(INCLUDE) $(PSRC) - -tags: $(PSRC) $(PHDR) - ctags $(PSRC) $(PHDR) - -all: lib$(P).a lib$(P).b llib-l$(P).ln tags - -clean: - rm -f *.o *.u .pure *.warnings - -distclean: clean - rm -f lib*.a lib$(P).b llib-l$(P).ln tags *~ *.bak *.qv *.qx diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/Makefile b/resources/3rdparty/cudd-2.5.0/src/mtr/Makefile deleted file mode 100644 index b62b7c5da..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/mtr/Makefile +++ /dev/null @@ -1,96 +0,0 @@ -# $Id: Makefile,v 1.2 1994/10/03 23:30:34 fabio Exp fabio $ -# -# mtr - multiway-branching tree package -#--------------------------- -.SUFFIXES: .o .c .u - -CC = cc -RANLIB = ranlib -PURE = -# Define EXE as .exe for MS-DOS and derivatives. -EXE = -#EXE = .exe - -MFLAG = -ICFLAGS = -g -CFLAGS = $(ICFLAGS) $(MFLAG) $(XCFLAGS) -MTRDEBUG = -DMTR_STATS -DMTR_VERBOSE -DMTR_DEBUG - -LINTFLAGS = -u -n -DMTR_STATS -DMTR_VERBOSE -DMTR_DEBUG - -# this is to create the lint library -LINTSWITCH = -o - -LDFLAGS = - -WHERE = .. - -INCLUDE = $(WHERE)/include - -P = mtr -PSRC = mtrBasic.c mtrGroup.c -PHDR = mtr.h -POBJ = $(PSRC:.c=.o) -PUBJ = $(PSRC:.c=.u) -SRC = test$(P).c -HDR = -OBJ = $(SRC:.c=.o) -UBJ = $(SRC:.c=.u) -TARGET = test$(P)$(EXE) -TARGETu = test$(P)-u - -LIBS = ./libmtr.a $(WHERE)/util/libutil.a - -BLIBS = -kL. -klmtr -kL$(WHERE)/util -klutil - -MNEMLIB = - -LINTLIBS = llib-l$(P).ln - -#--------------------------- - -lib$(P).a: $(POBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.o: $(PSRC) $(PHDR) - $(CC) -c $< -I$(INCLUDE) $(CFLAGS) $(MTRDEBUG) - -optimize_dec: lib$(P).b - -lib$(P).b: $(PUBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.u: $(PSRC) $(PHDR) - cc -j $< -I$(INCLUDE) $(XCFLAGS) - -# if the header files change, recompile -$(POBJ): $(PHDR) -$(PUBJ): $(PHDR) -$(OBJ): $(PHDR) -$(UBJ): $(PHDR) - -lint: llib-l$(P).ln - -llib-l$(P).ln: $(PSRC) $(PHDR) - lint $(LINTFLAGS) $(LINTSWITCH)$(P) -I$(INCLUDE) $(PSRC) - -tags: $(PSRC) $(PHDR) - ctags $(PSRC) $(PHDR) - -all: lib$(P).a lib$(P).b llib-l$(P).ln tags - -$(TARGET): $(POBJ) $(OBJ) $(LIBS) $(MNEMLIB) - $(PURE) $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJ) $(LIBS) $(MNEMLIB) -lm - -$(TARGETu): $(SRC) $(PSRC) $(PHDR) $(UBJ) $(PUBJ) $(LIBS:.a=.b) - cc -O3 $(XCFLAGS) $(LDFLAGS) -o $@ $(UBJ) $(BLIBS) -lm - -clean: - rm -f *.o *.u mon.out gmon.out *.pixie *.Addrs *.Counts mnem.* \ - .pure core *.warnings - -distclean: clean - rm -f $(TARGET) $(TARGETu) lib*.a lib$(P).b llib-l$(P).ln \ - *.bak *~ tags *.qv *.qx diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/Makefile.sis b/resources/3rdparty/cudd-2.5.0/src/mtr/Makefile.sis deleted file mode 100644 index d920cabf7..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/mtr/Makefile.sis +++ /dev/null @@ -1,83 +0,0 @@ -# $Id$ -# -# Cudd - DD package -#--------------------------- -.SUFFIXES: .o .c .u - -RANLIB = ranlib - -CAD = /projects/octtools/octtools/$(MACHINE) -SIS = .. -LINTCREATEFLAG = -C - -# files for the package -P = mtr -PSRC = mtrBasic.c mtrGroup.c -PHDR = mtr.h -POBJ = $(PSRC:.c=.o) - -# files for the test program -TARGET = test$(P) -SRC = test$(P).c -OBJ = $(SRC:.c=.o) -HDR = - -LIBS = ../util/libutil.a -LINTLIBS= ../util/llib-lutil.ln -INCLUDE = -I$(CAD)/include -I$(SIS)/include - -CFLAGS = -g $(INCLUDE) -LDFLAGS = -g -LINTFLAGS = $(INCLUDE) ${LINTEXTRAS} - -#------------------------------------------------------ - -$(TARGET): $(PHDR) $(OBJ) $(POBJ) $(LIBS) - $(CC) $(LDFLAGS) -o $(TARGET) $(OBJ) $(POBJ) $(LIBS) - -lint: $(PSRC) $(PHDR) $(SRC) $(HDR) - lint $(LINTFLAGS) $(SRC) $(PSRC) $(LINTLIBS) - -install: lib$(P).a llib-l$(P).ln - -lib$(P).a: $(POBJ) - ar cr $@ $? - $(RANLIB) $@ - -unpack: lib$(P).a - @for i in $(POBJ); do \ - ln -s $(SIS)/$(P)/$$i $(SIS)/unpack; \ - done - -llib-l$(P).ln: $(PSRC) $(PHDR) - lint $(LINTFLAGS) ${LINTCREATEFLAG}$(P) -n $(PSRC) - -clean: - rm -f $(TARGET) *.a *.ln *.o \ - [Tt]ags [Mm]ake.out lint malloc.out gmon.out __.SYMDEF - -tags: _force - @for i in $(PSRC) $(PHDR); do \ - cwd=`pwd`; ctags -a $$cwd/$$i; - done; - -strip_depend: - sed '/^#--DO NOT CHANGE ANYTHING AFTER THIS LINE/,$$d' Makefile >mktemp - mv mktemp Makefile - -depend: - sed '/^#--DO NOT CHANGE ANYTHING AFTER THIS LINE/,$$d' Makefile >mktemp - echo '#--DO NOT CHANGE ANYTHING AFTER THIS LINE' >>mktemp - $(CAD)/bin/cc-M $(CFLAGS) $(PSRC) | \ - sed 's|$(CAD)|$$(CAD)|g' | \ - grep -v '/usr/include' >>mktemp - mv mktemp Makefile - -#-------------------------- IBM 3090 support ----------------- -IBMHOST = opua -IBMDIST = /users2/sis -ibmdist: $(PSRC) $(PHDR) - rdist -Richw $(PSRC) $(PHDR) $(IBMHOST):$(IBMDIST) -#------------------------------------------------------------- -_force: - diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtr.doc b/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtr.doc deleted file mode 100644 index 2815d2948..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtr.doc +++ /dev/null @@ -1,252 +0,0 @@ -The mtr package - -Multiway-branch tree manipulation - -Fabio Somenzi - -********************************************************************** - -Mtr_AllocNode() Allocates new tree node. - -Mtr_CopyTree() Makes a copy of tree. - -Mtr_CreateFirstChild() Creates a new node and makes it the first child - of parent. - -Mtr_CreateLastChild() Creates a new node and makes it the last child - of parent. - -Mtr_DeallocNode() Deallocates tree node. - -Mtr_DissolveGroup() Merges the children of `group' with the - children of its parent. - -Mtr_FindGroup() Finds a group with size leaves starting at low, - if it exists. - -Mtr_FreeTree() Disposes of tree rooted at node. - -Mtr_InitGroupTree() Allocate new tree. - -Mtr_InitTree() Initializes tree with one node. - -Mtr_MakeFirstChild() Makes child the first child of parent. - -Mtr_MakeGroup() Makes a new group with size leaves starting at - low. - -Mtr_MakeLastChild() Makes child the last child of parent. - -Mtr_MakeNextSibling() Makes second the next sibling of first. - -Mtr_PrintGroups() Prints the groups as a parenthesized list. - -Mtr_PrintTree() Prints a tree, one node per line. - -Mtr_ReadGroups() Reads groups from a file and creates a group - tree. - -Mtr_SwapGroups() Swaps two children of a tree node. - -********************************************************************** - -This package provides two layers of functions. Functions of the lower level -manipulate multiway-branch trees, implemented according to the classical -scheme whereby each node points to its first child and its previous and -next siblings. These functions are collected in mtrBasic.c. Functions -of the upper layer deal with group trees, that is the trees used by group -sifting to represent the grouping of variables. These functions are -collected in mtrGroup.c. - -MtrNode * -Mtr_AllocNode( - -) - Allocates new tree node. Returns pointer to node. - - Side Effects: None - -MtrNode * -Mtr_CopyTree( - MtrNode * node, - int expansion -) - Makes a copy of tree. If parameter expansion is greater than 1, it will - expand the tree by that factor. It is an error for expansion to be less than - 1. Returns a pointer to the copy if successful; NULL otherwise. - - Side Effects: None - -MtrNode * -Mtr_CreateFirstChild( - MtrNode * parent -) - Creates a new node and makes it the first child of parent. Returns pointer - to new child. - - Side Effects: None - -MtrNode * -Mtr_CreateLastChild( - MtrNode * parent -) - Creates a new node and makes it the last child of parent. Returns pointer to - new child. - - Side Effects: None - -void -Mtr_DeallocNode( - MtrNode * node node to be deallocated -) - Deallocates tree node. - - Side Effects: None - -MtrNode * -Mtr_DissolveGroup( - MtrNode * group group to be dissolved -) - Merges the children of `group' with the children of its parent. Disposes of - the node pointed by group. If group is the root of the group tree, this - procedure leaves the tree unchanged. Returns the pointer to the parent of - `group' upon successful termination; NULL otherwise. - - Side Effects: None - -MtrNode * -Mtr_FindGroup( - MtrNode * root, root of the group tree - unsigned int low, lower bound of the group - unsigned int size upper bound of the group -) - Finds a group with size leaves starting at low, if it exists. This procedure - relies on the low and size fields of each node. It also assumes that the - children of each node are sorted in order of increasing low. Returns the - pointer to the root of the group upon successful termination; NULL - otherwise. - - Side Effects: None - -void -Mtr_FreeTree( - MtrNode * node -) - Disposes of tree rooted at node. - - Side Effects: None - -MtrNode * -Mtr_InitGroupTree( - int lower, - int size -) - Allocate new tree with one node, whose low and size fields are specified by - the lower and size parameters. Returns pointer to tree root. - - Side Effects: None - -MtrNode * -Mtr_InitTree( - -) - Initializes tree with one node. Returns pointer to node. - - Side Effects: None - -void -Mtr_MakeFirstChild( - MtrNode * parent, - MtrNode * child -) - Makes child the first child of parent. - - Side Effects: None - -MtrNode * -Mtr_MakeGroup( - MtrNode * root, root of the group tree - unsigned int low, lower bound of the group - unsigned int size, upper bound of the group - unsigned int flags flags for the new group -) - Makes a new group with size leaves starting at low. If the new group - intersects an existing group, it must either contain it or be contained by - it. This procedure relies on the low and size fields of each node. It also - assumes that the children of each node are sorted in order of increasing - low. In case of a valid request, the flags of the new group are set to the - value passed in `flags.' This can also be used to change the flags of an - existing group. Returns the pointer to the root of the new group upon - successful termination; NULL otherwise. If the group already exists, the - pointer to its root is returned. - - Side Effects: None - -void -Mtr_MakeLastChild( - MtrNode * parent, - MtrNode * child -) - Makes child the last child of parent. - - Side Effects: None - -void -Mtr_MakeNextSibling( - MtrNode * first, - MtrNode * second -) - Makes second the next sibling of first. Second becomes a child of the parent - of first. - - Side Effects: None - -void -Mtr_PrintGroups( - MtrNode * root, root of the group tree - int silent flag to check tree syntax only -) - Prints the groups as a parenthesized list. After each group, the group's - flag are printed, preceded by a `|'. For each flag (except MTR_TERMINAL) a - character is printed. F: MTR_FIXED N: MTR_NEWNODE S: - MTR_SOFT The second argument, silent, if different from 0, causes - Mtr_PrintGroups to only check the syntax of the group tree. - - Side Effects: None - -void -Mtr_PrintTree( - MtrNode * node -) - Prints a tree, one node per line. - - Side Effects: None - -MtrNode * -Mtr_ReadGroups( - FILE * fp, file pointer - int nleaves number of leaves of the new tree -) - Reads groups from a file and creates a group tree. Each group is specified - by three fields: low size flags. Low and size are (short) - integers. Flags is a string composed of the following characters (with - associated translation): D: MTR_DEFAULT F: MTR_FIXED N: - MTR_NEWNODE S: MTR_SOFT T: MTR_TERMINAL Normally, the only - flags that are needed are D and F. Groups and fields are separated by white - space (spaces, tabs, and newlines). Returns a pointer to the group tree if - successful; NULL otherwise. - - Side Effects: None - -int -Mtr_SwapGroups( - MtrNode * first, first node to be swapped - MtrNode * second second node to be swapped -) - Swaps two children of a tree node. Adjusts the high and low fields of the - two nodes and their descendants. The two children must be adjacent. However, - first may be the younger sibling of second. Returns 1 in case of success; 0 - otherwise. - - Side Effects: None - diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrAllAbs.html b/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrAllAbs.html deleted file mode 100644 index 9a59faada..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrAllAbs.html +++ /dev/null @@ -1,72 +0,0 @@ -<html> -<head><title>mtr package abstract (Internal)</title></head> -<body> - -<h1>mtr package abstract (Internal)</h1> -<h2>Internal data structures of the mtr package</h2> -<hr> - -<!-- Function Abstracts --> - -<dl> -<dt> <a href="mtrAllDet.html#Mtr_AllocNode"><code>Mtr_AllocNode()</code></a> -<dd> Allocates new tree node. - -<dt> <a href="mtrAllDet.html#Mtr_CopyTree"><code>Mtr_CopyTree()</code></a> -<dd> Makes a copy of tree. - -<dt> <a href="mtrAllDet.html#Mtr_CreateFirstChild"><code>Mtr_CreateFirstChild()</code></a> -<dd> Creates a new node and makes it the first child of parent. - -<dt> <a href="mtrAllDet.html#Mtr_CreateLastChild"><code>Mtr_CreateLastChild()</code></a> -<dd> Creates a new node and makes it the last child of parent. - -<dt> <a href="mtrAllDet.html#Mtr_DeallocNode"><code>Mtr_DeallocNode()</code></a> -<dd> Deallocates tree node. - -<dt> <a href="mtrAllDet.html#Mtr_DissolveGroup"><code>Mtr_DissolveGroup()</code></a> -<dd> Merges the children of `group' with the children of its parent. - -<dt> <a href="mtrAllDet.html#Mtr_FindGroup"><code>Mtr_FindGroup()</code></a> -<dd> Finds a group with size leaves starting at low, if it exists. - -<dt> <a href="mtrAllDet.html#Mtr_FreeTree"><code>Mtr_FreeTree()</code></a> -<dd> Disposes of tree rooted at node. - -<dt> <a href="mtrAllDet.html#Mtr_InitGroupTree"><code>Mtr_InitGroupTree()</code></a> -<dd> Allocate new tree. - -<dt> <a href="mtrAllDet.html#Mtr_InitTree"><code>Mtr_InitTree()</code></a> -<dd> Initializes tree with one node. - -<dt> <a href="mtrAllDet.html#Mtr_MakeFirstChild"><code>Mtr_MakeFirstChild()</code></a> -<dd> Makes child the first child of parent. - -<dt> <a href="mtrAllDet.html#Mtr_MakeGroup"><code>Mtr_MakeGroup()</code></a> -<dd> Makes a new group with size leaves starting at low. - -<dt> <a href="mtrAllDet.html#Mtr_MakeLastChild"><code>Mtr_MakeLastChild()</code></a> -<dd> Makes child the last child of parent. - -<dt> <a href="mtrAllDet.html#Mtr_MakeNextSibling"><code>Mtr_MakeNextSibling()</code></a> -<dd> Makes second the next sibling of first. - -<dt> <a href="mtrAllDet.html#Mtr_PrintGroups"><code>Mtr_PrintGroups()</code></a> -<dd> Prints the groups as a parenthesized list. - -<dt> <a href="mtrAllDet.html#Mtr_PrintTree"><code>Mtr_PrintTree()</code></a> -<dd> Prints a tree, one node per line. - -<dt> <a href="mtrAllDet.html#Mtr_ReadGroups"><code>Mtr_ReadGroups()</code></a> -<dd> Reads groups from a file and creates a group tree. - -<dt> <a href="mtrAllDet.html#Mtr_SwapGroups"><code>Mtr_SwapGroups()</code></a> -<dd> Swaps two children of a tree node. - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 970123 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrAllDet.html b/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrAllDet.html deleted file mode 100644 index e7b789074..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrAllDet.html +++ /dev/null @@ -1,317 +0,0 @@ -<html> -<head><title>The mtr package (Internal) </title></head> -<body> - -<h1>The mtr package (Internal) </h1> -<h2>Internal data structures of the mtr package</h2> -<h3></h3> -<hr> -<ul> -<li><a href="mtrExtAbs.html"><h3>External abstracts</h3></a> -<li><a href="mtrAllAbs.html"><h3>All abstracts</h3></a> -<li><a href="mtrExtDet.html#prototypes"><h3>External functions</h3></a> -<li><a href="mtrAllDet.html#prototypes"><h3>All functions</h3></a> -</ul> - -<hr> - -<a name="description"> -In this package all definitions are external. -</a> - -<hr> -<!-- Function Prototypes and description --> - -<dl> -<a name="prototypes"></a> -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_AllocNode"><b>Mtr_AllocNode</b></a>( - <b></b> <i></i> -) -</pre> -<dd> Allocates new tree node. Returns pointer to node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_DeallocNode">Mtr_DeallocNode</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_CopyTree"><b>Mtr_CopyTree</b></a>( - MtrNode * <b>node</b>, <i></i> - int <b>expansion</b> <i></i> -) -</pre> -<dd> Makes a copy of tree. If parameter expansion is greater than 1, it will expand the tree by that factor. It is an error for expansion to be less than 1. Returns a pointer to the copy if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_InitTree">Mtr_InitTree</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_CreateFirstChild"><b>Mtr_CreateFirstChild</b></a>( - MtrNode * <b>parent</b> <i></i> -) -</pre> -<dd> Creates a new node and makes it the first child of parent. Returns pointer to new child. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_MakeFirstChild">Mtr_MakeFirstChild</a> -<a href="mtrAllDet.html#Mtr_CreateLastChild">Mtr_CreateLastChild</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_CreateLastChild"><b>Mtr_CreateLastChild</b></a>( - MtrNode * <b>parent</b> <i></i> -) -</pre> -<dd> Creates a new node and makes it the last child of parent. Returns pointer to new child. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_MakeLastChild">Mtr_MakeLastChild</a> -<a href="mtrAllDet.html#Mtr_CreateFirstChild">Mtr_CreateFirstChild</a> -</code> - -<dt><pre> -void <i></i> -<a name="Mtr_DeallocNode"><b>Mtr_DeallocNode</b></a>( - MtrNode * <b>node</b> <i>node to be deallocated</i> -) -</pre> -<dd> Deallocates tree node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_AllocNode">Mtr_AllocNode</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_DissolveGroup"><b>Mtr_DissolveGroup</b></a>( - MtrNode * <b>group</b> <i>group to be dissolved</i> -) -</pre> -<dd> Merges the children of `group' with the children of its parent. Disposes of the node pointed by group. If group is the root of the group tree, this procedure leaves the tree unchanged. Returns the pointer to the parent of `group' upon successful termination; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_MakeGroup">Mtr_MakeGroup</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_FindGroup"><b>Mtr_FindGroup</b></a>( - MtrNode * <b>root</b>, <i>root of the group tree</i> - unsigned int <b>low</b>, <i>lower bound of the group</i> - unsigned int <b>size</b> <i>upper bound of the group</i> -) -</pre> -<dd> Finds a group with size leaves starting at low, if it exists. This procedure relies on the low and size fields of each node. It also assumes that the children of each node are sorted in order of increasing low. Returns the pointer to the root of the group upon successful termination; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -void <i></i> -<a name="Mtr_FreeTree"><b>Mtr_FreeTree</b></a>( - MtrNode * <b>node</b> <i></i> -) -</pre> -<dd> Disposes of tree rooted at node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_InitTree">Mtr_InitTree</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_InitGroupTree"><b>Mtr_InitGroupTree</b></a>( - int <b>lower</b>, <i></i> - int <b>size</b> <i></i> -) -</pre> -<dd> Allocate new tree with one node, whose low and size fields are specified by the lower and size parameters. Returns pointer to tree root. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_InitTree">Mtr_InitTree</a> -<a href="mtrAllDet.html#Mtr_FreeTree">Mtr_FreeTree</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_InitTree"><b>Mtr_InitTree</b></a>( - <b></b> <i></i> -) -</pre> -<dd> Initializes tree with one node. Returns pointer to node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_FreeTree">Mtr_FreeTree</a> -<a href="mtrAllDet.html#Mtr_InitGroupTree">Mtr_InitGroupTree</a> -</code> - -<dt><pre> -void <i></i> -<a name="Mtr_MakeFirstChild"><b>Mtr_MakeFirstChild</b></a>( - MtrNode * <b>parent</b>, <i></i> - MtrNode * <b>child</b> <i></i> -) -</pre> -<dd> Makes child the first child of parent. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_MakeLastChild">Mtr_MakeLastChild</a> -<a href="mtrAllDet.html#Mtr_CreateFirstChild">Mtr_CreateFirstChild</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_MakeGroup"><b>Mtr_MakeGroup</b></a>( - MtrNode * <b>root</b>, <i>root of the group tree</i> - unsigned int <b>low</b>, <i>lower bound of the group</i> - unsigned int <b>size</b>, <i>upper bound of the group</i> - unsigned int <b>flags</b> <i>flags for the new group</i> -) -</pre> -<dd> Makes a new group with size leaves starting at low. If the new group intersects an existing group, it must either contain it or be contained by it. This procedure relies on the low and size fields of each node. It also assumes that the children of each node are sorted in order of increasing low. In case of a valid request, the flags of the new group are set to the value passed in `flags.' This can also be used to change the flags of an existing group. Returns the pointer to the root of the new group upon successful termination; NULL otherwise. If the group already exists, the pointer to its root is returned. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_DissolveGroup">Mtr_DissolveGroup</a> -<a href="mtrAllDet.html#Mtr_ReadGroups">Mtr_ReadGroups</a> -<a href="mtrAllDet.html#Mtr_FindGroup">Mtr_FindGroup</a> -</code> - -<dt><pre> -void <i></i> -<a name="Mtr_MakeLastChild"><b>Mtr_MakeLastChild</b></a>( - MtrNode * <b>parent</b>, <i></i> - MtrNode * <b>child</b> <i></i> -) -</pre> -<dd> Makes child the last child of parent. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_MakeFirstChild">Mtr_MakeFirstChild</a> -<a href="mtrAllDet.html#Mtr_CreateLastChild">Mtr_CreateLastChild</a> -</code> - -<dt><pre> -void <i></i> -<a name="Mtr_MakeNextSibling"><b>Mtr_MakeNextSibling</b></a>( - MtrNode * <b>first</b>, <i></i> - MtrNode * <b>second</b> <i></i> -) -</pre> -<dd> Makes second the next sibling of first. Second becomes a child of the parent of first. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -void <i></i> -<a name="Mtr_PrintGroups"><b>Mtr_PrintGroups</b></a>( - MtrNode * <b>root</b>, <i>root of the group tree</i> - int <b>silent</b> <i>flag to check tree syntax only</i> -) -</pre> -<dd> Prints the groups as a parenthesized list. After each group, the group's flag are printed, preceded by a `|'. For each flag (except MTR_TERMINAL) a character is printed. <ul> <li>F: MTR_FIXED <li>N: MTR_NEWNODE <li>S: MTR_SOFT </ul> The second argument, silent, if different from 0, causes Mtr_PrintGroups to only check the syntax of the group tree. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_PrintTree">Mtr_PrintTree</a> -</code> - -<dt><pre> -void <i></i> -<a name="Mtr_PrintTree"><b>Mtr_PrintTree</b></a>( - MtrNode * <b>node</b> <i></i> -) -</pre> -<dd> Prints a tree, one node per line. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_PrintGroups">Mtr_PrintGroups</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_ReadGroups"><b>Mtr_ReadGroups</b></a>( - FILE * <b>fp</b>, <i>file pointer</i> - int <b>nleaves</b> <i>number of leaves of the new tree</i> -) -</pre> -<dd> Reads groups from a file and creates a group tree. Each group is specified by three fields: <xmp> low size flags. </xmp> Low and size are (short) integers. Flags is a string composed of the following characters (with associated translation): <ul> <li>D: MTR_DEFAULT <li>F: MTR_FIXED <li>N: MTR_NEWNODE <li>S: MTR_SOFT <li>T: MTR_TERMINAL </ul> Normally, the only flags that are needed are D and F. Groups and fields are separated by white space (spaces, tabs, and newlines). Returns a pointer to the group tree if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_InitGroupTree">Mtr_InitGroupTree</a> -<a href="mtrAllDet.html#Mtr_MakeGroup">Mtr_MakeGroup</a> -</code> - -<dt><pre> -int <i></i> -<a name="Mtr_SwapGroups"><b>Mtr_SwapGroups</b></a>( - MtrNode * <b>first</b>, <i>first node to be swapped</i> - MtrNode * <b>second</b> <i>second node to be swapped</i> -) -</pre> -<dd> Swaps two children of a tree node. Adjusts the high and low fields of the two nodes and their descendants. The two children must be adjacent. However, first may be the younger sibling of second. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 970123 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrExtAbs.html b/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrExtAbs.html deleted file mode 100644 index 9f48acbad..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrExtAbs.html +++ /dev/null @@ -1,72 +0,0 @@ -<html> -<head><title>mtr package abstract</title></head> -<body> - -<h1>mtr package abstract</h1> -<h2>Multiway-branch tree manipulation</h2> -<hr> - -<!-- Function Abstracts --> - -<dl> -<dt> <a href="mtrExtDet.html#Mtr_AllocNode"><code>Mtr_AllocNode()</code></a> -<dd> Allocates new tree node. - -<dt> <a href="mtrExtDet.html#Mtr_CopyTree"><code>Mtr_CopyTree()</code></a> -<dd> Makes a copy of tree. - -<dt> <a href="mtrExtDet.html#Mtr_CreateFirstChild"><code>Mtr_CreateFirstChild()</code></a> -<dd> Creates a new node and makes it the first child of parent. - -<dt> <a href="mtrExtDet.html#Mtr_CreateLastChild"><code>Mtr_CreateLastChild()</code></a> -<dd> Creates a new node and makes it the last child of parent. - -<dt> <a href="mtrExtDet.html#Mtr_DeallocNode"><code>Mtr_DeallocNode()</code></a> -<dd> Deallocates tree node. - -<dt> <a href="mtrExtDet.html#Mtr_DissolveGroup"><code>Mtr_DissolveGroup()</code></a> -<dd> Merges the children of `group' with the children of its parent. - -<dt> <a href="mtrExtDet.html#Mtr_FindGroup"><code>Mtr_FindGroup()</code></a> -<dd> Finds a group with size leaves starting at low, if it exists. - -<dt> <a href="mtrExtDet.html#Mtr_FreeTree"><code>Mtr_FreeTree()</code></a> -<dd> Disposes of tree rooted at node. - -<dt> <a href="mtrExtDet.html#Mtr_InitGroupTree"><code>Mtr_InitGroupTree()</code></a> -<dd> Allocate new tree. - -<dt> <a href="mtrExtDet.html#Mtr_InitTree"><code>Mtr_InitTree()</code></a> -<dd> Initializes tree with one node. - -<dt> <a href="mtrExtDet.html#Mtr_MakeFirstChild"><code>Mtr_MakeFirstChild()</code></a> -<dd> Makes child the first child of parent. - -<dt> <a href="mtrExtDet.html#Mtr_MakeGroup"><code>Mtr_MakeGroup()</code></a> -<dd> Makes a new group with size leaves starting at low. - -<dt> <a href="mtrExtDet.html#Mtr_MakeLastChild"><code>Mtr_MakeLastChild()</code></a> -<dd> Makes child the last child of parent. - -<dt> <a href="mtrExtDet.html#Mtr_MakeNextSibling"><code>Mtr_MakeNextSibling()</code></a> -<dd> Makes second the next sibling of first. - -<dt> <a href="mtrExtDet.html#Mtr_PrintGroups"><code>Mtr_PrintGroups()</code></a> -<dd> Prints the groups as a parenthesized list. - -<dt> <a href="mtrExtDet.html#Mtr_PrintTree"><code>Mtr_PrintTree()</code></a> -<dd> Prints a tree, one node per line. - -<dt> <a href="mtrExtDet.html#Mtr_ReadGroups"><code>Mtr_ReadGroups()</code></a> -<dd> Reads groups from a file and creates a group tree. - -<dt> <a href="mtrExtDet.html#Mtr_SwapGroups"><code>Mtr_SwapGroups()</code></a> -<dd> Swaps two children of a tree node. - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 970123 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrExtDet.html b/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrExtDet.html deleted file mode 100644 index 8300c3d6a..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/mtr/doc/mtrExtDet.html +++ /dev/null @@ -1,324 +0,0 @@ -<html> -<head><title>The mtr package</title></head> -<body> - -<h1>The mtr package</h1> -<h2>Multiway-branch tree manipulation</h2> -<h3></h3> -<hr> -<ul> -<li><a href="mtrExtAbs.html"><h3>External abstracts</h3></a> -<li><a href="mtrAllAbs.html"><h3>All abstracts</h3></a> -<li><a href="mtrExtDet.html#prototypes"><h3>External functions</h3></a> -<li><a href="mtrAllDet.html#prototypes"><h3>All functions</h3></a> -</ul> - -<hr> - -<a name="description"> -This package provides two layers of functions. Functions - of the lower level manipulate multiway-branch trees, implemented - according to the classical scheme whereby each node points to its - first child and its previous and next siblings. These functions are - collected in mtrBasic.c.<p> - Functions of the upper layer deal with group trees, that is the trees - used by group sifting to represent the grouping of variables. These - functions are collected in mtrGroup.c. -</a> - -<hr> -<!-- Function Prototypes and description --> - -<dl> -<a name="prototypes"></a> -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_AllocNode"><b>Mtr_AllocNode</b></a>( - <b></b> <i></i> -) -</pre> -<dd> Allocates new tree node. Returns pointer to node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_DeallocNode">Mtr_DeallocNode</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_CopyTree"><b>Mtr_CopyTree</b></a>( - MtrNode * <b>node</b>, <i></i> - int <b>expansion</b> <i></i> -) -</pre> -<dd> Makes a copy of tree. If parameter expansion is greater than 1, it will expand the tree by that factor. It is an error for expansion to be less than 1. Returns a pointer to the copy if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_InitTree">Mtr_InitTree</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_CreateFirstChild"><b>Mtr_CreateFirstChild</b></a>( - MtrNode * <b>parent</b> <i></i> -) -</pre> -<dd> Creates a new node and makes it the first child of parent. Returns pointer to new child. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_MakeFirstChild">Mtr_MakeFirstChild</a> -<a href="mtrAllDet.html#Mtr_CreateLastChild">Mtr_CreateLastChild</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_CreateLastChild"><b>Mtr_CreateLastChild</b></a>( - MtrNode * <b>parent</b> <i></i> -) -</pre> -<dd> Creates a new node and makes it the last child of parent. Returns pointer to new child. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_MakeLastChild">Mtr_MakeLastChild</a> -<a href="mtrAllDet.html#Mtr_CreateFirstChild">Mtr_CreateFirstChild</a> -</code> - -<dt><pre> -void <i></i> -<a name="Mtr_DeallocNode"><b>Mtr_DeallocNode</b></a>( - MtrNode * <b>node</b> <i>node to be deallocated</i> -) -</pre> -<dd> Deallocates tree node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_AllocNode">Mtr_AllocNode</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_DissolveGroup"><b>Mtr_DissolveGroup</b></a>( - MtrNode * <b>group</b> <i>group to be dissolved</i> -) -</pre> -<dd> Merges the children of `group' with the children of its parent. Disposes of the node pointed by group. If group is the root of the group tree, this procedure leaves the tree unchanged. Returns the pointer to the parent of `group' upon successful termination; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_MakeGroup">Mtr_MakeGroup</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_FindGroup"><b>Mtr_FindGroup</b></a>( - MtrNode * <b>root</b>, <i>root of the group tree</i> - unsigned int <b>low</b>, <i>lower bound of the group</i> - unsigned int <b>size</b> <i>upper bound of the group</i> -) -</pre> -<dd> Finds a group with size leaves starting at low, if it exists. This procedure relies on the low and size fields of each node. It also assumes that the children of each node are sorted in order of increasing low. Returns the pointer to the root of the group upon successful termination; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -void <i></i> -<a name="Mtr_FreeTree"><b>Mtr_FreeTree</b></a>( - MtrNode * <b>node</b> <i></i> -) -</pre> -<dd> Disposes of tree rooted at node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_InitTree">Mtr_InitTree</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_InitGroupTree"><b>Mtr_InitGroupTree</b></a>( - int <b>lower</b>, <i></i> - int <b>size</b> <i></i> -) -</pre> -<dd> Allocate new tree with one node, whose low and size fields are specified by the lower and size parameters. Returns pointer to tree root. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_InitTree">Mtr_InitTree</a> -<a href="mtrAllDet.html#Mtr_FreeTree">Mtr_FreeTree</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_InitTree"><b>Mtr_InitTree</b></a>( - <b></b> <i></i> -) -</pre> -<dd> Initializes tree with one node. Returns pointer to node. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_FreeTree">Mtr_FreeTree</a> -<a href="mtrAllDet.html#Mtr_InitGroupTree">Mtr_InitGroupTree</a> -</code> - -<dt><pre> -void <i></i> -<a name="Mtr_MakeFirstChild"><b>Mtr_MakeFirstChild</b></a>( - MtrNode * <b>parent</b>, <i></i> - MtrNode * <b>child</b> <i></i> -) -</pre> -<dd> Makes child the first child of parent. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_MakeLastChild">Mtr_MakeLastChild</a> -<a href="mtrAllDet.html#Mtr_CreateFirstChild">Mtr_CreateFirstChild</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_MakeGroup"><b>Mtr_MakeGroup</b></a>( - MtrNode * <b>root</b>, <i>root of the group tree</i> - unsigned int <b>low</b>, <i>lower bound of the group</i> - unsigned int <b>size</b>, <i>upper bound of the group</i> - unsigned int <b>flags</b> <i>flags for the new group</i> -) -</pre> -<dd> Makes a new group with size leaves starting at low. If the new group intersects an existing group, it must either contain it or be contained by it. This procedure relies on the low and size fields of each node. It also assumes that the children of each node are sorted in order of increasing low. In case of a valid request, the flags of the new group are set to the value passed in `flags.' This can also be used to change the flags of an existing group. Returns the pointer to the root of the new group upon successful termination; NULL otherwise. If the group already exists, the pointer to its root is returned. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_DissolveGroup">Mtr_DissolveGroup</a> -<a href="mtrAllDet.html#Mtr_ReadGroups">Mtr_ReadGroups</a> -<a href="mtrAllDet.html#Mtr_FindGroup">Mtr_FindGroup</a> -</code> - -<dt><pre> -void <i></i> -<a name="Mtr_MakeLastChild"><b>Mtr_MakeLastChild</b></a>( - MtrNode * <b>parent</b>, <i></i> - MtrNode * <b>child</b> <i></i> -) -</pre> -<dd> Makes child the last child of parent. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_MakeFirstChild">Mtr_MakeFirstChild</a> -<a href="mtrAllDet.html#Mtr_CreateLastChild">Mtr_CreateLastChild</a> -</code> - -<dt><pre> -void <i></i> -<a name="Mtr_MakeNextSibling"><b>Mtr_MakeNextSibling</b></a>( - MtrNode * <b>first</b>, <i></i> - MtrNode * <b>second</b> <i></i> -) -</pre> -<dd> Makes second the next sibling of first. Second becomes a child of the parent of first. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -void <i></i> -<a name="Mtr_PrintGroups"><b>Mtr_PrintGroups</b></a>( - MtrNode * <b>root</b>, <i>root of the group tree</i> - int <b>silent</b> <i>flag to check tree syntax only</i> -) -</pre> -<dd> Prints the groups as a parenthesized list. After each group, the group's flag are printed, preceded by a `|'. For each flag (except MTR_TERMINAL) a character is printed. <ul> <li>F: MTR_FIXED <li>N: MTR_NEWNODE <li>S: MTR_SOFT </ul> The second argument, silent, if different from 0, causes Mtr_PrintGroups to only check the syntax of the group tree. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_PrintTree">Mtr_PrintTree</a> -</code> - -<dt><pre> -void <i></i> -<a name="Mtr_PrintTree"><b>Mtr_PrintTree</b></a>( - MtrNode * <b>node</b> <i></i> -) -</pre> -<dd> Prints a tree, one node per line. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_PrintGroups">Mtr_PrintGroups</a> -</code> - -<dt><pre> -MtrNode * <i></i> -<a name="Mtr_ReadGroups"><b>Mtr_ReadGroups</b></a>( - FILE * <b>fp</b>, <i>file pointer</i> - int <b>nleaves</b> <i>number of leaves of the new tree</i> -) -</pre> -<dd> Reads groups from a file and creates a group tree. Each group is specified by three fields: <xmp> low size flags. </xmp> Low and size are (short) integers. Flags is a string composed of the following characters (with associated translation): <ul> <li>D: MTR_DEFAULT <li>F: MTR_FIXED <li>N: MTR_NEWNODE <li>S: MTR_SOFT <li>T: MTR_TERMINAL </ul> Normally, the only flags that are needed are D and F. Groups and fields are separated by white space (spaces, tabs, and newlines). Returns a pointer to the group tree if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="mtrAllDet.html#Mtr_InitGroupTree">Mtr_InitGroupTree</a> -<a href="mtrAllDet.html#Mtr_MakeGroup">Mtr_MakeGroup</a> -</code> - -<dt><pre> -int <i></i> -<a name="Mtr_SwapGroups"><b>Mtr_SwapGroups</b></a>( - MtrNode * <b>first</b>, <i>first node to be swapped</i> - MtrNode * <b>second</b> <i>second node to be swapped</i> -) -</pre> -<dd> Swaps two children of a tree node. Adjusts the high and low fields of the two nodes and their descendants. The two children must be adjacent. However, first may be the younger sibling of second. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 970123 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/C17.out b/resources/3rdparty/cudd-2.5.0/src/nanotrav/C17.out deleted file mode 100644 index dd7302744..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/C17.out +++ /dev/null @@ -1,101 +0,0 @@ -# Nanotrav Version #0.12, Release date 2003/12/31 -# ./nanotrav -p 1 -cover C17.blif -# CUDD Version 2.4.2 -Order before final reordering -1GAT(0) 2GAT(1) 3GAT(2) 6GAT(3) 7GAT(4) -22GAT(10): 8 nodes 18 minterms -23GAT(9): 8 nodes 18 minterms -22GAT(10): 5 nodes 3 minterms -Testing iterator on ZDD paths: --1-0- 1 --10-- 1 -1-1-- 1 - -1-1-- 1 --10-- 1 --1-0- 1 -23GAT(9): 6 nodes 4 minterms -Testing iterator on ZDD paths: ----01 1 ---0-1 1 --1-0- 1 --10-- 1 - --10-- 1 --1-0- 1 ---0-1 1 ----01 1 -**** CUDD modifiable parameters **** -Hard limit for cache size: 7645866 -Cache hit threshold for resizing: 30% -Garbage collection enabled: yes -Limit for fast unique table growth: 4587520 -Maximum number of variables sifted per reordering: 1000 -Maximum number of variable swaps per reordering: 2000000 -Maximum growth while sifting a variable: 1.2 -Dynamic reordering of BDDs enabled: no -Default BDD reordering method: 4 -Dynamic reordering of ZDDs enabled: no -Default ZDD reordering method: 4 -Realignment of ZDDs to BDDs enabled: yes -Realignment of BDDs to ZDDs enabled: no -Dead nodes counted in triggering reordering: no -Group checking criterion: 7 -Recombination threshold: 0 -Symmetry violation threshold: 10 -Arc violation threshold: 10 -GA population size: 0 -Number of crossovers for GA: 0 -Next reordering threshold: 4004 -**** CUDD non-modifiable parameters **** -Memory in use: 4737732 -Peak number of nodes: 1022 -Peak number of live nodes: 19 -Number of BDD variables: 5 -Number of ZDD variables: 10 -Number of cache entries: 32768 -Number of cache look-ups: 125 -Number of cache hits: 21 -Number of cache insertions: 117 -Number of cache collisions: 0 -Number of cache deletions: 35 -Cache used slots = 0.33% (expected 0.25%) -Soft limit for cache size: 16384 -Number of buckets in unique table: 4096 -Used buckets in unique table: 1.22% (expected 1.24%) -Number of BDD and ADD nodes: 24 -Number of ZDD nodes: 27 -Number of dead BDD and ADD nodes: 8 -Number of dead ZDD nodes: 17 -Total number of nodes allocated: 67 -Total number of nodes reclaimed: 8 -Garbage collections so far: 1 -Time for garbage collection: 0.00 sec -Reorderings so far: 0 -Time for reordering: 0.00 sec -Final size: 11 -total time = 0.00 sec -Runtime Statistics ------------------- -Machine name: jobim.colorado.edu -User time 0.0 seconds -System time 0.0 seconds - -Average resident text size = 0K -Average resident data+stack size = 0K -Maximum resident size = 0K - -Virtual text size = 131815K -Virtual data size = 297K - data size initialized = 25K - data size uninitialized = 137K - data size sbrk = 135K -Virtual memory limit = 358400K (4194304K) - -Major page faults = 8 -Minor page faults = 1413 -Swaps = 0 -Input blocks = 0 -Output blocks = 0 -Context switch (voluntary) = 12 -Context switch (involuntary) = 0 diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/C880.out b/resources/3rdparty/cudd-2.5.0/src/nanotrav/C880.out deleted file mode 100644 index 71dcb6295..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/C880.out +++ /dev/null @@ -1,101 +0,0 @@ -# Nanotrav Version #0.12, Release date 2003/12/31 -# ./nanotrav -p 1 -ordering dfs -autodyn -automethod sifting -reordering sifting -drop C880.blif -# CUDD Version 2.4.2 -BDD reordering with sifting: from 3974 to ... 2432 nodes in 0.039 sec -BDD reordering with sifting: from 4893 to ... 3549 nodes in 0.044 sec -BDD reordering with sifting: from 7133 to ... 6246 nodes in 0.072 sec -BDD reordering with sifting: from 12522 to ... 6465 nodes in 0.113 sec -Order before final reordering -86GAT(18) 85GAT(17) 90GAT(22) 89GAT(21) 88GAT(20) 87GAT(19) 1GAT(0) 51GAT(8) -75GAT(15) 26GAT(4) 268GAT(59) 36GAT(6) 29GAT(5) 80GAT(16) 59GAT(10) 42GAT(7) -156GAT(39) 17GAT(3) 74GAT(14) 55GAT(9) 8GAT(1) 219GAT(50) 210GAT(49) 91GAT(23) -101GAT(25) 138GAT(33) 96GAT(24) 171GAT(42) 152GAT(37) 146GAT(35) 116GAT(28) 189GAT(45) -149GAT(36) 121GAT(29) 195GAT(46) 153GAT(38) 126GAT(30) 261GAT(57) 201GAT(47) 143GAT(34) -111GAT(27) 183GAT(44) 130GAT(31) 135GAT(32) 106GAT(26) 177GAT(43) 165GAT(41) 207GAT(48) -159GAT(40) 228GAT(51) 237GAT(52) 246GAT(53) 73GAT(13) 72GAT(12) 68GAT(11) 13GAT(2) -260GAT(56) 267GAT(58) 259GAT(55) 255GAT(54) -Number of inputs = 60 -BDD reordering with sifting: from 6204 to ... 4623 nodes in 0.07 sec -New order -135GAT(32) 207GAT(48) 130GAT(31) 86GAT(18) 85GAT(17) 89GAT(21) 90GAT(22) 88GAT(20) -87GAT(19) 1GAT(0) 51GAT(8) 26GAT(4) 268GAT(59) 29GAT(5) 80GAT(16) 59GAT(10) -42GAT(7) 75GAT(15) 156GAT(39) 36GAT(6) 17GAT(3) 74GAT(14) 55GAT(9) 8GAT(1) -210GAT(49) 91GAT(23) 138GAT(33) 165GAT(41) 96GAT(24) 159GAT(40) 101GAT(25) 171GAT(42) -152GAT(37) 149GAT(36) 146GAT(35) 116GAT(28) 189GAT(45) 121GAT(29) 195GAT(46) 153GAT(38) -143GAT(34) 126GAT(30) 201GAT(47) 261GAT(57) 111GAT(27) 106GAT(26) 183GAT(44) 177GAT(43) -219GAT(50) 246GAT(53) 237GAT(52) 228GAT(51) 73GAT(13) 72GAT(12) 68GAT(11) 13GAT(2) -260GAT(56) 267GAT(58) 259GAT(55) 255GAT(54) -**** CUDD modifiable parameters **** -Hard limit for cache size: 7645866 -Cache hit threshold for resizing: 30% -Garbage collection enabled: yes -Limit for fast unique table growth: 4587520 -Maximum number of variables sifted per reordering: 1000000 -Maximum number of variable swaps per reordering: 1000000000 -Maximum growth while sifting a variable: 1.2 -Dynamic reordering of BDDs enabled: yes -Default BDD reordering method: 4 -Dynamic reordering of ZDDs enabled: no -Default ZDD reordering method: 4 -Realignment of ZDDs to BDDs enabled: no -Realignment of BDDs to ZDDs enabled: no -Dead nodes counted in triggering reordering: no -Group checking criterion: 7 -Recombination threshold: 0 -Symmetry violation threshold: 10 -Arc violation threshold: 10 -GA population size: 0 -Number of crossovers for GA: 0 -Next reordering threshold: 9340 -**** CUDD non-modifiable parameters **** -Memory in use: 5611044 -Peak number of nodes: 19418 -Peak number of live nodes: 12568 -Number of BDD variables: 60 -Number of ZDD variables: 0 -Number of cache entries: 65536 -Number of cache look-ups: 59167 -Number of cache hits: 28642 -Number of cache insertions: 30604 -Number of cache collisions: 2547 -Number of cache deletions: 28057 -Cache used slots = 18.04% (expected 0.00%) -Soft limit for cache size: 62464 -Number of buckets in unique table: 15616 -Used buckets in unique table: 20.84% (expected 20.96%) -Number of BDD and ADD nodes: 4671 -Number of ZDD nodes: 0 -Number of dead BDD and ADD nodes: 0 -Number of dead ZDD nodes: 0 -Total number of nodes allocated: 32671 -Total number of nodes reclaimed: 1974 -Garbage collections so far: 5 -Time for garbage collection: 0.00 sec -Reorderings so far: 5 -Time for reordering: 0.34 sec -Final size: 4623 -total time = 0.36 sec -Runtime Statistics ------------------- -Machine name: jobim.colorado.edu -User time 0.4 seconds -System time 0.0 seconds - -Average resident text size = 0K -Average resident data+stack size = 0K -Maximum resident size = 0K - -Virtual text size = 131815K -Virtual data size = 297K - data size initialized = 25K - data size uninitialized = 137K - data size sbrk = 135K -Virtual memory limit = 358400K (4194304K) - -Major page faults = 0 -Minor page faults = 1778 -Swaps = 0 -Input blocks = 0 -Output blocks = 0 -Context switch (voluntary) = 1 -Context switch (involuntary) = 6 diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/Makefile b/resources/3rdparty/cudd-2.5.0/src/nanotrav/Makefile deleted file mode 100644 index b40b547bd..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/Makefile +++ /dev/null @@ -1,98 +0,0 @@ -# $Id: Makefile,v 1.12 1999/08/31 19:10:05 fabio Exp fabio $ -# -# nanotrav: simple FSM traversal program -#--------------------------------------------------------------------------- -.SUFFIXES: .o .c .u - -CC = gcc -#CC = cc -RANLIB = ranlib -#RANLIB = : -PURE = - -EXE = -#EXE = .exe -TARGET = nanotrav$(EXE) -TARGETu = nanotrav-u - -WHERE = .. - -INCLUDE = $(WHERE)/include - -LIBS = $(WHERE)/dddmp/libdddmp.a $(WHERE)/cudd/libcudd.a \ - $(WHERE)/mtr/libmtr.a $(WHERE)/st/libst.a $(WHERE)/util/libutil.a \ - $(WHERE)/epd/libepd.a - -MNEMLIB = -#MNEMLIB = $(WHERE)/mnemosyne/libmnem.a - -BLIBS = -kL$(WHERE)/dddmp -kldddmp -kL$(WHERE)/cudd -klcudd -kL$(WHERE)/mtr \ - -klmtr -kL$(WHERE)/st -klst -kL$(WHERE)/util -klutil \ - -kL$(WHERE)/epd -klepd - -LINTLIBS = $(WHERE)/llib-ldddmp.a $(WHERE)/cudd/llib-lcudd.ln \ - $(WHERE)/mtr/llib-lmtr.ln $(WHERE)/st/llib-lst.ln \ - $(WHERE)/util/llib-lutil.ln $(WHERE)/epd/llib-lepd.ln - -SRC = main.c bnet.c ntr.c ntrHeap.c ntrBddTest.c ntrMflow.c ntrZddTest.c \ - ntrShort.c chkMterm.c ucbqsort.c -HDR = bnet.h ntr.h $(WHERE)/include/dddmp.h $(WHERE)/include/cudd.h \ - $(WHERE)/include/cuddInt.h - -OBJ = $(SRC:.c=.o) -UBJ = $(SRC:.c=.u) - -MFLAG = -#MFLAG = -DMNEMOSYNE -ICFLAGS = -g -O6 -Wall -#ICFLAGS = -g -Wall -XCFLAGS = -DHAVE_IEEE_754 -DBSD -#XCFLAGS = -xtaso -ieee_with_no_inexact -tune host -CFLAGS = $(ICFLAGS) $(MFLAG) $(XCFLAGS) -DDDEBUG = -#DDDEBUG = -DDD_STATS -DDD_VERBOSE -DDD_CACHE_PROFILE -DDD_UNIQUE_PROFILE -DDD_DEBUG - -LDFLAGS = -#LDFLAGS = -jmpopt -#LDFLAGS = -non_shared -om -taso - -LINTFLAGS = -u -n -DDD_STATS -DDD_CACHE_PROFILE -DDD_VERBOSE -DDD_DEBUG -DDD_UNIQUE_PROFILE - -#------------------------------------------------------ - -$(TARGET): $(SRC) $(OBJ) $(HDR) $(LIBS) $(MNEMLIB) - $(PURE) $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJ) $(LIBS) $(MNEMLIB) -lm - -.c.o: $(HDR) - $(CC) -c $< -I$(INCLUDE) $(CFLAGS) $(DDDEBUG) - -# if the header files change, recompile -$(OBJ): $(HDR) -$(UBJ): $(HDR) - -optimize_dec: $(TARGETu) - -# optimize (DECstations only: uses u-code) -$(TARGETu): $(SRC) $(UBJ) $(HDR) $(LIBS:.a=.b) - cc -O3 $(XCFLAGS) $(LDFLAGS) $(UBJ) -o $@ $(BLIBS) -lm - -.c.u: $(SRC) $(HDR) - cc -j -I$(INCLUDE) $(XCFLAGS) $< - -lint: $(SRC) $(HDR) $(LINTLIBS) - lint $(LINTFLAGS) -I$(INCLUDE) $(SRC) $(LINTLIBS) - -tags: $(SRC) $(HDR) - ctags $(SRC) $(HDR) - -all: $(TARGET) $(TARGETu) lint tags - -pixie: $(TARGETu) - pixie $(TARGETu) - -clean: - rm -f *.o *.u mon.out gmon.out *.pixie *.Addrs *.Counts mnem.* \ - .pure core *.warnings - -distclean: clean - rm -f $(TARGET) $(TARGETu) *.bak *~ .gdb_history *.qv *.qx diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetAllAbs.html b/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetAllAbs.html deleted file mode 100644 index 22ddf6667..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetAllAbs.html +++ /dev/null @@ -1,45 +0,0 @@ -<html> -<head><title>bnet package abstract (Internal)</title></head> -<body> - -<h1>bnet package abstract (Internal)</h1> -<h2></h2> -<hr> - -<!-- Function Abstracts --> - -<dl> -<dt> <a href="bnetAllDet.html#Bnet_BuildNodeBDD"><code>Bnet_BuildNodeBDD()</code></a> -<dd> Builds the BDD for the function of a node. - -<dt> <a href="bnetAllDet.html#Bnet_DfsVariableOrder"><code>Bnet_DfsVariableOrder()</code></a> -<dd> Orders the BDD variables by DFS. - -<dt> <a href="bnetAllDet.html#Bnet_FreeNetwork"><code>Bnet_FreeNetwork()</code></a> -<dd> Frees a boolean network created by Bnet_ReadNetwork. - -<dt> <a href="bnetAllDet.html#Bnet_PrintNetwork"><code>Bnet_PrintNetwork()</code></a> -<dd> Prints a boolean network created by readNetwork. - -<dt> <a href="bnetAllDet.html#Bnet_PrintOrder"><code>Bnet_PrintOrder()</code></a> -<dd> Prints the order of the DD variables of a network. - -<dt> <a href="bnetAllDet.html#Bnet_ReadNetwork"><code>Bnet_ReadNetwork()</code></a> -<dd> Reads boolean network from blif file. - -<dt> <a href="bnetAllDet.html#Bnet_ReadOrder"><code>Bnet_ReadOrder()</code></a> -<dd> Reads the variable order from a file. - -<dt> <a href="bnetAllDet.html#Bnet_bddArrayDump"><code>Bnet_bddArrayDump()</code></a> -<dd> Writes an array of BDDs to a file in dot, blif, DDcal, factored-form, or daVinci format. - -<dt> <a href="bnetAllDet.html#Bnet_bddDump"><code>Bnet_bddDump()</code></a> -<dd> Writes the network BDDs to a file in dot, blif, or daVinci format. - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 1010215 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetAllDet.html b/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetAllDet.html deleted file mode 100644 index 352011e23..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetAllDet.html +++ /dev/null @@ -1,173 +0,0 @@ -<html> -<head><title>The bnet package (Internal) </title></head> -<body> - -<h1>The bnet package (Internal) </h1> -<h2></h2> -<h3></h3> -<hr> -<ul> -<li><a href="bnetExtAbs.html"><h3>External abstracts</h3></a> -<li><a href="bnetAllAbs.html"><h3>All abstracts</h3></a> -<li><a href="bnetExtDet.html#prototypes"><h3>External functions</h3></a> -<li><a href="bnetAllDet.html#prototypes"><h3>All functions</h3></a> -</ul> - -<hr> - -<a name="description"> - -</a> - -<hr> -<!-- Function Prototypes and description --> - -<dl> -<a name="prototypes"></a> -<dt><pre> -int <i></i> -<a name="Bnet_BuildNodeBDD"><b>Bnet_BuildNodeBDD</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNode * <b>nd</b>, <i>node of the boolean network</i> - st_table * <b>hash</b>, <i>symbol table of the boolean network</i> - int <b>params</b>, <i>type of DD to be built</i> - int <b>nodrop</b> <i>retain the intermediate node DDs until the end</i> -) -</pre> -<dd> Builds the BDD for the function of a node and stores a pointer to it in the dd field of the node itself. The reference count of the BDD is incremented. If params is BNET_LOCAL_DD, then the BDD is built in terms of the local inputs to the node; otherwise, if params is BNET_GLOBAL_DD, the BDD is built in terms of the network primary inputs. To build the global BDD of a node, the BDDs for its local inputs must exist. If that is not the case, Bnet_BuildNodeBDD recursively builds them. Likewise, to create the local BDD for a node, the local inputs must have variables assigned to them. If that is not the case, Bnet_BuildNodeBDD recursively assigns variables to nodes. Bnet_BuildNodeBDD returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Sets the dd field of the node. -<p> - -<dt><pre> -int <i></i> -<a name="Bnet_DfsVariableOrder"><b>Bnet_DfsVariableOrder</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b> <i></i> -) -</pre> -<dd> Orders the BDD variables by DFS. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Uses the visited flags of the nodes. -<p> - -<dt><pre> -void <i></i> -<a name="Bnet_FreeNetwork"><b>Bnet_FreeNetwork</b></a>( - BnetNetwork * <b>net</b> <i></i> -) -</pre> -<dd> Frees a boolean network created by Bnet_ReadNetwork. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="bnetAllDet.html#Bnet_ReadNetwork">Bnet_ReadNetwork</a> -</code> - -<dt><pre> -void <i></i> -<a name="Bnet_PrintNetwork"><b>Bnet_PrintNetwork</b></a>( - BnetNetwork * <b>net</b> <i>boolean network</i> -) -</pre> -<dd> Prints to the standard output a boolean network created by Bnet_ReadNetwork. Uses the blif format; this way, one can verify the equivalence of the input and the output with, say, sis. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="bnetAllDet.html#Bnet_ReadNetwork">Bnet_ReadNetwork</a> -</code> - -<dt><pre> -int <i></i> -<a name="Bnet_PrintOrder"><b>Bnet_PrintOrder</b></a>( - BnetNetwork * <b>net</b>, <i></i> - DdManager * <b>dd</b> <i></i> -) -</pre> -<dd> Prints the order of the DD variables of a network. Only primary inputs and present states are printed. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -BnetNetwork * <i></i> -<a name="Bnet_ReadNetwork"><b>Bnet_ReadNetwork</b></a>( - FILE * <b>fp</b>, <i>pointer to the blif file</i> - int <b>pr</b> <i>verbosity level</i> -) -</pre> -<dd> Reads a boolean network from a blif file. A very restricted subset of blif is supported. Specifically: <ul> <li> The only directives recognized are: <ul> <li> .model <li> .inputs <li> .outputs <li> .latch <li> .names <li> .exdc <li> .wire_load_slope <li> .end </ul> <li> Latches must have an initial values and no other parameters specified. <li> Lines must not exceed MAXLENGTH-1 characters, and individual names must not exceed 1023 characters. </ul> Caveat emptor: There may be other limitations as well. One should check the syntax of the blif file with some other tool before relying on this parser. Bnet_ReadNetwork returns a pointer to the network if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="bnetAllDet.html#Bnet_PrintNetwork">Bnet_PrintNetwork</a> -<a href="bnetAllDet.html#Bnet_FreeNetwork">Bnet_FreeNetwork</a> -</code> - -<dt><pre> -int <i></i> -<a name="Bnet_ReadOrder"><b>Bnet_ReadOrder</b></a>( - DdManager * <b>dd</b>, <i></i> - char * <b>ordFile</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - int <b>locGlob</b>, <i></i> - int <b>nodrop</b> <i></i> -) -</pre> -<dd> Reads the variable order from a file. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> The BDDs for the primary inputs and present state variables are built. -<p> - -<dt><pre> -int <i></i> -<a name="Bnet_bddArrayDump"><b>Bnet_bddArrayDump</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNetwork * <b>network</b>, <i>network whose BDDs should be dumped</i> - char * <b>dfile</b>, <i>file name</i> - DdNode ** <b>outputs</b>, <i>BDDs to be dumped</i> - char ** <b>onames</b>, <i>names of the BDDs to be dumped</i> - int <b>noutputs</b>, <i>number of BDDs to be dumped</i> - int <b>dumpFmt</b> <i>0 -> dot</i> -) -</pre> -<dd> Writes an array of BDDs to a file in dot, blif, DDcal, factored-form, or daVinci format. The BDDs and their names are passed as arguments. The inputs and their names are taken from the network. If "-" is passed as file name, the BDDs are dumped to the standard output. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Bnet_bddDump"><b>Bnet_bddDump</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNetwork * <b>network</b>, <i>network whose BDDs should be dumped</i> - char * <b>dfile</b>, <i>file name</i> - int <b>dumpFmt</b>, <i>0 -> dot</i> - int <b>reencoded</b> <i>whether variables have been reencoded</i> -) -</pre> -<dd> Writes the network BDDs to a file in dot, blif, or daVinci format. If "-" is passed as file name, the BDDs are dumped to the standard output. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 1010215 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetExtAbs.html b/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetExtAbs.html deleted file mode 100644 index d8f645ce4..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetExtAbs.html +++ /dev/null @@ -1,45 +0,0 @@ -<html> -<head><title>bnet package abstract</title></head> -<body> - -<h1>bnet package abstract</h1> -<h2>Simple-minded package to read a blif file.</h2> -<hr> - -<!-- Function Abstracts --> - -<dl> -<dt> <a href="bnetExtDet.html#Bnet_BuildNodeBDD"><code>Bnet_BuildNodeBDD()</code></a> -<dd> Builds the BDD for the function of a node. - -<dt> <a href="bnetExtDet.html#Bnet_DfsVariableOrder"><code>Bnet_DfsVariableOrder()</code></a> -<dd> Orders the BDD variables by DFS. - -<dt> <a href="bnetExtDet.html#Bnet_FreeNetwork"><code>Bnet_FreeNetwork()</code></a> -<dd> Frees a boolean network created by Bnet_ReadNetwork. - -<dt> <a href="bnetExtDet.html#Bnet_PrintNetwork"><code>Bnet_PrintNetwork()</code></a> -<dd> Prints a boolean network created by readNetwork. - -<dt> <a href="bnetExtDet.html#Bnet_PrintOrder"><code>Bnet_PrintOrder()</code></a> -<dd> Prints the order of the DD variables of a network. - -<dt> <a href="bnetExtDet.html#Bnet_ReadNetwork"><code>Bnet_ReadNetwork()</code></a> -<dd> Reads boolean network from blif file. - -<dt> <a href="bnetExtDet.html#Bnet_ReadOrder"><code>Bnet_ReadOrder()</code></a> -<dd> Reads the variable order from a file. - -<dt> <a href="bnetExtDet.html#Bnet_bddArrayDump"><code>Bnet_bddArrayDump()</code></a> -<dd> Writes an array of BDDs to a file in dot, blif, DDcal, factored-form, or daVinci format. - -<dt> <a href="bnetExtDet.html#Bnet_bddDump"><code>Bnet_bddDump()</code></a> -<dd> Writes the network BDDs to a file in dot, blif, or daVinci format. - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 1010215 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetExtDet.html b/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetExtDet.html deleted file mode 100644 index aee62c09d..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/bnetExtDet.html +++ /dev/null @@ -1,173 +0,0 @@ -<html> -<head><title>The bnet package</title></head> -<body> - -<h1>The bnet package</h1> -<h2>Simple-minded package to read a blif file.</h2> -<h3></h3> -<hr> -<ul> -<li><a href="bnetExtAbs.html"><h3>External abstracts</h3></a> -<li><a href="bnetAllAbs.html"><h3>All abstracts</h3></a> -<li><a href="bnetExtDet.html#prototypes"><h3>External functions</h3></a> -<li><a href="bnetAllDet.html#prototypes"><h3>All functions</h3></a> -</ul> - -<hr> - -<a name="description"> - -</a> - -<hr> -<!-- Function Prototypes and description --> - -<dl> -<a name="prototypes"></a> -<dt><pre> -int <i></i> -<a name="Bnet_BuildNodeBDD"><b>Bnet_BuildNodeBDD</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNode * <b>nd</b>, <i>node of the boolean network</i> - st_table * <b>hash</b>, <i>symbol table of the boolean network</i> - int <b>params</b>, <i>type of DD to be built</i> - int <b>nodrop</b> <i>retain the intermediate node DDs until the end</i> -) -</pre> -<dd> Builds the BDD for the function of a node and stores a pointer to it in the dd field of the node itself. The reference count of the BDD is incremented. If params is BNET_LOCAL_DD, then the BDD is built in terms of the local inputs to the node; otherwise, if params is BNET_GLOBAL_DD, the BDD is built in terms of the network primary inputs. To build the global BDD of a node, the BDDs for its local inputs must exist. If that is not the case, Bnet_BuildNodeBDD recursively builds them. Likewise, to create the local BDD for a node, the local inputs must have variables assigned to them. If that is not the case, Bnet_BuildNodeBDD recursively assigns variables to nodes. Bnet_BuildNodeBDD returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Sets the dd field of the node. -<p> - -<dt><pre> -int <i></i> -<a name="Bnet_DfsVariableOrder"><b>Bnet_DfsVariableOrder</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b> <i></i> -) -</pre> -<dd> Orders the BDD variables by DFS. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Uses the visited flags of the nodes. -<p> - -<dt><pre> -void <i></i> -<a name="Bnet_FreeNetwork"><b>Bnet_FreeNetwork</b></a>( - BnetNetwork * <b>net</b> <i></i> -) -</pre> -<dd> Frees a boolean network created by Bnet_ReadNetwork. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="bnetAllDet.html#Bnet_ReadNetwork">Bnet_ReadNetwork</a> -</code> - -<dt><pre> -void <i></i> -<a name="Bnet_PrintNetwork"><b>Bnet_PrintNetwork</b></a>( - BnetNetwork * <b>net</b> <i>boolean network</i> -) -</pre> -<dd> Prints to the standard output a boolean network created by Bnet_ReadNetwork. Uses the blif format; this way, one can verify the equivalence of the input and the output with, say, sis. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="bnetAllDet.html#Bnet_ReadNetwork">Bnet_ReadNetwork</a> -</code> - -<dt><pre> -int <i></i> -<a name="Bnet_PrintOrder"><b>Bnet_PrintOrder</b></a>( - BnetNetwork * <b>net</b>, <i></i> - DdManager * <b>dd</b> <i></i> -) -</pre> -<dd> Prints the order of the DD variables of a network. Only primary inputs and present states are printed. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -BnetNetwork * <i></i> -<a name="Bnet_ReadNetwork"><b>Bnet_ReadNetwork</b></a>( - FILE * <b>fp</b>, <i>pointer to the blif file</i> - int <b>pr</b> <i>verbosity level</i> -) -</pre> -<dd> Reads a boolean network from a blif file. A very restricted subset of blif is supported. Specifically: <ul> <li> The only directives recognized are: <ul> <li> .model <li> .inputs <li> .outputs <li> .latch <li> .names <li> .exdc <li> .wire_load_slope <li> .end </ul> <li> Latches must have an initial values and no other parameters specified. <li> Lines must not exceed MAXLENGTH-1 characters, and individual names must not exceed 1023 characters. </ul> Caveat emptor: There may be other limitations as well. One should check the syntax of the blif file with some other tool before relying on this parser. Bnet_ReadNetwork returns a pointer to the network if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="bnetAllDet.html#Bnet_PrintNetwork">Bnet_PrintNetwork</a> -<a href="bnetAllDet.html#Bnet_FreeNetwork">Bnet_FreeNetwork</a> -</code> - -<dt><pre> -int <i></i> -<a name="Bnet_ReadOrder"><b>Bnet_ReadOrder</b></a>( - DdManager * <b>dd</b>, <i></i> - char * <b>ordFile</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - int <b>locGlob</b>, <i></i> - int <b>nodrop</b> <i></i> -) -</pre> -<dd> Reads the variable order from a file. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> The BDDs for the primary inputs and present state variables are built. -<p> - -<dt><pre> -int <i></i> -<a name="Bnet_bddArrayDump"><b>Bnet_bddArrayDump</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNetwork * <b>network</b>, <i>network whose BDDs should be dumped</i> - char * <b>dfile</b>, <i>file name</i> - DdNode ** <b>outputs</b>, <i>BDDs to be dumped</i> - char ** <b>onames</b>, <i>names of the BDDs to be dumped</i> - int <b>noutputs</b>, <i>number of BDDs to be dumped</i> - int <b>dumpFmt</b> <i>0 -> dot</i> -) -</pre> -<dd> Writes an array of BDDs to a file in dot, blif, DDcal, factored-form, or daVinci format. The BDDs and their names are passed as arguments. The inputs and their names are taken from the network. If "-" is passed as file name, the BDDs are dumped to the standard output. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Bnet_bddDump"><b>Bnet_bddDump</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNetwork * <b>network</b>, <i>network whose BDDs should be dumped</i> - char * <b>dfile</b>, <i>file name</i> - int <b>dumpFmt</b>, <i>0 -> dot</i> - int <b>reencoded</b> <i>whether variables have been reencoded</i> -) -</pre> -<dd> Writes the network BDDs to a file in dot, blif, or daVinci format. If "-" is passed as file name, the BDDs are dumped to the standard output. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 1010215 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrAllAbs.html b/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrAllAbs.html deleted file mode 100644 index 360a4e748..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrAllAbs.html +++ /dev/null @@ -1,114 +0,0 @@ -<html> -<head><title>ntr package abstract (Internal)</title></head> -<body> - -<h1>ntr package abstract (Internal)</h1> -<h2></h2> -<hr> - -<!-- Function Abstracts --> - -<dl> -<dt> <a href="ntrAllDet.html#Ntr_ClosureTrav"><code>Ntr_ClosureTrav()</code></a> -<dd> Transitive closure traversal procedure. - -<dt> <a href="ntrAllDet.html#Ntr_Envelope"><code>Ntr_Envelope()</code></a> -<dd> Poor man's outer envelope computation. - -<dt> <a href="ntrAllDet.html#Ntr_FreeHeap"><code>Ntr_FreeHeap()</code></a> -<dd> Frees a priority queue. - -<dt> <a href="ntrAllDet.html#Ntr_HeapClone"><code>Ntr_HeapClone()</code></a> -<dd> Clones a priority queue. - -<dt> <a href="ntrAllDet.html#Ntr_HeapCount"><code>Ntr_HeapCount()</code></a> -<dd> Returns the number of items in a priority queue. - -<dt> <a href="ntrAllDet.html#Ntr_HeapExtractMin"><code>Ntr_HeapExtractMin()</code></a> -<dd> Extracts the element with the minimum key from a priority queue. - -<dt> <a href="ntrAllDet.html#Ntr_HeapInsert"><code>Ntr_HeapInsert()</code></a> -<dd> Inserts an item in a priority queue. - -<dt> <a href="ntrAllDet.html#Ntr_InitHeap"><code>Ntr_InitHeap()</code></a> -<dd> Initializes a priority queue. - -<dt> <a href="ntrAllDet.html#Ntr_SCC"><code>Ntr_SCC()</code></a> -<dd> Computes the SCCs of the STG. - -<dt> <a href="ntrAllDet.html#Ntr_ShortestPaths"><code>Ntr_ShortestPaths()</code></a> -<dd> Computes shortest paths in a state graph. - -<dt> <a href="ntrAllDet.html#Ntr_TestClipping"><code>Ntr_TestClipping()</code></a> -<dd> Tests BDD clipping functions. - -<dt> <a href="ntrAllDet.html#Ntr_TestClosestCube"><code>Ntr_TestClosestCube()</code></a> -<dd> Tests the Cudd_bddClosestCube function. - -<dt> <a href="ntrAllDet.html#Ntr_TestCofactorEstimate"><code>Ntr_TestCofactorEstimate()</code></a> -<dd> Tests BDD cofactor estimate functions. - -<dt> <a href="ntrAllDet.html#Ntr_TestDecomp"><code>Ntr_TestDecomp()</code></a> -<dd> Tests BDD decomposition functions. - -<dt> <a href="ntrAllDet.html#Ntr_TestDensity"><code>Ntr_TestDensity()</code></a> -<dd> Tests BDD density-related functions. - -<dt> <a href="ntrAllDet.html#Ntr_TestEquivAndContain"><code>Ntr_TestEquivAndContain()</code></a> -<dd> Tests BDD equivalence and containment with don't cares. - -<dt> <a href="ntrAllDet.html#Ntr_TestHeap"><code>Ntr_TestHeap()</code></a> -<dd> Tests the heap property of a priority queue. - -<dt> <a href="ntrAllDet.html#Ntr_TestMinimization"><code>Ntr_TestMinimization()</code></a> -<dd> Tests BDD minimization functions. - -<dt> <a href="ntrAllDet.html#Ntr_TransitiveClosure"><code>Ntr_TransitiveClosure()</code></a> -<dd> Builds the transitive closure of a transition relation. - -<dt> <a href="ntrAllDet.html#Ntr_Trav"><code>Ntr_Trav()</code></a> -<dd> Poor man's traversal procedure. - -<dt> <a href="ntrAllDet.html#Ntr_VerifyEquivalence"><code>Ntr_VerifyEquivalence()</code></a> -<dd> Verify equivalence of combinational networks. - -<dt> <a href="ntrAllDet.html#Ntr_buildDDs"><code>Ntr_buildDDs()</code></a> -<dd> Builds DDs for a network outputs and next state functions. - -<dt> <a href="ntrAllDet.html#Ntr_buildTR"><code>Ntr_buildTR()</code></a> -<dd> Builds the transition relation for a network. - -<dt> <a href="ntrAllDet.html#Ntr_cloneTR"><code>Ntr_cloneTR()</code></a> -<dd> Makes a copy of a transition relation. - -<dt> <a href="ntrAllDet.html#Ntr_freeTR"><code>Ntr_freeTR()</code></a> -<dd> Frees the transition relation for a network. - -<dt> <a href="ntrAllDet.html#Ntr_getStateCube"><code>Ntr_getStateCube()</code></a> -<dd> Reads a state cube from a file or creates a random one. - -<dt> <a href="ntrAllDet.html#Ntr_initState"><code>Ntr_initState()</code></a> -<dd> Builds the BDD of the initial state(s). - -<dt> <a href="ntrAllDet.html#Ntr_maxflow"><code>Ntr_maxflow()</code></a> -<dd> Maximum 0-1 flow between source and sink states. - -<dt> <a href="ntrAllDet.html#Ntr_maximum01Flow"><code>Ntr_maximum01Flow()</code></a> -<dd> - -<dt> <a href="ntrAllDet.html#Ntr_testISOP"><code>Ntr_testISOP()</code></a> -<dd> Builds ZDD covers. - -<dt> <a href="ntrAllDet.html#Ntr_testZDD"><code>Ntr_testZDD()</code></a> -<dd> Tests ZDDs. - -<dt> <a href="ntrAllDet.html#STRING_EQUAL"><code>STRING_EQUAL()</code></a> -<dd> Returns 1 if the two arguments are identical strings. - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 1010215 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrAllDet.html b/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrAllDet.html deleted file mode 100644 index 5daa930d8..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrAllDet.html +++ /dev/null @@ -1,513 +0,0 @@ -<html> -<head><title>The ntr package (Internal) </title></head> -<body> - -<h1>The ntr package (Internal) </h1> -<h2></h2> -<h3></h3> -<hr> -<ul> -<li><a href="ntrExtAbs.html"><h3>External abstracts</h3></a> -<li><a href="ntrAllAbs.html"><h3>All abstracts</h3></a> -<li><a href="ntrExtDet.html#prototypes"><h3>External functions</h3></a> -<li><a href="ntrAllDet.html#prototypes"><h3>All functions</h3></a> -</ul> - -<hr> - -<a name="description"> - -</a> - -<hr> -<!-- Function Prototypes and description --> - -<dl> -<a name="prototypes"></a> -<dt><pre> -int <i></i> -<a name="Ntr_ClosureTrav"><b>Ntr_ClosureTrav</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNetwork * <b>net</b>, <i>network</i> - NtrOptions * <b>option</b> <i>options</i> -) -</pre> -<dd> Traversal procedure. based on the transitive closure of the transition relation. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_Trav">Ntr_Trav</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_Envelope"><b>Ntr_Envelope</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - NtrPartTR * <b>TR</b>, <i>transition relation</i> - FILE * <b>dfp</b>, <i>pointer to file for DD dump</i> - NtrOptions * <b>option</b> <i>program options</i> -) -</pre> -<dd> Poor man's outer envelope computation based on the monolithic transition relation. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -void <i></i> -<a name="Ntr_FreeHeap"><b>Ntr_FreeHeap</b></a>( - NtrHeap * <b>heap</b> <i></i> -) -</pre> -<dd> Frees a priority queue. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_InitHeap">Ntr_InitHeap</a> -</code> - -<dt><pre> -NtrHeap * <i></i> -<a name="Ntr_HeapClone"><b>Ntr_HeapClone</b></a>( - NtrHeap * <b>source</b> <i></i> -) -</pre> -<dd> Clones a priority queue. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_InitHeap">Ntr_InitHeap</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_HeapCount"><b>Ntr_HeapCount</b></a>( - NtrHeap * <b>heap</b> <i></i> -) -</pre> -<dd> Returns the number of items in a priority queue. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_HeapExtractMin"><b>Ntr_HeapExtractMin</b></a>( - NtrHeap * <b>heap</b>, <i></i> - void ** <b>item</b>, <i></i> - int * <b>key</b> <i></i> -) -</pre> -<dd> Extracts the element with the minimum key from a priority queue. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> The minimum key and the associated item are returned as side effects. -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_HeapInsert">Ntr_HeapInsert</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_HeapInsert"><b>Ntr_HeapInsert</b></a>( - NtrHeap * <b>heap</b>, <i></i> - void * <b>item</b>, <i></i> - int <b>key</b> <i></i> -) -</pre> -<dd> Inserts an item in a priority queue. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_HeapExtractMin">Ntr_HeapExtractMin</a> -</code> - -<dt><pre> -NtrHeap * <i></i> -<a name="Ntr_InitHeap"><b>Ntr_InitHeap</b></a>( - int <b>size</b> <i></i> -) -</pre> -<dd> Initializes a priority queue. Returns a pointer to the heap if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_FreeHeap">Ntr_FreeHeap</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_SCC"><b>Ntr_SCC</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNetwork * <b>net</b>, <i>network</i> - NtrOptions * <b>option</b> <i>options</i> -) -</pre> -<dd> Computes the strongly connected components of the state transition graph. Only the first 10 SCCs are computed. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_Trav">Ntr_Trav</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_ShortestPaths"><b>Ntr_ShortestPaths</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Computes shortest paths in the state transition graph of a network. Three methods are availabe: <ul> <li> Bellman-Ford algorithm for single-source shortest paths; the algorithm computes the distance (number of transitions) from the initial states to all states. <li> Floyd-Warshall algorithm for all-pair shortest paths. <li> Repeated squaring algorithm for all-pair shortest paths. </ul> The function returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> ADD variables are created in the manager. -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestClipping"><b>Ntr_TestClipping</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - BnetNetwork * <b>net2</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests BDD clipping functions. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestClosestCube"><b>Ntr_TestClosestCube</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests the Cudd_bddClosestCube function. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestCofactorEstimate"><b>Ntr_TestCofactorEstimate</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests BDD cofactor estimate functions. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestDecomp"><b>Ntr_TestDecomp</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests BDD decomposition functions. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestDensity"><b>Ntr_TestDensity</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests BDD density-related functions. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestEquivAndContain"><b>Ntr_TestEquivAndContain</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - BnetNetwork * <b>net2</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests functions for BDD equivalence and containment with don't cares, including Cudd_EquivDC and Cudd_bddLeqUnless. This function uses as care set the first output of net2 and checkes equivalence and containment for of all the output pairs of net1. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestHeap"><b>Ntr_TestHeap</b></a>( - NtrHeap * <b>heap</b>, <i></i> - int <b>i</b> <i></i> -) -</pre> -<dd> Tests the heap property of a priority queue. Returns 1 if Successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestMinimization"><b>Ntr_TestMinimization</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - BnetNetwork * <b>net2</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests BDD minimization functions, including leaf-identifying compaction, squeezing, and restrict. This function uses as constraint the first output of net2 and computes positive and negative cofactors of all the outputs of net1. For each cofactor, it checks whether compaction was safe (cofactor not larger than original function) and that the expansion based on each minimization function (used as a generalized cofactor) equals the original function. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -DdNode * <i></i> -<a name="Ntr_TransitiveClosure"><b>Ntr_TransitiveClosure</b></a>( - DdManager * <b>dd</b>, <i></i> - NtrPartTR * <b>TR</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Builds the transitive closure of a transition relation. Returns a BDD if successful; NULL otherwise. Uses a simple squaring algorithm. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_Trav"><b>Ntr_Trav</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNetwork * <b>net</b>, <i>network</i> - NtrOptions * <b>option</b> <i>options</i> -) -</pre> -<dd> Poor man's traversal procedure. based on the monolithic transition relation. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_ClosureTrav">Ntr_ClosureTrav</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_VerifyEquivalence"><b>Ntr_VerifyEquivalence</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - BnetNetwork * <b>net2</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Verify equivalence of combinational networks. Returns 1 if successful and if the networks are equivalent; -1 if successful, but the networks are not equivalent; 0 otherwise. The two networks are supposed to have the same names for inputs and outputs. The only exception is that the second network may miss output buffers that are present in the first network. This function tries to match both the output and the input of the buffer. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_buildDDs"><b>Ntr_buildDDs</b></a>( - BnetNetwork * <b>net</b>, <i>network for which DDs are to be built</i> - DdManager * <b>dd</b>, <i>DD manager</i> - NtrOptions * <b>option</b>, <i>option structure</i> - BnetNetwork * <b>net2</b> <i>companion network with which inputs may be shared</i> -) -</pre> -<dd> Builds DDs for a network outputs and next state functions. The method is really brain-dead, but it is very simple. Returns 1 in case of success; 0 otherwise. Some inputs to the network may be shared with another network whose DDs have already been built. In this case we want to share the DDs as well. -<p> - -<dd> <b>Side Effects</b> the dd fields of the network nodes are modified. Uses the count fields of the nodes. -<p> - -<dt><pre> -NtrPartTR * <i></i> -<a name="Ntr_buildTR"><b>Ntr_buildTR</b></a>( - DdManager * <b>dd</b>, <i>manager</i> - BnetNetwork * <b>net</b>, <i>network</i> - NtrOptions * <b>option</b>, <i>options</i> - int <b>image</b> <i>image type: monolithic ...</i> -) -</pre> -<dd> Builds the transition relation for a network. Returns a pointer to the transition relation structure if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -NtrPartTR * <i></i> -<a name="Ntr_cloneTR"><b>Ntr_cloneTR</b></a>( - NtrPartTR * <b>TR</b> <i></i> -) -</pre> -<dd> Makes a copy of a transition relation. Returns a pointer to the copy if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_buildTR">Ntr_buildTR</a> -<a href="ntrAllDet.html#Ntr_freeTR">Ntr_freeTR</a> -</code> - -<dt><pre> -void <i></i> -<a name="Ntr_freeTR"><b>Ntr_freeTR</b></a>( - DdManager * <b>dd</b>, <i></i> - NtrPartTR * <b>TR</b> <i></i> -) -</pre> -<dd> Frees the transition relation for a network. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -DdNode * <i></i> -<a name="Ntr_getStateCube"><b>Ntr_getStateCube</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - char * <b>filename</b>, <i></i> - int <b>pr</b> <i></i> -) -</pre> -<dd> Reads a state cube from a file or create a random one. Returns a pointer to the BDD of the sink nodes if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -DdNode * <i></i> -<a name="Ntr_initState"><b>Ntr_initState</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Builds the BDD of the initial state(s). Returns a BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_maxflow"><b>Ntr_maxflow</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Maximum 0-1 flow between source and sink states. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Creates two new sets of variables. -<p> - -<dt><pre> -double <i></i> -<a name="Ntr_maximum01Flow"><b>Ntr_maximum01Flow</b></a>( - DdManager * <b>bdd</b>, <i>manager</i> - DdNode * <b>sx</b>, <i>source node</i> - DdNode * <b>ty</b>, <i>sink node</i> - DdNode * <b>E</b>, <i>edge relation</i> - DdNode ** <b>F</b>, <i>flow relation</i> - DdNode ** <b>cut</b>, <i>cutset relation</i> - DdNode ** <b>x</b>, <i>array of row variables</i> - DdNode ** <b>y</b>, <i>array of column variables</i> - DdNode ** <b>z</b>, <i>arrays of auxiliary variables</i> - int <b>n</b>, <i>number of variables in each array</i> - int <b>pr</b> <i>verbosity level</i> -) -</pre> -<dd> This function implements Dinits's algorithm for (0-1) max flow, using BDDs and a symbolic technique to trace multiple edge-disjoint augmenting paths to complete a phase. The outer forever loop is over phases, and the inner forever loop is to propagate a (not yet) maximal flow of edge-disjoint augmenting paths from one layer to the previous. The subprocedure call implements a least fixed point iteration to compute a (not yet) maximal flow update between layers. At the end of each phase (except the last one) the flow is actually pushed from the source to the sink. Data items: <ul> <li> sx(ty) BDD representations of s(t). <li> x(y) The variables encoding the from(to)-node u(v) of an edge (u,v) in the given digraph. <li> z Another set of variables. <li> E(x,y) The edge relation. <li> F(x,y) BDD representation of the current flow, initialized to 0 for each arc, and updated by +1, -1, or 0 at the end of each phase. <li> Ms Mt The maximum flow, that is, the cardinality of a minimum cut, measured at the source and at the sink, respectively. The two values should be identical. <li> reached The set of nodes already visited in the BFS of the digraph. <li> fos fanout of the source node s. <li> fit fanin of the sink node t. </ul> -<p> - -<dd> <b>Side Effects</b> The flow realtion F and the cutset relation cut are returned as side effects. -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_testISOP"><b>Ntr_testISOP</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Builds ZDD covers. -<p> - -<dd> <b>Side Effects</b> Creates ZDD variables in the manager. -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_testZDD"><b>Ntr_testZDD</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests ZDDs. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Creates ZDD variables in the manager. -<p> - -<dt><pre> - <i></i> -<a name="STRING_EQUAL"><b>STRING_EQUAL</b></a>( - <b>s1</b>, <i></i> - <b>s2</b> <i></i> -) -</pre> -<dd> Returns 1 if the two arguments are identical strings. -<p> - -<dd> <b>Side Effects</b> none -<p> - - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 1010215 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrExtAbs.html b/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrExtAbs.html deleted file mode 100644 index 485d34676..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrExtAbs.html +++ /dev/null @@ -1,111 +0,0 @@ -<html> -<head><title>ntr package abstract</title></head> -<body> - -<h1>ntr package abstract</h1> -<h2>Simple-minded package to do traversal.</h2> -<hr> - -<!-- Function Abstracts --> - -<dl> -<dt> <a href="ntrExtDet.html#Ntr_ClosureTrav"><code>Ntr_ClosureTrav()</code></a> -<dd> Transitive closure traversal procedure. - -<dt> <a href="ntrExtDet.html#Ntr_Envelope"><code>Ntr_Envelope()</code></a> -<dd> Poor man's outer envelope computation. - -<dt> <a href="ntrExtDet.html#Ntr_FreeHeap"><code>Ntr_FreeHeap()</code></a> -<dd> Frees a priority queue. - -<dt> <a href="ntrExtDet.html#Ntr_HeapClone"><code>Ntr_HeapClone()</code></a> -<dd> Clones a priority queue. - -<dt> <a href="ntrExtDet.html#Ntr_HeapCount"><code>Ntr_HeapCount()</code></a> -<dd> Returns the number of items in a priority queue. - -<dt> <a href="ntrExtDet.html#Ntr_HeapExtractMin"><code>Ntr_HeapExtractMin()</code></a> -<dd> Extracts the element with the minimum key from a priority queue. - -<dt> <a href="ntrExtDet.html#Ntr_HeapInsert"><code>Ntr_HeapInsert()</code></a> -<dd> Inserts an item in a priority queue. - -<dt> <a href="ntrExtDet.html#Ntr_InitHeap"><code>Ntr_InitHeap()</code></a> -<dd> Initializes a priority queue. - -<dt> <a href="ntrExtDet.html#Ntr_SCC"><code>Ntr_SCC()</code></a> -<dd> Computes the SCCs of the STG. - -<dt> <a href="ntrExtDet.html#Ntr_ShortestPaths"><code>Ntr_ShortestPaths()</code></a> -<dd> Computes shortest paths in a state graph. - -<dt> <a href="ntrExtDet.html#Ntr_TestClipping"><code>Ntr_TestClipping()</code></a> -<dd> Tests BDD clipping functions. - -<dt> <a href="ntrExtDet.html#Ntr_TestClosestCube"><code>Ntr_TestClosestCube()</code></a> -<dd> Tests the Cudd_bddClosestCube function. - -<dt> <a href="ntrExtDet.html#Ntr_TestCofactorEstimate"><code>Ntr_TestCofactorEstimate()</code></a> -<dd> Tests BDD cofactor estimate functions. - -<dt> <a href="ntrExtDet.html#Ntr_TestDecomp"><code>Ntr_TestDecomp()</code></a> -<dd> Tests BDD decomposition functions. - -<dt> <a href="ntrExtDet.html#Ntr_TestDensity"><code>Ntr_TestDensity()</code></a> -<dd> Tests BDD density-related functions. - -<dt> <a href="ntrExtDet.html#Ntr_TestEquivAndContain"><code>Ntr_TestEquivAndContain()</code></a> -<dd> Tests BDD equivalence and containment with don't cares. - -<dt> <a href="ntrExtDet.html#Ntr_TestHeap"><code>Ntr_TestHeap()</code></a> -<dd> Tests the heap property of a priority queue. - -<dt> <a href="ntrExtDet.html#Ntr_TestMinimization"><code>Ntr_TestMinimization()</code></a> -<dd> Tests BDD minimization functions. - -<dt> <a href="ntrExtDet.html#Ntr_TransitiveClosure"><code>Ntr_TransitiveClosure()</code></a> -<dd> Builds the transitive closure of a transition relation. - -<dt> <a href="ntrExtDet.html#Ntr_Trav"><code>Ntr_Trav()</code></a> -<dd> Poor man's traversal procedure. - -<dt> <a href="ntrExtDet.html#Ntr_VerifyEquivalence"><code>Ntr_VerifyEquivalence()</code></a> -<dd> Verify equivalence of combinational networks. - -<dt> <a href="ntrExtDet.html#Ntr_buildDDs"><code>Ntr_buildDDs()</code></a> -<dd> Builds DDs for a network outputs and next state functions. - -<dt> <a href="ntrExtDet.html#Ntr_buildTR"><code>Ntr_buildTR()</code></a> -<dd> Builds the transition relation for a network. - -<dt> <a href="ntrExtDet.html#Ntr_cloneTR"><code>Ntr_cloneTR()</code></a> -<dd> Makes a copy of a transition relation. - -<dt> <a href="ntrExtDet.html#Ntr_freeTR"><code>Ntr_freeTR()</code></a> -<dd> Frees the transition relation for a network. - -<dt> <a href="ntrExtDet.html#Ntr_getStateCube"><code>Ntr_getStateCube()</code></a> -<dd> Reads a state cube from a file or creates a random one. - -<dt> <a href="ntrExtDet.html#Ntr_initState"><code>Ntr_initState()</code></a> -<dd> Builds the BDD of the initial state(s). - -<dt> <a href="ntrExtDet.html#Ntr_maxflow"><code>Ntr_maxflow()</code></a> -<dd> Maximum 0-1 flow between source and sink states. - -<dt> <a href="ntrExtDet.html#Ntr_maximum01Flow"><code>Ntr_maximum01Flow()</code></a> -<dd> - -<dt> <a href="ntrExtDet.html#Ntr_testISOP"><code>Ntr_testISOP()</code></a> -<dd> Builds ZDD covers. - -<dt> <a href="ntrExtDet.html#Ntr_testZDD"><code>Ntr_testZDD()</code></a> -<dd> Tests ZDDs. - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 1010215 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrExtDet.html b/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrExtDet.html deleted file mode 100644 index ae06139ec..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/doc/ntrExtDet.html +++ /dev/null @@ -1,500 +0,0 @@ -<html> -<head><title>The ntr package</title></head> -<body> - -<h1>The ntr package</h1> -<h2>Simple-minded package to do traversal.</h2> -<h3></h3> -<hr> -<ul> -<li><a href="ntrExtAbs.html"><h3>External abstracts</h3></a> -<li><a href="ntrAllAbs.html"><h3>All abstracts</h3></a> -<li><a href="ntrExtDet.html#prototypes"><h3>External functions</h3></a> -<li><a href="ntrAllDet.html#prototypes"><h3>All functions</h3></a> -</ul> - -<hr> - -<a name="description"> - -</a> - -<hr> -<!-- Function Prototypes and description --> - -<dl> -<a name="prototypes"></a> -<dt><pre> -int <i></i> -<a name="Ntr_ClosureTrav"><b>Ntr_ClosureTrav</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNetwork * <b>net</b>, <i>network</i> - NtrOptions * <b>option</b> <i>options</i> -) -</pre> -<dd> Traversal procedure. based on the transitive closure of the transition relation. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_Trav">Ntr_Trav</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_Envelope"><b>Ntr_Envelope</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - NtrPartTR * <b>TR</b>, <i>transition relation</i> - FILE * <b>dfp</b>, <i>pointer to file for DD dump</i> - NtrOptions * <b>option</b> <i>program options</i> -) -</pre> -<dd> Poor man's outer envelope computation based on the monolithic transition relation. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -void <i></i> -<a name="Ntr_FreeHeap"><b>Ntr_FreeHeap</b></a>( - NtrHeap * <b>heap</b> <i></i> -) -</pre> -<dd> Frees a priority queue. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_InitHeap">Ntr_InitHeap</a> -</code> - -<dt><pre> -NtrHeap * <i></i> -<a name="Ntr_HeapClone"><b>Ntr_HeapClone</b></a>( - NtrHeap * <b>source</b> <i></i> -) -</pre> -<dd> Clones a priority queue. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_InitHeap">Ntr_InitHeap</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_HeapCount"><b>Ntr_HeapCount</b></a>( - NtrHeap * <b>heap</b> <i></i> -) -</pre> -<dd> Returns the number of items in a priority queue. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_HeapExtractMin"><b>Ntr_HeapExtractMin</b></a>( - NtrHeap * <b>heap</b>, <i></i> - void ** <b>item</b>, <i></i> - int * <b>key</b> <i></i> -) -</pre> -<dd> Extracts the element with the minimum key from a priority queue. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> The minimum key and the associated item are returned as side effects. -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_HeapInsert">Ntr_HeapInsert</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_HeapInsert"><b>Ntr_HeapInsert</b></a>( - NtrHeap * <b>heap</b>, <i></i> - void * <b>item</b>, <i></i> - int <b>key</b> <i></i> -) -</pre> -<dd> Inserts an item in a priority queue. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_HeapExtractMin">Ntr_HeapExtractMin</a> -</code> - -<dt><pre> -NtrHeap * <i></i> -<a name="Ntr_InitHeap"><b>Ntr_InitHeap</b></a>( - int <b>size</b> <i></i> -) -</pre> -<dd> Initializes a priority queue. Returns a pointer to the heap if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_FreeHeap">Ntr_FreeHeap</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_SCC"><b>Ntr_SCC</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNetwork * <b>net</b>, <i>network</i> - NtrOptions * <b>option</b> <i>options</i> -) -</pre> -<dd> Computes the strongly connected components of the state transition graph. Only the first 10 SCCs are computed. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_Trav">Ntr_Trav</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_ShortestPaths"><b>Ntr_ShortestPaths</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Computes shortest paths in the state transition graph of a network. Three methods are availabe: <ul> <li> Bellman-Ford algorithm for single-source shortest paths; the algorithm computes the distance (number of transitions) from the initial states to all states. <li> Floyd-Warshall algorithm for all-pair shortest paths. <li> Repeated squaring algorithm for all-pair shortest paths. </ul> The function returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> ADD variables are created in the manager. -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestClipping"><b>Ntr_TestClipping</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - BnetNetwork * <b>net2</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests BDD clipping functions. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestClosestCube"><b>Ntr_TestClosestCube</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests the Cudd_bddClosestCube function. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestCofactorEstimate"><b>Ntr_TestCofactorEstimate</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests BDD cofactor estimate functions. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestDecomp"><b>Ntr_TestDecomp</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests BDD decomposition functions. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestDensity"><b>Ntr_TestDensity</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests BDD density-related functions. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestEquivAndContain"><b>Ntr_TestEquivAndContain</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - BnetNetwork * <b>net2</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests functions for BDD equivalence and containment with don't cares, including Cudd_EquivDC and Cudd_bddLeqUnless. This function uses as care set the first output of net2 and checkes equivalence and containment for of all the output pairs of net1. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestHeap"><b>Ntr_TestHeap</b></a>( - NtrHeap * <b>heap</b>, <i></i> - int <b>i</b> <i></i> -) -</pre> -<dd> Tests the heap property of a priority queue. Returns 1 if Successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_TestMinimization"><b>Ntr_TestMinimization</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - BnetNetwork * <b>net2</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests BDD minimization functions, including leaf-identifying compaction, squeezing, and restrict. This function uses as constraint the first output of net2 and computes positive and negative cofactors of all the outputs of net1. For each cofactor, it checks whether compaction was safe (cofactor not larger than original function) and that the expansion based on each minimization function (used as a generalized cofactor) equals the original function. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -DdNode * <i></i> -<a name="Ntr_TransitiveClosure"><b>Ntr_TransitiveClosure</b></a>( - DdManager * <b>dd</b>, <i></i> - NtrPartTR * <b>TR</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Builds the transitive closure of a transition relation. Returns a BDD if successful; NULL otherwise. Uses a simple squaring algorithm. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_Trav"><b>Ntr_Trav</b></a>( - DdManager * <b>dd</b>, <i>DD manager</i> - BnetNetwork * <b>net</b>, <i>network</i> - NtrOptions * <b>option</b> <i>options</i> -) -</pre> -<dd> Poor man's traversal procedure. based on the monolithic transition relation. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_ClosureTrav">Ntr_ClosureTrav</a> -</code> - -<dt><pre> -int <i></i> -<a name="Ntr_VerifyEquivalence"><b>Ntr_VerifyEquivalence</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net1</b>, <i></i> - BnetNetwork * <b>net2</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Verify equivalence of combinational networks. Returns 1 if successful and if the networks are equivalent; -1 if successful, but the networks are not equivalent; 0 otherwise. The two networks are supposed to have the same names for inputs and outputs. The only exception is that the second network may miss output buffers that are present in the first network. This function tries to match both the output and the input of the buffer. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_buildDDs"><b>Ntr_buildDDs</b></a>( - BnetNetwork * <b>net</b>, <i>network for which DDs are to be built</i> - DdManager * <b>dd</b>, <i>DD manager</i> - NtrOptions * <b>option</b>, <i>option structure</i> - BnetNetwork * <b>net2</b> <i>companion network with which inputs may be shared</i> -) -</pre> -<dd> Builds DDs for a network outputs and next state functions. The method is really brain-dead, but it is very simple. Returns 1 in case of success; 0 otherwise. Some inputs to the network may be shared with another network whose DDs have already been built. In this case we want to share the DDs as well. -<p> - -<dd> <b>Side Effects</b> the dd fields of the network nodes are modified. Uses the count fields of the nodes. -<p> - -<dt><pre> -NtrPartTR * <i></i> -<a name="Ntr_buildTR"><b>Ntr_buildTR</b></a>( - DdManager * <b>dd</b>, <i>manager</i> - BnetNetwork * <b>net</b>, <i>network</i> - NtrOptions * <b>option</b>, <i>options</i> - int <b>image</b> <i>image type: monolithic ...</i> -) -</pre> -<dd> Builds the transition relation for a network. Returns a pointer to the transition relation structure if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -NtrPartTR * <i></i> -<a name="Ntr_cloneTR"><b>Ntr_cloneTR</b></a>( - NtrPartTR * <b>TR</b> <i></i> -) -</pre> -<dd> Makes a copy of a transition relation. Returns a pointer to the copy if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="ntrAllDet.html#Ntr_buildTR">Ntr_buildTR</a> -<a href="ntrAllDet.html#Ntr_freeTR">Ntr_freeTR</a> -</code> - -<dt><pre> -void <i></i> -<a name="Ntr_freeTR"><b>Ntr_freeTR</b></a>( - DdManager * <b>dd</b>, <i></i> - NtrPartTR * <b>TR</b> <i></i> -) -</pre> -<dd> Frees the transition relation for a network. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -DdNode * <i></i> -<a name="Ntr_getStateCube"><b>Ntr_getStateCube</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - char * <b>filename</b>, <i></i> - int <b>pr</b> <i></i> -) -</pre> -<dd> Reads a state cube from a file or create a random one. Returns a pointer to the BDD of the sink nodes if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -DdNode * <i></i> -<a name="Ntr_initState"><b>Ntr_initState</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Builds the BDD of the initial state(s). Returns a BDD if successful; NULL otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_maxflow"><b>Ntr_maxflow</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Maximum 0-1 flow between source and sink states. Returns 1 in case of success; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Creates two new sets of variables. -<p> - -<dt><pre> -double <i></i> -<a name="Ntr_maximum01Flow"><b>Ntr_maximum01Flow</b></a>( - DdManager * <b>bdd</b>, <i>manager</i> - DdNode * <b>sx</b>, <i>source node</i> - DdNode * <b>ty</b>, <i>sink node</i> - DdNode * <b>E</b>, <i>edge relation</i> - DdNode ** <b>F</b>, <i>flow relation</i> - DdNode ** <b>cut</b>, <i>cutset relation</i> - DdNode ** <b>x</b>, <i>array of row variables</i> - DdNode ** <b>y</b>, <i>array of column variables</i> - DdNode ** <b>z</b>, <i>arrays of auxiliary variables</i> - int <b>n</b>, <i>number of variables in each array</i> - int <b>pr</b> <i>verbosity level</i> -) -</pre> -<dd> This function implements Dinits's algorithm for (0-1) max flow, using BDDs and a symbolic technique to trace multiple edge-disjoint augmenting paths to complete a phase. The outer forever loop is over phases, and the inner forever loop is to propagate a (not yet) maximal flow of edge-disjoint augmenting paths from one layer to the previous. The subprocedure call implements a least fixed point iteration to compute a (not yet) maximal flow update between layers. At the end of each phase (except the last one) the flow is actually pushed from the source to the sink. Data items: <ul> <li> sx(ty) BDD representations of s(t). <li> x(y) The variables encoding the from(to)-node u(v) of an edge (u,v) in the given digraph. <li> z Another set of variables. <li> E(x,y) The edge relation. <li> F(x,y) BDD representation of the current flow, initialized to 0 for each arc, and updated by +1, -1, or 0 at the end of each phase. <li> Ms Mt The maximum flow, that is, the cardinality of a minimum cut, measured at the source and at the sink, respectively. The two values should be identical. <li> reached The set of nodes already visited in the BFS of the digraph. <li> fos fanout of the source node s. <li> fit fanin of the sink node t. </ul> -<p> - -<dd> <b>Side Effects</b> The flow realtion F and the cutset relation cut are returned as side effects. -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_testISOP"><b>Ntr_testISOP</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Builds ZDD covers. -<p> - -<dd> <b>Side Effects</b> Creates ZDD variables in the manager. -<p> - -<dt><pre> -int <i></i> -<a name="Ntr_testZDD"><b>Ntr_testZDD</b></a>( - DdManager * <b>dd</b>, <i></i> - BnetNetwork * <b>net</b>, <i></i> - NtrOptions * <b>option</b> <i></i> -) -</pre> -<dd> Tests ZDDs. Returns 1 if successful; 0 otherwise. -<p> - -<dd> <b>Side Effects</b> Creates ZDD variables in the manager. -<p> - - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 1010215 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/mult32a.out b/resources/3rdparty/cudd-2.5.0/src/nanotrav/mult32a.out deleted file mode 100644 index f0933305e..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/mult32a.out +++ /dev/null @@ -1,258 +0,0 @@ -# Nanotrav Version #0.12, Release date 2003/12/31 -# ./nanotrav -p 1 -autodyn -reordering sifting -trav mult32a.blif -# CUDD Version 2.4.2 -BDD reordering with sifting: from 4001 to ... 268 nodes in 0.005 sec -BDD reordering with sifting: from 537 to ... 246 nodes in 0.006 sec -BDD reordering with sifting: from 493 to ... 250 nodes in 0.009 sec -BDD reordering with sifting: from 501 to ... 280 nodes in 0.012 sec -BDD reordering with sifting: from 561 to ... 296 nodes in 0.015 sec -Order before final reordering -2 34 33 66 32 65 31 64 -63 30 62 29 28 61 27 60 -26 59 25 58 24 57 23 56 -22 55 21 54 20 53 19 52 -51 18 50 17 49 16 48 15 -47 14 46 13 45 12 36 3 -37 4 38 5 39 6 40 7 -41 8 42 9 43 10 44 11 -1 -Number of inputs = 65 -BDD reordering with sifting: from 380 to ... 317 nodes in 0.012 sec -New order -1 2 34 66 33 65 32 64 -31 63 30 62 29 61 28 60 -27 59 26 58 25 57 24 56 -23 55 22 54 21 53 20 52 -19 51 18 50 17 49 16 48 -15 47 14 46 13 45 12 36 -3 4 37 5 38 6 39 7 -40 8 41 9 42 10 43 44 -11 -Building transition relation. Time = 0.06 sec -BDD reordering with sifting: from 670 to ... 453 nodes in 0.029 sec -@@BDD reordering with sifting: from 940 to ... 700 nodes in 0.03 sec -@@BDD reordering with sifting: from 1433 to ... 832 nodes in 0.039 sec -@@BDD reordering with sifting: from 1697 to ... 1063 nodes in 0.045 sec -@@@BDD reordering with sifting: from 2159 to ... 786 nodes in 0.049 sec -@@@@BDD reordering with sifting: from 1605 to ... 893 nodes in 0.043 sec -@@@@BDD reordering with sifting: from 1819 to ... 951 nodes in 0.048 sec -@@@@@BDD reordering with sifting: from 1935 to ... 965 nodes in 0.055 sec -@@@@@BDD reordering with sifting: from 1963 to ... 1055 nodes in 0.059 sec -@@@@@ -Transition relation: 1 parts 32 latches 199 nodes -Traversing. Time = 0.46 sec -S0: 33 nodes 1 leaves 1 minterms -From[1]: 33 nodes 1 leaves 2.14748e+09 minterms -Reached[1]: 2 nodes 1 leaves 2.14748e+09 minterms -2147483648 -2.14748e+9 -From[2]: 3 nodes 1 leaves 1.07374e+09 minterms -Reached[2]: 3 nodes 1 leaves 3.22123e+09 minterms -3221225472 -3.22122e+9 -From[3]: 4 nodes 1 leaves 5.36871e+08 minterms -Reached[3]: 4 nodes 1 leaves 3.7581e+09 minterms -3758096384 -3.75809e+9 -From[4]: 5 nodes 1 leaves 2.68435e+08 minterms -Reached[4]: 5 nodes 1 leaves 4.02653e+09 minterms -4026531840 -4.02653e+9 -From[5]: 6 nodes 1 leaves 1.34218e+08 minterms -Reached[5]: 6 nodes 1 leaves 4.16075e+09 minterms -4160749568 -4.16074e+9 -From[6]: 7 nodes 1 leaves 6.71089e+07 minterms -Reached[6]: 7 nodes 1 leaves 4.22786e+09 minterms -4227858432 -4.22785e+9 -From[7]: 8 nodes 1 leaves 3.35544e+07 minterms -Reached[7]: 8 nodes 1 leaves 4.26141e+09 minterms -4261412864 -4.26141e+9 -From[8]: 9 nodes 1 leaves 1.67772e+07 minterms -Reached[8]: 9 nodes 1 leaves 4.27819e+09 minterms -4278190080 -4.27819e+9 -From[9]: 10 nodes 1 leaves 8.38861e+06 minterms -Reached[9]: 10 nodes 1 leaves 4.28658e+09 minterms -4286578688 -4.28657e+9 -From[10]: 11 nodes 1 leaves 4.1943e+06 minterms -Reached[10]: 11 nodes 1 leaves 4.29077e+09 minterms -4290772992 -4.29077e+9 -From[11]: 12 nodes 1 leaves 2.09715e+06 minterms -Reached[11]: 12 nodes 1 leaves 4.29287e+09 minterms -4292870144 -4.29287e+9 -From[12]: 13 nodes 1 leaves 1.04858e+06 minterms -Reached[12]: 13 nodes 1 leaves 4.29392e+09 minterms -4293918720 -4.29391e+9 -From[13]: 14 nodes 1 leaves 524288 minterms -Reached[13]: 14 nodes 1 leaves 4.29444e+09 minterms -4294443008 -4.29444e+9 -From[14]: 15 nodes 1 leaves 262144 minterms -Reached[14]: 15 nodes 1 leaves 4.29471e+09 minterms -4294705152 -4.29470e+9 -From[15]: 16 nodes 1 leaves 131072 minterms -Reached[15]: 16 nodes 1 leaves 4.29484e+09 minterms -4294836224 -4.29483e+9 -From[16]: 17 nodes 1 leaves 65536 minterms -Reached[16]: 17 nodes 1 leaves 4.2949e+09 minterms -4294901760 -4.29490e+9 -From[17]: 18 nodes 1 leaves 32768 minterms -Reached[17]: 18 nodes 1 leaves 4.29493e+09 minterms -4294934528 -4.29493e+9 -From[18]: 19 nodes 1 leaves 16384 minterms -Reached[18]: 19 nodes 1 leaves 4.29495e+09 minterms -4294950912 -4.29495e+9 -From[19]: 20 nodes 1 leaves 8192 minterms -Reached[19]: 20 nodes 1 leaves 4.29496e+09 minterms -4294959104 -4.29495e+9 -From[20]: 21 nodes 1 leaves 4096 minterms -Reached[20]: 21 nodes 1 leaves 4.29496e+09 minterms -4294963200 -4.29496e+9 -From[21]: 22 nodes 1 leaves 2048 minterms -Reached[21]: 22 nodes 1 leaves 4.29497e+09 minterms -4294965248 -4.29496e+9 -From[22]: 23 nodes 1 leaves 1024 minterms -Reached[22]: 23 nodes 1 leaves 4.29497e+09 minterms -4294966272 -4.29496e+9 -From[23]: 24 nodes 1 leaves 512 minterms -Reached[23]: 24 nodes 1 leaves 4.29497e+09 minterms -4294966784 -4.29496e+9 -From[24]: 25 nodes 1 leaves 256 minterms -Reached[24]: 25 nodes 1 leaves 4.29497e+09 minterms -4294967040 -4.29496e+9 -From[25]: 26 nodes 1 leaves 128 minterms -Reached[25]: 26 nodes 1 leaves 4.29497e+09 minterms -4294967168 -4.29496e+9 -From[26]: 27 nodes 1 leaves 64 minterms -Reached[26]: 27 nodes 1 leaves 4.29497e+09 minterms -4294967232 -4.29496e+9 -From[27]: 28 nodes 1 leaves 32 minterms -Reached[27]: 28 nodes 1 leaves 4.29497e+09 minterms -4294967264 -4.29496e+9 -From[28]: 29 nodes 1 leaves 16 minterms -Reached[28]: 29 nodes 1 leaves 4.29497e+09 minterms -4294967280 -4.29496e+9 -From[29]: 30 nodes 1 leaves 8 minterms -Reached[29]: 30 nodes 1 leaves 4.29497e+09 minterms -4294967288 -4.29496e+9 -From[30]: 31 nodes 1 leaves 4 minterms -Reached[30]: 31 nodes 1 leaves 4.29497e+09 minterms -4294967292 -4.29496e+9 -From[31]: 32 nodes 1 leaves 2 minterms -Reached[31]: 32 nodes 1 leaves 4.29497e+09 minterms -4294967294 -4.29496e+9 -From[32]: 33 nodes 1 leaves 1 minterms -Reached[32]: 33 nodes 1 leaves 4.29497e+09 minterms -4294967295 -4.29496e+9 -depth = 32 -R: 33 nodes 1 leaves 4.29497e+09 minterms -Order at the end of reachability analysis -1 2 34 33 66 32 65 31 -64 63 30 29 62 28 61 60 -27 59 26 58 25 57 24 56 -23 55 22 54 21 20 53 19 -52 18 51 17 50 16 49 15 -48 14 47 13 46 12 45 11 -44 10 43 3 36 4 37 5 -38 6 39 7 40 8 41 42 -9 -**** CUDD modifiable parameters **** -Hard limit for cache size: 7645866 -Cache hit threshold for resizing: 30% -Garbage collection enabled: yes -Limit for fast unique table growth: 4587520 -Maximum number of variables sifted per reordering: 1000000 -Maximum number of variable swaps per reordering: 1000000000 -Maximum growth while sifting a variable: 1.2 -Dynamic reordering of BDDs enabled: yes -Default BDD reordering method: 4 -Dynamic reordering of ZDDs enabled: no -Default ZDD reordering method: 4 -Realignment of ZDDs to BDDs enabled: no -Realignment of BDDs to ZDDs enabled: no -Dead nodes counted in triggering reordering: no -Group checking criterion: 7 -Recombination threshold: 0 -Symmetry violation threshold: 10 -Arc violation threshold: 10 -GA population size: 0 -Number of crossovers for GA: 0 -Next reordering threshold: 2178 -**** CUDD non-modifiable parameters **** -Memory in use: 5461692 -Peak number of nodes: 7154 -Peak number of live nodes: 4004 -Number of BDD variables: 97 -Number of ZDD variables: 0 -Number of cache entries: 65536 -Number of cache look-ups: 48730 -Number of cache hits: 20857 -Number of cache insertions: 27828 -Number of cache collisions: 997 -Number of cache deletions: 20076 -Cache used slots = 17.56% (expected 10.31%) -Soft limit for cache size: 100352 -Number of buckets in unique table: 25088 -Used buckets in unique table: 12.29% (expected 12.30%) -Number of BDD and ADD nodes: 3533 -Number of ZDD nodes: 0 -Number of dead BDD and ADD nodes: 3186 -Number of dead ZDD nodes: 0 -Total number of nodes allocated: 23948 -Total number of nodes reclaimed: 3937 -Garbage collections so far: 15 -Time for garbage collection: 0.00 sec -Reorderings so far: 15 -Time for reordering: 0.46 sec -Final size: 275 -total time = 0.47 sec -Runtime Statistics ------------------- -Machine name: jobim.colorado.edu -User time 0.5 seconds -System time 0.0 seconds - -Average resident text size = 0K -Average resident data+stack size = 0K -Maximum resident size = 0K - -Virtual text size = 131815K -Virtual data size = 297K - data size initialized = 25K - data size uninitialized = 137K - data size sbrk = 135K -Virtual memory limit = 358400K (4194304K) - -Major page faults = 0 -Minor page faults = 1754 -Swaps = 0 -Input blocks = 0 -Output blocks = 0 -Context switch (voluntary) = 1 -Context switch (involuntary) = 21 diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/rcn25.out b/resources/3rdparty/cudd-2.5.0/src/nanotrav/rcn25.out deleted file mode 100644 index a44f9703c..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/rcn25.out +++ /dev/null @@ -1,521 +0,0 @@ -# Nanotrav Version #0.12, Release date 2003/12/31 -# ./nanotrav -p 1 -envelope rcn25.blif -# CUDD Version 2.4.2 -Order before final reordering -n0 n1 n2 n3 n4 n5 n6 n7 -n8 n9 n10 n11 n12 n13 n14 n15 -n16 n17 n18 n19 n20 n21 n22 n23 -n24 -Number of inputs = 25 -@@@@@@@@@@@@@@@@@@@@@@@@@ -S0: 1 nodes 1 leaves 3.35544e+07 minterms -Envelope[1]: 68 nodes 1 leaves 1.95734e+07 minterms -Envelope[2]: 131 nodes 1 leaves 1.53791e+07 minterms -Envelope[3]: 240 nodes 1 leaves 1.30489e+07 minterms -Envelope[4]: 351 nodes 1 leaves 1.07188e+07 minterms -Envelope[5]: 365 nodes 1 leaves 9.08766e+06 minterms -Envelope[6]: 672 nodes 1 leaves 7.88374e+06 minterms -Envelope[7]: 977 nodes 1 leaves 6.85458e+06 minterms -Envelope[8]: 1697 nodes 1 leaves 6.16039e+06 minterms -Envelope[9]: 2507 nodes 1 leaves 5.53173e+06 minterms -Envelope[10]: 2728 nodes 1 leaves 4.99328e+06 minterms -Envelope[11]: 4877 nodes 1 leaves 4.56022e+06 minterms -Envelope[12]: 7131 nodes 1 leaves 4.15173e+06 minterms -Envelope[13]: 10837 nodes 1 leaves 3.83181e+06 minterms -Envelope[14]: 16376 nodes 1 leaves 3.53694e+06 minterms -Envelope[15]: 18686 nodes 1 leaves 3.26485e+06 minterms -Envelope[16]: 27175 nodes 1 leaves 3.03016e+06 minterms -Envelope[17]: 37624 nodes 1 leaves 2.81134e+06 minterms -Envelope[18]: 42091 nodes 1 leaves 2.62598e+06 minterms -Envelope[19]: 64761 nodes 1 leaves 2.45532e+06 minterms -Envelope[20]: 88199 nodes 1 leaves 2.29512e+06 minterms -Envelope[21]: 112012 nodes 1 leaves 2.15501e+06 minterms -Envelope[22]: 148131 nodes 1 leaves 2.02284e+06 minterms -Envelope[23]: 178957 nodes 1 leaves 1.90343e+06 minterms -Envelope[24]: 213207 nodes 1 leaves 1.79426e+06 minterms -Envelope[25]: 251015 nodes 1 leaves 1.69064e+06 minterms -Envelope[26]: 278969 nodes 1 leaves 1.59836e+06 minterms -Envelope[27]: 298983 nodes 1 leaves 1.51117e+06 minterms -Envelope[28]: 310186 nodes 1 leaves 1.4295e+06 minterms -Envelope[29]: 314312 nodes 1 leaves 1.35474e+06 minterms -Envelope[30]: 312346 nodes 1 leaves 1.2838e+06 minterms -Envelope[31]: 308909 nodes 1 leaves 1.21948e+06 minterms -Envelope[32]: 304183 nodes 1 leaves 1.15867e+06 minterms -Envelope[33]: 298541 nodes 1 leaves 1.10083e+06 minterms -Envelope[34]: 292868 nodes 1 leaves 1.04754e+06 minterms -Envelope[35]: 286698 nodes 1 leaves 996946 minterms -Envelope[36]: 280610 nodes 1 leaves 949953 minterms -Envelope[37]: 274275 nodes 1 leaves 905778 minterms -Envelope[38]: 267711 nodes 1 leaves 863616 minterms -Envelope[39]: 261513 nodes 1 leaves 824606 minterms -Envelope[40]: 255196 nodes 1 leaves 787378 minterms -Envelope[41]: 248890 nodes 1 leaves 752197 minterms -Envelope[42]: 242617 nodes 1 leaves 719152 minterms -Envelope[43]: 236080 nodes 1 leaves 687560 minterms -Envelope[44]: 230130 nodes 1 leaves 658155 minterms -Envelope[45]: 224259 nodes 1 leaves 629967 minterms -Envelope[46]: 218166 nodes 1 leaves 603079 minterms -Envelope[47]: 212397 nodes 1 leaves 577815 minterms -Envelope[48]: 206597 nodes 1 leaves 553658 minterms -Envelope[49]: 201169 nodes 1 leaves 531033 minterms -Envelope[50]: 195784 nodes 1 leaves 509531 minterms -Envelope[51]: 190388 nodes 1 leaves 488904 minterms -Envelope[52]: 185402 nodes 1 leaves 469490 minterms -Envelope[53]: 180396 nodes 1 leaves 450891 minterms -Envelope[54]: 175724 nodes 1 leaves 433247 minterms -Envelope[55]: 171253 nodes 1 leaves 416458 minterms -Envelope[56]: 166524 nodes 1 leaves 400345 minterms -Envelope[57]: 162304 nodes 1 leaves 385129 minterms -Envelope[58]: 158158 nodes 1 leaves 370518 minterms -Envelope[59]: 154136 nodes 1 leaves 356541 minterms -Envelope[60]: 150218 nodes 1 leaves 343262 minterms -Envelope[61]: 146293 nodes 1 leaves 330504 minterms -Envelope[62]: 142731 nodes 1 leaves 318444 minterms -Envelope[63]: 139152 nodes 1 leaves 306873 minterms -Envelope[64]: 135570 nodes 1 leaves 295766 minterms -Envelope[65]: 132114 nodes 1 leaves 285183 minterms -Envelope[66]: 128777 nodes 1 leaves 275032 minterms -Envelope[67]: 125644 nodes 1 leaves 265348 minterms -Envelope[68]: 122532 nodes 1 leaves 256089 minterms -Envelope[69]: 119388 nodes 1 leaves 247191 minterms -Envelope[70]: 116557 nodes 1 leaves 238707 minterms -Envelope[71]: 113576 nodes 1 leaves 230531 minterms -Envelope[72]: 110737 nodes 1 leaves 222700 minterms -Envelope[73]: 107964 nodes 1 leaves 215170 minterms -Envelope[74]: 105272 nodes 1 leaves 207896 minterms -Envelope[75]: 102720 nodes 1 leaves 200935 minterms -Envelope[76]: 100098 nodes 1 leaves 194214 minterms -Envelope[77]: 97630 nodes 1 leaves 187719 minterms -Envelope[78]: 95248 nodes 1 leaves 181488 minterms -Envelope[79]: 92891 nodes 1 leaves 175479 minterms -Envelope[80]: 90738 nodes 1 leaves 169733 minterms -Envelope[81]: 88566 nodes 1 leaves 164201 minterms -Envelope[82]: 86372 nodes 1 leaves 158855 minterms -Envelope[83]: 84200 nodes 1 leaves 153722 minterms -Envelope[84]: 82108 nodes 1 leaves 148752 minterms -Envelope[85]: 80162 nodes 1 leaves 143977 minterms -Envelope[86]: 78254 nodes 1 leaves 139369 minterms -Envelope[87]: 76349 nodes 1 leaves 134921 minterms -Envelope[88]: 74645 nodes 1 leaves 130668 minterms -Envelope[89]: 72849 nodes 1 leaves 126558 minterms -Envelope[90]: 71140 nodes 1 leaves 122588 minterms -Envelope[91]: 69484 nodes 1 leaves 118779 minterms -Envelope[92]: 67898 nodes 1 leaves 115076 minterms -Envelope[93]: 66429 nodes 1 leaves 111539 minterms -Envelope[94]: 64879 nodes 1 leaves 108113 minterms -Envelope[95]: 63332 nodes 1 leaves 104807 minterms -Envelope[96]: 61892 nodes 1 leaves 101634 minterms -Envelope[97]: 60487 nodes 1 leaves 98554 minterms -Envelope[98]: 59076 nodes 1 leaves 95579 minterms -Envelope[99]: 57675 nodes 1 leaves 92712 minterms -Envelope[100]: 56346 nodes 1 leaves 89943 minterms -Envelope[101]: 55101 nodes 1 leaves 87270 minterms -Envelope[102]: 53857 nodes 1 leaves 84669 minterms -Envelope[103]: 52673 nodes 1 leaves 82155 minterms -Envelope[104]: 51498 nodes 1 leaves 79722 minterms -Envelope[105]: 50375 nodes 1 leaves 77355 minterms -Envelope[106]: 49253 nodes 1 leaves 75077 minterms -Envelope[107]: 48157 nodes 1 leaves 72867 minterms -Envelope[108]: 47096 nodes 1 leaves 70729 minterms -Envelope[109]: 46100 nodes 1 leaves 68652 minterms -Envelope[110]: 45047 nodes 1 leaves 66635 minterms -Envelope[111]: 44107 nodes 1 leaves 64689 minterms -Envelope[112]: 43198 nodes 1 leaves 62806 minterms -Envelope[113]: 42227 nodes 1 leaves 60981 minterms -Envelope[114]: 41297 nodes 1 leaves 59228 minterms -Envelope[115]: 40371 nodes 1 leaves 57524 minterms -Envelope[116]: 39479 nodes 1 leaves 55874 minterms -Envelope[117]: 38623 nodes 1 leaves 54279 minterms -Envelope[118]: 37792 nodes 1 leaves 52739 minterms -Envelope[119]: 37000 nodes 1 leaves 51264 minterms -Envelope[120]: 36185 nodes 1 leaves 49837 minterms -Envelope[121]: 35400 nodes 1 leaves 48443 minterms -Envelope[122]: 34580 nodes 1 leaves 47093 minterms -Envelope[123]: 33793 nodes 1 leaves 45782 minterms -Envelope[124]: 33084 nodes 1 leaves 44519 minterms -Envelope[125]: 32388 nodes 1 leaves 43292 minterms -Envelope[126]: 31710 nodes 1 leaves 42089 minterms -Envelope[127]: 31025 nodes 1 leaves 40920 minterms -Envelope[128]: 30350 nodes 1 leaves 39778 minterms -Envelope[129]: 29683 nodes 1 leaves 38664 minterms -Envelope[130]: 29050 nodes 1 leaves 37589 minterms -Envelope[131]: 28418 nodes 1 leaves 36551 minterms -Envelope[132]: 27804 nodes 1 leaves 35547 minterms -Envelope[133]: 27184 nodes 1 leaves 34573 minterms -Envelope[134]: 26621 nodes 1 leaves 33636 minterms -Envelope[135]: 26074 nodes 1 leaves 32724 minterms -Envelope[136]: 25528 nodes 1 leaves 31831 minterms -Envelope[137]: 24996 nodes 1 leaves 30967 minterms -Envelope[138]: 24472 nodes 1 leaves 30133 minterms -Envelope[139]: 23993 nodes 1 leaves 29324 minterms -Envelope[140]: 23514 nodes 1 leaves 28535 minterms -Envelope[141]: 23008 nodes 1 leaves 27769 minterms -Envelope[142]: 22525 nodes 1 leaves 27029 minterms -Envelope[143]: 22039 nodes 1 leaves 26318 minterms -Envelope[144]: 21561 nodes 1 leaves 25624 minterms -Envelope[145]: 21094 nodes 1 leaves 24950 minterms -Envelope[146]: 20685 nodes 1 leaves 24289 minterms -Envelope[147]: 20249 nodes 1 leaves 23651 minterms -Envelope[148]: 19794 nodes 1 leaves 23023 minterms -Envelope[149]: 19369 nodes 1 leaves 22418 minterms -Envelope[150]: 18976 nodes 1 leaves 21837 minterms -Envelope[151]: 18589 nodes 1 leaves 21272 minterms -Envelope[152]: 18201 nodes 1 leaves 20723 minterms -Envelope[153]: 17806 nodes 1 leaves 20198 minterms -Envelope[154]: 17419 nodes 1 leaves 19684 minterms -Envelope[155]: 17049 nodes 1 leaves 19180 minterms -Envelope[156]: 16672 nodes 1 leaves 18691 minterms -Envelope[157]: 16315 nodes 1 leaves 18214 minterms -Envelope[158]: 16005 nodes 1 leaves 17741 minterms -Envelope[159]: 15679 nodes 1 leaves 17284 minterms -Envelope[160]: 15341 nodes 1 leaves 16836 minterms -Envelope[161]: 14999 nodes 1 leaves 16397 minterms -Envelope[162]: 14667 nodes 1 leaves 15962 minterms -Envelope[163]: 14365 nodes 1 leaves 15544 minterms -Envelope[164]: 14066 nodes 1 leaves 15138 minterms -Envelope[165]: 13792 nodes 1 leaves 14743 minterms -Envelope[166]: 13539 nodes 1 leaves 14361 minterms -Envelope[167]: 13283 nodes 1 leaves 13992 minterms -Envelope[168]: 13022 nodes 1 leaves 13632 minterms -Envelope[169]: 12765 nodes 1 leaves 13280 minterms -Envelope[170]: 12497 nodes 1 leaves 12938 minterms -Envelope[171]: 12257 nodes 1 leaves 12605 minterms -Envelope[172]: 11990 nodes 1 leaves 12279 minterms -Envelope[173]: 11716 nodes 1 leaves 11958 minterms -Envelope[174]: 11436 nodes 1 leaves 11646 minterms -Envelope[175]: 11180 nodes 1 leaves 11345 minterms -Envelope[176]: 10939 nodes 1 leaves 11056 minterms -Envelope[177]: 10717 nodes 1 leaves 10771 minterms -Envelope[178]: 10488 nodes 1 leaves 10493 minterms -Envelope[179]: 10255 nodes 1 leaves 10221 minterms -Envelope[180]: 10013 nodes 1 leaves 9957 minterms -Envelope[181]: 9810 nodes 1 leaves 9699 minterms -Envelope[182]: 9568 nodes 1 leaves 9449 minterms -Envelope[183]: 9355 nodes 1 leaves 9206 minterms -Envelope[184]: 9176 nodes 1 leaves 8967 minterms -Envelope[185]: 8990 nodes 1 leaves 8733 minterms -Envelope[186]: 8810 nodes 1 leaves 8512 minterms -Envelope[187]: 8621 nodes 1 leaves 8297 minterms -Envelope[188]: 8421 nodes 1 leaves 8091 minterms -Envelope[189]: 8200 nodes 1 leaves 7895 minterms -Envelope[190]: 7992 nodes 1 leaves 7705 minterms -Envelope[191]: 7816 nodes 1 leaves 7519 minterms -Envelope[192]: 7641 nodes 1 leaves 7338 minterms -Envelope[193]: 7475 nodes 1 leaves 7161 minterms -Envelope[194]: 7307 nodes 1 leaves 6986 minterms -Envelope[195]: 7137 nodes 1 leaves 6814 minterms -Envelope[196]: 6956 nodes 1 leaves 6644 minterms -Envelope[197]: 6784 nodes 1 leaves 6477 minterms -Envelope[198]: 6642 nodes 1 leaves 6315 minterms -Envelope[199]: 6515 nodes 1 leaves 6157 minterms -Envelope[200]: 6377 nodes 1 leaves 6000 minterms -Envelope[201]: 6221 nodes 1 leaves 5847 minterms -Envelope[202]: 6069 nodes 1 leaves 5699 minterms -Envelope[203]: 5919 nodes 1 leaves 5555 minterms -Envelope[204]: 5797 nodes 1 leaves 5417 minterms -Envelope[205]: 5662 nodes 1 leaves 5282 minterms -Envelope[206]: 5535 nodes 1 leaves 5149 minterms -Envelope[207]: 5414 nodes 1 leaves 5018 minterms -Envelope[208]: 5293 nodes 1 leaves 4890 minterms -Envelope[209]: 5170 nodes 1 leaves 4765 minterms -Envelope[210]: 5057 nodes 1 leaves 4644 minterms -Envelope[211]: 4948 nodes 1 leaves 4526 minterms -Envelope[212]: 4856 nodes 1 leaves 4410 minterms -Envelope[213]: 4763 nodes 1 leaves 4296 minterms -Envelope[214]: 4651 nodes 1 leaves 4183 minterms -Envelope[215]: 4568 nodes 1 leaves 4076 minterms -Envelope[216]: 4488 nodes 1 leaves 3972 minterms -Envelope[217]: 4406 nodes 1 leaves 3869 minterms -Envelope[218]: 4322 nodes 1 leaves 3771 minterms -Envelope[219]: 4249 nodes 1 leaves 3677 minterms -Envelope[220]: 4177 nodes 1 leaves 3586 minterms -Envelope[221]: 4102 nodes 1 leaves 3496 minterms -Envelope[222]: 4021 nodes 1 leaves 3408 minterms -Envelope[223]: 3949 nodes 1 leaves 3322 minterms -Envelope[224]: 3871 nodes 1 leaves 3238 minterms -Envelope[225]: 3800 nodes 1 leaves 3158 minterms -Envelope[226]: 3740 nodes 1 leaves 3079 minterms -Envelope[227]: 3674 nodes 1 leaves 3002 minterms -Envelope[228]: 3618 nodes 1 leaves 2926 minterms -Envelope[229]: 3552 nodes 1 leaves 2852 minterms -Envelope[230]: 3485 nodes 1 leaves 2780 minterms -Envelope[231]: 3428 nodes 1 leaves 2711 minterms -Envelope[232]: 3370 nodes 1 leaves 2643 minterms -Envelope[233]: 3304 nodes 1 leaves 2575 minterms -Envelope[234]: 3244 nodes 1 leaves 2510 minterms -Envelope[235]: 3177 nodes 1 leaves 2447 minterms -Envelope[236]: 3112 nodes 1 leaves 2385 minterms -Envelope[237]: 3054 nodes 1 leaves 2324 minterms -Envelope[238]: 2999 nodes 1 leaves 2268 minterms -Envelope[239]: 2947 nodes 1 leaves 2212 minterms -Envelope[240]: 2892 nodes 1 leaves 2157 minterms -Envelope[241]: 2831 nodes 1 leaves 2104 minterms -Envelope[242]: 2769 nodes 1 leaves 2052 minterms -Envelope[243]: 2709 nodes 1 leaves 2001 minterms -Envelope[244]: 2644 nodes 1 leaves 1952 minterms -Envelope[245]: 2569 nodes 1 leaves 1903 minterms -Envelope[246]: 2505 nodes 1 leaves 1855 minterms -Envelope[247]: 2432 nodes 1 leaves 1807 minterms -Envelope[248]: 2361 nodes 1 leaves 1760 minterms -Envelope[249]: 2289 nodes 1 leaves 1715 minterms -Envelope[250]: 2215 nodes 1 leaves 1673 minterms -Envelope[251]: 2169 nodes 1 leaves 1632 minterms -Envelope[252]: 2114 nodes 1 leaves 1591 minterms -Envelope[253]: 2063 nodes 1 leaves 1551 minterms -Envelope[254]: 2011 nodes 1 leaves 1512 minterms -Envelope[255]: 1957 nodes 1 leaves 1473 minterms -Envelope[256]: 1902 nodes 1 leaves 1434 minterms -Envelope[257]: 1852 nodes 1 leaves 1396 minterms -Envelope[258]: 1805 nodes 1 leaves 1359 minterms -Envelope[259]: 1763 nodes 1 leaves 1322 minterms -Envelope[260]: 1711 nodes 1 leaves 1287 minterms -Envelope[261]: 1653 nodes 1 leaves 1255 minterms -Envelope[262]: 1604 nodes 1 leaves 1223 minterms -Envelope[263]: 1557 nodes 1 leaves 1193 minterms -Envelope[264]: 1515 nodes 1 leaves 1164 minterms -Envelope[265]: 1482 nodes 1 leaves 1136 minterms -Envelope[266]: 1447 nodes 1 leaves 1108 minterms -Envelope[267]: 1416 nodes 1 leaves 1081 minterms -Envelope[268]: 1383 nodes 1 leaves 1054 minterms -Envelope[269]: 1353 nodes 1 leaves 1028 minterms -Envelope[270]: 1323 nodes 1 leaves 1003 minterms -Envelope[271]: 1290 nodes 1 leaves 978 minterms -Envelope[272]: 1252 nodes 1 leaves 954 minterms -Envelope[273]: 1215 nodes 1 leaves 931 minterms -Envelope[274]: 1174 nodes 1 leaves 908 minterms -Envelope[275]: 1144 nodes 1 leaves 887 minterms -Envelope[276]: 1120 nodes 1 leaves 867 minterms -Envelope[277]: 1102 nodes 1 leaves 848 minterms -Envelope[278]: 1082 nodes 1 leaves 830 minterms -Envelope[279]: 1061 nodes 1 leaves 812 minterms -Envelope[280]: 1045 nodes 1 leaves 795 minterms -Envelope[281]: 1031 nodes 1 leaves 778 minterms -Envelope[282]: 1015 nodes 1 leaves 763 minterms -Envelope[283]: 1004 nodes 1 leaves 748 minterms -Envelope[284]: 996 nodes 1 leaves 733 minterms -Envelope[285]: 983 nodes 1 leaves 719 minterms -Envelope[286]: 964 nodes 1 leaves 705 minterms -Envelope[287]: 949 nodes 1 leaves 691 minterms -Envelope[288]: 938 nodes 1 leaves 677 minterms -Envelope[289]: 925 nodes 1 leaves 663 minterms -Envelope[290]: 913 nodes 1 leaves 650 minterms -Envelope[291]: 907 nodes 1 leaves 637 minterms -Envelope[292]: 901 nodes 1 leaves 624 minterms -Envelope[293]: 887 nodes 1 leaves 611 minterms -Envelope[294]: 878 nodes 1 leaves 598 minterms -Envelope[295]: 872 nodes 1 leaves 585 minterms -Envelope[296]: 860 nodes 1 leaves 573 minterms -Envelope[297]: 852 nodes 1 leaves 561 minterms -Envelope[298]: 842 nodes 1 leaves 549 minterms -Envelope[299]: 834 nodes 1 leaves 537 minterms -Envelope[300]: 826 nodes 1 leaves 526 minterms -Envelope[301]: 819 nodes 1 leaves 515 minterms -Envelope[302]: 808 nodes 1 leaves 505 minterms -Envelope[303]: 797 nodes 1 leaves 495 minterms -Envelope[304]: 789 nodes 1 leaves 485 minterms -Envelope[305]: 773 nodes 1 leaves 475 minterms -Envelope[306]: 758 nodes 1 leaves 465 minterms -Envelope[307]: 742 nodes 1 leaves 455 minterms -Envelope[308]: 727 nodes 1 leaves 445 minterms -Envelope[309]: 711 nodes 1 leaves 435 minterms -Envelope[310]: 698 nodes 1 leaves 425 minterms -Envelope[311]: 677 nodes 1 leaves 415 minterms -Envelope[312]: 662 nodes 1 leaves 405 minterms -Envelope[313]: 653 nodes 1 leaves 395 minterms -Envelope[314]: 638 nodes 1 leaves 386 minterms -Envelope[315]: 625 nodes 1 leaves 377 minterms -Envelope[316]: 611 nodes 1 leaves 368 minterms -Envelope[317]: 603 nodes 1 leaves 359 minterms -Envelope[318]: 598 nodes 1 leaves 350 minterms -Envelope[319]: 588 nodes 1 leaves 342 minterms -Envelope[320]: 581 nodes 1 leaves 334 minterms -Envelope[321]: 576 nodes 1 leaves 326 minterms -Envelope[322]: 566 nodes 1 leaves 318 minterms -Envelope[323]: 555 nodes 1 leaves 311 minterms -Envelope[324]: 546 nodes 1 leaves 305 minterms -Envelope[325]: 537 nodes 1 leaves 299 minterms -Envelope[326]: 526 nodes 1 leaves 293 minterms -Envelope[327]: 515 nodes 1 leaves 287 minterms -Envelope[328]: 505 nodes 1 leaves 281 minterms -Envelope[329]: 493 nodes 1 leaves 275 minterms -Envelope[330]: 481 nodes 1 leaves 270 minterms -Envelope[331]: 468 nodes 1 leaves 265 minterms -Envelope[332]: 455 nodes 1 leaves 260 minterms -Envelope[333]: 446 nodes 1 leaves 255 minterms -Envelope[334]: 438 nodes 1 leaves 250 minterms -Envelope[335]: 433 nodes 1 leaves 245 minterms -Envelope[336]: 430 nodes 1 leaves 240 minterms -Envelope[337]: 421 nodes 1 leaves 235 minterms -Envelope[338]: 415 nodes 1 leaves 230 minterms -Envelope[339]: 405 nodes 1 leaves 225 minterms -Envelope[340]: 397 nodes 1 leaves 220 minterms -Envelope[341]: 390 nodes 1 leaves 215 minterms -Envelope[342]: 382 nodes 1 leaves 210 minterms -Envelope[343]: 374 nodes 1 leaves 205 minterms -Envelope[344]: 368 nodes 1 leaves 200 minterms -Envelope[345]: 357 nodes 1 leaves 195 minterms -Envelope[346]: 349 nodes 1 leaves 190 minterms -Envelope[347]: 345 nodes 1 leaves 185 minterms -Envelope[348]: 343 nodes 1 leaves 180 minterms -Envelope[349]: 338 nodes 1 leaves 175 minterms -Envelope[350]: 329 nodes 1 leaves 170 minterms -Envelope[351]: 318 nodes 1 leaves 165 minterms -Envelope[352]: 312 nodes 1 leaves 160 minterms -Envelope[353]: 305 nodes 1 leaves 156 minterms -Envelope[354]: 298 nodes 1 leaves 152 minterms -Envelope[355]: 291 nodes 1 leaves 148 minterms -Envelope[356]: 284 nodes 1 leaves 144 minterms -Envelope[357]: 274 nodes 1 leaves 140 minterms -Envelope[358]: 267 nodes 1 leaves 136 minterms -Envelope[359]: 258 nodes 1 leaves 132 minterms -Envelope[360]: 250 nodes 1 leaves 129 minterms -Envelope[361]: 242 nodes 1 leaves 126 minterms -Envelope[362]: 239 nodes 1 leaves 123 minterms -Envelope[363]: 230 nodes 1 leaves 120 minterms -Envelope[364]: 224 nodes 1 leaves 117 minterms -Envelope[365]: 218 nodes 1 leaves 114 minterms -Envelope[366]: 217 nodes 1 leaves 111 minterms -Envelope[367]: 216 nodes 1 leaves 108 minterms -Envelope[368]: 214 nodes 1 leaves 105 minterms -Envelope[369]: 213 nodes 1 leaves 102 minterms -Envelope[370]: 213 nodes 1 leaves 99 minterms -Envelope[371]: 210 nodes 1 leaves 96 minterms -Envelope[372]: 206 nodes 1 leaves 93 minterms -Envelope[373]: 203 nodes 1 leaves 90 minterms -Envelope[374]: 199 nodes 1 leaves 87 minterms -Envelope[375]: 195 nodes 1 leaves 84 minterms -Envelope[376]: 191 nodes 1 leaves 81 minterms -Envelope[377]: 188 nodes 1 leaves 78 minterms -Envelope[378]: 186 nodes 1 leaves 75 minterms -Envelope[379]: 184 nodes 1 leaves 72 minterms -Envelope[380]: 183 nodes 1 leaves 70 minterms -Envelope[381]: 183 nodes 1 leaves 68 minterms -Envelope[382]: 182 nodes 1 leaves 66 minterms -Envelope[383]: 181 nodes 1 leaves 64 minterms -Envelope[384]: 179 nodes 1 leaves 62 minterms -Envelope[385]: 179 nodes 1 leaves 60 minterms -Envelope[386]: 178 nodes 1 leaves 58 minterms -Envelope[387]: 177 nodes 1 leaves 56 minterms -Envelope[388]: 175 nodes 1 leaves 54 minterms -Envelope[389]: 171 nodes 1 leaves 52 minterms -Envelope[390]: 168 nodes 1 leaves 50 minterms -Envelope[391]: 164 nodes 1 leaves 48 minterms -Envelope[392]: 159 nodes 1 leaves 46 minterms -Envelope[393]: 153 nodes 1 leaves 45 minterms -Envelope[394]: 148 nodes 1 leaves 44 minterms -Envelope[395]: 144 nodes 1 leaves 43 minterms -Envelope[396]: 140 nodes 1 leaves 42 minterms -Envelope[397]: 135 nodes 1 leaves 41 minterms -Envelope[398]: 132 nodes 1 leaves 40 minterms -Envelope[399]: 127 nodes 1 leaves 39 minterms -Envelope[400]: 122 nodes 1 leaves 38 minterms -Envelope[401]: 118 nodes 1 leaves 37 minterms -Envelope[402]: 114 nodes 1 leaves 36 minterms -Envelope[403]: 107 nodes 1 leaves 35 minterms -Envelope[404]: 100 nodes 1 leaves 34 minterms -Envelope[405]: 95 nodes 1 leaves 33 minterms -Envelope[406]: 92 nodes 1 leaves 32 minterms -Envelope[407]: 89 nodes 1 leaves 31 minterms -Envelope[408]: 84 nodes 1 leaves 30 minterms -Envelope[409]: 81 nodes 1 leaves 29 minterms -Envelope[410]: 78 nodes 1 leaves 28 minterms -Envelope[411]: 73 nodes 1 leaves 27 minterms -Envelope[412]: 70 nodes 1 leaves 26 minterms -Envelope[413]: 67 nodes 1 leaves 25 minterms -Envelope[414]: 63 nodes 1 leaves 24 minterms -Envelope[415]: 59 nodes 1 leaves 23 minterms -Envelope[416]: 56 nodes 1 leaves 22 minterms -Envelope[417]: 55 nodes 1 leaves 21 minterms -Envelope[418]: 54 nodes 1 leaves 20 minterms -Envelope[419]: 53 nodes 1 leaves 19 minterms -Envelope[420]: 52 nodes 1 leaves 18 minterms -Envelope[421]: 52 nodes 1 leaves 17 minterms -Envelope[422]: 50 nodes 1 leaves 16 minterms -Envelope[423]: 47 nodes 1 leaves 15 minterms -Envelope[424]: 44 nodes 1 leaves 14 minterms -Envelope[425]: 40 nodes 1 leaves 13 minterms -Envelope[426]: 36 nodes 1 leaves 12 minterms -Envelope[427]: 33 nodes 1 leaves 11 minterms -Envelope[428]: 31 nodes 1 leaves 10 minterms -Envelope[429]: 30 nodes 1 leaves 9 minterms -Envelope[430]: 29 nodes 1 leaves 8 minterms -Envelope[431]: 29 nodes 1 leaves 7 minterms -Envelope[432]: 29 nodes 1 leaves 6 minterms -Envelope[433]: 28 nodes 1 leaves 5 minterms -Envelope[434]: 27 nodes 1 leaves 4 minterms -depth = 434 -Envelope: 27 nodes 1 leaves 4 minterms -**** CUDD modifiable parameters **** -Hard limit for cache size: 7645866 -Cache hit threshold for resizing: 30% -Garbage collection enabled: yes -Limit for fast unique table growth: 4587520 -Maximum number of variables sifted per reordering: 1000 -Maximum number of variable swaps per reordering: 2000000 -Maximum growth while sifting a variable: 1.2 -Dynamic reordering of BDDs enabled: no -Default BDD reordering method: 4 -Dynamic reordering of ZDDs enabled: no -Default ZDD reordering method: 4 -Realignment of ZDDs to BDDs enabled: no -Realignment of BDDs to ZDDs enabled: no -Dead nodes counted in triggering reordering: no -Group checking criterion: 7 -Recombination threshold: 0 -Symmetry violation threshold: 10 -Arc violation threshold: 10 -GA population size: 0 -Number of crossovers for GA: 0 -Next reordering threshold: 4004 -**** CUDD non-modifiable parameters **** -Memory in use: 240456716 -Peak number of nodes: 9643592 -Peak number of live nodes: 3171948 -Number of BDD variables: 50 -Number of ZDD variables: 0 -Number of cache entries: 4194304 -Number of cache look-ups: 53170021 -Number of cache hits: 30653976 -Number of cache insertions: 22515985 -Number of cache collisions: 15665382 -Number of cache deletions: 3483568 -Cache used slots = 97.84% (expected 98.41%) -Soft limit for cache size: 7645866 -Number of buckets in unique table: 3677184 -Used buckets in unique table: 71.16% (expected 71.15%) -Number of BDD and ADD nodes: 5843265 -Number of ZDD nodes: 0 -Number of dead BDD and ADD nodes: 4325974 -Number of dead ZDD nodes: 0 -Total number of nodes allocated: 15264438 -Total number of nodes reclaimed: 7806126 -Garbage collections so far: 2 -Time for garbage collection: 2.38 sec -Reorderings so far: 0 -Time for reordering: 0.00 sec -Final size: 869 -total time = 66.53 sec -Runtime Statistics ------------------- -Machine name: jobim.colorado.edu -User time 66.5 seconds -System time 0.6 seconds - -Average resident text size = 0K -Average resident data+stack size = 0K -Maximum resident size = 0K - -Virtual text size = 131815K -Virtual data size = 297K - data size initialized = 25K - data size uninitialized = 137K - data size sbrk = 135K -Virtual memory limit = 358400K (4194304K) - -Major page faults = 5 -Minor page faults = 80223 -Swaps = 0 -Input blocks = 0 -Output blocks = 0 -Context switch (voluntary) = 6 -Context switch (involuntary) = 1991 diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/s27.out b/resources/3rdparty/cudd-2.5.0/src/nanotrav/s27.out deleted file mode 100644 index b9746f6c2..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/s27.out +++ /dev/null @@ -1,95 +0,0 @@ -# Nanotrav Version #0.12, Release date 2003/12/31 -# ./nanotrav -p 1 -trav s27.blif -# CUDD Version 2.4.2 -Order before final reordering -G0 G1 G2 G3 G5 G6 G7 -Number of inputs = 7 -Building transition relation. Time = 0.00 sec -@@@ -Transition relation: 1 parts 3 latches 9 nodes -Traversing. Time = 0.00 sec -S0: 4 nodes 1 leaves 1 minterms -From[1]: 5 nodes 1 leaves 4 minterms -Reached[1]: 5 nodes 1 leaves 5 minterms -5 -5e+0 -From[2]: 4 nodes 1 leaves 1 minterms -Reached[2]: 3 nodes 1 leaves 6 minterms -6 -6e+0 -depth = 2 -R: 3 nodes 1 leaves 6 minterms -**** CUDD modifiable parameters **** -Hard limit for cache size: 7645866 -Cache hit threshold for resizing: 30% -Garbage collection enabled: yes -Limit for fast unique table growth: 4587520 -Maximum number of variables sifted per reordering: 1000 -Maximum number of variable swaps per reordering: 2000000 -Maximum growth while sifting a variable: 1.2 -Dynamic reordering of BDDs enabled: no -Default BDD reordering method: 4 -Dynamic reordering of ZDDs enabled: no -Default ZDD reordering method: 4 -Realignment of ZDDs to BDDs enabled: no -Realignment of BDDs to ZDDs enabled: no -Dead nodes counted in triggering reordering: no -Group checking criterion: 7 -Recombination threshold: 0 -Symmetry violation threshold: 10 -Arc violation threshold: 10 -GA population size: 0 -Number of crossovers for GA: 0 -Next reordering threshold: 4004 -**** CUDD non-modifiable parameters **** -Memory in use: 4737772 -Peak number of nodes: 1022 -Peak number of live nodes: 95 -Number of BDD variables: 10 -Number of ZDD variables: 0 -Number of cache entries: 32768 -Number of cache look-ups: 180 -Number of cache hits: 26 -Number of cache insertions: 151 -Number of cache collisions: 1 -Number of cache deletions: 0 -Cache used slots = 0.46% (expected 0.46%) -Soft limit for cache size: 11264 -Number of buckets in unique table: 2816 -Used buckets in unique table: 4.97% (expected 5.15%) -Number of BDD and ADD nodes: 150 -Number of ZDD nodes: 0 -Number of dead BDD and ADD nodes: 75 -Number of dead ZDD nodes: 0 -Total number of nodes allocated: 150 -Total number of nodes reclaimed: 12 -Garbage collections so far: 0 -Time for garbage collection: 0.00 sec -Reorderings so far: 0 -Time for reordering: 0.00 sec -Final size: 16 -total time = 0.00 sec -Runtime Statistics ------------------- -Machine name: jobim.colorado.edu -User time 0.0 seconds -System time 0.0 seconds - -Average resident text size = 0K -Average resident data+stack size = 0K -Maximum resident size = 0K - -Virtual text size = 131815K -Virtual data size = 297K - data size initialized = 25K - data size uninitialized = 137K - data size sbrk = 135K -Virtual memory limit = 358400K (4194304K) - -Major page faults = 0 -Minor page faults = 1424 -Swaps = 0 -Input blocks = 0 -Output blocks = 0 -Context switch (voluntary) = 1 -Context switch (involuntary) = 0 diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/tst.sh b/resources/3rdparty/cudd-2.5.0/src/nanotrav/tst.sh deleted file mode 100644 index c51e67e29..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/tst.sh +++ /dev/null @@ -1,9 +0,0 @@ -#! /bin/sh -# -# $Id: tst.sh,v 1.2 1998/05/03 08:41:38 fabio Exp fabio $ -# -./nanotrav -p 1 -cover C17.blif > C17.tst -./nanotrav -p 1 -ordering dfs -autodyn -automethod sifting -reordering sifting -drop C880.blif > C880.tst -./nanotrav -p 1 -trav s27.blif > s27.tst -./nanotrav -p 1 -autodyn -reordering sifting -trav mult32a.blif > mult32a.tst -./nanotrav -p 1 -envelope rcn25.blif > rcn25.tst diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ucbqsort.c b/resources/3rdparty/cudd-2.5.0/src/nanotrav/ucbqsort.c deleted file mode 100644 index 376feafdd..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ucbqsort.c +++ /dev/null @@ -1,208 +0,0 @@ -#include "ucbqsort.h" -#if defined(__GNUC__) && (__GNUC__ >2 || __GNUC_MINOR__ >=7) -#define UNUSED __attribute__ ((unused)) -#else -#define UNUSED -#endif - -#ifndef lint -static char rcsid[] UNUSED = "$Id: ucbqsort.c,v 1.4 2004/01/01 07:06:06 fabio Exp $"; -#endif - -/* @(#)qsort.c 4.2 (Berkeley) 3/9/83 */ - -/* - * qsort.c: - * Our own version of the system qsort routine which is faster by an average - * of 25%, with lows and highs of 10% and 50%. - * The THRESHold below is the insertion sort threshold, and has been adjusted - * for records of size 48 bytes. - * The MTHREShold is where we stop finding a better median. - */ - -/* - * qsort: - * First, set up some global parameters for qst to share. Then, quicksort - * with qst(), and then a cleanup insertion sort ourselves. Sound simple? - * It's not... - */ -#undef min -#undef max -void -cudd__qsort( - void *base, - int n, - int size, - QSFP compar) -{ - register char c, *i, *j, *lo, *hi; - char *min, *max; - - if (n <= 1) - return; - qsz = size; - qcmp = compar; - thresh = qsz * THRESH; - mthresh = qsz * MTHRESH; - max = ((char*)base) + n * qsz; - if (n >= THRESH) { - qst(base, max); - hi = ((char*)base) + thresh; - } else { - hi = max; - } - /* - * First put smallest element, which must be in the first THRESH, in - * the first position as a sentinel. This is done just by searching - * the first THRESH elements (or the first n if n < THRESH), finding - * the min, and swapping it into the first position. - */ - for (j = lo = ((char*)base); (lo += qsz) < hi; ) - if ((*qcmp)(j, lo) > 0) - j = lo; - if (j != base) { - /* swap j into place */ - for (i = ((char*)base), hi = ((char*)base) + qsz; i < hi; ) { - c = *j; - *j++ = *i; - *i++ = c; - } - } - /* - * With our sentinel in place, we now run the following hyper-fast - * insertion sort. For each remaining element, min, from [1] to [n-1], - * set hi to the index of the element AFTER which this one goes. - * Then, do the standard insertion sort shift on a character at a time - * basis for each element in the frob. - */ - for (min = ((char*)base); (hi = min += qsz) < max; ) { - while ((*qcmp)(hi -= qsz, min) > 0) - /* void */; - if ((hi += qsz) != min) { - for (lo = min + qsz; --lo >= min; ) { - c = *lo; - for (i = j = lo; (j -= qsz) >= hi; i = j) - *i = *j; - *i = c; - } - } - } -} - -/* - * qst: - * Do a quicksort - * First, find the median element, and put that one in the first place as the - * discriminator. (This "median" is just the median of the first, last and - * middle elements). (Using this median instead of the first element is a big - * win). Then, the usual partitioning/swapping, followed by moving the - * discriminator into the right place. Then, figure out the sizes of the two - * partions, do the smaller one recursively and the larger one via a repeat of - * this code. Stopping when there are less than THRESH elements in a partition - * and cleaning up with an insertion sort (in our caller) is a huge win. - * All data swaps are done in-line, which is space-losing but time-saving. - * (And there are only three places where this is done). - */ - -void -qst(void *base, char *max) -{ - register char c, *i, *j, *jj; - register int ii; - char *mid, *tmp; - size_t lo, hi; - - /* - * At the top here, lo is the number of characters of elements in the - * current partition. (Which should be max - base). - * Find the median of the first, last, and middle element and make - * that the middle element. Set j to largest of first and middle. - * If max is larger than that guy, then it's that guy, else compare - * max with loser of first and take larger. Things are set up to - * prefer the middle, then the first in case of ties. - */ - lo = max - ((char*)base); /* number of elements as chars */ - do { - mid = i = ((char*)base) + qsz * ((lo / qsz) >> 1); - if (lo >= mthresh) { - j = ((*qcmp)((jj = ((char*)base)), i) > 0 ? jj : i); - if ((*qcmp)(j, (tmp = max - qsz)) > 0) { - /* switch to first loser */ - j = (j == jj ? i : jj); - if ((*qcmp)(j, tmp) < 0) - j = tmp; - } - if (j != i) { - ii = qsz; - do { - c = *i; - *i++ = *j; - *j++ = c; - } while (--ii); - } - } - /* - * Semi-standard quicksort partitioning/swapping - */ - for (i = ((char*)base), j = max - qsz; ; ) { - while (i < mid && (*qcmp)(i, mid) <= 0) - i += qsz; - while (j > mid) { - if ((*qcmp)(mid, j) <= 0) { - j -= qsz; - continue; - } - tmp = i + qsz; /* value of i after swap */ - if (i == mid) { - /* j <-> mid, new mid is j */ - mid = jj = j; - } else { - /* i <-> j */ - jj = j; - j -= qsz; - } - goto swap; - } - if (i == mid) { - break; - } else { - /* i <-> mid, new mid is i */ - jj = mid; - tmp = mid = i; /* value of i after swap */ - j -= qsz; - } - swap: - ii = qsz; - do { - c = *i; - *i++ = *jj; - *jj++ = c; - } while (--ii); - i = tmp; - } - /* - * Look at sizes of the two partitions, do the smaller - * one first by recursion, then do the larger one by - * making sure lo is its size, base and max are update - * correctly, and branching back. But only repeat - * (recursively or by branching) if the partition is - * of at least size THRESH. - */ - i = (j = mid) + qsz; - if ((lo = j - ((char*)base)) <= (hi = max - i)) { - if (lo >= thresh) - qst(base, j); - base = i; - lo = hi; - } else { - if (hi >= thresh) - qst(i, max); - max = j; - } - } while (lo >= thresh); -} - -/*---------------------------------------------------------------------------*/ -/* Static function prototypes */ -/*---------------------------------------------------------------------------*/ - diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ucbqsort.h b/resources/3rdparty/cudd-2.5.0/src/nanotrav/ucbqsort.h deleted file mode 100644 index 1f6d012c8..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ucbqsort.h +++ /dev/null @@ -1,33 +0,0 @@ -/* @(#)qsort.h 4.2 (Berkeley) 3/9/83 */ - -/* - * qsort.h: - * Our own version of the system qsort routine which is faster by an average - * of 25%, with lows and highs of 10% and 50%. - * The THRESHold below is the insertion sort threshold, and has been adjusted - * for records of size 48 bytes. - * The MTHREShold is where we stop finding a better median. - */ - -#ifdef __cplusplus -extern "C" { -#endif - -#include <stddef.h> - -typedef int (*QSFP)(const void *, const void *); -void cudd__qsort (void* base, int n, int size, QSFP compar); - -#define THRESH 4 /* threshold for insertion */ -#define MTHRESH 6 /* threshold for median */ - -static QSFP qcmp; /* the comparison routine */ -static int qsz; /* size of each record */ -static int thresh; /* THRESHold in chars */ -static int mthresh; /* MTHRESHold in chars */ - -void qst (void *base, char *max); - -#ifdef __cplusplus -} -#endif \ No newline at end of file diff --git a/resources/3rdparty/cudd-2.5.0/src/st/Makefile b/resources/3rdparty/cudd-2.5.0/src/st/Makefile deleted file mode 100644 index 5fdc949c6..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/st/Makefile +++ /dev/null @@ -1,64 +0,0 @@ -# $Id: Makefile,v 1.3 2004/01/01 06:53:06 fabio Exp fabio $ -# -# st -- hash table package -#--------------------------------------------------------------------------- -.SUFFIXES: .c .o .u - -CC = gcc -RANLIB = ranlib - -MFLAG = -ICFLAGS = -g -O6 -Wall -CFLAGS = $(ICFLAGS) $(MFLAG) $(XCFLAGS) - -LINTFLAGS = -u -n - -# this is to create the lint library -LINTSWITCH = -o - -P = st -PSRC = st.c -PHDR = st.h -POBJ = $(PSRC:.c=.o) -PUBJ = $(PSRC:.c=.u) - -WHERE = .. -INCLUDE = $(WHERE)/include - -#--------------------------- - -lib$(P).a: $(POBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.o: $(PHDR) - $(CC) -c $< -I$(INCLUDE) $(CFLAGS) - -optimize_dec: lib$(P).b - -lib$(P).b: $(PUBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.u: $(PSRC) $(PHDR) - cc -j $< -I$(INCLUDE) $(XCFLAGS) - -# if the header files change, recompile -$(POBJ): $(PHDR) -$(PUBJ): $(PHDR) - -lint: llib-l$(P).ln - -llib-l$(P).ln: $(PSRC) $(PHDR) - lint $(LINTFLAGS) $(LINTSWITCH)$(P) -I$(INCLUDE) $(PSRC) - -tags: $(PSRC) $(PHDR) - ctags $(PSRC) $(PHDR) - -all: lib$(P).a lib$(P).b llib-l$(P).ln tags - -clean: - rm -f *.o *.u .pure *.warnings - -distclean: clean - rm -f lib*.a lib$(P).b llib-l$(P).ln tags *~ *.bak *.qv *.qx diff --git a/resources/3rdparty/cudd-2.5.0/src/st/doc/stAllAbs.html b/resources/3rdparty/cudd-2.5.0/src/st/doc/stAllAbs.html deleted file mode 100644 index 927c116bc..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/st/doc/stAllAbs.html +++ /dev/null @@ -1,96 +0,0 @@ -<html> -<head><title>st package abstract (Internal)</title></head> -<body> - -<h1>st package abstract (Internal)</h1> -<h2></h2> -<hr> - -<!-- Function Abstracts --> - -<dl> -<dt> <a href="stAllDet.html#st_add_direct"><code>st_add_direct()</code></a> -<dd> Place 'value' in 'table' under the key 'key'. - -<dt> <a href="stAllDet.html#st_copy"><code>st_copy()</code></a> -<dd> Return a copy of old_table and all its members. - -<dt> <a href="stAllDet.html#st_count"><code>st_count()</code></a> -<dd> Returns the number of entries in the table `table'. - -<dt> <a href="stAllDet.html#st_delete_int"><code>st_delete_int()</code></a> -<dd> Delete the entry with the key pointed to by `keyp'. - -<dt> <a href="stAllDet.html#st_delete"><code>st_delete()</code></a> -<dd> Delete the entry with the key pointed to by `keyp'. - -<dt> <a href="stAllDet.html#st_find_or_add"><code>st_find_or_add()</code></a> -<dd> Lookup `key' in `table'. - -<dt> <a href="stAllDet.html#st_find"><code>st_find()</code></a> -<dd> Lookup `key' in `table'. - -<dt> <a href="stAllDet.html#st_foreach_item_int"><code>st_foreach_item_int()</code></a> -<dd> Iteration macro. - -<dt> <a href="stAllDet.html#st_foreach_item"><code>st_foreach_item()</code></a> -<dd> Iteration macro. - -<dt> <a href="stAllDet.html#st_foreach"><code>st_foreach()</code></a> -<dd> Iterates over the elements of a table. - -<dt> <a href="stAllDet.html#st_free_gen"><code>st_free_gen()</code></a> -<dd> Reclaims the resources associated with `gen'. - -<dt> <a href="stAllDet.html#st_free_table"><code>st_free_table()</code></a> -<dd> Free a table. - -<dt> <a href="stAllDet.html#st_gen_int"><code>st_gen_int()</code></a> -<dd> Returns the next (key, value) pair in the generation sequence. - -<dt> <a href="stAllDet.html#st_gen"><code>st_gen()</code></a> -<dd> returns the next (key, value) pair in the generation sequence. - -<dt> <a href="stAllDet.html#st_init_gen"><code>st_init_gen()</code></a> -<dd> Initializes a generator. - -<dt> <a href="stAllDet.html#st_init_table_with_params"><code>st_init_table_with_params()</code></a> -<dd> Create a table with given parameters. - -<dt> <a href="stAllDet.html#st_init_table"><code>st_init_table()</code></a> -<dd> Create and initialize a table. - -<dt> <a href="stAllDet.html#st_insert"><code>st_insert()</code></a> -<dd> Insert value in table under the key 'key'. - -<dt> <a href="stAllDet.html#st_is_member"><code>st_is_member()</code></a> -<dd> Checks whethere `key' is in `table'. - -<dt> <a href="stAllDet.html#st_lookup_int"><code>st_lookup_int()</code></a> -<dd> Lookup up `key' in `table'. - -<dt> <a href="stAllDet.html#st_lookup"><code>st_lookup()</code></a> -<dd> Lookup up `key' in `table'. - -<dt> <a href="stAllDet.html#st_numcmp"><code>st_numcmp()</code></a> -<dd> Number comparison function. - -<dt> <a href="stAllDet.html#st_numhash"><code>st_numhash()</code></a> -<dd> Number hash function. - -<dt> <a href="stAllDet.html#st_ptrcmp"><code>st_ptrcmp()</code></a> -<dd> Pointer comparison function. - -<dt> <a href="stAllDet.html#st_ptrhash"><code>st_ptrhash()</code></a> -<dd> Pointer hash function. - -<dt> <a href="stAllDet.html#st_strhash"><code>st_strhash()</code></a> -<dd> String hash function. - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 20040102 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/st/doc/stAllDet.html b/resources/3rdparty/cudd-2.5.0/src/st/doc/stAllDet.html deleted file mode 100644 index e56d8834d..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/st/doc/stAllDet.html +++ /dev/null @@ -1,462 +0,0 @@ -<html> -<head><title>The st package (Internal) </title></head> -<body> - -<h1>The st package (Internal) </h1> -<h2></h2> -<h3></h3> -<hr> -<ul> -<li><a href="stExtAbs.html"><h3>External abstracts</h3></a> -<li><a href="stAllAbs.html"><h3>All abstracts</h3></a> -<li><a href="stExtDet.html#prototypes"><h3>External functions</h3></a> -<li><a href="stAllDet.html#prototypes"><h3>All functions</h3></a> -</ul> - -<hr> - -<a name="description"> - -</a> - -<hr> -<!-- Function Prototypes and description --> - -<dl> -<a name="prototypes"></a> -<dt><pre> -int <i></i> -<a name="st_add_direct"><b>st_add_direct</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - void * <b>value</b> <i></i> -) -</pre> -<dd> Place 'value' in 'table' under the key 'key'. This is done without checking if 'key' is in 'table' already. This should only be used if you are sure there is not already an entry for 'key', since it is undefined which entry you would later get from st_lookup or st_find_or_add. Returns 1 if successful; ST_OUT_OF_MEM otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -st_table * <i></i> -<a name="st_copy"><b>st_copy</b></a>( - st_table * <b>old_table</b> <i></i> -) -</pre> -<dd> Return a copy of old_table and all its members. (st_table *) 0 is returned if there was insufficient memory to do the copy. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> - <i></i> -<a name="st_count"><b>st_count</b></a>( - <b>table</b> <i></i> -) -</pre> -<dd> Returns the number of entries in the table `table'. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="st_delete_int"><b>st_delete_int</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>keyp</b>, <i></i> - int * <b>value</b> <i></i> -) -</pre> -<dd> Delete the entry with the key pointed to by `keyp'. `value' must be a pointer to an integer. If the entry is found, 1 is returned, the variable pointed by `keyp' is set to the actual key and the variable pointed by `value' is set to the corresponding entry. (This allows the freeing of the associated storage.) If the entry is not found, then 0 is returned and nothing is changed. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_delete">st_delete</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_delete"><b>st_delete</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>keyp</b>, <i></i> - void * <b>value</b> <i></i> -) -</pre> -<dd> Delete the entry with the key pointed to by `keyp'. If the entry is found, 1 is returned, the variable pointed by `keyp' is set to the actual key and the variable pointed by `value' is set to the corresponding entry. (This allows the freeing of the associated storage.) If the entry is not found, then 0 is returned and nothing is changed. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_delete_int">st_delete_int</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_find_or_add"><b>st_find_or_add</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - void * <b>slot</b> <i></i> -) -</pre> -<dd> Lookup `key' in `table'. If not found, create an entry. In either case set slot to point to the field in the entry where the value is stored. The value associated with `key' may then be changed by accessing directly through slot. Returns 1 if an entry already existed, 0 if it did not exist and creation was successful; ST_OUT_OF_MEM otherwise. As an example: <pre> char **slot; </pre> <pre> char *key; </pre> <pre> char *value = (char *) item_ptr <-- ptr to a malloc'd structure </pre> <pre> if (st_find_or_add(table, key, &slot) == 1) { </pre> <pre> FREE(*slot); <-- free the old value of the record </pre> <pre> } </pre> <pre> *slot = value; <-- attach the new value to the record </pre> This replaces the equivelent code: <pre> if (st_lookup(table, key, &ovalue) == 1) { </pre> <pre> FREE(ovalue); </pre> <pre> } </pre> <pre> st_insert(table, key, value); </pre> -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_find">st_find</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_find"><b>st_find</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - void * <b>slot</b> <i></i> -) -</pre> -<dd> Like st_find_or_add, but does not create an entry if one is not found. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_find_or_add">st_find_or_add</a> -</code> - -<dt><pre> - <i></i> -<a name="st_foreach_item_int"><b>st_foreach_item_int</b></a>( - <b>table</b>, <i></i> - <b>gen</b>, <i></i> - <b>key</b>, <i></i> - <b>value</b> <i></i> -) -</pre> -<dd> An iteration macro which loops over all the entries in `table', setting `key' to point to the key and `value' to the associated value (if it is not nil). `value' is assumed to be a pointer to an integer. `gen' is a generator variable used internally. Sample usage: <pre> char *key; </pre> <pre> int value; </pre> <pre> st_generator *gen; </pre> <pre> st_foreach_item_int(table, gen, &key, &value) { </pre> <pre> process_item(value); </pre> <pre> } </pre> -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_foreach_item">st_foreach_item</a> -<a href="stAllDet.html#st_foreach">st_foreach</a> -</code> - -<dt><pre> - <i></i> -<a name="st_foreach_item"><b>st_foreach_item</b></a>( - <b>table</b>, <i></i> - <b>gen</b>, <i></i> - <b>key</b>, <i></i> - <b>value</b> <i></i> -) -</pre> -<dd> An iteration macro which loops over all the entries in `table', setting `key' to point to the key and `value' to the associated value (if it is not nil). `gen' is a generator variable used internally. Sample usage: <pre> char *key, *value; </pre> <pre> st_generator *gen; </pre> <pre> st_foreach_item(table, gen, &key, &value) { </pre> <pre> process_item(value); </pre> <pre> } </pre> -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_foreach_item_int">st_foreach_item_int</a> -<a href="stAllDet.html#st_foreach">st_foreach</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_foreach"><b>st_foreach</b></a>( - st_table * <b>table</b>, <i></i> - ST_PFSR <b>func</b>, <i></i> - char * <b>arg</b> <i></i> -) -</pre> -<dd> For each (key, value) record in `table', st_foreach call func with the arguments <pre> (*func)(key, value, arg) </pre> If func returns ST_CONTINUE, st_foreach continues processing entries. If func returns ST_STOP, st_foreach stops processing and returns immediately. If func returns ST_DELETE, then the entry is deleted from the symbol table and st_foreach continues. In the case of ST_DELETE, it is func's responsibility to free the key and value, if necessary.<p> The routine returns 1 if all items in the table were generated and 0 if the generation sequence was aborted using ST_STOP. The order in which the records are visited will be seemingly random. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_foreach_item">st_foreach_item</a> -<a href="stAllDet.html#st_foreach_item_int">st_foreach_item_int</a> -</code> - -<dt><pre> -void <i></i> -<a name="st_free_gen"><b>st_free_gen</b></a>( - st_generator * <b>gen</b> <i></i> -) -</pre> -<dd> After generating all items in a generation sequence, this routine must be called to reclaim the resources associated with `gen'. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_gen">st_init_gen</a> -</code> - -<dt><pre> -void <i></i> -<a name="st_free_table"><b>st_free_table</b></a>( - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Any internal storage associated with table is freed. It is the user's responsibility to free any storage associated with the pointers he placed in the table (by perhaps using st_foreach). -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_init_table_with_params">st_init_table_with_params</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_gen_int"><b>st_gen_int</b></a>( - st_generator * <b>gen</b>, <i></i> - void * <b>key_p</b>, <i></i> - int * <b>value_p</b> <i></i> -) -</pre> -<dd> Given a generator returned by st_init_gen(), this routine returns the next (key, value) pair in the generation sequence. `value_p' must be a pointer to an integer. The pointer `value_p' can be zero which means no value will be returned. When there are no more items in the generation sequence, the routine returns 0. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_gen">st_gen</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_gen"><b>st_gen</b></a>( - st_generator * <b>gen</b>, <i></i> - void * <b>key_p</b>, <i></i> - void * <b>value_p</b> <i></i> -) -</pre> -<dd> Given a generator returned by st_init_gen(), this routine returns the next (key, value) pair in the generation sequence. The pointer `value_p' can be zero which means no value will be returned. When there are no more items in the generation sequence, the routine returns 0. While using a generation sequence, deleting any (key, value) pair other than the one just generated may cause a fatal error when st_gen() is called later in the sequence and is therefore not recommended. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_gen_int">st_gen_int</a> -</code> - -<dt><pre> -st_generator * <i></i> -<a name="st_init_gen"><b>st_init_gen</b></a>( - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Returns a generator handle which when used with st_gen() will progressively return each (key, value) record in `table'. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_free_gen">st_free_gen</a> -</code> - -<dt><pre> -st_table * <i></i> -<a name="st_init_table_with_params"><b>st_init_table_with_params</b></a>( - ST_PFICPCP <b>compare</b>, <i></i> - ST_PFICPI <b>hash</b>, <i></i> - int <b>size</b>, <i></i> - int <b>density</b>, <i></i> - double <b>grow_factor</b>, <i></i> - int <b>reorder_flag</b> <i></i> -) -</pre> -<dd> The full blown table initializer. compare and hash are the same as in st_init_table. density is the largest the average number of entries per hash bin there should be before the table is grown. grow_factor is the factor the table is grown by when it becomes too full. size is the initial number of bins to be allocated for the hash table. If reorder_flag is non-zero, then every time an entry is found, it is moved to the top of the chain.<p> st_init_table(compare, hash) is equivelent to <pre> st_init_table_with_params(compare, hash, ST_DEFAULT_INIT_TABLE_SIZE, ST_DEFAULT_MAX_DENSITY, ST_DEFAULT_GROW_FACTOR, ST_DEFAULT_REORDER_FLAG); </pre> -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_free_table">st_free_table</a> -</code> - -<dt><pre> -st_table * <i></i> -<a name="st_init_table"><b>st_init_table</b></a>( - ST_PFICPCP <b>compare</b>, <i></i> - ST_PFICPI <b>hash</b> <i></i> -) -</pre> -<dd> Create and initialize a table with the comparison function compare_fn and hash function hash_fn. compare_fn is <pre> int compare_fn(const char *key1, const char *key2) </pre> It returns <,=,> 0 depending on whether key1 <,=,> key2 by some measure.<p> hash_fn is <pre> int hash_fn(char *key, int modulus) </pre> It returns a integer between 0 and modulus-1 such that if compare_fn(key1,key2) == 0 then hash_fn(key1) == hash_fn(key2).<p> There are five predefined hash and comparison functions in st. For keys as numbers: <pre> st_numhash(key, modulus) { return (unsigned int) key % modulus; } </pre> <pre> st_numcmp(x,y) { return (int) x - (int) y; } </pre> For keys as pointers: <pre> st_ptrhash(key, modulus) { return ((unsigned int) key/4) % modulus } </pre> <pre> st_ptrcmp(x,y) { return (int) x - (int) y; } </pre> For keys as strings: <pre> st_strhash(x,y) - a reasonable hashing function for strings </pre> <pre> strcmp(x,y) - the standard library function </pre> It is recommended to use these particular functions if they fit your needs, since st will recognize certain of them and run more quickly because of it. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table_with_params">st_init_table_with_params</a> -<a href="stAllDet.html#st_free_table">st_free_table</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_insert"><b>st_insert</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - void * <b>value</b> <i></i> -) -</pre> -<dd> Insert value in table under the key 'key'. Returns 1 if there was an entry already under the key; 0 if there was no entry under the key and insertion was successful; ST_OUT_OF_MEM otherwise. In either of the first two cases the new value is added. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> - <i></i> -<a name="st_is_member"><b>st_is_member</b></a>( - <b>table</b>, <i></i> - <b>key</b> <i></i> -) -</pre> -<dd> Returns 1 if there is an entry under `key' in `table', 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_lookup">st_lookup</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_lookup_int"><b>st_lookup_int</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - int * <b>value</b> <i></i> -) -</pre> -<dd> Lookup up `key' in `table'. If an entry is found, 1 is returned and if `value' is not nil, the variable it points to is set to the associated integer value. If an entry is not found, 0 is return and the variable pointed by `value' is unchanged. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_lookup">st_lookup</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_lookup"><b>st_lookup</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - void * <b>value</b> <i></i> -) -</pre> -<dd> Lookup up `key' in `table'. If an entry is found, 1 is returned and if `value' is not nil, the variable it points to is set to the associated value. If an entry is not found, 0 is returned and the variable pointed by value is unchanged. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_lookup_int">st_lookup_int</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_numcmp"><b>st_numcmp</b></a>( - const char * <b>x</b>, <i></i> - const char * <b>y</b> <i></i> -) -</pre> -<dd> integer number comparison function. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_numhash">st_numhash</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_numhash"><b>st_numhash</b></a>( - char * <b>x</b>, <i></i> - int <b>size</b> <i></i> -) -</pre> -<dd> Integer number hash function. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_numcmp">st_numcmp</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_ptrcmp"><b>st_ptrcmp</b></a>( - const char * <b>x</b>, <i></i> - const char * <b>y</b> <i></i> -) -</pre> -<dd> Pointer comparison function. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_ptrhash">st_ptrhash</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_ptrhash"><b>st_ptrhash</b></a>( - char * <b>x</b>, <i></i> - int <b>size</b> <i></i> -) -</pre> -<dd> Pointer hash function. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_ptrcmp">st_ptrcmp</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_strhash"><b>st_strhash</b></a>( - char * <b>string</b>, <i></i> - int <b>modulus</b> <i></i> -) -</pre> -<dd> String hash function. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -</code> - - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 20040102 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/st/doc/stExtAbs.html b/resources/3rdparty/cudd-2.5.0/src/st/doc/stExtAbs.html deleted file mode 100644 index 5302461fa..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/st/doc/stExtAbs.html +++ /dev/null @@ -1,96 +0,0 @@ -<html> -<head><title>st package abstract</title></head> -<body> - -<h1>st package abstract</h1> -<h2>Symbol table package.</h2> -<hr> - -<!-- Function Abstracts --> - -<dl> -<dt> <a href="stExtDet.html#st_add_direct"><code>st_add_direct()</code></a> -<dd> Place 'value' in 'table' under the key 'key'. - -<dt> <a href="stExtDet.html#st_copy"><code>st_copy()</code></a> -<dd> Return a copy of old_table and all its members. - -<dt> <a href="stExtDet.html#st_count"><code>st_count()</code></a> -<dd> Returns the number of entries in the table `table'. - -<dt> <a href="stExtDet.html#st_delete_int"><code>st_delete_int()</code></a> -<dd> Delete the entry with the key pointed to by `keyp'. - -<dt> <a href="stExtDet.html#st_delete"><code>st_delete()</code></a> -<dd> Delete the entry with the key pointed to by `keyp'. - -<dt> <a href="stExtDet.html#st_find_or_add"><code>st_find_or_add()</code></a> -<dd> Lookup `key' in `table'. - -<dt> <a href="stExtDet.html#st_find"><code>st_find()</code></a> -<dd> Lookup `key' in `table'. - -<dt> <a href="stExtDet.html#st_foreach_item_int"><code>st_foreach_item_int()</code></a> -<dd> Iteration macro. - -<dt> <a href="stExtDet.html#st_foreach_item"><code>st_foreach_item()</code></a> -<dd> Iteration macro. - -<dt> <a href="stExtDet.html#st_foreach"><code>st_foreach()</code></a> -<dd> Iterates over the elements of a table. - -<dt> <a href="stExtDet.html#st_free_gen"><code>st_free_gen()</code></a> -<dd> Reclaims the resources associated with `gen'. - -<dt> <a href="stExtDet.html#st_free_table"><code>st_free_table()</code></a> -<dd> Free a table. - -<dt> <a href="stExtDet.html#st_gen_int"><code>st_gen_int()</code></a> -<dd> Returns the next (key, value) pair in the generation sequence. - -<dt> <a href="stExtDet.html#st_gen"><code>st_gen()</code></a> -<dd> returns the next (key, value) pair in the generation sequence. - -<dt> <a href="stExtDet.html#st_init_gen"><code>st_init_gen()</code></a> -<dd> Initializes a generator. - -<dt> <a href="stExtDet.html#st_init_table_with_params"><code>st_init_table_with_params()</code></a> -<dd> Create a table with given parameters. - -<dt> <a href="stExtDet.html#st_init_table"><code>st_init_table()</code></a> -<dd> Create and initialize a table. - -<dt> <a href="stExtDet.html#st_insert"><code>st_insert()</code></a> -<dd> Insert value in table under the key 'key'. - -<dt> <a href="stExtDet.html#st_is_member"><code>st_is_member()</code></a> -<dd> Checks whethere `key' is in `table'. - -<dt> <a href="stExtDet.html#st_lookup_int"><code>st_lookup_int()</code></a> -<dd> Lookup up `key' in `table'. - -<dt> <a href="stExtDet.html#st_lookup"><code>st_lookup()</code></a> -<dd> Lookup up `key' in `table'. - -<dt> <a href="stExtDet.html#st_numcmp"><code>st_numcmp()</code></a> -<dd> Number comparison function. - -<dt> <a href="stExtDet.html#st_numhash"><code>st_numhash()</code></a> -<dd> Number hash function. - -<dt> <a href="stExtDet.html#st_ptrcmp"><code>st_ptrcmp()</code></a> -<dd> Pointer comparison function. - -<dt> <a href="stExtDet.html#st_ptrhash"><code>st_ptrhash()</code></a> -<dd> Pointer hash function. - -<dt> <a href="stExtDet.html#st_strhash"><code>st_strhash()</code></a> -<dd> String hash function. - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 20040102 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/st/doc/stExtDet.html b/resources/3rdparty/cudd-2.5.0/src/st/doc/stExtDet.html deleted file mode 100644 index 43cb6f464..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/st/doc/stExtDet.html +++ /dev/null @@ -1,463 +0,0 @@ -<html> -<head><title>The st package</title></head> -<body> - -<h1>The st package</h1> -<h2>Symbol table package.</h2> -<h3></h3> -<hr> -<ul> -<li><a href="stExtAbs.html"><h3>External abstracts</h3></a> -<li><a href="stAllAbs.html"><h3>All abstracts</h3></a> -<li><a href="stExtDet.html#prototypes"><h3>External functions</h3></a> -<li><a href="stAllDet.html#prototypes"><h3>All functions</h3></a> -</ul> - -<hr> - -<a name="description"> -The st library provides functions to create, maintain, - and query symbol tables. -</a> - -<hr> -<!-- Function Prototypes and description --> - -<dl> -<a name="prototypes"></a> -<dt><pre> -int <i></i> -<a name="st_add_direct"><b>st_add_direct</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - void * <b>value</b> <i></i> -) -</pre> -<dd> Place 'value' in 'table' under the key 'key'. This is done without checking if 'key' is in 'table' already. This should only be used if you are sure there is not already an entry for 'key', since it is undefined which entry you would later get from st_lookup or st_find_or_add. Returns 1 if successful; ST_OUT_OF_MEM otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -st_table * <i></i> -<a name="st_copy"><b>st_copy</b></a>( - st_table * <b>old_table</b> <i></i> -) -</pre> -<dd> Return a copy of old_table and all its members. (st_table *) 0 is returned if there was insufficient memory to do the copy. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> - <i></i> -<a name="st_count"><b>st_count</b></a>( - <b>table</b> <i></i> -) -</pre> -<dd> Returns the number of entries in the table `table'. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> -int <i></i> -<a name="st_delete_int"><b>st_delete_int</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>keyp</b>, <i></i> - int * <b>value</b> <i></i> -) -</pre> -<dd> Delete the entry with the key pointed to by `keyp'. `value' must be a pointer to an integer. If the entry is found, 1 is returned, the variable pointed by `keyp' is set to the actual key and the variable pointed by `value' is set to the corresponding entry. (This allows the freeing of the associated storage.) If the entry is not found, then 0 is returned and nothing is changed. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_delete">st_delete</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_delete"><b>st_delete</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>keyp</b>, <i></i> - void * <b>value</b> <i></i> -) -</pre> -<dd> Delete the entry with the key pointed to by `keyp'. If the entry is found, 1 is returned, the variable pointed by `keyp' is set to the actual key and the variable pointed by `value' is set to the corresponding entry. (This allows the freeing of the associated storage.) If the entry is not found, then 0 is returned and nothing is changed. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_delete_int">st_delete_int</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_find_or_add"><b>st_find_or_add</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - void * <b>slot</b> <i></i> -) -</pre> -<dd> Lookup `key' in `table'. If not found, create an entry. In either case set slot to point to the field in the entry where the value is stored. The value associated with `key' may then be changed by accessing directly through slot. Returns 1 if an entry already existed, 0 if it did not exist and creation was successful; ST_OUT_OF_MEM otherwise. As an example: <pre> char **slot; </pre> <pre> char *key; </pre> <pre> char *value = (char *) item_ptr <-- ptr to a malloc'd structure </pre> <pre> if (st_find_or_add(table, key, &slot) == 1) { </pre> <pre> FREE(*slot); <-- free the old value of the record </pre> <pre> } </pre> <pre> *slot = value; <-- attach the new value to the record </pre> This replaces the equivelent code: <pre> if (st_lookup(table, key, &ovalue) == 1) { </pre> <pre> FREE(ovalue); </pre> <pre> } </pre> <pre> st_insert(table, key, value); </pre> -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_find">st_find</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_find"><b>st_find</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - void * <b>slot</b> <i></i> -) -</pre> -<dd> Like st_find_or_add, but does not create an entry if one is not found. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_find_or_add">st_find_or_add</a> -</code> - -<dt><pre> - <i></i> -<a name="st_foreach_item_int"><b>st_foreach_item_int</b></a>( - <b>table</b>, <i></i> - <b>gen</b>, <i></i> - <b>key</b>, <i></i> - <b>value</b> <i></i> -) -</pre> -<dd> An iteration macro which loops over all the entries in `table', setting `key' to point to the key and `value' to the associated value (if it is not nil). `value' is assumed to be a pointer to an integer. `gen' is a generator variable used internally. Sample usage: <pre> char *key; </pre> <pre> int value; </pre> <pre> st_generator *gen; </pre> <pre> st_foreach_item_int(table, gen, &key, &value) { </pre> <pre> process_item(value); </pre> <pre> } </pre> -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_foreach_item">st_foreach_item</a> -<a href="stAllDet.html#st_foreach">st_foreach</a> -</code> - -<dt><pre> - <i></i> -<a name="st_foreach_item"><b>st_foreach_item</b></a>( - <b>table</b>, <i></i> - <b>gen</b>, <i></i> - <b>key</b>, <i></i> - <b>value</b> <i></i> -) -</pre> -<dd> An iteration macro which loops over all the entries in `table', setting `key' to point to the key and `value' to the associated value (if it is not nil). `gen' is a generator variable used internally. Sample usage: <pre> char *key, *value; </pre> <pre> st_generator *gen; </pre> <pre> st_foreach_item(table, gen, &key, &value) { </pre> <pre> process_item(value); </pre> <pre> } </pre> -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_foreach_item_int">st_foreach_item_int</a> -<a href="stAllDet.html#st_foreach">st_foreach</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_foreach"><b>st_foreach</b></a>( - st_table * <b>table</b>, <i></i> - ST_PFSR <b>func</b>, <i></i> - char * <b>arg</b> <i></i> -) -</pre> -<dd> For each (key, value) record in `table', st_foreach call func with the arguments <pre> (*func)(key, value, arg) </pre> If func returns ST_CONTINUE, st_foreach continues processing entries. If func returns ST_STOP, st_foreach stops processing and returns immediately. If func returns ST_DELETE, then the entry is deleted from the symbol table and st_foreach continues. In the case of ST_DELETE, it is func's responsibility to free the key and value, if necessary.<p> The routine returns 1 if all items in the table were generated and 0 if the generation sequence was aborted using ST_STOP. The order in which the records are visited will be seemingly random. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_foreach_item">st_foreach_item</a> -<a href="stAllDet.html#st_foreach_item_int">st_foreach_item_int</a> -</code> - -<dt><pre> -void <i></i> -<a name="st_free_gen"><b>st_free_gen</b></a>( - st_generator * <b>gen</b> <i></i> -) -</pre> -<dd> After generating all items in a generation sequence, this routine must be called to reclaim the resources associated with `gen'. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_gen">st_init_gen</a> -</code> - -<dt><pre> -void <i></i> -<a name="st_free_table"><b>st_free_table</b></a>( - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Any internal storage associated with table is freed. It is the user's responsibility to free any storage associated with the pointers he placed in the table (by perhaps using st_foreach). -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_init_table_with_params">st_init_table_with_params</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_gen_int"><b>st_gen_int</b></a>( - st_generator * <b>gen</b>, <i></i> - void * <b>key_p</b>, <i></i> - int * <b>value_p</b> <i></i> -) -</pre> -<dd> Given a generator returned by st_init_gen(), this routine returns the next (key, value) pair in the generation sequence. `value_p' must be a pointer to an integer. The pointer `value_p' can be zero which means no value will be returned. When there are no more items in the generation sequence, the routine returns 0. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_gen">st_gen</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_gen"><b>st_gen</b></a>( - st_generator * <b>gen</b>, <i></i> - void * <b>key_p</b>, <i></i> - void * <b>value_p</b> <i></i> -) -</pre> -<dd> Given a generator returned by st_init_gen(), this routine returns the next (key, value) pair in the generation sequence. The pointer `value_p' can be zero which means no value will be returned. When there are no more items in the generation sequence, the routine returns 0. While using a generation sequence, deleting any (key, value) pair other than the one just generated may cause a fatal error when st_gen() is called later in the sequence and is therefore not recommended. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_gen_int">st_gen_int</a> -</code> - -<dt><pre> -st_generator * <i></i> -<a name="st_init_gen"><b>st_init_gen</b></a>( - st_table * <b>table</b> <i></i> -) -</pre> -<dd> Returns a generator handle which when used with st_gen() will progressively return each (key, value) record in `table'. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_free_gen">st_free_gen</a> -</code> - -<dt><pre> -st_table * <i></i> -<a name="st_init_table_with_params"><b>st_init_table_with_params</b></a>( - ST_PFICPCP <b>compare</b>, <i></i> - ST_PFICPI <b>hash</b>, <i></i> - int <b>size</b>, <i></i> - int <b>density</b>, <i></i> - double <b>grow_factor</b>, <i></i> - int <b>reorder_flag</b> <i></i> -) -</pre> -<dd> The full blown table initializer. compare and hash are the same as in st_init_table. density is the largest the average number of entries per hash bin there should be before the table is grown. grow_factor is the factor the table is grown by when it becomes too full. size is the initial number of bins to be allocated for the hash table. If reorder_flag is non-zero, then every time an entry is found, it is moved to the top of the chain.<p> st_init_table(compare, hash) is equivelent to <pre> st_init_table_with_params(compare, hash, ST_DEFAULT_INIT_TABLE_SIZE, ST_DEFAULT_MAX_DENSITY, ST_DEFAULT_GROW_FACTOR, ST_DEFAULT_REORDER_FLAG); </pre> -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_free_table">st_free_table</a> -</code> - -<dt><pre> -st_table * <i></i> -<a name="st_init_table"><b>st_init_table</b></a>( - ST_PFICPCP <b>compare</b>, <i></i> - ST_PFICPI <b>hash</b> <i></i> -) -</pre> -<dd> Create and initialize a table with the comparison function compare_fn and hash function hash_fn. compare_fn is <pre> int compare_fn(const char *key1, const char *key2) </pre> It returns <,=,> 0 depending on whether key1 <,=,> key2 by some measure.<p> hash_fn is <pre> int hash_fn(char *key, int modulus) </pre> It returns a integer between 0 and modulus-1 such that if compare_fn(key1,key2) == 0 then hash_fn(key1) == hash_fn(key2).<p> There are five predefined hash and comparison functions in st. For keys as numbers: <pre> st_numhash(key, modulus) { return (unsigned int) key % modulus; } </pre> <pre> st_numcmp(x,y) { return (int) x - (int) y; } </pre> For keys as pointers: <pre> st_ptrhash(key, modulus) { return ((unsigned int) key/4) % modulus } </pre> <pre> st_ptrcmp(x,y) { return (int) x - (int) y; } </pre> For keys as strings: <pre> st_strhash(x,y) - a reasonable hashing function for strings </pre> <pre> strcmp(x,y) - the standard library function </pre> It is recommended to use these particular functions if they fit your needs, since st will recognize certain of them and run more quickly because of it. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table_with_params">st_init_table_with_params</a> -<a href="stAllDet.html#st_free_table">st_free_table</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_insert"><b>st_insert</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - void * <b>value</b> <i></i> -) -</pre> -<dd> Insert value in table under the key 'key'. Returns 1 if there was an entry already under the key; 0 if there was no entry under the key and insertion was successful; ST_OUT_OF_MEM otherwise. In either of the first two cases the new value is added. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dt><pre> - <i></i> -<a name="st_is_member"><b>st_is_member</b></a>( - <b>table</b>, <i></i> - <b>key</b> <i></i> -) -</pre> -<dd> Returns 1 if there is an entry under `key' in `table', 0 otherwise. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_lookup">st_lookup</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_lookup_int"><b>st_lookup_int</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - int * <b>value</b> <i></i> -) -</pre> -<dd> Lookup up `key' in `table'. If an entry is found, 1 is returned and if `value' is not nil, the variable it points to is set to the associated integer value. If an entry is not found, 0 is return and the variable pointed by `value' is unchanged. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_lookup">st_lookup</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_lookup"><b>st_lookup</b></a>( - st_table * <b>table</b>, <i></i> - void * <b>key</b>, <i></i> - void * <b>value</b> <i></i> -) -</pre> -<dd> Lookup up `key' in `table'. If an entry is found, 1 is returned and if `value' is not nil, the variable it points to is set to the associated value. If an entry is not found, 0 is returned and the variable pointed by value is unchanged. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_lookup_int">st_lookup_int</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_numcmp"><b>st_numcmp</b></a>( - const char * <b>x</b>, <i></i> - const char * <b>y</b> <i></i> -) -</pre> -<dd> integer number comparison function. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_numhash">st_numhash</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_numhash"><b>st_numhash</b></a>( - char * <b>x</b>, <i></i> - int <b>size</b> <i></i> -) -</pre> -<dd> Integer number hash function. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_numcmp">st_numcmp</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_ptrcmp"><b>st_ptrcmp</b></a>( - const char * <b>x</b>, <i></i> - const char * <b>y</b> <i></i> -) -</pre> -<dd> Pointer comparison function. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_ptrhash">st_ptrhash</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_ptrhash"><b>st_ptrhash</b></a>( - char * <b>x</b>, <i></i> - int <b>size</b> <i></i> -) -</pre> -<dd> Pointer hash function. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -<a href="stAllDet.html#st_ptrcmp">st_ptrcmp</a> -</code> - -<dt><pre> -int <i></i> -<a name="st_strhash"><b>st_strhash</b></a>( - char * <b>string</b>, <i></i> - int <b>modulus</b> <i></i> -) -</pre> -<dd> String hash function. -<p> - -<dd> <b>Side Effects</b> None -<p> - -<dd> <b>See Also</b> <code><a href="stAllDet.html#st_init_table">st_init_table</a> -</code> - - -</dl> - -<hr> - -Generated automatically by <code>extdoc</code> on 20040102 - -</body></html> diff --git a/resources/3rdparty/cudd-2.5.0/src/st/st.c b/resources/3rdparty/cudd-2.5.0/src/st/st.c deleted file mode 100644 index dd76fa591..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/st/st.c +++ /dev/null @@ -1,1065 +0,0 @@ -/**CFile*********************************************************************** - - FileName [st.c] - - PackageName [st] - - Synopsis [Symbol table package.] - - Description [The st library provides functions to create, maintain, - and query symbol tables.] - - SeeAlso [] - - Author [] - - Copyright [] - -******************************************************************************/ - -#include "util.h" -#include "st.h" - -/*---------------------------------------------------------------------------*/ -/* Constant declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Stucture declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Type declarations */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Variable declarations */ -/*---------------------------------------------------------------------------*/ - -#ifndef lint -static char rcsid[] UTIL_UNUSED = " $Id: st.c,v 1.12 2010/04/22 19:00:55 fabio Exp fabio $"; -#endif - -/*---------------------------------------------------------------------------*/ -/* Macro declarations */ -/*---------------------------------------------------------------------------*/ - -#define ST_NUMCMP(x,y) ((x) != (y)) - -#define ST_NUMHASH(x,size) ((unsigned long)(x)%(size)) - -#if SIZEOF_VOID_P == 8 -#define st_shift 3 -#else -#define st_shift 2 -#endif - -#define ST_PTRHASH(x,size) ((unsigned int)((unsigned long)(x)>>st_shift)%size) - -#define EQUAL(func, x, y) \ - ((((func) == st_numcmp) || ((func) == st_ptrcmp)) ?\ - (ST_NUMCMP((x),(y)) == 0) : ((*func)((x), (y)) == 0)) - -#define do_hash(key, table)\ - ((int)((table->hash == st_ptrhash) ? ST_PTRHASH((char *)(key),(table)->num_bins) :\ - (table->hash == st_numhash) ? ST_NUMHASH((char *)(key), (table)->num_bins) :\ - (*table->hash)((char *)(key), (table)->num_bins))) - -#define PTR_NOT_EQUAL(table, ptr, user_key)\ -(ptr != NIL(st_table_entry) && !EQUAL(table->compare, (char *)user_key, (ptr)->key)) - -#define FIND_ENTRY(table, hash_val, key, ptr, last) \ - (last) = &(table)->bins[hash_val];\ - (ptr) = *(last);\ - while (PTR_NOT_EQUAL((table), (ptr), (key))) {\ - (last) = &(ptr)->next; (ptr) = *(last);\ - }\ - if ((ptr) != NIL(st_table_entry) && (table)->reorder_flag) {\ - *(last) = (ptr)->next;\ - (ptr)->next = (table)->bins[hash_val];\ - (table)->bins[hash_val] = (ptr);\ - } - -/* This macro does not check if memory allocation fails. Use at you own risk */ -#define ADD_DIRECT(table, key, value, hash_val, newt)\ -{\ - if (table->num_entries/table->num_bins >= table->max_density) {\ - rehash(table);\ - hash_val = do_hash(key,table);\ - }\ - \ - newt = ALLOC(st_table_entry, 1);\ - \ - newt->key = (char *)key;\ - newt->record = value;\ - newt->next = table->bins[hash_val];\ - table->bins[hash_val] = newt;\ - table->num_entries++;\ -} - -/**AutomaticStart*************************************************************/ - -/*---------------------------------------------------------------------------*/ -/* Static function prototypes */ -/*---------------------------------------------------------------------------*/ - -static int rehash (st_table *); - -/**AutomaticEnd***************************************************************/ - - -/*---------------------------------------------------------------------------*/ -/* Definition of exported functions */ -/*---------------------------------------------------------------------------*/ - -/**Function******************************************************************** - - Synopsis [Create and initialize a table.] - - Description [Create and initialize a table with the comparison function - compare_fn and hash function hash_fn. compare_fn is - <pre> - int compare_fn(const char *key1, const char *key2) - </pre> - It returns <,=,> 0 depending on whether key1 <,=,> key2 by some measure.<p> - hash_fn is - <pre> - int hash_fn(char *key, int modulus) - </pre> - It returns a integer between 0 and modulus-1 such that if - compare_fn(key1,key2) == 0 then hash_fn(key1) == hash_fn(key2).<p> - There are five predefined hash and comparison functions in st. - For keys as numbers: - <pre> - st_numhash(key, modulus) { return (unsigned int) key % modulus; } - </pre> - <pre> - st_numcmp(x,y) { return (int) x - (int) y; } - </pre> - For keys as pointers: - <pre> - st_ptrhash(key, modulus) { return ((unsigned int) key/4) % modulus } - </pre> - <pre> - st_ptrcmp(x,y) { return (int) x - (int) y; } - </pre> - For keys as strings: - <pre> - st_strhash(x,y) - a reasonable hashing function for strings - </pre> - <pre> - strcmp(x,y) - the standard library function - </pre> - It is recommended to use these particular functions if they fit your - needs, since st will recognize certain of them and run more quickly - because of it.] - - SideEffects [None] - - SeeAlso [st_init_table_with_params st_free_table] - -******************************************************************************/ -st_table * -st_init_table(ST_PFICPCP compare, ST_PFICPI hash) -{ - return st_init_table_with_params(compare, hash, ST_DEFAULT_INIT_TABLE_SIZE, - ST_DEFAULT_MAX_DENSITY, - ST_DEFAULT_GROW_FACTOR, - ST_DEFAULT_REORDER_FLAG); - -} /* st_init_table */ - - -/**Function******************************************************************** - - Synopsis [Create a table with given parameters.] - - Description [The full blown table initializer. compare and hash are - the same as in st_init_table. density is the largest the average - number of entries per hash bin there should be before the table is - grown. grow_factor is the factor the table is grown by when it - becomes too full. size is the initial number of bins to be allocated - for the hash table. If reorder_flag is non-zero, then every time an - entry is found, it is moved to the top of the chain.<p> - st_init_table(compare, hash) is equivelent to - <pre> - st_init_table_with_params(compare, hash, ST_DEFAULT_INIT_TABLE_SIZE, - ST_DEFAULT_MAX_DENSITY, - ST_DEFAULT_GROW_FACTOR, - ST_DEFAULT_REORDER_FLAG); - </pre> - ] - - SideEffects [None] - - SeeAlso [st_init_table st_free_table] - -******************************************************************************/ -st_table * -st_init_table_with_params( - ST_PFICPCP compare, - ST_PFICPI hash, - int size, - int density, - double grow_factor, - int reorder_flag) -{ - int i; - st_table *newt; - - newt = ALLOC(st_table, 1); - if (newt == NIL(st_table)) { - return NIL(st_table); - } - newt->compare = compare; - newt->hash = hash; - newt->num_entries = 0; - newt->max_density = density; - newt->grow_factor = grow_factor; - newt->reorder_flag = reorder_flag; - if (size <= 0) { - size = 1; - } - newt->num_bins = size; - newt->bins = ALLOC(st_table_entry *, size); - if (newt->bins == NIL(st_table_entry *)) { - FREE(newt); - return NIL(st_table); - } - for(i = 0; i < size; i++) { - newt->bins[i] = 0; - } - return newt; - -} /* st_init_table_with_params */ - - -/**Function******************************************************************** - - Synopsis [Free a table.] - - Description [Any internal storage associated with table is freed. - It is the user's responsibility to free any storage associated - with the pointers he placed in the table (by perhaps using - st_foreach).] - - SideEffects [None] - - SeeAlso [st_init_table st_init_table_with_params] - -******************************************************************************/ -void -st_free_table(st_table *table) -{ - st_table_entry *ptr, *next; - int i; - - for(i = 0; i < table->num_bins ; i++) { - ptr = table->bins[i]; - while (ptr != NIL(st_table_entry)) { - next = ptr->next; - FREE(ptr); - ptr = next; - } - } - FREE(table->bins); - FREE(table); - -} /* st_free_table */ - - -/**Function******************************************************************** - - Synopsis [Lookup up `key' in `table'.] - - Description [Lookup up `key' in `table'. If an entry is found, 1 is - returned and if `value' is not nil, the variable it points to is set - to the associated value. If an entry is not found, 0 is returned - and the variable pointed by value is unchanged.] - - SideEffects [None] - - SeeAlso [st_lookup_int] - -******************************************************************************/ -int -st_lookup(st_table *table, void *key, void *value) -{ - int hash_val; - st_table_entry *ptr, **last; - - hash_val = do_hash(key, table); - - FIND_ENTRY(table, hash_val, key, ptr, last); - - if (ptr == NIL(st_table_entry)) { - return 0; - } else { - if (value != NIL(void)) { - *(char **)value = ptr->record; - } - return 1; - } - -} /* st_lookup */ - - -/**Function******************************************************************** - - Synopsis [Lookup up `key' in `table'.] - - Description [Lookup up `key' in `table'. If an entry is found, 1 is - returned and if `value' is not nil, the variable it points to is - set to the associated integer value. If an entry is not found, 0 is - return and the variable pointed by `value' is unchanged.] - - SideEffects [None] - - SeeAlso [st_lookup] - -******************************************************************************/ -int -st_lookup_int(st_table *table, void *key, int *value) -{ - int hash_val; - st_table_entry *ptr, **last; - - hash_val = do_hash(key, table); - - FIND_ENTRY(table, hash_val, key, ptr, last); - - if (ptr == NIL(st_table_entry)) { - return 0; - } else { - if (value != NIL(int)) { - *value = (int) (long) ptr->record; - } - return 1; - } - -} /* st_lookup_int */ - - -/**Function******************************************************************** - - Synopsis [Insert value in table under the key 'key'.] - - Description [Insert value in table under the key 'key'. Returns 1 - if there was an entry already under the key; 0 if there was no entry - under the key and insertion was successful; ST_OUT_OF_MEM otherwise. - In either of the first two cases the new value is added.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -int -st_insert(st_table *table, void *key, void *value) -{ - int hash_val; - st_table_entry *newt; - st_table_entry *ptr, **last; - - hash_val = do_hash(key, table); - - FIND_ENTRY(table, hash_val, key, ptr, last); - - if (ptr == NIL(st_table_entry)) { - if (table->num_entries/table->num_bins >= table->max_density) { - if (rehash(table) == ST_OUT_OF_MEM) { - return ST_OUT_OF_MEM; - } - hash_val = do_hash(key, table); - } - newt = ALLOC(st_table_entry, 1); - if (newt == NIL(st_table_entry)) { - return ST_OUT_OF_MEM; - } - newt->key = (char *)key; - newt->record = (char *)value; - newt->next = table->bins[hash_val]; - table->bins[hash_val] = newt; - table->num_entries++; - return 0; - } else { - ptr->record = (char *)value; - return 1; - } - -} /* st_insert */ - - -/**Function******************************************************************** - - Synopsis [Place 'value' in 'table' under the key 'key'.] - - Description [Place 'value' in 'table' under the key 'key'. This is - done without checking if 'key' is in 'table' already. This should - only be used if you are sure there is not already an entry for - 'key', since it is undefined which entry you would later get from - st_lookup or st_find_or_add. Returns 1 if successful; ST_OUT_OF_MEM - otherwise.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -int -st_add_direct(st_table *table, void *key, void *value) -{ - int hash_val; - st_table_entry *newt; - - hash_val = do_hash(key, table); - if (table->num_entries / table->num_bins >= table->max_density) { - if (rehash(table) == ST_OUT_OF_MEM) { - return ST_OUT_OF_MEM; - } - } - hash_val = do_hash(key, table); - newt = ALLOC(st_table_entry, 1); - if (newt == NIL(st_table_entry)) { - return ST_OUT_OF_MEM; - } - newt->key = (char *)key; - newt->record = (char *)value; - newt->next = table->bins[hash_val]; - table->bins[hash_val] = newt; - table->num_entries++; - return 1; - -} /* st_add_direct */ - - -/**Function******************************************************************** - - Synopsis [Lookup `key' in `table'.] - - Description [Lookup `key' in `table'. If not found, create an - entry. In either case set slot to point to the field in the entry - where the value is stored. The value associated with `key' may then - be changed by accessing directly through slot. Returns 1 if an - entry already existed, 0 if it did not exist and creation was - successful; ST_OUT_OF_MEM otherwise. As an example: - <pre> - char **slot; - </pre> - <pre> - char *key; - </pre> - <pre> - char *value = (char *) item_ptr <-- ptr to a malloc'd structure - </pre> - <pre> - if (st_find_or_add(table, key, &slot) == 1) { - </pre> - <pre> - FREE(*slot); <-- free the old value of the record - </pre> - <pre> - } - </pre> - <pre> - *slot = value; <-- attach the new value to the record - </pre> - This replaces the equivelent code: - <pre> - if (st_lookup(table, key, &ovalue) == 1) { - </pre> - <pre> - FREE(ovalue); - </pre> - <pre> - } - </pre> - <pre> - st_insert(table, key, value); - </pre> - ] - - SideEffects [None] - - SeeAlso [st_find] - -******************************************************************************/ -int -st_find_or_add(st_table *table, void *key, void *slot) -{ - int hash_val; - st_table_entry *newt, *ptr, **last; - - hash_val = do_hash(key, table); - - FIND_ENTRY(table, hash_val, key, ptr, last); - - if (ptr == NIL(st_table_entry)) { - if (table->num_entries / table->num_bins >= table->max_density) { - if (rehash(table) == ST_OUT_OF_MEM) { - return ST_OUT_OF_MEM; - } - hash_val = do_hash(key, table); - } - newt = ALLOC(st_table_entry, 1); - if (newt == NIL(st_table_entry)) { - return ST_OUT_OF_MEM; - } - newt->key = (char *)key; - newt->record = (char *) 0; - newt->next = table->bins[hash_val]; - table->bins[hash_val] = newt; - table->num_entries++; - if (slot != NIL(void)) *(char ***)slot = &newt->record; - return 0; - } else { - if (slot != NIL(void)) *(char ***)slot = &ptr->record; - return 1; - } - -} /* st_find_or_add */ - - -/**Function******************************************************************** - - Synopsis [Lookup `key' in `table'.] - - Description [Like st_find_or_add, but does not create an entry if - one is not found.] - - SideEffects [None] - - SeeAlso [st_find_or_add] - -******************************************************************************/ -int -st_find(st_table *table, void *key, void *slot) -{ - int hash_val; - st_table_entry *ptr, **last; - - hash_val = do_hash(key, table); - - FIND_ENTRY(table, hash_val, key, ptr, last); - - if (ptr == NIL(st_table_entry)) { - return 0; - } else { - if (slot != NIL(void)) { - *(char ***)slot = &ptr->record; - } - return 1; - } - -} /* st_find */ - - -/**Function******************************************************************** - - Synopsis [Return a copy of old_table and all its members.] - - Description [Return a copy of old_table and all its members. - (st_table *) 0 is returned if there was insufficient memory to do - the copy.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -st_table * -st_copy(st_table *old_table) -{ - st_table *new_table; - st_table_entry *ptr, *newptr, *next, *newt; - int i, j, num_bins = old_table->num_bins; - - new_table = ALLOC(st_table, 1); - if (new_table == NIL(st_table)) { - return NIL(st_table); - } - - *new_table = *old_table; - new_table->bins = ALLOC(st_table_entry *, num_bins); - if (new_table->bins == NIL(st_table_entry *)) { - FREE(new_table); - return NIL(st_table); - } - for(i = 0; i < num_bins ; i++) { - new_table->bins[i] = NIL(st_table_entry); - ptr = old_table->bins[i]; - while (ptr != NIL(st_table_entry)) { - newt = ALLOC(st_table_entry, 1); - if (newt == NIL(st_table_entry)) { - for (j = 0; j <= i; j++) { - newptr = new_table->bins[j]; - while (newptr != NIL(st_table_entry)) { - next = newptr->next; - FREE(newptr); - newptr = next; - } - } - FREE(new_table->bins); - FREE(new_table); - return NIL(st_table); - } - *newt = *ptr; - newt->next = new_table->bins[i]; - new_table->bins[i] = newt; - ptr = ptr->next; - } - } - return new_table; - -} /* st_copy */ - - -/**Function******************************************************************** - - Synopsis [Delete the entry with the key pointed to by `keyp'.] - - Description [Delete the entry with the key pointed to by `keyp'. If - the entry is found, 1 is returned, the variable pointed by `keyp' is - set to the actual key and the variable pointed by `value' is set to - the corresponding entry. (This allows the freeing of the associated - storage.) If the entry is not found, then 0 is returned and nothing - is changed.] - - SideEffects [None] - - SeeAlso [st_delete_int] - -******************************************************************************/ -int -st_delete(st_table *table, void *keyp, void *value) -{ - int hash_val; - char *key = *(char **)keyp; - st_table_entry *ptr, **last; - - hash_val = do_hash(key, table); - - FIND_ENTRY(table, hash_val, key, ptr ,last); - - if (ptr == NIL(st_table_entry)) { - return 0; - } - - *last = ptr->next; - if (value != NIL(void)) *(char **)value = ptr->record; - *(char **)keyp = ptr->key; - FREE(ptr); - table->num_entries--; - return 1; - -} /* st_delete */ - - -/**Function******************************************************************** - - Synopsis [Delete the entry with the key pointed to by `keyp'.] - - Description [Delete the entry with the key pointed to by `keyp'. - `value' must be a pointer to an integer. If the entry is found, 1 - is returned, the variable pointed by `keyp' is set to the actual key - and the variable pointed by `value' is set to the corresponding - entry. (This allows the freeing of the associated storage.) If the - entry is not found, then 0 is returned and nothing is changed.] - - SideEffects [None] - - SeeAlso [st_delete] - -******************************************************************************/ -int -st_delete_int(st_table *table, void *keyp, int *value) -{ - int hash_val; - char *key = *(char **)keyp; - st_table_entry *ptr, **last; - - hash_val = do_hash(key, table); - - FIND_ENTRY(table, hash_val, key, ptr ,last); - - if (ptr == NIL(st_table_entry)) { - return 0; - } - - *last = ptr->next; - if (value != NIL(int)) *value = (int) (long) ptr->record; - *(char **)keyp = ptr->key; - FREE(ptr); - table->num_entries--; - return 1; - -} /* st_delete_int */ - - -/**Function******************************************************************** - - Synopsis [Iterates over the elements of a table.] - - Description [For each (key, value) record in `table', st_foreach - call func with the arguments - <pre> - (*func)(key, value, arg) - </pre> - If func returns ST_CONTINUE, st_foreach continues processing - entries. If func returns ST_STOP, st_foreach stops processing and - returns immediately. If func returns ST_DELETE, then the entry is - deleted from the symbol table and st_foreach continues. In the case - of ST_DELETE, it is func's responsibility to free the key and value, - if necessary.<p> - - The routine returns 1 if all items in the table were generated and 0 - if the generation sequence was aborted using ST_STOP. The order in - which the records are visited will be seemingly random.] - - SideEffects [None] - - SeeAlso [st_foreach_item st_foreach_item_int] - -******************************************************************************/ -int -st_foreach(st_table *table, ST_PFSR func, char *arg) -{ - st_table_entry *ptr, **last; - enum st_retval retval; - int i; - - for(i = 0; i < table->num_bins; i++) { - last = &table->bins[i]; ptr = *last; - while (ptr != NIL(st_table_entry)) { - retval = (*func)(ptr->key, ptr->record, arg); - switch (retval) { - case ST_CONTINUE: - last = &ptr->next; ptr = *last; - break; - case ST_STOP: - return 0; - case ST_DELETE: - *last = ptr->next; - table->num_entries--; /* cstevens@ic */ - FREE(ptr); - ptr = *last; - } - } - } - return 1; - -} /* st_foreach */ - - -/**Function******************************************************************** - - Synopsis [String hash function.] - - Description [String hash function.] - - SideEffects [None] - - SeeAlso [st_init_table] - -******************************************************************************/ -int -st_strhash(char *string, int modulus) -{ - int val = 0; - int c; - - while ((c = *string++) != '\0') { - val = val*997 + c; - } - - return ((val < 0) ? -val : val)%modulus; - -} /* st_strhash */ - - -/**Function******************************************************************** - - Synopsis [Number hash function.] - - Description [Integer number hash function.] - - SideEffects [None] - - SeeAlso [st_init_table st_numcmp] - -******************************************************************************/ -int -st_numhash(char *x, int size) -{ - return ST_NUMHASH(x, size); - -} /* st_numhash */ - - -/**Function******************************************************************** - - Synopsis [Pointer hash function.] - - Description [Pointer hash function.] - - SideEffects [None] - - SeeAlso [st_init_table st_ptrcmp] - -******************************************************************************/ -int -st_ptrhash(char *x, int size) -{ - return ST_PTRHASH(x, size); - -} /* st_ptrhash */ - - -/**Function******************************************************************** - - Synopsis [Number comparison function.] - - Description [integer number comparison function.] - - SideEffects [None] - - SeeAlso [st_init_table st_numhash] - -******************************************************************************/ -int -st_numcmp(const char *x, const char *y) -{ - return ST_NUMCMP(x, y); - -} /* st_numcmp */ - - -/**Function******************************************************************** - - Synopsis [Pointer comparison function.] - - Description [Pointer comparison function.] - - SideEffects [None] - - SeeAlso [st_init_table st_ptrhash] - -******************************************************************************/ -int -st_ptrcmp(const char *x, const char *y) -{ - return ST_NUMCMP(x, y); - -} /* st_ptrcmp */ - - -/**Function******************************************************************** - - Synopsis [Initializes a generator.] - - Description [Returns a generator handle which when used with - st_gen() will progressively return each (key, value) record in - `table'.] - - SideEffects [None] - - SeeAlso [st_free_gen] - -******************************************************************************/ -st_generator * -st_init_gen(st_table *table) -{ - st_generator *gen; - - gen = ALLOC(st_generator, 1); - if (gen == NIL(st_generator)) { - return NIL(st_generator); - } - gen->table = table; - gen->entry = NIL(st_table_entry); - gen->index = 0; - return gen; - -} /* st_init_gen */ - - -/**Function******************************************************************** - - Synopsis [returns the next (key, value) pair in the generation - sequence. ] - - Description [Given a generator returned by st_init_gen(), this - routine returns the next (key, value) pair in the generation - sequence. The pointer `value_p' can be zero which means no value - will be returned. When there are no more items in the generation - sequence, the routine returns 0. - - While using a generation sequence, deleting any (key, value) pair - other than the one just generated may cause a fatal error when - st_gen() is called later in the sequence and is therefore not - recommended.] - - SideEffects [None] - - SeeAlso [st_gen_int] - -******************************************************************************/ -int -st_gen(st_generator *gen, void *key_p, void *value_p) -{ - int i; - - if (gen->entry == NIL(st_table_entry)) { - /* try to find next entry */ - for(i = gen->index; i < gen->table->num_bins; i++) { - if (gen->table->bins[i] != NIL(st_table_entry)) { - gen->index = i+1; - gen->entry = gen->table->bins[i]; - break; - } - } - if (gen->entry == NIL(st_table_entry)) { - return 0; /* that's all folks ! */ - } - } - *(char **)key_p = gen->entry->key; - if (value_p != NIL(void)) { - *(char **)value_p = gen->entry->record; - } - gen->entry = gen->entry->next; - return 1; - -} /* st_gen */ - - -/**Function******************************************************************** - - Synopsis [Returns the next (key, value) pair in the generation - sequence.] - - Description [Given a generator returned by st_init_gen(), this - routine returns the next (key, value) pair in the generation - sequence. `value_p' must be a pointer to an integer. The pointer - `value_p' can be zero which means no value will be returned. When - there are no more items in the generation sequence, the routine - returns 0.] - - SideEffects [None] - - SeeAlso [st_gen] - -******************************************************************************/ -int -st_gen_int(st_generator *gen, void *key_p, int *value_p) -{ - int i; - - if (gen->entry == NIL(st_table_entry)) { - /* try to find next entry */ - for(i = gen->index; i < gen->table->num_bins; i++) { - if (gen->table->bins[i] != NIL(st_table_entry)) { - gen->index = i+1; - gen->entry = gen->table->bins[i]; - break; - } - } - if (gen->entry == NIL(st_table_entry)) { - return 0; /* that's all folks ! */ - } - } - *(char **)key_p = gen->entry->key; - if (value_p != NIL(int)) { - *value_p = (int) (long) gen->entry->record; - } - gen->entry = gen->entry->next; - return 1; - -} /* st_gen_int */ - - -/**Function******************************************************************** - - Synopsis [Reclaims the resources associated with `gen'.] - - Description [After generating all items in a generation sequence, - this routine must be called to reclaim the resources associated with - `gen'.] - - SideEffects [None] - - SeeAlso [st_init_gen] - -******************************************************************************/ -void -st_free_gen(st_generator *gen) -{ - FREE(gen); - -} /* st_free_gen */ - - -/*---------------------------------------------------------------------------*/ -/* Definition of internal functions */ -/*---------------------------------------------------------------------------*/ - -/*---------------------------------------------------------------------------*/ -/* Definition of static functions */ -/*---------------------------------------------------------------------------*/ - -/**Function******************************************************************** - - Synopsis [Rehashes a symbol table.] - - Description [Rehashes a symbol table.] - - SideEffects [None] - - SeeAlso [st_insert] - -******************************************************************************/ -static int -rehash(st_table *table) -{ - st_table_entry *ptr, *next, **old_bins; - int i, old_num_bins, hash_val, old_num_entries; - - /* save old values */ - old_bins = table->bins; - old_num_bins = table->num_bins; - old_num_entries = table->num_entries; - - /* rehash */ - table->num_bins = (int) (table->grow_factor * old_num_bins); - if (table->num_bins % 2 == 0) { - table->num_bins += 1; - } - table->num_entries = 0; - table->bins = ALLOC(st_table_entry *, table->num_bins); - if (table->bins == NIL(st_table_entry *)) { - table->bins = old_bins; - table->num_bins = old_num_bins; - table->num_entries = old_num_entries; - return ST_OUT_OF_MEM; - } - /* initialize */ - for (i = 0; i < table->num_bins; i++) { - table->bins[i] = 0; - } - - /* copy data over */ - for (i = 0; i < old_num_bins; i++) { - ptr = old_bins[i]; - while (ptr != NIL(st_table_entry)) { - next = ptr->next; - hash_val = do_hash(ptr->key, table); - ptr->next = table->bins[hash_val]; - table->bins[hash_val] = ptr; - table->num_entries++; - ptr = next; - } - } - FREE(old_bins); - - return 1; - -} /* rehash */ diff --git a/resources/3rdparty/cudd-2.5.0/src/st/st.h b/resources/3rdparty/cudd-2.5.0/src/st/st.h deleted file mode 100644 index dbb14bbeb..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/st/st.h +++ /dev/null @@ -1,232 +0,0 @@ -/**CHeaderFile***************************************************************** - - FileName [st.h] - - PackageName [st] - - Synopsis [Symbol table package.] - - Description [The st library provides functions to create, maintain, - and query symbol tables.] - - SeeAlso [] - - Author [] - - Copyright [] - - Revision [$Id: st.h,v 1.10 2004/01/02 07:40:31 fabio Exp fabio $] - -******************************************************************************/ - -#ifndef ST_INCLUDED -#define ST_INCLUDED - -/*---------------------------------------------------------------------------*/ -/* Nested includes */ -/*---------------------------------------------------------------------------*/ - -#ifdef __cplusplus -extern "C" { -#endif - -/*---------------------------------------------------------------------------*/ -/* Constant declarations */ -/*---------------------------------------------------------------------------*/ - -#define ST_DEFAULT_MAX_DENSITY 5 -#define ST_DEFAULT_INIT_TABLE_SIZE 11 -#define ST_DEFAULT_GROW_FACTOR 2.0 -#define ST_DEFAULT_REORDER_FLAG 0 -#define ST_OUT_OF_MEM -10000 - -/*---------------------------------------------------------------------------*/ -/* Stucture declarations */ -/*---------------------------------------------------------------------------*/ - - -/*---------------------------------------------------------------------------*/ -/* Type declarations */ -/*---------------------------------------------------------------------------*/ - -typedef struct st_table_entry st_table_entry; -struct st_table_entry { - char *key; - char *record; - st_table_entry *next; -}; - -typedef struct st_table st_table; -struct st_table { - int (*compare)(const char *, const char *); - int (*hash)(char *, int); - int num_bins; - int num_entries; - int max_density; - int reorder_flag; - double grow_factor; - st_table_entry **bins; -}; - -typedef struct st_generator st_generator; -struct st_generator { - st_table *table; - st_table_entry *entry; - int index; -}; - -enum st_retval {ST_CONTINUE, ST_STOP, ST_DELETE}; - -typedef enum st_retval (*ST_PFSR)(char *, char *, char *); - -typedef int (*ST_PFICPCP)(const char *, const char *); /* type for comparison function */ - -typedef int (*ST_PFICPI)(char *, int); /* type for hash function */ - -/*---------------------------------------------------------------------------*/ -/* Variable declarations */ -/*---------------------------------------------------------------------------*/ - - -/*---------------------------------------------------------------------------*/ -/* Macro declarations */ -/*---------------------------------------------------------------------------*/ - -/**Macro*********************************************************************** - - Synopsis [Checks whethere `key' is in `table'.] - - Description [Returns 1 if there is an entry under `key' in `table', 0 - otherwise.] - - SideEffects [None] - - SeeAlso [st_lookup] - -******************************************************************************/ -#define st_is_member(table,key) st_lookup(table,key,(char **) 0) - - -/**Macro*********************************************************************** - - Synopsis [Returns the number of entries in the table `table'.] - - Description [Returns the number of entries in the table `table'.] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -#define st_count(table) ((table)->num_entries) - - -/**Macro*********************************************************************** - - Synopsis [Iteration macro.] - - Description [An iteration macro which loops over all the entries in - `table', setting `key' to point to the key and `value' to the - associated value (if it is not nil). `gen' is a generator variable - used internally. Sample usage: - <pre> - char *key, *value; - </pre> - <pre> - st_generator *gen; - </pre> - <pre> - - st_foreach_item(table, gen, &key, &value) { - </pre> - <pre> - process_item(value); - </pre> - <pre> - } - </pre> - ] - - SideEffects [None] - - SeeAlso [st_foreach_item_int st_foreach] - -******************************************************************************/ -#define st_foreach_item(table, gen, key, value) \ - for(gen=st_init_gen(table); st_gen(gen,key,value) || (st_free_gen(gen),0);) - - -/**Macro*********************************************************************** - - Synopsis [Iteration macro.] - - Description [An iteration macro which loops over all the entries in - `table', setting `key' to point to the key and `value' to the - associated value (if it is not nil). `value' is assumed to be a - pointer to an integer. `gen' is a generator variable used - internally. Sample usage: - <pre> - char *key; - </pre> - <pre> - int value; - </pre> - <pre> - st_generator *gen; - </pre> - <pre> - - st_foreach_item_int(table, gen, &key, &value) { - </pre> - <pre> - process_item(value); - </pre> - <pre> - } - </pre> - ] - - SideEffects [None] - - SeeAlso [st_foreach_item st_foreach] - -******************************************************************************/ -#define st_foreach_item_int(table, gen, key, value) \ - for(gen=st_init_gen(table); st_gen_int(gen,key,value) || (st_free_gen(gen),0);) - -/**AutomaticStart*************************************************************/ - -/*---------------------------------------------------------------------------*/ -/* Function prototypes */ -/*---------------------------------------------------------------------------*/ - -extern st_table *st_init_table_with_params (ST_PFICPCP, ST_PFICPI, int, int, double, int); -extern st_table *st_init_table (ST_PFICPCP, ST_PFICPI); -extern void st_free_table (st_table *); -extern int st_lookup (st_table *, void *, void *); -extern int st_lookup_int (st_table *, void *, int *); -extern int st_insert (st_table *, void *, void *); -extern int st_add_direct (st_table *, void *, void *); -extern int st_find_or_add (st_table *, void *, void *); -extern int st_find (st_table *, void *, void *); -extern st_table *st_copy (st_table *); -extern int st_delete (st_table *, void *, void *); -extern int st_delete_int (st_table *, void *, int *); -extern int st_foreach (st_table *, ST_PFSR, char *); -extern int st_strhash (char *, int); -extern int st_numhash (char *, int); -extern int st_ptrhash (char *, int); -extern int st_numcmp (const char *, const char *); -extern int st_ptrcmp (const char *, const char *); -extern st_generator *st_init_gen (st_table *); -extern int st_gen (st_generator *, void *, void *); -extern int st_gen_int (st_generator *, void *, int *); -extern void st_free_gen (st_generator *); - -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} /* end of extern "C" */ -#endif - -#endif /* ST_INCLUDED */ diff --git a/resources/3rdparty/cudd-2.5.0/src/util/Makefile b/resources/3rdparty/cudd-2.5.0/src/util/Makefile deleted file mode 100644 index 61543baee..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/Makefile +++ /dev/null @@ -1,64 +0,0 @@ -# $Id$ -# -# util -- miscellaneous utility routines -#--------------------------------------------------------------------------- -.SUFFIXES: .c .o .u - -CC = gcc -RANLIB = ranlib - -FLAGS = -DUNIX -MFLAG = -ICFLAGS = -g -CFLAGS = $(ICFLAGS) $(MFLAG) $(XCFLAGS) - -LINTFLAGS = -u -n - -# this is to create the lint library -LINTSWITCH = -o - -P = util -PSRC = cpu_time.c cpu_stats.c safe_mem.c strsav.c texpand.c \ - ptime.c prtime.c pipefork.c pathsearch.c stub.c datalimit.c -POBJ = $(PSRC:.c=.o) -PUBJ = $(PSRC:.c=.u) -PHDR = util.h - -WHERE = .. -INCLUDE = $(WHERE)/include - -lib$(P).a: $(POBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.o: $(PHDR) - $(CC) -c $< -I$(INCLUDE) $(FLAGS) $(CFLAGS) - -optimize_dec: lib$(P).b - -lib$(P).b: $(PUBJ) - ar rv $@ $? - $(RANLIB) $@ - -.c.u: $(PHDR) - cc -j $< -I$(INCLUDE) $(FLAGS) $(XCFLAGS) - -# if the header files change, recompile -$(POBJ): $(PHDR) -$(PUBJ): $(PHDR) - -lint: llib-l$(P).ln - -llib-l$(P).ln: $(PSRC) $(PHDR) - lint $(LINTFLAGS) $(LINTSWITCH)$(P) -I$(INCLUDE) $(PSRC) - -tags: $(PSRC) $(PHDR) - ctags $(PSRC) $(PHDR) - -all: lib$(P).a lib$(P).b llib-l$(P).ln tags - -clean: - rm -f *.o *.u core *.warnings - -distclean: clean - rm -f lib$(P).a lib$(P).b llib-l$(P).ln tags *.bak *~ .pure diff --git a/resources/3rdparty/cudd-2.5.0/src/util/cpu_stats.c b/resources/3rdparty/cudd-2.5.0/src/util/cpu_stats.c deleted file mode 100644 index 40117d463..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/cpu_stats.c +++ /dev/null @@ -1,89 +0,0 @@ -/* LINTLIBRARY */ - -#include "util.h" - - -#ifdef BSD -#include <sys/types.h> -#include <sys/time.h> -#include <sys/resource.h> - -#if defined(_IBMR2) -#define etext _etext -#define edata _edata -#define end _end -#endif - -extern int end, etext, edata; - -#endif - -void -util_print_cpu_stats(FILE *fp) -{ -#ifdef BSD - struct rusage rusage; - struct rlimit rlp; - long text, data, vm_limit, vm_soft_limit; - double user, system, scale; - char hostname[257]; - long vm_text, vm_init_data, vm_uninit_data, vm_sbrk_data; - - /* Get the hostname */ - (void) gethostname(hostname, 256); - hostname[256] = '\0'; /* just in case */ - - /* Get the virtual memory sizes */ - vm_text = (long) (((long) (&etext)) / 1024.0 + 0.5); - vm_init_data = (long) (((long) (&edata) - (long) (&etext)) / 1024.0 + 0.5); - vm_uninit_data = (long) (((long) (&end) - (long) (&edata)) / 1024.0 + 0.5); - vm_sbrk_data = (long) (((long) sbrk(0) - (long) (&end)) / 1024.0 + 0.5); - - /* Get virtual memory limits */ - (void) getrlimit(RLIMIT_DATA, &rlp); - vm_limit = (long) (rlp.rlim_max / 1024.0 + 0.5); - vm_soft_limit = (long) (rlp.rlim_cur / 1024.0 + 0.5); - - /* Get usage stats */ - (void) getrusage(RUSAGE_SELF, &rusage); - user = rusage.ru_utime.tv_sec + rusage.ru_utime.tv_usec/1.0e6; - system = rusage.ru_stime.tv_sec + rusage.ru_stime.tv_usec/1.0e6; - scale = (user + system)*100.0; - if (scale == 0.0) scale = 0.001; - - (void) fprintf(fp, "Runtime Statistics\n"); - (void) fprintf(fp, "------------------\n"); - (void) fprintf(fp, "Machine name: %s\n", hostname); - (void) fprintf(fp, "User time %6.1f seconds\n", user); - (void) fprintf(fp, "System time %6.1f seconds\n\n", system); - - text = (int) (rusage.ru_ixrss / scale + 0.5); - data = (int) ((rusage.ru_idrss + rusage.ru_isrss) / scale + 0.5); - (void) fprintf(fp, "Average resident text size = %5ldK\n", text); - (void) fprintf(fp, "Average resident data+stack size = %5ldK\n", data); - (void) fprintf(fp, "Maximum resident size = %5ldK\n\n", - rusage.ru_maxrss/2); - (void) fprintf(fp, "Virtual text size = %5ldK\n", - vm_text); - (void) fprintf(fp, "Virtual data size = %5ldK\n", - vm_init_data + vm_uninit_data + vm_sbrk_data); - (void) fprintf(fp, " data size initialized = %5ldK\n", - vm_init_data); - (void) fprintf(fp, " data size uninitialized = %5ldK\n", - vm_uninit_data); - (void) fprintf(fp, " data size sbrk = %5ldK\n", - vm_sbrk_data); - (void) fprintf(fp, "Virtual memory limit = %5ldK (%ldK)\n\n", - vm_soft_limit, vm_limit); - - (void) fprintf(fp, "Major page faults = %ld\n", rusage.ru_majflt); - (void) fprintf(fp, "Minor page faults = %ld\n", rusage.ru_minflt); - (void) fprintf(fp, "Swaps = %ld\n", rusage.ru_nswap); - (void) fprintf(fp, "Input blocks = %ld\n", rusage.ru_inblock); - (void) fprintf(fp, "Output blocks = %ld\n", rusage.ru_oublock); - (void) fprintf(fp, "Context switch (voluntary) = %ld\n", rusage.ru_nvcsw); - (void) fprintf(fp, "Context switch (involuntary) = %ld\n", rusage.ru_nivcsw); -#else - (void) fprintf(fp, "Usage statistics not available\n"); -#endif -} diff --git a/resources/3rdparty/cudd-2.5.0/src/util/cpu_time.c b/resources/3rdparty/cudd-2.5.0/src/util/cpu_time.c deleted file mode 100644 index 2a4be9240..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/cpu_time.c +++ /dev/null @@ -1,76 +0,0 @@ -/* LINTLIBRARY */ - -#include <stdio.h> -#include "util.h" - -#ifdef IBM_WATC /* IBM Waterloo-C compiler (same as bsd 4.2) */ -#define void int -#define BSD -#endif - -#ifdef BSD -#include <sys/types.h> -#include <sys/time.h> -#include <sys/resource.h> -#endif - -#if defined(UNIX60) || defined(UNIX100) || defined(__CYGWIN32__) -#include <sys/types.h> -#include <sys/times.h> -#endif - -#ifdef vms /* VAX/C compiler -- times() with 100 HZ clock */ -#include <types.h> -#include <time.h> -#endif - - - -/* - * util_cpu_time -- return a long which represents the elapsed processor - * time in milliseconds since some constant reference - */ -long -util_cpu_time() -{ - long t = 0; - -#ifdef BSD - struct rusage rusage; - (void) getrusage(RUSAGE_SELF, &rusage); - t = (long) rusage.ru_utime.tv_sec*1000 + rusage.ru_utime.tv_usec/1000; -#endif - -#ifdef IBMPC - long ltime; - (void) time(<ime); - t = ltime * 1000; -#endif - -#ifdef UNIX60 /* times() with 60 Hz resolution */ - struct tms buffer; - times(&buffer); - t = buffer.tms_utime * 16.6667; -#endif - -#ifdef UNIX100 - struct tms buffer; /* times() with 100 Hz resolution */ - times(&buffer); - t = buffer.tms_utime * 10; -#endif - -#ifdef __CYGWIN32__ - /* Works under Windows NT but not Windows 95. */ - struct tms buffer; /* times() with 1000 Hz resolution */ - times(&buffer); - t = buffer.tms_utime; -#endif - -#ifdef vms - tbuffer_t buffer; /* times() with 100 Hz resolution */ - times(&buffer); - t = buffer.proc_user_time * 10; -#endif - - return t; -} diff --git a/resources/3rdparty/cudd-2.5.0/src/util/datalimit.c b/resources/3rdparty/cudd-2.5.0/src/util/datalimit.c deleted file mode 100644 index bec93a639..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/datalimit.c +++ /dev/null @@ -1,62 +0,0 @@ -/* $Id: datalimit.c,v 1.5 2007/08/24 18:17:31 fabio Exp fabio $ */ - -#if !defined(HAVE_SYS_RESOURCE_H) -# ifdef WIN32 -# define HAVE_SYS_RESOURCE_H 0 -# else -# define HAVE_SYS_RESOURCE_H 1 -# endif -#endif -#if !defined(HAVE_SYS_TIME_H) -# ifdef WIN32 -# define HAVE_SYS_TIME_H 0 -# else -# define HAVE_SYS_TIME_H 1 -# endif -#endif -#if !defined(HAVE_GETRLIMIT) -# ifdef WIN32 -# define HAVE_GETRLIMIT 0 -# else -# define HAVE_GETRLIMIT 1 -# endif -#endif - -#if HAVE_SYS_RESOURCE_H == 1 -# if (HAVE_SYS_TIME_H == 1) -# include <sys/time.h> -# endif -# include <sys/resource.h> -#endif - -#ifndef RLIMIT_DATA_DEFAULT -#define RLIMIT_DATA_DEFAULT 1073741824 /* assume 1024MB by default */ -#endif - -#ifndef EXTERN -# ifdef __cplusplus -# define EXTERN extern "C" -# else -# define EXTERN extern -# endif -#endif - -EXTERN unsigned long getSoftDataLimit(void); - -unsigned long -getSoftDataLimit(void) -{ -#if HAVE_SYS_RESOURCE_H == 1 && HAVE_GETRLIMIT == 1 && defined(RLIMIT_DATA) - struct rlimit rl; - int result; - - result = getrlimit(RLIMIT_DATA, &rl); - if (result != 0 || rl.rlim_cur == RLIM_INFINITY) - return((unsigned long) RLIMIT_DATA_DEFAULT); - else - return((unsigned long) rl.rlim_cur); -#else - return((unsigned long) RLIMIT_DATA_DEFAULT); -#endif - -} /* end of getSoftDataLimit */ diff --git a/resources/3rdparty/cudd-2.5.0/src/util/pathsearch.c b/resources/3rdparty/cudd-2.5.0/src/util/pathsearch.c deleted file mode 100644 index 67c34b868..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/pathsearch.c +++ /dev/null @@ -1,94 +0,0 @@ -/* LINTLIBRARY */ - -#include <stdio.h> -#include "util.h" - -static int check_file (char const *, char const *); - -char * -util_path_search(char const *prog) -{ -#ifdef UNIX - return util_file_search(prog, getenv("PATH"), (char *) "x"); -#else - return util_file_search(prog, NIL(char), (char *) "x"); -#endif -} - - -char * -util_file_search( - char const *file, /* file we're looking for */ - char *path, /* search path, colon separated */ - char const *mode /* "r", "w", or "x" */) -{ - int quit; - char *buffer, *filename, *save_path, *cp; - - if (path == 0 || strcmp(path, "") == 0) { - path = (char *) "."; /* just look in the current directory */ - } - - save_path = path = strsav(path); - quit = 0; - do { - cp = strchr(path, ':'); - if (cp != 0) { - *cp = '\0'; - } else { - quit = 1; - } - - /* cons up the filename out of the path and file name */ - if (strcmp(path, ".") == 0) { - buffer = strsav(file); - } else { - buffer = ALLOC(char, strlen(path) + strlen(file) + 4); - (void) sprintf(buffer, "%s/%s", path, file); - } - filename = util_tilde_expand(buffer); - FREE(buffer); - - /* see if we can access it */ - if (check_file(filename, mode)) { - FREE(save_path); - return filename; - } - FREE(filename); - path = ++cp; - } while (! quit); - - FREE(save_path); - return 0; -} - - -static int -check_file(char const *filename, char const *mode) -{ -#ifdef UNIX - int access_mode = /*F_OK*/ 0; - - if (strcmp(mode, "r") == 0) { - access_mode = /*R_OK*/ 4; - } else if (strcmp(mode, "w") == 0) { - access_mode = /*W_OK*/ 2; - } else if (strcmp(mode, "x") == 0) { - access_mode = /*X_OK*/ 1; - } - return access(filename, access_mode) == 0; -#else - FILE *fp; - int got_file; - - if (strcmp(mode, "x") == 0) { - mode = "r"; - } - fp = fopen(filename, mode); - got_file = (fp != 0); - if (fp != 0) { - (void) fclose(fp); - } - return got_file; -#endif -} diff --git a/resources/3rdparty/cudd-2.5.0/src/util/pipefork.c b/resources/3rdparty/cudd-2.5.0/src/util/pipefork.c deleted file mode 100644 index 09acb2fd2..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/pipefork.c +++ /dev/null @@ -1,95 +0,0 @@ -/* - * Revision Control Information - * - * $Id: pipefork.c,v 1.7 2012/02/05 05:34:04 fabio Exp fabio $ - * - */ -/* LINTLIBRARY */ - -#include "util.h" -#ifndef WIN32 -# include <sys/wait.h> -#endif - -/* - * util_pipefork - fork a command and set up pipes to and from - * - * Rick L Spickelmier, 3/23/86 - * Richard Rudell, 4/6/86 - * Rick L Spickelmier, 4/30/90, got rid of slimey vfork semantics - * - * Returns: - * 1 for success, with toCommand and fromCommand pointing to the streams - * 0 for failure - */ - -/* ARGSUSED */ -int -util_pipefork( - char * const *argv, /* normal argv argument list */ - FILE **toCommand, /* pointer to the sending stream */ - FILE **fromCommand, /* pointer to the reading stream */ - int *pid) -{ -#ifdef UNIX - int forkpid, waitPid; - int topipe[2], frompipe[2]; - char buffer[1024]; - int status; - - /* create the PIPES... - * fildes[0] for reading from command - * fildes[1] for writing to command - */ - if (pipe(topipe)) return(0); - if (pipe(frompipe)) return(0); - -#ifdef __CYGWIN32__ - if ((forkpid = fork()) == 0) { -#else - if ((forkpid = vfork()) == 0) { -#endif - /* child here, connect the pipes */ - (void) dup2(topipe[0], fileno(stdin)); - (void) dup2(frompipe[1], fileno(stdout)); - - (void) close(topipe[0]); - (void) close(topipe[1]); - (void) close(frompipe[0]); - (void) close(frompipe[1]); - - (void) execvp(argv[0], argv); - (void) sprintf(buffer, "util_pipefork: can not exec %s", argv[0]); - perror(buffer); - (void) _exit(1); - } - - if (pid) { - *pid = forkpid; - } - -#ifdef __CYGWIN32__ - waitPid = waitpid(-1, &status, WNOHANG); -#else - waitPid = wait3(&status, WNOHANG, NULL); -#endif - - /* parent here, use slimey vfork() semantics to get return status */ - if (waitPid == forkpid && WIFEXITED(status)) { - return 0; - } - if ((*toCommand = fdopen(topipe[1], "w")) == NULL) { - return 0; - } - if ((*fromCommand = fdopen(frompipe[0], "r")) == NULL) { - return 0; - } - (void) close(topipe[0]); - (void) close(frompipe[1]); - return 1; -#else - (void) fprintf(stderr, - "util_pipefork: not implemented on your operating system\n"); - return 0; -#endif -} diff --git a/resources/3rdparty/cudd-2.5.0/src/util/prtime.c b/resources/3rdparty/cudd-2.5.0/src/util/prtime.c deleted file mode 100644 index 236eafb75..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/prtime.c +++ /dev/null @@ -1,21 +0,0 @@ -/* LINTLIBRARY */ - -#include <stdio.h> -#include "util.h" - - -/* - * util_print_time -- massage a long which represents a time interval in - * milliseconds, into a string suitable for output - * - * Hack for IBM/PC -- avoids using floating point - */ - -char * -util_print_time(unsigned long t) -{ - static char s[40]; - - (void) sprintf(s, "%lu.%02lu sec", t/1000, (t%1000)/10); - return s; -} diff --git a/resources/3rdparty/cudd-2.5.0/src/util/ptime.c b/resources/3rdparty/cudd-2.5.0/src/util/ptime.c deleted file mode 100644 index 4510857be..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/ptime.c +++ /dev/null @@ -1,9 +0,0 @@ -/* LINTLIBRARY */ -#include "util.h" - -/* backwards compatibility */ -long -ptime() -{ - return util_cpu_time(); -} diff --git a/resources/3rdparty/cudd-2.5.0/src/util/restart.c b/resources/3rdparty/cudd-2.5.0/src/util/restart.c deleted file mode 100644 index b81dcb8c8..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/restart.c +++ /dev/null @@ -1,137 +0,0 @@ -#include <stdio.h> -#include "util.h" - -#if (defined(sun) && ! defined(sparc)) || defined(vax) - -#include <signal.h> -#include <sys/types.h> -#include <sys/time.h> - -static char *save_stack_base; -static char *stack_lo_addr; -static char *stack_hi_addr; -static int stack_size; - -static int restart_global_flag; -static char *old_file_name; -static char *new_file_name; - -char *util_save_sp; /* set by util_restart_save_state() */ -extern char *sbrk(); - -static void -grow_stack() -{ - int i, space[256]; - - for(i = 0; i < 256; i++) { - space[i] = 0; - } - if ((char *) &i > stack_lo_addr) { - grow_stack(); - } -} - - -/* ARGSUSED */ -static int -handle_sigquit(int sig, int code, struct sigcontext *scp) -{ - if (util_restart_save_state()) { - /* we are restarting ! -- return from signal */ - - } else { - /* copy stack to user data space */ - stack_lo_addr = util_save_sp; - stack_size = stack_hi_addr - stack_lo_addr + 1; - save_stack_base = sbrk(stack_size); - (void) memcpy(save_stack_base, stack_lo_addr, stack_size); - - /* write a new executable */ - (void) fprintf(stderr, "Writing executable %s ...\n", new_file_name); - (void) util_save_image(old_file_name, new_file_name); - - /* terminate if signal was a QUIT */ - if (sig == SIGQUIT) { - (void) _exit(1); - } - } -} - - -static void -restart_program() -{ - (void) fprintf(stderr, "Continuing execution ...\n"); - - /* create the stack */ - grow_stack(); - -#ifdef vax - asm("movl _util_save_sp,sp"); -#endif -#ifdef sun - asm("movl _util_save_sp,sp"); -#endif - - /* copy the stack back from user space */ - (void) memcpy(stack_lo_addr, save_stack_base, stack_size); - - /* remove the sbrk for the stack */ - if (sbrk(-stack_size) < 0) { - perror("sbrk"); - } - - util_restart_restore_state(); /* jump back into handle_sigquit() */ -} - -void -util_restart(char const *old, char const *neW, int interval) -{ - struct itimerval itimer; - -#ifdef vax -#ifdef ultrix - stack_hi_addr = (char *) 0x7fffe3ff; /* ultrix */ -#else - stack_hi_addr = (char *) 0x7fffebff; /* bsd 4.3 */ -#endif -#endif -#ifdef sun - stack_hi_addr = (char *) 0x0effffff; /* Sun OS 3.2, 3.4 */ -#endif - - old_file_name = old; - new_file_name = neW; - - (void) signal(SIGQUIT, handle_sigquit); - - if (interval > 0) { - (void) signal(SIGVTALRM, handle_sigquit); - itimer.it_interval.tv_sec = interval; - itimer.it_interval.tv_usec = 0; - itimer.it_value.tv_sec = interval; - itimer.it_value.tv_usec = 0; - if (setitimer(ITIMER_VIRTUAL, &itimer, (struct itimerval *) 0) < 0) { - perror("setitimer"); - exit(1); - } - } - - if (restart_global_flag) { - restart_program(); - } - restart_global_flag = 1; -} - -#else - -/* ARGSUSED */ -void -util_restart(char const *old, char const *neW, int interval) -{ - (void) fprintf(stderr, - "util_restart: not supported on your operating system/hardware\n"); -} - -#endif diff --git a/resources/3rdparty/cudd-2.5.0/src/util/safe_mem.c b/resources/3rdparty/cudd-2.5.0/src/util/safe_mem.c deleted file mode 100644 index 597cc892b..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/safe_mem.c +++ /dev/null @@ -1,97 +0,0 @@ -/* LINTLIBRARY */ - -#include <stdio.h> -#include "util.h" - -/* - * These are interface routines to be placed between a program and the - * system memory allocator. - * - * It forces well-defined semantics for several 'borderline' cases: - * - * malloc() of a 0 size object is guaranteed to return something - * which is not 0, and can safely be freed (but not dereferenced) - * free() accepts (silently) an 0 pointer - * realloc of a 0 pointer is allowed, and is equiv. to malloc() - * For the IBM/PC it forces no object > 64K; note that the size argument - * to malloc/realloc is a 'long' to catch this condition - * - * The function pointer MMoutOfMemory() contains a vector to handle a - * 'out-of-memory' error (which, by default, points at a simple wrap-up - * and exit routine). - */ - -#ifdef __cplusplus -extern "C" { -#endif - -extern char *MMalloc(long); -extern void MMout_of_memory(long); -extern char *MMrealloc(char *, long); - -void (*MMoutOfMemory)(long) = MMout_of_memory; - -#ifdef __cplusplus -} -#endif - - -/* MMout_of_memory -- out of memory for lazy people, flush and exit */ -void -MMout_of_memory(long size) -{ - (void) fflush(stdout); - (void) fprintf(stderr, "\nout of memory allocating %lu bytes\n", - (unsigned long) size); - exit(1); -} - - -char * -MMalloc(long size) -{ - char *p; - -#ifdef IBMPC - if (size > 65000L) { - if (MMoutOfMemory != (void (*)(long)) 0 ) (*MMoutOfMemory)(size); - return NIL(char); - } -#endif - if (size == 0) size = sizeof(long); - if ((p = (char *) malloc((unsigned long) size)) == NIL(char)) { - if (MMoutOfMemory != 0 ) (*MMoutOfMemory)(size); - return NIL(char); - } - return p; -} - - -char * -MMrealloc(char *obj, long size) -{ - char *p; - -#ifdef IBMPC - if (size > 65000L) { - if (MMoutOfMemory != 0 ) (*MMoutOfMemory)(size); - return NIL(char); - } -#endif - if (obj == NIL(char)) return MMalloc(size); - if (size <= 0) size = sizeof(long); - if ((p = (char *) realloc(obj, (unsigned long) size)) == NIL(char)) { - if (MMoutOfMemory != 0 ) (*MMoutOfMemory)(size); - return NIL(char); - } - return p; -} - - -void -MMfree(char *obj) -{ - if (obj != 0) { - free(obj); - } -} diff --git a/resources/3rdparty/cudd-2.5.0/src/util/saveimage.c b/resources/3rdparty/cudd-2.5.0/src/util/saveimage.c deleted file mode 100644 index 32332ef40..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/saveimage.c +++ /dev/null @@ -1,229 +0,0 @@ -/* LINTLIBRARY */ - - -/* - * saveimage.c -- - * - * Function to save an executable copy of the current process's - * image in a file. - * - */ - -#include <stdio.h> -#include "util.h" - -#ifdef BSD -#include <sys/types.h> -#include <sys/stat.h> -#include <a.out.h> -#include <errno.h> - -extern int errno; - -#define BUFSIZE 8192 - -extern long lseek(); /* For lint */ -extern int getpagesize(); -extern char *sbrk(); - -static int copy_file(); -static int pad_file(); - - -int -util_save_image(char const *orig_file_name, char const *save_file_name) -{ - int origFd = -1, saveFd = -1; - char *start_data, *end_data, *start_text, *end_round; - struct exec old_hdr, new_hdr; - struct stat old_stat; - int n, page_size, length_text, length_data; - - if ((origFd = open(orig_file_name, 0)) < 0) { - perror(orig_file_name); - (void) fprintf(stderr, "Cannot open original a.out file\n"); - goto bad; - } - - if (fstat(origFd, &old_stat) < 0) { - perror(orig_file_name); - (void) fprintf(stderr, "Cannot stat original a.out file\n"); - goto bad; - } - - /* - * Read the a.out header from the original file. - */ - if (read(origFd, (char *) &old_hdr, sizeof(old_hdr)) != sizeof(old_hdr)) { - perror(orig_file_name); - (void) fprintf(stderr, "Cannot read original a.out header\n"); - goto bad; - } - if (N_BADMAG(old_hdr)) { - (void) fprintf(stderr, "File %s has a bad magic number (%o)\n", - orig_file_name, old_hdr.a_magic); - goto bad; - } - if (old_hdr.a_magic != ZMAGIC) { - (void) fprintf(stderr, "File %s is not demand-paged\n", orig_file_name); - goto bad; - } - - /* - * Open the output file. - */ - if (access(save_file_name, /* F_OK */ 0) == 0) { - (void) unlink(save_file_name); - } - if ((saveFd = creat(save_file_name, 0777)) < 0) { - if (errno == ETXTBSY) { - (void) unlink(save_file_name); - saveFd = creat(save_file_name, 0777); - } - if (saveFd < 0) { - perror(save_file_name); - (void) fprintf(stderr, "Cannot create save file.\n"); - goto bad; - } - } - - /* - * Find out how far the data segment extends. - */ - new_hdr = old_hdr; - end_data = sbrk(0); - page_size = getpagesize(); - n = ((((int) end_data) + page_size - 1) / page_size) * page_size; - end_round = (char *) n; - if (end_round > end_data) { - end_data = sbrk(end_round - end_data); - } - -#ifdef vax - start_text = 0; - length_text = new_hdr.a_text; - start_data = (char *) old_hdr.a_text; - length_data = end_data - start_data; -#endif vax -#ifdef sun - start_text = (char *) N_TXTADDR(old_hdr) + sizeof(old_hdr); - length_text = old_hdr.a_text - sizeof(old_hdr); - start_data = (char *) N_DATADDR(old_hdr); - length_data = end_data - start_data; -#endif sun - new_hdr.a_data = end_data - start_data; - new_hdr.a_bss = 0; - - /* - * First, the header plus enough pad to extend up to N_TXTOFF. - */ - if (write(saveFd, (char *) &new_hdr, (int) sizeof(new_hdr)) != - sizeof(new_hdr)) { - perror("write"); - (void) fprintf(stderr, "Error while copying header.\n"); - goto bad; - } - if (! pad_file(saveFd, N_TXTOFF(old_hdr) - sizeof(new_hdr))) { - (void) fprintf(stderr, "Error while padding.\n"); - goto bad; - } - - - /* - * Copy our text segment - */ - if (write(saveFd, start_text, length_text) != length_text) { - perror("write"); - (void) fprintf(stderr, "Error while copying text segment.\n"); - goto bad; - } - - - /* - * Copy our data segment - */ - if (write(saveFd, start_data, length_data) != length_data) { - perror("write"); - (void) fprintf(stderr, "Error while copying data segment.\n"); - goto bad; - } - - /* - * Copy the symbol table and everything else. - * This takes us to the end of the original file. - */ - (void) lseek(origFd, (long) N_SYMOFF(old_hdr), 0); - if (! copy_file(origFd, saveFd, old_stat.st_size - N_SYMOFF(old_hdr))) { - (void) fprintf(stderr, "Error while copying symbol table.\n"); - goto bad; - } - (void) close(origFd); - (void) close(saveFd); - return 1; - -bad: - if (origFd >= 0) (void) close(origFd); - if (saveFd >= 0) (void) close(saveFd); - return 0; -} - - -static int -copy_file(inFd, outFd, nbytes) -int inFd, outFd; -unsigned long nbytes; -{ - char buf[BUFSIZE]; - int nread, ntoread; - - while (nbytes > 0) { - ntoread = nbytes; - if (ntoread > sizeof buf) ntoread = sizeof buf; - if ((nread = read(inFd, buf, ntoread)) != ntoread) { - perror("read"); - return (0); - } - if (write(outFd, buf, nread) != nread) { - perror("write"); - return (0); - } - nbytes -= nread; - } - - return (1); -} - - -static int -pad_file(outFd, nbytes) -int outFd; -int nbytes; -{ - char buf[BUFSIZE]; - int nzero; - - nzero = (nbytes > sizeof(buf)) ? sizeof(buf) : nbytes; - bzero(buf, nzero); - while (nbytes > 0) { - nzero = (nbytes > sizeof(buf)) ? sizeof(buf) : nbytes; - if (write(outFd, buf, nzero) != nzero) { - perror("write"); - return (0); - } - nbytes -= nzero; - } - - return (1); -} -#else - -/* ARGSUSED */ -int -util_save_image(char const *orig_file_name, char const *save_file_name) -{ - (void) fprintf(stderr, - "util_save_image: not implemented on your operating system\n"); - return 0; -} - -#endif diff --git a/resources/3rdparty/cudd-2.5.0/src/util/state.c b/resources/3rdparty/cudd-2.5.0/src/util/state.c deleted file mode 100644 index ef830aa74..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/state.c +++ /dev/null @@ -1,82 +0,0 @@ -#ifdef lint -util_restart_save_state() -{ - return 0; -} - - -util_restart_restore_state() -{ -} - -#else - -static char rcsid[] = "$Id: state.c,v 1.1 1997/11/04 22:38:50 fabio Exp $"; - -#ifdef vax -int util_restart_state[32]; - -util_restart_save_state() -{ - asm("movl sp,_util_save_sp"); - asm("movl r1,_util_restart_state"); - asm("movl r2,_util_restart_state+4"); - asm("movl r3,_util_restart_state+8"); - asm("movl r4,_util_restart_state+12"); - asm("movl r5,_util_restart_state+16"); - asm("movl r6,_util_restart_state+20"); - asm("movl r7,_util_restart_state+24"); - asm("movl r8,_util_restart_state+28"); - asm("movl r9,_util_restart_state+32"); - asm("movl r10,_util_restart_state+36"); - asm("movl r11,_util_restart_state+40"); - asm("movl 8(fp),_util_restart_state+44"); - asm("movl 12(fp),_util_restart_state+48"); - asm("movl 16(fp),_util_restart_state+52"); - asm("movl $0,r0"); -} - -util_restart_restore_state() -{ - asm("movl _util_restart_state,r1"); - asm("movl _util_restart_state+4,r2"); - asm("movl _util_restart_state+8,r3"); - asm("movl _util_restart_state+12,r4"); - asm("movl _util_restart_state+16,r5"); - asm("movl _util_restart_state+20,r6"); - asm("movl _util_restart_state+24,r7"); - asm("movl _util_restart_state+28,r8"); - asm("movl _util_restart_state+32,r9"); - asm("movl _util_restart_state+36,r10"); - asm("movl _util_restart_state+40,r11"); - asm("movl _util_restart_state+44,ap"); - asm("movl _util_restart_state+48,fp"); - asm("addl3 fp,$4,sp"); - asm("movl _util_restart_state+52,r0"); - asm("jmp (r0)"); -} -#endif - - -#if defined(sun) && ! defined(sparc) -int util_restart_state[32]; - -util_restart_save_state() -{ - asm("movel sp,_util_save_sp"); - asm("movel sp@,_util_restart_state"); - asm("movel sp@(0x4),_util_restart_state+4"); - asm("moveml #0xFFFF,_util_restart_state+8"); - return 0; -} - -util_restart_restore_state() -{ - asm("moveml _util_restart_state+8,#0xFFFF"); - asm("movel _util_restart_state+4,sp@(0x4)"); - asm("movel _util_restart_state,sp@"); - return 1; -} -#endif - -#endif diff --git a/resources/3rdparty/cudd-2.5.0/src/util/strsav.c b/resources/3rdparty/cudd-2.5.0/src/util/strsav.c deleted file mode 100644 index 454e237c4..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/strsav.c +++ /dev/null @@ -1,14 +0,0 @@ -/* LINTLIBRARY */ - -#include <stdio.h> -#include "util.h" - - -/* - * util_strsav -- save a copy of a string - */ -char * -util_strsav(char const *s) -{ - return strcpy(ALLOC(char, strlen(s)+1), s); -} diff --git a/resources/3rdparty/cudd-2.5.0/src/util/stub.c b/resources/3rdparty/cudd-2.5.0/src/util/stub.c deleted file mode 100644 index 93f57e67f..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/stub.c +++ /dev/null @@ -1,82 +0,0 @@ -/* LINTLIBRARY */ - -#ifdef LACK_SYS5 - -char * -memcpy(s1, s2, n) -char *s1, *s2; -int n; -{ - extern bcopy(); - bcopy(s2, s1, n); - return s1; -} - -char * -memset(s, c, n) -char *s; -int c; -int n; -{ - extern bzero(); - register int i; - - if (c == 0) { - bzero(s, n); - } else { - for(i = n-1; i >= 0; i--) { - *s++ = c; - } - } - return s; -} - -char * -strchr(s, c) -char *s; -int c; -{ - extern char *index(); - return index(s, c); -} - -char * -strrchr(s, c) -char *s; -int c; -{ - extern char *rindex(); - return rindex(s, c); -} - - -#endif - -#ifndef UNIX -#include <stdio.h> - -FILE * -popen(string, mode) -const char *string; -const char *mode; -{ - (void) fprintf(stderr, "popen not supported on your operating system\n"); - return NULL; -} - - -int -pclose(fp) -FILE *fp; -{ - (void) fprintf(stderr, "pclose not supported on your operating system\n"); - return -1; -} -#endif - -/* put something here in case some compilers abort on empty files ... */ -int -util_do_nothing() -{ - return 1; -} diff --git a/resources/3rdparty/cudd-2.5.0/src/util/texpand.c b/resources/3rdparty/cudd-2.5.0/src/util/texpand.c deleted file mode 100644 index c14defee8..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/texpand.c +++ /dev/null @@ -1,57 +0,0 @@ -/* LINTLIBRARY */ - -#include <stdio.h> -#include "util.h" - -#ifdef BSD -#include <pwd.h> -#endif - - -char * -util_tilde_expand(char const *fname) -{ -#ifdef BSD - struct passwd *userRecord; - char username[256], *filename; - register int i, j; - - filename = ALLOC(char, strlen(fname) + 256); - - /* Clear the return string */ - i = 0; - filename[0] = '\0'; - - /* Tilde? */ - if (fname[0] == '~') { - j = 0; - i = 1; - while ((fname[i] != '\0') && (fname[i] != '/')) { - username[j++] = fname[i++]; - } - username[j] = '\0'; - - if (username[0] == '\0') { - /* ~/ resolves to home directory of current user */ - if ((userRecord = getpwuid(getuid())) != 0) { - (void) strcat(filename, userRecord->pw_dir); - } else { - i = 0; - } - } else { - /* ~user/ resolves to home directory of 'user' */ - if ((userRecord = getpwnam(username)) != 0) { - (void) strcat(filename, userRecord->pw_dir); - } else { - i = 0; - } - } - } - - /* Concantenate remaining portion of file name */ - (void) strcat(filename, fname + i); - return filename; -#else - return strsav(fname); -#endif -} diff --git a/resources/3rdparty/cudd-2.5.0/src/util/util.h b/resources/3rdparty/cudd-2.5.0/src/util/util.h deleted file mode 100644 index 58bf0473c..000000000 --- a/resources/3rdparty/cudd-2.5.0/src/util/util.h +++ /dev/null @@ -1,206 +0,0 @@ -/* $Id: util.h,v 1.10 2012/02/05 05:34:04 fabio Exp fabio $ */ - -#ifndef UTIL_H -#define UTIL_H - -#ifdef __cplusplus -extern "C" { -#endif - -#if defined(__GNUC__) -# define UTIL_INLINE __inline__ -# if __GNUC__ > 2 || __GNUC_MINOR__ >= 7 -# define UTIL_UNUSED __attribute__ ((unused)) -# else -# define UTIL_UNUSED -# endif -#else -# define UTIL_INLINE -# define UTIL_UNUSED -#endif - -#ifndef SIZEOF_VOID_P -#define SIZEOF_VOID_P 4 -#endif -#ifndef SIZEOF_INT -#define SIZEOF_INT 4 -#endif -#ifndef SIZEOF_LONG -#define SIZEOF_LONG 4 -#endif - -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 -typedef long util_ptrint; -#else -typedef int util_ptrint; -#endif - -/* #define USE_MM */ /* choose libmm.a as the memory allocator */ - -/* these are too entrenched to get away with changing the name */ -#define strsav util_strsav -#ifndef WIN32 -#include <unistd.h> -#endif - -#define NIL(type) ((type *) 0) - -#if defined(USE_MM) || defined(MNEMOSYNE) -/* - * assumes the memory manager is either libmm.a or libmnem.a - * libmm.a: - * - allows malloc(0) or realloc(obj, 0) - * - catches out of memory (and calls MMout_of_memory()) - * - catch free(0) and realloc(0, size) in the macros - * libmnem.a: - * - reports memory leaks - * - is used in conjunction with the mnemalyse postprocessor - */ -#ifdef MNEMOSYNE -#include "mnemosyne.h" -#define ALLOC(type, num) \ - ((num) ? ((type *) malloc(sizeof(type) * (num))) : \ - ((type *) malloc(sizeof(long)))) -#else -#define ALLOC(type, num) \ - ((type *) malloc(sizeof(type) * (num))) -#endif -#define REALLOC(type, obj, num) \ - (obj) ? ((type *) realloc((char *) obj, sizeof(type) * (num))) : \ - ((type *) malloc(sizeof(type) * (num))) -#define FREE(obj) \ - ((obj) ? (free((char *) (obj)), (obj) = 0) : 0) -#else -/* - * enforce strict semantics on the memory allocator - * - when in doubt, delete the '#define USE_MM' above - */ -#define ALLOC(type, num) \ - ((type *) MMalloc((long) sizeof(type) * (long) (num))) -#define REALLOC(type, obj, num) \ - ((type *) MMrealloc((char *) (obj), (long) sizeof(type) * (long) (num))) -#define FREE(obj) \ - ((obj) ? (free((char *) (obj)), (obj) = 0) : 0) -#endif - - -/* Ultrix (and SABER) have 'fixed' certain functions which used to be int */ -#if defined(ultrix) || defined(SABER) || defined(aiws) || defined(hpux) || defined(apollo) || defined(__osf__) || defined(__SVR4) || defined(__GNUC__) -#define VOID_OR_INT void -#define VOID_OR_CHAR void -#else -#define VOID_OR_INT int -#define VOID_OR_CHAR char -#endif - - -/* No machines seem to have much of a problem with these */ -#include <stdio.h> -#include <ctype.h> - - -/* Some machines fail to define some functions in stdio.h */ -#if !defined(__STDC__) && !defined(__cplusplus) && !defined(WIN32) -extern FILE *popen(), *tmpfile(); -extern int pclose(); -#endif - - -/* most machines don't give us a header file for these */ -#if (defined(__STDC__) || defined(__cplusplus) || defined(ultrix)) && !defined(MNEMOSYNE) || defined(__SVR4) || defined(WIN32) -# include <stdlib.h> -#else -# ifndef _IBMR2 - extern VOID_OR_INT abort(), exit(); -# endif -# if !defined(MNEMOSYNE) && !defined(_IBMR2) - extern VOID_OR_INT free (void *); - extern VOID_OR_CHAR *malloc(), *realloc(); -# endif - extern char *getenv(); - extern int system(); - extern double atof(); -#endif - - -/* some call it strings.h, some call it string.h; others, also have memory.h */ -#if defined(__STDC__) || defined(__cplusplus) || defined(_IBMR2) || defined(ultrix) || defined(WIN32) -#include <string.h> -#else -/* ANSI C string.h -- 1/11/88 Draft Standard */ -extern char *strcpy(), *strncpy(), *strcat(), *strncat(), *strerror(); -extern char *strpbrk(), *strtok(), *strchr(), *strrchr(), *strstr(); -extern int strcoll(), strxfrm(), strncmp(), strlen(), strspn(), strcspn(); -extern char *memmove(), *memccpy(), *memchr(), *memcpy(), *memset(); -extern int memcmp(), strcmp(); -#endif - - -#ifdef __STDC__ -#include <assert.h> -#else -#ifndef NDEBUG -#define assert(ex) {\ - if (! (ex)) {\ - (void) fprintf(stderr,\ - "Assertion failed: file %s, line %d\n\"%s\"\n",\ - __FILE__, __LINE__, "ex");\ - (void) fflush(stdout);\ - abort();\ - }\ -} -#else -#define assert(ex) ; -#endif -#endif - - -#define fail(why) {\ - (void) fprintf(stderr, "Fatal error: file %s, line %d\n%s\n",\ - __FILE__, __LINE__, why);\ - (void) fflush(stdout);\ - abort();\ -} - - -#ifdef lint -#undef putc /* correct lint '_flsbuf' bug */ -#undef ALLOC /* allow for lint -h flag */ -#undef REALLOC -#define ALLOC(type, num) (((type *) 0) + (num)) -#define REALLOC(type, obj, num) ((obj) + (num)) -#endif - - -/* These arguably do NOT belong in util.h */ -#define ABS(a) ((a) < 0 ? -(a) : (a)) -#define MAX(a,b) ((a) > (b) ? (a) : (b)) -#define MIN(a,b) ((a) < (b) ? (a) : (b)) - - -#ifndef USE_MM -extern char *MMalloc (long); -extern void MMout_of_memory (long); -extern void (*MMoutOfMemory) (long); -extern char *MMrealloc (char *, long); -#endif - -extern long util_cpu_time (void); -extern char *util_path_search (char const *); -extern char *util_file_search (char const *, char *, char const *); -extern int util_pipefork (char * const *, FILE **, FILE **, int *); -extern void util_print_cpu_stats (FILE *); -extern char *util_print_time (unsigned long); -extern int util_save_image (char const *, char const *); -extern char *util_strsav (char const *); -extern char *util_tilde_expand (char const *); -extern void util_restart (char const *, char const *, int); - - -extern unsigned long getSoftDataLimit (void); - -#ifdef __cplusplus -} -#endif - -#endif /* UTIL_H */ diff --git a/resources/3rdparty/cudd-3.0.0/Doxyfile.in b/resources/3rdparty/cudd-3.0.0/Doxyfile.in new file mode 100644 index 000000000..3c02de3f3 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/Doxyfile.in @@ -0,0 +1,2383 @@ +# Doxyfile 1.8.9.1 + +# This file describes the settings to be used by the documentation system +# doxygen (www.doxygen.org) for a project. +# +# All text after a double hash (##) is considered a comment and is placed in +# front of the TAG it is preceding. +# +# All text after a single hash (#) is considered a comment and will be ignored. +# The format is: +# TAG = value [value, ...] +# For lists, items can also be appended using: +# TAG += value [value, ...] +# Values that contain spaces should be placed between quotes (\" \"). + +#--------------------------------------------------------------------------- +# Project related configuration options +#--------------------------------------------------------------------------- + +# This tag specifies the encoding used for all characters in the config file +# that follow. The default is UTF-8 which is also the encoding used for all text +# before the first occurrence of this tag. Doxygen uses libiconv (or the iconv +# built into libc) for the transcoding. See http://www.gnu.org/software/libiconv +# for the list of possible encodings. +# The default value is: UTF-8. + +DOXYFILE_ENCODING = UTF-8 + +# The PROJECT_NAME tag is a single word (or a sequence of words surrounded by +# double-quotes, unless you are using Doxywizard) that should identify the +# project for which the documentation is generated. This name is used in the +# title of most generated pages and in a few other places. +# The default value is: My Project. + +PROJECT_NAME = @PACKAGE_NAME@ + +# The PROJECT_NUMBER tag can be used to enter a project or revision number. This +# could be handy for archiving the generated documentation or if some version +# control system is used. + +PROJECT_NUMBER = @PACKAGE_VERSION@ + +# Using the PROJECT_BRIEF tag one can provide an optional one line description +# for a project that appears at the top of each page and should give viewer a +# quick idea about the purpose of the project. Keep the description short. + +PROJECT_BRIEF = "The University of Colorado Decision Diagram Package" + +# With the PROJECT_LOGO tag one can specify a logo or an icon that is included +# in the documentation. The maximum height of the logo should not exceed 55 +# pixels and the maximum width should not exceed 200 pixels. Doxygen will copy +# the logo to the output directory. + +PROJECT_LOGO = + +# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) path +# into which the generated documentation will be written. If a relative path is +# entered, it will be relative to the location where doxygen was started. If +# left blank the current directory will be used. + +OUTPUT_DIRECTORY = + +# If the CREATE_SUBDIRS tag is set to YES then doxygen will create 4096 sub- +# directories (in 2 levels) under the output directory of each output format and +# will distribute the generated files over these directories. Enabling this +# option can be useful when feeding doxygen a huge amount of source files, where +# putting all generated files in the same directory would otherwise causes +# performance problems for the file system. +# The default value is: NO. + +CREATE_SUBDIRS = NO + +# If the ALLOW_UNICODE_NAMES tag is set to YES, doxygen will allow non-ASCII +# characters to appear in the names of generated files. If set to NO, non-ASCII +# characters will be escaped, for example _xE3_x81_x84 will be used for Unicode +# U+3044. +# The default value is: NO. + +ALLOW_UNICODE_NAMES = NO + +# The OUTPUT_LANGUAGE tag is used to specify the language in which all +# documentation generated by doxygen is written. Doxygen will use this +# information to generate all constant output in the proper language. +# Possible values are: Afrikaans, Arabic, Armenian, Brazilian, Catalan, Chinese, +# Chinese-Traditional, Croatian, Czech, Danish, Dutch, English (United States), +# Esperanto, Farsi (Persian), Finnish, French, German, Greek, Hungarian, +# Indonesian, Italian, Japanese, Japanese-en (Japanese with English messages), +# Korean, Korean-en (Korean with English messages), Latvian, Lithuanian, +# Macedonian, Norwegian, Persian (Farsi), Polish, Portuguese, Romanian, Russian, +# Serbian, Serbian-Cyrillic, Slovak, Slovene, Spanish, Swedish, Turkish, +# Ukrainian and Vietnamese. +# The default value is: English. + +OUTPUT_LANGUAGE = English + +# If the BRIEF_MEMBER_DESC tag is set to YES, doxygen will include brief member +# descriptions after the members that are listed in the file and class +# documentation (similar to Javadoc). Set to NO to disable this. +# The default value is: YES. + +BRIEF_MEMBER_DESC = YES + +# If the REPEAT_BRIEF tag is set to YES, doxygen will prepend the brief +# description of a member or function before the detailed description +# +# Note: If both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the +# brief descriptions will be completely suppressed. +# The default value is: YES. + +REPEAT_BRIEF = YES + +# This tag implements a quasi-intelligent brief description abbreviator that is +# used to form the text in various listings. Each string in this list, if found +# as the leading text of the brief description, will be stripped from the text +# and the result, after processing the whole list, is used as the annotated +# text. Otherwise, the brief description is used as-is. If left blank, the +# following values are used ($name is automatically replaced with the name of +# the entity):The $name class, The $name widget, The $name file, is, provides, +# specifies, contains, represents, a, an and the. + +ABBREVIATE_BRIEF = + +# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then +# doxygen will generate a detailed section even if there is only a brief +# description. +# The default value is: NO. + +ALWAYS_DETAILED_SEC = NO + +# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all +# inherited members of a class in the documentation of that class as if those +# members were ordinary class members. Constructors, destructors and assignment +# operators of the base classes will not be shown. +# The default value is: NO. + +INLINE_INHERITED_MEMB = NO + +# If the FULL_PATH_NAMES tag is set to YES, doxygen will prepend the full path +# before files name in the file list and in the header files. If set to NO the +# shortest path that makes the file name unique will be used +# The default value is: YES. + +FULL_PATH_NAMES = YES + +# The STRIP_FROM_PATH tag can be used to strip a user-defined part of the path. +# Stripping is only done if one of the specified strings matches the left-hand +# part of the path. The tag can be used to show relative paths in the file list. +# If left blank the directory from which doxygen is run is used as the path to +# strip. +# +# Note that you can specify absolute paths here, but also relative paths, which +# will be relative from the directory where doxygen is started. +# This tag requires that the tag FULL_PATH_NAMES is set to YES. + +STRIP_FROM_PATH = @top_srcdir@ + +# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of the +# path mentioned in the documentation of a class, which tells the reader which +# header file to include in order to use a class. If left blank only the name of +# the header file containing the class definition is used. Otherwise one should +# specify the list of include paths that are normally passed to the compiler +# using the -I flag. + +STRIP_FROM_INC_PATH = + +# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter (but +# less readable) file names. This can be useful is your file systems doesn't +# support long names like on DOS, Mac, or CD-ROM. +# The default value is: NO. + +SHORT_NAMES = NO + +# If the JAVADOC_AUTOBRIEF tag is set to YES then doxygen will interpret the +# first line (until the first dot) of a Javadoc-style comment as the brief +# description. If set to NO, the Javadoc-style will behave just like regular Qt- +# style comments (thus requiring an explicit @brief command for a brief +# description.) +# The default value is: NO. + +JAVADOC_AUTOBRIEF = NO + +# If the QT_AUTOBRIEF tag is set to YES then doxygen will interpret the first +# line (until the first dot) of a Qt-style comment as the brief description. If +# set to NO, the Qt-style will behave just like regular Qt-style comments (thus +# requiring an explicit \brief command for a brief description.) +# The default value is: NO. + +QT_AUTOBRIEF = NO + +# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make doxygen treat a +# multi-line C++ special comment block (i.e. a block of //! or /// comments) as +# a brief description. This used to be the default behavior. The new default is +# to treat a multi-line C++ comment block as a detailed description. Set this +# tag to YES if you prefer the old behavior instead. +# +# Note that setting this tag to YES also means that rational rose comments are +# not recognized any more. +# The default value is: NO. + +MULTILINE_CPP_IS_BRIEF = NO + +# If the INHERIT_DOCS tag is set to YES then an undocumented member inherits the +# documentation from any documented member that it re-implements. +# The default value is: YES. + +INHERIT_DOCS = YES + +# If the SEPARATE_MEMBER_PAGES tag is set to YES then doxygen will produce a new +# page for each member. If set to NO, the documentation of a member will be part +# of the file/class/namespace that contains it. +# The default value is: NO. + +SEPARATE_MEMBER_PAGES = NO + +# The TAB_SIZE tag can be used to set the number of spaces in a tab. Doxygen +# uses this value to replace tabs by spaces in code fragments. +# Minimum value: 1, maximum value: 16, default value: 4. + +TAB_SIZE = 4 + +# This tag can be used to specify a number of aliases that act as commands in +# the documentation. An alias has the form: +# name=value +# For example adding +# "sideeffect=@par Side effects\n" +# will allow you to put the command \sideeffect (or @sideeffect) in the +# documentation, which will result in a user-defined paragraph with heading +# "Side Effects:". You can put \n's in the value part of an alias to insert +# newlines. + +ALIASES = sideeffect="\par Side effects\n" + +# This tag can be used to specify a number of word-keyword mappings (TCL only). +# A mapping has the form "name=value". For example adding "class=itcl::class" +# will allow you to use the command class in the itcl::class meaning. + +TCL_SUBST = + +# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources +# only. Doxygen will then generate output that is more tailored for C. For +# instance, some of the names that are used will be different. The list of all +# members will be omitted, etc. +# The default value is: NO. + +OPTIMIZE_OUTPUT_FOR_C = YES + +# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java or +# Python sources only. Doxygen will then generate output that is more tailored +# for that language. For instance, namespaces will be presented as packages, +# qualified scopes will look different, etc. +# The default value is: NO. + +OPTIMIZE_OUTPUT_JAVA = NO + +# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran +# sources. Doxygen will then generate output that is tailored for Fortran. +# The default value is: NO. + +OPTIMIZE_FOR_FORTRAN = NO + +# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL +# sources. Doxygen will then generate output that is tailored for VHDL. +# The default value is: NO. + +OPTIMIZE_OUTPUT_VHDL = NO + +# Doxygen selects the parser to use depending on the extension of the files it +# parses. With this tag you can assign which parser to use for a given +# extension. Doxygen has a built-in mapping, but you can override or extend it +# using this tag. The format is ext=language, where ext is a file extension, and +# language is one of the parsers supported by doxygen: IDL, Java, Javascript, +# C#, C, C++, D, PHP, Objective-C, Python, Fortran (fixed format Fortran: +# FortranFixed, free formatted Fortran: FortranFree, unknown formatted Fortran: +# Fortran. In the later case the parser tries to guess whether the code is fixed +# or free formatted code, this is the default for Fortran type files), VHDL. For +# instance to make doxygen treat .inc files as Fortran files (default is PHP), +# and .f files as C (default is Fortran), use: inc=Fortran f=C. +# +# Note: For files without extension you can use no_extension as a placeholder. +# +# Note that for custom extensions you also need to set FILE_PATTERNS otherwise +# the files are not read by doxygen. + +EXTENSION_MAPPING = + +# If the MARKDOWN_SUPPORT tag is enabled then doxygen pre-processes all comments +# according to the Markdown format, which allows for more readable +# documentation. See http://daringfireball.net/projects/markdown/ for details. +# The output of markdown processing is further processed by doxygen, so you can +# mix doxygen, HTML, and XML commands with Markdown formatting. Disable only in +# case of backward compatibilities issues. +# The default value is: YES. + +MARKDOWN_SUPPORT = YES + +# When enabled doxygen tries to link words that correspond to documented +# classes, or namespaces to their corresponding documentation. Such a link can +# be prevented in individual cases by putting a % sign in front of the word or +# globally by setting AUTOLINK_SUPPORT to NO. +# The default value is: YES. + +AUTOLINK_SUPPORT = YES + +# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want +# to include (a tag file for) the STL sources as input, then you should set this +# tag to YES in order to let doxygen match functions declarations and +# definitions whose arguments contain STL classes (e.g. func(std::string); +# versus func(std::string) {}). This also make the inheritance and collaboration +# diagrams that involve STL classes more complete and accurate. +# The default value is: NO. + +BUILTIN_STL_SUPPORT = NO + +# If you use Microsoft's C++/CLI language, you should set this option to YES to +# enable parsing support. +# The default value is: NO. + +CPP_CLI_SUPPORT = NO + +# Set the SIP_SUPPORT tag to YES if your project consists of sip (see: +# http://www.riverbankcomputing.co.uk/software/sip/intro) sources only. Doxygen +# will parse them like normal C++ but will assume all classes use public instead +# of private inheritance when no explicit protection keyword is present. +# The default value is: NO. + +SIP_SUPPORT = NO + +# For Microsoft's IDL there are propget and propput attributes to indicate +# getter and setter methods for a property. Setting this option to YES will make +# doxygen to replace the get and set methods by a property in the documentation. +# This will only work if the methods are indeed getting or setting a simple +# type. If this is not the case, or you want to show the methods anyway, you +# should set this option to NO. +# The default value is: YES. + +IDL_PROPERTY_SUPPORT = YES + +# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC +# tag is set to YES then doxygen will reuse the documentation of the first +# member in the group (if any) for the other members of the group. By default +# all members of a group must be documented explicitly. +# The default value is: NO. + +DISTRIBUTE_GROUP_DOC = NO + +# Set the SUBGROUPING tag to YES to allow class member groups of the same type +# (for instance a group of public functions) to be put as a subgroup of that +# type (e.g. under the Public Functions section). Set it to NO to prevent +# subgrouping. Alternatively, this can be done per class using the +# \nosubgrouping command. +# The default value is: YES. + +SUBGROUPING = YES + +# When the INLINE_GROUPED_CLASSES tag is set to YES, classes, structs and unions +# are shown inside the group in which they are included (e.g. using \ingroup) +# instead of on a separate page (for HTML and Man pages) or section (for LaTeX +# and RTF). +# +# Note that this feature does not work in combination with +# SEPARATE_MEMBER_PAGES. +# The default value is: NO. + +INLINE_GROUPED_CLASSES = NO + +# When the INLINE_SIMPLE_STRUCTS tag is set to YES, structs, classes, and unions +# with only public data fields or simple typedef fields will be shown inline in +# the documentation of the scope in which they are defined (i.e. file, +# namespace, or group documentation), provided this scope is documented. If set +# to NO, structs, classes, and unions are shown on a separate page (for HTML and +# Man pages) or section (for LaTeX and RTF). +# The default value is: NO. + +INLINE_SIMPLE_STRUCTS = NO + +# When TYPEDEF_HIDES_STRUCT tag is enabled, a typedef of a struct, union, or +# enum is documented as struct, union, or enum with the name of the typedef. So +# typedef struct TypeS {} TypeT, will appear in the documentation as a struct +# with name TypeT. When disabled the typedef will appear as a member of a file, +# namespace, or class. And the struct will be named TypeS. This can typically be +# useful for C code in case the coding convention dictates that all compound +# types are typedef'ed and only the typedef is referenced, never the tag name. +# The default value is: NO. + +TYPEDEF_HIDES_STRUCT = NO + +# The size of the symbol lookup cache can be set using LOOKUP_CACHE_SIZE. This +# cache is used to resolve symbols given their name and scope. Since this can be +# an expensive process and often the same symbol appears multiple times in the +# code, doxygen keeps a cache of pre-resolved symbols. If the cache is too small +# doxygen will become slower. If the cache is too large, memory is wasted. The +# cache size is given by this formula: 2^(16+LOOKUP_CACHE_SIZE). The valid range +# is 0..9, the default is 0, corresponding to a cache size of 2^16=65536 +# symbols. At the end of a run doxygen will report the cache usage and suggest +# the optimal cache size from a speed point of view. +# Minimum value: 0, maximum value: 9, default value: 0. + +LOOKUP_CACHE_SIZE = 0 + +#--------------------------------------------------------------------------- +# Build related configuration options +#--------------------------------------------------------------------------- + +# If the EXTRACT_ALL tag is set to YES, doxygen will assume all entities in +# documentation are documented, even if no documentation was available. Private +# class members and static file members will be hidden unless the +# EXTRACT_PRIVATE respectively EXTRACT_STATIC tags are set to YES. +# Note: This will also disable the warnings about undocumented members that are +# normally produced when WARNINGS is set to YES. +# The default value is: NO. + +EXTRACT_ALL = NO + +# If the EXTRACT_PRIVATE tag is set to YES, all private members of a class will +# be included in the documentation. +# The default value is: NO. + +EXTRACT_PRIVATE = NO + +# If the EXTRACT_PACKAGE tag is set to YES, all members with package or internal +# scope will be included in the documentation. +# The default value is: NO. + +EXTRACT_PACKAGE = NO + +# If the EXTRACT_STATIC tag is set to YES, all static members of a file will be +# included in the documentation. +# The default value is: NO. + +EXTRACT_STATIC = YES + +# If the EXTRACT_LOCAL_CLASSES tag is set to YES, classes (and structs) defined +# locally in source files will be included in the documentation. If set to NO, +# only classes defined in header files are included. Does not have any effect +# for Java sources. +# The default value is: YES. + +EXTRACT_LOCAL_CLASSES = YES + +# This flag is only useful for Objective-C code. If set to YES, local methods, +# which are defined in the implementation section but not in the interface are +# included in the documentation. If set to NO, only methods in the interface are +# included. +# The default value is: NO. + +EXTRACT_LOCAL_METHODS = NO + +# If this flag is set to YES, the members of anonymous namespaces will be +# extracted and appear in the documentation as a namespace called +# 'anonymous_namespace{file}', where file will be replaced with the base name of +# the file that contains the anonymous namespace. By default anonymous namespace +# are hidden. +# The default value is: NO. + +EXTRACT_ANON_NSPACES = NO + +# If the HIDE_UNDOC_MEMBERS tag is set to YES, doxygen will hide all +# undocumented members inside documented classes or files. If set to NO these +# members will be included in the various overviews, but no documentation +# section is generated. This option has no effect if EXTRACT_ALL is enabled. +# The default value is: NO. + +HIDE_UNDOC_MEMBERS = NO + +# If the HIDE_UNDOC_CLASSES tag is set to YES, doxygen will hide all +# undocumented classes that are normally visible in the class hierarchy. If set +# to NO, these classes will be included in the various overviews. This option +# has no effect if EXTRACT_ALL is enabled. +# The default value is: NO. + +HIDE_UNDOC_CLASSES = NO + +# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, doxygen will hide all friend +# (class|struct|union) declarations. If set to NO, these declarations will be +# included in the documentation. +# The default value is: NO. + +HIDE_FRIEND_COMPOUNDS = NO + +# If the HIDE_IN_BODY_DOCS tag is set to YES, doxygen will hide any +# documentation blocks found inside the body of a function. If set to NO, these +# blocks will be appended to the function's detailed documentation block. +# The default value is: NO. + +HIDE_IN_BODY_DOCS = NO + +# The INTERNAL_DOCS tag determines if documentation that is typed after a +# \internal command is included. If the tag is set to NO then the documentation +# will be excluded. Set it to YES to include the internal documentation. +# The default value is: NO. + +INTERNAL_DOCS = NO + +# If the CASE_SENSE_NAMES tag is set to NO then doxygen will only generate file +# names in lower-case letters. If set to YES, upper-case letters are also +# allowed. This is useful if you have classes or files whose names only differ +# in case and if your file system supports case sensitive file names. Windows +# and Mac users are advised to set this option to NO. +# The default value is: system dependent. + +CASE_SENSE_NAMES = YES + +# If the HIDE_SCOPE_NAMES tag is set to NO then doxygen will show members with +# their full class and namespace scopes in the documentation. If set to YES, the +# scope will be hidden. +# The default value is: NO. + +HIDE_SCOPE_NAMES = NO + +# If the HIDE_COMPOUND_REFERENCE tag is set to NO (default) then doxygen will +# append additional text to a page's title, such as Class Reference. If set to +# YES the compound reference will be hidden. +# The default value is: NO. + +HIDE_COMPOUND_REFERENCE= NO + +# If the SHOW_INCLUDE_FILES tag is set to YES then doxygen will put a list of +# the files that are included by a file in the documentation of that file. +# The default value is: YES. + +SHOW_INCLUDE_FILES = YES + +# If the SHOW_GROUPED_MEMB_INC tag is set to YES then Doxygen will add for each +# grouped member an include statement to the documentation, telling the reader +# which file to include in order to use the member. +# The default value is: NO. + +SHOW_GROUPED_MEMB_INC = NO + +# If the FORCE_LOCAL_INCLUDES tag is set to YES then doxygen will list include +# files with double quotes in the documentation rather than with sharp brackets. +# The default value is: NO. + +FORCE_LOCAL_INCLUDES = NO + +# If the INLINE_INFO tag is set to YES then a tag [inline] is inserted in the +# documentation for inline members. +# The default value is: YES. + +INLINE_INFO = YES + +# If the SORT_MEMBER_DOCS tag is set to YES then doxygen will sort the +# (detailed) documentation of file and class members alphabetically by member +# name. If set to NO, the members will appear in declaration order. +# The default value is: YES. + +SORT_MEMBER_DOCS = YES + +# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the brief +# descriptions of file, namespace and class members alphabetically by member +# name. If set to NO, the members will appear in declaration order. Note that +# this will also influence the order of the classes in the class list. +# The default value is: NO. + +SORT_BRIEF_DOCS = NO + +# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen will sort the +# (brief and detailed) documentation of class members so that constructors and +# destructors are listed first. If set to NO the constructors will appear in the +# respective orders defined by SORT_BRIEF_DOCS and SORT_MEMBER_DOCS. +# Note: If SORT_BRIEF_DOCS is set to NO this option is ignored for sorting brief +# member documentation. +# Note: If SORT_MEMBER_DOCS is set to NO this option is ignored for sorting +# detailed member documentation. +# The default value is: NO. + +SORT_MEMBERS_CTORS_1ST = NO + +# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the hierarchy +# of group names into alphabetical order. If set to NO the group names will +# appear in their defined order. +# The default value is: NO. + +SORT_GROUP_NAMES = NO + +# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be sorted by +# fully-qualified names, including namespaces. If set to NO, the class list will +# be sorted only by class name, not including the namespace part. +# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. +# Note: This option applies only to the class list, not to the alphabetical +# list. +# The default value is: NO. + +SORT_BY_SCOPE_NAME = NO + +# If the STRICT_PROTO_MATCHING option is enabled and doxygen fails to do proper +# type resolution of all parameters of a function it will reject a match between +# the prototype and the implementation of a member function even if there is +# only one candidate or it is obvious which candidate to choose by doing a +# simple string match. By disabling STRICT_PROTO_MATCHING doxygen will still +# accept a match between prototype and implementation in such cases. +# The default value is: NO. + +STRICT_PROTO_MATCHING = NO + +# The GENERATE_TODOLIST tag can be used to enable (YES) or disable (NO) the todo +# list. This list is created by putting \todo commands in the documentation. +# The default value is: YES. + +GENERATE_TODOLIST = YES + +# The GENERATE_TESTLIST tag can be used to enable (YES) or disable (NO) the test +# list. This list is created by putting \test commands in the documentation. +# The default value is: YES. + +GENERATE_TESTLIST = YES + +# The GENERATE_BUGLIST tag can be used to enable (YES) or disable (NO) the bug +# list. This list is created by putting \bug commands in the documentation. +# The default value is: YES. + +GENERATE_BUGLIST = YES + +# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or disable (NO) +# the deprecated list. This list is created by putting \deprecated commands in +# the documentation. +# The default value is: YES. + +GENERATE_DEPRECATEDLIST= YES + +# The ENABLED_SECTIONS tag can be used to enable conditional documentation +# sections, marked by \if <section_label> ... \endif and \cond <section_label> +# ... \endcond blocks. + +ENABLED_SECTIONS = + +# The MAX_INITIALIZER_LINES tag determines the maximum number of lines that the +# initial value of a variable or macro / define can have for it to appear in the +# documentation. If the initializer consists of more lines than specified here +# it will be hidden. Use a value of 0 to hide initializers completely. The +# appearance of the value of individual variables and macros / defines can be +# controlled using \showinitializer or \hideinitializer command in the +# documentation regardless of this setting. +# Minimum value: 0, maximum value: 10000, default value: 30. + +MAX_INITIALIZER_LINES = 30 + +# Set the SHOW_USED_FILES tag to NO to disable the list of files generated at +# the bottom of the documentation of classes and structs. If set to YES, the +# list will mention the files that were used to generate the documentation. +# The default value is: YES. + +SHOW_USED_FILES = YES + +# Set the SHOW_FILES tag to NO to disable the generation of the Files page. This +# will remove the Files entry from the Quick Index and from the Folder Tree View +# (if specified). +# The default value is: YES. + +SHOW_FILES = YES + +# Set the SHOW_NAMESPACES tag to NO to disable the generation of the Namespaces +# page. This will remove the Namespaces entry from the Quick Index and from the +# Folder Tree View (if specified). +# The default value is: YES. + +SHOW_NAMESPACES = YES + +# The FILE_VERSION_FILTER tag can be used to specify a program or script that +# doxygen should invoke to get the current version for each file (typically from +# the version control system). Doxygen will invoke the program by executing (via +# popen()) the command command input-file, where command is the value of the +# FILE_VERSION_FILTER tag, and input-file is the name of an input file provided +# by doxygen. Whatever the program writes to standard output is used as the file +# version. For an example see the documentation. + +FILE_VERSION_FILTER = + +# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed +# by doxygen. The layout file controls the global structure of the generated +# output files in an output format independent way. To create the layout file +# that represents doxygen's defaults, run doxygen with the -l option. You can +# optionally specify a file name after the option, if omitted DoxygenLayout.xml +# will be used as the name of the layout file. +# +# Note that if you run doxygen from a directory containing a file called +# DoxygenLayout.xml, doxygen will parse it automatically even if the LAYOUT_FILE +# tag is left empty. + +LAYOUT_FILE = + +# The CITE_BIB_FILES tag can be used to specify one or more bib files containing +# the reference definitions. This must be a list of .bib files. The .bib +# extension is automatically appended if omitted. This requires the bibtex tool +# to be installed. See also http://en.wikipedia.org/wiki/BibTeX for more info. +# For LaTeX the style of the bibliography can be controlled using +# LATEX_BIB_STYLE. To use this feature you need bibtex and perl available in the +# search path. See also \cite for info how to create references. + +CITE_BIB_FILES = + +#--------------------------------------------------------------------------- +# Configuration options related to warning and progress messages +#--------------------------------------------------------------------------- + +# The QUIET tag can be used to turn on/off the messages that are generated to +# standard output by doxygen. If QUIET is set to YES this implies that the +# messages are off. +# The default value is: NO. + +QUIET = NO + +# The WARNINGS tag can be used to turn on/off the warning messages that are +# generated to standard error (stderr) by doxygen. If WARNINGS is set to YES +# this implies that the warnings are on. +# +# Tip: Turn warnings on while writing the documentation. +# The default value is: YES. + +WARNINGS = YES + +# If the WARN_IF_UNDOCUMENTED tag is set to YES then doxygen will generate +# warnings for undocumented members. If EXTRACT_ALL is set to YES then this flag +# will automatically be disabled. +# The default value is: YES. + +WARN_IF_UNDOCUMENTED = YES + +# If the WARN_IF_DOC_ERROR tag is set to YES, doxygen will generate warnings for +# potential errors in the documentation, such as not documenting some parameters +# in a documented function, or documenting parameters that don't exist or using +# markup commands wrongly. +# The default value is: YES. + +WARN_IF_DOC_ERROR = YES + +# This WARN_NO_PARAMDOC option can be enabled to get warnings for functions that +# are documented, but have no documentation for their parameters or return +# value. If set to NO, doxygen will only warn about wrong or incomplete +# parameter documentation, but not about the absence of documentation. +# The default value is: NO. + +WARN_NO_PARAMDOC = NO + +# The WARN_FORMAT tag determines the format of the warning messages that doxygen +# can produce. The string should contain the $file, $line, and $text tags, which +# will be replaced by the file and line number from which the warning originated +# and the warning text. Optionally the format may contain $version, which will +# be replaced by the version of the file (if it could be obtained via +# FILE_VERSION_FILTER) +# The default value is: $file:$line: $text. + +WARN_FORMAT = "$file:$line: $text" + +# The WARN_LOGFILE tag can be used to specify a file to which warning and error +# messages should be written. If left blank the output is written to standard +# error (stderr). + +WARN_LOGFILE = + +#--------------------------------------------------------------------------- +# Configuration options related to the input files +#--------------------------------------------------------------------------- + +# The INPUT tag is used to specify the files and/or directories that contain +# documented source files. You may enter file names like myfile.cpp or +# directories like /usr/src/myproject. Separate the files or directories with +# spaces. +# Note: If this tag is empty the current directory is searched. + +INPUT = @top_srcdir@ @top_srcdir@/cudd @top_srcdir@/mtr @top_srcdir@/epd @top_srcdir@/st @top_srcdir@/util @top_srcdir@/cplusplus @top_srcdir@/nanotrav + +# This tag can be used to specify the character encoding of the source files +# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses +# libiconv (or the iconv built into libc) for the transcoding. See the libiconv +# documentation (see: http://www.gnu.org/software/libiconv) for the list of +# possible encodings. +# The default value is: UTF-8. + +INPUT_ENCODING = UTF-8 + +# If the value of the INPUT tag contains directories, you can use the +# FILE_PATTERNS tag to specify one or more wildcard patterns (like *.cpp and +# *.h) to filter out the source-files in the directories. If left blank the +# following patterns are tested:*.c, *.cc, *.cxx, *.cpp, *.c++, *.java, *.ii, +# *.ixx, *.ipp, *.i++, *.inl, *.idl, *.ddl, *.odl, *.h, *.hh, *.hxx, *.hpp, +# *.h++, *.cs, *.d, *.php, *.php4, *.php5, *.phtml, *.inc, *.m, *.markdown, +# *.md, *.mm, *.dox, *.py, *.f90, *.f, *.for, *.tcl, *.vhd, *.vhdl, *.ucf, +# *.qsf, *.as and *.js. + +FILE_PATTERNS = + +# The RECURSIVE tag can be used to specify whether or not subdirectories should +# be searched for input files as well. +# The default value is: NO. + +RECURSIVE = NO + +# The EXCLUDE tag can be used to specify files and/or directories that should be +# excluded from the INPUT source files. This way you can easily exclude a +# subdirectory from a directory tree whose root is specified with the INPUT tag. +# +# Note that relative paths are relative to the directory from which doxygen is +# run. + +EXCLUDE = config.h + +# The EXCLUDE_SYMLINKS tag can be used to select whether or not files or +# directories that are symbolic links (a Unix file system feature) are excluded +# from the input. +# The default value is: NO. + +EXCLUDE_SYMLINKS = NO + +# If the value of the INPUT tag contains directories, you can use the +# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude +# certain files from those directories. +# +# Note that the wildcards are matched against the file with absolute path, so to +# exclude all test directories for example use the pattern */test/* + +EXCLUDE_PATTERNS = + +# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names +# (namespaces, classes, functions, etc.) that should be excluded from the +# output. The symbol name can be a fully qualified name, a word, or if the +# wildcard * is used, a substring. Examples: ANamespace, AClass, +# AClass::ANamespace, ANamespace::*Test +# +# Note that the wildcards are matched against the file with absolute path, so to +# exclude all test directories use the pattern */test/* + +EXCLUDE_SYMBOLS = + +# The EXAMPLE_PATH tag can be used to specify one or more files or directories +# that contain example code fragments that are included (see the \include +# command). + +EXAMPLE_PATH = + +# If the value of the EXAMPLE_PATH tag contains directories, you can use the +# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp and +# *.h) to filter out the source-files in the directories. If left blank all +# files are included. + +EXAMPLE_PATTERNS = + +# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be +# searched for input files to be used with the \include or \dontinclude commands +# irrespective of the value of the RECURSIVE tag. +# The default value is: NO. + +EXAMPLE_RECURSIVE = NO + +# The IMAGE_PATH tag can be used to specify one or more files or directories +# that contain images that are to be included in the documentation (see the +# \image command). + +IMAGE_PATH = + +# The INPUT_FILTER tag can be used to specify a program that doxygen should +# invoke to filter for each input file. Doxygen will invoke the filter program +# by executing (via popen()) the command: +# +# <filter> <input-file> +# +# where <filter> is the value of the INPUT_FILTER tag, and <input-file> is the +# name of an input file. Doxygen will then use the output that the filter +# program writes to standard output. If FILTER_PATTERNS is specified, this tag +# will be ignored. +# +# Note that the filter must not add or remove lines; it is applied before the +# code is scanned, but not when the output code is generated. If lines are added +# or removed, the anchors will not be placed correctly. + +INPUT_FILTER = + +# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern +# basis. Doxygen will compare the file name with each pattern and apply the +# filter if there is a match. The filters are a list of the form: pattern=filter +# (like *.cpp=my_cpp_filter). See INPUT_FILTER for further information on how +# filters are used. If the FILTER_PATTERNS tag is empty or if none of the +# patterns match the file name, INPUT_FILTER is applied. + +FILTER_PATTERNS = + +# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using +# INPUT_FILTER) will also be used to filter the input files that are used for +# producing the source files to browse (i.e. when SOURCE_BROWSER is set to YES). +# The default value is: NO. + +FILTER_SOURCE_FILES = NO + +# The FILTER_SOURCE_PATTERNS tag can be used to specify source filters per file +# pattern. A pattern will override the setting for FILTER_PATTERN (if any) and +# it is also possible to disable source filtering for a specific pattern using +# *.ext= (so without naming a filter). +# This tag requires that the tag FILTER_SOURCE_FILES is set to YES. + +FILTER_SOURCE_PATTERNS = + +# If the USE_MDFILE_AS_MAINPAGE tag refers to the name of a markdown file that +# is part of the input, its contents will be placed on the main page +# (index.html). This can be useful if you have a project on for instance GitHub +# and want to reuse the introduction page also for the doxygen output. + +USE_MDFILE_AS_MAINPAGE = + +#--------------------------------------------------------------------------- +# Configuration options related to source browsing +#--------------------------------------------------------------------------- + +# If the SOURCE_BROWSER tag is set to YES then a list of source files will be +# generated. Documented entities will be cross-referenced with these sources. +# +# Note: To get rid of all source code in the generated output, make sure that +# also VERBATIM_HEADERS is set to NO. +# The default value is: NO. + +SOURCE_BROWSER = NO + +# Setting the INLINE_SOURCES tag to YES will include the body of functions, +# classes and enums directly into the documentation. +# The default value is: NO. + +INLINE_SOURCES = NO + +# Setting the STRIP_CODE_COMMENTS tag to YES will instruct doxygen to hide any +# special comment blocks from generated source code fragments. Normal C, C++ and +# Fortran comments will always remain visible. +# The default value is: YES. + +STRIP_CODE_COMMENTS = YES + +# If the REFERENCED_BY_RELATION tag is set to YES then for each documented +# function all documented functions referencing it will be listed. +# The default value is: NO. + +REFERENCED_BY_RELATION = NO + +# If the REFERENCES_RELATION tag is set to YES then for each documented function +# all documented entities called/used by that function will be listed. +# The default value is: NO. + +REFERENCES_RELATION = NO + +# If the REFERENCES_LINK_SOURCE tag is set to YES and SOURCE_BROWSER tag is set +# to YES then the hyperlinks from functions in REFERENCES_RELATION and +# REFERENCED_BY_RELATION lists will link to the source code. Otherwise they will +# link to the documentation. +# The default value is: YES. + +REFERENCES_LINK_SOURCE = YES + +# If SOURCE_TOOLTIPS is enabled (the default) then hovering a hyperlink in the +# source code will show a tooltip with additional information such as prototype, +# brief description and links to the definition and documentation. Since this +# will make the HTML file larger and loading of large files a bit slower, you +# can opt to disable this feature. +# The default value is: YES. +# This tag requires that the tag SOURCE_BROWSER is set to YES. + +SOURCE_TOOLTIPS = YES + +# If the USE_HTAGS tag is set to YES then the references to source code will +# point to the HTML generated by the htags(1) tool instead of doxygen built-in +# source browser. The htags tool is part of GNU's global source tagging system +# (see http://www.gnu.org/software/global/global.html). You will need version +# 4.8.6 or higher. +# +# To use it do the following: +# - Install the latest version of global +# - Enable SOURCE_BROWSER and USE_HTAGS in the config file +# - Make sure the INPUT points to the root of the source tree +# - Run doxygen as normal +# +# Doxygen will invoke htags (and that will in turn invoke gtags), so these +# tools must be available from the command line (i.e. in the search path). +# +# The result: instead of the source browser generated by doxygen, the links to +# source code will now point to the output of htags. +# The default value is: NO. +# This tag requires that the tag SOURCE_BROWSER is set to YES. + +USE_HTAGS = NO + +# If the VERBATIM_HEADERS tag is set the YES then doxygen will generate a +# verbatim copy of the header file for each class for which an include is +# specified. Set to NO to disable this. +# See also: Section \class. +# The default value is: YES. + +VERBATIM_HEADERS = YES + +# If the CLANG_ASSISTED_PARSING tag is set to YES then doxygen will use the +# clang parser (see: http://clang.llvm.org/) for more accurate parsing at the +# cost of reduced performance. This can be particularly helpful with template +# rich C++ code for which doxygen's built-in parser lacks the necessary type +# information. +# Note: The availability of this option depends on whether or not doxygen was +# compiled with the --with-libclang option. +# The default value is: NO. + +CLANG_ASSISTED_PARSING = NO + +# If clang assisted parsing is enabled you can provide the compiler with command +# line options that you would normally use when invoking the compiler. Note that +# the include paths will already be set by doxygen for the files and directories +# specified with INPUT and INCLUDE_PATH. +# This tag requires that the tag CLANG_ASSISTED_PARSING is set to YES. + +CLANG_OPTIONS = + +#--------------------------------------------------------------------------- +# Configuration options related to the alphabetical class index +#--------------------------------------------------------------------------- + +# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index of all +# compounds will be generated. Enable this if the project contains a lot of +# classes, structs, unions or interfaces. +# The default value is: YES. + +ALPHABETICAL_INDEX = YES + +# The COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns in +# which the alphabetical index list will be split. +# Minimum value: 1, maximum value: 20, default value: 5. +# This tag requires that the tag ALPHABETICAL_INDEX is set to YES. + +COLS_IN_ALPHA_INDEX = 5 + +# In case all classes in a project start with a common prefix, all classes will +# be put under the same header in the alphabetical index. The IGNORE_PREFIX tag +# can be used to specify a prefix (or a list of prefixes) that should be ignored +# while generating the index headers. +# This tag requires that the tag ALPHABETICAL_INDEX is set to YES. + +IGNORE_PREFIX = + +#--------------------------------------------------------------------------- +# Configuration options related to the HTML output +#--------------------------------------------------------------------------- + +# If the GENERATE_HTML tag is set to YES, doxygen will generate HTML output +# The default value is: YES. + +GENERATE_HTML = YES + +# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. If a +# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of +# it. +# The default directory is: html. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_OUTPUT = html + +# The HTML_FILE_EXTENSION tag can be used to specify the file extension for each +# generated HTML page (for example: .htm, .php, .asp). +# The default value is: .html. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_FILE_EXTENSION = .html + +# The HTML_HEADER tag can be used to specify a user-defined HTML header file for +# each generated HTML page. If the tag is left blank doxygen will generate a +# standard header. +# +# To get valid HTML the header file that includes any scripts and style sheets +# that doxygen needs, which is dependent on the configuration options used (e.g. +# the setting GENERATE_TREEVIEW). It is highly recommended to start with a +# default header using +# doxygen -w html new_header.html new_footer.html new_stylesheet.css +# YourConfigFile +# and then modify the file new_header.html. See also section "Doxygen usage" +# for information on how to generate the default header that doxygen normally +# uses. +# Note: The header is subject to change so you typically have to regenerate the +# default header when upgrading to a newer version of doxygen. For a description +# of the possible markers and block names see the documentation. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_HEADER = + +# The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each +# generated HTML page. If the tag is left blank doxygen will generate a standard +# footer. See HTML_HEADER for more information on how to generate a default +# footer and what special commands can be used inside the footer. See also +# section "Doxygen usage" for information on how to generate the default footer +# that doxygen normally uses. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_FOOTER = + +# The HTML_STYLESHEET tag can be used to specify a user-defined cascading style +# sheet that is used by each HTML page. It can be used to fine-tune the look of +# the HTML output. If left blank doxygen will generate a default style sheet. +# See also section "Doxygen usage" for information on how to generate the style +# sheet that doxygen normally uses. +# Note: It is recommended to use HTML_EXTRA_STYLESHEET instead of this tag, as +# it is more robust and this tag (HTML_STYLESHEET) will in the future become +# obsolete. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_STYLESHEET = + +# The HTML_EXTRA_STYLESHEET tag can be used to specify additional user-defined +# cascading style sheets that are included after the standard style sheets +# created by doxygen. Using this option one can overrule certain style aspects. +# This is preferred over using HTML_STYLESHEET since it does not replace the +# standard style sheet and is therefore more robust against future updates. +# Doxygen will copy the style sheet files to the output directory. +# Note: The order of the extra style sheet files is of importance (e.g. the last +# style sheet in the list overrules the setting of the previous ones in the +# list). For an example see the documentation. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_EXTRA_STYLESHEET = + +# The HTML_EXTRA_FILES tag can be used to specify one or more extra images or +# other source files which should be copied to the HTML output directory. Note +# that these files will be copied to the base HTML output directory. Use the +# $relpath^ marker in the HTML_HEADER and/or HTML_FOOTER files to load these +# files. In the HTML_STYLESHEET file, use the file name only. Also note that the +# files will be copied as-is; there are no commands or markers available. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_EXTRA_FILES = + +# The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. Doxygen +# will adjust the colors in the style sheet and background images according to +# this color. Hue is specified as an angle on a colorwheel, see +# http://en.wikipedia.org/wiki/Hue for more information. For instance the value +# 0 represents red, 60 is yellow, 120 is green, 180 is cyan, 240 is blue, 300 +# purple, and 360 is red again. +# Minimum value: 0, maximum value: 359, default value: 220. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_COLORSTYLE_HUE = 220 + +# The HTML_COLORSTYLE_SAT tag controls the purity (or saturation) of the colors +# in the HTML output. For a value of 0 the output will use grayscales only. A +# value of 255 will produce the most vivid colors. +# Minimum value: 0, maximum value: 255, default value: 100. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_COLORSTYLE_SAT = 100 + +# The HTML_COLORSTYLE_GAMMA tag controls the gamma correction applied to the +# luminance component of the colors in the HTML output. Values below 100 +# gradually make the output lighter, whereas values above 100 make the output +# darker. The value divided by 100 is the actual gamma applied, so 80 represents +# a gamma of 0.8, The value 220 represents a gamma of 2.2, and 100 does not +# change the gamma. +# Minimum value: 40, maximum value: 240, default value: 80. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_COLORSTYLE_GAMMA = 80 + +# If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML +# page will contain the date and time when the page was generated. Setting this +# to NO can help when comparing the output of multiple runs. +# The default value is: YES. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_TIMESTAMP = YES + +# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML +# documentation will contain sections that can be hidden and shown after the +# page has loaded. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_DYNAMIC_SECTIONS = NO + +# With HTML_INDEX_NUM_ENTRIES one can control the preferred number of entries +# shown in the various tree structured indices initially; the user can expand +# and collapse entries dynamically later on. Doxygen will expand the tree to +# such a level that at most the specified number of entries are visible (unless +# a fully collapsed tree already exceeds this amount). So setting the number of +# entries 1 will produce a full collapsed tree by default. 0 is a special value +# representing an infinite number of entries and will result in a full expanded +# tree by default. +# Minimum value: 0, maximum value: 9999, default value: 100. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_INDEX_NUM_ENTRIES = 100 + +# If the GENERATE_DOCSET tag is set to YES, additional index files will be +# generated that can be used as input for Apple's Xcode 3 integrated development +# environment (see: http://developer.apple.com/tools/xcode/), introduced with +# OSX 10.5 (Leopard). To create a documentation set, doxygen will generate a +# Makefile in the HTML output directory. Running make will produce the docset in +# that directory and running make install will install the docset in +# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find it at +# startup. See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html +# for more information. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_DOCSET = NO + +# This tag determines the name of the docset feed. A documentation feed provides +# an umbrella under which multiple documentation sets from a single provider +# (such as a company or product suite) can be grouped. +# The default value is: Doxygen generated docs. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_FEEDNAME = "Doxygen generated docs" + +# This tag specifies a string that should uniquely identify the documentation +# set bundle. This should be a reverse domain-name style string, e.g. +# com.mycompany.MyDocSet. Doxygen will append .docset to the name. +# The default value is: org.doxygen.Project. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_BUNDLE_ID = org.doxygen.Project + +# The DOCSET_PUBLISHER_ID tag specifies a string that should uniquely identify +# the documentation publisher. This should be a reverse domain-name style +# string, e.g. com.mycompany.MyDocSet.documentation. +# The default value is: org.doxygen.Publisher. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_PUBLISHER_ID = org.doxygen.Publisher + +# The DOCSET_PUBLISHER_NAME tag identifies the documentation publisher. +# The default value is: Publisher. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_PUBLISHER_NAME = Publisher + +# If the GENERATE_HTMLHELP tag is set to YES then doxygen generates three +# additional HTML index files: index.hhp, index.hhc, and index.hhk. The +# index.hhp is a project file that can be read by Microsoft's HTML Help Workshop +# (see: http://www.microsoft.com/en-us/download/details.aspx?id=21138) on +# Windows. +# +# The HTML Help Workshop contains a compiler that can convert all HTML output +# generated by doxygen into a single compiled HTML file (.chm). Compiled HTML +# files are now used as the Windows 98 help format, and will replace the old +# Windows help format (.hlp) on all Windows platforms in the future. Compressed +# HTML files also contain an index, a table of contents, and you can search for +# words in the documentation. The HTML workshop also contains a viewer for +# compressed HTML files. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_HTMLHELP = NO + +# The CHM_FILE tag can be used to specify the file name of the resulting .chm +# file. You can add a path in front of the file if the result should not be +# written to the html output directory. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +CHM_FILE = + +# The HHC_LOCATION tag can be used to specify the location (absolute path +# including file name) of the HTML help compiler (hhc.exe). If non-empty, +# doxygen will try to run the HTML help compiler on the generated index.hhp. +# The file has to be specified with full path. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +HHC_LOCATION = + +# The GENERATE_CHI flag controls if a separate .chi index file is generated +# (YES) or that it should be included in the master .chm file (NO). +# The default value is: NO. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +GENERATE_CHI = NO + +# The CHM_INDEX_ENCODING is used to encode HtmlHelp index (hhk), content (hhc) +# and project file content. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +CHM_INDEX_ENCODING = + +# The BINARY_TOC flag controls whether a binary table of contents is generated +# (YES) or a normal table of contents (NO) in the .chm file. Furthermore it +# enables the Previous and Next buttons. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +BINARY_TOC = NO + +# The TOC_EXPAND flag can be set to YES to add extra items for group members to +# the table of contents of the HTML help documentation and to the tree view. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +TOC_EXPAND = NO + +# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and +# QHP_VIRTUAL_FOLDER are set, an additional index file will be generated that +# can be used as input for Qt's qhelpgenerator to generate a Qt Compressed Help +# (.qch) of the generated HTML documentation. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_QHP = NO + +# If the QHG_LOCATION tag is specified, the QCH_FILE tag can be used to specify +# the file name of the resulting .qch file. The path specified is relative to +# the HTML output folder. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QCH_FILE = + +# The QHP_NAMESPACE tag specifies the namespace to use when generating Qt Help +# Project output. For more information please see Qt Help Project / Namespace +# (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#namespace). +# The default value is: org.doxygen.Project. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_NAMESPACE = org.doxygen.Project + +# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating Qt +# Help Project output. For more information please see Qt Help Project / Virtual +# Folders (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#virtual- +# folders). +# The default value is: doc. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_VIRTUAL_FOLDER = doc + +# If the QHP_CUST_FILTER_NAME tag is set, it specifies the name of a custom +# filter to add. For more information please see Qt Help Project / Custom +# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- +# filters). +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_CUST_FILTER_NAME = + +# The QHP_CUST_FILTER_ATTRS tag specifies the list of the attributes of the +# custom filter to add. For more information please see Qt Help Project / Custom +# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- +# filters). +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_CUST_FILTER_ATTRS = + +# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this +# project's filter section matches. Qt Help Project / Filter Attributes (see: +# http://qt-project.org/doc/qt-4.8/qthelpproject.html#filter-attributes). +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_SECT_FILTER_ATTRS = + +# The QHG_LOCATION tag can be used to specify the location of Qt's +# qhelpgenerator. If non-empty doxygen will try to run qhelpgenerator on the +# generated .qhp file. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHG_LOCATION = + +# If the GENERATE_ECLIPSEHELP tag is set to YES, additional index files will be +# generated, together with the HTML files, they form an Eclipse help plugin. To +# install this plugin and make it available under the help contents menu in +# Eclipse, the contents of the directory containing the HTML and XML files needs +# to be copied into the plugins directory of eclipse. The name of the directory +# within the plugins directory should be the same as the ECLIPSE_DOC_ID value. +# After copying Eclipse needs to be restarted before the help appears. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_ECLIPSEHELP = NO + +# A unique identifier for the Eclipse help plugin. When installing the plugin +# the directory name containing the HTML and XML files should also have this +# name. Each documentation set should have its own identifier. +# The default value is: org.doxygen.Project. +# This tag requires that the tag GENERATE_ECLIPSEHELP is set to YES. + +ECLIPSE_DOC_ID = org.doxygen.Project + +# If you want full control over the layout of the generated HTML pages it might +# be necessary to disable the index and replace it with your own. The +# DISABLE_INDEX tag can be used to turn on/off the condensed index (tabs) at top +# of each HTML page. A value of NO enables the index and the value YES disables +# it. Since the tabs in the index contain the same information as the navigation +# tree, you can set this option to YES if you also set GENERATE_TREEVIEW to YES. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +DISABLE_INDEX = NO + +# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index +# structure should be generated to display hierarchical information. If the tag +# value is set to YES, a side panel will be generated containing a tree-like +# index structure (just like the one that is generated for HTML Help). For this +# to work a browser that supports JavaScript, DHTML, CSS and frames is required +# (i.e. any modern browser). Windows users are probably better off using the +# HTML help feature. Via custom style sheets (see HTML_EXTRA_STYLESHEET) one can +# further fine-tune the look of the index. As an example, the default style +# sheet generated by doxygen has an example that shows how to put an image at +# the root of the tree instead of the PROJECT_NAME. Since the tree basically has +# the same information as the tab index, you could consider setting +# DISABLE_INDEX to YES when enabling this option. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_TREEVIEW = NO + +# The ENUM_VALUES_PER_LINE tag can be used to set the number of enum values that +# doxygen will group on one line in the generated HTML documentation. +# +# Note that a value of 0 will completely suppress the enum values from appearing +# in the overview section. +# Minimum value: 0, maximum value: 20, default value: 4. +# This tag requires that the tag GENERATE_HTML is set to YES. + +ENUM_VALUES_PER_LINE = 4 + +# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be used +# to set the initial width (in pixels) of the frame in which the tree is shown. +# Minimum value: 0, maximum value: 1500, default value: 250. +# This tag requires that the tag GENERATE_HTML is set to YES. + +TREEVIEW_WIDTH = 250 + +# If the EXT_LINKS_IN_WINDOW option is set to YES, doxygen will open links to +# external symbols imported via tag files in a separate window. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +EXT_LINKS_IN_WINDOW = NO + +# Use this tag to change the font size of LaTeX formulas included as images in +# the HTML documentation. When you change the font size after a successful +# doxygen run you need to manually remove any form_*.png images from the HTML +# output directory to force them to be regenerated. +# Minimum value: 8, maximum value: 50, default value: 10. +# This tag requires that the tag GENERATE_HTML is set to YES. + +FORMULA_FONTSIZE = 10 + +# Use the FORMULA_TRANPARENT tag to determine whether or not the images +# generated for formulas are transparent PNGs. Transparent PNGs are not +# supported properly for IE 6.0, but are supported on all modern browsers. +# +# Note that when changing this option you need to delete any form_*.png files in +# the HTML output directory before the changes have effect. +# The default value is: YES. +# This tag requires that the tag GENERATE_HTML is set to YES. + +FORMULA_TRANSPARENT = YES + +# Enable the USE_MATHJAX option to render LaTeX formulas using MathJax (see +# http://www.mathjax.org) which uses client side Javascript for the rendering +# instead of using pre-rendered bitmaps. Use this if you do not have LaTeX +# installed or if you want to formulas look prettier in the HTML output. When +# enabled you may also need to install MathJax separately and configure the path +# to it using the MATHJAX_RELPATH option. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +USE_MATHJAX = NO + +# When MathJax is enabled you can set the default output format to be used for +# the MathJax output. See the MathJax site (see: +# http://docs.mathjax.org/en/latest/output.html) for more details. +# Possible values are: HTML-CSS (which is slower, but has the best +# compatibility), NativeMML (i.e. MathML) and SVG. +# The default value is: HTML-CSS. +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_FORMAT = HTML-CSS + +# When MathJax is enabled you need to specify the location relative to the HTML +# output directory using the MATHJAX_RELPATH option. The destination directory +# should contain the MathJax.js script. For instance, if the mathjax directory +# is located at the same level as the HTML output directory, then +# MATHJAX_RELPATH should be ../mathjax. The default value points to the MathJax +# Content Delivery Network so you can quickly see the result without installing +# MathJax. However, it is strongly recommended to install a local copy of +# MathJax from http://www.mathjax.org before deployment. +# The default value is: http://cdn.mathjax.org/mathjax/latest. +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_RELPATH = http://cdn.mathjax.org/mathjax/latest + +# The MATHJAX_EXTENSIONS tag can be used to specify one or more MathJax +# extension names that should be enabled during MathJax rendering. For example +# MATHJAX_EXTENSIONS = TeX/AMSmath TeX/AMSsymbols +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_EXTENSIONS = + +# The MATHJAX_CODEFILE tag can be used to specify a file with javascript pieces +# of code that will be used on startup of the MathJax code. See the MathJax site +# (see: http://docs.mathjax.org/en/latest/output.html) for more details. For an +# example see the documentation. +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_CODEFILE = + +# When the SEARCHENGINE tag is enabled doxygen will generate a search box for +# the HTML output. The underlying search engine uses javascript and DHTML and +# should work on any modern browser. Note that when using HTML help +# (GENERATE_HTMLHELP), Qt help (GENERATE_QHP), or docsets (GENERATE_DOCSET) +# there is already a search function so this one should typically be disabled. +# For large projects the javascript based search engine can be slow, then +# enabling SERVER_BASED_SEARCH may provide a better solution. It is possible to +# search using the keyboard; to jump to the search box use <access key> + S +# (what the <access key> is depends on the OS and browser, but it is typically +# <CTRL>, <ALT>/<option>, or both). Inside the search box use the <cursor down +# key> to jump into the search results window, the results can be navigated +# using the <cursor keys>. Press <Enter> to select an item or <escape> to cancel +# the search. The filter options can be selected when the cursor is inside the +# search box by pressing <Shift>+<cursor down>. Also here use the <cursor keys> +# to select a filter and <Enter> or <escape> to activate or cancel the filter +# option. +# The default value is: YES. +# This tag requires that the tag GENERATE_HTML is set to YES. + +SEARCHENGINE = YES + +# When the SERVER_BASED_SEARCH tag is enabled the search engine will be +# implemented using a web server instead of a web client using Javascript. There +# are two flavors of web server based searching depending on the EXTERNAL_SEARCH +# setting. When disabled, doxygen will generate a PHP script for searching and +# an index file used by the script. When EXTERNAL_SEARCH is enabled the indexing +# and searching needs to be provided by external tools. See the section +# "External Indexing and Searching" for details. +# The default value is: NO. +# This tag requires that the tag SEARCHENGINE is set to YES. + +SERVER_BASED_SEARCH = NO + +# When EXTERNAL_SEARCH tag is enabled doxygen will no longer generate the PHP +# script for searching. Instead the search results are written to an XML file +# which needs to be processed by an external indexer. Doxygen will invoke an +# external search engine pointed to by the SEARCHENGINE_URL option to obtain the +# search results. +# +# Doxygen ships with an example indexer (doxyindexer) and search engine +# (doxysearch.cgi) which are based on the open source search engine library +# Xapian (see: http://xapian.org/). +# +# See the section "External Indexing and Searching" for details. +# The default value is: NO. +# This tag requires that the tag SEARCHENGINE is set to YES. + +EXTERNAL_SEARCH = NO + +# The SEARCHENGINE_URL should point to a search engine hosted by a web server +# which will return the search results when EXTERNAL_SEARCH is enabled. +# +# Doxygen ships with an example indexer (doxyindexer) and search engine +# (doxysearch.cgi) which are based on the open source search engine library +# Xapian (see: http://xapian.org/). See the section "External Indexing and +# Searching" for details. +# This tag requires that the tag SEARCHENGINE is set to YES. + +SEARCHENGINE_URL = + +# When SERVER_BASED_SEARCH and EXTERNAL_SEARCH are both enabled the unindexed +# search data is written to a file for indexing by an external tool. With the +# SEARCHDATA_FILE tag the name of this file can be specified. +# The default file is: searchdata.xml. +# This tag requires that the tag SEARCHENGINE is set to YES. + +SEARCHDATA_FILE = searchdata.xml + +# When SERVER_BASED_SEARCH and EXTERNAL_SEARCH are both enabled the +# EXTERNAL_SEARCH_ID tag can be used as an identifier for the project. This is +# useful in combination with EXTRA_SEARCH_MAPPINGS to search through multiple +# projects and redirect the results back to the right project. +# This tag requires that the tag SEARCHENGINE is set to YES. + +EXTERNAL_SEARCH_ID = + +# The EXTRA_SEARCH_MAPPINGS tag can be used to enable searching through doxygen +# projects other than the one defined by this configuration file, but that are +# all added to the same external search index. Each project needs to have a +# unique id set via EXTERNAL_SEARCH_ID. The search mapping then maps the id of +# to a relative location where the documentation can be found. The format is: +# EXTRA_SEARCH_MAPPINGS = tagname1=loc1 tagname2=loc2 ... +# This tag requires that the tag SEARCHENGINE is set to YES. + +EXTRA_SEARCH_MAPPINGS = + +#--------------------------------------------------------------------------- +# Configuration options related to the LaTeX output +#--------------------------------------------------------------------------- + +# If the GENERATE_LATEX tag is set to YES, doxygen will generate LaTeX output. +# The default value is: YES. + +GENERATE_LATEX = NO + +# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. If a +# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of +# it. +# The default directory is: latex. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +LATEX_OUTPUT = latex + +# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be +# invoked. +# +# Note that when enabling USE_PDFLATEX this option is only used for generating +# bitmaps for formulas in the HTML output, but not in the Makefile that is +# written to the output directory. +# The default file is: latex. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +LATEX_CMD_NAME = latex + +# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to generate +# index for LaTeX. +# The default file is: makeindex. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +MAKEINDEX_CMD_NAME = makeindex + +# If the COMPACT_LATEX tag is set to YES, doxygen generates more compact LaTeX +# documents. This may be useful for small projects and may help to save some +# trees in general. +# The default value is: NO. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +COMPACT_LATEX = NO + +# The PAPER_TYPE tag can be used to set the paper type that is used by the +# printer. +# Possible values are: a4 (210 x 297 mm), letter (8.5 x 11 inches), legal (8.5 x +# 14 inches) and executive (7.25 x 10.5 inches). +# The default value is: a4. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +PAPER_TYPE = a4 + +# The EXTRA_PACKAGES tag can be used to specify one or more LaTeX package names +# that should be included in the LaTeX output. To get the times font for +# instance you can specify +# EXTRA_PACKAGES=times +# If left blank no extra packages will be included. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +EXTRA_PACKAGES = + +# The LATEX_HEADER tag can be used to specify a personal LaTeX header for the +# generated LaTeX document. The header should contain everything until the first +# chapter. If it is left blank doxygen will generate a standard header. See +# section "Doxygen usage" for information on how to let doxygen write the +# default header to a separate file. +# +# Note: Only use a user-defined header if you know what you are doing! The +# following commands have a special meaning inside the header: $title, +# $datetime, $date, $doxygenversion, $projectname, $projectnumber, +# $projectbrief, $projectlogo. Doxygen will replace $title with the empty +# string, for the replacement values of the other commands the user is referred +# to HTML_HEADER. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +LATEX_HEADER = + +# The LATEX_FOOTER tag can be used to specify a personal LaTeX footer for the +# generated LaTeX document. The footer should contain everything after the last +# chapter. If it is left blank doxygen will generate a standard footer. See +# LATEX_HEADER for more information on how to generate a default footer and what +# special commands can be used inside the footer. +# +# Note: Only use a user-defined footer if you know what you are doing! +# This tag requires that the tag GENERATE_LATEX is set to YES. + +LATEX_FOOTER = + +# The LATEX_EXTRA_STYLESHEET tag can be used to specify additional user-defined +# LaTeX style sheets that are included after the standard style sheets created +# by doxygen. Using this option one can overrule certain style aspects. Doxygen +# will copy the style sheet files to the output directory. +# Note: The order of the extra style sheet files is of importance (e.g. the last +# style sheet in the list overrules the setting of the previous ones in the +# list). +# This tag requires that the tag GENERATE_LATEX is set to YES. + +LATEX_EXTRA_STYLESHEET = + +# The LATEX_EXTRA_FILES tag can be used to specify one or more extra images or +# other source files which should be copied to the LATEX_OUTPUT output +# directory. Note that the files will be copied as-is; there are no commands or +# markers available. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +LATEX_EXTRA_FILES = + +# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated is +# prepared for conversion to PDF (using ps2pdf or pdflatex). The PDF file will +# contain links (just like the HTML output) instead of page references. This +# makes the output suitable for online browsing using a PDF viewer. +# The default value is: YES. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +PDF_HYPERLINKS = YES + +# If the USE_PDFLATEX tag is set to YES, doxygen will use pdflatex to generate +# the PDF file directly from the LaTeX files. Set this option to YES, to get a +# higher quality PDF documentation. +# The default value is: YES. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +USE_PDFLATEX = YES + +# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \batchmode +# command to the generated LaTeX files. This will instruct LaTeX to keep running +# if errors occur, instead of asking the user for help. This option is also used +# when generating formulas in HTML. +# The default value is: NO. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +LATEX_BATCHMODE = NO + +# If the LATEX_HIDE_INDICES tag is set to YES then doxygen will not include the +# index chapters (such as File Index, Compound Index, etc.) in the output. +# The default value is: NO. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +LATEX_HIDE_INDICES = NO + +# If the LATEX_SOURCE_CODE tag is set to YES then doxygen will include source +# code with syntax highlighting in the LaTeX output. +# +# Note that which sources are shown also depends on other settings such as +# SOURCE_BROWSER. +# The default value is: NO. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +LATEX_SOURCE_CODE = NO + +# The LATEX_BIB_STYLE tag can be used to specify the style to use for the +# bibliography, e.g. plainnat, or ieeetr. See +# http://en.wikipedia.org/wiki/BibTeX and \cite for more info. +# The default value is: plain. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +LATEX_BIB_STYLE = plain + +#--------------------------------------------------------------------------- +# Configuration options related to the RTF output +#--------------------------------------------------------------------------- + +# If the GENERATE_RTF tag is set to YES, doxygen will generate RTF output. The +# RTF output is optimized for Word 97 and may not look too pretty with other RTF +# readers/editors. +# The default value is: NO. + +GENERATE_RTF = NO + +# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. If a +# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of +# it. +# The default directory is: rtf. +# This tag requires that the tag GENERATE_RTF is set to YES. + +RTF_OUTPUT = rtf + +# If the COMPACT_RTF tag is set to YES, doxygen generates more compact RTF +# documents. This may be useful for small projects and may help to save some +# trees in general. +# The default value is: NO. +# This tag requires that the tag GENERATE_RTF is set to YES. + +COMPACT_RTF = NO + +# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated will +# contain hyperlink fields. The RTF file will contain links (just like the HTML +# output) instead of page references. This makes the output suitable for online +# browsing using Word or some other Word compatible readers that support those +# fields. +# +# Note: WordPad (write) and others do not support links. +# The default value is: NO. +# This tag requires that the tag GENERATE_RTF is set to YES. + +RTF_HYPERLINKS = NO + +# Load stylesheet definitions from file. Syntax is similar to doxygen's config +# file, i.e. a series of assignments. You only have to provide replacements, +# missing definitions are set to their default value. +# +# See also section "Doxygen usage" for information on how to generate the +# default style sheet that doxygen normally uses. +# This tag requires that the tag GENERATE_RTF is set to YES. + +RTF_STYLESHEET_FILE = + +# Set optional variables used in the generation of an RTF document. Syntax is +# similar to doxygen's config file. A template extensions file can be generated +# using doxygen -e rtf extensionFile. +# This tag requires that the tag GENERATE_RTF is set to YES. + +RTF_EXTENSIONS_FILE = + +# If the RTF_SOURCE_CODE tag is set to YES then doxygen will include source code +# with syntax highlighting in the RTF output. +# +# Note that which sources are shown also depends on other settings such as +# SOURCE_BROWSER. +# The default value is: NO. +# This tag requires that the tag GENERATE_RTF is set to YES. + +RTF_SOURCE_CODE = NO + +#--------------------------------------------------------------------------- +# Configuration options related to the man page output +#--------------------------------------------------------------------------- + +# If the GENERATE_MAN tag is set to YES, doxygen will generate man pages for +# classes and files. +# The default value is: NO. + +GENERATE_MAN = NO + +# The MAN_OUTPUT tag is used to specify where the man pages will be put. If a +# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of +# it. A directory man3 will be created inside the directory specified by +# MAN_OUTPUT. +# The default directory is: man. +# This tag requires that the tag GENERATE_MAN is set to YES. + +MAN_OUTPUT = man + +# The MAN_EXTENSION tag determines the extension that is added to the generated +# man pages. In case the manual section does not start with a number, the number +# 3 is prepended. The dot (.) at the beginning of the MAN_EXTENSION tag is +# optional. +# The default value is: .3. +# This tag requires that the tag GENERATE_MAN is set to YES. + +MAN_EXTENSION = .3 + +# The MAN_SUBDIR tag determines the name of the directory created within +# MAN_OUTPUT in which the man pages are placed. If defaults to man followed by +# MAN_EXTENSION with the initial . removed. +# This tag requires that the tag GENERATE_MAN is set to YES. + +MAN_SUBDIR = + +# If the MAN_LINKS tag is set to YES and doxygen generates man output, then it +# will generate one additional man file for each entity documented in the real +# man page(s). These additional files only source the real man page, but without +# them the man command would be unable to find the correct page. +# The default value is: NO. +# This tag requires that the tag GENERATE_MAN is set to YES. + +MAN_LINKS = NO + +#--------------------------------------------------------------------------- +# Configuration options related to the XML output +#--------------------------------------------------------------------------- + +# If the GENERATE_XML tag is set to YES, doxygen will generate an XML file that +# captures the structure of the code including all documentation. +# The default value is: NO. + +GENERATE_XML = NO + +# The XML_OUTPUT tag is used to specify where the XML pages will be put. If a +# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of +# it. +# The default directory is: xml. +# This tag requires that the tag GENERATE_XML is set to YES. + +XML_OUTPUT = xml + +# If the XML_PROGRAMLISTING tag is set to YES, doxygen will dump the program +# listings (including syntax highlighting and cross-referencing information) to +# the XML output. Note that enabling this will significantly increase the size +# of the XML output. +# The default value is: YES. +# This tag requires that the tag GENERATE_XML is set to YES. + +XML_PROGRAMLISTING = YES + +#--------------------------------------------------------------------------- +# Configuration options related to the DOCBOOK output +#--------------------------------------------------------------------------- + +# If the GENERATE_DOCBOOK tag is set to YES, doxygen will generate Docbook files +# that can be used to generate PDF. +# The default value is: NO. + +GENERATE_DOCBOOK = NO + +# The DOCBOOK_OUTPUT tag is used to specify where the Docbook pages will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be put in +# front of it. +# The default directory is: docbook. +# This tag requires that the tag GENERATE_DOCBOOK is set to YES. + +DOCBOOK_OUTPUT = docbook + +# If the DOCBOOK_PROGRAMLISTING tag is set to YES, doxygen will include the +# program listings (including syntax highlighting and cross-referencing +# information) to the DOCBOOK output. Note that enabling this will significantly +# increase the size of the DOCBOOK output. +# The default value is: NO. +# This tag requires that the tag GENERATE_DOCBOOK is set to YES. + +DOCBOOK_PROGRAMLISTING = NO + +#--------------------------------------------------------------------------- +# Configuration options for the AutoGen Definitions output +#--------------------------------------------------------------------------- + +# If the GENERATE_AUTOGEN_DEF tag is set to YES, doxygen will generate an +# AutoGen Definitions (see http://autogen.sf.net) file that captures the +# structure of the code including all documentation. Note that this feature is +# still experimental and incomplete at the moment. +# The default value is: NO. + +GENERATE_AUTOGEN_DEF = NO + +#--------------------------------------------------------------------------- +# Configuration options related to the Perl module output +#--------------------------------------------------------------------------- + +# If the GENERATE_PERLMOD tag is set to YES, doxygen will generate a Perl module +# file that captures the structure of the code including all documentation. +# +# Note that this feature is still experimental and incomplete at the moment. +# The default value is: NO. + +GENERATE_PERLMOD = NO + +# If the PERLMOD_LATEX tag is set to YES, doxygen will generate the necessary +# Makefile rules, Perl scripts and LaTeX code to be able to generate PDF and DVI +# output from the Perl module output. +# The default value is: NO. +# This tag requires that the tag GENERATE_PERLMOD is set to YES. + +PERLMOD_LATEX = NO + +# If the PERLMOD_PRETTY tag is set to YES, the Perl module output will be nicely +# formatted so it can be parsed by a human reader. This is useful if you want to +# understand what is going on. On the other hand, if this tag is set to NO, the +# size of the Perl module output will be much smaller and Perl will parse it +# just the same. +# The default value is: YES. +# This tag requires that the tag GENERATE_PERLMOD is set to YES. + +PERLMOD_PRETTY = YES + +# The names of the make variables in the generated doxyrules.make file are +# prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. This is useful +# so different doxyrules.make files included by the same Makefile don't +# overwrite each other's variables. +# This tag requires that the tag GENERATE_PERLMOD is set to YES. + +PERLMOD_MAKEVAR_PREFIX = + +#--------------------------------------------------------------------------- +# Configuration options related to the preprocessor +#--------------------------------------------------------------------------- + +# If the ENABLE_PREPROCESSING tag is set to YES, doxygen will evaluate all +# C-preprocessor directives found in the sources and include files. +# The default value is: YES. + +ENABLE_PREPROCESSING = YES + +# If the MACRO_EXPANSION tag is set to YES, doxygen will expand all macro names +# in the source code. If set to NO, only conditional compilation will be +# performed. Macro expansion can be done in a controlled way by setting +# EXPAND_ONLY_PREDEF to YES. +# The default value is: NO. +# This tag requires that the tag ENABLE_PREPROCESSING is set to YES. + +MACRO_EXPANSION = YES + +# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES then +# the macro expansion is limited to the macros specified with the PREDEFINED and +# EXPAND_AS_DEFINED tags. +# The default value is: NO. +# This tag requires that the tag ENABLE_PREPROCESSING is set to YES. + +EXPAND_ONLY_PREDEF = NO + +# If the SEARCH_INCLUDES tag is set to YES, the include files in the +# INCLUDE_PATH will be searched if a #include is found. +# The default value is: YES. +# This tag requires that the tag ENABLE_PREPROCESSING is set to YES. + +SEARCH_INCLUDES = YES + +# The INCLUDE_PATH tag can be used to specify one or more directories that +# contain include files that are not input files but should be processed by the +# preprocessor. +# This tag requires that the tag SEARCH_INCLUDES is set to YES. + +INCLUDE_PATH = @top_srcdir@ + +# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard +# patterns (like *.h and *.hpp) to filter out the header-files in the +# directories. If left blank, the patterns specified with FILE_PATTERNS will be +# used. +# This tag requires that the tag ENABLE_PREPROCESSING is set to YES. + +INCLUDE_FILE_PATTERNS = + +# The PREDEFINED tag can be used to specify one or more macro names that are +# defined before the preprocessor is started (similar to the -D option of e.g. +# gcc). The argument of the tag is a list of macros of the form: name or +# name=definition (no spaces). If the definition and the "=" are omitted, "=1" +# is assumed. To prevent a macro definition from being undefined via #undef or +# recursively expanded use the := operator instead of the = operator. +# This tag requires that the tag ENABLE_PREPROCESSING is set to YES. + +PREDEFINED = HAVE_CONFIG_H + +# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then this +# tag can be used to specify a list of macro names that should be expanded. The +# macro definition that is found in the sources will be used. Use the PREDEFINED +# tag if you want to use a different macro definition that overrules the +# definition found in the source code. +# This tag requires that the tag ENABLE_PREPROCESSING is set to YES. + +EXPAND_AS_DEFINED = + +# If the SKIP_FUNCTION_MACROS tag is set to YES then doxygen's preprocessor will +# remove all references to function-like macros that are alone on a line, have +# an all uppercase name, and do not end with a semicolon. Such function macros +# are typically used for boiler-plate code, and will confuse the parser if not +# removed. +# The default value is: YES. +# This tag requires that the tag ENABLE_PREPROCESSING is set to YES. + +SKIP_FUNCTION_MACROS = YES + +#--------------------------------------------------------------------------- +# Configuration options related to external references +#--------------------------------------------------------------------------- + +# The TAGFILES tag can be used to specify one or more tag files. For each tag +# file the location of the external documentation should be added. The format of +# a tag file without this location is as follows: +# TAGFILES = file1 file2 ... +# Adding location for the tag files is done as follows: +# TAGFILES = file1=loc1 "file2 = loc2" ... +# where loc1 and loc2 can be relative or absolute paths or URLs. See the +# section "Linking to external documentation" for more information about the use +# of tag files. +# Note: Each tag file must have a unique name (where the name does NOT include +# the path). If a tag file is not located in the directory in which doxygen is +# run, you must also specify the path to the tagfile here. + +TAGFILES = + +# When a file name is specified after GENERATE_TAGFILE, doxygen will create a +# tag file that is based on the input files it reads. See section "Linking to +# external documentation" for more information about the usage of tag files. + +GENERATE_TAGFILE = + +# If the ALLEXTERNALS tag is set to YES, all external class will be listed in +# the class index. If set to NO, only the inherited external classes will be +# listed. +# The default value is: NO. + +ALLEXTERNALS = NO + +# If the EXTERNAL_GROUPS tag is set to YES, all external groups will be listed +# in the modules index. If set to NO, only the current project's groups will be +# listed. +# The default value is: YES. + +EXTERNAL_GROUPS = YES + +# If the EXTERNAL_PAGES tag is set to YES, all external pages will be listed in +# the related pages index. If set to NO, only the current project's pages will +# be listed. +# The default value is: YES. + +EXTERNAL_PAGES = YES + +# The PERL_PATH should be the absolute path and name of the perl script +# interpreter (i.e. the result of 'which perl'). +# The default file (with absolute path) is: /usr/bin/perl. + +PERL_PATH = /usr/bin/perl + +#--------------------------------------------------------------------------- +# Configuration options related to the dot tool +#--------------------------------------------------------------------------- + +# If the CLASS_DIAGRAMS tag is set to YES, doxygen will generate a class diagram +# (in HTML and LaTeX) for classes with base or super classes. Setting the tag to +# NO turns the diagrams off. Note that this option also works with HAVE_DOT +# disabled, but it is recommended to install and use dot, since it yields more +# powerful graphs. +# The default value is: YES. + +CLASS_DIAGRAMS = YES + +# You can define message sequence charts within doxygen comments using the \msc +# command. Doxygen will then run the mscgen tool (see: +# http://www.mcternan.me.uk/mscgen/)) to produce the chart and insert it in the +# documentation. The MSCGEN_PATH tag allows you to specify the directory where +# the mscgen tool resides. If left empty the tool is assumed to be found in the +# default search path. + +MSCGEN_PATH = + +# You can include diagrams made with dia in doxygen documentation. Doxygen will +# then run dia to produce the diagram and insert it in the documentation. The +# DIA_PATH tag allows you to specify the directory where the dia binary resides. +# If left empty dia is assumed to be found in the default search path. + +DIA_PATH = + +# If set to YES the inheritance and collaboration graphs will hide inheritance +# and usage relations if the target is undocumented or is not a class. +# The default value is: YES. + +HIDE_UNDOC_RELATIONS = YES + +# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is +# available from the path. This tool is part of Graphviz (see: +# http://www.graphviz.org/), a graph visualization toolkit from AT&T and Lucent +# Bell Labs. The other options in this section have no effect if this option is +# set to NO +# The default value is: YES. + +HAVE_DOT = YES + +# The DOT_NUM_THREADS specifies the number of dot invocations doxygen is allowed +# to run in parallel. When set to 0 doxygen will base this on the number of +# processors available in the system. You can set it explicitly to a value +# larger than 0 to get control over the balance between CPU load and processing +# speed. +# Minimum value: 0, maximum value: 32, default value: 0. +# This tag requires that the tag HAVE_DOT is set to YES. + +DOT_NUM_THREADS = 0 + +# When you want a differently looking font in the dot files that doxygen +# generates you can specify the font name using DOT_FONTNAME. You need to make +# sure dot is able to find the font, which can be done by putting it in a +# standard location or by setting the DOTFONTPATH environment variable or by +# setting DOT_FONTPATH to the directory containing the font. +# The default value is: Helvetica. +# This tag requires that the tag HAVE_DOT is set to YES. + +DOT_FONTNAME = Helvetica + +# The DOT_FONTSIZE tag can be used to set the size (in points) of the font of +# dot graphs. +# Minimum value: 4, maximum value: 24, default value: 10. +# This tag requires that the tag HAVE_DOT is set to YES. + +DOT_FONTSIZE = 10 + +# By default doxygen will tell dot to use the default font as specified with +# DOT_FONTNAME. If you specify a different font using DOT_FONTNAME you can set +# the path where dot can find it using this tag. +# This tag requires that the tag HAVE_DOT is set to YES. + +DOT_FONTPATH = + +# If the CLASS_GRAPH tag is set to YES then doxygen will generate a graph for +# each documented class showing the direct and indirect inheritance relations. +# Setting this tag to YES will force the CLASS_DIAGRAMS tag to NO. +# The default value is: YES. +# This tag requires that the tag HAVE_DOT is set to YES. + +CLASS_GRAPH = YES + +# If the COLLABORATION_GRAPH tag is set to YES then doxygen will generate a +# graph for each documented class showing the direct and indirect implementation +# dependencies (inheritance, containment, and class references variables) of the +# class with other documented classes. +# The default value is: YES. +# This tag requires that the tag HAVE_DOT is set to YES. + +COLLABORATION_GRAPH = YES + +# If the GROUP_GRAPHS tag is set to YES then doxygen will generate a graph for +# groups, showing the direct groups dependencies. +# The default value is: YES. +# This tag requires that the tag HAVE_DOT is set to YES. + +GROUP_GRAPHS = YES + +# If the UML_LOOK tag is set to YES, doxygen will generate inheritance and +# collaboration diagrams in a style similar to the OMG's Unified Modeling +# Language. +# The default value is: NO. +# This tag requires that the tag HAVE_DOT is set to YES. + +UML_LOOK = NO + +# If the UML_LOOK tag is enabled, the fields and methods are shown inside the +# class node. If there are many fields or methods and many nodes the graph may +# become too big to be useful. The UML_LIMIT_NUM_FIELDS threshold limits the +# number of items for each type to make the size more manageable. Set this to 0 +# for no limit. Note that the threshold may be exceeded by 50% before the limit +# is enforced. So when you set the threshold to 10, up to 15 fields may appear, +# but if the number exceeds 15, the total amount of fields shown is limited to +# 10. +# Minimum value: 0, maximum value: 100, default value: 10. +# This tag requires that the tag HAVE_DOT is set to YES. + +UML_LIMIT_NUM_FIELDS = 10 + +# If the TEMPLATE_RELATIONS tag is set to YES then the inheritance and +# collaboration graphs will show the relations between templates and their +# instances. +# The default value is: NO. +# This tag requires that the tag HAVE_DOT is set to YES. + +TEMPLATE_RELATIONS = NO + +# If the INCLUDE_GRAPH, ENABLE_PREPROCESSING and SEARCH_INCLUDES tags are set to +# YES then doxygen will generate a graph for each documented file showing the +# direct and indirect include dependencies of the file with other documented +# files. +# The default value is: YES. +# This tag requires that the tag HAVE_DOT is set to YES. + +INCLUDE_GRAPH = YES + +# If the INCLUDED_BY_GRAPH, ENABLE_PREPROCESSING and SEARCH_INCLUDES tags are +# set to YES then doxygen will generate a graph for each documented file showing +# the direct and indirect include dependencies of the file with other documented +# files. +# The default value is: YES. +# This tag requires that the tag HAVE_DOT is set to YES. + +INCLUDED_BY_GRAPH = NO + +# If the CALL_GRAPH tag is set to YES then doxygen will generate a call +# dependency graph for every global function or class method. +# +# Note that enabling this option will significantly increase the time of a run. +# So in most cases it will be better to enable call graphs for selected +# functions only using the \callgraph command. +# The default value is: NO. +# This tag requires that the tag HAVE_DOT is set to YES. + +CALL_GRAPH = NO + +# If the CALLER_GRAPH tag is set to YES then doxygen will generate a caller +# dependency graph for every global function or class method. +# +# Note that enabling this option will significantly increase the time of a run. +# So in most cases it will be better to enable caller graphs for selected +# functions only using the \callergraph command. +# The default value is: NO. +# This tag requires that the tag HAVE_DOT is set to YES. + +CALLER_GRAPH = NO + +# If the GRAPHICAL_HIERARCHY tag is set to YES then doxygen will graphical +# hierarchy of all classes instead of a textual one. +# The default value is: YES. +# This tag requires that the tag HAVE_DOT is set to YES. + +GRAPHICAL_HIERARCHY = YES + +# If the DIRECTORY_GRAPH tag is set to YES then doxygen will show the +# dependencies a directory has on other directories in a graphical way. The +# dependency relations are determined by the #include relations between the +# files in the directories. +# The default value is: YES. +# This tag requires that the tag HAVE_DOT is set to YES. + +DIRECTORY_GRAPH = YES + +# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images +# generated by dot. +# Note: If you choose svg you need to set HTML_FILE_EXTENSION to xhtml in order +# to make the SVG files visible in IE 9+ (other browsers do not have this +# requirement). +# Possible values are: png, png:cairo, png:cairo:cairo, png:cairo:gd, png:gd, +# png:gd:gd, jpg, jpg:cairo, jpg:cairo:gd, jpg:gd, jpg:gd:gd, gif, gif:cairo, +# gif:cairo:gd, gif:gd, gif:gd:gd and svg. +# The default value is: png. +# This tag requires that the tag HAVE_DOT is set to YES. + +DOT_IMAGE_FORMAT = png + +# If DOT_IMAGE_FORMAT is set to svg, then this option can be set to YES to +# enable generation of interactive SVG images that allow zooming and panning. +# +# Note that this requires a modern browser other than Internet Explorer. Tested +# and working are Firefox, Chrome, Safari, and Opera. +# Note: For IE 9+ you need to set HTML_FILE_EXTENSION to xhtml in order to make +# the SVG files visible. Older versions of IE do not have SVG support. +# The default value is: NO. +# This tag requires that the tag HAVE_DOT is set to YES. + +INTERACTIVE_SVG = NO + +# The DOT_PATH tag can be used to specify the path where the dot tool can be +# found. If left blank, it is assumed the dot tool can be found in the path. +# This tag requires that the tag HAVE_DOT is set to YES. + +DOT_PATH = + +# The DOTFILE_DIRS tag can be used to specify one or more directories that +# contain dot files that are included in the documentation (see the \dotfile +# command). +# This tag requires that the tag HAVE_DOT is set to YES. + +DOTFILE_DIRS = + +# The MSCFILE_DIRS tag can be used to specify one or more directories that +# contain msc files that are included in the documentation (see the \mscfile +# command). + +MSCFILE_DIRS = + +# The DIAFILE_DIRS tag can be used to specify one or more directories that +# contain dia files that are included in the documentation (see the \diafile +# command). + +DIAFILE_DIRS = + +# When using plantuml, the PLANTUML_JAR_PATH tag should be used to specify the +# path where java can find the plantuml.jar file. If left blank, it is assumed +# PlantUML is not used or called during a preprocessing step. Doxygen will +# generate a warning when it encounters a \startuml command in this case and +# will not generate output for the diagram. + +PLANTUML_JAR_PATH = + +# When using plantuml, the specified paths are searched for files specified by +# the !include statement in a plantuml block. + +PLANTUML_INCLUDE_PATH = + +# The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of nodes +# that will be shown in the graph. If the number of nodes in a graph becomes +# larger than this value, doxygen will truncate the graph, which is visualized +# by representing a node as a red box. Note that doxygen if the number of direct +# children of the root node in a graph is already larger than +# DOT_GRAPH_MAX_NODES then the graph will not be shown at all. Also note that +# the size of a graph can be further restricted by MAX_DOT_GRAPH_DEPTH. +# Minimum value: 0, maximum value: 10000, default value: 50. +# This tag requires that the tag HAVE_DOT is set to YES. + +DOT_GRAPH_MAX_NODES = 50 + +# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the graphs +# generated by dot. A depth value of 3 means that only nodes reachable from the +# root by following a path via at most 3 edges will be shown. Nodes that lay +# further from the root node will be omitted. Note that setting this option to 1 +# or 2 may greatly reduce the computation time needed for large code bases. Also +# note that the size of a graph can be further restricted by +# DOT_GRAPH_MAX_NODES. Using a depth of 0 means no depth restriction. +# Minimum value: 0, maximum value: 1000, default value: 0. +# This tag requires that the tag HAVE_DOT is set to YES. + +MAX_DOT_GRAPH_DEPTH = 0 + +# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent +# background. This is disabled by default, because dot on Windows does not seem +# to support this out of the box. +# +# Warning: Depending on the platform used, enabling this option may lead to +# badly anti-aliased labels on the edges of a graph (i.e. they become hard to +# read). +# The default value is: NO. +# This tag requires that the tag HAVE_DOT is set to YES. + +DOT_TRANSPARENT = NO + +# Set the DOT_MULTI_TARGETS tag to YES to allow dot to generate multiple output +# files in one run (i.e. multiple -o and -T options on the command line). This +# makes dot run faster, but since only newer versions of dot (>1.8.10) support +# this, this feature is disabled by default. +# The default value is: NO. +# This tag requires that the tag HAVE_DOT is set to YES. + +DOT_MULTI_TARGETS = NO + +# If the GENERATE_LEGEND tag is set to YES doxygen will generate a legend page +# explaining the meaning of the various boxes and arrows in the dot generated +# graphs. +# The default value is: YES. +# This tag requires that the tag HAVE_DOT is set to YES. + +GENERATE_LEGEND = YES + +# If the DOT_CLEANUP tag is set to YES, doxygen will remove the intermediate dot +# files that are used to generate the various graphs. +# The default value is: YES. +# This tag requires that the tag HAVE_DOT is set to YES. + +DOT_CLEANUP = YES diff --git a/resources/3rdparty/cudd-2.5.0/LICENSE b/resources/3rdparty/cudd-3.0.0/LICENSE similarity index 100% rename from resources/3rdparty/cudd-2.5.0/LICENSE rename to resources/3rdparty/cudd-3.0.0/LICENSE diff --git a/resources/3rdparty/cudd-3.0.0/Makefile.am b/resources/3rdparty/cudd-3.0.0/Makefile.am new file mode 100644 index 000000000..54f0b03d4 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/Makefile.am @@ -0,0 +1,58 @@ +ACLOCAL_AMFLAGS = -I m4 + +include_HEADERS = cudd/cudd.h +include_HEADERS += mtr/mtr.h +if DDDMP +include_HEADERS += dddmp/dddmp.h +endif +if OBJ +include_HEADERS += cplusplus/cuddObj.hh +endif + +check_PROGRAMS = +check_SCRIPTS = +dist_check_DATA = +EXTRA_DIST = README RELEASE.NOTES LICENSE groups.dox +TESTS = +CLEANFILES = +noinst_LTLIBRARIES = +TEST_LOG_DRIVER = env AM_TAP_AWK='$(AWK)' $(SHELL) \ + $(top_srcdir)/build-aux/tap-driver.sh + +do_subst = sed \ + -e 's,[@]EXEEXT[@],$(EXEEXT),g' \ + -e 's,[@]srcdir[@],$(srcdir),g' + +include $(top_srcdir)/cudd/Included.am +include $(top_srcdir)/util/Included.am +include $(top_srcdir)/st/Included.am +include $(top_srcdir)/epd/Included.am +include $(top_srcdir)/mtr/Included.am +include $(top_srcdir)/dddmp/Included.am +include $(top_srcdir)/cplusplus/Included.am +include $(top_srcdir)/nanotrav/Included.am +include $(top_srcdir)/doc/Included.am + +dist-hook: + rm -rf `find $(distdir) -name .svn` + +.PHONY : + +all: html/index.html doc/cudd.pdf + +#if HAVE_DOXYGEN +# +#html/index.html: Doxyfile $(lib_LTLIBRARIES) +# @if $(AM_V_P); then dest='2>&1'; else dest='> /dev/null 2>&1'; fi; \ +# eval "$(DOXYGEN) $< $${dest}" +# +#clean-local: +# rm -rf html doxygen_sqlite3.db +# +#else + +html/index.html: + +#endif + +CLEANFILES += $(check_SCRIPTS) diff --git a/resources/3rdparty/cudd-3.0.0/Makefile.in b/resources/3rdparty/cudd-3.0.0/Makefile.in new file mode 100644 index 000000000..75846bc4c --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/Makefile.in @@ -0,0 +1,3190 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +@DDDMP_TRUE@am__append_1 = dddmp/dddmp.h +@OBJ_TRUE@am__append_2 = cplusplus/cuddObj.hh +check_PROGRAMS = cudd/testcudd$(EXEEXT) cudd/testextra$(EXEEXT) \ + st/testst$(EXEEXT) mtr/testmtr$(EXEEXT) \ + dddmp/testdddmp$(EXEEXT) cplusplus/testobj$(EXEEXT) \ + cplusplus/testmulti$(EXEEXT) nanotrav/nanotrav$(EXEEXT) +@CROSS_COMPILING_FALSE@am__append_3 = cudd/test_cudd.test \ +@CROSS_COMPILING_FALSE@ st/test_st.test mtr/test_mtr.test \ +@CROSS_COMPILING_FALSE@ dddmp/test_dddmp.test \ +@CROSS_COMPILING_FALSE@ cplusplus/test_obj.test \ +@CROSS_COMPILING_FALSE@ nanotrav/test_ntrv.test +@DDDMP_TRUE@am__append_4 = $(dddmp_sources) +@DDDMP_FALSE@am__append_5 = dddmp/libdddmp.la +@OBJ_TRUE@am__append_6 = $(cplusplus_sources) +@OBJ_FALSE@am__append_7 = cplusplus/libobj.la +@HAVE_PDFLATEX_TRUE@am__append_8 = doc/cudd.pdf doc/cudd.aux doc/cudd.idx doc/cudd.ilg doc/cudd.ind \ +@HAVE_PDFLATEX_TRUE@ doc/cudd.log doc/cudd.out doc/cudd.toc + +subdir = . +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/modern_cxx.m4 $(top_srcdir)/m4/w32.m4 \ + $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ + $(am__configure_deps) $(dist_check_DATA) \ + $(am__include_HEADERS_DIST) $(am__DIST_COMMON) +am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ + configure.lineno config.status.lineno +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = config.h +CONFIG_CLEAN_FILES = Doxyfile doc/cudd.tex dddmp/exp/test1.sh \ + dddmp/exp/test2.sh dddmp/exp/test3.sh dddmp/exp/test4.sh \ + dddmp/exp/test5.sh dddmp/exp/test6.sh dddmp/exp/test7.sh +CONFIG_CLEAN_VPATH_FILES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)" +LTLIBRARIES = $(lib_LTLIBRARIES) $(noinst_LTLIBRARIES) +cplusplus_libobj_la_LIBADD = +am__cplusplus_libobj_la_SOURCES_DIST = cplusplus/cuddObj.hh \ + cplusplus/cuddObj.cc +am__dirstamp = $(am__leading_dot)dirstamp +am__objects_1 = cplusplus/cplusplus_libobj_la-cuddObj.lo +@OBJ_FALSE@am_cplusplus_libobj_la_OBJECTS = $(am__objects_1) +cplusplus_libobj_la_OBJECTS = $(am_cplusplus_libobj_la_OBJECTS) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +@OBJ_FALSE@am_cplusplus_libobj_la_rpath = +cudd_libcudd_la_DEPENDENCIES = +am__cudd_libcudd_la_SOURCES_DIST = cudd/cudd.h cudd/cuddInt.h \ + cudd/cuddAddAbs.c cudd/cuddAddApply.c cudd/cuddAddFind.c \ + cudd/cuddAddInv.c cudd/cuddAddIte.c cudd/cuddAddNeg.c \ + cudd/cuddAddWalsh.c cudd/cuddAndAbs.c cudd/cuddAnneal.c \ + cudd/cuddApa.c cudd/cuddAPI.c cudd/cuddApprox.c \ + cudd/cuddBddAbs.c cudd/cuddBddCorr.c cudd/cuddBddIte.c \ + cudd/cuddBridge.c cudd/cuddCache.c cudd/cuddCheck.c \ + cudd/cuddClip.c cudd/cuddCof.c cudd/cuddCompose.c \ + cudd/cuddDecomp.c cudd/cuddEssent.c cudd/cuddExact.c \ + cudd/cuddExport.c cudd/cuddGenCof.c cudd/cuddGenetic.c \ + cudd/cuddGroup.c cudd/cuddHarwell.c cudd/cuddInit.c \ + cudd/cuddInteract.c cudd/cuddLCache.c cudd/cuddLevelQ.c \ + cudd/cuddLinear.c cudd/cuddLiteral.c cudd/cuddMatMult.c \ + cudd/cuddPriority.c cudd/cuddRead.c cudd/cuddRef.c \ + cudd/cuddReorder.c cudd/cuddSat.c cudd/cuddSign.c \ + cudd/cuddSolve.c cudd/cuddSplit.c cudd/cuddSubsetHB.c \ + cudd/cuddSubsetSP.c cudd/cuddSymmetry.c cudd/cuddTable.c \ + cudd/cuddUtil.c cudd/cuddWindow.c cudd/cuddZddCount.c \ + cudd/cuddZddFuncs.c cudd/cuddZddGroup.c cudd/cuddZddIsop.c \ + cudd/cuddZddLin.c cudd/cuddZddMisc.c cudd/cuddZddPort.c \ + cudd/cuddZddReord.c cudd/cuddZddSetop.c cudd/cuddZddSymm.c \ + cudd/cuddZddUtil.c util/util.h util/cstringstream.h \ + util/cpu_stats.c util/cpu_time.c util/cstringstream.c \ + util/datalimit.c util/pathsearch.c util/pipefork.c \ + util/prtime.c util/safe_mem.c util/strsav.c util/texpand.c \ + util/ucbqsort.c st/st.h st/st.c epd/epd.c epd/epdInt.h \ + epd/epd.h mtr/mtr.h mtr/mtrInt.h mtr/mtrBasic.c mtr/mtrGroup.c \ + dddmp/dddmp.h dddmp/dddmpInt.h dddmp/dddmpBinary.c \ + dddmp/dddmpConvert.c dddmp/dddmpDbg.c dddmp/dddmpLoad.c \ + dddmp/dddmpLoadCnf.c dddmp/dddmpNodeAdd.c dddmp/dddmpNodeBdd.c \ + dddmp/dddmpNodeCnf.c dddmp/dddmpStoreAdd.c \ + dddmp/dddmpStoreBdd.c dddmp/dddmpStoreCnf.c \ + dddmp/dddmpStoreMisc.c dddmp/dddmpUtil.c cplusplus/cuddObj.hh \ + cplusplus/cuddObj.cc +am__objects_2 = dddmp/cudd_libcudd_la-dddmpBinary.lo \ + dddmp/cudd_libcudd_la-dddmpConvert.lo \ + dddmp/cudd_libcudd_la-dddmpDbg.lo \ + dddmp/cudd_libcudd_la-dddmpLoad.lo \ + dddmp/cudd_libcudd_la-dddmpLoadCnf.lo \ + dddmp/cudd_libcudd_la-dddmpNodeAdd.lo \ + dddmp/cudd_libcudd_la-dddmpNodeBdd.lo \ + dddmp/cudd_libcudd_la-dddmpNodeCnf.lo \ + dddmp/cudd_libcudd_la-dddmpStoreAdd.lo \ + dddmp/cudd_libcudd_la-dddmpStoreBdd.lo \ + dddmp/cudd_libcudd_la-dddmpStoreCnf.lo \ + dddmp/cudd_libcudd_la-dddmpStoreMisc.lo \ + dddmp/cudd_libcudd_la-dddmpUtil.lo +@DDDMP_TRUE@am__objects_3 = $(am__objects_2) +am__objects_4 = cplusplus/cudd_libcudd_la-cuddObj.lo +@OBJ_TRUE@am__objects_5 = $(am__objects_4) +am_cudd_libcudd_la_OBJECTS = cudd/cudd_libcudd_la-cuddAddAbs.lo \ + cudd/cudd_libcudd_la-cuddAddApply.lo \ + cudd/cudd_libcudd_la-cuddAddFind.lo \ + cudd/cudd_libcudd_la-cuddAddInv.lo \ + cudd/cudd_libcudd_la-cuddAddIte.lo \ + cudd/cudd_libcudd_la-cuddAddNeg.lo \ + cudd/cudd_libcudd_la-cuddAddWalsh.lo \ + cudd/cudd_libcudd_la-cuddAndAbs.lo \ + cudd/cudd_libcudd_la-cuddAnneal.lo \ + cudd/cudd_libcudd_la-cuddApa.lo \ + cudd/cudd_libcudd_la-cuddAPI.lo \ + cudd/cudd_libcudd_la-cuddApprox.lo \ + cudd/cudd_libcudd_la-cuddBddAbs.lo \ + cudd/cudd_libcudd_la-cuddBddCorr.lo \ + cudd/cudd_libcudd_la-cuddBddIte.lo \ + cudd/cudd_libcudd_la-cuddBridge.lo \ + cudd/cudd_libcudd_la-cuddCache.lo \ + cudd/cudd_libcudd_la-cuddCheck.lo \ + cudd/cudd_libcudd_la-cuddClip.lo \ + cudd/cudd_libcudd_la-cuddCof.lo \ + cudd/cudd_libcudd_la-cuddCompose.lo \ + cudd/cudd_libcudd_la-cuddDecomp.lo \ + cudd/cudd_libcudd_la-cuddEssent.lo \ + cudd/cudd_libcudd_la-cuddExact.lo \ + cudd/cudd_libcudd_la-cuddExport.lo \ + cudd/cudd_libcudd_la-cuddGenCof.lo \ + cudd/cudd_libcudd_la-cuddGenetic.lo \ + cudd/cudd_libcudd_la-cuddGroup.lo \ + cudd/cudd_libcudd_la-cuddHarwell.lo \ + cudd/cudd_libcudd_la-cuddInit.lo \ + cudd/cudd_libcudd_la-cuddInteract.lo \ + cudd/cudd_libcudd_la-cuddLCache.lo \ + cudd/cudd_libcudd_la-cuddLevelQ.lo \ + cudd/cudd_libcudd_la-cuddLinear.lo \ + cudd/cudd_libcudd_la-cuddLiteral.lo \ + cudd/cudd_libcudd_la-cuddMatMult.lo \ + cudd/cudd_libcudd_la-cuddPriority.lo \ + cudd/cudd_libcudd_la-cuddRead.lo \ + cudd/cudd_libcudd_la-cuddRef.lo \ + cudd/cudd_libcudd_la-cuddReorder.lo \ + cudd/cudd_libcudd_la-cuddSat.lo \ + cudd/cudd_libcudd_la-cuddSign.lo \ + cudd/cudd_libcudd_la-cuddSolve.lo \ + cudd/cudd_libcudd_la-cuddSplit.lo \ + cudd/cudd_libcudd_la-cuddSubsetHB.lo \ + cudd/cudd_libcudd_la-cuddSubsetSP.lo \ + cudd/cudd_libcudd_la-cuddSymmetry.lo \ + cudd/cudd_libcudd_la-cuddTable.lo \ + cudd/cudd_libcudd_la-cuddUtil.lo \ + cudd/cudd_libcudd_la-cuddWindow.lo \ + cudd/cudd_libcudd_la-cuddZddCount.lo \ + cudd/cudd_libcudd_la-cuddZddFuncs.lo \ + cudd/cudd_libcudd_la-cuddZddGroup.lo \ + cudd/cudd_libcudd_la-cuddZddIsop.lo \ + cudd/cudd_libcudd_la-cuddZddLin.lo \ + cudd/cudd_libcudd_la-cuddZddMisc.lo \ + cudd/cudd_libcudd_la-cuddZddPort.lo \ + cudd/cudd_libcudd_la-cuddZddReord.lo \ + cudd/cudd_libcudd_la-cuddZddSetop.lo \ + cudd/cudd_libcudd_la-cuddZddSymm.lo \ + cudd/cudd_libcudd_la-cuddZddUtil.lo \ + util/cudd_libcudd_la-cpu_stats.lo \ + util/cudd_libcudd_la-cpu_time.lo \ + util/cudd_libcudd_la-cstringstream.lo \ + util/cudd_libcudd_la-datalimit.lo \ + util/cudd_libcudd_la-pathsearch.lo \ + util/cudd_libcudd_la-pipefork.lo \ + util/cudd_libcudd_la-prtime.lo \ + util/cudd_libcudd_la-safe_mem.lo \ + util/cudd_libcudd_la-strsav.lo util/cudd_libcudd_la-texpand.lo \ + util/cudd_libcudd_la-ucbqsort.lo st/cudd_libcudd_la-st.lo \ + epd/cudd_libcudd_la-epd.lo mtr/cudd_libcudd_la-mtrBasic.lo \ + mtr/cudd_libcudd_la-mtrGroup.lo $(am__objects_3) \ + $(am__objects_5) +cudd_libcudd_la_OBJECTS = $(am_cudd_libcudd_la_OBJECTS) +cudd_libcudd_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX \ + $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link \ + $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(cudd_libcudd_la_LDFLAGS) \ + $(LDFLAGS) -o $@ +dddmp_libdddmp_la_LIBADD = +am__dddmp_libdddmp_la_SOURCES_DIST = dddmp/dddmp.h dddmp/dddmpInt.h \ + dddmp/dddmpBinary.c dddmp/dddmpConvert.c dddmp/dddmpDbg.c \ + dddmp/dddmpLoad.c dddmp/dddmpLoadCnf.c dddmp/dddmpNodeAdd.c \ + dddmp/dddmpNodeBdd.c dddmp/dddmpNodeCnf.c \ + dddmp/dddmpStoreAdd.c dddmp/dddmpStoreBdd.c \ + dddmp/dddmpStoreCnf.c dddmp/dddmpStoreMisc.c dddmp/dddmpUtil.c +am__objects_6 = dddmp/dddmp_libdddmp_la-dddmpBinary.lo \ + dddmp/dddmp_libdddmp_la-dddmpConvert.lo \ + dddmp/dddmp_libdddmp_la-dddmpDbg.lo \ + dddmp/dddmp_libdddmp_la-dddmpLoad.lo \ + dddmp/dddmp_libdddmp_la-dddmpLoadCnf.lo \ + dddmp/dddmp_libdddmp_la-dddmpNodeAdd.lo \ + dddmp/dddmp_libdddmp_la-dddmpNodeBdd.lo \ + dddmp/dddmp_libdddmp_la-dddmpNodeCnf.lo \ + dddmp/dddmp_libdddmp_la-dddmpStoreAdd.lo \ + dddmp/dddmp_libdddmp_la-dddmpStoreBdd.lo \ + dddmp/dddmp_libdddmp_la-dddmpStoreCnf.lo \ + dddmp/dddmp_libdddmp_la-dddmpStoreMisc.lo \ + dddmp/dddmp_libdddmp_la-dddmpUtil.lo +@DDDMP_FALSE@am_dddmp_libdddmp_la_OBJECTS = $(am__objects_6) +dddmp_libdddmp_la_OBJECTS = $(am_dddmp_libdddmp_la_OBJECTS) +@DDDMP_FALSE@am_dddmp_libdddmp_la_rpath = +am_cplusplus_testmulti_OBJECTS = \ + cplusplus/cplusplus_testmulti-testmulti.$(OBJEXT) +cplusplus_testmulti_OBJECTS = $(am_cplusplus_testmulti_OBJECTS) +@OBJ_FALSE@cplusplus_testmulti_DEPENDENCIES = cplusplus/libobj.la \ +@OBJ_FALSE@ cudd/libcudd.la +@OBJ_TRUE@cplusplus_testmulti_DEPENDENCIES = cudd/libcudd.la +cplusplus_testmulti_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX \ + $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CXXLD) \ + $(AM_CXXFLAGS) $(CXXFLAGS) $(cplusplus_testmulti_LDFLAGS) \ + $(LDFLAGS) -o $@ +am_cplusplus_testobj_OBJECTS = \ + cplusplus/cplusplus_testobj-testobj.$(OBJEXT) +cplusplus_testobj_OBJECTS = $(am_cplusplus_testobj_OBJECTS) +@OBJ_FALSE@cplusplus_testobj_DEPENDENCIES = cplusplus/libobj.la \ +@OBJ_FALSE@ cudd/libcudd.la +@OBJ_TRUE@cplusplus_testobj_DEPENDENCIES = cudd/libcudd.la +am_cudd_testcudd_OBJECTS = cudd/cudd_testcudd-testcudd.$(OBJEXT) +cudd_testcudd_OBJECTS = $(am_cudd_testcudd_OBJECTS) +cudd_testcudd_DEPENDENCIES = cudd/libcudd.la +am_cudd_testextra_OBJECTS = cudd/cudd_testextra-testextra.$(OBJEXT) +cudd_testextra_OBJECTS = $(am_cudd_testextra_OBJECTS) +cudd_testextra_DEPENDENCIES = cudd/libcudd.la +am_dddmp_testdddmp_OBJECTS = \ + dddmp/dddmp_testdddmp-testdddmp.$(OBJEXT) +dddmp_testdddmp_OBJECTS = $(am_dddmp_testdddmp_OBJECTS) +@DDDMP_FALSE@dddmp_testdddmp_DEPENDENCIES = dddmp/libdddmp.la \ +@DDDMP_FALSE@ cudd/libcudd.la +@DDDMP_TRUE@dddmp_testdddmp_DEPENDENCIES = cudd/libcudd.la +am_mtr_testmtr_OBJECTS = mtr/mtr_testmtr-testmtr.$(OBJEXT) +mtr_testmtr_OBJECTS = $(am_mtr_testmtr_OBJECTS) +mtr_testmtr_DEPENDENCIES = cudd/libcudd.la +am_nanotrav_nanotrav_OBJECTS = \ + nanotrav/nanotrav_nanotrav-bnet.$(OBJEXT) \ + nanotrav/nanotrav_nanotrav-chkMterm.$(OBJEXT) \ + nanotrav/nanotrav_nanotrav-main.$(OBJEXT) \ + nanotrav/nanotrav_nanotrav-ntrBddTest.$(OBJEXT) \ + nanotrav/nanotrav_nanotrav-ntr.$(OBJEXT) \ + nanotrav/nanotrav_nanotrav-ntrHeap.$(OBJEXT) \ + nanotrav/nanotrav_nanotrav-ntrMflow.$(OBJEXT) \ + nanotrav/nanotrav_nanotrav-ntrShort.$(OBJEXT) \ + nanotrav/nanotrav_nanotrav-ntrZddTest.$(OBJEXT) +nanotrav_nanotrav_OBJECTS = $(am_nanotrav_nanotrav_OBJECTS) +@DDDMP_FALSE@nanotrav_nanotrav_DEPENDENCIES = dddmp/libdddmp.la \ +@DDDMP_FALSE@ cudd/libcudd.la +@DDDMP_TRUE@nanotrav_nanotrav_DEPENDENCIES = cudd/libcudd.la +am_st_testst_OBJECTS = st/st_testst-testst.$(OBJEXT) +st_testst_OBJECTS = $(am_st_testst_OBJECTS) +st_testst_DEPENDENCIES = cudd/libcudd.la +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ +depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = +CCLD = $(CC) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ + $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) +LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CXXFLAGS) $(CXXFLAGS) +AM_V_CXX = $(am__v_CXX_@AM_V@) +am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) +am__v_CXX_0 = @echo " CXX " $@; +am__v_CXX_1 = +CXXLD = $(CXX) +CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ + $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) +am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) +am__v_CXXLD_0 = @echo " CXXLD " $@; +am__v_CXXLD_1 = +SOURCES = $(cplusplus_libobj_la_SOURCES) $(cudd_libcudd_la_SOURCES) \ + $(dddmp_libdddmp_la_SOURCES) $(cplusplus_testmulti_SOURCES) \ + $(cplusplus_testobj_SOURCES) $(cudd_testcudd_SOURCES) \ + $(cudd_testextra_SOURCES) $(dddmp_testdddmp_SOURCES) \ + $(mtr_testmtr_SOURCES) $(nanotrav_nanotrav_SOURCES) \ + $(st_testst_SOURCES) +DIST_SOURCES = $(am__cplusplus_libobj_la_SOURCES_DIST) \ + $(am__cudd_libcudd_la_SOURCES_DIST) \ + $(am__dddmp_libdddmp_la_SOURCES_DIST) \ + $(cplusplus_testmulti_SOURCES) $(cplusplus_testobj_SOURCES) \ + $(cudd_testcudd_SOURCES) $(cudd_testextra_SOURCES) \ + $(dddmp_testdddmp_SOURCES) $(mtr_testmtr_SOURCES) \ + $(nanotrav_nanotrav_SOURCES) $(st_testst_SOURCES) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__include_HEADERS_DIST = cudd/cudd.h mtr/mtr.h dddmp/dddmp.h \ + cplusplus/cuddObj.hh +HEADERS = $(include_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \ + $(LISP)config.h.in +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +CSCOPE = cscope +AM_RECURSIVE_TARGETS = cscope check recheck +am__tty_colors_dummy = \ + mgn= red= grn= lgn= blu= brg= std=; \ + am__color_tests=no +am__tty_colors = { \ + $(am__tty_colors_dummy); \ + if test "X$(AM_COLOR_TESTS)" = Xno; then \ + am__color_tests=no; \ + elif test "X$(AM_COLOR_TESTS)" = Xalways; then \ + am__color_tests=yes; \ + elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \ + am__color_tests=yes; \ + fi; \ + if test $$am__color_tests = yes; then \ + red='[0;31m'; \ + grn='[0;32m'; \ + lgn='[1;32m'; \ + blu='[1;34m'; \ + mgn='[0;35m'; \ + brg='[1m'; \ + std='[m'; \ + fi; \ +} +am__recheck_rx = ^[ ]*:recheck:[ ]* +am__global_test_result_rx = ^[ ]*:global-test-result:[ ]* +am__copy_in_global_log_rx = ^[ ]*:copy-in-global-log:[ ]* +# A command that, given a newline-separated list of test names on the +# standard input, print the name of the tests that are to be re-run +# upon "make recheck". +am__list_recheck_tests = $(AWK) '{ \ + recheck = 1; \ + while ((rc = (getline line < ($$0 ".trs"))) != 0) \ + { \ + if (rc < 0) \ + { \ + if ((getline line2 < ($$0 ".log")) < 0) \ + recheck = 0; \ + break; \ + } \ + else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \ + { \ + recheck = 0; \ + break; \ + } \ + else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \ + { \ + break; \ + } \ + }; \ + if (recheck) \ + print $$0; \ + close ($$0 ".trs"); \ + close ($$0 ".log"); \ +}' +# A command that, given a newline-separated list of test names on the +# standard input, create the global log from their .trs and .log files. +am__create_global_log = $(AWK) ' \ +function fatal(msg) \ +{ \ + print "fatal: making $@: " msg | "cat >&2"; \ + exit 1; \ +} \ +function rst_section(header) \ +{ \ + print header; \ + len = length(header); \ + for (i = 1; i <= len; i = i + 1) \ + printf "="; \ + printf "\n\n"; \ +} \ +{ \ + copy_in_global_log = 1; \ + global_test_result = "RUN"; \ + while ((rc = (getline line < ($$0 ".trs"))) != 0) \ + { \ + if (rc < 0) \ + fatal("failed to read from " $$0 ".trs"); \ + if (line ~ /$(am__global_test_result_rx)/) \ + { \ + sub("$(am__global_test_result_rx)", "", line); \ + sub("[ ]*$$", "", line); \ + global_test_result = line; \ + } \ + else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \ + copy_in_global_log = 0; \ + }; \ + if (copy_in_global_log) \ + { \ + rst_section(global_test_result ": " $$0); \ + while ((rc = (getline line < ($$0 ".log"))) != 0) \ + { \ + if (rc < 0) \ + fatal("failed to read from " $$0 ".log"); \ + print line; \ + }; \ + printf "\n"; \ + }; \ + close ($$0 ".trs"); \ + close ($$0 ".log"); \ +}' +# Restructured Text title. +am__rst_title = { sed 's/.*/ & /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; } +# Solaris 10 'make', and several other traditional 'make' implementations, +# pass "-e" to $(SHELL), and POSIX 2008 even requires this. Work around it +# by disabling -e (using the XSI extension "set +e") if it's set. +am__sh_e_setup = case $$- in *e*) set +e;; esac +# Default flags passed to test drivers. +am__common_driver_flags = \ + --color-tests "$$am__color_tests" \ + --enable-hard-errors "$$am__enable_hard_errors" \ + --expect-failure "$$am__expect_failure" +# To be inserted before the command running the test. Creates the +# directory for the log if needed. Stores in $dir the directory +# containing $f, in $tst the test, in $log the log. Executes the +# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and +# passes TESTS_ENVIRONMENT. Set up options for the wrapper that +# will run the test scripts (or their associated LOG_COMPILER, if +# thy have one). +am__check_pre = \ +$(am__sh_e_setup); \ +$(am__vpath_adj_setup) $(am__vpath_adj) \ +$(am__tty_colors); \ +srcdir=$(srcdir); export srcdir; \ +case "$@" in \ + */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;; \ + *) am__odir=.;; \ +esac; \ +test "x$$am__odir" = x"." || test -d "$$am__odir" \ + || $(MKDIR_P) "$$am__odir" || exit $$?; \ +if test -f "./$$f"; then dir=./; \ +elif test -f "$$f"; then dir=; \ +else dir="$(srcdir)/"; fi; \ +tst=$$dir$$f; log='$@'; \ +if test -n '$(DISABLE_HARD_ERRORS)'; then \ + am__enable_hard_errors=no; \ +else \ + am__enable_hard_errors=yes; \ +fi; \ +case " $(XFAIL_TESTS) " in \ + *[\ \ ]$$f[\ \ ]* | *[\ \ ]$$dir$$f[\ \ ]*) \ + am__expect_failure=yes;; \ + *) \ + am__expect_failure=no;; \ +esac; \ +$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT) +# A shell command to get the names of the tests scripts with any registered +# extension removed (i.e., equivalently, the names of the test logs, with +# the '.log' extension removed). The result is saved in the shell variable +# '$bases'. This honors runtime overriding of TESTS and TEST_LOGS. Sadly, +# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)", +# since that might cause problem with VPATH rewrites for suffix-less tests. +# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'. +am__set_TESTS_bases = \ + bases='$(TEST_LOGS)'; \ + bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \ + bases=`echo $$bases` +RECHECK_LOGS = $(TEST_LOGS) +TEST_SUITE_LOG = test-suite.log +TEST_EXTENSIONS = @EXEEXT@ .test +am__test_logs1 = $(TESTS:=.log) +am__test_logs2 = $(am__test_logs1:@EXEEXT@.log=.log) +TEST_LOGS = $(am__test_logs2:.test.log=.log) +TEST_LOG_COMPILE = $(TEST_LOG_COMPILER) $(AM_TEST_LOG_FLAGS) \ + $(TEST_LOG_FLAGS) +am__set_b = \ + case '$@' in \ + */*) \ + case '$*' in \ + */*) b='$*';; \ + *) b=`echo '$@' | sed 's/\.log$$//'`; \ + esac;; \ + *) \ + b='$*';; \ + esac +am__DIST_COMMON = $(srcdir)/Doxyfile.in $(srcdir)/Makefile.in \ + $(srcdir)/config.h.in $(top_srcdir)/build-aux/ar-lib \ + $(top_srcdir)/build-aux/compile \ + $(top_srcdir)/build-aux/config.guess \ + $(top_srcdir)/build-aux/config.sub \ + $(top_srcdir)/build-aux/depcomp \ + $(top_srcdir)/build-aux/install-sh \ + $(top_srcdir)/build-aux/ltmain.sh \ + $(top_srcdir)/build-aux/missing \ + $(top_srcdir)/build-aux/tap-driver.sh \ + $(top_srcdir)/cplusplus/Included.am \ + $(top_srcdir)/cudd/Included.am $(top_srcdir)/dddmp/Included.am \ + $(top_srcdir)/dddmp/exp/test1.sh.in \ + $(top_srcdir)/dddmp/exp/test2.sh.in \ + $(top_srcdir)/dddmp/exp/test3.sh.in \ + $(top_srcdir)/dddmp/exp/test4.sh.in \ + $(top_srcdir)/dddmp/exp/test5.sh.in \ + $(top_srcdir)/dddmp/exp/test6.sh.in \ + $(top_srcdir)/dddmp/exp/test7.sh.in \ + $(top_srcdir)/doc/Included.am $(top_srcdir)/doc/cudd.tex.in \ + $(top_srcdir)/epd/Included.am $(top_srcdir)/mtr/Included.am \ + $(top_srcdir)/nanotrav/Included.am \ + $(top_srcdir)/st/Included.am $(top_srcdir)/util/Included.am \ + README build-aux/ar-lib build-aux/compile \ + build-aux/config.guess build-aux/config.sub build-aux/depcomp \ + build-aux/install-sh build-aux/ltmain.sh build-aux/missing +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +distdir = $(PACKAGE)-$(VERSION) +top_distdir = $(distdir) +am__remove_distdir = \ + if test -d "$(distdir)"; then \ + find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ + && rm -rf "$(distdir)" \ + || { sleep 5 && rm -rf "$(distdir)"; }; \ + else :; fi +am__post_remove_distdir = $(am__remove_distdir) +DIST_ARCHIVES = $(distdir).tar.gz +GZIP_ENV = --best +DIST_TARGETS = dist-gzip +distuninstallcheck_listfiles = find . -type f -print +am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ + | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' +distcleancheck_listfiles = find . -type f -print +ACLOCAL = @ACLOCAL@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINDEX = @MAKEINDEX@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PDFLATEX = @PDFLATEX@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +ACLOCAL_AMFLAGS = -I m4 +include_HEADERS = cudd/cudd.h mtr/mtr.h $(am__append_1) \ + $(am__append_2) +check_SCRIPTS = cudd/test_cudd.test st/test_st.test mtr/test_mtr.test \ + dddmp/test_dddmp.test cplusplus/test_obj.test \ + nanotrav/test_ntrv.test +dist_check_DATA = cudd/r7x8.1.mat cudd/r7x8.1.out cudd/extra.out \ + mtr/test.groups mtr/test.out cplusplus/test.out \ + cplusplus/multi.out nanotrav/adj49.blif nanotrav/adj49.out \ + nanotrav/C17.blif nanotrav/C17.out nanotrav/C880.blif \ + nanotrav/C880.out nanotrav/closest.blif nanotrav/closest.out \ + nanotrav/ham01.blif nanotrav/ham01.out nanotrav/mult32a.blif \ + nanotrav/mult32a.out nanotrav/rcn25.blif nanotrav/rcn25.out \ + nanotrav/s27.blif nanotrav/s27.out nanotrav/s27b.blif \ + nanotrav/s27b.out nanotrav/s27c.blif nanotrav/s27c.out \ + nanotrav/s382.blif nanotrav/s382.out nanotrav/s641.blif \ + nanotrav/s641.out nanotrav/miniFirst.blif \ + nanotrav/miniSecond.blif nanotrav/miniFirst.out +EXTRA_DIST = README RELEASE.NOTES LICENSE groups.dox \ + cudd/test_cudd.test.in st/test_st.test.in mtr/test_mtr.test.in \ + dddmp/README.dddmp dddmp/README.testdddmp dddmp/RELEASE_NOTES \ + dddmp/doc dddmp/test_dddmp.test.in dddmp/exp/test1.sh.in \ + dddmp/exp/test2.sh.in dddmp/exp/test3.sh.in \ + dddmp/exp/test4.sh.in dddmp/exp/test5.sh.in \ + dddmp/exp/test6.sh.in dddmp/exp/test7.sh.in dddmp/exp/0.add \ + dddmp/exp/0.bdd dddmp/exp/0or1.bdd dddmp/exp/1.add \ + dddmp/exp/1.bdd dddmp/exp/2and3.bdd dddmp/exp/2.bdd \ + dddmp/exp/3.bdd dddmp/exp/4.bdd dddmp/exp/4.bdd.bis1 \ + dddmp/exp/4.bdd.bis2 dddmp/exp/4.bdd.bis3 dddmp/exp/4.bdd.bis4 \ + dddmp/exp/4bis.bdd dddmp/exp/4.cnf dddmp/exp/4.cnf.bis \ + dddmp/exp/4.max1 dddmp/exp/4.max2 dddmp/exp/4xor5.bdd \ + dddmp/exp/5.bdd dddmp/exp/composeids.txt dddmp/exp/one.bdd \ + dddmp/exp/s27deltaDddmp1.bdd dddmp/exp/s27deltaDddmp1.bdd.bis \ + dddmp/exp/s27deltaDddmp2.bdd dddmp/exp/s27RP1.bdd \ + dddmp/exp/varauxids.ord dddmp/exp/varnames.ord \ + dddmp/exp/zero.bdd cplusplus/test_obj.test.in nanotrav/README \ + nanotrav/nanotrav.1 nanotrav/test_ntrv.test.in doc/phase.pdf +TESTS = $(am__append_3) + +#endif +CLEANFILES = cudd/r7x8.1.tst cudd/extra.tst mtr/test.tst \ + dddmp/exp/test1.sh dddmp/exp/test2.sh dddmp/exp/test3.sh \ + dddmp/exp/test4.sh dddmp/exp/test5.sh dddmp/exp/test6.sh \ + dddmp/exp/test7.sh cplusplus/test.tst cplusplus/multi.tst \ + nanotrav/adj49.tst nanotrav/C17.tst nanotrav/C880.tst \ + nanotrav/closest.tst nanotrav/ham01.tst nanotrav/mult32a.tst \ + nanotrav/rcn25.tst nanotrav/s27.tst nanotrav/s27b.tst \ + nanotrav/s27c.tst nanotrav/s382.tst nanotrav/s641.tst \ + nanotrav/miniFirst.tst $(am__append_8) $(check_SCRIPTS) +noinst_LTLIBRARIES = $(am__append_5) $(am__append_7) +TEST_LOG_DRIVER = env AM_TAP_AWK='$(AWK)' $(SHELL) \ + $(top_srcdir)/build-aux/tap-driver.sh + +do_subst = sed \ + -e 's,[@]EXEEXT[@],$(EXEEXT),g' \ + -e 's,[@]srcdir[@],$(srcdir),g' + +lib_LTLIBRARIES = cudd/libcudd.la +cudd_libcudd_la_SOURCES = cudd/cudd.h cudd/cuddInt.h cudd/cuddAddAbs.c \ + cudd/cuddAddApply.c cudd/cuddAddFind.c cudd/cuddAddInv.c \ + cudd/cuddAddIte.c cudd/cuddAddNeg.c cudd/cuddAddWalsh.c \ + cudd/cuddAndAbs.c cudd/cuddAnneal.c cudd/cuddApa.c \ + cudd/cuddAPI.c cudd/cuddApprox.c cudd/cuddBddAbs.c \ + cudd/cuddBddCorr.c cudd/cuddBddIte.c cudd/cuddBridge.c \ + cudd/cuddCache.c cudd/cuddCheck.c cudd/cuddClip.c \ + cudd/cuddCof.c cudd/cuddCompose.c cudd/cuddDecomp.c \ + cudd/cuddEssent.c cudd/cuddExact.c cudd/cuddExport.c \ + cudd/cuddGenCof.c cudd/cuddGenetic.c cudd/cuddGroup.c \ + cudd/cuddHarwell.c cudd/cuddInit.c cudd/cuddInteract.c \ + cudd/cuddLCache.c cudd/cuddLevelQ.c cudd/cuddLinear.c \ + cudd/cuddLiteral.c cudd/cuddMatMult.c cudd/cuddPriority.c \ + cudd/cuddRead.c cudd/cuddRef.c cudd/cuddReorder.c \ + cudd/cuddSat.c cudd/cuddSign.c cudd/cuddSolve.c \ + cudd/cuddSplit.c cudd/cuddSubsetHB.c cudd/cuddSubsetSP.c \ + cudd/cuddSymmetry.c cudd/cuddTable.c cudd/cuddUtil.c \ + cudd/cuddWindow.c cudd/cuddZddCount.c cudd/cuddZddFuncs.c \ + cudd/cuddZddGroup.c cudd/cuddZddIsop.c cudd/cuddZddLin.c \ + cudd/cuddZddMisc.c cudd/cuddZddPort.c cudd/cuddZddReord.c \ + cudd/cuddZddSetop.c cudd/cuddZddSymm.c cudd/cuddZddUtil.c \ + util/util.h util/cstringstream.h util/cpu_stats.c \ + util/cpu_time.c util/cstringstream.c util/datalimit.c \ + util/pathsearch.c util/pipefork.c util/prtime.c \ + util/safe_mem.c util/strsav.c util/texpand.c util/ucbqsort.c \ + st/st.h st/st.c epd/epd.c epd/epdInt.h epd/epd.h mtr/mtr.h \ + mtr/mtrInt.h mtr/mtrBasic.c mtr/mtrGroup.c $(am__append_4) \ + $(am__append_6) +cudd_libcudd_la_CPPFLAGS = -I$(top_srcdir)/cudd -I$(top_srcdir)/st \ + -I$(top_srcdir)/epd -I$(top_srcdir)/mtr -I$(top_srcdir)/util + +@OBJ_TRUE@cudd_libcudd_la_LIBTOOLFLAGS = --tag=CXX +cudd_libcudd_la_LDFLAGS = -release @PACKAGE_VERSION@ -version-info 0:0:0 \ + -no-undefined + +cudd_testcudd_SOURCES = cudd/testcudd.c +cudd_testcudd_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +cudd_testcudd_LDADD = cudd/libcudd.la +cudd_testextra_SOURCES = cudd/testextra.c +cudd_testextra_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +cudd_testextra_LDADD = cudd/libcudd.la +@CROSS_COMPILING_TRUE@@MINGW64_TRUE@cudd_libcudd_la_LIBADD = -lws2_32 -lpsapi +st_testst_SOURCES = st/testst.c +st_testst_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +st_testst_LDADD = cudd/libcudd.la +mtr_testmtr_SOURCES = mtr/testmtr.c +mtr_testmtr_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +mtr_testmtr_LDADD = cudd/libcudd.la +dddmp_sources = dddmp/dddmp.h dddmp/dddmpInt.h \ + dddmp/dddmpBinary.c dddmp/dddmpConvert.c dddmp/dddmpDbg.c \ + dddmp/dddmpLoad.c dddmp/dddmpLoadCnf.c dddmp/dddmpNodeAdd.c \ + dddmp/dddmpNodeBdd.c dddmp/dddmpNodeCnf.c dddmp/dddmpStoreAdd.c \ + dddmp/dddmpStoreBdd.c dddmp/dddmpStoreCnf.c dddmp/dddmpStoreMisc.c \ + dddmp/dddmpUtil.c + +@DDDMP_FALSE@dddmp_libdddmp_la_SOURCES = $(dddmp_sources) +@DDDMP_FALSE@dddmp_libdddmp_la_CPPFLAGS = -I$(top_srcdir)/util -I$(top_srcdir)/mtr \ +@DDDMP_FALSE@ -I$(top_srcdir)/epd -I$(top_srcdir)/cudd -I$(top_srcdir)/st + +dddmp_testdddmp_SOURCES = dddmp/testdddmp.c +@DDDMP_FALSE@dddmp_testdddmp_CPPFLAGS = $(dddmp_libdddmp_la_CPPFLAGS) +@DDDMP_TRUE@dddmp_testdddmp_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +@DDDMP_FALSE@dddmp_testdddmp_LDADD = dddmp/libdddmp.la cudd/libcudd.la +@DDDMP_TRUE@dddmp_testdddmp_LDADD = cudd/libcudd.la +cplusplus_sources = cplusplus/cuddObj.hh cplusplus/cuddObj.cc +@OBJ_FALSE@cplusplus_libobj_la_SOURCES = $(cplusplus_sources) +@OBJ_FALSE@cplusplus_libobj_la_CPPFLAGS = -I$(top_srcdir)/cudd -I$(top_srcdir)/mtr \ +@OBJ_FALSE@ -I$(top_srcdir)/epd -I$(top_srcdir)/st + +cplusplus_testobj_SOURCES = cplusplus/testobj.cc +@OBJ_FALSE@cplusplus_testobj_CPPFLAGS = $(cplusplus_libobj_la_CPPFLAGS) +@OBJ_TRUE@cplusplus_testobj_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +@OBJ_FALSE@cplusplus_testobj_LDADD = cplusplus/libobj.la \ +@OBJ_FALSE@ cudd/libcudd.la +@OBJ_TRUE@cplusplus_testobj_LDADD = cudd/libcudd.la +cplusplus_testmulti_SOURCES = cplusplus/testmulti.cc +@OBJ_FALSE@cplusplus_testmulti_CPPFLAGS = $(cplusplus_libobj_la_CPPFLAGS) +@OBJ_TRUE@cplusplus_testmulti_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +@OBJ_FALSE@cplusplus_testmulti_LDADD = cplusplus/libobj.la \ +@OBJ_FALSE@ cudd/libcudd.la +@OBJ_TRUE@cplusplus_testmulti_LDADD = cudd/libcudd.la +@HAVE_PTHREADS_TRUE@cplusplus_testmulti_LDFLAGS = -pthread +nanotrav_nanotrav_SOURCES = nanotrav/bnet.h nanotrav/ntr.h \ + nanotrav/bnet.c nanotrav/chkMterm.c nanotrav/main.c nanotrav/ntrBddTest.c \ + nanotrav/ntr.c nanotrav/ntrHeap.c nanotrav/ntrMflow.c nanotrav/ntrShort.c \ + nanotrav/ntrZddTest.c + +nanotrav_nanotrav_CPPFLAGS = -I$(top_srcdir)/cudd -I$(top_srcdir)/mtr \ + -I$(top_srcdir)/epd -I$(top_srcdir)/st -I$(top_srcdir)/dddmp \ + -I$(top_srcdir)/util + +@DDDMP_FALSE@nanotrav_nanotrav_LDADD = dddmp/libdddmp.la \ +@DDDMP_FALSE@ cudd/libcudd.la +@DDDMP_TRUE@nanotrav_nanotrav_LDADD = cudd/libcudd.la +all: config.h + $(MAKE) $(AM_MAKEFLAGS) all-am + +.SUFFIXES: +.SUFFIXES: .c .cc .lo .log .o .obj .test .test$(EXEEXT) .trs +am--refresh: Makefile + @: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/cudd/Included.am $(top_srcdir)/util/Included.am $(top_srcdir)/st/Included.am $(top_srcdir)/epd/Included.am $(top_srcdir)/mtr/Included.am $(top_srcdir)/dddmp/Included.am $(top_srcdir)/cplusplus/Included.am $(top_srcdir)/nanotrav/Included.am $(top_srcdir)/doc/Included.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ + $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ + && exit 0; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + echo ' $(SHELL) ./config.status'; \ + $(SHELL) ./config.status;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ + esac; +$(top_srcdir)/cudd/Included.am $(top_srcdir)/util/Included.am $(top_srcdir)/st/Included.am $(top_srcdir)/epd/Included.am $(top_srcdir)/mtr/Included.am $(top_srcdir)/dddmp/Included.am $(top_srcdir)/cplusplus/Included.am $(top_srcdir)/nanotrav/Included.am $(top_srcdir)/doc/Included.am $(am__empty): + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + $(SHELL) ./config.status --recheck + +$(top_srcdir)/configure: $(am__configure_deps) + $(am__cd) $(srcdir) && $(AUTOCONF) +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) +$(am__aclocal_m4_deps): + +config.h: stamp-h1 + @test -f $@ || rm -f stamp-h1 + @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1 + +stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status + @rm -f stamp-h1 + cd $(top_builddir) && $(SHELL) ./config.status config.h +$(srcdir)/config.h.in: $(am__configure_deps) + ($(am__cd) $(top_srcdir) && $(AUTOHEADER)) + rm -f stamp-h1 + touch $@ + +distclean-hdr: + -rm -f config.h stamp-h1 +@HAVE_DOXYGEN_TRUE@Doxyfile: $(top_builddir)/config.status $(srcdir)/Doxyfile.in +@HAVE_DOXYGEN_TRUE@ cd $(top_builddir) && $(SHELL) ./config.status $@ +@HAVE_PDFLATEX_TRUE@doc/cudd.tex: $(top_builddir)/config.status $(top_srcdir)/doc/cudd.tex.in +@HAVE_PDFLATEX_TRUE@ cd $(top_builddir) && $(SHELL) ./config.status $@ +dddmp/exp/test1.sh: $(top_builddir)/config.status $(top_srcdir)/dddmp/exp/test1.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $@ +dddmp/exp/test2.sh: $(top_builddir)/config.status $(top_srcdir)/dddmp/exp/test2.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $@ +dddmp/exp/test3.sh: $(top_builddir)/config.status $(top_srcdir)/dddmp/exp/test3.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $@ +dddmp/exp/test4.sh: $(top_builddir)/config.status $(top_srcdir)/dddmp/exp/test4.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $@ +dddmp/exp/test5.sh: $(top_builddir)/config.status $(top_srcdir)/dddmp/exp/test5.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $@ +dddmp/exp/test6.sh: $(top_builddir)/config.status $(top_srcdir)/dddmp/exp/test6.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $@ +dddmp/exp/test7.sh: $(top_builddir)/config.status $(top_srcdir)/dddmp/exp/test7.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $@ + +install-libLTLIBRARIES: $(lib_LTLIBRARIES) + @$(NORMAL_INSTALL) + @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ + list2=; for p in $$list; do \ + if test -f $$p; then \ + list2="$$list2 $$p"; \ + else :; fi; \ + done; \ + test -z "$$list2" || { \ + echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ + echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ + $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ + } + +uninstall-libLTLIBRARIES: + @$(NORMAL_UNINSTALL) + @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ + for p in $$list; do \ + $(am__strip_dir) \ + echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ + $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ + done + +clean-libLTLIBRARIES: + -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) + @list='$(lib_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } + +clean-noinstLTLIBRARIES: + -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) + @list='$(noinst_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } +cplusplus/$(am__dirstamp): + @$(MKDIR_P) cplusplus + @: > cplusplus/$(am__dirstamp) +cplusplus/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) cplusplus/$(DEPDIR) + @: > cplusplus/$(DEPDIR)/$(am__dirstamp) +cplusplus/cplusplus_libobj_la-cuddObj.lo: cplusplus/$(am__dirstamp) \ + cplusplus/$(DEPDIR)/$(am__dirstamp) + +cplusplus/libobj.la: $(cplusplus_libobj_la_OBJECTS) $(cplusplus_libobj_la_DEPENDENCIES) $(EXTRA_cplusplus_libobj_la_DEPENDENCIES) cplusplus/$(am__dirstamp) + $(AM_V_CXXLD)$(CXXLINK) $(am_cplusplus_libobj_la_rpath) $(cplusplus_libobj_la_OBJECTS) $(cplusplus_libobj_la_LIBADD) $(LIBS) +cudd/$(am__dirstamp): + @$(MKDIR_P) cudd + @: > cudd/$(am__dirstamp) +cudd/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) cudd/$(DEPDIR) + @: > cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddAddAbs.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddAddApply.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddAddFind.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddAddInv.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddAddIte.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddAddNeg.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddAddWalsh.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddAndAbs.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddAnneal.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddApa.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddAPI.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddApprox.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddBddAbs.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddBddCorr.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddBddIte.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddBridge.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddCache.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddCheck.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddClip.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddCof.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddCompose.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddDecomp.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddEssent.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddExact.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddExport.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddGenCof.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddGenetic.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddGroup.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddHarwell.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddInit.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddInteract.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddLCache.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddLevelQ.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddLinear.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddLiteral.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddMatMult.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddPriority.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddRead.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddRef.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddReorder.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddSat.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddSign.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddSolve.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddSplit.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddSubsetHB.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddSubsetSP.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddSymmetry.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddTable.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddUtil.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddWindow.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddZddCount.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddZddFuncs.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddZddGroup.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddZddIsop.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddZddLin.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddZddMisc.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddZddPort.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddZddReord.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddZddSetop.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddZddSymm.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +cudd/cudd_libcudd_la-cuddZddUtil.lo: cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) +util/$(am__dirstamp): + @$(MKDIR_P) util + @: > util/$(am__dirstamp) +util/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) util/$(DEPDIR) + @: > util/$(DEPDIR)/$(am__dirstamp) +util/cudd_libcudd_la-cpu_stats.lo: util/$(am__dirstamp) \ + util/$(DEPDIR)/$(am__dirstamp) +util/cudd_libcudd_la-cpu_time.lo: util/$(am__dirstamp) \ + util/$(DEPDIR)/$(am__dirstamp) +util/cudd_libcudd_la-cstringstream.lo: util/$(am__dirstamp) \ + util/$(DEPDIR)/$(am__dirstamp) +util/cudd_libcudd_la-datalimit.lo: util/$(am__dirstamp) \ + util/$(DEPDIR)/$(am__dirstamp) +util/cudd_libcudd_la-pathsearch.lo: util/$(am__dirstamp) \ + util/$(DEPDIR)/$(am__dirstamp) +util/cudd_libcudd_la-pipefork.lo: util/$(am__dirstamp) \ + util/$(DEPDIR)/$(am__dirstamp) +util/cudd_libcudd_la-prtime.lo: util/$(am__dirstamp) \ + util/$(DEPDIR)/$(am__dirstamp) +util/cudd_libcudd_la-safe_mem.lo: util/$(am__dirstamp) \ + util/$(DEPDIR)/$(am__dirstamp) +util/cudd_libcudd_la-strsav.lo: util/$(am__dirstamp) \ + util/$(DEPDIR)/$(am__dirstamp) +util/cudd_libcudd_la-texpand.lo: util/$(am__dirstamp) \ + util/$(DEPDIR)/$(am__dirstamp) +util/cudd_libcudd_la-ucbqsort.lo: util/$(am__dirstamp) \ + util/$(DEPDIR)/$(am__dirstamp) +st/$(am__dirstamp): + @$(MKDIR_P) st + @: > st/$(am__dirstamp) +st/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) st/$(DEPDIR) + @: > st/$(DEPDIR)/$(am__dirstamp) +st/cudd_libcudd_la-st.lo: st/$(am__dirstamp) \ + st/$(DEPDIR)/$(am__dirstamp) +epd/$(am__dirstamp): + @$(MKDIR_P) epd + @: > epd/$(am__dirstamp) +epd/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) epd/$(DEPDIR) + @: > epd/$(DEPDIR)/$(am__dirstamp) +epd/cudd_libcudd_la-epd.lo: epd/$(am__dirstamp) \ + epd/$(DEPDIR)/$(am__dirstamp) +mtr/$(am__dirstamp): + @$(MKDIR_P) mtr + @: > mtr/$(am__dirstamp) +mtr/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) mtr/$(DEPDIR) + @: > mtr/$(DEPDIR)/$(am__dirstamp) +mtr/cudd_libcudd_la-mtrBasic.lo: mtr/$(am__dirstamp) \ + mtr/$(DEPDIR)/$(am__dirstamp) +mtr/cudd_libcudd_la-mtrGroup.lo: mtr/$(am__dirstamp) \ + mtr/$(DEPDIR)/$(am__dirstamp) +dddmp/$(am__dirstamp): + @$(MKDIR_P) dddmp + @: > dddmp/$(am__dirstamp) +dddmp/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) dddmp/$(DEPDIR) + @: > dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpBinary.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpConvert.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpDbg.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpLoad.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpLoadCnf.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpNodeAdd.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpNodeBdd.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpNodeCnf.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpStoreAdd.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpStoreBdd.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpStoreCnf.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpStoreMisc.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/cudd_libcudd_la-dddmpUtil.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +cplusplus/cudd_libcudd_la-cuddObj.lo: cplusplus/$(am__dirstamp) \ + cplusplus/$(DEPDIR)/$(am__dirstamp) + +cudd/libcudd.la: $(cudd_libcudd_la_OBJECTS) $(cudd_libcudd_la_DEPENDENCIES) $(EXTRA_cudd_libcudd_la_DEPENDENCIES) cudd/$(am__dirstamp) + $(AM_V_CXXLD)$(cudd_libcudd_la_LINK) -rpath $(libdir) $(cudd_libcudd_la_OBJECTS) $(cudd_libcudd_la_LIBADD) $(LIBS) +dddmp/dddmp_libdddmp_la-dddmpBinary.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpConvert.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpDbg.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpLoad.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpLoadCnf.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpNodeAdd.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpNodeBdd.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpNodeCnf.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpStoreAdd.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpStoreBdd.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpStoreCnf.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpStoreMisc.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) +dddmp/dddmp_libdddmp_la-dddmpUtil.lo: dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) + +dddmp/libdddmp.la: $(dddmp_libdddmp_la_OBJECTS) $(dddmp_libdddmp_la_DEPENDENCIES) $(EXTRA_dddmp_libdddmp_la_DEPENDENCIES) dddmp/$(am__dirstamp) + $(AM_V_CCLD)$(LINK) $(am_dddmp_libdddmp_la_rpath) $(dddmp_libdddmp_la_OBJECTS) $(dddmp_libdddmp_la_LIBADD) $(LIBS) + +clean-checkPROGRAMS: + @list='$(check_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +cplusplus/cplusplus_testmulti-testmulti.$(OBJEXT): \ + cplusplus/$(am__dirstamp) cplusplus/$(DEPDIR)/$(am__dirstamp) + +cplusplus/testmulti$(EXEEXT): $(cplusplus_testmulti_OBJECTS) $(cplusplus_testmulti_DEPENDENCIES) $(EXTRA_cplusplus_testmulti_DEPENDENCIES) cplusplus/$(am__dirstamp) + @rm -f cplusplus/testmulti$(EXEEXT) + $(AM_V_CXXLD)$(cplusplus_testmulti_LINK) $(cplusplus_testmulti_OBJECTS) $(cplusplus_testmulti_LDADD) $(LIBS) +cplusplus/cplusplus_testobj-testobj.$(OBJEXT): \ + cplusplus/$(am__dirstamp) cplusplus/$(DEPDIR)/$(am__dirstamp) + +cplusplus/testobj$(EXEEXT): $(cplusplus_testobj_OBJECTS) $(cplusplus_testobj_DEPENDENCIES) $(EXTRA_cplusplus_testobj_DEPENDENCIES) cplusplus/$(am__dirstamp) + @rm -f cplusplus/testobj$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(cplusplus_testobj_OBJECTS) $(cplusplus_testobj_LDADD) $(LIBS) +cudd/cudd_testcudd-testcudd.$(OBJEXT): cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) + +cudd/testcudd$(EXEEXT): $(cudd_testcudd_OBJECTS) $(cudd_testcudd_DEPENDENCIES) $(EXTRA_cudd_testcudd_DEPENDENCIES) cudd/$(am__dirstamp) + @rm -f cudd/testcudd$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(cudd_testcudd_OBJECTS) $(cudd_testcudd_LDADD) $(LIBS) +cudd/cudd_testextra-testextra.$(OBJEXT): cudd/$(am__dirstamp) \ + cudd/$(DEPDIR)/$(am__dirstamp) + +cudd/testextra$(EXEEXT): $(cudd_testextra_OBJECTS) $(cudd_testextra_DEPENDENCIES) $(EXTRA_cudd_testextra_DEPENDENCIES) cudd/$(am__dirstamp) + @rm -f cudd/testextra$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(cudd_testextra_OBJECTS) $(cudd_testextra_LDADD) $(LIBS) +dddmp/dddmp_testdddmp-testdddmp.$(OBJEXT): dddmp/$(am__dirstamp) \ + dddmp/$(DEPDIR)/$(am__dirstamp) + +dddmp/testdddmp$(EXEEXT): $(dddmp_testdddmp_OBJECTS) $(dddmp_testdddmp_DEPENDENCIES) $(EXTRA_dddmp_testdddmp_DEPENDENCIES) dddmp/$(am__dirstamp) + @rm -f dddmp/testdddmp$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(dddmp_testdddmp_OBJECTS) $(dddmp_testdddmp_LDADD) $(LIBS) +mtr/mtr_testmtr-testmtr.$(OBJEXT): mtr/$(am__dirstamp) \ + mtr/$(DEPDIR)/$(am__dirstamp) + +mtr/testmtr$(EXEEXT): $(mtr_testmtr_OBJECTS) $(mtr_testmtr_DEPENDENCIES) $(EXTRA_mtr_testmtr_DEPENDENCIES) mtr/$(am__dirstamp) + @rm -f mtr/testmtr$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(mtr_testmtr_OBJECTS) $(mtr_testmtr_LDADD) $(LIBS) +nanotrav/$(am__dirstamp): + @$(MKDIR_P) nanotrav + @: > nanotrav/$(am__dirstamp) +nanotrav/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) nanotrav/$(DEPDIR) + @: > nanotrav/$(DEPDIR)/$(am__dirstamp) +nanotrav/nanotrav_nanotrav-bnet.$(OBJEXT): nanotrav/$(am__dirstamp) \ + nanotrav/$(DEPDIR)/$(am__dirstamp) +nanotrav/nanotrav_nanotrav-chkMterm.$(OBJEXT): \ + nanotrav/$(am__dirstamp) nanotrav/$(DEPDIR)/$(am__dirstamp) +nanotrav/nanotrav_nanotrav-main.$(OBJEXT): nanotrav/$(am__dirstamp) \ + nanotrav/$(DEPDIR)/$(am__dirstamp) +nanotrav/nanotrav_nanotrav-ntrBddTest.$(OBJEXT): \ + nanotrav/$(am__dirstamp) nanotrav/$(DEPDIR)/$(am__dirstamp) +nanotrav/nanotrav_nanotrav-ntr.$(OBJEXT): nanotrav/$(am__dirstamp) \ + nanotrav/$(DEPDIR)/$(am__dirstamp) +nanotrav/nanotrav_nanotrav-ntrHeap.$(OBJEXT): \ + nanotrav/$(am__dirstamp) nanotrav/$(DEPDIR)/$(am__dirstamp) +nanotrav/nanotrav_nanotrav-ntrMflow.$(OBJEXT): \ + nanotrav/$(am__dirstamp) nanotrav/$(DEPDIR)/$(am__dirstamp) +nanotrav/nanotrav_nanotrav-ntrShort.$(OBJEXT): \ + nanotrav/$(am__dirstamp) nanotrav/$(DEPDIR)/$(am__dirstamp) +nanotrav/nanotrav_nanotrav-ntrZddTest.$(OBJEXT): \ + nanotrav/$(am__dirstamp) nanotrav/$(DEPDIR)/$(am__dirstamp) + +nanotrav/nanotrav$(EXEEXT): $(nanotrav_nanotrav_OBJECTS) $(nanotrav_nanotrav_DEPENDENCIES) $(EXTRA_nanotrav_nanotrav_DEPENDENCIES) nanotrav/$(am__dirstamp) + @rm -f nanotrav/nanotrav$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(nanotrav_nanotrav_OBJECTS) $(nanotrav_nanotrav_LDADD) $(LIBS) +st/st_testst-testst.$(OBJEXT): st/$(am__dirstamp) \ + st/$(DEPDIR)/$(am__dirstamp) + +st/testst$(EXEEXT): $(st_testst_OBJECTS) $(st_testst_DEPENDENCIES) $(EXTRA_st_testst_DEPENDENCIES) st/$(am__dirstamp) + @rm -f st/testst$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(st_testst_OBJECTS) $(st_testst_LDADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + -rm -f cplusplus/*.$(OBJEXT) + -rm -f cplusplus/*.lo + -rm -f cudd/*.$(OBJEXT) + -rm -f cudd/*.lo + -rm -f dddmp/*.$(OBJEXT) + -rm -f dddmp/*.lo + -rm -f epd/*.$(OBJEXT) + -rm -f epd/*.lo + -rm -f mtr/*.$(OBJEXT) + -rm -f mtr/*.lo + -rm -f nanotrav/*.$(OBJEXT) + -rm -f st/*.$(OBJEXT) + -rm -f st/*.lo + -rm -f util/*.$(OBJEXT) + -rm -f util/*.lo + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@cplusplus/$(DEPDIR)/cplusplus_libobj_la-cuddObj.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cplusplus/$(DEPDIR)/cplusplus_testmulti-testmulti.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cplusplus/$(DEPDIR)/cplusplus_testobj-testobj.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cplusplus/$(DEPDIR)/cudd_libcudd_la-cuddObj.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddAPI.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddAbs.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddApply.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddFind.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddInv.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddIte.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddNeg.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddWalsh.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddAndAbs.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddAnneal.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddApa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddApprox.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddAbs.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddCorr.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddIte.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddBridge.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddCache.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddCheck.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddClip.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddCof.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddCompose.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddDecomp.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddEssent.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddExact.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddExport.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddGenCof.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddGenetic.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddGroup.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddHarwell.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddInit.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddInteract.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddLCache.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddLevelQ.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddLinear.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddLiteral.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddMatMult.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddPriority.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddRead.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddRef.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddReorder.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddSat.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddSign.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddSolve.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddSplit.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddSubsetHB.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddSubsetSP.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddSymmetry.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddTable.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddUtil.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddWindow.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddCount.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddFuncs.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddGroup.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddIsop.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddLin.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddMisc.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddPort.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddReord.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddSetop.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddSymm.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddUtil.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_testcudd-testcudd.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@cudd/$(DEPDIR)/cudd_testextra-testextra.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpBinary.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpConvert.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpDbg.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpLoad.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpLoadCnf.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeAdd.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeBdd.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeCnf.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreAdd.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreBdd.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreCnf.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreMisc.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpUtil.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpBinary.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpConvert.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpDbg.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpLoad.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpLoadCnf.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeAdd.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeBdd.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeCnf.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreAdd.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreBdd.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreCnf.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreMisc.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpUtil.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@dddmp/$(DEPDIR)/dddmp_testdddmp-testdddmp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@epd/$(DEPDIR)/cudd_libcudd_la-epd.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@mtr/$(DEPDIR)/cudd_libcudd_la-mtrBasic.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@mtr/$(DEPDIR)/cudd_libcudd_la-mtrGroup.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@mtr/$(DEPDIR)/mtr_testmtr-testmtr.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@nanotrav/$(DEPDIR)/nanotrav_nanotrav-bnet.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@nanotrav/$(DEPDIR)/nanotrav_nanotrav-chkMterm.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@nanotrav/$(DEPDIR)/nanotrav_nanotrav-main.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntr.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrBddTest.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrHeap.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrMflow.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrShort.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrZddTest.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@st/$(DEPDIR)/cudd_libcudd_la-st.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@st/$(DEPDIR)/st_testst-testst.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@util/$(DEPDIR)/cudd_libcudd_la-cpu_stats.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@util/$(DEPDIR)/cudd_libcudd_la-cpu_time.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@util/$(DEPDIR)/cudd_libcudd_la-cstringstream.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@util/$(DEPDIR)/cudd_libcudd_la-datalimit.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@util/$(DEPDIR)/cudd_libcudd_la-pathsearch.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@util/$(DEPDIR)/cudd_libcudd_la-pipefork.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@util/$(DEPDIR)/cudd_libcudd_la-prtime.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@util/$(DEPDIR)/cudd_libcudd_la-safe_mem.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@util/$(DEPDIR)/cudd_libcudd_la-strsav.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@util/$(DEPDIR)/cudd_libcudd_la-texpand.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@util/$(DEPDIR)/cudd_libcudd_la-ucbqsort.Plo@am__quote@ + +.c.o: +@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ +@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ +@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< + +.c.obj: +@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\ +@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\ +@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.c.lo: +@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\ +@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ +@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< + +cudd/cudd_libcudd_la-cuddAddAbs.lo: cudd/cuddAddAbs.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddAddAbs.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddAbs.Tpo -c -o cudd/cudd_libcudd_la-cuddAddAbs.lo `test -f 'cudd/cuddAddAbs.c' || echo '$(srcdir)/'`cudd/cuddAddAbs.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddAbs.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddAbs.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddAddAbs.c' object='cudd/cudd_libcudd_la-cuddAddAbs.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddAddAbs.lo `test -f 'cudd/cuddAddAbs.c' || echo '$(srcdir)/'`cudd/cuddAddAbs.c + +cudd/cudd_libcudd_la-cuddAddApply.lo: cudd/cuddAddApply.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddAddApply.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddApply.Tpo -c -o cudd/cudd_libcudd_la-cuddAddApply.lo `test -f 'cudd/cuddAddApply.c' || echo '$(srcdir)/'`cudd/cuddAddApply.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddApply.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddApply.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddAddApply.c' object='cudd/cudd_libcudd_la-cuddAddApply.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddAddApply.lo `test -f 'cudd/cuddAddApply.c' || echo '$(srcdir)/'`cudd/cuddAddApply.c + +cudd/cudd_libcudd_la-cuddAddFind.lo: cudd/cuddAddFind.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddAddFind.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddFind.Tpo -c -o cudd/cudd_libcudd_la-cuddAddFind.lo `test -f 'cudd/cuddAddFind.c' || echo '$(srcdir)/'`cudd/cuddAddFind.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddFind.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddFind.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddAddFind.c' object='cudd/cudd_libcudd_la-cuddAddFind.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddAddFind.lo `test -f 'cudd/cuddAddFind.c' || echo '$(srcdir)/'`cudd/cuddAddFind.c + +cudd/cudd_libcudd_la-cuddAddInv.lo: cudd/cuddAddInv.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddAddInv.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddInv.Tpo -c -o cudd/cudd_libcudd_la-cuddAddInv.lo `test -f 'cudd/cuddAddInv.c' || echo '$(srcdir)/'`cudd/cuddAddInv.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddInv.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddInv.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddAddInv.c' object='cudd/cudd_libcudd_la-cuddAddInv.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddAddInv.lo `test -f 'cudd/cuddAddInv.c' || echo '$(srcdir)/'`cudd/cuddAddInv.c + +cudd/cudd_libcudd_la-cuddAddIte.lo: cudd/cuddAddIte.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddAddIte.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddIte.Tpo -c -o cudd/cudd_libcudd_la-cuddAddIte.lo `test -f 'cudd/cuddAddIte.c' || echo '$(srcdir)/'`cudd/cuddAddIte.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddIte.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddIte.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddAddIte.c' object='cudd/cudd_libcudd_la-cuddAddIte.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddAddIte.lo `test -f 'cudd/cuddAddIte.c' || echo '$(srcdir)/'`cudd/cuddAddIte.c + +cudd/cudd_libcudd_la-cuddAddNeg.lo: cudd/cuddAddNeg.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddAddNeg.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddNeg.Tpo -c -o cudd/cudd_libcudd_la-cuddAddNeg.lo `test -f 'cudd/cuddAddNeg.c' || echo '$(srcdir)/'`cudd/cuddAddNeg.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddNeg.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddNeg.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddAddNeg.c' object='cudd/cudd_libcudd_la-cuddAddNeg.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddAddNeg.lo `test -f 'cudd/cuddAddNeg.c' || echo '$(srcdir)/'`cudd/cuddAddNeg.c + +cudd/cudd_libcudd_la-cuddAddWalsh.lo: cudd/cuddAddWalsh.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddAddWalsh.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddWalsh.Tpo -c -o cudd/cudd_libcudd_la-cuddAddWalsh.lo `test -f 'cudd/cuddAddWalsh.c' || echo '$(srcdir)/'`cudd/cuddAddWalsh.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddWalsh.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddAddWalsh.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddAddWalsh.c' object='cudd/cudd_libcudd_la-cuddAddWalsh.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddAddWalsh.lo `test -f 'cudd/cuddAddWalsh.c' || echo '$(srcdir)/'`cudd/cuddAddWalsh.c + +cudd/cudd_libcudd_la-cuddAndAbs.lo: cudd/cuddAndAbs.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddAndAbs.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddAndAbs.Tpo -c -o cudd/cudd_libcudd_la-cuddAndAbs.lo `test -f 'cudd/cuddAndAbs.c' || echo '$(srcdir)/'`cudd/cuddAndAbs.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddAndAbs.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddAndAbs.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddAndAbs.c' object='cudd/cudd_libcudd_la-cuddAndAbs.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddAndAbs.lo `test -f 'cudd/cuddAndAbs.c' || echo '$(srcdir)/'`cudd/cuddAndAbs.c + +cudd/cudd_libcudd_la-cuddAnneal.lo: cudd/cuddAnneal.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddAnneal.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddAnneal.Tpo -c -o cudd/cudd_libcudd_la-cuddAnneal.lo `test -f 'cudd/cuddAnneal.c' || echo '$(srcdir)/'`cudd/cuddAnneal.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddAnneal.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddAnneal.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddAnneal.c' object='cudd/cudd_libcudd_la-cuddAnneal.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddAnneal.lo `test -f 'cudd/cuddAnneal.c' || echo '$(srcdir)/'`cudd/cuddAnneal.c + +cudd/cudd_libcudd_la-cuddApa.lo: cudd/cuddApa.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddApa.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddApa.Tpo -c -o cudd/cudd_libcudd_la-cuddApa.lo `test -f 'cudd/cuddApa.c' || echo '$(srcdir)/'`cudd/cuddApa.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddApa.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddApa.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddApa.c' object='cudd/cudd_libcudd_la-cuddApa.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddApa.lo `test -f 'cudd/cuddApa.c' || echo '$(srcdir)/'`cudd/cuddApa.c + +cudd/cudd_libcudd_la-cuddAPI.lo: cudd/cuddAPI.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddAPI.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddAPI.Tpo -c -o cudd/cudd_libcudd_la-cuddAPI.lo `test -f 'cudd/cuddAPI.c' || echo '$(srcdir)/'`cudd/cuddAPI.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddAPI.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddAPI.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddAPI.c' object='cudd/cudd_libcudd_la-cuddAPI.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddAPI.lo `test -f 'cudd/cuddAPI.c' || echo '$(srcdir)/'`cudd/cuddAPI.c + +cudd/cudd_libcudd_la-cuddApprox.lo: cudd/cuddApprox.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddApprox.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddApprox.Tpo -c -o cudd/cudd_libcudd_la-cuddApprox.lo `test -f 'cudd/cuddApprox.c' || echo '$(srcdir)/'`cudd/cuddApprox.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddApprox.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddApprox.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddApprox.c' object='cudd/cudd_libcudd_la-cuddApprox.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddApprox.lo `test -f 'cudd/cuddApprox.c' || echo '$(srcdir)/'`cudd/cuddApprox.c + +cudd/cudd_libcudd_la-cuddBddAbs.lo: cudd/cuddBddAbs.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddBddAbs.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddAbs.Tpo -c -o cudd/cudd_libcudd_la-cuddBddAbs.lo `test -f 'cudd/cuddBddAbs.c' || echo '$(srcdir)/'`cudd/cuddBddAbs.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddAbs.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddAbs.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddBddAbs.c' object='cudd/cudd_libcudd_la-cuddBddAbs.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddBddAbs.lo `test -f 'cudd/cuddBddAbs.c' || echo '$(srcdir)/'`cudd/cuddBddAbs.c + +cudd/cudd_libcudd_la-cuddBddCorr.lo: cudd/cuddBddCorr.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddBddCorr.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddCorr.Tpo -c -o cudd/cudd_libcudd_la-cuddBddCorr.lo `test -f 'cudd/cuddBddCorr.c' || echo '$(srcdir)/'`cudd/cuddBddCorr.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddCorr.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddCorr.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddBddCorr.c' object='cudd/cudd_libcudd_la-cuddBddCorr.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddBddCorr.lo `test -f 'cudd/cuddBddCorr.c' || echo '$(srcdir)/'`cudd/cuddBddCorr.c + +cudd/cudd_libcudd_la-cuddBddIte.lo: cudd/cuddBddIte.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddBddIte.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddIte.Tpo -c -o cudd/cudd_libcudd_la-cuddBddIte.lo `test -f 'cudd/cuddBddIte.c' || echo '$(srcdir)/'`cudd/cuddBddIte.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddIte.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddBddIte.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddBddIte.c' object='cudd/cudd_libcudd_la-cuddBddIte.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddBddIte.lo `test -f 'cudd/cuddBddIte.c' || echo '$(srcdir)/'`cudd/cuddBddIte.c + +cudd/cudd_libcudd_la-cuddBridge.lo: cudd/cuddBridge.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddBridge.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddBridge.Tpo -c -o cudd/cudd_libcudd_la-cuddBridge.lo `test -f 'cudd/cuddBridge.c' || echo '$(srcdir)/'`cudd/cuddBridge.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddBridge.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddBridge.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddBridge.c' object='cudd/cudd_libcudd_la-cuddBridge.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddBridge.lo `test -f 'cudd/cuddBridge.c' || echo '$(srcdir)/'`cudd/cuddBridge.c + +cudd/cudd_libcudd_la-cuddCache.lo: cudd/cuddCache.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddCache.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddCache.Tpo -c -o cudd/cudd_libcudd_la-cuddCache.lo `test -f 'cudd/cuddCache.c' || echo '$(srcdir)/'`cudd/cuddCache.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddCache.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddCache.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddCache.c' object='cudd/cudd_libcudd_la-cuddCache.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddCache.lo `test -f 'cudd/cuddCache.c' || echo '$(srcdir)/'`cudd/cuddCache.c + +cudd/cudd_libcudd_la-cuddCheck.lo: cudd/cuddCheck.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddCheck.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddCheck.Tpo -c -o cudd/cudd_libcudd_la-cuddCheck.lo `test -f 'cudd/cuddCheck.c' || echo '$(srcdir)/'`cudd/cuddCheck.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddCheck.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddCheck.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddCheck.c' object='cudd/cudd_libcudd_la-cuddCheck.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddCheck.lo `test -f 'cudd/cuddCheck.c' || echo '$(srcdir)/'`cudd/cuddCheck.c + +cudd/cudd_libcudd_la-cuddClip.lo: cudd/cuddClip.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddClip.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddClip.Tpo -c -o cudd/cudd_libcudd_la-cuddClip.lo `test -f 'cudd/cuddClip.c' || echo '$(srcdir)/'`cudd/cuddClip.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddClip.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddClip.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddClip.c' object='cudd/cudd_libcudd_la-cuddClip.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddClip.lo `test -f 'cudd/cuddClip.c' || echo '$(srcdir)/'`cudd/cuddClip.c + +cudd/cudd_libcudd_la-cuddCof.lo: cudd/cuddCof.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddCof.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddCof.Tpo -c -o cudd/cudd_libcudd_la-cuddCof.lo `test -f 'cudd/cuddCof.c' || echo '$(srcdir)/'`cudd/cuddCof.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddCof.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddCof.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddCof.c' object='cudd/cudd_libcudd_la-cuddCof.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddCof.lo `test -f 'cudd/cuddCof.c' || echo '$(srcdir)/'`cudd/cuddCof.c + +cudd/cudd_libcudd_la-cuddCompose.lo: cudd/cuddCompose.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddCompose.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddCompose.Tpo -c -o cudd/cudd_libcudd_la-cuddCompose.lo `test -f 'cudd/cuddCompose.c' || echo '$(srcdir)/'`cudd/cuddCompose.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddCompose.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddCompose.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddCompose.c' object='cudd/cudd_libcudd_la-cuddCompose.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddCompose.lo `test -f 'cudd/cuddCompose.c' || echo '$(srcdir)/'`cudd/cuddCompose.c + +cudd/cudd_libcudd_la-cuddDecomp.lo: cudd/cuddDecomp.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddDecomp.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddDecomp.Tpo -c -o cudd/cudd_libcudd_la-cuddDecomp.lo `test -f 'cudd/cuddDecomp.c' || echo '$(srcdir)/'`cudd/cuddDecomp.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddDecomp.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddDecomp.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddDecomp.c' object='cudd/cudd_libcudd_la-cuddDecomp.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddDecomp.lo `test -f 'cudd/cuddDecomp.c' || echo '$(srcdir)/'`cudd/cuddDecomp.c + +cudd/cudd_libcudd_la-cuddEssent.lo: cudd/cuddEssent.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddEssent.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddEssent.Tpo -c -o cudd/cudd_libcudd_la-cuddEssent.lo `test -f 'cudd/cuddEssent.c' || echo '$(srcdir)/'`cudd/cuddEssent.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddEssent.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddEssent.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddEssent.c' object='cudd/cudd_libcudd_la-cuddEssent.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddEssent.lo `test -f 'cudd/cuddEssent.c' || echo '$(srcdir)/'`cudd/cuddEssent.c + +cudd/cudd_libcudd_la-cuddExact.lo: cudd/cuddExact.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddExact.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddExact.Tpo -c -o cudd/cudd_libcudd_la-cuddExact.lo `test -f 'cudd/cuddExact.c' || echo '$(srcdir)/'`cudd/cuddExact.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddExact.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddExact.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddExact.c' object='cudd/cudd_libcudd_la-cuddExact.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddExact.lo `test -f 'cudd/cuddExact.c' || echo '$(srcdir)/'`cudd/cuddExact.c + +cudd/cudd_libcudd_la-cuddExport.lo: cudd/cuddExport.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddExport.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddExport.Tpo -c -o cudd/cudd_libcudd_la-cuddExport.lo `test -f 'cudd/cuddExport.c' || echo '$(srcdir)/'`cudd/cuddExport.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddExport.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddExport.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddExport.c' object='cudd/cudd_libcudd_la-cuddExport.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddExport.lo `test -f 'cudd/cuddExport.c' || echo '$(srcdir)/'`cudd/cuddExport.c + +cudd/cudd_libcudd_la-cuddGenCof.lo: cudd/cuddGenCof.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddGenCof.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddGenCof.Tpo -c -o cudd/cudd_libcudd_la-cuddGenCof.lo `test -f 'cudd/cuddGenCof.c' || echo '$(srcdir)/'`cudd/cuddGenCof.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddGenCof.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddGenCof.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddGenCof.c' object='cudd/cudd_libcudd_la-cuddGenCof.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddGenCof.lo `test -f 'cudd/cuddGenCof.c' || echo '$(srcdir)/'`cudd/cuddGenCof.c + +cudd/cudd_libcudd_la-cuddGenetic.lo: cudd/cuddGenetic.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddGenetic.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddGenetic.Tpo -c -o cudd/cudd_libcudd_la-cuddGenetic.lo `test -f 'cudd/cuddGenetic.c' || echo '$(srcdir)/'`cudd/cuddGenetic.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddGenetic.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddGenetic.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddGenetic.c' object='cudd/cudd_libcudd_la-cuddGenetic.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddGenetic.lo `test -f 'cudd/cuddGenetic.c' || echo '$(srcdir)/'`cudd/cuddGenetic.c + +cudd/cudd_libcudd_la-cuddGroup.lo: cudd/cuddGroup.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddGroup.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddGroup.Tpo -c -o cudd/cudd_libcudd_la-cuddGroup.lo `test -f 'cudd/cuddGroup.c' || echo '$(srcdir)/'`cudd/cuddGroup.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddGroup.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddGroup.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddGroup.c' object='cudd/cudd_libcudd_la-cuddGroup.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddGroup.lo `test -f 'cudd/cuddGroup.c' || echo '$(srcdir)/'`cudd/cuddGroup.c + +cudd/cudd_libcudd_la-cuddHarwell.lo: cudd/cuddHarwell.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddHarwell.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddHarwell.Tpo -c -o cudd/cudd_libcudd_la-cuddHarwell.lo `test -f 'cudd/cuddHarwell.c' || echo '$(srcdir)/'`cudd/cuddHarwell.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddHarwell.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddHarwell.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddHarwell.c' object='cudd/cudd_libcudd_la-cuddHarwell.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddHarwell.lo `test -f 'cudd/cuddHarwell.c' || echo '$(srcdir)/'`cudd/cuddHarwell.c + +cudd/cudd_libcudd_la-cuddInit.lo: cudd/cuddInit.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddInit.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddInit.Tpo -c -o cudd/cudd_libcudd_la-cuddInit.lo `test -f 'cudd/cuddInit.c' || echo '$(srcdir)/'`cudd/cuddInit.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddInit.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddInit.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddInit.c' object='cudd/cudd_libcudd_la-cuddInit.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddInit.lo `test -f 'cudd/cuddInit.c' || echo '$(srcdir)/'`cudd/cuddInit.c + +cudd/cudd_libcudd_la-cuddInteract.lo: cudd/cuddInteract.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddInteract.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddInteract.Tpo -c -o cudd/cudd_libcudd_la-cuddInteract.lo `test -f 'cudd/cuddInteract.c' || echo '$(srcdir)/'`cudd/cuddInteract.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddInteract.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddInteract.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddInteract.c' object='cudd/cudd_libcudd_la-cuddInteract.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddInteract.lo `test -f 'cudd/cuddInteract.c' || echo '$(srcdir)/'`cudd/cuddInteract.c + +cudd/cudd_libcudd_la-cuddLCache.lo: cudd/cuddLCache.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddLCache.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddLCache.Tpo -c -o cudd/cudd_libcudd_la-cuddLCache.lo `test -f 'cudd/cuddLCache.c' || echo '$(srcdir)/'`cudd/cuddLCache.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddLCache.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddLCache.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddLCache.c' object='cudd/cudd_libcudd_la-cuddLCache.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddLCache.lo `test -f 'cudd/cuddLCache.c' || echo '$(srcdir)/'`cudd/cuddLCache.c + +cudd/cudd_libcudd_la-cuddLevelQ.lo: cudd/cuddLevelQ.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddLevelQ.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddLevelQ.Tpo -c -o cudd/cudd_libcudd_la-cuddLevelQ.lo `test -f 'cudd/cuddLevelQ.c' || echo '$(srcdir)/'`cudd/cuddLevelQ.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddLevelQ.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddLevelQ.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddLevelQ.c' object='cudd/cudd_libcudd_la-cuddLevelQ.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddLevelQ.lo `test -f 'cudd/cuddLevelQ.c' || echo '$(srcdir)/'`cudd/cuddLevelQ.c + +cudd/cudd_libcudd_la-cuddLinear.lo: cudd/cuddLinear.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddLinear.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddLinear.Tpo -c -o cudd/cudd_libcudd_la-cuddLinear.lo `test -f 'cudd/cuddLinear.c' || echo '$(srcdir)/'`cudd/cuddLinear.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddLinear.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddLinear.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddLinear.c' object='cudd/cudd_libcudd_la-cuddLinear.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddLinear.lo `test -f 'cudd/cuddLinear.c' || echo '$(srcdir)/'`cudd/cuddLinear.c + +cudd/cudd_libcudd_la-cuddLiteral.lo: cudd/cuddLiteral.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddLiteral.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddLiteral.Tpo -c -o cudd/cudd_libcudd_la-cuddLiteral.lo `test -f 'cudd/cuddLiteral.c' || echo '$(srcdir)/'`cudd/cuddLiteral.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddLiteral.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddLiteral.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddLiteral.c' object='cudd/cudd_libcudd_la-cuddLiteral.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddLiteral.lo `test -f 'cudd/cuddLiteral.c' || echo '$(srcdir)/'`cudd/cuddLiteral.c + +cudd/cudd_libcudd_la-cuddMatMult.lo: cudd/cuddMatMult.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddMatMult.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddMatMult.Tpo -c -o cudd/cudd_libcudd_la-cuddMatMult.lo `test -f 'cudd/cuddMatMult.c' || echo '$(srcdir)/'`cudd/cuddMatMult.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddMatMult.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddMatMult.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddMatMult.c' object='cudd/cudd_libcudd_la-cuddMatMult.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddMatMult.lo `test -f 'cudd/cuddMatMult.c' || echo '$(srcdir)/'`cudd/cuddMatMult.c + +cudd/cudd_libcudd_la-cuddPriority.lo: cudd/cuddPriority.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddPriority.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddPriority.Tpo -c -o cudd/cudd_libcudd_la-cuddPriority.lo `test -f 'cudd/cuddPriority.c' || echo '$(srcdir)/'`cudd/cuddPriority.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddPriority.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddPriority.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddPriority.c' object='cudd/cudd_libcudd_la-cuddPriority.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddPriority.lo `test -f 'cudd/cuddPriority.c' || echo '$(srcdir)/'`cudd/cuddPriority.c + +cudd/cudd_libcudd_la-cuddRead.lo: cudd/cuddRead.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddRead.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddRead.Tpo -c -o cudd/cudd_libcudd_la-cuddRead.lo `test -f 'cudd/cuddRead.c' || echo '$(srcdir)/'`cudd/cuddRead.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddRead.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddRead.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddRead.c' object='cudd/cudd_libcudd_la-cuddRead.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddRead.lo `test -f 'cudd/cuddRead.c' || echo '$(srcdir)/'`cudd/cuddRead.c + +cudd/cudd_libcudd_la-cuddRef.lo: cudd/cuddRef.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddRef.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddRef.Tpo -c -o cudd/cudd_libcudd_la-cuddRef.lo `test -f 'cudd/cuddRef.c' || echo '$(srcdir)/'`cudd/cuddRef.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddRef.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddRef.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddRef.c' object='cudd/cudd_libcudd_la-cuddRef.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddRef.lo `test -f 'cudd/cuddRef.c' || echo '$(srcdir)/'`cudd/cuddRef.c + +cudd/cudd_libcudd_la-cuddReorder.lo: cudd/cuddReorder.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddReorder.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddReorder.Tpo -c -o cudd/cudd_libcudd_la-cuddReorder.lo `test -f 'cudd/cuddReorder.c' || echo '$(srcdir)/'`cudd/cuddReorder.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddReorder.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddReorder.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddReorder.c' object='cudd/cudd_libcudd_la-cuddReorder.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddReorder.lo `test -f 'cudd/cuddReorder.c' || echo '$(srcdir)/'`cudd/cuddReorder.c + +cudd/cudd_libcudd_la-cuddSat.lo: cudd/cuddSat.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddSat.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddSat.Tpo -c -o cudd/cudd_libcudd_la-cuddSat.lo `test -f 'cudd/cuddSat.c' || echo '$(srcdir)/'`cudd/cuddSat.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddSat.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddSat.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddSat.c' object='cudd/cudd_libcudd_la-cuddSat.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddSat.lo `test -f 'cudd/cuddSat.c' || echo '$(srcdir)/'`cudd/cuddSat.c + +cudd/cudd_libcudd_la-cuddSign.lo: cudd/cuddSign.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddSign.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddSign.Tpo -c -o cudd/cudd_libcudd_la-cuddSign.lo `test -f 'cudd/cuddSign.c' || echo '$(srcdir)/'`cudd/cuddSign.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddSign.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddSign.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddSign.c' object='cudd/cudd_libcudd_la-cuddSign.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddSign.lo `test -f 'cudd/cuddSign.c' || echo '$(srcdir)/'`cudd/cuddSign.c + +cudd/cudd_libcudd_la-cuddSolve.lo: cudd/cuddSolve.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddSolve.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddSolve.Tpo -c -o cudd/cudd_libcudd_la-cuddSolve.lo `test -f 'cudd/cuddSolve.c' || echo '$(srcdir)/'`cudd/cuddSolve.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddSolve.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddSolve.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddSolve.c' object='cudd/cudd_libcudd_la-cuddSolve.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddSolve.lo `test -f 'cudd/cuddSolve.c' || echo '$(srcdir)/'`cudd/cuddSolve.c + +cudd/cudd_libcudd_la-cuddSplit.lo: cudd/cuddSplit.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddSplit.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddSplit.Tpo -c -o cudd/cudd_libcudd_la-cuddSplit.lo `test -f 'cudd/cuddSplit.c' || echo '$(srcdir)/'`cudd/cuddSplit.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddSplit.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddSplit.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddSplit.c' object='cudd/cudd_libcudd_la-cuddSplit.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddSplit.lo `test -f 'cudd/cuddSplit.c' || echo '$(srcdir)/'`cudd/cuddSplit.c + +cudd/cudd_libcudd_la-cuddSubsetHB.lo: cudd/cuddSubsetHB.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddSubsetHB.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddSubsetHB.Tpo -c -o cudd/cudd_libcudd_la-cuddSubsetHB.lo `test -f 'cudd/cuddSubsetHB.c' || echo '$(srcdir)/'`cudd/cuddSubsetHB.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddSubsetHB.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddSubsetHB.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddSubsetHB.c' object='cudd/cudd_libcudd_la-cuddSubsetHB.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddSubsetHB.lo `test -f 'cudd/cuddSubsetHB.c' || echo '$(srcdir)/'`cudd/cuddSubsetHB.c + +cudd/cudd_libcudd_la-cuddSubsetSP.lo: cudd/cuddSubsetSP.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddSubsetSP.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddSubsetSP.Tpo -c -o cudd/cudd_libcudd_la-cuddSubsetSP.lo `test -f 'cudd/cuddSubsetSP.c' || echo '$(srcdir)/'`cudd/cuddSubsetSP.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddSubsetSP.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddSubsetSP.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddSubsetSP.c' object='cudd/cudd_libcudd_la-cuddSubsetSP.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddSubsetSP.lo `test -f 'cudd/cuddSubsetSP.c' || echo '$(srcdir)/'`cudd/cuddSubsetSP.c + +cudd/cudd_libcudd_la-cuddSymmetry.lo: cudd/cuddSymmetry.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddSymmetry.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddSymmetry.Tpo -c -o cudd/cudd_libcudd_la-cuddSymmetry.lo `test -f 'cudd/cuddSymmetry.c' || echo '$(srcdir)/'`cudd/cuddSymmetry.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddSymmetry.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddSymmetry.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddSymmetry.c' object='cudd/cudd_libcudd_la-cuddSymmetry.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddSymmetry.lo `test -f 'cudd/cuddSymmetry.c' || echo '$(srcdir)/'`cudd/cuddSymmetry.c + +cudd/cudd_libcudd_la-cuddTable.lo: cudd/cuddTable.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddTable.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddTable.Tpo -c -o cudd/cudd_libcudd_la-cuddTable.lo `test -f 'cudd/cuddTable.c' || echo '$(srcdir)/'`cudd/cuddTable.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddTable.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddTable.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddTable.c' object='cudd/cudd_libcudd_la-cuddTable.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddTable.lo `test -f 'cudd/cuddTable.c' || echo '$(srcdir)/'`cudd/cuddTable.c + +cudd/cudd_libcudd_la-cuddUtil.lo: cudd/cuddUtil.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddUtil.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddUtil.Tpo -c -o cudd/cudd_libcudd_la-cuddUtil.lo `test -f 'cudd/cuddUtil.c' || echo '$(srcdir)/'`cudd/cuddUtil.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddUtil.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddUtil.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddUtil.c' object='cudd/cudd_libcudd_la-cuddUtil.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddUtil.lo `test -f 'cudd/cuddUtil.c' || echo '$(srcdir)/'`cudd/cuddUtil.c + +cudd/cudd_libcudd_la-cuddWindow.lo: cudd/cuddWindow.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddWindow.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddWindow.Tpo -c -o cudd/cudd_libcudd_la-cuddWindow.lo `test -f 'cudd/cuddWindow.c' || echo '$(srcdir)/'`cudd/cuddWindow.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddWindow.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddWindow.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddWindow.c' object='cudd/cudd_libcudd_la-cuddWindow.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddWindow.lo `test -f 'cudd/cuddWindow.c' || echo '$(srcdir)/'`cudd/cuddWindow.c + +cudd/cudd_libcudd_la-cuddZddCount.lo: cudd/cuddZddCount.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddZddCount.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddCount.Tpo -c -o cudd/cudd_libcudd_la-cuddZddCount.lo `test -f 'cudd/cuddZddCount.c' || echo '$(srcdir)/'`cudd/cuddZddCount.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddCount.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddCount.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddZddCount.c' object='cudd/cudd_libcudd_la-cuddZddCount.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddZddCount.lo `test -f 'cudd/cuddZddCount.c' || echo '$(srcdir)/'`cudd/cuddZddCount.c + +cudd/cudd_libcudd_la-cuddZddFuncs.lo: cudd/cuddZddFuncs.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddZddFuncs.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddFuncs.Tpo -c -o cudd/cudd_libcudd_la-cuddZddFuncs.lo `test -f 'cudd/cuddZddFuncs.c' || echo '$(srcdir)/'`cudd/cuddZddFuncs.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddFuncs.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddFuncs.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddZddFuncs.c' object='cudd/cudd_libcudd_la-cuddZddFuncs.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddZddFuncs.lo `test -f 'cudd/cuddZddFuncs.c' || echo '$(srcdir)/'`cudd/cuddZddFuncs.c + +cudd/cudd_libcudd_la-cuddZddGroup.lo: cudd/cuddZddGroup.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddZddGroup.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddGroup.Tpo -c -o cudd/cudd_libcudd_la-cuddZddGroup.lo `test -f 'cudd/cuddZddGroup.c' || echo '$(srcdir)/'`cudd/cuddZddGroup.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddGroup.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddGroup.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddZddGroup.c' object='cudd/cudd_libcudd_la-cuddZddGroup.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddZddGroup.lo `test -f 'cudd/cuddZddGroup.c' || echo '$(srcdir)/'`cudd/cuddZddGroup.c + +cudd/cudd_libcudd_la-cuddZddIsop.lo: cudd/cuddZddIsop.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddZddIsop.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddIsop.Tpo -c -o cudd/cudd_libcudd_la-cuddZddIsop.lo `test -f 'cudd/cuddZddIsop.c' || echo '$(srcdir)/'`cudd/cuddZddIsop.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddIsop.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddIsop.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddZddIsop.c' object='cudd/cudd_libcudd_la-cuddZddIsop.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddZddIsop.lo `test -f 'cudd/cuddZddIsop.c' || echo '$(srcdir)/'`cudd/cuddZddIsop.c + +cudd/cudd_libcudd_la-cuddZddLin.lo: cudd/cuddZddLin.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddZddLin.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddLin.Tpo -c -o cudd/cudd_libcudd_la-cuddZddLin.lo `test -f 'cudd/cuddZddLin.c' || echo '$(srcdir)/'`cudd/cuddZddLin.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddLin.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddLin.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddZddLin.c' object='cudd/cudd_libcudd_la-cuddZddLin.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddZddLin.lo `test -f 'cudd/cuddZddLin.c' || echo '$(srcdir)/'`cudd/cuddZddLin.c + +cudd/cudd_libcudd_la-cuddZddMisc.lo: cudd/cuddZddMisc.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddZddMisc.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddMisc.Tpo -c -o cudd/cudd_libcudd_la-cuddZddMisc.lo `test -f 'cudd/cuddZddMisc.c' || echo '$(srcdir)/'`cudd/cuddZddMisc.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddMisc.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddMisc.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddZddMisc.c' object='cudd/cudd_libcudd_la-cuddZddMisc.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddZddMisc.lo `test -f 'cudd/cuddZddMisc.c' || echo '$(srcdir)/'`cudd/cuddZddMisc.c + +cudd/cudd_libcudd_la-cuddZddPort.lo: cudd/cuddZddPort.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddZddPort.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddPort.Tpo -c -o cudd/cudd_libcudd_la-cuddZddPort.lo `test -f 'cudd/cuddZddPort.c' || echo '$(srcdir)/'`cudd/cuddZddPort.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddPort.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddPort.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddZddPort.c' object='cudd/cudd_libcudd_la-cuddZddPort.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddZddPort.lo `test -f 'cudd/cuddZddPort.c' || echo '$(srcdir)/'`cudd/cuddZddPort.c + +cudd/cudd_libcudd_la-cuddZddReord.lo: cudd/cuddZddReord.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddZddReord.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddReord.Tpo -c -o cudd/cudd_libcudd_la-cuddZddReord.lo `test -f 'cudd/cuddZddReord.c' || echo '$(srcdir)/'`cudd/cuddZddReord.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddReord.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddReord.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddZddReord.c' object='cudd/cudd_libcudd_la-cuddZddReord.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddZddReord.lo `test -f 'cudd/cuddZddReord.c' || echo '$(srcdir)/'`cudd/cuddZddReord.c + +cudd/cudd_libcudd_la-cuddZddSetop.lo: cudd/cuddZddSetop.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddZddSetop.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddSetop.Tpo -c -o cudd/cudd_libcudd_la-cuddZddSetop.lo `test -f 'cudd/cuddZddSetop.c' || echo '$(srcdir)/'`cudd/cuddZddSetop.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddSetop.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddSetop.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddZddSetop.c' object='cudd/cudd_libcudd_la-cuddZddSetop.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddZddSetop.lo `test -f 'cudd/cuddZddSetop.c' || echo '$(srcdir)/'`cudd/cuddZddSetop.c + +cudd/cudd_libcudd_la-cuddZddSymm.lo: cudd/cuddZddSymm.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddZddSymm.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddSymm.Tpo -c -o cudd/cudd_libcudd_la-cuddZddSymm.lo `test -f 'cudd/cuddZddSymm.c' || echo '$(srcdir)/'`cudd/cuddZddSymm.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddSymm.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddSymm.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddZddSymm.c' object='cudd/cudd_libcudd_la-cuddZddSymm.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddZddSymm.lo `test -f 'cudd/cuddZddSymm.c' || echo '$(srcdir)/'`cudd/cuddZddSymm.c + +cudd/cudd_libcudd_la-cuddZddUtil.lo: cudd/cuddZddUtil.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_libcudd_la-cuddZddUtil.lo -MD -MP -MF cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddUtil.Tpo -c -o cudd/cudd_libcudd_la-cuddZddUtil.lo `test -f 'cudd/cuddZddUtil.c' || echo '$(srcdir)/'`cudd/cuddZddUtil.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddUtil.Tpo cudd/$(DEPDIR)/cudd_libcudd_la-cuddZddUtil.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/cuddZddUtil.c' object='cudd/cudd_libcudd_la-cuddZddUtil.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_libcudd_la-cuddZddUtil.lo `test -f 'cudd/cuddZddUtil.c' || echo '$(srcdir)/'`cudd/cuddZddUtil.c + +util/cudd_libcudd_la-cpu_stats.lo: util/cpu_stats.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT util/cudd_libcudd_la-cpu_stats.lo -MD -MP -MF util/$(DEPDIR)/cudd_libcudd_la-cpu_stats.Tpo -c -o util/cudd_libcudd_la-cpu_stats.lo `test -f 'util/cpu_stats.c' || echo '$(srcdir)/'`util/cpu_stats.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) util/$(DEPDIR)/cudd_libcudd_la-cpu_stats.Tpo util/$(DEPDIR)/cudd_libcudd_la-cpu_stats.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='util/cpu_stats.c' object='util/cudd_libcudd_la-cpu_stats.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o util/cudd_libcudd_la-cpu_stats.lo `test -f 'util/cpu_stats.c' || echo '$(srcdir)/'`util/cpu_stats.c + +util/cudd_libcudd_la-cpu_time.lo: util/cpu_time.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT util/cudd_libcudd_la-cpu_time.lo -MD -MP -MF util/$(DEPDIR)/cudd_libcudd_la-cpu_time.Tpo -c -o util/cudd_libcudd_la-cpu_time.lo `test -f 'util/cpu_time.c' || echo '$(srcdir)/'`util/cpu_time.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) util/$(DEPDIR)/cudd_libcudd_la-cpu_time.Tpo util/$(DEPDIR)/cudd_libcudd_la-cpu_time.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='util/cpu_time.c' object='util/cudd_libcudd_la-cpu_time.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o util/cudd_libcudd_la-cpu_time.lo `test -f 'util/cpu_time.c' || echo '$(srcdir)/'`util/cpu_time.c + +util/cudd_libcudd_la-cstringstream.lo: util/cstringstream.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT util/cudd_libcudd_la-cstringstream.lo -MD -MP -MF util/$(DEPDIR)/cudd_libcudd_la-cstringstream.Tpo -c -o util/cudd_libcudd_la-cstringstream.lo `test -f 'util/cstringstream.c' || echo '$(srcdir)/'`util/cstringstream.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) util/$(DEPDIR)/cudd_libcudd_la-cstringstream.Tpo util/$(DEPDIR)/cudd_libcudd_la-cstringstream.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='util/cstringstream.c' object='util/cudd_libcudd_la-cstringstream.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o util/cudd_libcudd_la-cstringstream.lo `test -f 'util/cstringstream.c' || echo '$(srcdir)/'`util/cstringstream.c + +util/cudd_libcudd_la-datalimit.lo: util/datalimit.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT util/cudd_libcudd_la-datalimit.lo -MD -MP -MF util/$(DEPDIR)/cudd_libcudd_la-datalimit.Tpo -c -o util/cudd_libcudd_la-datalimit.lo `test -f 'util/datalimit.c' || echo '$(srcdir)/'`util/datalimit.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) util/$(DEPDIR)/cudd_libcudd_la-datalimit.Tpo util/$(DEPDIR)/cudd_libcudd_la-datalimit.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='util/datalimit.c' object='util/cudd_libcudd_la-datalimit.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o util/cudd_libcudd_la-datalimit.lo `test -f 'util/datalimit.c' || echo '$(srcdir)/'`util/datalimit.c + +util/cudd_libcudd_la-pathsearch.lo: util/pathsearch.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT util/cudd_libcudd_la-pathsearch.lo -MD -MP -MF util/$(DEPDIR)/cudd_libcudd_la-pathsearch.Tpo -c -o util/cudd_libcudd_la-pathsearch.lo `test -f 'util/pathsearch.c' || echo '$(srcdir)/'`util/pathsearch.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) util/$(DEPDIR)/cudd_libcudd_la-pathsearch.Tpo util/$(DEPDIR)/cudd_libcudd_la-pathsearch.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='util/pathsearch.c' object='util/cudd_libcudd_la-pathsearch.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o util/cudd_libcudd_la-pathsearch.lo `test -f 'util/pathsearch.c' || echo '$(srcdir)/'`util/pathsearch.c + +util/cudd_libcudd_la-pipefork.lo: util/pipefork.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT util/cudd_libcudd_la-pipefork.lo -MD -MP -MF util/$(DEPDIR)/cudd_libcudd_la-pipefork.Tpo -c -o util/cudd_libcudd_la-pipefork.lo `test -f 'util/pipefork.c' || echo '$(srcdir)/'`util/pipefork.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) util/$(DEPDIR)/cudd_libcudd_la-pipefork.Tpo util/$(DEPDIR)/cudd_libcudd_la-pipefork.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='util/pipefork.c' object='util/cudd_libcudd_la-pipefork.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o util/cudd_libcudd_la-pipefork.lo `test -f 'util/pipefork.c' || echo '$(srcdir)/'`util/pipefork.c + +util/cudd_libcudd_la-prtime.lo: util/prtime.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT util/cudd_libcudd_la-prtime.lo -MD -MP -MF util/$(DEPDIR)/cudd_libcudd_la-prtime.Tpo -c -o util/cudd_libcudd_la-prtime.lo `test -f 'util/prtime.c' || echo '$(srcdir)/'`util/prtime.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) util/$(DEPDIR)/cudd_libcudd_la-prtime.Tpo util/$(DEPDIR)/cudd_libcudd_la-prtime.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='util/prtime.c' object='util/cudd_libcudd_la-prtime.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o util/cudd_libcudd_la-prtime.lo `test -f 'util/prtime.c' || echo '$(srcdir)/'`util/prtime.c + +util/cudd_libcudd_la-safe_mem.lo: util/safe_mem.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT util/cudd_libcudd_la-safe_mem.lo -MD -MP -MF util/$(DEPDIR)/cudd_libcudd_la-safe_mem.Tpo -c -o util/cudd_libcudd_la-safe_mem.lo `test -f 'util/safe_mem.c' || echo '$(srcdir)/'`util/safe_mem.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) util/$(DEPDIR)/cudd_libcudd_la-safe_mem.Tpo util/$(DEPDIR)/cudd_libcudd_la-safe_mem.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='util/safe_mem.c' object='util/cudd_libcudd_la-safe_mem.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o util/cudd_libcudd_la-safe_mem.lo `test -f 'util/safe_mem.c' || echo '$(srcdir)/'`util/safe_mem.c + +util/cudd_libcudd_la-strsav.lo: util/strsav.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT util/cudd_libcudd_la-strsav.lo -MD -MP -MF util/$(DEPDIR)/cudd_libcudd_la-strsav.Tpo -c -o util/cudd_libcudd_la-strsav.lo `test -f 'util/strsav.c' || echo '$(srcdir)/'`util/strsav.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) util/$(DEPDIR)/cudd_libcudd_la-strsav.Tpo util/$(DEPDIR)/cudd_libcudd_la-strsav.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='util/strsav.c' object='util/cudd_libcudd_la-strsav.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o util/cudd_libcudd_la-strsav.lo `test -f 'util/strsav.c' || echo '$(srcdir)/'`util/strsav.c + +util/cudd_libcudd_la-texpand.lo: util/texpand.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT util/cudd_libcudd_la-texpand.lo -MD -MP -MF util/$(DEPDIR)/cudd_libcudd_la-texpand.Tpo -c -o util/cudd_libcudd_la-texpand.lo `test -f 'util/texpand.c' || echo '$(srcdir)/'`util/texpand.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) util/$(DEPDIR)/cudd_libcudd_la-texpand.Tpo util/$(DEPDIR)/cudd_libcudd_la-texpand.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='util/texpand.c' object='util/cudd_libcudd_la-texpand.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o util/cudd_libcudd_la-texpand.lo `test -f 'util/texpand.c' || echo '$(srcdir)/'`util/texpand.c + +util/cudd_libcudd_la-ucbqsort.lo: util/ucbqsort.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT util/cudd_libcudd_la-ucbqsort.lo -MD -MP -MF util/$(DEPDIR)/cudd_libcudd_la-ucbqsort.Tpo -c -o util/cudd_libcudd_la-ucbqsort.lo `test -f 'util/ucbqsort.c' || echo '$(srcdir)/'`util/ucbqsort.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) util/$(DEPDIR)/cudd_libcudd_la-ucbqsort.Tpo util/$(DEPDIR)/cudd_libcudd_la-ucbqsort.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='util/ucbqsort.c' object='util/cudd_libcudd_la-ucbqsort.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o util/cudd_libcudd_la-ucbqsort.lo `test -f 'util/ucbqsort.c' || echo '$(srcdir)/'`util/ucbqsort.c + +st/cudd_libcudd_la-st.lo: st/st.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT st/cudd_libcudd_la-st.lo -MD -MP -MF st/$(DEPDIR)/cudd_libcudd_la-st.Tpo -c -o st/cudd_libcudd_la-st.lo `test -f 'st/st.c' || echo '$(srcdir)/'`st/st.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) st/$(DEPDIR)/cudd_libcudd_la-st.Tpo st/$(DEPDIR)/cudd_libcudd_la-st.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='st/st.c' object='st/cudd_libcudd_la-st.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o st/cudd_libcudd_la-st.lo `test -f 'st/st.c' || echo '$(srcdir)/'`st/st.c + +epd/cudd_libcudd_la-epd.lo: epd/epd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT epd/cudd_libcudd_la-epd.lo -MD -MP -MF epd/$(DEPDIR)/cudd_libcudd_la-epd.Tpo -c -o epd/cudd_libcudd_la-epd.lo `test -f 'epd/epd.c' || echo '$(srcdir)/'`epd/epd.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) epd/$(DEPDIR)/cudd_libcudd_la-epd.Tpo epd/$(DEPDIR)/cudd_libcudd_la-epd.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='epd/epd.c' object='epd/cudd_libcudd_la-epd.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o epd/cudd_libcudd_la-epd.lo `test -f 'epd/epd.c' || echo '$(srcdir)/'`epd/epd.c + +mtr/cudd_libcudd_la-mtrBasic.lo: mtr/mtrBasic.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mtr/cudd_libcudd_la-mtrBasic.lo -MD -MP -MF mtr/$(DEPDIR)/cudd_libcudd_la-mtrBasic.Tpo -c -o mtr/cudd_libcudd_la-mtrBasic.lo `test -f 'mtr/mtrBasic.c' || echo '$(srcdir)/'`mtr/mtrBasic.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) mtr/$(DEPDIR)/cudd_libcudd_la-mtrBasic.Tpo mtr/$(DEPDIR)/cudd_libcudd_la-mtrBasic.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='mtr/mtrBasic.c' object='mtr/cudd_libcudd_la-mtrBasic.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mtr/cudd_libcudd_la-mtrBasic.lo `test -f 'mtr/mtrBasic.c' || echo '$(srcdir)/'`mtr/mtrBasic.c + +mtr/cudd_libcudd_la-mtrGroup.lo: mtr/mtrGroup.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mtr/cudd_libcudd_la-mtrGroup.lo -MD -MP -MF mtr/$(DEPDIR)/cudd_libcudd_la-mtrGroup.Tpo -c -o mtr/cudd_libcudd_la-mtrGroup.lo `test -f 'mtr/mtrGroup.c' || echo '$(srcdir)/'`mtr/mtrGroup.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) mtr/$(DEPDIR)/cudd_libcudd_la-mtrGroup.Tpo mtr/$(DEPDIR)/cudd_libcudd_la-mtrGroup.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='mtr/mtrGroup.c' object='mtr/cudd_libcudd_la-mtrGroup.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mtr/cudd_libcudd_la-mtrGroup.lo `test -f 'mtr/mtrGroup.c' || echo '$(srcdir)/'`mtr/mtrGroup.c + +dddmp/cudd_libcudd_la-dddmpBinary.lo: dddmp/dddmpBinary.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpBinary.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpBinary.Tpo -c -o dddmp/cudd_libcudd_la-dddmpBinary.lo `test -f 'dddmp/dddmpBinary.c' || echo '$(srcdir)/'`dddmp/dddmpBinary.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpBinary.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpBinary.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpBinary.c' object='dddmp/cudd_libcudd_la-dddmpBinary.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpBinary.lo `test -f 'dddmp/dddmpBinary.c' || echo '$(srcdir)/'`dddmp/dddmpBinary.c + +dddmp/cudd_libcudd_la-dddmpConvert.lo: dddmp/dddmpConvert.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpConvert.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpConvert.Tpo -c -o dddmp/cudd_libcudd_la-dddmpConvert.lo `test -f 'dddmp/dddmpConvert.c' || echo '$(srcdir)/'`dddmp/dddmpConvert.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpConvert.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpConvert.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpConvert.c' object='dddmp/cudd_libcudd_la-dddmpConvert.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpConvert.lo `test -f 'dddmp/dddmpConvert.c' || echo '$(srcdir)/'`dddmp/dddmpConvert.c + +dddmp/cudd_libcudd_la-dddmpDbg.lo: dddmp/dddmpDbg.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpDbg.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpDbg.Tpo -c -o dddmp/cudd_libcudd_la-dddmpDbg.lo `test -f 'dddmp/dddmpDbg.c' || echo '$(srcdir)/'`dddmp/dddmpDbg.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpDbg.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpDbg.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpDbg.c' object='dddmp/cudd_libcudd_la-dddmpDbg.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpDbg.lo `test -f 'dddmp/dddmpDbg.c' || echo '$(srcdir)/'`dddmp/dddmpDbg.c + +dddmp/cudd_libcudd_la-dddmpLoad.lo: dddmp/dddmpLoad.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpLoad.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpLoad.Tpo -c -o dddmp/cudd_libcudd_la-dddmpLoad.lo `test -f 'dddmp/dddmpLoad.c' || echo '$(srcdir)/'`dddmp/dddmpLoad.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpLoad.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpLoad.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpLoad.c' object='dddmp/cudd_libcudd_la-dddmpLoad.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpLoad.lo `test -f 'dddmp/dddmpLoad.c' || echo '$(srcdir)/'`dddmp/dddmpLoad.c + +dddmp/cudd_libcudd_la-dddmpLoadCnf.lo: dddmp/dddmpLoadCnf.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpLoadCnf.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpLoadCnf.Tpo -c -o dddmp/cudd_libcudd_la-dddmpLoadCnf.lo `test -f 'dddmp/dddmpLoadCnf.c' || echo '$(srcdir)/'`dddmp/dddmpLoadCnf.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpLoadCnf.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpLoadCnf.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpLoadCnf.c' object='dddmp/cudd_libcudd_la-dddmpLoadCnf.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpLoadCnf.lo `test -f 'dddmp/dddmpLoadCnf.c' || echo '$(srcdir)/'`dddmp/dddmpLoadCnf.c + +dddmp/cudd_libcudd_la-dddmpNodeAdd.lo: dddmp/dddmpNodeAdd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpNodeAdd.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeAdd.Tpo -c -o dddmp/cudd_libcudd_la-dddmpNodeAdd.lo `test -f 'dddmp/dddmpNodeAdd.c' || echo '$(srcdir)/'`dddmp/dddmpNodeAdd.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeAdd.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeAdd.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpNodeAdd.c' object='dddmp/cudd_libcudd_la-dddmpNodeAdd.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpNodeAdd.lo `test -f 'dddmp/dddmpNodeAdd.c' || echo '$(srcdir)/'`dddmp/dddmpNodeAdd.c + +dddmp/cudd_libcudd_la-dddmpNodeBdd.lo: dddmp/dddmpNodeBdd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpNodeBdd.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeBdd.Tpo -c -o dddmp/cudd_libcudd_la-dddmpNodeBdd.lo `test -f 'dddmp/dddmpNodeBdd.c' || echo '$(srcdir)/'`dddmp/dddmpNodeBdd.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeBdd.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeBdd.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpNodeBdd.c' object='dddmp/cudd_libcudd_la-dddmpNodeBdd.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpNodeBdd.lo `test -f 'dddmp/dddmpNodeBdd.c' || echo '$(srcdir)/'`dddmp/dddmpNodeBdd.c + +dddmp/cudd_libcudd_la-dddmpNodeCnf.lo: dddmp/dddmpNodeCnf.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpNodeCnf.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeCnf.Tpo -c -o dddmp/cudd_libcudd_la-dddmpNodeCnf.lo `test -f 'dddmp/dddmpNodeCnf.c' || echo '$(srcdir)/'`dddmp/dddmpNodeCnf.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeCnf.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpNodeCnf.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpNodeCnf.c' object='dddmp/cudd_libcudd_la-dddmpNodeCnf.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpNodeCnf.lo `test -f 'dddmp/dddmpNodeCnf.c' || echo '$(srcdir)/'`dddmp/dddmpNodeCnf.c + +dddmp/cudd_libcudd_la-dddmpStoreAdd.lo: dddmp/dddmpStoreAdd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpStoreAdd.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreAdd.Tpo -c -o dddmp/cudd_libcudd_la-dddmpStoreAdd.lo `test -f 'dddmp/dddmpStoreAdd.c' || echo '$(srcdir)/'`dddmp/dddmpStoreAdd.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreAdd.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreAdd.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpStoreAdd.c' object='dddmp/cudd_libcudd_la-dddmpStoreAdd.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpStoreAdd.lo `test -f 'dddmp/dddmpStoreAdd.c' || echo '$(srcdir)/'`dddmp/dddmpStoreAdd.c + +dddmp/cudd_libcudd_la-dddmpStoreBdd.lo: dddmp/dddmpStoreBdd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpStoreBdd.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreBdd.Tpo -c -o dddmp/cudd_libcudd_la-dddmpStoreBdd.lo `test -f 'dddmp/dddmpStoreBdd.c' || echo '$(srcdir)/'`dddmp/dddmpStoreBdd.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreBdd.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreBdd.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpStoreBdd.c' object='dddmp/cudd_libcudd_la-dddmpStoreBdd.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpStoreBdd.lo `test -f 'dddmp/dddmpStoreBdd.c' || echo '$(srcdir)/'`dddmp/dddmpStoreBdd.c + +dddmp/cudd_libcudd_la-dddmpStoreCnf.lo: dddmp/dddmpStoreCnf.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpStoreCnf.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreCnf.Tpo -c -o dddmp/cudd_libcudd_la-dddmpStoreCnf.lo `test -f 'dddmp/dddmpStoreCnf.c' || echo '$(srcdir)/'`dddmp/dddmpStoreCnf.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreCnf.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreCnf.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpStoreCnf.c' object='dddmp/cudd_libcudd_la-dddmpStoreCnf.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpStoreCnf.lo `test -f 'dddmp/dddmpStoreCnf.c' || echo '$(srcdir)/'`dddmp/dddmpStoreCnf.c + +dddmp/cudd_libcudd_la-dddmpStoreMisc.lo: dddmp/dddmpStoreMisc.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpStoreMisc.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreMisc.Tpo -c -o dddmp/cudd_libcudd_la-dddmpStoreMisc.lo `test -f 'dddmp/dddmpStoreMisc.c' || echo '$(srcdir)/'`dddmp/dddmpStoreMisc.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreMisc.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpStoreMisc.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpStoreMisc.c' object='dddmp/cudd_libcudd_la-dddmpStoreMisc.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpStoreMisc.lo `test -f 'dddmp/dddmpStoreMisc.c' || echo '$(srcdir)/'`dddmp/dddmpStoreMisc.c + +dddmp/cudd_libcudd_la-dddmpUtil.lo: dddmp/dddmpUtil.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/cudd_libcudd_la-dddmpUtil.lo -MD -MP -MF dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpUtil.Tpo -c -o dddmp/cudd_libcudd_la-dddmpUtil.lo `test -f 'dddmp/dddmpUtil.c' || echo '$(srcdir)/'`dddmp/dddmpUtil.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpUtil.Tpo dddmp/$(DEPDIR)/cudd_libcudd_la-dddmpUtil.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpUtil.c' object='dddmp/cudd_libcudd_la-dddmpUtil.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/cudd_libcudd_la-dddmpUtil.lo `test -f 'dddmp/dddmpUtil.c' || echo '$(srcdir)/'`dddmp/dddmpUtil.c + +dddmp/dddmp_libdddmp_la-dddmpBinary.lo: dddmp/dddmpBinary.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpBinary.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpBinary.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpBinary.lo `test -f 'dddmp/dddmpBinary.c' || echo '$(srcdir)/'`dddmp/dddmpBinary.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpBinary.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpBinary.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpBinary.c' object='dddmp/dddmp_libdddmp_la-dddmpBinary.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpBinary.lo `test -f 'dddmp/dddmpBinary.c' || echo '$(srcdir)/'`dddmp/dddmpBinary.c + +dddmp/dddmp_libdddmp_la-dddmpConvert.lo: dddmp/dddmpConvert.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpConvert.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpConvert.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpConvert.lo `test -f 'dddmp/dddmpConvert.c' || echo '$(srcdir)/'`dddmp/dddmpConvert.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpConvert.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpConvert.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpConvert.c' object='dddmp/dddmp_libdddmp_la-dddmpConvert.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpConvert.lo `test -f 'dddmp/dddmpConvert.c' || echo '$(srcdir)/'`dddmp/dddmpConvert.c + +dddmp/dddmp_libdddmp_la-dddmpDbg.lo: dddmp/dddmpDbg.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpDbg.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpDbg.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpDbg.lo `test -f 'dddmp/dddmpDbg.c' || echo '$(srcdir)/'`dddmp/dddmpDbg.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpDbg.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpDbg.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpDbg.c' object='dddmp/dddmp_libdddmp_la-dddmpDbg.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpDbg.lo `test -f 'dddmp/dddmpDbg.c' || echo '$(srcdir)/'`dddmp/dddmpDbg.c + +dddmp/dddmp_libdddmp_la-dddmpLoad.lo: dddmp/dddmpLoad.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpLoad.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpLoad.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpLoad.lo `test -f 'dddmp/dddmpLoad.c' || echo '$(srcdir)/'`dddmp/dddmpLoad.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpLoad.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpLoad.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpLoad.c' object='dddmp/dddmp_libdddmp_la-dddmpLoad.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpLoad.lo `test -f 'dddmp/dddmpLoad.c' || echo '$(srcdir)/'`dddmp/dddmpLoad.c + +dddmp/dddmp_libdddmp_la-dddmpLoadCnf.lo: dddmp/dddmpLoadCnf.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpLoadCnf.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpLoadCnf.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpLoadCnf.lo `test -f 'dddmp/dddmpLoadCnf.c' || echo '$(srcdir)/'`dddmp/dddmpLoadCnf.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpLoadCnf.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpLoadCnf.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpLoadCnf.c' object='dddmp/dddmp_libdddmp_la-dddmpLoadCnf.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpLoadCnf.lo `test -f 'dddmp/dddmpLoadCnf.c' || echo '$(srcdir)/'`dddmp/dddmpLoadCnf.c + +dddmp/dddmp_libdddmp_la-dddmpNodeAdd.lo: dddmp/dddmpNodeAdd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpNodeAdd.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeAdd.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpNodeAdd.lo `test -f 'dddmp/dddmpNodeAdd.c' || echo '$(srcdir)/'`dddmp/dddmpNodeAdd.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeAdd.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeAdd.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpNodeAdd.c' object='dddmp/dddmp_libdddmp_la-dddmpNodeAdd.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpNodeAdd.lo `test -f 'dddmp/dddmpNodeAdd.c' || echo '$(srcdir)/'`dddmp/dddmpNodeAdd.c + +dddmp/dddmp_libdddmp_la-dddmpNodeBdd.lo: dddmp/dddmpNodeBdd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpNodeBdd.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeBdd.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpNodeBdd.lo `test -f 'dddmp/dddmpNodeBdd.c' || echo '$(srcdir)/'`dddmp/dddmpNodeBdd.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeBdd.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeBdd.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpNodeBdd.c' object='dddmp/dddmp_libdddmp_la-dddmpNodeBdd.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpNodeBdd.lo `test -f 'dddmp/dddmpNodeBdd.c' || echo '$(srcdir)/'`dddmp/dddmpNodeBdd.c + +dddmp/dddmp_libdddmp_la-dddmpNodeCnf.lo: dddmp/dddmpNodeCnf.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpNodeCnf.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeCnf.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpNodeCnf.lo `test -f 'dddmp/dddmpNodeCnf.c' || echo '$(srcdir)/'`dddmp/dddmpNodeCnf.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeCnf.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpNodeCnf.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpNodeCnf.c' object='dddmp/dddmp_libdddmp_la-dddmpNodeCnf.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpNodeCnf.lo `test -f 'dddmp/dddmpNodeCnf.c' || echo '$(srcdir)/'`dddmp/dddmpNodeCnf.c + +dddmp/dddmp_libdddmp_la-dddmpStoreAdd.lo: dddmp/dddmpStoreAdd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpStoreAdd.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreAdd.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpStoreAdd.lo `test -f 'dddmp/dddmpStoreAdd.c' || echo '$(srcdir)/'`dddmp/dddmpStoreAdd.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreAdd.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreAdd.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpStoreAdd.c' object='dddmp/dddmp_libdddmp_la-dddmpStoreAdd.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpStoreAdd.lo `test -f 'dddmp/dddmpStoreAdd.c' || echo '$(srcdir)/'`dddmp/dddmpStoreAdd.c + +dddmp/dddmp_libdddmp_la-dddmpStoreBdd.lo: dddmp/dddmpStoreBdd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpStoreBdd.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreBdd.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpStoreBdd.lo `test -f 'dddmp/dddmpStoreBdd.c' || echo '$(srcdir)/'`dddmp/dddmpStoreBdd.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreBdd.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreBdd.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpStoreBdd.c' object='dddmp/dddmp_libdddmp_la-dddmpStoreBdd.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpStoreBdd.lo `test -f 'dddmp/dddmpStoreBdd.c' || echo '$(srcdir)/'`dddmp/dddmpStoreBdd.c + +dddmp/dddmp_libdddmp_la-dddmpStoreCnf.lo: dddmp/dddmpStoreCnf.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpStoreCnf.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreCnf.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpStoreCnf.lo `test -f 'dddmp/dddmpStoreCnf.c' || echo '$(srcdir)/'`dddmp/dddmpStoreCnf.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreCnf.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreCnf.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpStoreCnf.c' object='dddmp/dddmp_libdddmp_la-dddmpStoreCnf.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpStoreCnf.lo `test -f 'dddmp/dddmpStoreCnf.c' || echo '$(srcdir)/'`dddmp/dddmpStoreCnf.c + +dddmp/dddmp_libdddmp_la-dddmpStoreMisc.lo: dddmp/dddmpStoreMisc.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpStoreMisc.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreMisc.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpStoreMisc.lo `test -f 'dddmp/dddmpStoreMisc.c' || echo '$(srcdir)/'`dddmp/dddmpStoreMisc.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreMisc.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpStoreMisc.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpStoreMisc.c' object='dddmp/dddmp_libdddmp_la-dddmpStoreMisc.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpStoreMisc.lo `test -f 'dddmp/dddmpStoreMisc.c' || echo '$(srcdir)/'`dddmp/dddmpStoreMisc.c + +dddmp/dddmp_libdddmp_la-dddmpUtil.lo: dddmp/dddmpUtil.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_libdddmp_la-dddmpUtil.lo -MD -MP -MF dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpUtil.Tpo -c -o dddmp/dddmp_libdddmp_la-dddmpUtil.lo `test -f 'dddmp/dddmpUtil.c' || echo '$(srcdir)/'`dddmp/dddmpUtil.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpUtil.Tpo dddmp/$(DEPDIR)/dddmp_libdddmp_la-dddmpUtil.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/dddmpUtil.c' object='dddmp/dddmp_libdddmp_la-dddmpUtil.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_libdddmp_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_libdddmp_la-dddmpUtil.lo `test -f 'dddmp/dddmpUtil.c' || echo '$(srcdir)/'`dddmp/dddmpUtil.c + +cudd/cudd_testcudd-testcudd.o: cudd/testcudd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_testcudd_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_testcudd-testcudd.o -MD -MP -MF cudd/$(DEPDIR)/cudd_testcudd-testcudd.Tpo -c -o cudd/cudd_testcudd-testcudd.o `test -f 'cudd/testcudd.c' || echo '$(srcdir)/'`cudd/testcudd.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_testcudd-testcudd.Tpo cudd/$(DEPDIR)/cudd_testcudd-testcudd.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/testcudd.c' object='cudd/cudd_testcudd-testcudd.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_testcudd_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_testcudd-testcudd.o `test -f 'cudd/testcudd.c' || echo '$(srcdir)/'`cudd/testcudd.c + +cudd/cudd_testcudd-testcudd.obj: cudd/testcudd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_testcudd_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_testcudd-testcudd.obj -MD -MP -MF cudd/$(DEPDIR)/cudd_testcudd-testcudd.Tpo -c -o cudd/cudd_testcudd-testcudd.obj `if test -f 'cudd/testcudd.c'; then $(CYGPATH_W) 'cudd/testcudd.c'; else $(CYGPATH_W) '$(srcdir)/cudd/testcudd.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_testcudd-testcudd.Tpo cudd/$(DEPDIR)/cudd_testcudd-testcudd.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/testcudd.c' object='cudd/cudd_testcudd-testcudd.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_testcudd_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_testcudd-testcudd.obj `if test -f 'cudd/testcudd.c'; then $(CYGPATH_W) 'cudd/testcudd.c'; else $(CYGPATH_W) '$(srcdir)/cudd/testcudd.c'; fi` + +cudd/cudd_testextra-testextra.o: cudd/testextra.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_testextra_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_testextra-testextra.o -MD -MP -MF cudd/$(DEPDIR)/cudd_testextra-testextra.Tpo -c -o cudd/cudd_testextra-testextra.o `test -f 'cudd/testextra.c' || echo '$(srcdir)/'`cudd/testextra.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_testextra-testextra.Tpo cudd/$(DEPDIR)/cudd_testextra-testextra.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/testextra.c' object='cudd/cudd_testextra-testextra.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_testextra_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_testextra-testextra.o `test -f 'cudd/testextra.c' || echo '$(srcdir)/'`cudd/testextra.c + +cudd/cudd_testextra-testextra.obj: cudd/testextra.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_testextra_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT cudd/cudd_testextra-testextra.obj -MD -MP -MF cudd/$(DEPDIR)/cudd_testextra-testextra.Tpo -c -o cudd/cudd_testextra-testextra.obj `if test -f 'cudd/testextra.c'; then $(CYGPATH_W) 'cudd/testextra.c'; else $(CYGPATH_W) '$(srcdir)/cudd/testextra.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) cudd/$(DEPDIR)/cudd_testextra-testextra.Tpo cudd/$(DEPDIR)/cudd_testextra-testextra.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cudd/testextra.c' object='cudd/cudd_testextra-testextra.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_testextra_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o cudd/cudd_testextra-testextra.obj `if test -f 'cudd/testextra.c'; then $(CYGPATH_W) 'cudd/testextra.c'; else $(CYGPATH_W) '$(srcdir)/cudd/testextra.c'; fi` + +dddmp/dddmp_testdddmp-testdddmp.o: dddmp/testdddmp.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_testdddmp_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_testdddmp-testdddmp.o -MD -MP -MF dddmp/$(DEPDIR)/dddmp_testdddmp-testdddmp.Tpo -c -o dddmp/dddmp_testdddmp-testdddmp.o `test -f 'dddmp/testdddmp.c' || echo '$(srcdir)/'`dddmp/testdddmp.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_testdddmp-testdddmp.Tpo dddmp/$(DEPDIR)/dddmp_testdddmp-testdddmp.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/testdddmp.c' object='dddmp/dddmp_testdddmp-testdddmp.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_testdddmp_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_testdddmp-testdddmp.o `test -f 'dddmp/testdddmp.c' || echo '$(srcdir)/'`dddmp/testdddmp.c + +dddmp/dddmp_testdddmp-testdddmp.obj: dddmp/testdddmp.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_testdddmp_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dddmp/dddmp_testdddmp-testdddmp.obj -MD -MP -MF dddmp/$(DEPDIR)/dddmp_testdddmp-testdddmp.Tpo -c -o dddmp/dddmp_testdddmp-testdddmp.obj `if test -f 'dddmp/testdddmp.c'; then $(CYGPATH_W) 'dddmp/testdddmp.c'; else $(CYGPATH_W) '$(srcdir)/dddmp/testdddmp.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) dddmp/$(DEPDIR)/dddmp_testdddmp-testdddmp.Tpo dddmp/$(DEPDIR)/dddmp_testdddmp-testdddmp.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='dddmp/testdddmp.c' object='dddmp/dddmp_testdddmp-testdddmp.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(dddmp_testdddmp_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dddmp/dddmp_testdddmp-testdddmp.obj `if test -f 'dddmp/testdddmp.c'; then $(CYGPATH_W) 'dddmp/testdddmp.c'; else $(CYGPATH_W) '$(srcdir)/dddmp/testdddmp.c'; fi` + +mtr/mtr_testmtr-testmtr.o: mtr/testmtr.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(mtr_testmtr_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mtr/mtr_testmtr-testmtr.o -MD -MP -MF mtr/$(DEPDIR)/mtr_testmtr-testmtr.Tpo -c -o mtr/mtr_testmtr-testmtr.o `test -f 'mtr/testmtr.c' || echo '$(srcdir)/'`mtr/testmtr.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) mtr/$(DEPDIR)/mtr_testmtr-testmtr.Tpo mtr/$(DEPDIR)/mtr_testmtr-testmtr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='mtr/testmtr.c' object='mtr/mtr_testmtr-testmtr.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(mtr_testmtr_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mtr/mtr_testmtr-testmtr.o `test -f 'mtr/testmtr.c' || echo '$(srcdir)/'`mtr/testmtr.c + +mtr/mtr_testmtr-testmtr.obj: mtr/testmtr.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(mtr_testmtr_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mtr/mtr_testmtr-testmtr.obj -MD -MP -MF mtr/$(DEPDIR)/mtr_testmtr-testmtr.Tpo -c -o mtr/mtr_testmtr-testmtr.obj `if test -f 'mtr/testmtr.c'; then $(CYGPATH_W) 'mtr/testmtr.c'; else $(CYGPATH_W) '$(srcdir)/mtr/testmtr.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) mtr/$(DEPDIR)/mtr_testmtr-testmtr.Tpo mtr/$(DEPDIR)/mtr_testmtr-testmtr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='mtr/testmtr.c' object='mtr/mtr_testmtr-testmtr.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(mtr_testmtr_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mtr/mtr_testmtr-testmtr.obj `if test -f 'mtr/testmtr.c'; then $(CYGPATH_W) 'mtr/testmtr.c'; else $(CYGPATH_W) '$(srcdir)/mtr/testmtr.c'; fi` + +nanotrav/nanotrav_nanotrav-bnet.o: nanotrav/bnet.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-bnet.o -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-bnet.Tpo -c -o nanotrav/nanotrav_nanotrav-bnet.o `test -f 'nanotrav/bnet.c' || echo '$(srcdir)/'`nanotrav/bnet.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-bnet.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-bnet.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/bnet.c' object='nanotrav/nanotrav_nanotrav-bnet.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-bnet.o `test -f 'nanotrav/bnet.c' || echo '$(srcdir)/'`nanotrav/bnet.c + +nanotrav/nanotrav_nanotrav-bnet.obj: nanotrav/bnet.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-bnet.obj -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-bnet.Tpo -c -o nanotrav/nanotrav_nanotrav-bnet.obj `if test -f 'nanotrav/bnet.c'; then $(CYGPATH_W) 'nanotrav/bnet.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/bnet.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-bnet.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-bnet.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/bnet.c' object='nanotrav/nanotrav_nanotrav-bnet.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-bnet.obj `if test -f 'nanotrav/bnet.c'; then $(CYGPATH_W) 'nanotrav/bnet.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/bnet.c'; fi` + +nanotrav/nanotrav_nanotrav-chkMterm.o: nanotrav/chkMterm.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-chkMterm.o -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-chkMterm.Tpo -c -o nanotrav/nanotrav_nanotrav-chkMterm.o `test -f 'nanotrav/chkMterm.c' || echo '$(srcdir)/'`nanotrav/chkMterm.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-chkMterm.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-chkMterm.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/chkMterm.c' object='nanotrav/nanotrav_nanotrav-chkMterm.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-chkMterm.o `test -f 'nanotrav/chkMterm.c' || echo '$(srcdir)/'`nanotrav/chkMterm.c + +nanotrav/nanotrav_nanotrav-chkMterm.obj: nanotrav/chkMterm.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-chkMterm.obj -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-chkMterm.Tpo -c -o nanotrav/nanotrav_nanotrav-chkMterm.obj `if test -f 'nanotrav/chkMterm.c'; then $(CYGPATH_W) 'nanotrav/chkMterm.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/chkMterm.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-chkMterm.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-chkMterm.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/chkMterm.c' object='nanotrav/nanotrav_nanotrav-chkMterm.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-chkMterm.obj `if test -f 'nanotrav/chkMterm.c'; then $(CYGPATH_W) 'nanotrav/chkMterm.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/chkMterm.c'; fi` + +nanotrav/nanotrav_nanotrav-main.o: nanotrav/main.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-main.o -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-main.Tpo -c -o nanotrav/nanotrav_nanotrav-main.o `test -f 'nanotrav/main.c' || echo '$(srcdir)/'`nanotrav/main.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-main.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-main.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/main.c' object='nanotrav/nanotrav_nanotrav-main.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-main.o `test -f 'nanotrav/main.c' || echo '$(srcdir)/'`nanotrav/main.c + +nanotrav/nanotrav_nanotrav-main.obj: nanotrav/main.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-main.obj -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-main.Tpo -c -o nanotrav/nanotrav_nanotrav-main.obj `if test -f 'nanotrav/main.c'; then $(CYGPATH_W) 'nanotrav/main.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/main.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-main.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-main.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/main.c' object='nanotrav/nanotrav_nanotrav-main.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-main.obj `if test -f 'nanotrav/main.c'; then $(CYGPATH_W) 'nanotrav/main.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/main.c'; fi` + +nanotrav/nanotrav_nanotrav-ntrBddTest.o: nanotrav/ntrBddTest.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntrBddTest.o -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrBddTest.Tpo -c -o nanotrav/nanotrav_nanotrav-ntrBddTest.o `test -f 'nanotrav/ntrBddTest.c' || echo '$(srcdir)/'`nanotrav/ntrBddTest.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrBddTest.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrBddTest.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntrBddTest.c' object='nanotrav/nanotrav_nanotrav-ntrBddTest.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntrBddTest.o `test -f 'nanotrav/ntrBddTest.c' || echo '$(srcdir)/'`nanotrav/ntrBddTest.c + +nanotrav/nanotrav_nanotrav-ntrBddTest.obj: nanotrav/ntrBddTest.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntrBddTest.obj -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrBddTest.Tpo -c -o nanotrav/nanotrav_nanotrav-ntrBddTest.obj `if test -f 'nanotrav/ntrBddTest.c'; then $(CYGPATH_W) 'nanotrav/ntrBddTest.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntrBddTest.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrBddTest.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrBddTest.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntrBddTest.c' object='nanotrav/nanotrav_nanotrav-ntrBddTest.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntrBddTest.obj `if test -f 'nanotrav/ntrBddTest.c'; then $(CYGPATH_W) 'nanotrav/ntrBddTest.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntrBddTest.c'; fi` + +nanotrav/nanotrav_nanotrav-ntr.o: nanotrav/ntr.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntr.o -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntr.Tpo -c -o nanotrav/nanotrav_nanotrav-ntr.o `test -f 'nanotrav/ntr.c' || echo '$(srcdir)/'`nanotrav/ntr.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntr.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntr.c' object='nanotrav/nanotrav_nanotrav-ntr.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntr.o `test -f 'nanotrav/ntr.c' || echo '$(srcdir)/'`nanotrav/ntr.c + +nanotrav/nanotrav_nanotrav-ntr.obj: nanotrav/ntr.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntr.obj -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntr.Tpo -c -o nanotrav/nanotrav_nanotrav-ntr.obj `if test -f 'nanotrav/ntr.c'; then $(CYGPATH_W) 'nanotrav/ntr.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntr.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntr.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntr.c' object='nanotrav/nanotrav_nanotrav-ntr.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntr.obj `if test -f 'nanotrav/ntr.c'; then $(CYGPATH_W) 'nanotrav/ntr.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntr.c'; fi` + +nanotrav/nanotrav_nanotrav-ntrHeap.o: nanotrav/ntrHeap.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntrHeap.o -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrHeap.Tpo -c -o nanotrav/nanotrav_nanotrav-ntrHeap.o `test -f 'nanotrav/ntrHeap.c' || echo '$(srcdir)/'`nanotrav/ntrHeap.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrHeap.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrHeap.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntrHeap.c' object='nanotrav/nanotrav_nanotrav-ntrHeap.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntrHeap.o `test -f 'nanotrav/ntrHeap.c' || echo '$(srcdir)/'`nanotrav/ntrHeap.c + +nanotrav/nanotrav_nanotrav-ntrHeap.obj: nanotrav/ntrHeap.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntrHeap.obj -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrHeap.Tpo -c -o nanotrav/nanotrav_nanotrav-ntrHeap.obj `if test -f 'nanotrav/ntrHeap.c'; then $(CYGPATH_W) 'nanotrav/ntrHeap.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntrHeap.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrHeap.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrHeap.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntrHeap.c' object='nanotrav/nanotrav_nanotrav-ntrHeap.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntrHeap.obj `if test -f 'nanotrav/ntrHeap.c'; then $(CYGPATH_W) 'nanotrav/ntrHeap.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntrHeap.c'; fi` + +nanotrav/nanotrav_nanotrav-ntrMflow.o: nanotrav/ntrMflow.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntrMflow.o -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrMflow.Tpo -c -o nanotrav/nanotrav_nanotrav-ntrMflow.o `test -f 'nanotrav/ntrMflow.c' || echo '$(srcdir)/'`nanotrav/ntrMflow.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrMflow.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrMflow.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntrMflow.c' object='nanotrav/nanotrav_nanotrav-ntrMflow.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntrMflow.o `test -f 'nanotrav/ntrMflow.c' || echo '$(srcdir)/'`nanotrav/ntrMflow.c + +nanotrav/nanotrav_nanotrav-ntrMflow.obj: nanotrav/ntrMflow.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntrMflow.obj -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrMflow.Tpo -c -o nanotrav/nanotrav_nanotrav-ntrMflow.obj `if test -f 'nanotrav/ntrMflow.c'; then $(CYGPATH_W) 'nanotrav/ntrMflow.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntrMflow.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrMflow.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrMflow.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntrMflow.c' object='nanotrav/nanotrav_nanotrav-ntrMflow.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntrMflow.obj `if test -f 'nanotrav/ntrMflow.c'; then $(CYGPATH_W) 'nanotrav/ntrMflow.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntrMflow.c'; fi` + +nanotrav/nanotrav_nanotrav-ntrShort.o: nanotrav/ntrShort.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntrShort.o -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrShort.Tpo -c -o nanotrav/nanotrav_nanotrav-ntrShort.o `test -f 'nanotrav/ntrShort.c' || echo '$(srcdir)/'`nanotrav/ntrShort.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrShort.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrShort.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntrShort.c' object='nanotrav/nanotrav_nanotrav-ntrShort.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntrShort.o `test -f 'nanotrav/ntrShort.c' || echo '$(srcdir)/'`nanotrav/ntrShort.c + +nanotrav/nanotrav_nanotrav-ntrShort.obj: nanotrav/ntrShort.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntrShort.obj -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrShort.Tpo -c -o nanotrav/nanotrav_nanotrav-ntrShort.obj `if test -f 'nanotrav/ntrShort.c'; then $(CYGPATH_W) 'nanotrav/ntrShort.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntrShort.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrShort.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrShort.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntrShort.c' object='nanotrav/nanotrav_nanotrav-ntrShort.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntrShort.obj `if test -f 'nanotrav/ntrShort.c'; then $(CYGPATH_W) 'nanotrav/ntrShort.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntrShort.c'; fi` + +nanotrav/nanotrav_nanotrav-ntrZddTest.o: nanotrav/ntrZddTest.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntrZddTest.o -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrZddTest.Tpo -c -o nanotrav/nanotrav_nanotrav-ntrZddTest.o `test -f 'nanotrav/ntrZddTest.c' || echo '$(srcdir)/'`nanotrav/ntrZddTest.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrZddTest.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrZddTest.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntrZddTest.c' object='nanotrav/nanotrav_nanotrav-ntrZddTest.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntrZddTest.o `test -f 'nanotrav/ntrZddTest.c' || echo '$(srcdir)/'`nanotrav/ntrZddTest.c + +nanotrav/nanotrav_nanotrav-ntrZddTest.obj: nanotrav/ntrZddTest.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT nanotrav/nanotrav_nanotrav-ntrZddTest.obj -MD -MP -MF nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrZddTest.Tpo -c -o nanotrav/nanotrav_nanotrav-ntrZddTest.obj `if test -f 'nanotrav/ntrZddTest.c'; then $(CYGPATH_W) 'nanotrav/ntrZddTest.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntrZddTest.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrZddTest.Tpo nanotrav/$(DEPDIR)/nanotrav_nanotrav-ntrZddTest.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='nanotrav/ntrZddTest.c' object='nanotrav/nanotrav_nanotrav-ntrZddTest.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(nanotrav_nanotrav_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o nanotrav/nanotrav_nanotrav-ntrZddTest.obj `if test -f 'nanotrav/ntrZddTest.c'; then $(CYGPATH_W) 'nanotrav/ntrZddTest.c'; else $(CYGPATH_W) '$(srcdir)/nanotrav/ntrZddTest.c'; fi` + +st/st_testst-testst.o: st/testst.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(st_testst_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT st/st_testst-testst.o -MD -MP -MF st/$(DEPDIR)/st_testst-testst.Tpo -c -o st/st_testst-testst.o `test -f 'st/testst.c' || echo '$(srcdir)/'`st/testst.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) st/$(DEPDIR)/st_testst-testst.Tpo st/$(DEPDIR)/st_testst-testst.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='st/testst.c' object='st/st_testst-testst.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(st_testst_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o st/st_testst-testst.o `test -f 'st/testst.c' || echo '$(srcdir)/'`st/testst.c + +st/st_testst-testst.obj: st/testst.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(st_testst_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT st/st_testst-testst.obj -MD -MP -MF st/$(DEPDIR)/st_testst-testst.Tpo -c -o st/st_testst-testst.obj `if test -f 'st/testst.c'; then $(CYGPATH_W) 'st/testst.c'; else $(CYGPATH_W) '$(srcdir)/st/testst.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) st/$(DEPDIR)/st_testst-testst.Tpo st/$(DEPDIR)/st_testst-testst.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='st/testst.c' object='st/st_testst-testst.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(st_testst_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o st/st_testst-testst.obj `if test -f 'st/testst.c'; then $(CYGPATH_W) 'st/testst.c'; else $(CYGPATH_W) '$(srcdir)/st/testst.c'; fi` + +.cc.o: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ +@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ +@am__fastdepCXX_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< + +.cc.obj: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\ +@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\ +@am__fastdepCXX_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.cc.lo: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\ +@am__fastdepCXX_TRUE@ $(LTCXXCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ +@am__fastdepCXX_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< + +cplusplus/cplusplus_libobj_la-cuddObj.lo: cplusplus/cuddObj.cc +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cplusplus_libobj_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT cplusplus/cplusplus_libobj_la-cuddObj.lo -MD -MP -MF cplusplus/$(DEPDIR)/cplusplus_libobj_la-cuddObj.Tpo -c -o cplusplus/cplusplus_libobj_la-cuddObj.lo `test -f 'cplusplus/cuddObj.cc' || echo '$(srcdir)/'`cplusplus/cuddObj.cc +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) cplusplus/$(DEPDIR)/cplusplus_libobj_la-cuddObj.Tpo cplusplus/$(DEPDIR)/cplusplus_libobj_la-cuddObj.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='cplusplus/cuddObj.cc' object='cplusplus/cplusplus_libobj_la-cuddObj.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cplusplus_libobj_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o cplusplus/cplusplus_libobj_la-cuddObj.lo `test -f 'cplusplus/cuddObj.cc' || echo '$(srcdir)/'`cplusplus/cuddObj.cc + +cplusplus/cudd_libcudd_la-cuddObj.lo: cplusplus/cuddObj.cc +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT cplusplus/cudd_libcudd_la-cuddObj.lo -MD -MP -MF cplusplus/$(DEPDIR)/cudd_libcudd_la-cuddObj.Tpo -c -o cplusplus/cudd_libcudd_la-cuddObj.lo `test -f 'cplusplus/cuddObj.cc' || echo '$(srcdir)/'`cplusplus/cuddObj.cc +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) cplusplus/$(DEPDIR)/cudd_libcudd_la-cuddObj.Tpo cplusplus/$(DEPDIR)/cudd_libcudd_la-cuddObj.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='cplusplus/cuddObj.cc' object='cplusplus/cudd_libcudd_la-cuddObj.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(cudd_libcudd_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cudd_libcudd_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o cplusplus/cudd_libcudd_la-cuddObj.lo `test -f 'cplusplus/cuddObj.cc' || echo '$(srcdir)/'`cplusplus/cuddObj.cc + +cplusplus/cplusplus_testmulti-testmulti.o: cplusplus/testmulti.cc +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cplusplus_testmulti_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT cplusplus/cplusplus_testmulti-testmulti.o -MD -MP -MF cplusplus/$(DEPDIR)/cplusplus_testmulti-testmulti.Tpo -c -o cplusplus/cplusplus_testmulti-testmulti.o `test -f 'cplusplus/testmulti.cc' || echo '$(srcdir)/'`cplusplus/testmulti.cc +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) cplusplus/$(DEPDIR)/cplusplus_testmulti-testmulti.Tpo cplusplus/$(DEPDIR)/cplusplus_testmulti-testmulti.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='cplusplus/testmulti.cc' object='cplusplus/cplusplus_testmulti-testmulti.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cplusplus_testmulti_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o cplusplus/cplusplus_testmulti-testmulti.o `test -f 'cplusplus/testmulti.cc' || echo '$(srcdir)/'`cplusplus/testmulti.cc + +cplusplus/cplusplus_testmulti-testmulti.obj: cplusplus/testmulti.cc +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cplusplus_testmulti_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT cplusplus/cplusplus_testmulti-testmulti.obj -MD -MP -MF cplusplus/$(DEPDIR)/cplusplus_testmulti-testmulti.Tpo -c -o cplusplus/cplusplus_testmulti-testmulti.obj `if test -f 'cplusplus/testmulti.cc'; then $(CYGPATH_W) 'cplusplus/testmulti.cc'; else $(CYGPATH_W) '$(srcdir)/cplusplus/testmulti.cc'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) cplusplus/$(DEPDIR)/cplusplus_testmulti-testmulti.Tpo cplusplus/$(DEPDIR)/cplusplus_testmulti-testmulti.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='cplusplus/testmulti.cc' object='cplusplus/cplusplus_testmulti-testmulti.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cplusplus_testmulti_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o cplusplus/cplusplus_testmulti-testmulti.obj `if test -f 'cplusplus/testmulti.cc'; then $(CYGPATH_W) 'cplusplus/testmulti.cc'; else $(CYGPATH_W) '$(srcdir)/cplusplus/testmulti.cc'; fi` + +cplusplus/cplusplus_testobj-testobj.o: cplusplus/testobj.cc +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cplusplus_testobj_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT cplusplus/cplusplus_testobj-testobj.o -MD -MP -MF cplusplus/$(DEPDIR)/cplusplus_testobj-testobj.Tpo -c -o cplusplus/cplusplus_testobj-testobj.o `test -f 'cplusplus/testobj.cc' || echo '$(srcdir)/'`cplusplus/testobj.cc +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) cplusplus/$(DEPDIR)/cplusplus_testobj-testobj.Tpo cplusplus/$(DEPDIR)/cplusplus_testobj-testobj.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='cplusplus/testobj.cc' object='cplusplus/cplusplus_testobj-testobj.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cplusplus_testobj_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o cplusplus/cplusplus_testobj-testobj.o `test -f 'cplusplus/testobj.cc' || echo '$(srcdir)/'`cplusplus/testobj.cc + +cplusplus/cplusplus_testobj-testobj.obj: cplusplus/testobj.cc +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cplusplus_testobj_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT cplusplus/cplusplus_testobj-testobj.obj -MD -MP -MF cplusplus/$(DEPDIR)/cplusplus_testobj-testobj.Tpo -c -o cplusplus/cplusplus_testobj-testobj.obj `if test -f 'cplusplus/testobj.cc'; then $(CYGPATH_W) 'cplusplus/testobj.cc'; else $(CYGPATH_W) '$(srcdir)/cplusplus/testobj.cc'; fi` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) cplusplus/$(DEPDIR)/cplusplus_testobj-testobj.Tpo cplusplus/$(DEPDIR)/cplusplus_testobj-testobj.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='cplusplus/testobj.cc' object='cplusplus/cplusplus_testobj-testobj.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(cplusplus_testobj_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o cplusplus/cplusplus_testobj-testobj.obj `if test -f 'cplusplus/testobj.cc'; then $(CYGPATH_W) 'cplusplus/testobj.cc'; else $(CYGPATH_W) '$(srcdir)/cplusplus/testobj.cc'; fi` + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + -rm -rf cplusplus/.libs cplusplus/_libs + -rm -rf cudd/.libs cudd/_libs + -rm -rf dddmp/.libs dddmp/_libs + -rm -rf epd/.libs epd/_libs + -rm -rf mtr/.libs mtr/_libs + -rm -rf nanotrav/.libs nanotrav/_libs + -rm -rf st/.libs st/_libs + -rm -rf util/.libs util/_libs + +distclean-libtool: + -rm -f libtool config.lt +install-includeHEADERS: $(include_HEADERS) + @$(NORMAL_INSTALL) + @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \ + $(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \ + done + +uninstall-includeHEADERS: + @$(NORMAL_UNINSTALL) + @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir) + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscope: cscope.files + test ! -s cscope.files \ + || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS) +clean-cscope: + -rm -f cscope.files +cscope.files: clean-cscope cscopelist +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + -rm -f cscope.out cscope.in.out cscope.po.out cscope.files + +# Recover from deleted '.trs' file; this should ensure that +# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create +# both 'foo.log' and 'foo.trs'. Break the recipe in two subshells +# to avoid problems with "make -n". +.log.trs: + rm -f $< $@ + $(MAKE) $(AM_MAKEFLAGS) $< + +# Leading 'am--fnord' is there to ensure the list of targets does not +# expand to empty, as could happen e.g. with make check TESTS=''. +am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck) +am--force-recheck: + @: + +$(TEST_SUITE_LOG): $(TEST_LOGS) + @$(am__set_TESTS_bases); \ + am__f_ok () { test -f "$$1" && test -r "$$1"; }; \ + redo_bases=`for i in $$bases; do \ + am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \ + done`; \ + if test -n "$$redo_bases"; then \ + redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \ + redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \ + if $(am__make_dryrun); then :; else \ + rm -f $$redo_logs && rm -f $$redo_results || exit 1; \ + fi; \ + fi; \ + if test -n "$$am__remaking_logs"; then \ + echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \ + "recursion detected" >&2; \ + elif test -n "$$redo_logs"; then \ + am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \ + fi; \ + if $(am__make_dryrun); then :; else \ + st=0; \ + errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \ + for i in $$redo_bases; do \ + test -f $$i.trs && test -r $$i.trs \ + || { echo "$$errmsg $$i.trs" >&2; st=1; }; \ + test -f $$i.log && test -r $$i.log \ + || { echo "$$errmsg $$i.log" >&2; st=1; }; \ + done; \ + test $$st -eq 0 || exit 1; \ + fi + @$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \ + ws='[ ]'; \ + results=`for b in $$bases; do echo $$b.trs; done`; \ + test -n "$$results" || results=/dev/null; \ + all=` grep "^$$ws*:test-result:" $$results | wc -l`; \ + pass=` grep "^$$ws*:test-result:$$ws*PASS" $$results | wc -l`; \ + fail=` grep "^$$ws*:test-result:$$ws*FAIL" $$results | wc -l`; \ + skip=` grep "^$$ws*:test-result:$$ws*SKIP" $$results | wc -l`; \ + xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \ + xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \ + error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \ + if test `expr $$fail + $$xpass + $$error` -eq 0; then \ + success=true; \ + else \ + success=false; \ + fi; \ + br='==================='; br=$$br$$br$$br$$br; \ + result_count () \ + { \ + if test x"$$1" = x"--maybe-color"; then \ + maybe_colorize=yes; \ + elif test x"$$1" = x"--no-color"; then \ + maybe_colorize=no; \ + else \ + echo "$@: invalid 'result_count' usage" >&2; exit 4; \ + fi; \ + shift; \ + desc=$$1 count=$$2; \ + if test $$maybe_colorize = yes && test $$count -gt 0; then \ + color_start=$$3 color_end=$$std; \ + else \ + color_start= color_end=; \ + fi; \ + echo "$${color_start}# $$desc $$count$${color_end}"; \ + }; \ + create_testsuite_report () \ + { \ + result_count $$1 "TOTAL:" $$all "$$brg"; \ + result_count $$1 "PASS: " $$pass "$$grn"; \ + result_count $$1 "SKIP: " $$skip "$$blu"; \ + result_count $$1 "XFAIL:" $$xfail "$$lgn"; \ + result_count $$1 "FAIL: " $$fail "$$red"; \ + result_count $$1 "XPASS:" $$xpass "$$red"; \ + result_count $$1 "ERROR:" $$error "$$mgn"; \ + }; \ + { \ + echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" | \ + $(am__rst_title); \ + create_testsuite_report --no-color; \ + echo; \ + echo ".. contents:: :depth: 2"; \ + echo; \ + for b in $$bases; do echo $$b; done \ + | $(am__create_global_log); \ + } >$(TEST_SUITE_LOG).tmp || exit 1; \ + mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG); \ + if $$success; then \ + col="$$grn"; \ + else \ + col="$$red"; \ + test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG); \ + fi; \ + echo "$${col}$$br$${std}"; \ + echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}"; \ + echo "$${col}$$br$${std}"; \ + create_testsuite_report --maybe-color; \ + echo "$$col$$br$$std"; \ + if $$success; then :; else \ + echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}"; \ + if test -n "$(PACKAGE_BUGREPORT)"; then \ + echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}"; \ + fi; \ + echo "$$col$$br$$std"; \ + fi; \ + $$success || exit 1 + +check-TESTS: + @list='$(RECHECK_LOGS)'; test -z "$$list" || rm -f $$list + @list='$(RECHECK_LOGS:.log=.trs)'; test -z "$$list" || rm -f $$list + @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) + @set +e; $(am__set_TESTS_bases); \ + log_list=`for i in $$bases; do echo $$i.log; done`; \ + trs_list=`for i in $$bases; do echo $$i.trs; done`; \ + log_list=`echo $$log_list`; trs_list=`echo $$trs_list`; \ + $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) TEST_LOGS="$$log_list"; \ + exit $$?; +recheck: all $(check_PROGRAMS) $(check_SCRIPTS) $(dist_check_DATA) + @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) + @set +e; $(am__set_TESTS_bases); \ + bases=`for i in $$bases; do echo $$i; done \ + | $(am__list_recheck_tests)` || exit 1; \ + log_list=`for i in $$bases; do echo $$i.log; done`; \ + log_list=`echo $$log_list`; \ + $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \ + am__force_recheck=am--force-recheck \ + TEST_LOGS="$$log_list"; \ + exit $$? +.test.log: + @p='$<'; \ + $(am__set_b); \ + $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ + --log-file $$b.log --trs-file $$b.trs \ + $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ + "$$tst" $(AM_TESTS_FD_REDIRECT) +@am__EXEEXT_TRUE@.test$(EXEEXT).log: +@am__EXEEXT_TRUE@ @p='$<'; \ +@am__EXEEXT_TRUE@ $(am__set_b); \ +@am__EXEEXT_TRUE@ $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ +@am__EXEEXT_TRUE@ --log-file $$b.log --trs-file $$b.trs \ +@am__EXEEXT_TRUE@ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ +@am__EXEEXT_TRUE@ "$$tst" $(AM_TESTS_FD_REDIRECT) + +distdir: $(DISTFILES) + $(am__remove_distdir) + test -d "$(distdir)" || mkdir "$(distdir)" + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$(top_distdir)" distdir="$(distdir)" \ + dist-hook + -test -n "$(am__skip_mode_fix)" \ + || find "$(distdir)" -type d ! -perm -755 \ + -exec chmod u+rwx,go+rx {} \; -o \ + ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ + ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ + ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ + || chmod -R a+r "$(distdir)" +dist-gzip: distdir + tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz + $(am__post_remove_distdir) + +dist-bzip2: distdir + tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 + $(am__post_remove_distdir) + +dist-lzip: distdir + tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz + $(am__post_remove_distdir) + +dist-xz: distdir + tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz + $(am__post_remove_distdir) + +dist-tarZ: distdir + @echo WARNING: "Support for distribution archives compressed with" \ + "legacy program 'compress' is deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 + tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z + $(am__post_remove_distdir) + +dist-shar: distdir + @echo WARNING: "Support for shar distribution archives is" \ + "deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 + shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz + $(am__post_remove_distdir) + +dist-zip: distdir + -rm -f $(distdir).zip + zip -rq $(distdir).zip $(distdir) + $(am__post_remove_distdir) + +dist dist-all: + $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:' + $(am__post_remove_distdir) + +# This target untars the dist file and tries a VPATH configuration. Then +# it guarantees that the distribution is self-contained by making another +# tarfile. +distcheck: dist + case '$(DIST_ARCHIVES)' in \ + *.tar.gz*) \ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ + *.tar.bz2*) \ + bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ + *.tar.lz*) \ + lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ + *.tar.xz*) \ + xz -dc $(distdir).tar.xz | $(am__untar) ;;\ + *.tar.Z*) \ + uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ + *.shar.gz*) \ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\ + *.zip*) \ + unzip $(distdir).zip ;;\ + esac + chmod -R a-w $(distdir) + chmod u+w $(distdir) + mkdir $(distdir)/_build $(distdir)/_build/sub $(distdir)/_inst + chmod a-w $(distdir) + test -d $(distdir)/_build || exit 0; \ + dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ + && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ + && am__cwd=`pwd` \ + && $(am__cd) $(distdir)/_build/sub \ + && ../../configure \ + $(AM_DISTCHECK_CONFIGURE_FLAGS) \ + $(DISTCHECK_CONFIGURE_FLAGS) \ + --srcdir=../.. --prefix="$$dc_install_base" \ + && $(MAKE) $(AM_MAKEFLAGS) \ + && $(MAKE) $(AM_MAKEFLAGS) dvi \ + && $(MAKE) $(AM_MAKEFLAGS) check \ + && $(MAKE) $(AM_MAKEFLAGS) install \ + && $(MAKE) $(AM_MAKEFLAGS) installcheck \ + && $(MAKE) $(AM_MAKEFLAGS) uninstall \ + && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ + distuninstallcheck \ + && chmod -R a-w "$$dc_install_base" \ + && ({ \ + (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ + distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ + } || { rm -rf "$$dc_destdir"; exit 1; }) \ + && rm -rf "$$dc_destdir" \ + && $(MAKE) $(AM_MAKEFLAGS) dist \ + && rm -rf $(DIST_ARCHIVES) \ + && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ + && cd "$$am__cwd" \ + || exit 1 + $(am__post_remove_distdir) + @(echo "$(distdir) archives ready for distribution: "; \ + list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ + sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' +distuninstallcheck: + @test -n '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: trying to run $@ with an empty' \ + '$$(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + $(am__cd) '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \ + || { echo "ERROR: files left after uninstall:" ; \ + if test -n "$(DESTDIR)"; then \ + echo " (check DESTDIR support)"; \ + fi ; \ + $(distuninstallcheck_listfiles) ; \ + exit 1; } >&2 +distcleancheck: distclean + @if test '$(srcdir)' = . ; then \ + echo "ERROR: distcleancheck can only run from a VPATH build" ; \ + exit 1 ; \ + fi + @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ + || { echo "ERROR: files left in build directory after distclean:" ; \ + $(distcleancheck_listfiles) ; \ + exit 1; } >&2 +check-am: all-am + $(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS) $(check_SCRIPTS) \ + $(dist_check_DATA) + $(MAKE) $(AM_MAKEFLAGS) check-TESTS +check: check-am +all-am: Makefile $(LTLIBRARIES) $(HEADERS) config.h +installdirs: + for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + -test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS) + -test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs) + -test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -rm -f cplusplus/$(DEPDIR)/$(am__dirstamp) + -rm -f cplusplus/$(am__dirstamp) + -rm -f cudd/$(DEPDIR)/$(am__dirstamp) + -rm -f cudd/$(am__dirstamp) + -rm -f dddmp/$(DEPDIR)/$(am__dirstamp) + -rm -f dddmp/$(am__dirstamp) + -rm -f epd/$(DEPDIR)/$(am__dirstamp) + -rm -f epd/$(am__dirstamp) + -rm -f mtr/$(DEPDIR)/$(am__dirstamp) + -rm -f mtr/$(am__dirstamp) + -rm -f nanotrav/$(DEPDIR)/$(am__dirstamp) + -rm -f nanotrav/$(am__dirstamp) + -rm -f st/$(DEPDIR)/$(am__dirstamp) + -rm -f st/$(am__dirstamp) + -rm -f util/$(DEPDIR)/$(am__dirstamp) + -rm -f util/$(am__dirstamp) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-checkPROGRAMS clean-generic clean-libLTLIBRARIES \ + clean-libtool clean-noinstLTLIBRARIES mostlyclean-am + +distclean: distclean-am + -rm -f $(am__CONFIG_DISTCLEAN_FILES) + -rm -rf cplusplus/$(DEPDIR) cudd/$(DEPDIR) dddmp/$(DEPDIR) epd/$(DEPDIR) mtr/$(DEPDIR) nanotrav/$(DEPDIR) st/$(DEPDIR) util/$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-hdr distclean-libtool distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-includeHEADERS + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: install-libLTLIBRARIES + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f $(am__CONFIG_DISTCLEAN_FILES) + -rm -rf $(top_srcdir)/autom4te.cache + -rm -rf cplusplus/$(DEPDIR) cudd/$(DEPDIR) dddmp/$(DEPDIR) epd/$(DEPDIR) mtr/$(DEPDIR) nanotrav/$(DEPDIR) st/$(DEPDIR) util/$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-includeHEADERS uninstall-libLTLIBRARIES + +.MAKE: all check-am install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am am--refresh check check-TESTS \ + check-am clean clean-checkPROGRAMS clean-cscope clean-generic \ + clean-libLTLIBRARIES clean-libtool clean-noinstLTLIBRARIES \ + cscope cscopelist-am ctags ctags-am dist dist-all dist-bzip2 \ + dist-gzip dist-hook dist-lzip dist-shar dist-tarZ dist-xz \ + dist-zip distcheck distclean distclean-compile \ + distclean-generic distclean-hdr distclean-libtool \ + distclean-tags distcleancheck distdir distuninstallcheck dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-html install-html-am \ + install-includeHEADERS install-info install-info-am \ + install-libLTLIBRARIES install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + recheck tags tags-am uninstall uninstall-am \ + uninstall-includeHEADERS uninstall-libLTLIBRARIES + +.PRECIOUS: Makefile + + +cudd/test_cudd.test: cudd/test_cudd.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ + +st/test_st.test: st/test_st.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ + +mtr/test_mtr.test: mtr/test_mtr.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ + +dddmp/test_dddmp.test: dddmp/test_dddmp.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ + +cplusplus/test_obj.test: cplusplus/test_obj.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ + +nanotrav/test_ntrv.test: nanotrav/test_ntrv.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ + +@HAVE_PDFLATEX_TRUE@doc/cudd.pdf: doc/cudd.tex $(top_srcdir)/doc/phase.pdf +@HAVE_PDFLATEX_TRUE@ @if $(AM_V_P); then dest='2>&1'; else dest='> /dev/null 2>&1'; fi; \ +@HAVE_PDFLATEX_TRUE@ cd doc && eval "$(PDFLATEX) cudd $${dest}" && \ +@HAVE_PDFLATEX_TRUE@ eval "$(MAKEINDEX) cudd $${dest}" && \ +@HAVE_PDFLATEX_TRUE@ eval "$(PDFLATEX) cudd $${dest}" && \ +@HAVE_PDFLATEX_TRUE@ eval "$(PDFLATEX) cudd $${dest}" + +@HAVE_PDFLATEX_FALSE@doc/cudd.pdf: + +dist-hook: + rm -rf `find $(distdir) -name .svn` + +.PHONY : + +all: html/index.html doc/cudd.pdf + +#if HAVE_DOXYGEN +# +#html/index.html: Doxyfile $(lib_LTLIBRARIES) +# @if $(AM_V_P); then dest='2>&1'; else dest='> /dev/null 2>&1'; fi; \ +# eval "$(DOXYGEN) $< $${dest}" +# +#clean-local: +# rm -rf html doxygen_sqlite3.db +# +#else + +html/index.html: + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/resources/3rdparty/cudd-3.0.0/README b/resources/3rdparty/cudd-3.0.0/README new file mode 100644 index 000000000..4858eb1d9 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/README @@ -0,0 +1,117 @@ +The CUDD package is a package written in C for the manipulation of +decision diagrams. It supports binary decision diagrams (BDDs), +algebraic decision diagrams (ADDs), and Zero-Suppressed BDDs (ZDDs). + +This directory contains a set of packages that allow you to build a test +application based on the CUDD package. + +The test application provided in this kit is called nanotrav and is a +simple-minded FSM traversal program. (See the README file and the man +page nanotrav.1 in the nanotrav directory for the details.) It is +included so that you can run a sanity check on your installation. + +Also included in this distribution are the dddmp libray by Giampiero +Cabodi and Stefano Quer and a C++ object-oriented wrapper for CUDD. + +BUILD AND INSTALLATION + +In the simplest form, you can build the static libraries with: + + ./configure + make + make check + +The configure script provides a few options, which can be listed with + + ./configure --help + +Notable options include + + --enable-silent-rules + --enable-shared + --enable-dddmp + --enable-obj + --with-system-qsort + +The --enable-silent-rules option is a standard option that streamlines the +messages produced by the build process. The remaining options are specific +to CUDD. + +The three "enable" options control the build of shared libraries. By +default, only static libraries are built. With --enable-shared, a +shared library for libcudd is built. (Before installation, it can be +found in cudd/.libs.) + +The last two "enable" options control the inclusion of the dddmp +library and C++ wrapper in the shared library, which by default only +contains the core CUDD library. + +The --with-system-qsort option requests use of the qsort from the +standard library instead of the portable one shipped with CUDD. This +option is provided for backward compatibility and is not otherwise +recommended. Some of the tests of "make check" may fail with the +system qsort because variable orders may be generated that are +different from the reference ones. + +As an example, a more elaborate build command sequence may be: + + ./configure CC=clang CXX=clang++ --enable-silent-rules \ + --enable-shared --enable-obj + make -j4 check + make install + +which selects alternate compilers instead of gcc and g++, causes the +C++ wrapper to be included in the shared library, enables parallel +compilation (with -j4) and finally installs the shared library using +the default prefix /usr/local. + +For those unfamiliar with libtool it may be worth noting that the +libraries it builds go in .libs subdirectories. One should also note +that with shared libraries enabled, the test programs immediately +visible to the user are shell scripts that make sure dynamic linking +works before installation. If you want to run valgrind on, say, a +dynamically linked nanotrav, specify the option --trace-children=yes. + +PLATFORMS + +This kit has been successfully built on the following configurations: + + PC (x86 and x86_64) running Ubuntu with gcc and clang + PC (x86 and x86_64) running Ubuntu with g++ + PC (x86 and x86_64) running Linux RedHat with gcc + PC (x86 and x86_64) running Linux RedHat with g++ + PC (x86_64) running 32-bit Cygwin on Windows 7 and Vista with gcc + PC (x86_64) running 32-bit Cygwin on Windows 7 and Vista with g++ + PC (x86_64) running 64-bit Cygwin on Windows 8.1 with gcc and g++ + PC (x86_64) running MinGW-w64 on Windows 8.1 with gcc + +In all these cases, the C++ wrapper was compiled with the matching C++ +compiler (g++ for gcc and clang++ for clang). To compile under MSYS2 +(MinGW-w64) one has to pass --build=x86_64-w64-mingw32 to ./configure. + +SANITY CHECK + +The directory `nanotrav' contains a simple application based on the +CUDD package. The `nanotrav' directory contains a man page that +describes the options nanotrav supports. The files *.blif are sample +input files for nanotrav. The *.out files are the reference output +files. + +DOCUMENTATION + +If doxygen is installed, running "make" puts HTML documentation for +the CUDD package in directory cudd-3.0.0/cudd/html. The recommended +starting point is index.html. The user's manual in PDF format is +built in cudd-3.0.0/doc if pdflatex and makeindex are installed. +Documentation for the dddmp library is in the dddmp/doc subdirectory. + +FEEDBACK: + +Send feedback to: + +Fabio Somenzi +University of Colorado at Boulder +ECE Dept. +Boulder, CO 80309-0425 +Fabio@Colorado.EDU +http://vlsi.colorado.edu/~fabio diff --git a/resources/3rdparty/cudd-3.0.0/RELEASE.NOTES b/resources/3rdparty/cudd-3.0.0/RELEASE.NOTES new file mode 100644 index 000000000..adf4fdcc4 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/RELEASE.NOTES @@ -0,0 +1,344 @@ +Release 3.0.0 of Cudd uses autotools for its build. It can also +produce a shared library. The shared library contains the core CUDD +functions, and, optionally, the dddmp functions and the C++ wrapper. +It is now safe to use separate CUDD managers in different threads. + +There are changes in the API, discussed later. The documentation is +now extracted from the code by Doxygen. About a dozen bugs were fixed +in seldom-used functions. + +The switch to autotools means that one no longer needs to edit the +configuration section of the main Makefile. It was also instrumental +in providing shared library support (via libtool) on multiple +platforms and a "check" make target worth its name. Initial support +for cross compilation has been added. + +Build time is significantly longer, especially the first time, and +especially when shared libraries are enabled. In return one gets +dependency tracking, support for VPATH builds, packaging of +distributions, and so on. + +The CUDD package and its sub-packages now expose significantly fewer +details of their implementations to the applications. It is now +possible to compile a CUDD-based application while including only the +cudd.h header and linking only libcudd.a (or the equivalent shared +library). A few const type qualifiers have been added to APIs too. + +Some macros have been turned into functions to improve encapsulation, +namely Cudd_T, Cudd_E, Cudd_V, and Cudd_IsConstant. Another API +change brought about by this restructuring is that the digits of +arbitrary-precision integers are now always 32-bit wide. As a +consequence, the function Cudd_ApaIntDivision is now deprecated. + +The malloc/realloc/free wrappers in safe_mem.c have been simplified +and made more consistent with the standard functions. (The majority +of what the wrappers did was supplying functionality that any modern +compliant implementation of C would supply anyway.) Some parts of the +util library are no longer distributed with CUDD. (They were never +used by it.) + +Applications that call functions from the mtr or epd packages now have +to explicitly include their headers _before_ including cudd.h. +Applications that access data structures that are no longer exposed +should declare their close kinship with those data structure by +including the internal headers. + +There is a new function in the API, Cudd_PrintSummary, that is +analogous to Cudd_PrintDebug, but only prints one line using +arbitrary-precision arithmetic to compute the number of minterms. The +function Cudd_ApaPrintExponential now behaves like printf of glibc with +a "g" conversion specifier. These changes were motivated by the +discrepancies between printfs on Linux and Windows that affected "make +check." + +CUDD now explicitly calls an implementation of qsort that is included +in the util library. While this version of qsort has been shipped +with CUDD since Release 1.0.0, it was up to the application to decide +whether to link it or not. However, dynamic linking on Windows and OS +X makes it difficult to replace the system qsort with a function of +the same name; hence, there is now a util_qsort in the CUDD library. +(The main reasons for not using the system qsort are repeatability and +performance of variable reordering.) To use the system qsort, +configure CUDD with the --with-system-qsort option. Keep in mind that +some tests in "make check" may fail in this case by producing variable +orders different from the reference ones. + +The random number generator is now local to a manager. The interface +has changed accordingly. The only global variable in the whole +package is the one used to store the out-of-memory handler. As long +as it is not modified, distinct CUDD managers can be run in different +threads. + +Even with a portable sort routine and random number generator, CUDD +does not guarantee the same output on all platforms. For instance, +the simulated annealing reordering algorithm uses floating-point +arithmetic, and the results on i686 machines occasionally differ from +those on x86_64 machines. + +In the C++ wrapper, the default error handler now throws an exception +instead of failing. A new function helps in handling failed memory +allocations: Cudd_InstallOutOfMemoryHandler; it can be used to modify +the default behavior, which is to terminate the program. There are a +few new functions in the C++ API and a substantial clean-up has taken +place. Several functions have had some of their parameters given +default values, and in a few cases the order of the parameters has +been changed to improve consistency. + +New functions: + +DD_OOMFP Cudd_InstallOutOfMemoryHandler(DD_OOMFP newHandler); + +DD_OOMFP Cudd_RegisterOutOfMemoryCallback(DdManager *unique, DD_OOMFP callback); + +void Cudd_UnregisterOutOfMemoryCallback(DdManager *unique); + +void Cudd_OutOfMemSilent(size_t size); + +DdNode * Cudd_bddInterpolate(DdManager * dd, DdNode * l, DdNode * u); + +int Cudd_VarsAreSymmetric(DdManager * dd, DdNode * f, int index1, int index2); + +int Cudd_PrintSummary(DdManager * dd, DdNode * f, int n, int mode); + +void Cudd_FreeApaNumber(DdApaNumber number); + +char * Cudd_ApaStringDecimal(int digits, DdConstApaNumber number); + +long double Cudd_LdblCountMinterm(DdManager const *manager, DdNode *node, + int nvars); + +int Cudd_EpdPrintMinterm(DdManager const * dd, DdNode * node, int nvars); + +st_table * st_init_table_with_params_and_arg(st_compare_arg_t, + st_hash_arg_t, void const *, int, int, double, int); + +st_table * st_init_table_with_arg(st_compare_arg_t, st_hash_arg_t, + void const *); + +void ABDD::summary(int nvars, int mode = 0) const; + +DD_OOMFP Cudd::InstallOutOfMemoryHandler(DD_OOMFP newHandler) const; + +DD_OOMFP RegisterOutOfMemoryCallback(DD_OOMFP callback) const; + +void UnregisterOutOfMemoryCallback(void) const; + +BDD computeCube(std::vector<BDD> const & vars) const; + +ADD computeCube(std::vector<ADD> const & vars) const; + +BDD BDD::Interpolate(const BDD& u) const; + +bool BDD::VarAreSymmetric(int index1, int index2) const; + +std::string ApaStringDecimal(int digits, DdApaNumber number) const; + +void Cudd::ApaPrintExponential(int digits, DdApaNumber number, + int precision = 6, FILE * fp = stdout) const; + +void ApaPrintMintermExp(int nvars, int precision = 6, FILE * fp = stdout) const; + +long double LdblCountMinterm(int nvars) const; + +ADD Cudd::Harwell(FILE * fp, std::vector<ADD>& x, std::vector<ADD>& y, + std::vector<ADD>& xn, std::vector<ADD>& yn_, + int * m, int * n, int bx = 0, int sx = 2, int by = 1, + int sy = 2, int pr = 0) const; + +ADD Cudd::Read(FILE * fp, std::vector<ADD>& x, std::vector<ADD>& y, + std::vector<ADD>& xn, std::vector<ADD>& yn_, int * m, int * n, + int bx = 0, int sx = 2, int by = 1, int sy = 2) const; +BDD Cudd::Read(FILE * fp, std::vector<BDD>& x, std::vector<BDD>& y, + int * m, int * n, int bx = 0, int sx = 2, int by = 1, + int sy = 2) const; + +std::string Cudd::OrderString(void) const; + +Special thanks go to Hubert Garavel for the many discussions that have +greatly contributed to shaping this new CUDD release. + +---------------------------------------------------------------------- + +Release 2.6.0 of Cudd is the first release to compile out of the box +with MinGW-w64. This is achieved primarily by using types and macros +defined in inttypes.h. The only visible changes in the API are some +parameter types that are now "size_t" instead of "unsinged long." + +Support for multi-threaded applications has been slightly enhanced. +The Makefile has been slightly enhanced and finally supports creation +of top-level tag files for both emacs and vi. + +The code has been cleaned up a bit so that all warnings that would be +produced by gcc with "-Wextra" have been removed. The tests run by +nanotrav/tst.sh and obj/testobj cover a bit more of the package's +functionality. + +---------------------------------------------------------------------- + +Release 2.5.1 of Cudd improves support for multi-threaded applications. +Specifically, an application may now register a callback function that +is called from time to time to check whether computation should be +terminated because another thread has found the result. + +The C++ interface allows the application to register variable names with +the manager and implements operator<< for BDDs. The interfaces of +SolveEqn and VerifySol now take std::vectors instead of plain arrays. + +Fixed a few bugs in CUDD and a bug in the mtr package. + +Added const qualifiers to dumping function interfaces +(Cudd_DumpDot,...). + +The Makefile now supports gmake's -j option. Change "@+" back to "@" if +this causes problems with your make program. + +Buggy documentation that was shipped with 2.5.0 has been fixed. + +New functions: + +int Cudd_bddIsVar(DdManager * dd, DdNode * f); + +void Cudd_RegisterTerminationCallback(DdManager *unique, + +void Cudd_UnregisterTerminationCallback(DdManager *unique); + +void Cudd_SetApplicationHook(DdManager *dd, void * value); + +void * Cudd_ReadApplicationHook(DdManager *dd); + +char * Cudd_FactoredFormString(DdManager *dd, DdNode *f, + char const * const * inames); + +---------------------------------------------------------------------- + +Releas 2.5.0 of Cudd introduces the ability to set timeouts. The +function that is interrupted returns NULL (which the application must +be prepared to handle,) but the BDDs are uncorrupted and the invoking +program can continue to use the manager. + +In addition, reordering is now aware of timeouts, so that it gives up +when a timeout is approaching to give the invoking program a chance to +obtain some results. + +The response time to the timeout is not immediate, though most of the time +it is well below one second. Checking for timeouts has a small overhead. +In experiments, less than 1% has been observed on average. + +Creation of BDD managers with many variables (e.g., tens or hundreds +of thousands) is now much more efficient. Computing small supports of +BDDs when there are many variables is also much more efficient, but +this has been at the cost of separating the function for BDDs and ADDs +(Cudd_Support) from that for ZDDs (Cudd_zddSupport). + +The C++ interface has undergone a major upgrade. + +The handling of variable gruops in reordering has been much improved. +(Thanks to Arie Gurfinkel for a very detailed bug report!) A handful +of other bugs have been fixed as well. + + +New Functions: + +unsigned long Cudd_ReadStartTime(DdManager *unique); + +unsigned long Cudd_ReadElapsedTime(DdManager *unique); + +void Cudd_SetStartTime(DdManager *unique, unsigned long st); + +void Cudd_ResetStartTime(DdManager *unique); + +unsigned long Cudd_ReadTimeLimit(DdManager *unique); + +void Cudd_SetTimeLimit(DdManager *unique, unsigned long tl); + +void Cudd_UpdateTimeLimit(DdManager * unique); + +void Cudd_IncreaseTimeLimit(DdManager * unique, unsigned long increase); + +void Cudd_UnsetTimeLimit(DdManager *unique); + +int Cudd_TimeLimited(DdManager *unique); + +unsigned int Cudd_ReadMaxReorderings (DdManager *dd); + +void Cudd_SetMaxReorderings (DdManager *dd, unsigned int mr); + +unsigned int Cudd_ReadOrderRandomization(DdManager * dd); + +void Cudd_SetOrderRandomization(DdManager * dd, unsigned int factor); + +int Cudd_PrintGroupedOrder(DdManager * dd, const char *str, void *data); + +int Cudd_EnableOrderingMonitoring(DdManager *dd); + +int Cudd_DisableOrderingMonitoring(DdManager *dd); + +int Cudd_OrderingMonitoring(DdManager *dd); + +DdNode * Cudd_bddExistAbstractLimit(DdManager * manager, DdNode * f, DdNode * cube, unsigned int limit); + +DdNode * Cudd_bddIteLimit (DdManager *dd, DdNode *f, DdNode *g, DdNode *h, unsigned int limit); + +DdNode * Cudd_bddOrLimit (DdManager *dd, DdNode *f, DdNode *g, unsigned int limit); + +DdNode * Cudd_bddXnorLimit (DdManager *dd, DdNode *f, DdNode *g, unsigned int limit); + +int Cudd_CheckCube (DdManager *dd, DdNode *g); + +DdNode * Cudd_bddMaximallyExpand(DdManager *dd, DdNode *lb, DdNode *ub, DdNode *f); + +DdNode * Cudd_bddLargestPrimeUnate(DdManager *dd , DdNode *f, DdNode *phaseBdd); + +int Cudd_Reserve(DdManager *manager, int amount); + +int Cudd_SupportIndices(DdManager * dd, DdNode * f, int **indices); + +int Cudd_VectorSupportIndices(DdManager * dd, DdNode ** F, int n, int **indices); + +DdNode * Cudd_zddSupport(DdManager * dd, DdNode * f); + + +Changed prototypes: + +unsigned int Cudd_ReadReorderings (DdManager *dd); + +---------------------------------------------------------------------- + +Release 2.4.2 of Cudd features several bug fixes. The most important +are those that prevented Cudd from making full use of up to 4 GB of +memory when using 32-bit pointers. A handful of bugs were discovered by +Coverity. (Thanks to Christian Stangier!) + +This release can be compiled with either 64-bit pointers or 32-bit +pointers on x86_64 platforms if sizeof(long) = sizeof(void *) = 8 and +sizeof(int) = 4. This is known as the LP64 model. For 32-bit pointers, +one usually needs supplementary libraries. On Ubuntu and Debian Linux, +one needs g++-multilib, which can be installed with +"apt-get install g++-multilib." + +Added functions + +DdNode *Cudd_Inequality (DdManager * dd, int N, int c, DdNode ** x, +DdNode ** y); + +DdNode * Cudd_Disequality (DdManager * dd, int N, int c, DdNode ** x, +DdNode ** y); + +DdNode * Cudd_bddInterval (DdManager * dd, int N, DdNode ** x, +unsigned int lowerB, unsigned int upperB); + +Changed prototypes: + +int Cudd_DumpBlif (DdManager *dd, int n, DdNode **f, char +**inames, char **onames, char *mname, FILE *fp, int mv); + +int Cudd_DumpBlifBody (DdManager *dd, int n, DdNode **f, char +**inames, char **onames, FILE *fp, int mv); + +The additional parameter allows the caller to choose between plain blif +and blif-MV. + +---------------------------------------------------------------------- + +Release 2.4.1 of Cudd features one major change with respect to previous +releases. The licensing terms are now explicitly stated. diff --git a/resources/3rdparty/cudd-3.0.0/aclocal.m4 b/resources/3rdparty/cudd-3.0.0/aclocal.m4 new file mode 100644 index 000000000..0de6688a7 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/aclocal.m4 @@ -0,0 +1,1256 @@ +# generated automatically by aclocal 1.15 -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. + +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) +m4_ifndef([AC_AUTOCONF_VERSION], + [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl +m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],, +[m4_warning([this file was generated for autoconf 2.69. +You have another version of autoconf. It may work, but is not guaranteed to. +If you have problems, you may need to regenerate the build system entirely. +To do so, use the procedure documented by the package, typically 'autoreconf'.])]) + +# Copyright (C) 2002-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_AUTOMAKE_VERSION(VERSION) +# ---------------------------- +# Automake X.Y traces this macro to ensure aclocal.m4 has been +# generated from the m4 files accompanying Automake X.Y. +# (This private macro should not be called outside this file.) +AC_DEFUN([AM_AUTOMAKE_VERSION], +[am__api_version='1.15' +dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to +dnl require some minimum version. Point them to the right macro. +m4_if([$1], [1.15], [], + [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl +]) + +# _AM_AUTOCONF_VERSION(VERSION) +# ----------------------------- +# aclocal traces this macro to find the Autoconf version. +# This is a private macro too. Using m4_define simplifies +# the logic in aclocal, which can simply ignore this definition. +m4_define([_AM_AUTOCONF_VERSION], []) + +# AM_SET_CURRENT_AUTOMAKE_VERSION +# ------------------------------- +# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. +# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. +AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], +[AM_AUTOMAKE_VERSION([1.15])dnl +m4_ifndef([AC_AUTOCONF_VERSION], + [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl +_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) + +# Copyright (C) 2011-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_PROG_AR([ACT-IF-FAIL]) +# ------------------------- +# Try to determine the archiver interface, and trigger the ar-lib wrapper +# if it is needed. If the detection of archiver interface fails, run +# ACT-IF-FAIL (default is to abort configure with a proper error message). +AC_DEFUN([AM_PROG_AR], +[AC_BEFORE([$0], [LT_INIT])dnl +AC_BEFORE([$0], [AC_PROG_LIBTOOL])dnl +AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([ar-lib])dnl +AC_CHECK_TOOLS([AR], [ar lib "link -lib"], [false]) +: ${AR=ar} + +AC_CACHE_CHECK([the archiver ($AR) interface], [am_cv_ar_interface], + [AC_LANG_PUSH([C]) + am_cv_ar_interface=ar + AC_COMPILE_IFELSE([AC_LANG_SOURCE([[int some_variable = 0;]])], + [am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&AS_MESSAGE_LOG_FD' + AC_TRY_EVAL([am_ar_try]) + if test "$ac_status" -eq 0; then + am_cv_ar_interface=ar + else + am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&AS_MESSAGE_LOG_FD' + AC_TRY_EVAL([am_ar_try]) + if test "$ac_status" -eq 0; then + am_cv_ar_interface=lib + else + am_cv_ar_interface=unknown + fi + fi + rm -f conftest.lib libconftest.a + ]) + AC_LANG_POP([C])]) + +case $am_cv_ar_interface in +ar) + ;; +lib) + # Microsoft lib, so override with the ar-lib wrapper script. + # FIXME: It is wrong to rewrite AR. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__AR in this case, + # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something + # similar. + AR="$am_aux_dir/ar-lib $AR" + ;; +unknown) + m4_default([$1], + [AC_MSG_ERROR([could not determine $AR interface])]) + ;; +esac +AC_SUBST([AR])dnl +]) + +# AM_AUX_DIR_EXPAND -*- Autoconf -*- + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets +# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to +# '$srcdir', '$srcdir/..', or '$srcdir/../..'. +# +# Of course, Automake must honor this variable whenever it calls a +# tool from the auxiliary directory. The problem is that $srcdir (and +# therefore $ac_aux_dir as well) can be either absolute or relative, +# depending on how configure is run. This is pretty annoying, since +# it makes $ac_aux_dir quite unusable in subdirectories: in the top +# source directory, any form will work fine, but in subdirectories a +# relative path needs to be adjusted first. +# +# $ac_aux_dir/missing +# fails when called from a subdirectory if $ac_aux_dir is relative +# $top_srcdir/$ac_aux_dir/missing +# fails if $ac_aux_dir is absolute, +# fails when called from a subdirectory in a VPATH build with +# a relative $ac_aux_dir +# +# The reason of the latter failure is that $top_srcdir and $ac_aux_dir +# are both prefixed by $srcdir. In an in-source build this is usually +# harmless because $srcdir is '.', but things will broke when you +# start a VPATH build or use an absolute $srcdir. +# +# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, +# iff we strip the leading $srcdir from $ac_aux_dir. That would be: +# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` +# and then we would define $MISSING as +# MISSING="\${SHELL} $am_aux_dir/missing" +# This will work as long as MISSING is not called from configure, because +# unfortunately $(top_srcdir) has no meaning in configure. +# However there are other variables, like CC, which are often used in +# configure, and could therefore not use this "fixed" $ac_aux_dir. +# +# Another solution, used here, is to always expand $ac_aux_dir to an +# absolute PATH. The drawback is that using absolute paths prevent a +# configured tree to be moved without reconfiguration. + +AC_DEFUN([AM_AUX_DIR_EXPAND], +[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` +]) + +# AM_COND_IF -*- Autoconf -*- + +# Copyright (C) 2008-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_COND_IF +# _AM_COND_ELSE +# _AM_COND_ENDIF +# -------------- +# These macros are only used for tracing. +m4_define([_AM_COND_IF]) +m4_define([_AM_COND_ELSE]) +m4_define([_AM_COND_ENDIF]) + +# AM_COND_IF(COND, [IF-TRUE], [IF-FALSE]) +# --------------------------------------- +# If the shell condition COND is true, execute IF-TRUE, otherwise execute +# IF-FALSE. Allow automake to learn about conditional instantiating macros +# (the AC_CONFIG_FOOS). +AC_DEFUN([AM_COND_IF], +[m4_ifndef([_AM_COND_VALUE_$1], + [m4_fatal([$0: no such condition "$1"])])dnl +_AM_COND_IF([$1])dnl +if test -z "$$1_TRUE"; then : + m4_n([$2])[]dnl +m4_ifval([$3], +[_AM_COND_ELSE([$1])dnl +else + $3 +])dnl +_AM_COND_ENDIF([$1])dnl +fi[]dnl +]) + +# AM_CONDITIONAL -*- Autoconf -*- + +# Copyright (C) 1997-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_CONDITIONAL(NAME, SHELL-CONDITION) +# ------------------------------------- +# Define a conditional. +AC_DEFUN([AM_CONDITIONAL], +[AC_PREREQ([2.52])dnl + m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], + [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl +AC_SUBST([$1_TRUE])dnl +AC_SUBST([$1_FALSE])dnl +_AM_SUBST_NOTMAKE([$1_TRUE])dnl +_AM_SUBST_NOTMAKE([$1_FALSE])dnl +m4_define([_AM_COND_VALUE_$1], [$2])dnl +if $2; then + $1_TRUE= + $1_FALSE='#' +else + $1_TRUE='#' + $1_FALSE= +fi +AC_CONFIG_COMMANDS_PRE( +[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then + AC_MSG_ERROR([[conditional "$1" was never defined. +Usually this means the macro was only invoked conditionally.]]) +fi])]) + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + + +# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be +# written in clear, in which case automake, when reading aclocal.m4, +# will think it sees a *use*, and therefore will trigger all it's +# C support machinery. Also note that it means that autoscan, seeing +# CC etc. in the Makefile, will ask for an AC_PROG_CC use... + + +# _AM_DEPENDENCIES(NAME) +# ---------------------- +# See how the compiler implements dependency checking. +# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". +# We try a few techniques and use that to set a single cache variable. +# +# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was +# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular +# dependency, and given that the user is not expected to run this macro, +# just rely on AC_PROG_CC. +AC_DEFUN([_AM_DEPENDENCIES], +[AC_REQUIRE([AM_SET_DEPDIR])dnl +AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl +AC_REQUIRE([AM_MAKE_INCLUDE])dnl +AC_REQUIRE([AM_DEP_TRACK])dnl + +m4_if([$1], [CC], [depcc="$CC" am_compiler_list=], + [$1], [CXX], [depcc="$CXX" am_compiler_list=], + [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], + [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], + [$1], [UPC], [depcc="$UPC" am_compiler_list=], + [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], + [depcc="$$1" am_compiler_list=]) + +AC_CACHE_CHECK([dependency style of $depcc], + [am_cv_$1_dependencies_compiler_type], +[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_$1_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` + fi + am__universal=false + m4_case([$1], [CC], + [case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac], + [CXX], + [case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac]) + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_$1_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_$1_dependencies_compiler_type=none +fi +]) +AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) +AM_CONDITIONAL([am__fastdep$1], [ + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) +]) + + +# AM_SET_DEPDIR +# ------------- +# Choose a directory name for dependency files. +# This macro is AC_REQUIREd in _AM_DEPENDENCIES. +AC_DEFUN([AM_SET_DEPDIR], +[AC_REQUIRE([AM_SET_LEADING_DOT])dnl +AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl +]) + + +# AM_DEP_TRACK +# ------------ +AC_DEFUN([AM_DEP_TRACK], +[AC_ARG_ENABLE([dependency-tracking], [dnl +AS_HELP_STRING( + [--enable-dependency-tracking], + [do not reject slow dependency extractors]) +AS_HELP_STRING( + [--disable-dependency-tracking], + [speeds up one-time build])]) +if test "x$enable_dependency_tracking" != xno; then + am_depcomp="$ac_aux_dir/depcomp" + AMDEPBACKSLASH='\' + am__nodep='_no' +fi +AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) +AC_SUBST([AMDEPBACKSLASH])dnl +_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl +AC_SUBST([am__nodep])dnl +_AM_SUBST_NOTMAKE([am__nodep])dnl +]) + +# Generate code to set up dependency tracking. -*- Autoconf -*- + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + + +# _AM_OUTPUT_DEPENDENCY_COMMANDS +# ------------------------------ +AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], +[{ + # Older Autoconf quotes --file arguments for eval, but not when files + # are listed without --file. Let's play safe and only enable the eval + # if we detect the quoting. + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac + shift + for mf + do + # Strip MF so we end up with the name of the file. + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named 'Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line + # limit of 2048, but all sed's we know have understand at least 4000. + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`AS_DIRNAME("$mf")` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running 'make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "$am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`AS_DIRNAME(["$file"])` + AS_MKDIR_P([$dirpart/$fdir]) + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done + done +} +])# _AM_OUTPUT_DEPENDENCY_COMMANDS + + +# AM_OUTPUT_DEPENDENCY_COMMANDS +# ----------------------------- +# This macro should only be invoked once -- use via AC_REQUIRE. +# +# This code is only required when automatic dependency tracking +# is enabled. FIXME. This creates each '.P' file that we will +# need in order to bootstrap the dependency handling code. +AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], +[AC_CONFIG_COMMANDS([depfiles], + [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], + [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) +]) + +# Do all the work for Automake. -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This macro actually does too much. Some checks are only needed if +# your package does certain things. But this isn't really a big deal. + +dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. +m4_define([AC_PROG_CC], +m4_defn([AC_PROG_CC]) +[_AM_PROG_CC_C_O +]) + +# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) +# AM_INIT_AUTOMAKE([OPTIONS]) +# ----------------------------------------------- +# The call with PACKAGE and VERSION arguments is the old style +# call (pre autoconf-2.50), which is being phased out. PACKAGE +# and VERSION should now be passed to AC_INIT and removed from +# the call to AM_INIT_AUTOMAKE. +# We support both call styles for the transition. After +# the next Automake release, Autoconf can make the AC_INIT +# arguments mandatory, and then we can depend on a new Autoconf +# release and drop the old call support. +AC_DEFUN([AM_INIT_AUTOMAKE], +[AC_PREREQ([2.65])dnl +dnl Autoconf wants to disallow AM_ names. We explicitly allow +dnl the ones we care about. +m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl +AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl +AC_REQUIRE([AC_PROG_INSTALL])dnl +if test "`cd $srcdir && pwd`" != "`pwd`"; then + # Use -I$(srcdir) only when $(srcdir) != ., so that make's output + # is not polluted with repeated "-I." + AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl + # test to see if srcdir already configured + if test -f $srcdir/config.status; then + AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) + fi +fi + +# test whether we have cygpath +if test -z "$CYGPATH_W"; then + if (cygpath --version) >/dev/null 2>/dev/null; then + CYGPATH_W='cygpath -w' + else + CYGPATH_W=echo + fi +fi +AC_SUBST([CYGPATH_W]) + +# Define the identity of the package. +dnl Distinguish between old-style and new-style calls. +m4_ifval([$2], +[AC_DIAGNOSE([obsolete], + [$0: two- and three-arguments forms are deprecated.]) +m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl + AC_SUBST([PACKAGE], [$1])dnl + AC_SUBST([VERSION], [$2])], +[_AM_SET_OPTIONS([$1])dnl +dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. +m4_if( + m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]), + [ok:ok],, + [m4_fatal([AC_INIT should be called with package and version arguments])])dnl + AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl + AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl + +_AM_IF_OPTION([no-define],, +[AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) + AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl + +# Some tools Automake needs. +AC_REQUIRE([AM_SANITY_CHECK])dnl +AC_REQUIRE([AC_ARG_PROGRAM])dnl +AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) +AM_MISSING_PROG([AUTOCONF], [autoconf]) +AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) +AM_MISSING_PROG([AUTOHEADER], [autoheader]) +AM_MISSING_PROG([MAKEINFO], [makeinfo]) +AC_REQUIRE([AM_PROG_INSTALL_SH])dnl +AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl +AC_REQUIRE([AC_PROG_MKDIR_P])dnl +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html> +# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html> +AC_SUBST([mkdir_p], ['$(MKDIR_P)']) +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. +AC_REQUIRE([AC_PROG_AWK])dnl +AC_REQUIRE([AC_PROG_MAKE_SET])dnl +AC_REQUIRE([AM_SET_LEADING_DOT])dnl +_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], + [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], + [_AM_PROG_TAR([v7])])]) +_AM_IF_OPTION([no-dependencies],, +[AC_PROVIDE_IFELSE([AC_PROG_CC], + [_AM_DEPENDENCIES([CC])], + [m4_define([AC_PROG_CC], + m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_CXX], + [_AM_DEPENDENCIES([CXX])], + [m4_define([AC_PROG_CXX], + m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_OBJC], + [_AM_DEPENDENCIES([OBJC])], + [m4_define([AC_PROG_OBJC], + m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], + [_AM_DEPENDENCIES([OBJCXX])], + [m4_define([AC_PROG_OBJCXX], + m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl +]) +AC_REQUIRE([AM_SILENT_RULES])dnl +dnl The testsuite driver may need to know about EXEEXT, so add the +dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This +dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. +AC_CONFIG_COMMANDS_PRE(dnl +[m4_provide_if([_AM_COMPILER_EXEEXT], + [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl + +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542> + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: <http://www.gnu.org/software/coreutils/>. + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) + fi +fi +dnl The trailing newline in this macro's definition is deliberate, for +dnl backward compatibility and to allow trailing 'dnl'-style comments +dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. +]) + +dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not +dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further +dnl mangled by Autoconf and run in a shell conditional statement. +m4_define([_AC_COMPILER_EXEEXT], +m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) + +# When config.status generates a header, we must update the stamp-h file. +# This file resides in the same directory as the config header +# that is generated. The stamp files are numbered to have different names. + +# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the +# loop where config.status creates the headers, so we can generate +# our stamp files there. +AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], +[# Compute $1's index in $config_headers. +_am_arg=$1 +_am_stamp_count=1 +for _am_header in $config_headers :; do + case $_am_header in + $_am_arg | $_am_arg:* ) + break ;; + * ) + _am_stamp_count=`expr $_am_stamp_count + 1` ;; + esac +done +echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_PROG_INSTALL_SH +# ------------------ +# Define $install_sh. +AC_DEFUN([AM_PROG_INSTALL_SH], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +if test x"${install_sh+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; + *) + install_sh="\${SHELL} $am_aux_dir/install-sh" + esac +fi +AC_SUBST([install_sh])]) + +# Copyright (C) 2003-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# Check whether the underlying file-system supports filenames +# with a leading dot. For instance MS-DOS doesn't. +AC_DEFUN([AM_SET_LEADING_DOT], +[rm -rf .tst 2>/dev/null +mkdir .tst 2>/dev/null +if test -d .tst; then + am__leading_dot=. +else + am__leading_dot=_ +fi +rmdir .tst 2>/dev/null +AC_SUBST([am__leading_dot])]) + +# Check to see how 'make' treats includes. -*- Autoconf -*- + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_MAKE_INCLUDE() +# ----------------- +# Check to see how make treats includes. +AC_DEFUN([AM_MAKE_INCLUDE], +[am_make=${MAKE-make} +cat > confinc << 'END' +am__doit: + @echo this is the am__doit target +.PHONY: am__doit +END +# If we don't find an include directive, just comment out the code. +AC_MSG_CHECKING([for style of include used by $am_make]) +am__include="#" +am__quote= +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# Ignore all kinds of additional output from 'make'. +case `$am_make -s -f confmf 2> /dev/null` in #( +*the\ am__doit\ target*) + am__include=include + am__quote= + _am_result=GNU + ;; +esac +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + case `$am_make -s -f confmf 2> /dev/null` in #( + *the\ am__doit\ target*) + am__include=.include + am__quote="\"" + _am_result=BSD + ;; + esac +fi +AC_SUBST([am__include]) +AC_SUBST([am__quote]) +AC_MSG_RESULT([$_am_result]) +rm -f confinc confmf +]) + +# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- + +# Copyright (C) 1997-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_MISSING_PROG(NAME, PROGRAM) +# ------------------------------ +AC_DEFUN([AM_MISSING_PROG], +[AC_REQUIRE([AM_MISSING_HAS_RUN]) +$1=${$1-"${am_missing_run}$2"} +AC_SUBST($1)]) + +# AM_MISSING_HAS_RUN +# ------------------ +# Define MISSING if not defined so far and test if it is modern enough. +# If it is, set am_missing_run to use it, otherwise, to nothing. +AC_DEFUN([AM_MISSING_HAS_RUN], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([missing])dnl +if test x"${MISSING+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; + *) + MISSING="\${SHELL} $am_aux_dir/missing" ;; + esac +fi +# Use eval to expand $SHELL +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " +else + am_missing_run= + AC_MSG_WARN(['missing' script is too old or missing]) +fi +]) + +# Helper functions for option handling. -*- Autoconf -*- + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_MANGLE_OPTION(NAME) +# ----------------------- +AC_DEFUN([_AM_MANGLE_OPTION], +[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) + +# _AM_SET_OPTION(NAME) +# -------------------- +# Set option NAME. Presently that only means defining a flag for this option. +AC_DEFUN([_AM_SET_OPTION], +[m4_define(_AM_MANGLE_OPTION([$1]), [1])]) + +# _AM_SET_OPTIONS(OPTIONS) +# ------------------------ +# OPTIONS is a space-separated list of Automake options. +AC_DEFUN([_AM_SET_OPTIONS], +[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) + +# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) +# ------------------------------------------- +# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. +AC_DEFUN([_AM_IF_OPTION], +[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_PROG_CC_C_O +# --------------- +# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC +# to automatically call this. +AC_DEFUN([_AM_PROG_CC_C_O], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([compile])dnl +AC_LANG_PUSH([C])dnl +AC_CACHE_CHECK( + [whether $CC understands -c and -o together], + [am_cv_prog_cc_c_o], + [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i]) +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +AC_LANG_POP([C])]) + +# For backward compatibility. +AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_RUN_LOG(COMMAND) +# ------------------- +# Run COMMAND, save the exit status in ac_status, and log it. +# (This has been adapted from Autoconf's _AC_RUN_LOG macro.) +AC_DEFUN([AM_RUN_LOG], +[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD + ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + (exit $ac_status); }]) + +# Check to make sure that the build environment is sane. -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_SANITY_CHECK +# --------------- +AC_DEFUN([AM_SANITY_CHECK], +[AC_MSG_CHECKING([whether build environment is sane]) +# Reject unsafe characters in $srcdir or the absolute working directory +# name. Accept space and tab only in the latter. +am_lf=' +' +case `pwd` in + *[[\\\"\#\$\&\'\`$am_lf]]*) + AC_MSG_ERROR([unsafe absolute working directory name]);; +esac +case $srcdir in + *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) + AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; +esac + +# Do 'set' in a subshell so we don't clobber the current shell's +# arguments. Must try -L first in case configure is actually a +# symlink; some systems play weird games with the mod time of symlinks +# (eg FreeBSD returns the mod time of the symlink's containing +# directory). +if ( + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$[*]" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$[*]" != "X $srcdir/configure conftest.file" \ + && test "$[*]" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken + alias in your environment]) + fi + if test "$[2]" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done + test "$[2]" = conftest.file + ) +then + # Ok. + : +else + AC_MSG_ERROR([newly created file is older than distributed files! +Check your system clock]) +fi +AC_MSG_RESULT([yes]) +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi +AC_CONFIG_COMMANDS_PRE( + [AC_MSG_CHECKING([that generated files are newer than configure]) + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + AC_MSG_RESULT([done])]) +rm -f conftest.file +]) + +# Copyright (C) 2009-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_SILENT_RULES([DEFAULT]) +# -------------------------- +# Enable less verbose build rules; with the default set to DEFAULT +# ("yes" being less verbose, "no" or empty being verbose). +AC_DEFUN([AM_SILENT_RULES], +[AC_ARG_ENABLE([silent-rules], [dnl +AS_HELP_STRING( + [--enable-silent-rules], + [less verbose build output (undo: "make V=1")]) +AS_HELP_STRING( + [--disable-silent-rules], + [verbose build output (undo: "make V=0")])dnl +]) +case $enable_silent_rules in @%:@ ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; +esac +dnl +dnl A few 'make' implementations (e.g., NonStop OS and NextStep) +dnl do not support nested variable expansions. +dnl See automake bug#9928 and bug#10237. +am_make=${MAKE-make} +AC_CACHE_CHECK([whether $am_make supports nested variables], + [am_cv_make_support_nested_variables], + [if AS_ECHO([['TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi]) +if test $am_cv_make_support_nested_variables = yes; then + dnl Using '$V' instead of '$(V)' breaks IRIX make. + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AC_SUBST([AM_V])dnl +AM_SUBST_NOTMAKE([AM_V])dnl +AC_SUBST([AM_DEFAULT_V])dnl +AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl +AC_SUBST([AM_DEFAULT_VERBOSITY])dnl +AM_BACKSLASH='\' +AC_SUBST([AM_BACKSLASH])dnl +_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl +]) + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_PROG_INSTALL_STRIP +# --------------------- +# One issue with vendor 'install' (even GNU) is that you can't +# specify the program used to strip binaries. This is especially +# annoying in cross-compiling environments, where the build's strip +# is unlikely to handle the host's binaries. +# Fortunately install-sh will honor a STRIPPROG variable, so we +# always use install-sh in "make install-strip", and initialize +# STRIPPROG with the value of the STRIP variable (set by the user). +AC_DEFUN([AM_PROG_INSTALL_STRIP], +[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right +# tool to use in cross-compilation environments, therefore Automake +# will honor the 'STRIP' environment variable to overrule this program. +dnl Don't test for $cross_compiling = yes, because it might be 'maybe'. +if test "$cross_compiling" != no; then + AC_CHECK_TOOL([STRIP], [strip], :) +fi +INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" +AC_SUBST([INSTALL_STRIP_PROGRAM])]) + +# Copyright (C) 2006-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_SUBST_NOTMAKE(VARIABLE) +# --------------------------- +# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. +# This macro is traced by Automake. +AC_DEFUN([_AM_SUBST_NOTMAKE]) + +# AM_SUBST_NOTMAKE(VARIABLE) +# -------------------------- +# Public sister of _AM_SUBST_NOTMAKE. +AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) + +# Check how to create a tarball. -*- Autoconf -*- + +# Copyright (C) 2004-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_PROG_TAR(FORMAT) +# -------------------- +# Check how to create a tarball in format FORMAT. +# FORMAT should be one of 'v7', 'ustar', or 'pax'. +# +# Substitute a variable $(am__tar) that is a command +# writing to stdout a FORMAT-tarball containing the directory +# $tardir. +# tardir=directory && $(am__tar) > result.tar +# +# Substitute a variable $(am__untar) that extract such +# a tarball read from stdin. +# $(am__untar) < result.tar +# +AC_DEFUN([_AM_PROG_TAR], +[# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AC_SUBST([AMTAR], ['$${TAR-tar}']) + +# We'll loop over all known methods to create a tar archive until one works. +_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' + +m4_if([$1], [v7], + [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], + + [m4_case([$1], + [ustar], + [# The POSIX 1988 'ustar' format is defined with fixed-size fields. + # There is notably a 21 bits limit for the UID and the GID. In fact, + # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 + # and bug#13588). + am_max_uid=2097151 # 2^21 - 1 + am_max_gid=$am_max_uid + # The $UID and $GID variables are not portable, so we need to resort + # to the POSIX-mandated id(1) utility. Errors in the 'id' calls + # below are definitely unexpected, so allow the users to see them + # (that is, avoid stderr redirection). + am_uid=`id -u || echo unknown` + am_gid=`id -g || echo unknown` + AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) + if test $am_uid -le $am_max_uid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi + AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) + if test $am_gid -le $am_max_gid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi], + + [pax], + [], + + [m4_fatal([Unknown tar format])]) + + AC_MSG_CHECKING([how to create a $1 tar archive]) + + # Go ahead even if we have the value already cached. We do so because we + # need to set the values for the 'am__tar' and 'am__untar' variables. + _am_tools=${am_cv_prog_tar_$1-$_am_tools} + + for _am_tool in $_am_tools; do + case $_am_tool in + gnutar) + for _am_tar in tar gnutar gtar; do + AM_RUN_LOG([$_am_tar --version]) && break + done + am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' + am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' + am__untar="$_am_tar -xf -" + ;; + plaintar) + # Must skip GNU tar: if it does not support --format= it doesn't create + # ustar tarball either. + (tar --version) >/dev/null 2>&1 && continue + am__tar='tar chf - "$$tardir"' + am__tar_='tar chf - "$tardir"' + am__untar='tar xf -' + ;; + pax) + am__tar='pax -L -x $1 -w "$$tardir"' + am__tar_='pax -L -x $1 -w "$tardir"' + am__untar='pax -r' + ;; + cpio) + am__tar='find "$$tardir" -print | cpio -o -H $1 -L' + am__tar_='find "$tardir" -print | cpio -o -H $1 -L' + am__untar='cpio -i -H $1 -d' + ;; + none) + am__tar=false + am__tar_=false + am__untar=false + ;; + esac + + # If the value was cached, stop now. We just wanted to have am__tar + # and am__untar set. + test -n "${am_cv_prog_tar_$1}" && break + + # tar/untar a dummy directory, and stop if the command works. + rm -rf conftest.dir + mkdir conftest.dir + echo GrepMe > conftest.dir/file + AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) + rm -rf conftest.dir + if test -s conftest.tar; then + AM_RUN_LOG([$am__untar <conftest.tar]) + AM_RUN_LOG([cat conftest.dir/file]) + grep GrepMe conftest.dir/file >/dev/null 2>&1 && break + fi + done + rm -rf conftest.dir + + AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) + AC_MSG_RESULT([$am_cv_prog_tar_$1])]) + +AC_SUBST([am__tar]) +AC_SUBST([am__untar]) +]) # _AM_PROG_TAR + +m4_include([m4/libtool.m4]) +m4_include([m4/ltoptions.m4]) +m4_include([m4/ltsugar.m4]) +m4_include([m4/ltversion.m4]) +m4_include([m4/lt~obsolete.m4]) +m4_include([m4/modern_cxx.m4]) +m4_include([m4/w32.m4]) diff --git a/resources/3rdparty/cudd-3.0.0/build-aux/ar-lib b/resources/3rdparty/cudd-3.0.0/build-aux/ar-lib new file mode 100755 index 000000000..fe2301e71 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/build-aux/ar-lib @@ -0,0 +1,270 @@ +#! /bin/sh +# Wrapper for Microsoft lib.exe + +me=ar-lib +scriptversion=2012-03-01.08; # UTC + +# Copyright (C) 2010-2013 Free Software Foundation, Inc. +# Written by Peter Rosin <peda@lysator.liu.se>. +# +# 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. +# +# 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. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# This file is maintained in Automake, please report +# bugs to <bug-automake@gnu.org> or send patches to +# <automake-patches@gnu.org>. + + +# func_error message +func_error () +{ + echo "$me: $1" 1>&2 + exit 1 +} + +file_conv= + +# func_file_conv build_file +# Convert a $build file to $host form and store it in $file +# Currently only supports Windows hosts. +func_file_conv () +{ + file=$1 + case $file in + / | /[!/]*) # absolute file, and not a UNC file + if test -z "$file_conv"; then + # lazily determine how to convert abs files + case `uname -s` in + MINGW*) + file_conv=mingw + ;; + CYGWIN*) + file_conv=cygwin + ;; + *) + file_conv=wine + ;; + esac + fi + case $file_conv in + mingw) + file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` + ;; + cygwin) + file=`cygpath -m "$file" || echo "$file"` + ;; + wine) + file=`winepath -w "$file" || echo "$file"` + ;; + esac + ;; + esac +} + +# func_at_file at_file operation archive +# Iterate over all members in AT_FILE performing OPERATION on ARCHIVE +# for each of them. +# When interpreting the content of the @FILE, do NOT use func_file_conv, +# since the user would need to supply preconverted file names to +# binutils ar, at least for MinGW. +func_at_file () +{ + operation=$2 + archive=$3 + at_file_contents=`cat "$1"` + eval set x "$at_file_contents" + shift + + for member + do + $AR -NOLOGO $operation:"$member" "$archive" || exit $? + done +} + +case $1 in + '') + func_error "no command. Try '$0 --help' for more information." + ;; + -h | --h*) + cat <<EOF +Usage: $me [--help] [--version] PROGRAM ACTION ARCHIVE [MEMBER...] + +Members may be specified in a file named with @FILE. +EOF + exit $? + ;; + -v | --v*) + echo "$me, version $scriptversion" + exit $? + ;; +esac + +if test $# -lt 3; then + func_error "you must specify a program, an action and an archive" +fi + +AR=$1 +shift +while : +do + if test $# -lt 2; then + func_error "you must specify a program, an action and an archive" + fi + case $1 in + -lib | -LIB \ + | -ltcg | -LTCG \ + | -machine* | -MACHINE* \ + | -subsystem* | -SUBSYSTEM* \ + | -verbose | -VERBOSE \ + | -wx* | -WX* ) + AR="$AR $1" + shift + ;; + *) + action=$1 + shift + break + ;; + esac +done +orig_archive=$1 +shift +func_file_conv "$orig_archive" +archive=$file + +# strip leading dash in $action +action=${action#-} + +delete= +extract= +list= +quick= +replace= +index= +create= + +while test -n "$action" +do + case $action in + d*) delete=yes ;; + x*) extract=yes ;; + t*) list=yes ;; + q*) quick=yes ;; + r*) replace=yes ;; + s*) index=yes ;; + S*) ;; # the index is always updated implicitly + c*) create=yes ;; + u*) ;; # TODO: don't ignore the update modifier + v*) ;; # TODO: don't ignore the verbose modifier + *) + func_error "unknown action specified" + ;; + esac + action=${action#?} +done + +case $delete$extract$list$quick$replace,$index in + yes,* | ,yes) + ;; + yesyes*) + func_error "more than one action specified" + ;; + *) + func_error "no action specified" + ;; +esac + +if test -n "$delete"; then + if test ! -f "$orig_archive"; then + func_error "archive not found" + fi + for member + do + case $1 in + @*) + func_at_file "${1#@}" -REMOVE "$archive" + ;; + *) + func_file_conv "$1" + $AR -NOLOGO -REMOVE:"$file" "$archive" || exit $? + ;; + esac + done + +elif test -n "$extract"; then + if test ! -f "$orig_archive"; then + func_error "archive not found" + fi + if test $# -gt 0; then + for member + do + case $1 in + @*) + func_at_file "${1#@}" -EXTRACT "$archive" + ;; + *) + func_file_conv "$1" + $AR -NOLOGO -EXTRACT:"$file" "$archive" || exit $? + ;; + esac + done + else + $AR -NOLOGO -LIST "$archive" | sed -e 's/\\/\\\\/g' | while read member + do + $AR -NOLOGO -EXTRACT:"$member" "$archive" || exit $? + done + fi + +elif test -n "$quick$replace"; then + if test ! -f "$orig_archive"; then + if test -z "$create"; then + echo "$me: creating $orig_archive" + fi + orig_archive= + else + orig_archive=$archive + fi + + for member + do + case $1 in + @*) + func_file_conv "${1#@}" + set x "$@" "@$file" + ;; + *) + func_file_conv "$1" + set x "$@" "$file" + ;; + esac + shift + shift + done + + if test -n "$orig_archive"; then + $AR -NOLOGO -OUT:"$archive" "$orig_archive" "$@" || exit $? + else + $AR -NOLOGO -OUT:"$archive" "$@" || exit $? + fi + +elif test -n "$list"; then + if test ! -f "$orig_archive"; then + func_error "archive not found" + fi + $AR -NOLOGO -LIST "$archive" || exit $? +fi diff --git a/resources/3rdparty/cudd-3.0.0/build-aux/compile b/resources/3rdparty/cudd-3.0.0/build-aux/compile new file mode 100755 index 000000000..531136b06 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/build-aux/compile @@ -0,0 +1,347 @@ +#! /bin/sh +# Wrapper for compilers which do not understand '-c -o'. + +scriptversion=2012-10-14.11; # UTC + +# Copyright (C) 1999-2013 Free Software Foundation, Inc. +# Written by Tom Tromey <tromey@cygnus.com>. +# +# 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. +# +# 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. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# This file is maintained in Automake, please report +# bugs to <bug-automake@gnu.org> or send patches to +# <automake-patches@gnu.org>. + +nl=' +' + +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent tools from complaining about whitespace usage. +IFS=" "" $nl" + +file_conv= + +# func_file_conv build_file lazy +# Convert a $build file to $host form and store it in $file +# Currently only supports Windows hosts. If the determined conversion +# type is listed in (the comma separated) LAZY, no conversion will +# take place. +func_file_conv () +{ + file=$1 + case $file in + / | /[!/]*) # absolute file, and not a UNC file + if test -z "$file_conv"; then + # lazily determine how to convert abs files + case `uname -s` in + MINGW*) + file_conv=mingw + ;; + CYGWIN*) + file_conv=cygwin + ;; + *) + file_conv=wine + ;; + esac + fi + case $file_conv/,$2, in + *,$file_conv,*) + ;; + mingw/*) + file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` + ;; + cygwin/*) + file=`cygpath -m "$file" || echo "$file"` + ;; + wine/*) + file=`winepath -w "$file" || echo "$file"` + ;; + esac + ;; + esac +} + +# func_cl_dashL linkdir +# Make cl look for libraries in LINKDIR +func_cl_dashL () +{ + func_file_conv "$1" + if test -z "$lib_path"; then + lib_path=$file + else + lib_path="$lib_path;$file" + fi + linker_opts="$linker_opts -LIBPATH:$file" +} + +# func_cl_dashl library +# Do a library search-path lookup for cl +func_cl_dashl () +{ + lib=$1 + found=no + save_IFS=$IFS + IFS=';' + for dir in $lib_path $LIB + do + IFS=$save_IFS + if $shared && test -f "$dir/$lib.dll.lib"; then + found=yes + lib=$dir/$lib.dll.lib + break + fi + if test -f "$dir/$lib.lib"; then + found=yes + lib=$dir/$lib.lib + break + fi + if test -f "$dir/lib$lib.a"; then + found=yes + lib=$dir/lib$lib.a + break + fi + done + IFS=$save_IFS + + if test "$found" != yes; then + lib=$lib.lib + fi +} + +# func_cl_wrapper cl arg... +# Adjust compile command to suit cl +func_cl_wrapper () +{ + # Assume a capable shell + lib_path= + shared=: + linker_opts= + for arg + do + if test -n "$eat"; then + eat= + else + case $1 in + -o) + # configure might choose to run compile as 'compile cc -o foo foo.c'. + eat=1 + case $2 in + *.o | *.[oO][bB][jJ]) + func_file_conv "$2" + set x "$@" -Fo"$file" + shift + ;; + *) + func_file_conv "$2" + set x "$@" -Fe"$file" + shift + ;; + esac + ;; + -I) + eat=1 + func_file_conv "$2" mingw + set x "$@" -I"$file" + shift + ;; + -I*) + func_file_conv "${1#-I}" mingw + set x "$@" -I"$file" + shift + ;; + -l) + eat=1 + func_cl_dashl "$2" + set x "$@" "$lib" + shift + ;; + -l*) + func_cl_dashl "${1#-l}" + set x "$@" "$lib" + shift + ;; + -L) + eat=1 + func_cl_dashL "$2" + ;; + -L*) + func_cl_dashL "${1#-L}" + ;; + -static) + shared=false + ;; + -Wl,*) + arg=${1#-Wl,} + save_ifs="$IFS"; IFS=',' + for flag in $arg; do + IFS="$save_ifs" + linker_opts="$linker_opts $flag" + done + IFS="$save_ifs" + ;; + -Xlinker) + eat=1 + linker_opts="$linker_opts $2" + ;; + -*) + set x "$@" "$1" + shift + ;; + *.cc | *.CC | *.cxx | *.CXX | *.[cC]++) + func_file_conv "$1" + set x "$@" -Tp"$file" + shift + ;; + *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO]) + func_file_conv "$1" mingw + set x "$@" "$file" + shift + ;; + *) + set x "$@" "$1" + shift + ;; + esac + fi + shift + done + if test -n "$linker_opts"; then + linker_opts="-link$linker_opts" + fi + exec "$@" $linker_opts + exit 1 +} + +eat= + +case $1 in + '') + echo "$0: No command. Try '$0 --help' for more information." 1>&2 + exit 1; + ;; + -h | --h*) + cat <<\EOF +Usage: compile [--help] [--version] PROGRAM [ARGS] + +Wrapper for compilers which do not understand '-c -o'. +Remove '-o dest.o' from ARGS, run PROGRAM with the remaining +arguments, and rename the output as expected. + +If you are trying to build a whole package this is not the +right script to run: please start by reading the file 'INSTALL'. + +Report bugs to <bug-automake@gnu.org>. +EOF + exit $? + ;; + -v | --v*) + echo "compile $scriptversion" + exit $? + ;; + cl | *[/\\]cl | cl.exe | *[/\\]cl.exe ) + func_cl_wrapper "$@" # Doesn't return... + ;; +esac + +ofile= +cfile= + +for arg +do + if test -n "$eat"; then + eat= + else + case $1 in + -o) + # configure might choose to run compile as 'compile cc -o foo foo.c'. + # So we strip '-o arg' only if arg is an object. + eat=1 + case $2 in + *.o | *.obj) + ofile=$2 + ;; + *) + set x "$@" -o "$2" + shift + ;; + esac + ;; + *.c) + cfile=$1 + set x "$@" "$1" + shift + ;; + *) + set x "$@" "$1" + shift + ;; + esac + fi + shift +done + +if test -z "$ofile" || test -z "$cfile"; then + # If no '-o' option was seen then we might have been invoked from a + # pattern rule where we don't need one. That is ok -- this is a + # normal compilation that the losing compiler can handle. If no + # '.c' file was seen then we are probably linking. That is also + # ok. + exec "$@" +fi + +# Name of file we expect compiler to create. +cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'` + +# Create the lock directory. +# Note: use '[/\\:.-]' here to ensure that we don't use the same name +# that we are using for the .o file. Also, base the name on the expected +# object file name, since that is what matters with a parallel build. +lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d +while true; do + if mkdir "$lockdir" >/dev/null 2>&1; then + break + fi + sleep 1 +done +# FIXME: race condition here if user kills between mkdir and trap. +trap "rmdir '$lockdir'; exit 1" 1 2 15 + +# Run the compile. +"$@" +ret=$? + +if test -f "$cofile"; then + test "$cofile" = "$ofile" || mv "$cofile" "$ofile" +elif test -f "${cofile}bj"; then + test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile" +fi + +rmdir "$lockdir" +exit $ret + +# Local Variables: +# mode: shell-script +# sh-indentation: 2 +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/resources/3rdparty/cudd-3.0.0/build-aux/config.guess b/resources/3rdparty/cudd-3.0.0/build-aux/config.guess new file mode 100755 index 000000000..1f5c50c0d --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/build-aux/config.guess @@ -0,0 +1,1420 @@ +#! /bin/sh +# Attempt to guess a canonical system name. +# Copyright 1992-2014 Free Software Foundation, Inc. + +timestamp='2014-03-23' + +# This file 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 3 of the License, or +# (at your option) any later version. +# +# 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. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, see <http://www.gnu.org/licenses/>. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that +# program. This Exception is an additional permission under section 7 +# of the GNU General Public License, version 3 ("GPLv3"). +# +# Originally written by Per Bothner. +# +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD +# +# Please send patches with a ChangeLog entry to config-patches@gnu.org. + + +me=`echo "$0" | sed -e 's,.*/,,'` + +usage="\ +Usage: $0 [OPTION] + +Output the configuration name of the system \`$me' is run on. + +Operation modes: + -h, --help print this help, then exit + -t, --time-stamp print date of last modification, then exit + -v, --version print version number, then exit + +Report bugs and patches to <config-patches@gnu.org>." + +version="\ +GNU config.guess ($timestamp) + +Originally written by Per Bothner. +Copyright 1992-2014 Free Software Foundation, Inc. + +This is free software; see the source for copying conditions. There is NO +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." + +help=" +Try \`$me --help' for more information." + +# Parse command line +while test $# -gt 0 ; do + case $1 in + --time-stamp | --time* | -t ) + echo "$timestamp" ; exit ;; + --version | -v ) + echo "$version" ; exit ;; + --help | --h* | -h ) + echo "$usage"; exit ;; + -- ) # Stop option processing + shift; break ;; + - ) # Use stdin as input. + break ;; + -* ) + echo "$me: invalid option $1$help" >&2 + exit 1 ;; + * ) + break ;; + esac +done + +if test $# != 0; then + echo "$me: too many arguments$help" >&2 + exit 1 +fi + +trap 'exit 1' 1 2 15 + +# CC_FOR_BUILD -- compiler used by this script. Note that the use of a +# compiler to aid in system detection is discouraged as it requires +# temporary files to be created and, as you can see below, it is a +# headache to deal with in a portable fashion. + +# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still +# use `HOST_CC' if defined, but it is deprecated. + +# Portable tmp directory creation inspired by the Autoconf team. + +set_cc_for_build=' +trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; +trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; +: ${TMPDIR=/tmp} ; + { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || + { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || + { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || + { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; +dummy=$tmp/dummy ; +tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; +case $CC_FOR_BUILD,$HOST_CC,$CC in + ,,) echo "int x;" > $dummy.c ; + for c in cc gcc c89 c99 ; do + if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then + CC_FOR_BUILD="$c"; break ; + fi ; + done ; + if test x"$CC_FOR_BUILD" = x ; then + CC_FOR_BUILD=no_compiler_found ; + fi + ;; + ,,*) CC_FOR_BUILD=$CC ;; + ,*,*) CC_FOR_BUILD=$HOST_CC ;; +esac ; set_cc_for_build= ;' + +# This is needed to find uname on a Pyramid OSx when run in the BSD universe. +# (ghazi@noc.rutgers.edu 1994-08-24) +if (test -f /.attbin/uname) >/dev/null 2>&1 ; then + PATH=$PATH:/.attbin ; export PATH +fi + +UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown +UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown +UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown +UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown + +case "${UNAME_SYSTEM}" in +Linux|GNU|GNU/*) + # If the system lacks a compiler, then just pick glibc. + # We could probably try harder. + LIBC=gnu + + eval $set_cc_for_build + cat <<-EOF > $dummy.c + #include <features.h> + #if defined(__UCLIBC__) + LIBC=uclibc + #elif defined(__dietlibc__) + LIBC=dietlibc + #else + LIBC=gnu + #endif + EOF + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC' | sed 's, ,,g'` + ;; +esac + +# Note: order is significant - the case branches are not exclusive. + +case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in + *:NetBSD:*:*) + # NetBSD (nbsd) targets should (where applicable) match one or + # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, + # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently + # switched to ELF, *-*-netbsd* would select the old + # object file format. This provides both forward + # compatibility and a consistent mechanism for selecting the + # object file format. + # + # Note: NetBSD doesn't particularly care about the vendor + # portion of the name. We always set it to "unknown". + sysctl="sysctl -n hw.machine_arch" + UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ + /usr/sbin/$sysctl 2>/dev/null || echo unknown)` + case "${UNAME_MACHINE_ARCH}" in + armeb) machine=armeb-unknown ;; + arm*) machine=arm-unknown ;; + sh3el) machine=shl-unknown ;; + sh3eb) machine=sh-unknown ;; + sh5el) machine=sh5le-unknown ;; + *) machine=${UNAME_MACHINE_ARCH}-unknown ;; + esac + # The Operating System including object format, if it has switched + # to ELF recently, or will in the future. + case "${UNAME_MACHINE_ARCH}" in + arm*|i386|m68k|ns32k|sh3*|sparc|vax) + eval $set_cc_for_build + if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ELF__ + then + # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). + # Return netbsd for either. FIX? + os=netbsd + else + os=netbsdelf + fi + ;; + *) + os=netbsd + ;; + esac + # The OS release + # Debian GNU/NetBSD machines have a different userland, and + # thus, need a distinct triplet. However, they do not need + # kernel version information, so it can be replaced with a + # suitable tag, in the style of linux-gnu. + case "${UNAME_VERSION}" in + Debian*) + release='-gnu' + ;; + *) + release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` + ;; + esac + # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: + # contains redundant information, the shorter form: + # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. + echo "${machine}-${os}${release}" + exit ;; + *:Bitrig:*:*) + UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` + echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE} + exit ;; + *:OpenBSD:*:*) + UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` + echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} + exit ;; + *:ekkoBSD:*:*) + echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} + exit ;; + *:SolidBSD:*:*) + echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} + exit ;; + macppc:MirBSD:*:*) + echo powerpc-unknown-mirbsd${UNAME_RELEASE} + exit ;; + *:MirBSD:*:*) + echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} + exit ;; + alpha:OSF1:*:*) + case $UNAME_RELEASE in + *4.0) + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` + ;; + *5.*) + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` + ;; + esac + # According to Compaq, /usr/sbin/psrinfo has been available on + # OSF/1 and Tru64 systems produced since 1995. I hope that + # covers most systems running today. This code pipes the CPU + # types through head -n 1, so we only detect the type of CPU 0. + ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` + case "$ALPHA_CPU_TYPE" in + "EV4 (21064)") + UNAME_MACHINE="alpha" ;; + "EV4.5 (21064)") + UNAME_MACHINE="alpha" ;; + "LCA4 (21066/21068)") + UNAME_MACHINE="alpha" ;; + "EV5 (21164)") + UNAME_MACHINE="alphaev5" ;; + "EV5.6 (21164A)") + UNAME_MACHINE="alphaev56" ;; + "EV5.6 (21164PC)") + UNAME_MACHINE="alphapca56" ;; + "EV5.7 (21164PC)") + UNAME_MACHINE="alphapca57" ;; + "EV6 (21264)") + UNAME_MACHINE="alphaev6" ;; + "EV6.7 (21264A)") + UNAME_MACHINE="alphaev67" ;; + "EV6.8CB (21264C)") + UNAME_MACHINE="alphaev68" ;; + "EV6.8AL (21264B)") + UNAME_MACHINE="alphaev68" ;; + "EV6.8CX (21264D)") + UNAME_MACHINE="alphaev68" ;; + "EV6.9A (21264/EV69A)") + UNAME_MACHINE="alphaev69" ;; + "EV7 (21364)") + UNAME_MACHINE="alphaev7" ;; + "EV7.9 (21364A)") + UNAME_MACHINE="alphaev79" ;; + esac + # A Pn.n version is a patched version. + # A Vn.n version is a released version. + # A Tn.n version is a released field test version. + # A Xn.n version is an unreleased experimental baselevel. + # 1.2 uses "1.2" for uname -r. + echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` + # Reset EXIT trap before exiting to avoid spurious non-zero exit code. + exitcode=$? + trap '' 0 + exit $exitcode ;; + Alpha\ *:Windows_NT*:*) + # How do we know it's Interix rather than the generic POSIX subsystem? + # Should we change UNAME_MACHINE based on the output of uname instead + # of the specific Alpha model? + echo alpha-pc-interix + exit ;; + 21064:Windows_NT:50:3) + echo alpha-dec-winnt3.5 + exit ;; + Amiga*:UNIX_System_V:4.0:*) + echo m68k-unknown-sysv4 + exit ;; + *:[Aa]miga[Oo][Ss]:*:*) + echo ${UNAME_MACHINE}-unknown-amigaos + exit ;; + *:[Mm]orph[Oo][Ss]:*:*) + echo ${UNAME_MACHINE}-unknown-morphos + exit ;; + *:OS/390:*:*) + echo i370-ibm-openedition + exit ;; + *:z/VM:*:*) + echo s390-ibm-zvmoe + exit ;; + *:OS400:*:*) + echo powerpc-ibm-os400 + exit ;; + arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) + echo arm-acorn-riscix${UNAME_RELEASE} + exit ;; + arm*:riscos:*:*|arm*:RISCOS:*:*) + echo arm-unknown-riscos + exit ;; + SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) + echo hppa1.1-hitachi-hiuxmpp + exit ;; + Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) + # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. + if test "`(/bin/universe) 2>/dev/null`" = att ; then + echo pyramid-pyramid-sysv3 + else + echo pyramid-pyramid-bsd + fi + exit ;; + NILE*:*:*:dcosx) + echo pyramid-pyramid-svr4 + exit ;; + DRS?6000:unix:4.0:6*) + echo sparc-icl-nx6 + exit ;; + DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) + case `/usr/bin/uname -p` in + sparc) echo sparc-icl-nx7; exit ;; + esac ;; + s390x:SunOS:*:*) + echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4H:SunOS:5.*:*) + echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) + echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) + echo i386-pc-auroraux${UNAME_RELEASE} + exit ;; + i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) + eval $set_cc_for_build + SUN_ARCH="i386" + # If there is a compiler, see if it is configured for 64-bit objects. + # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. + # This test works for both compilers. + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + SUN_ARCH="x86_64" + fi + fi + echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4*:SunOS:6*:*) + # According to config.sub, this is the proper way to canonicalize + # SunOS6. Hard to guess exactly what SunOS6 will be like, but + # it's likely to be more like Solaris than SunOS4. + echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4*:SunOS:*:*) + case "`/usr/bin/arch -k`" in + Series*|S4*) + UNAME_RELEASE=`uname -v` + ;; + esac + # Japanese Language versions have a version number like `4.1.3-JL'. + echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` + exit ;; + sun3*:SunOS:*:*) + echo m68k-sun-sunos${UNAME_RELEASE} + exit ;; + sun*:*:4.2BSD:*) + UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` + test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 + case "`/bin/arch`" in + sun3) + echo m68k-sun-sunos${UNAME_RELEASE} + ;; + sun4) + echo sparc-sun-sunos${UNAME_RELEASE} + ;; + esac + exit ;; + aushp:SunOS:*:*) + echo sparc-auspex-sunos${UNAME_RELEASE} + exit ;; + # The situation for MiNT is a little confusing. The machine name + # can be virtually everything (everything which is not + # "atarist" or "atariste" at least should have a processor + # > m68000). The system name ranges from "MiNT" over "FreeMiNT" + # to the lowercase version "mint" (or "freemint"). Finally + # the system name "TOS" denotes a system which is actually not + # MiNT. But MiNT is downward compatible to TOS, so this should + # be no problem. + atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) + echo m68k-atari-mint${UNAME_RELEASE} + exit ;; + atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) + echo m68k-atari-mint${UNAME_RELEASE} + exit ;; + *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) + echo m68k-atari-mint${UNAME_RELEASE} + exit ;; + milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) + echo m68k-milan-mint${UNAME_RELEASE} + exit ;; + hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) + echo m68k-hades-mint${UNAME_RELEASE} + exit ;; + *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) + echo m68k-unknown-mint${UNAME_RELEASE} + exit ;; + m68k:machten:*:*) + echo m68k-apple-machten${UNAME_RELEASE} + exit ;; + powerpc:machten:*:*) + echo powerpc-apple-machten${UNAME_RELEASE} + exit ;; + RISC*:Mach:*:*) + echo mips-dec-mach_bsd4.3 + exit ;; + RISC*:ULTRIX:*:*) + echo mips-dec-ultrix${UNAME_RELEASE} + exit ;; + VAX*:ULTRIX*:*:*) + echo vax-dec-ultrix${UNAME_RELEASE} + exit ;; + 2020:CLIX:*:* | 2430:CLIX:*:*) + echo clipper-intergraph-clix${UNAME_RELEASE} + exit ;; + mips:*:*:UMIPS | mips:*:*:RISCos) + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c +#ifdef __cplusplus +#include <stdio.h> /* for printf() prototype */ + int main (int argc, char *argv[]) { +#else + int main (argc, argv) int argc; char *argv[]; { +#endif + #if defined (host_mips) && defined (MIPSEB) + #if defined (SYSTYPE_SYSV) + printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); + #endif + #if defined (SYSTYPE_SVR4) + printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); + #endif + #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) + printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); + #endif + #endif + exit (-1); + } +EOF + $CC_FOR_BUILD -o $dummy $dummy.c && + dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && + SYSTEM_NAME=`$dummy $dummyarg` && + { echo "$SYSTEM_NAME"; exit; } + echo mips-mips-riscos${UNAME_RELEASE} + exit ;; + Motorola:PowerMAX_OS:*:*) + echo powerpc-motorola-powermax + exit ;; + Motorola:*:4.3:PL8-*) + echo powerpc-harris-powermax + exit ;; + Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) + echo powerpc-harris-powermax + exit ;; + Night_Hawk:Power_UNIX:*:*) + echo powerpc-harris-powerunix + exit ;; + m88k:CX/UX:7*:*) + echo m88k-harris-cxux7 + exit ;; + m88k:*:4*:R4*) + echo m88k-motorola-sysv4 + exit ;; + m88k:*:3*:R3*) + echo m88k-motorola-sysv3 + exit ;; + AViiON:dgux:*:*) + # DG/UX returns AViiON for all architectures + UNAME_PROCESSOR=`/usr/bin/uname -p` + if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] + then + if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ + [ ${TARGET_BINARY_INTERFACE}x = x ] + then + echo m88k-dg-dgux${UNAME_RELEASE} + else + echo m88k-dg-dguxbcs${UNAME_RELEASE} + fi + else + echo i586-dg-dgux${UNAME_RELEASE} + fi + exit ;; + M88*:DolphinOS:*:*) # DolphinOS (SVR3) + echo m88k-dolphin-sysv3 + exit ;; + M88*:*:R3*:*) + # Delta 88k system running SVR3 + echo m88k-motorola-sysv3 + exit ;; + XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) + echo m88k-tektronix-sysv3 + exit ;; + Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) + echo m68k-tektronix-bsd + exit ;; + *:IRIX*:*:*) + echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` + exit ;; + ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. + echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id + exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' + i*86:AIX:*:*) + echo i386-ibm-aix + exit ;; + ia64:AIX:*:*) + if [ -x /usr/bin/oslevel ] ; then + IBM_REV=`/usr/bin/oslevel` + else + IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} + fi + echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} + exit ;; + *:AIX:2:3) + if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #include <sys/systemcfg.h> + + main() + { + if (!__power_pc()) + exit(1); + puts("powerpc-ibm-aix3.2.5"); + exit(0); + } +EOF + if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` + then + echo "$SYSTEM_NAME" + else + echo rs6000-ibm-aix3.2.5 + fi + elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then + echo rs6000-ibm-aix3.2.4 + else + echo rs6000-ibm-aix3.2 + fi + exit ;; + *:AIX:*:[4567]) + IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` + if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then + IBM_ARCH=rs6000 + else + IBM_ARCH=powerpc + fi + if [ -x /usr/bin/oslevel ] ; then + IBM_REV=`/usr/bin/oslevel` + else + IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} + fi + echo ${IBM_ARCH}-ibm-aix${IBM_REV} + exit ;; + *:AIX:*:*) + echo rs6000-ibm-aix + exit ;; + ibmrt:4.4BSD:*|romp-ibm:BSD:*) + echo romp-ibm-bsd4.4 + exit ;; + ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and + echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to + exit ;; # report: romp-ibm BSD 4.3 + *:BOSX:*:*) + echo rs6000-bull-bosx + exit ;; + DPX/2?00:B.O.S.:*:*) + echo m68k-bull-sysv3 + exit ;; + 9000/[34]??:4.3bsd:1.*:*) + echo m68k-hp-bsd + exit ;; + hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) + echo m68k-hp-bsd4.4 + exit ;; + 9000/[34678]??:HP-UX:*:*) + HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` + case "${UNAME_MACHINE}" in + 9000/31? ) HP_ARCH=m68000 ;; + 9000/[34]?? ) HP_ARCH=m68k ;; + 9000/[678][0-9][0-9]) + if [ -x /usr/bin/getconf ]; then + sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` + sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` + case "${sc_cpu_version}" in + 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 + 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 + 532) # CPU_PA_RISC2_0 + case "${sc_kernel_bits}" in + 32) HP_ARCH="hppa2.0n" ;; + 64) HP_ARCH="hppa2.0w" ;; + '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 + esac ;; + esac + fi + if [ "${HP_ARCH}" = "" ]; then + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + + #define _HPUX_SOURCE + #include <stdlib.h> + #include <unistd.h> + + int main () + { + #if defined(_SC_KERNEL_BITS) + long bits = sysconf(_SC_KERNEL_BITS); + #endif + long cpu = sysconf (_SC_CPU_VERSION); + + switch (cpu) + { + case CPU_PA_RISC1_0: puts ("hppa1.0"); break; + case CPU_PA_RISC1_1: puts ("hppa1.1"); break; + case CPU_PA_RISC2_0: + #if defined(_SC_KERNEL_BITS) + switch (bits) + { + case 64: puts ("hppa2.0w"); break; + case 32: puts ("hppa2.0n"); break; + default: puts ("hppa2.0"); break; + } break; + #else /* !defined(_SC_KERNEL_BITS) */ + puts ("hppa2.0"); break; + #endif + default: puts ("hppa1.0"); break; + } + exit (0); + } +EOF + (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` + test -z "$HP_ARCH" && HP_ARCH=hppa + fi ;; + esac + if [ ${HP_ARCH} = "hppa2.0w" ] + then + eval $set_cc_for_build + + # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating + # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler + # generating 64-bit code. GNU and HP use different nomenclature: + # + # $ CC_FOR_BUILD=cc ./config.guess + # => hppa2.0w-hp-hpux11.23 + # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess + # => hppa64-hp-hpux11.23 + + if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | + grep -q __LP64__ + then + HP_ARCH="hppa2.0w" + else + HP_ARCH="hppa64" + fi + fi + echo ${HP_ARCH}-hp-hpux${HPUX_REV} + exit ;; + ia64:HP-UX:*:*) + HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` + echo ia64-hp-hpux${HPUX_REV} + exit ;; + 3050*:HI-UX:*:*) + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #include <unistd.h> + int + main () + { + long cpu = sysconf (_SC_CPU_VERSION); + /* The order matters, because CPU_IS_HP_MC68K erroneously returns + true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct + results, however. */ + if (CPU_IS_PA_RISC (cpu)) + { + switch (cpu) + { + case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; + case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; + case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; + default: puts ("hppa-hitachi-hiuxwe2"); break; + } + } + else if (CPU_IS_HP_MC68K (cpu)) + puts ("m68k-hitachi-hiuxwe2"); + else puts ("unknown-hitachi-hiuxwe2"); + exit (0); + } +EOF + $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && + { echo "$SYSTEM_NAME"; exit; } + echo unknown-hitachi-hiuxwe2 + exit ;; + 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) + echo hppa1.1-hp-bsd + exit ;; + 9000/8??:4.3bsd:*:*) + echo hppa1.0-hp-bsd + exit ;; + *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) + echo hppa1.0-hp-mpeix + exit ;; + hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) + echo hppa1.1-hp-osf + exit ;; + hp8??:OSF1:*:*) + echo hppa1.0-hp-osf + exit ;; + i*86:OSF1:*:*) + if [ -x /usr/sbin/sysversion ] ; then + echo ${UNAME_MACHINE}-unknown-osf1mk + else + echo ${UNAME_MACHINE}-unknown-osf1 + fi + exit ;; + parisc*:Lites*:*:*) + echo hppa1.1-hp-lites + exit ;; + C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) + echo c1-convex-bsd + exit ;; + C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) + if getsysinfo -f scalar_acc + then echo c32-convex-bsd + else echo c2-convex-bsd + fi + exit ;; + C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) + echo c34-convex-bsd + exit ;; + C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) + echo c38-convex-bsd + exit ;; + C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) + echo c4-convex-bsd + exit ;; + CRAY*Y-MP:*:*:*) + echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*[A-Z]90:*:*:*) + echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ + | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ + -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ + -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*TS:*:*:*) + echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*T3E:*:*:*) + echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*SV1:*:*:*) + echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + *:UNICOS/mp:*:*) + echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) + FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` + echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit ;; + 5000:UNIX_System_V:4.*:*) + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` + echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit ;; + i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) + echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} + exit ;; + sparc*:BSD/OS:*:*) + echo sparc-unknown-bsdi${UNAME_RELEASE} + exit ;; + *:BSD/OS:*:*) + echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} + exit ;; + *:FreeBSD:*:*) + UNAME_PROCESSOR=`/usr/bin/uname -p` + case ${UNAME_PROCESSOR} in + amd64) + echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + *) + echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + esac + exit ;; + i*:CYGWIN*:*) + echo ${UNAME_MACHINE}-pc-cygwin + exit ;; + *:MINGW64*:*) + echo ${UNAME_MACHINE}-pc-mingw64 + exit ;; + *:MINGW*:*) + echo ${UNAME_MACHINE}-pc-mingw32 + exit ;; + *:MSYS*:*) + echo ${UNAME_MACHINE}-pc-msys + exit ;; + i*:windows32*:*) + # uname -m includes "-pc" on this system. + echo ${UNAME_MACHINE}-mingw32 + exit ;; + i*:PW*:*) + echo ${UNAME_MACHINE}-pc-pw32 + exit ;; + *:Interix*:*) + case ${UNAME_MACHINE} in + x86) + echo i586-pc-interix${UNAME_RELEASE} + exit ;; + authenticamd | genuineintel | EM64T) + echo x86_64-unknown-interix${UNAME_RELEASE} + exit ;; + IA64) + echo ia64-unknown-interix${UNAME_RELEASE} + exit ;; + esac ;; + [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) + echo i${UNAME_MACHINE}-pc-mks + exit ;; + 8664:Windows_NT:*) + echo x86_64-pc-mks + exit ;; + i*:Windows_NT*:* | Pentium*:Windows_NT*:*) + # How do we know it's Interix rather than the generic POSIX subsystem? + # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we + # UNAME_MACHINE based on the output of uname instead of i386? + echo i586-pc-interix + exit ;; + i*:UWIN*:*) + echo ${UNAME_MACHINE}-pc-uwin + exit ;; + amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) + echo x86_64-unknown-cygwin + exit ;; + p*:CYGWIN*:*) + echo powerpcle-unknown-cygwin + exit ;; + prep*:SunOS:5.*:*) + echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + *:GNU:*:*) + # the GNU system + echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-${LIBC}`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` + exit ;; + *:GNU/*:*:*) + # other systems with GNU libc and userland + echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-${LIBC} + exit ;; + i*86:Minix:*:*) + echo ${UNAME_MACHINE}-pc-minix + exit ;; + aarch64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + aarch64_be:Linux:*:*) + UNAME_MACHINE=aarch64_be + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + alpha:Linux:*:*) + case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in + EV5) UNAME_MACHINE=alphaev5 ;; + EV56) UNAME_MACHINE=alphaev56 ;; + PCA56) UNAME_MACHINE=alphapca56 ;; + PCA57) UNAME_MACHINE=alphapca56 ;; + EV6) UNAME_MACHINE=alphaev6 ;; + EV67) UNAME_MACHINE=alphaev67 ;; + EV68*) UNAME_MACHINE=alphaev68 ;; + esac + objdump --private-headers /bin/sh | grep -q ld.so.1 + if test "$?" = 0 ; then LIBC="gnulibc1" ; fi + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + arc:Linux:*:* | arceb:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + arm*:Linux:*:*) + eval $set_cc_for_build + if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_EABI__ + then + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + else + if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_PCS_VFP + then + echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabi + else + echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabihf + fi + fi + exit ;; + avr32*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + cris:Linux:*:*) + echo ${UNAME_MACHINE}-axis-linux-${LIBC} + exit ;; + crisv32:Linux:*:*) + echo ${UNAME_MACHINE}-axis-linux-${LIBC} + exit ;; + frv:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + hexagon:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + i*86:Linux:*:*) + echo ${UNAME_MACHINE}-pc-linux-${LIBC} + exit ;; + ia64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + m32r*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + m68*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + mips:Linux:*:* | mips64:Linux:*:*) + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #undef CPU + #undef ${UNAME_MACHINE} + #undef ${UNAME_MACHINE}el + #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) + CPU=${UNAME_MACHINE}el + #else + #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) + CPU=${UNAME_MACHINE} + #else + CPU= + #endif + #endif +EOF + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` + test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; } + ;; + openrisc*:Linux:*:*) + echo or1k-unknown-linux-${LIBC} + exit ;; + or32:Linux:*:* | or1k*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + padre:Linux:*:*) + echo sparc-unknown-linux-${LIBC} + exit ;; + parisc64:Linux:*:* | hppa64:Linux:*:*) + echo hppa64-unknown-linux-${LIBC} + exit ;; + parisc:Linux:*:* | hppa:Linux:*:*) + # Look for CPU level + case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in + PA7*) echo hppa1.1-unknown-linux-${LIBC} ;; + PA8*) echo hppa2.0-unknown-linux-${LIBC} ;; + *) echo hppa-unknown-linux-${LIBC} ;; + esac + exit ;; + ppc64:Linux:*:*) + echo powerpc64-unknown-linux-${LIBC} + exit ;; + ppc:Linux:*:*) + echo powerpc-unknown-linux-${LIBC} + exit ;; + ppc64le:Linux:*:*) + echo powerpc64le-unknown-linux-${LIBC} + exit ;; + ppcle:Linux:*:*) + echo powerpcle-unknown-linux-${LIBC} + exit ;; + s390:Linux:*:* | s390x:Linux:*:*) + echo ${UNAME_MACHINE}-ibm-linux-${LIBC} + exit ;; + sh64*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + sh*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + sparc:Linux:*:* | sparc64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + tile*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + vax:Linux:*:*) + echo ${UNAME_MACHINE}-dec-linux-${LIBC} + exit ;; + x86_64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + xtensa*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + i*86:DYNIX/ptx:4*:*) + # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. + # earlier versions are messed up and put the nodename in both + # sysname and nodename. + echo i386-sequent-sysv4 + exit ;; + i*86:UNIX_SV:4.2MP:2.*) + # Unixware is an offshoot of SVR4, but it has its own version + # number series starting with 2... + # I am not positive that other SVR4 systems won't match this, + # I just have to hope. -- rms. + # Use sysv4.2uw... so that sysv4* matches it. + echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} + exit ;; + i*86:OS/2:*:*) + # If we were able to find `uname', then EMX Unix compatibility + # is probably installed. + echo ${UNAME_MACHINE}-pc-os2-emx + exit ;; + i*86:XTS-300:*:STOP) + echo ${UNAME_MACHINE}-unknown-stop + exit ;; + i*86:atheos:*:*) + echo ${UNAME_MACHINE}-unknown-atheos + exit ;; + i*86:syllable:*:*) + echo ${UNAME_MACHINE}-pc-syllable + exit ;; + i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) + echo i386-unknown-lynxos${UNAME_RELEASE} + exit ;; + i*86:*DOS:*:*) + echo ${UNAME_MACHINE}-pc-msdosdjgpp + exit ;; + i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) + UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` + if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then + echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} + else + echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} + fi + exit ;; + i*86:*:5:[678]*) + # UnixWare 7.x, OpenUNIX and OpenServer 6. + case `/bin/uname -X | grep "^Machine"` in + *486*) UNAME_MACHINE=i486 ;; + *Pentium) UNAME_MACHINE=i586 ;; + *Pent*|*Celeron) UNAME_MACHINE=i686 ;; + esac + echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} + exit ;; + i*86:*:3.2:*) + if test -f /usr/options/cb.name; then + UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name` + echo ${UNAME_MACHINE}-pc-isc$UNAME_REL + elif /bin/uname -X 2>/dev/null >/dev/null ; then + UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` + (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 + (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ + && UNAME_MACHINE=i586 + (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ + && UNAME_MACHINE=i686 + (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ + && UNAME_MACHINE=i686 + echo ${UNAME_MACHINE}-pc-sco$UNAME_REL + else + echo ${UNAME_MACHINE}-pc-sysv32 + fi + exit ;; + pc:*:*:*) + # Left here for compatibility: + # uname -m prints for DJGPP always 'pc', but it prints nothing about + # the processor, so we play safe by assuming i586. + # Note: whatever this is, it MUST be the same as what config.sub + # prints for the "djgpp" host, or else GDB configury will decide that + # this is a cross-build. + echo i586-pc-msdosdjgpp + exit ;; + Intel:Mach:3*:*) + echo i386-pc-mach3 + exit ;; + paragon:*:*:*) + echo i860-intel-osf1 + exit ;; + i860:*:4.*:*) # i860-SVR4 + if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then + echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 + else # Add other i860-SVR4 vendors below as they are discovered. + echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 + fi + exit ;; + mini*:CTIX:SYS*5:*) + # "miniframe" + echo m68010-convergent-sysv + exit ;; + mc68k:UNIX:SYSTEM5:3.51m) + echo m68k-convergent-sysv + exit ;; + M680?0:D-NIX:5.3:*) + echo m68k-diab-dnix + exit ;; + M68*:*:R3V[5678]*:*) + test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; + 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) + OS_REL='' + test -r /etc/.relid \ + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; + 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4; exit; } ;; + NCR*:*:4.2:* | MPRAS*:*:4.2:*) + OS_REL='.3' + test -r /etc/.relid \ + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; + m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) + echo m68k-unknown-lynxos${UNAME_RELEASE} + exit ;; + mc68030:UNIX_System_V:4.*:*) + echo m68k-atari-sysv4 + exit ;; + TSUNAMI:LynxOS:2.*:*) + echo sparc-unknown-lynxos${UNAME_RELEASE} + exit ;; + rs6000:LynxOS:2.*:*) + echo rs6000-unknown-lynxos${UNAME_RELEASE} + exit ;; + PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) + echo powerpc-unknown-lynxos${UNAME_RELEASE} + exit ;; + SM[BE]S:UNIX_SV:*:*) + echo mips-dde-sysv${UNAME_RELEASE} + exit ;; + RM*:ReliantUNIX-*:*:*) + echo mips-sni-sysv4 + exit ;; + RM*:SINIX-*:*:*) + echo mips-sni-sysv4 + exit ;; + *:SINIX-*:*:*) + if uname -p 2>/dev/null >/dev/null ; then + UNAME_MACHINE=`(uname -p) 2>/dev/null` + echo ${UNAME_MACHINE}-sni-sysv4 + else + echo ns32k-sni-sysv + fi + exit ;; + PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + # says <Richard.M.Bartel@ccMail.Census.GOV> + echo i586-unisys-sysv4 + exit ;; + *:UNIX_System_V:4*:FTX*) + # From Gerald Hewes <hewes@openmarket.com>. + # How about differentiating between stratus architectures? -djm + echo hppa1.1-stratus-sysv4 + exit ;; + *:*:*:FTX*) + # From seanf@swdc.stratus.com. + echo i860-stratus-sysv4 + exit ;; + i*86:VOS:*:*) + # From Paul.Green@stratus.com. + echo ${UNAME_MACHINE}-stratus-vos + exit ;; + *:VOS:*:*) + # From Paul.Green@stratus.com. + echo hppa1.1-stratus-vos + exit ;; + mc68*:A/UX:*:*) + echo m68k-apple-aux${UNAME_RELEASE} + exit ;; + news*:NEWS-OS:6*:*) + echo mips-sony-newsos6 + exit ;; + R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) + if [ -d /usr/nec ]; then + echo mips-nec-sysv${UNAME_RELEASE} + else + echo mips-unknown-sysv${UNAME_RELEASE} + fi + exit ;; + BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. + echo powerpc-be-beos + exit ;; + BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. + echo powerpc-apple-beos + exit ;; + BePC:BeOS:*:*) # BeOS running on Intel PC compatible. + echo i586-pc-beos + exit ;; + BePC:Haiku:*:*) # Haiku running on Intel PC compatible. + echo i586-pc-haiku + exit ;; + x86_64:Haiku:*:*) + echo x86_64-unknown-haiku + exit ;; + SX-4:SUPER-UX:*:*) + echo sx4-nec-superux${UNAME_RELEASE} + exit ;; + SX-5:SUPER-UX:*:*) + echo sx5-nec-superux${UNAME_RELEASE} + exit ;; + SX-6:SUPER-UX:*:*) + echo sx6-nec-superux${UNAME_RELEASE} + exit ;; + SX-7:SUPER-UX:*:*) + echo sx7-nec-superux${UNAME_RELEASE} + exit ;; + SX-8:SUPER-UX:*:*) + echo sx8-nec-superux${UNAME_RELEASE} + exit ;; + SX-8R:SUPER-UX:*:*) + echo sx8r-nec-superux${UNAME_RELEASE} + exit ;; + Power*:Rhapsody:*:*) + echo powerpc-apple-rhapsody${UNAME_RELEASE} + exit ;; + *:Rhapsody:*:*) + echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} + exit ;; + *:Darwin:*:*) + UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown + eval $set_cc_for_build + if test "$UNAME_PROCESSOR" = unknown ; then + UNAME_PROCESSOR=powerpc + fi + if test `echo "$UNAME_RELEASE" | sed -e 's/\..*//'` -le 10 ; then + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + case $UNAME_PROCESSOR in + i386) UNAME_PROCESSOR=x86_64 ;; + powerpc) UNAME_PROCESSOR=powerpc64 ;; + esac + fi + fi + elif test "$UNAME_PROCESSOR" = i386 ; then + # Avoid executing cc on OS X 10.9, as it ships with a stub + # that puts up a graphical alert prompting to install + # developer tools. Any system running Mac OS X 10.7 or + # later (Darwin 11 and later) is required to have a 64-bit + # processor. This is not true of the ARM version of Darwin + # that Apple uses in portable devices. + UNAME_PROCESSOR=x86_64 + fi + echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} + exit ;; + *:procnto*:*:* | *:QNX:[0123456789]*:*) + UNAME_PROCESSOR=`uname -p` + if test "$UNAME_PROCESSOR" = "x86"; then + UNAME_PROCESSOR=i386 + UNAME_MACHINE=pc + fi + echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} + exit ;; + *:QNX:*:4*) + echo i386-pc-qnx + exit ;; + NEO-?:NONSTOP_KERNEL:*:*) + echo neo-tandem-nsk${UNAME_RELEASE} + exit ;; + NSE-*:NONSTOP_KERNEL:*:*) + echo nse-tandem-nsk${UNAME_RELEASE} + exit ;; + NSR-?:NONSTOP_KERNEL:*:*) + echo nsr-tandem-nsk${UNAME_RELEASE} + exit ;; + *:NonStop-UX:*:*) + echo mips-compaq-nonstopux + exit ;; + BS2000:POSIX*:*:*) + echo bs2000-siemens-sysv + exit ;; + DS/*:UNIX_System_V:*:*) + echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} + exit ;; + *:Plan9:*:*) + # "uname -m" is not consistent, so use $cputype instead. 386 + # is converted to i386 for consistency with other x86 + # operating systems. + if test "$cputype" = "386"; then + UNAME_MACHINE=i386 + else + UNAME_MACHINE="$cputype" + fi + echo ${UNAME_MACHINE}-unknown-plan9 + exit ;; + *:TOPS-10:*:*) + echo pdp10-unknown-tops10 + exit ;; + *:TENEX:*:*) + echo pdp10-unknown-tenex + exit ;; + KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) + echo pdp10-dec-tops20 + exit ;; + XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) + echo pdp10-xkl-tops20 + exit ;; + *:TOPS-20:*:*) + echo pdp10-unknown-tops20 + exit ;; + *:ITS:*:*) + echo pdp10-unknown-its + exit ;; + SEI:*:*:SEIUX) + echo mips-sei-seiux${UNAME_RELEASE} + exit ;; + *:DragonFly:*:*) + echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` + exit ;; + *:*VMS:*:*) + UNAME_MACHINE=`(uname -p) 2>/dev/null` + case "${UNAME_MACHINE}" in + A*) echo alpha-dec-vms ; exit ;; + I*) echo ia64-dec-vms ; exit ;; + V*) echo vax-dec-vms ; exit ;; + esac ;; + *:XENIX:*:SysV) + echo i386-pc-xenix + exit ;; + i*86:skyos:*:*) + echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' + exit ;; + i*86:rdos:*:*) + echo ${UNAME_MACHINE}-pc-rdos + exit ;; + i*86:AROS:*:*) + echo ${UNAME_MACHINE}-pc-aros + exit ;; + x86_64:VMkernel:*:*) + echo ${UNAME_MACHINE}-unknown-esx + exit ;; +esac + +cat >&2 <<EOF +$0: unable to guess system type + +This script, last modified $timestamp, has failed to recognize +the operating system you are using. It is advised that you +download the most up to date version of the config scripts from + + http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD +and + http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD + +If the version you run ($0) is already up to date, please +send the following data and any information you think might be +pertinent to <config-patches@gnu.org> in order to provide the needed +information to handle your system. + +config.guess timestamp = $timestamp + +uname -m = `(uname -m) 2>/dev/null || echo unknown` +uname -r = `(uname -r) 2>/dev/null || echo unknown` +uname -s = `(uname -s) 2>/dev/null || echo unknown` +uname -v = `(uname -v) 2>/dev/null || echo unknown` + +/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` +/bin/uname -X = `(/bin/uname -X) 2>/dev/null` + +hostinfo = `(hostinfo) 2>/dev/null` +/bin/universe = `(/bin/universe) 2>/dev/null` +/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` +/bin/arch = `(/bin/arch) 2>/dev/null` +/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` +/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` + +UNAME_MACHINE = ${UNAME_MACHINE} +UNAME_RELEASE = ${UNAME_RELEASE} +UNAME_SYSTEM = ${UNAME_SYSTEM} +UNAME_VERSION = ${UNAME_VERSION} +EOF + +exit 1 + +# Local variables: +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "timestamp='" +# time-stamp-format: "%:y-%02m-%02d" +# time-stamp-end: "'" +# End: diff --git a/resources/3rdparty/cudd-3.0.0/build-aux/config.sub b/resources/3rdparty/cudd-3.0.0/build-aux/config.sub new file mode 100755 index 000000000..bba4efb80 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/build-aux/config.sub @@ -0,0 +1,1799 @@ +#! /bin/sh +# Configuration validation subroutine script. +# Copyright 1992-2014 Free Software Foundation, Inc. + +timestamp='2014-09-11' + +# This file 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 3 of the License, or +# (at your option) any later version. +# +# 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. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, see <http://www.gnu.org/licenses/>. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that +# program. This Exception is an additional permission under section 7 +# of the GNU General Public License, version 3 ("GPLv3"). + + +# Please send patches with a ChangeLog entry to config-patches@gnu.org. +# +# Configuration subroutine to validate and canonicalize a configuration type. +# Supply the specified configuration type as an argument. +# If it is invalid, we print an error message on stderr and exit with code 1. +# Otherwise, we print the canonical config type on stdout and succeed. + +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD + +# This file is supposed to be the same for all GNU packages +# and recognize all the CPU types, system types and aliases +# that are meaningful with *any* GNU software. +# Each package is responsible for reporting which valid configurations +# it does not support. The user should be able to distinguish +# a failure to support a valid configuration from a meaningless +# configuration. + +# The goal of this file is to map all the various variations of a given +# machine specification into a single specification in the form: +# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM +# or in some cases, the newer four-part form: +# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM +# It is wrong to echo any other type of specification. + +me=`echo "$0" | sed -e 's,.*/,,'` + +usage="\ +Usage: $0 [OPTION] CPU-MFR-OPSYS + $0 [OPTION] ALIAS + +Canonicalize a configuration name. + +Operation modes: + -h, --help print this help, then exit + -t, --time-stamp print date of last modification, then exit + -v, --version print version number, then exit + +Report bugs and patches to <config-patches@gnu.org>." + +version="\ +GNU config.sub ($timestamp) + +Copyright 1992-2014 Free Software Foundation, Inc. + +This is free software; see the source for copying conditions. There is NO +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." + +help=" +Try \`$me --help' for more information." + +# Parse command line +while test $# -gt 0 ; do + case $1 in + --time-stamp | --time* | -t ) + echo "$timestamp" ; exit ;; + --version | -v ) + echo "$version" ; exit ;; + --help | --h* | -h ) + echo "$usage"; exit ;; + -- ) # Stop option processing + shift; break ;; + - ) # Use stdin as input. + break ;; + -* ) + echo "$me: invalid option $1$help" + exit 1 ;; + + *local*) + # First pass through any local machine types. + echo $1 + exit ;; + + * ) + break ;; + esac +done + +case $# in + 0) echo "$me: missing argument$help" >&2 + exit 1;; + 1) ;; + *) echo "$me: too many arguments$help" >&2 + exit 1;; +esac + +# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). +# Here we must recognize all the valid KERNEL-OS combinations. +maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` +case $maybe_os in + nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ + linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ + knetbsd*-gnu* | netbsd*-gnu* | \ + kopensolaris*-gnu* | \ + storm-chaos* | os2-emx* | rtmk-nova*) + os=-$maybe_os + basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` + ;; + android-linux) + os=-linux-android + basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown + ;; + *) + basic_machine=`echo $1 | sed 's/-[^-]*$//'` + if [ $basic_machine != $1 ] + then os=`echo $1 | sed 's/.*-/-/'` + else os=; fi + ;; +esac + +### Let's recognize common machines as not being operating systems so +### that things like config.sub decstation-3100 work. We also +### recognize some manufacturers as not being operating systems, so we +### can provide default operating systems below. +case $os in + -sun*os*) + # Prevent following clause from handling this invalid input. + ;; + -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ + -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ + -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ + -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ + -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ + -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ + -apple | -axis | -knuth | -cray | -microblaze*) + os= + basic_machine=$1 + ;; + -bluegene*) + os=-cnk + ;; + -sim | -cisco | -oki | -wec | -winbond) + os= + basic_machine=$1 + ;; + -scout) + ;; + -wrs) + os=-vxworks + basic_machine=$1 + ;; + -chorusos*) + os=-chorusos + basic_machine=$1 + ;; + -chorusrdb) + os=-chorusrdb + basic_machine=$1 + ;; + -hiux*) + os=-hiuxwe2 + ;; + -sco6) + os=-sco5v6 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco5) + os=-sco3.2v5 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco4) + os=-sco3.2v4 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco3.2.[4-9]*) + os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco3.2v[4-9]*) + # Don't forget version if it is 3.2v4 or newer. + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco5v6*) + # Don't forget version if it is 3.2v4 or newer. + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco*) + os=-sco3.2v2 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -udk*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -isc) + os=-isc2.2 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -clix*) + basic_machine=clipper-intergraph + ;; + -isc*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -lynx*178) + os=-lynxos178 + ;; + -lynx*5) + os=-lynxos5 + ;; + -lynx*) + os=-lynxos + ;; + -ptx*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` + ;; + -windowsnt*) + os=`echo $os | sed -e 's/windowsnt/winnt/'` + ;; + -psos*) + os=-psos + ;; + -mint | -mint[0-9]*) + basic_machine=m68k-atari + os=-mint + ;; +esac + +# Decode aliases for certain CPU-COMPANY combinations. +case $basic_machine in + # Recognize the basic CPU types without company name. + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ + | aarch64 | aarch64_be \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ + | arc | arceb \ + | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \ + | avr | avr32 \ + | be32 | be64 \ + | bfin \ + | c4x | c8051 | clipper \ + | d10v | d30v | dlx | dsp16xx \ + | epiphany \ + | fido | fr30 | frv \ + | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ + | hexagon \ + | i370 | i860 | i960 | ia64 \ + | ip2k | iq2000 \ + | k1om \ + | le32 | le64 \ + | lm32 \ + | m32c | m32r | m32rle | m68000 | m68k | m88k \ + | maxq | mb | microblaze | microblazeel | mcore | mep | metag \ + | mips | mipsbe | mipseb | mipsel | mipsle \ + | mips16 \ + | mips64 | mips64el \ + | mips64octeon | mips64octeonel \ + | mips64orion | mips64orionel \ + | mips64r5900 | mips64r5900el \ + | mips64vr | mips64vrel \ + | mips64vr4100 | mips64vr4100el \ + | mips64vr4300 | mips64vr4300el \ + | mips64vr5000 | mips64vr5000el \ + | mips64vr5900 | mips64vr5900el \ + | mipsisa32 | mipsisa32el \ + | mipsisa32r2 | mipsisa32r2el \ + | mipsisa32r6 | mipsisa32r6el \ + | mipsisa64 | mipsisa64el \ + | mipsisa64r2 | mipsisa64r2el \ + | mipsisa64r6 | mipsisa64r6el \ + | mipsisa64sb1 | mipsisa64sb1el \ + | mipsisa64sr71k | mipsisa64sr71kel \ + | mipsr5900 | mipsr5900el \ + | mipstx39 | mipstx39el \ + | mn10200 | mn10300 \ + | moxie \ + | mt \ + | msp430 \ + | nds32 | nds32le | nds32be \ + | nios | nios2 | nios2eb | nios2el \ + | ns16k | ns32k \ + | open8 | or1k | or1knd | or32 \ + | pdp10 | pdp11 | pj | pjl \ + | powerpc | powerpc64 | powerpc64le | powerpcle \ + | pyramid \ + | riscv32 | riscv64 \ + | rl78 | rx \ + | score \ + | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ + | sh64 | sh64le \ + | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ + | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ + | spu \ + | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ + | ubicom32 \ + | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ + | we32k \ + | x86 | xc16x | xstormy16 | xtensa \ + | z8k | z80) + basic_machine=$basic_machine-unknown + ;; + c54x) + basic_machine=tic54x-unknown + ;; + c55x) + basic_machine=tic55x-unknown + ;; + c6x) + basic_machine=tic6x-unknown + ;; + m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip) + basic_machine=$basic_machine-unknown + os=-none + ;; + m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) + ;; + ms1) + basic_machine=mt-unknown + ;; + + strongarm | thumb | xscale) + basic_machine=arm-unknown + ;; + xgate) + basic_machine=$basic_machine-unknown + os=-none + ;; + xscaleeb) + basic_machine=armeb-unknown + ;; + + xscaleel) + basic_machine=armel-unknown + ;; + + # We use `pc' rather than `unknown' + # because (1) that's what they normally are, and + # (2) the word "unknown" tends to confuse beginning users. + i*86 | x86_64) + basic_machine=$basic_machine-pc + ;; + # Object if more than one company name word. + *-*-*) + echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 + exit 1 + ;; + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ + | aarch64-* | aarch64_be-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ + | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ + | avr-* | avr32-* \ + | be32-* | be64-* \ + | bfin-* | bs2000-* \ + | c[123]* | c30-* | [cjt]90-* | c4x-* \ + | c8051-* | clipper-* | craynv-* | cydra-* \ + | d10v-* | d30v-* | dlx-* \ + | elxsi-* \ + | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ + | h8300-* | h8500-* \ + | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ + | hexagon-* \ + | i*86-* | i860-* | i960-* | ia64-* \ + | ip2k-* | iq2000-* \ + | k1om-* \ + | le32-* | le64-* \ + | lm32-* \ + | m32c-* | m32r-* | m32rle-* \ + | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ + | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \ + | microblaze-* | microblazeel-* \ + | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ + | mips16-* \ + | mips64-* | mips64el-* \ + | mips64octeon-* | mips64octeonel-* \ + | mips64orion-* | mips64orionel-* \ + | mips64r5900-* | mips64r5900el-* \ + | mips64vr-* | mips64vrel-* \ + | mips64vr4100-* | mips64vr4100el-* \ + | mips64vr4300-* | mips64vr4300el-* \ + | mips64vr5000-* | mips64vr5000el-* \ + | mips64vr5900-* | mips64vr5900el-* \ + | mipsisa32-* | mipsisa32el-* \ + | mipsisa32r2-* | mipsisa32r2el-* \ + | mipsisa32r6-* | mipsisa32r6el-* \ + | mipsisa64-* | mipsisa64el-* \ + | mipsisa64r2-* | mipsisa64r2el-* \ + | mipsisa64r6-* | mipsisa64r6el-* \ + | mipsisa64sb1-* | mipsisa64sb1el-* \ + | mipsisa64sr71k-* | mipsisa64sr71kel-* \ + | mipsr5900-* | mipsr5900el-* \ + | mipstx39-* | mipstx39el-* \ + | mmix-* \ + | mt-* \ + | msp430-* \ + | nds32-* | nds32le-* | nds32be-* \ + | nios-* | nios2-* | nios2eb-* | nios2el-* \ + | none-* | np1-* | ns16k-* | ns32k-* \ + | open8-* \ + | or1k*-* \ + | orion-* \ + | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ + | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ + | pyramid-* \ + | rl78-* | romp-* | rs6000-* | rx-* \ + | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ + | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ + | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ + | sparclite-* \ + | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \ + | tahoe-* \ + | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ + | tile*-* \ + | tron-* \ + | ubicom32-* \ + | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ + | vax-* \ + | we32k-* \ + | x86-* | x86_64-* | xc16x-* | xps100-* \ + | xstormy16-* | xtensa*-* \ + | ymp-* \ + | z8k-* | z80-*) + ;; + # Recognize the basic CPU types without company name, with glob match. + xtensa*) + basic_machine=$basic_machine-unknown + ;; + # Recognize the various machine names and aliases which stand + # for a CPU type and a company and sometimes even an OS. + 386bsd) + basic_machine=i386-unknown + os=-bsd + ;; + 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) + basic_machine=m68000-att + ;; + 3b*) + basic_machine=we32k-att + ;; + a29khif) + basic_machine=a29k-amd + os=-udi + ;; + abacus) + basic_machine=abacus-unknown + ;; + adobe68k) + basic_machine=m68010-adobe + os=-scout + ;; + alliant | fx80) + basic_machine=fx80-alliant + ;; + altos | altos3068) + basic_machine=m68k-altos + ;; + am29k) + basic_machine=a29k-none + os=-bsd + ;; + amd64) + basic_machine=x86_64-pc + ;; + amd64-*) + basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + amdahl) + basic_machine=580-amdahl + os=-sysv + ;; + amiga | amiga-*) + basic_machine=m68k-unknown + ;; + amigaos | amigados) + basic_machine=m68k-unknown + os=-amigaos + ;; + amigaunix | amix) + basic_machine=m68k-unknown + os=-sysv4 + ;; + apollo68) + basic_machine=m68k-apollo + os=-sysv + ;; + apollo68bsd) + basic_machine=m68k-apollo + os=-bsd + ;; + aros) + basic_machine=i386-pc + os=-aros + ;; + aux) + basic_machine=m68k-apple + os=-aux + ;; + balance) + basic_machine=ns32k-sequent + os=-dynix + ;; + blackfin) + basic_machine=bfin-unknown + os=-linux + ;; + blackfin-*) + basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + bluegene*) + basic_machine=powerpc-ibm + os=-cnk + ;; + c54x-*) + basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c55x-*) + basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c6x-*) + basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c90) + basic_machine=c90-cray + os=-unicos + ;; + cegcc) + basic_machine=arm-unknown + os=-cegcc + ;; + convex-c1) + basic_machine=c1-convex + os=-bsd + ;; + convex-c2) + basic_machine=c2-convex + os=-bsd + ;; + convex-c32) + basic_machine=c32-convex + os=-bsd + ;; + convex-c34) + basic_machine=c34-convex + os=-bsd + ;; + convex-c38) + basic_machine=c38-convex + os=-bsd + ;; + cray | j90) + basic_machine=j90-cray + os=-unicos + ;; + craynv) + basic_machine=craynv-cray + os=-unicosmp + ;; + cr16 | cr16-*) + basic_machine=cr16-unknown + os=-elf + ;; + crds | unos) + basic_machine=m68k-crds + ;; + crisv32 | crisv32-* | etraxfs*) + basic_machine=crisv32-axis + ;; + cris | cris-* | etrax*) + basic_machine=cris-axis + ;; + crx) + basic_machine=crx-unknown + os=-elf + ;; + da30 | da30-*) + basic_machine=m68k-da30 + ;; + decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) + basic_machine=mips-dec + ;; + decsystem10* | dec10*) + basic_machine=pdp10-dec + os=-tops10 + ;; + decsystem20* | dec20*) + basic_machine=pdp10-dec + os=-tops20 + ;; + delta | 3300 | motorola-3300 | motorola-delta \ + | 3300-motorola | delta-motorola) + basic_machine=m68k-motorola + ;; + delta88) + basic_machine=m88k-motorola + os=-sysv3 + ;; + dicos) + basic_machine=i686-pc + os=-dicos + ;; + djgpp) + basic_machine=i586-pc + os=-msdosdjgpp + ;; + dpx20 | dpx20-*) + basic_machine=rs6000-bull + os=-bosx + ;; + dpx2* | dpx2*-bull) + basic_machine=m68k-bull + os=-sysv3 + ;; + ebmon29k) + basic_machine=a29k-amd + os=-ebmon + ;; + elxsi) + basic_machine=elxsi-elxsi + os=-bsd + ;; + encore | umax | mmax) + basic_machine=ns32k-encore + ;; + es1800 | OSE68k | ose68k | ose | OSE) + basic_machine=m68k-ericsson + os=-ose + ;; + fx2800) + basic_machine=i860-alliant + ;; + genix) + basic_machine=ns32k-ns + ;; + gmicro) + basic_machine=tron-gmicro + os=-sysv + ;; + go32) + basic_machine=i386-pc + os=-go32 + ;; + h3050r* | hiux*) + basic_machine=hppa1.1-hitachi + os=-hiuxwe2 + ;; + h8300hms) + basic_machine=h8300-hitachi + os=-hms + ;; + h8300xray) + basic_machine=h8300-hitachi + os=-xray + ;; + h8500hms) + basic_machine=h8500-hitachi + os=-hms + ;; + harris) + basic_machine=m88k-harris + os=-sysv3 + ;; + hp300-*) + basic_machine=m68k-hp + ;; + hp300bsd) + basic_machine=m68k-hp + os=-bsd + ;; + hp300hpux) + basic_machine=m68k-hp + os=-hpux + ;; + hp3k9[0-9][0-9] | hp9[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hp9k2[0-9][0-9] | hp9k31[0-9]) + basic_machine=m68000-hp + ;; + hp9k3[2-9][0-9]) + basic_machine=m68k-hp + ;; + hp9k6[0-9][0-9] | hp6[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hp9k7[0-79][0-9] | hp7[0-79][0-9]) + basic_machine=hppa1.1-hp + ;; + hp9k78[0-9] | hp78[0-9]) + # FIXME: really hppa2.0-hp + basic_machine=hppa1.1-hp + ;; + hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) + # FIXME: really hppa2.0-hp + basic_machine=hppa1.1-hp + ;; + hp9k8[0-9][13679] | hp8[0-9][13679]) + basic_machine=hppa1.1-hp + ;; + hp9k8[0-9][0-9] | hp8[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hppa-next) + os=-nextstep3 + ;; + hppaosf) + basic_machine=hppa1.1-hp + os=-osf + ;; + hppro) + basic_machine=hppa1.1-hp + os=-proelf + ;; + i370-ibm* | ibm*) + basic_machine=i370-ibm + ;; + i*86v32) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv32 + ;; + i*86v4*) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv4 + ;; + i*86v) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv + ;; + i*86sol2) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-solaris2 + ;; + i386mach) + basic_machine=i386-mach + os=-mach + ;; + i386-vsta | vsta) + basic_machine=i386-unknown + os=-vsta + ;; + iris | iris4d) + basic_machine=mips-sgi + case $os in + -irix*) + ;; + *) + os=-irix4 + ;; + esac + ;; + isi68 | isi) + basic_machine=m68k-isi + os=-sysv + ;; + m68knommu) + basic_machine=m68k-unknown + os=-linux + ;; + m68knommu-*) + basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + m88k-omron*) + basic_machine=m88k-omron + ;; + magnum | m3230) + basic_machine=mips-mips + os=-sysv + ;; + merlin) + basic_machine=ns32k-utek + os=-sysv + ;; + microblaze*) + basic_machine=microblaze-xilinx + ;; + mingw64) + basic_machine=x86_64-pc + os=-mingw64 + ;; + mingw32) + basic_machine=i686-pc + os=-mingw32 + ;; + mingw32ce) + basic_machine=arm-unknown + os=-mingw32ce + ;; + miniframe) + basic_machine=m68000-convergent + ;; + *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) + basic_machine=m68k-atari + os=-mint + ;; + mips3*-*) + basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` + ;; + mips3*) + basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown + ;; + monitor) + basic_machine=m68k-rom68k + os=-coff + ;; + morphos) + basic_machine=powerpc-unknown + os=-morphos + ;; + moxiebox) + basic_machine=moxie-unknown + os=-moxiebox + ;; + msdos) + basic_machine=i386-pc + os=-msdos + ;; + ms1-*) + basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` + ;; + msys) + basic_machine=i686-pc + os=-msys + ;; + mvs) + basic_machine=i370-ibm + os=-mvs + ;; + nacl) + basic_machine=le32-unknown + os=-nacl + ;; + ncr3000) + basic_machine=i486-ncr + os=-sysv4 + ;; + netbsd386) + basic_machine=i386-unknown + os=-netbsd + ;; + netwinder) + basic_machine=armv4l-rebel + os=-linux + ;; + news | news700 | news800 | news900) + basic_machine=m68k-sony + os=-newsos + ;; + news1000) + basic_machine=m68030-sony + os=-newsos + ;; + news-3600 | risc-news) + basic_machine=mips-sony + os=-newsos + ;; + necv70) + basic_machine=v70-nec + os=-sysv + ;; + next | m*-next ) + basic_machine=m68k-next + case $os in + -nextstep* ) + ;; + -ns2*) + os=-nextstep2 + ;; + *) + os=-nextstep3 + ;; + esac + ;; + nh3000) + basic_machine=m68k-harris + os=-cxux + ;; + nh[45]000) + basic_machine=m88k-harris + os=-cxux + ;; + nindy960) + basic_machine=i960-intel + os=-nindy + ;; + mon960) + basic_machine=i960-intel + os=-mon960 + ;; + nonstopux) + basic_machine=mips-compaq + os=-nonstopux + ;; + np1) + basic_machine=np1-gould + ;; + neo-tandem) + basic_machine=neo-tandem + ;; + nse-tandem) + basic_machine=nse-tandem + ;; + nsr-tandem) + basic_machine=nsr-tandem + ;; + op50n-* | op60c-*) + basic_machine=hppa1.1-oki + os=-proelf + ;; + openrisc | openrisc-*) + basic_machine=or32-unknown + ;; + os400) + basic_machine=powerpc-ibm + os=-os400 + ;; + OSE68000 | ose68000) + basic_machine=m68000-ericsson + os=-ose + ;; + os68k) + basic_machine=m68k-none + os=-os68k + ;; + pa-hitachi) + basic_machine=hppa1.1-hitachi + os=-hiuxwe2 + ;; + paragon) + basic_machine=i860-intel + os=-osf + ;; + parisc) + basic_machine=hppa-unknown + os=-linux + ;; + parisc-*) + basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + pbd) + basic_machine=sparc-tti + ;; + pbb) + basic_machine=m68k-tti + ;; + pc532 | pc532-*) + basic_machine=ns32k-pc532 + ;; + pc98) + basic_machine=i386-pc + ;; + pc98-*) + basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentium | p5 | k5 | k6 | nexgen | viac3) + basic_machine=i586-pc + ;; + pentiumpro | p6 | 6x86 | athlon | athlon_*) + basic_machine=i686-pc + ;; + pentiumii | pentium2 | pentiumiii | pentium3) + basic_machine=i686-pc + ;; + pentium4) + basic_machine=i786-pc + ;; + pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) + basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentiumpro-* | p6-* | 6x86-* | athlon-*) + basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) + basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentium4-*) + basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pn) + basic_machine=pn-gould + ;; + power) basic_machine=power-ibm + ;; + ppc | ppcbe) basic_machine=powerpc-unknown + ;; + ppc-* | ppcbe-*) + basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppcle | powerpclittle | ppc-le | powerpc-little) + basic_machine=powerpcle-unknown + ;; + ppcle-* | powerpclittle-*) + basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppc64) basic_machine=powerpc64-unknown + ;; + ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppc64le | powerpc64little | ppc64-le | powerpc64-little) + basic_machine=powerpc64le-unknown + ;; + ppc64le-* | powerpc64little-*) + basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ps2) + basic_machine=i386-ibm + ;; + pw32) + basic_machine=i586-unknown + os=-pw32 + ;; + rdos | rdos64) + basic_machine=x86_64-pc + os=-rdos + ;; + rdos32) + basic_machine=i386-pc + os=-rdos + ;; + rom68k) + basic_machine=m68k-rom68k + os=-coff + ;; + rm[46]00) + basic_machine=mips-siemens + ;; + rtpc | rtpc-*) + basic_machine=romp-ibm + ;; + s390 | s390-*) + basic_machine=s390-ibm + ;; + s390x | s390x-*) + basic_machine=s390x-ibm + ;; + sa29200) + basic_machine=a29k-amd + os=-udi + ;; + sb1) + basic_machine=mipsisa64sb1-unknown + ;; + sb1el) + basic_machine=mipsisa64sb1el-unknown + ;; + sde) + basic_machine=mipsisa32-sde + os=-elf + ;; + sei) + basic_machine=mips-sei + os=-seiux + ;; + sequent) + basic_machine=i386-sequent + ;; + sh) + basic_machine=sh-hitachi + os=-hms + ;; + sh5el) + basic_machine=sh5le-unknown + ;; + sh64) + basic_machine=sh64-unknown + ;; + sparclite-wrs | simso-wrs) + basic_machine=sparclite-wrs + os=-vxworks + ;; + sps7) + basic_machine=m68k-bull + os=-sysv2 + ;; + spur) + basic_machine=spur-unknown + ;; + st2000) + basic_machine=m68k-tandem + ;; + stratus) + basic_machine=i860-stratus + os=-sysv4 + ;; + strongarm-* | thumb-*) + basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + sun2) + basic_machine=m68000-sun + ;; + sun2os3) + basic_machine=m68000-sun + os=-sunos3 + ;; + sun2os4) + basic_machine=m68000-sun + os=-sunos4 + ;; + sun3os3) + basic_machine=m68k-sun + os=-sunos3 + ;; + sun3os4) + basic_machine=m68k-sun + os=-sunos4 + ;; + sun4os3) + basic_machine=sparc-sun + os=-sunos3 + ;; + sun4os4) + basic_machine=sparc-sun + os=-sunos4 + ;; + sun4sol2) + basic_machine=sparc-sun + os=-solaris2 + ;; + sun3 | sun3-*) + basic_machine=m68k-sun + ;; + sun4) + basic_machine=sparc-sun + ;; + sun386 | sun386i | roadrunner) + basic_machine=i386-sun + ;; + sv1) + basic_machine=sv1-cray + os=-unicos + ;; + symmetry) + basic_machine=i386-sequent + os=-dynix + ;; + t3e) + basic_machine=alphaev5-cray + os=-unicos + ;; + t90) + basic_machine=t90-cray + os=-unicos + ;; + tile*) + basic_machine=$basic_machine-unknown + os=-linux-gnu + ;; + tx39) + basic_machine=mipstx39-unknown + ;; + tx39el) + basic_machine=mipstx39el-unknown + ;; + toad1) + basic_machine=pdp10-xkl + os=-tops20 + ;; + tower | tower-32) + basic_machine=m68k-ncr + ;; + tpf) + basic_machine=s390x-ibm + os=-tpf + ;; + udi29k) + basic_machine=a29k-amd + os=-udi + ;; + ultra3) + basic_machine=a29k-nyu + os=-sym1 + ;; + v810 | necv810) + basic_machine=v810-nec + os=-none + ;; + vaxv) + basic_machine=vax-dec + os=-sysv + ;; + vms) + basic_machine=vax-dec + os=-vms + ;; + vpp*|vx|vx-*) + basic_machine=f301-fujitsu + ;; + vxworks960) + basic_machine=i960-wrs + os=-vxworks + ;; + vxworks68) + basic_machine=m68k-wrs + os=-vxworks + ;; + vxworks29k) + basic_machine=a29k-wrs + os=-vxworks + ;; + w65*) + basic_machine=w65-wdc + os=-none + ;; + w89k-*) + basic_machine=hppa1.1-winbond + os=-proelf + ;; + xbox) + basic_machine=i686-pc + os=-mingw32 + ;; + xps | xps100) + basic_machine=xps100-honeywell + ;; + xscale-* | xscalee[bl]-*) + basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` + ;; + ymp) + basic_machine=ymp-cray + os=-unicos + ;; + z8k-*-coff) + basic_machine=z8k-unknown + os=-sim + ;; + z80-*-coff) + basic_machine=z80-unknown + os=-sim + ;; + none) + basic_machine=none-none + os=-none + ;; + +# Here we handle the default manufacturer of certain CPU types. It is in +# some cases the only manufacturer, in others, it is the most popular. + w89k) + basic_machine=hppa1.1-winbond + ;; + op50n) + basic_machine=hppa1.1-oki + ;; + op60c) + basic_machine=hppa1.1-oki + ;; + romp) + basic_machine=romp-ibm + ;; + mmix) + basic_machine=mmix-knuth + ;; + rs6000) + basic_machine=rs6000-ibm + ;; + vax) + basic_machine=vax-dec + ;; + pdp10) + # there are many clones, so DEC is not a safe bet + basic_machine=pdp10-unknown + ;; + pdp11) + basic_machine=pdp11-dec + ;; + we32k) + basic_machine=we32k-att + ;; + sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) + basic_machine=sh-unknown + ;; + sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) + basic_machine=sparc-sun + ;; + cydra) + basic_machine=cydra-cydrome + ;; + orion) + basic_machine=orion-highlevel + ;; + orion105) + basic_machine=clipper-highlevel + ;; + mac | mpw | mac-mpw) + basic_machine=m68k-apple + ;; + pmac | pmac-mpw) + basic_machine=powerpc-apple + ;; + *-unknown) + # Make sure to match an already-canonicalized machine name. + ;; + *) + echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 + exit 1 + ;; +esac + +# Here we canonicalize certain aliases for manufacturers. +case $basic_machine in + *-digital*) + basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` + ;; + *-commodore*) + basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` + ;; + *) + ;; +esac + +# Decode manufacturer-specific aliases for certain operating systems. + +if [ x"$os" != x"" ] +then +case $os in + # First match some system type aliases + # that might get confused with valid system types. + # -solaris* is a basic system type, with this one exception. + -auroraux) + os=-auroraux + ;; + -solaris1 | -solaris1.*) + os=`echo $os | sed -e 's|solaris1|sunos4|'` + ;; + -solaris) + os=-solaris2 + ;; + -svr4*) + os=-sysv4 + ;; + -unixware*) + os=-sysv4.2uw + ;; + -gnu/linux*) + os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` + ;; + # First accept the basic system types. + # The portable systems comes first. + # Each alternative MUST END IN A *, to match a version number. + # -sysv* is not here because it comes later, after sysvr4. + -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ + | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ + | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ + | -sym* | -kopensolaris* | -plan9* \ + | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ + | -aos* | -aros* \ + | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ + | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ + | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ + | -bitrig* | -openbsd* | -solidbsd* \ + | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ + | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ + | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ + | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ + | -chorusos* | -chorusrdb* | -cegcc* \ + | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ + | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \ + | -linux-newlib* | -linux-musl* | -linux-uclibc* \ + | -uxpv* | -beos* | -mpeix* | -udk* | -moxiebox* \ + | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ + | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ + | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ + | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ + | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ + | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ + | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es* | -tirtos*) + # Remember, each alternative MUST END IN *, to match a version number. + ;; + -qnx*) + case $basic_machine in + x86-* | i*86-*) + ;; + *) + os=-nto$os + ;; + esac + ;; + -nto-qnx*) + ;; + -nto*) + os=`echo $os | sed -e 's|nto|nto-qnx|'` + ;; + -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ + | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ + | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) + ;; + -mac*) + os=`echo $os | sed -e 's|mac|macos|'` + ;; + -linux-dietlibc) + os=-linux-dietlibc + ;; + -linux*) + os=`echo $os | sed -e 's|linux|linux-gnu|'` + ;; + -sunos5*) + os=`echo $os | sed -e 's|sunos5|solaris2|'` + ;; + -sunos6*) + os=`echo $os | sed -e 's|sunos6|solaris3|'` + ;; + -opened*) + os=-openedition + ;; + -os400*) + os=-os400 + ;; + -wince*) + os=-wince + ;; + -osfrose*) + os=-osfrose + ;; + -osf*) + os=-osf + ;; + -utek*) + os=-bsd + ;; + -dynix*) + os=-bsd + ;; + -acis*) + os=-aos + ;; + -atheos*) + os=-atheos + ;; + -syllable*) + os=-syllable + ;; + -386bsd) + os=-bsd + ;; + -ctix* | -uts*) + os=-sysv + ;; + -nova*) + os=-rtmk-nova + ;; + -ns2 ) + os=-nextstep2 + ;; + -nsk*) + os=-nsk + ;; + # Preserve the version number of sinix5. + -sinix5.*) + os=`echo $os | sed -e 's|sinix|sysv|'` + ;; + -sinix*) + os=-sysv4 + ;; + -tpf*) + os=-tpf + ;; + -triton*) + os=-sysv3 + ;; + -oss*) + os=-sysv3 + ;; + -svr4) + os=-sysv4 + ;; + -svr3) + os=-sysv3 + ;; + -sysvr4) + os=-sysv4 + ;; + # This must come after -sysvr4. + -sysv*) + ;; + -ose*) + os=-ose + ;; + -es1800*) + os=-ose + ;; + -xenix) + os=-xenix + ;; + -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) + os=-mint + ;; + -aros*) + os=-aros + ;; + -zvmoe) + os=-zvmoe + ;; + -dicos*) + os=-dicos + ;; + -nacl*) + ;; + -none) + ;; + *) + # Get rid of the `-' at the beginning of $os. + os=`echo $os | sed 's/[^-]*-//'` + echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 + exit 1 + ;; +esac +else + +# Here we handle the default operating systems that come with various machines. +# The value should be what the vendor currently ships out the door with their +# machine or put another way, the most popular os provided with the machine. + +# Note that if you're going to try to match "-MANUFACTURER" here (say, +# "-sun"), then you have to tell the case statement up towards the top +# that MANUFACTURER isn't an operating system. Otherwise, code above +# will signal an error saying that MANUFACTURER isn't an operating +# system, and we'll never get to this point. + +case $basic_machine in + score-*) + os=-elf + ;; + spu-*) + os=-elf + ;; + *-acorn) + os=-riscix1.2 + ;; + arm*-rebel) + os=-linux + ;; + arm*-semi) + os=-aout + ;; + c4x-* | tic4x-*) + os=-coff + ;; + c8051-*) + os=-elf + ;; + hexagon-*) + os=-elf + ;; + tic54x-*) + os=-coff + ;; + tic55x-*) + os=-coff + ;; + tic6x-*) + os=-coff + ;; + # This must come before the *-dec entry. + pdp10-*) + os=-tops20 + ;; + pdp11-*) + os=-none + ;; + *-dec | vax-*) + os=-ultrix4.2 + ;; + m68*-apollo) + os=-domain + ;; + i386-sun) + os=-sunos4.0.2 + ;; + m68000-sun) + os=-sunos3 + ;; + m68*-cisco) + os=-aout + ;; + mep-*) + os=-elf + ;; + mips*-cisco) + os=-elf + ;; + mips*-*) + os=-elf + ;; + or32-*) + os=-coff + ;; + *-tti) # must be before sparc entry or we get the wrong os. + os=-sysv3 + ;; + sparc-* | *-sun) + os=-sunos4.1.1 + ;; + *-be) + os=-beos + ;; + *-haiku) + os=-haiku + ;; + *-ibm) + os=-aix + ;; + *-knuth) + os=-mmixware + ;; + *-wec) + os=-proelf + ;; + *-winbond) + os=-proelf + ;; + *-oki) + os=-proelf + ;; + *-hp) + os=-hpux + ;; + *-hitachi) + os=-hiux + ;; + i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) + os=-sysv + ;; + *-cbm) + os=-amigaos + ;; + *-dg) + os=-dgux + ;; + *-dolphin) + os=-sysv3 + ;; + m68k-ccur) + os=-rtu + ;; + m88k-omron*) + os=-luna + ;; + *-next ) + os=-nextstep + ;; + *-sequent) + os=-ptx + ;; + *-crds) + os=-unos + ;; + *-ns) + os=-genix + ;; + i370-*) + os=-mvs + ;; + *-next) + os=-nextstep3 + ;; + *-gould) + os=-sysv + ;; + *-highlevel) + os=-bsd + ;; + *-encore) + os=-bsd + ;; + *-sgi) + os=-irix + ;; + *-siemens) + os=-sysv4 + ;; + *-masscomp) + os=-rtu + ;; + f30[01]-fujitsu | f700-fujitsu) + os=-uxpv + ;; + *-rom68k) + os=-coff + ;; + *-*bug) + os=-coff + ;; + *-apple) + os=-macos + ;; + *-atari*) + os=-mint + ;; + *) + os=-none + ;; +esac +fi + +# Here we handle the case where we know the os, and the CPU type, but not the +# manufacturer. We pick the logical manufacturer. +vendor=unknown +case $basic_machine in + *-unknown) + case $os in + -riscix*) + vendor=acorn + ;; + -sunos*) + vendor=sun + ;; + -cnk*|-aix*) + vendor=ibm + ;; + -beos*) + vendor=be + ;; + -hpux*) + vendor=hp + ;; + -mpeix*) + vendor=hp + ;; + -hiux*) + vendor=hitachi + ;; + -unos*) + vendor=crds + ;; + -dgux*) + vendor=dg + ;; + -luna*) + vendor=omron + ;; + -genix*) + vendor=ns + ;; + -mvs* | -opened*) + vendor=ibm + ;; + -os400*) + vendor=ibm + ;; + -ptx*) + vendor=sequent + ;; + -tpf*) + vendor=ibm + ;; + -vxsim* | -vxworks* | -windiss*) + vendor=wrs + ;; + -aux*) + vendor=apple + ;; + -hms*) + vendor=hitachi + ;; + -mpw* | -macos*) + vendor=apple + ;; + -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) + vendor=atari + ;; + -vos*) + vendor=stratus + ;; + esac + basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` + ;; +esac + +echo $basic_machine$os +exit + +# Local variables: +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "timestamp='" +# time-stamp-format: "%:y-%02m-%02d" +# time-stamp-end: "'" +# End: diff --git a/resources/3rdparty/cudd-3.0.0/build-aux/depcomp b/resources/3rdparty/cudd-3.0.0/build-aux/depcomp new file mode 100755 index 000000000..4ebd5b3a2 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/build-aux/depcomp @@ -0,0 +1,791 @@ +#! /bin/sh +# depcomp - compile a program generating dependencies as side-effects + +scriptversion=2013-05-30.07; # UTC + +# Copyright (C) 1999-2013 Free Software Foundation, Inc. + +# 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. + +# 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. + +# You should have received a copy of the GNU General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# Originally written by Alexandre Oliva <oliva@dcc.unicamp.br>. + +case $1 in + '') + echo "$0: No command. Try '$0 --help' for more information." 1>&2 + exit 1; + ;; + -h | --h*) + cat <<\EOF +Usage: depcomp [--help] [--version] PROGRAM [ARGS] + +Run PROGRAMS ARGS to compile a file, generating dependencies +as side-effects. + +Environment variables: + depmode Dependency tracking mode. + source Source file read by 'PROGRAMS ARGS'. + object Object file output by 'PROGRAMS ARGS'. + DEPDIR directory where to store dependencies. + depfile Dependency file to output. + tmpdepfile Temporary file to use when outputting dependencies. + libtool Whether libtool is used (yes/no). + +Report bugs to <bug-automake@gnu.org>. +EOF + exit $? + ;; + -v | --v*) + echo "depcomp $scriptversion" + exit $? + ;; +esac + +# Get the directory component of the given path, and save it in the +# global variables '$dir'. Note that this directory component will +# be either empty or ending with a '/' character. This is deliberate. +set_dir_from () +{ + case $1 in + */*) dir=`echo "$1" | sed -e 's|/[^/]*$|/|'`;; + *) dir=;; + esac +} + +# Get the suffix-stripped basename of the given path, and save it the +# global variable '$base'. +set_base_from () +{ + base=`echo "$1" | sed -e 's|^.*/||' -e 's/\.[^.]*$//'` +} + +# If no dependency file was actually created by the compiler invocation, +# we still have to create a dummy depfile, to avoid errors with the +# Makefile "include basename.Plo" scheme. +make_dummy_depfile () +{ + echo "#dummy" > "$depfile" +} + +# Factor out some common post-processing of the generated depfile. +# Requires the auxiliary global variable '$tmpdepfile' to be set. +aix_post_process_depfile () +{ + # If the compiler actually managed to produce a dependency file, + # post-process it. + if test -f "$tmpdepfile"; then + # Each line is of the form 'foo.o: dependency.h'. + # Do two passes, one to just change these to + # $object: dependency.h + # and one to simply output + # dependency.h: + # which is needed to avoid the deleted-header problem. + { sed -e "s,^.*\.[$lower]*:,$object:," < "$tmpdepfile" + sed -e "s,^.*\.[$lower]*:[$tab ]*,," -e 's,$,:,' < "$tmpdepfile" + } > "$depfile" + rm -f "$tmpdepfile" + else + make_dummy_depfile + fi +} + +# A tabulation character. +tab=' ' +# A newline character. +nl=' +' +# Character ranges might be problematic outside the C locale. +# These definitions help. +upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ +lower=abcdefghijklmnopqrstuvwxyz +digits=0123456789 +alpha=${upper}${lower} + +if test -z "$depmode" || test -z "$source" || test -z "$object"; then + echo "depcomp: Variables source, object and depmode must be set" 1>&2 + exit 1 +fi + +# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. +depfile=${depfile-`echo "$object" | + sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} +tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} + +rm -f "$tmpdepfile" + +# Avoid interferences from the environment. +gccflag= dashmflag= + +# Some modes work just like other modes, but use different flags. We +# parameterize here, but still list the modes in the big case below, +# to make depend.m4 easier to write. Note that we *cannot* use a case +# here, because this file can only contain one case statement. +if test "$depmode" = hp; then + # HP compiler uses -M and no extra arg. + gccflag=-M + depmode=gcc +fi + +if test "$depmode" = dashXmstdout; then + # This is just like dashmstdout with a different argument. + dashmflag=-xM + depmode=dashmstdout +fi + +cygpath_u="cygpath -u -f -" +if test "$depmode" = msvcmsys; then + # This is just like msvisualcpp but w/o cygpath translation. + # Just convert the backslash-escaped backslashes to single forward + # slashes to satisfy depend.m4 + cygpath_u='sed s,\\\\,/,g' + depmode=msvisualcpp +fi + +if test "$depmode" = msvc7msys; then + # This is just like msvc7 but w/o cygpath translation. + # Just convert the backslash-escaped backslashes to single forward + # slashes to satisfy depend.m4 + cygpath_u='sed s,\\\\,/,g' + depmode=msvc7 +fi + +if test "$depmode" = xlc; then + # IBM C/C++ Compilers xlc/xlC can output gcc-like dependency information. + gccflag=-qmakedep=gcc,-MF + depmode=gcc +fi + +case "$depmode" in +gcc3) +## gcc 3 implements dependency tracking that does exactly what +## we want. Yay! Note: for some reason libtool 1.4 doesn't like +## it if -MD -MP comes after the -MF stuff. Hmm. +## Unfortunately, FreeBSD c89 acceptance of flags depends upon +## the command line argument order; so add the flags where they +## appear in depend2.am. Note that the slowdown incurred here +## affects only configure: in makefiles, %FASTDEP% shortcuts this. + for arg + do + case $arg in + -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; + *) set fnord "$@" "$arg" ;; + esac + shift # fnord + shift # $arg + done + "$@" + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + mv "$tmpdepfile" "$depfile" + ;; + +gcc) +## Note that this doesn't just cater to obsosete pre-3.x GCC compilers. +## but also to in-use compilers like IMB xlc/xlC and the HP C compiler. +## (see the conditional assignment to $gccflag above). +## There are various ways to get dependency output from gcc. Here's +## why we pick this rather obscure method: +## - Don't want to use -MD because we'd like the dependencies to end +## up in a subdir. Having to rename by hand is ugly. +## (We might end up doing this anyway to support other compilers.) +## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like +## -MM, not -M (despite what the docs say). Also, it might not be +## supported by the other compilers which use the 'gcc' depmode. +## - Using -M directly means running the compiler twice (even worse +## than renaming). + if test -z "$gccflag"; then + gccflag=-MD, + fi + "$@" -Wp,"$gccflag$tmpdepfile" + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + rm -f "$depfile" + echo "$object : \\" > "$depfile" + # The second -e expression handles DOS-style file names with drive + # letters. + sed -e 's/^[^:]*: / /' \ + -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" +## This next piece of magic avoids the "deleted header file" problem. +## The problem is that when a header file which appears in a .P file +## is deleted, the dependency causes make to die (because there is +## typically no way to rebuild the header). We avoid this by adding +## dummy dependencies for each header file. Too bad gcc doesn't do +## this for us directly. +## Some versions of gcc put a space before the ':'. On the theory +## that the space means something, we add a space to the output as +## well. hp depmode also adds that space, but also prefixes the VPATH +## to the object. Take care to not repeat it in the output. +## Some versions of the HPUX 10.20 sed can't process this invocation +## correctly. Breaking it into two sed invocations is a workaround. + tr ' ' "$nl" < "$tmpdepfile" \ + | sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \ + | sed -e 's/$/ :/' >> "$depfile" + rm -f "$tmpdepfile" + ;; + +hp) + # This case exists only to let depend.m4 do its work. It works by + # looking at the text of this script. This case will never be run, + # since it is checked for above. + exit 1 + ;; + +sgi) + if test "$libtool" = yes; then + "$@" "-Wp,-MDupdate,$tmpdepfile" + else + "$@" -MDupdate "$tmpdepfile" + fi + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + rm -f "$depfile" + + if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files + echo "$object : \\" > "$depfile" + # Clip off the initial element (the dependent). Don't try to be + # clever and replace this with sed code, as IRIX sed won't handle + # lines with more than a fixed number of characters (4096 in + # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; + # the IRIX cc adds comments like '#:fec' to the end of the + # dependency line. + tr ' ' "$nl" < "$tmpdepfile" \ + | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' \ + | tr "$nl" ' ' >> "$depfile" + echo >> "$depfile" + # The second pass generates a dummy entry for each header file. + tr ' ' "$nl" < "$tmpdepfile" \ + | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ + >> "$depfile" + else + make_dummy_depfile + fi + rm -f "$tmpdepfile" + ;; + +xlc) + # This case exists only to let depend.m4 do its work. It works by + # looking at the text of this script. This case will never be run, + # since it is checked for above. + exit 1 + ;; + +aix) + # The C for AIX Compiler uses -M and outputs the dependencies + # in a .u file. In older versions, this file always lives in the + # current directory. Also, the AIX compiler puts '$object:' at the + # start of each line; $object doesn't have directory information. + # Version 6 uses the directory in both cases. + set_dir_from "$object" + set_base_from "$object" + if test "$libtool" = yes; then + tmpdepfile1=$dir$base.u + tmpdepfile2=$base.u + tmpdepfile3=$dir.libs/$base.u + "$@" -Wc,-M + else + tmpdepfile1=$dir$base.u + tmpdepfile2=$dir$base.u + tmpdepfile3=$dir$base.u + "$@" -M + fi + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" + exit $stat + fi + + for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" + do + test -f "$tmpdepfile" && break + done + aix_post_process_depfile + ;; + +tcc) + # tcc (Tiny C Compiler) understand '-MD -MF file' since version 0.9.26 + # FIXME: That version still under development at the moment of writing. + # Make that this statement remains true also for stable, released + # versions. + # It will wrap lines (doesn't matter whether long or short) with a + # trailing '\', as in: + # + # foo.o : \ + # foo.c \ + # foo.h \ + # + # It will put a trailing '\' even on the last line, and will use leading + # spaces rather than leading tabs (at least since its commit 0394caf7 + # "Emit spaces for -MD"). + "$@" -MD -MF "$tmpdepfile" + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + rm -f "$depfile" + # Each non-empty line is of the form 'foo.o : \' or ' dep.h \'. + # We have to change lines of the first kind to '$object: \'. + sed -e "s|.*:|$object :|" < "$tmpdepfile" > "$depfile" + # And for each line of the second kind, we have to emit a 'dep.h:' + # dummy dependency, to avoid the deleted-header problem. + sed -n -e 's|^ *\(.*\) *\\$|\1:|p' < "$tmpdepfile" >> "$depfile" + rm -f "$tmpdepfile" + ;; + +## The order of this option in the case statement is important, since the +## shell code in configure will try each of these formats in the order +## listed in this file. A plain '-MD' option would be understood by many +## compilers, so we must ensure this comes after the gcc and icc options. +pgcc) + # Portland's C compiler understands '-MD'. + # Will always output deps to 'file.d' where file is the root name of the + # source file under compilation, even if file resides in a subdirectory. + # The object file name does not affect the name of the '.d' file. + # pgcc 10.2 will output + # foo.o: sub/foo.c sub/foo.h + # and will wrap long lines using '\' : + # foo.o: sub/foo.c ... \ + # sub/foo.h ... \ + # ... + set_dir_from "$object" + # Use the source, not the object, to determine the base name, since + # that's sadly what pgcc will do too. + set_base_from "$source" + tmpdepfile=$base.d + + # For projects that build the same source file twice into different object + # files, the pgcc approach of using the *source* file root name can cause + # problems in parallel builds. Use a locking strategy to avoid stomping on + # the same $tmpdepfile. + lockdir=$base.d-lock + trap " + echo '$0: caught signal, cleaning up...' >&2 + rmdir '$lockdir' + exit 1 + " 1 2 13 15 + numtries=100 + i=$numtries + while test $i -gt 0; do + # mkdir is a portable test-and-set. + if mkdir "$lockdir" 2>/dev/null; then + # This process acquired the lock. + "$@" -MD + stat=$? + # Release the lock. + rmdir "$lockdir" + break + else + # If the lock is being held by a different process, wait + # until the winning process is done or we timeout. + while test -d "$lockdir" && test $i -gt 0; do + sleep 1 + i=`expr $i - 1` + done + fi + i=`expr $i - 1` + done + trap - 1 2 13 15 + if test $i -le 0; then + echo "$0: failed to acquire lock after $numtries attempts" >&2 + echo "$0: check lockdir '$lockdir'" >&2 + exit 1 + fi + + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + rm -f "$depfile" + # Each line is of the form `foo.o: dependent.h', + # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. + # Do two passes, one to just change these to + # `$object: dependent.h' and one to simply `dependent.h:'. + sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" + # Some versions of the HPUX 10.20 sed can't process this invocation + # correctly. Breaking it into two sed invocations is a workaround. + sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" \ + | sed -e 's/$/ :/' >> "$depfile" + rm -f "$tmpdepfile" + ;; + +hp2) + # The "hp" stanza above does not work with aCC (C++) and HP's ia64 + # compilers, which have integrated preprocessors. The correct option + # to use with these is +Maked; it writes dependencies to a file named + # 'foo.d', which lands next to the object file, wherever that + # happens to be. + # Much of this is similar to the tru64 case; see comments there. + set_dir_from "$object" + set_base_from "$object" + if test "$libtool" = yes; then + tmpdepfile1=$dir$base.d + tmpdepfile2=$dir.libs/$base.d + "$@" -Wc,+Maked + else + tmpdepfile1=$dir$base.d + tmpdepfile2=$dir$base.d + "$@" +Maked + fi + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile1" "$tmpdepfile2" + exit $stat + fi + + for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" + do + test -f "$tmpdepfile" && break + done + if test -f "$tmpdepfile"; then + sed -e "s,^.*\.[$lower]*:,$object:," "$tmpdepfile" > "$depfile" + # Add 'dependent.h:' lines. + sed -ne '2,${ + s/^ *// + s/ \\*$// + s/$/:/ + p + }' "$tmpdepfile" >> "$depfile" + else + make_dummy_depfile + fi + rm -f "$tmpdepfile" "$tmpdepfile2" + ;; + +tru64) + # The Tru64 compiler uses -MD to generate dependencies as a side + # effect. 'cc -MD -o foo.o ...' puts the dependencies into 'foo.o.d'. + # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put + # dependencies in 'foo.d' instead, so we check for that too. + # Subdirectories are respected. + set_dir_from "$object" + set_base_from "$object" + + if test "$libtool" = yes; then + # Libtool generates 2 separate objects for the 2 libraries. These + # two compilations output dependencies in $dir.libs/$base.o.d and + # in $dir$base.o.d. We have to check for both files, because + # one of the two compilations can be disabled. We should prefer + # $dir$base.o.d over $dir.libs/$base.o.d because the latter is + # automatically cleaned when .libs/ is deleted, while ignoring + # the former would cause a distcleancheck panic. + tmpdepfile1=$dir$base.o.d # libtool 1.5 + tmpdepfile2=$dir.libs/$base.o.d # Likewise. + tmpdepfile3=$dir.libs/$base.d # Compaq CCC V6.2-504 + "$@" -Wc,-MD + else + tmpdepfile1=$dir$base.d + tmpdepfile2=$dir$base.d + tmpdepfile3=$dir$base.d + "$@" -MD + fi + + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" + exit $stat + fi + + for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" + do + test -f "$tmpdepfile" && break + done + # Same post-processing that is required for AIX mode. + aix_post_process_depfile + ;; + +msvc7) + if test "$libtool" = yes; then + showIncludes=-Wc,-showIncludes + else + showIncludes=-showIncludes + fi + "$@" $showIncludes > "$tmpdepfile" + stat=$? + grep -v '^Note: including file: ' "$tmpdepfile" + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + rm -f "$depfile" + echo "$object : \\" > "$depfile" + # The first sed program below extracts the file names and escapes + # backslashes for cygpath. The second sed program outputs the file + # name when reading, but also accumulates all include files in the + # hold buffer in order to output them again at the end. This only + # works with sed implementations that can handle large buffers. + sed < "$tmpdepfile" -n ' +/^Note: including file: *\(.*\)/ { + s//\1/ + s/\\/\\\\/g + p +}' | $cygpath_u | sort -u | sed -n ' +s/ /\\ /g +s/\(.*\)/'"$tab"'\1 \\/p +s/.\(.*\) \\/\1:/ +H +$ { + s/.*/'"$tab"'/ + G + p +}' >> "$depfile" + echo >> "$depfile" # make sure the fragment doesn't end with a backslash + rm -f "$tmpdepfile" + ;; + +msvc7msys) + # This case exists only to let depend.m4 do its work. It works by + # looking at the text of this script. This case will never be run, + # since it is checked for above. + exit 1 + ;; + +#nosideeffect) + # This comment above is used by automake to tell side-effect + # dependency tracking mechanisms from slower ones. + +dashmstdout) + # Important note: in order to support this mode, a compiler *must* + # always write the preprocessed file to stdout, regardless of -o. + "$@" || exit $? + + # Remove the call to Libtool. + if test "$libtool" = yes; then + while test "X$1" != 'X--mode=compile'; do + shift + done + shift + fi + + # Remove '-o $object'. + IFS=" " + for arg + do + case $arg in + -o) + shift + ;; + $object) + shift + ;; + *) + set fnord "$@" "$arg" + shift # fnord + shift # $arg + ;; + esac + done + + test -z "$dashmflag" && dashmflag=-M + # Require at least two characters before searching for ':' + # in the target name. This is to cope with DOS-style filenames: + # a dependency such as 'c:/foo/bar' could be seen as target 'c' otherwise. + "$@" $dashmflag | + sed "s|^[$tab ]*[^:$tab ][^:][^:]*:[$tab ]*|$object: |" > "$tmpdepfile" + rm -f "$depfile" + cat < "$tmpdepfile" > "$depfile" + # Some versions of the HPUX 10.20 sed can't process this sed invocation + # correctly. Breaking it into two sed invocations is a workaround. + tr ' ' "$nl" < "$tmpdepfile" \ + | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ + | sed -e 's/$/ :/' >> "$depfile" + rm -f "$tmpdepfile" + ;; + +dashXmstdout) + # This case only exists to satisfy depend.m4. It is never actually + # run, as this mode is specially recognized in the preamble. + exit 1 + ;; + +makedepend) + "$@" || exit $? + # Remove any Libtool call + if test "$libtool" = yes; then + while test "X$1" != 'X--mode=compile'; do + shift + done + shift + fi + # X makedepend + shift + cleared=no eat=no + for arg + do + case $cleared in + no) + set ""; shift + cleared=yes ;; + esac + if test $eat = yes; then + eat=no + continue + fi + case "$arg" in + -D*|-I*) + set fnord "$@" "$arg"; shift ;; + # Strip any option that makedepend may not understand. Remove + # the object too, otherwise makedepend will parse it as a source file. + -arch) + eat=yes ;; + -*|$object) + ;; + *) + set fnord "$@" "$arg"; shift ;; + esac + done + obj_suffix=`echo "$object" | sed 's/^.*\././'` + touch "$tmpdepfile" + ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" + rm -f "$depfile" + # makedepend may prepend the VPATH from the source file name to the object. + # No need to regex-escape $object, excess matching of '.' is harmless. + sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile" + # Some versions of the HPUX 10.20 sed can't process the last invocation + # correctly. Breaking it into two sed invocations is a workaround. + sed '1,2d' "$tmpdepfile" \ + | tr ' ' "$nl" \ + | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ + | sed -e 's/$/ :/' >> "$depfile" + rm -f "$tmpdepfile" "$tmpdepfile".bak + ;; + +cpp) + # Important note: in order to support this mode, a compiler *must* + # always write the preprocessed file to stdout. + "$@" || exit $? + + # Remove the call to Libtool. + if test "$libtool" = yes; then + while test "X$1" != 'X--mode=compile'; do + shift + done + shift + fi + + # Remove '-o $object'. + IFS=" " + for arg + do + case $arg in + -o) + shift + ;; + $object) + shift + ;; + *) + set fnord "$@" "$arg" + shift # fnord + shift # $arg + ;; + esac + done + + "$@" -E \ + | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ + -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ + | sed '$ s: \\$::' > "$tmpdepfile" + rm -f "$depfile" + echo "$object : \\" > "$depfile" + cat < "$tmpdepfile" >> "$depfile" + sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" + rm -f "$tmpdepfile" + ;; + +msvisualcpp) + # Important note: in order to support this mode, a compiler *must* + # always write the preprocessed file to stdout. + "$@" || exit $? + + # Remove the call to Libtool. + if test "$libtool" = yes; then + while test "X$1" != 'X--mode=compile'; do + shift + done + shift + fi + + IFS=" " + for arg + do + case "$arg" in + -o) + shift + ;; + $object) + shift + ;; + "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") + set fnord "$@" + shift + shift + ;; + *) + set fnord "$@" "$arg" + shift + shift + ;; + esac + done + "$@" -E 2>/dev/null | + sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile" + rm -f "$depfile" + echo "$object : \\" > "$depfile" + sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::'"$tab"'\1 \\:p' >> "$depfile" + echo "$tab" >> "$depfile" + sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile" + rm -f "$tmpdepfile" + ;; + +msvcmsys) + # This case exists only to let depend.m4 do its work. It works by + # looking at the text of this script. This case will never be run, + # since it is checked for above. + exit 1 + ;; + +none) + exec "$@" + ;; + +*) + echo "Unknown depmode $depmode" 1>&2 + exit 1 + ;; +esac + +exit 0 + +# Local Variables: +# mode: shell-script +# sh-indentation: 2 +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/resources/3rdparty/cudd-3.0.0/build-aux/install-sh b/resources/3rdparty/cudd-3.0.0/build-aux/install-sh new file mode 100755 index 000000000..377bb8687 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/build-aux/install-sh @@ -0,0 +1,527 @@ +#!/bin/sh +# install - install a program, script, or datafile + +scriptversion=2011-11-20.07; # UTC + +# This originates from X11R5 (mit/util/scripts/install.sh), which was +# later released in X11R6 (xc/config/util/install.sh) with the +# following copyright and license. +# +# Copyright (C) 1994 X Consortium +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to +# deal in the Software without restriction, including without limitation the +# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or +# sell copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in +# all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- +# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +# +# Except as contained in this notice, the name of the X Consortium shall not +# be used in advertising or otherwise to promote the sale, use or other deal- +# ings in this Software without prior written authorization from the X Consor- +# tium. +# +# +# FSF changes to this file are in the public domain. +# +# Calling this script install-sh is preferred over install.sh, to prevent +# 'make' implicit rules from creating a file called install from it +# when there is no Makefile. +# +# This script is compatible with the BSD install script, but was written +# from scratch. + +nl=' +' +IFS=" "" $nl" + +# set DOITPROG to echo to test this script + +# Don't use :- since 4.3BSD and earlier shells don't like it. +doit=${DOITPROG-} +if test -z "$doit"; then + doit_exec=exec +else + doit_exec=$doit +fi + +# Put in absolute file names if you don't have them in your path; +# or use environment vars. + +chgrpprog=${CHGRPPROG-chgrp} +chmodprog=${CHMODPROG-chmod} +chownprog=${CHOWNPROG-chown} +cmpprog=${CMPPROG-cmp} +cpprog=${CPPROG-cp} +mkdirprog=${MKDIRPROG-mkdir} +mvprog=${MVPROG-mv} +rmprog=${RMPROG-rm} +stripprog=${STRIPPROG-strip} + +posix_glob='?' +initialize_posix_glob=' + test "$posix_glob" != "?" || { + if (set -f) 2>/dev/null; then + posix_glob= + else + posix_glob=: + fi + } +' + +posix_mkdir= + +# Desired mode of installed file. +mode=0755 + +chgrpcmd= +chmodcmd=$chmodprog +chowncmd= +mvcmd=$mvprog +rmcmd="$rmprog -f" +stripcmd= + +src= +dst= +dir_arg= +dst_arg= + +copy_on_change=false +no_target_directory= + +usage="\ +Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE + or: $0 [OPTION]... SRCFILES... DIRECTORY + or: $0 [OPTION]... -t DIRECTORY SRCFILES... + or: $0 [OPTION]... -d DIRECTORIES... + +In the 1st form, copy SRCFILE to DSTFILE. +In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. +In the 4th, create DIRECTORIES. + +Options: + --help display this help and exit. + --version display version info and exit. + + -c (ignored) + -C install only if different (preserve the last data modification time) + -d create directories instead of installing files. + -g GROUP $chgrpprog installed files to GROUP. + -m MODE $chmodprog installed files to MODE. + -o USER $chownprog installed files to USER. + -s $stripprog installed files. + -t DIRECTORY install into DIRECTORY. + -T report an error if DSTFILE is a directory. + +Environment variables override the default commands: + CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG + RMPROG STRIPPROG +" + +while test $# -ne 0; do + case $1 in + -c) ;; + + -C) copy_on_change=true;; + + -d) dir_arg=true;; + + -g) chgrpcmd="$chgrpprog $2" + shift;; + + --help) echo "$usage"; exit $?;; + + -m) mode=$2 + case $mode in + *' '* | *' '* | *' +'* | *'*'* | *'?'* | *'['*) + echo "$0: invalid mode: $mode" >&2 + exit 1;; + esac + shift;; + + -o) chowncmd="$chownprog $2" + shift;; + + -s) stripcmd=$stripprog;; + + -t) dst_arg=$2 + # Protect names problematic for 'test' and other utilities. + case $dst_arg in + -* | [=\(\)!]) dst_arg=./$dst_arg;; + esac + shift;; + + -T) no_target_directory=true;; + + --version) echo "$0 $scriptversion"; exit $?;; + + --) shift + break;; + + -*) echo "$0: invalid option: $1" >&2 + exit 1;; + + *) break;; + esac + shift +done + +if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then + # When -d is used, all remaining arguments are directories to create. + # When -t is used, the destination is already specified. + # Otherwise, the last argument is the destination. Remove it from $@. + for arg + do + if test -n "$dst_arg"; then + # $@ is not empty: it contains at least $arg. + set fnord "$@" "$dst_arg" + shift # fnord + fi + shift # arg + dst_arg=$arg + # Protect names problematic for 'test' and other utilities. + case $dst_arg in + -* | [=\(\)!]) dst_arg=./$dst_arg;; + esac + done +fi + +if test $# -eq 0; then + if test -z "$dir_arg"; then + echo "$0: no input file specified." >&2 + exit 1 + fi + # It's OK to call 'install-sh -d' without argument. + # This can happen when creating conditional directories. + exit 0 +fi + +if test -z "$dir_arg"; then + do_exit='(exit $ret); exit $ret' + trap "ret=129; $do_exit" 1 + trap "ret=130; $do_exit" 2 + trap "ret=141; $do_exit" 13 + trap "ret=143; $do_exit" 15 + + # Set umask so as not to create temps with too-generous modes. + # However, 'strip' requires both read and write access to temps. + case $mode in + # Optimize common cases. + *644) cp_umask=133;; + *755) cp_umask=22;; + + *[0-7]) + if test -z "$stripcmd"; then + u_plus_rw= + else + u_plus_rw='% 200' + fi + cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; + *) + if test -z "$stripcmd"; then + u_plus_rw= + else + u_plus_rw=,u+rw + fi + cp_umask=$mode$u_plus_rw;; + esac +fi + +for src +do + # Protect names problematic for 'test' and other utilities. + case $src in + -* | [=\(\)!]) src=./$src;; + esac + + if test -n "$dir_arg"; then + dst=$src + dstdir=$dst + test -d "$dstdir" + dstdir_status=$? + else + + # Waiting for this to be detected by the "$cpprog $src $dsttmp" command + # might cause directories to be created, which would be especially bad + # if $src (and thus $dsttmp) contains '*'. + if test ! -f "$src" && test ! -d "$src"; then + echo "$0: $src does not exist." >&2 + exit 1 + fi + + if test -z "$dst_arg"; then + echo "$0: no destination specified." >&2 + exit 1 + fi + dst=$dst_arg + + # If destination is a directory, append the input filename; won't work + # if double slashes aren't ignored. + if test -d "$dst"; then + if test -n "$no_target_directory"; then + echo "$0: $dst_arg: Is a directory" >&2 + exit 1 + fi + dstdir=$dst + dst=$dstdir/`basename "$src"` + dstdir_status=0 + else + # Prefer dirname, but fall back on a substitute if dirname fails. + dstdir=` + (dirname "$dst") 2>/dev/null || + expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$dst" : 'X\(//\)[^/]' \| \ + X"$dst" : 'X\(//\)$' \| \ + X"$dst" : 'X\(/\)' \| . 2>/dev/null || + echo X"$dst" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q' + ` + + test -d "$dstdir" + dstdir_status=$? + fi + fi + + obsolete_mkdir_used=false + + if test $dstdir_status != 0; then + case $posix_mkdir in + '') + # Create intermediate dirs using mode 755 as modified by the umask. + # This is like FreeBSD 'install' as of 1997-10-28. + umask=`umask` + case $stripcmd.$umask in + # Optimize common cases. + *[2367][2367]) mkdir_umask=$umask;; + .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; + + *[0-7]) + mkdir_umask=`expr $umask + 22 \ + - $umask % 100 % 40 + $umask % 20 \ + - $umask % 10 % 4 + $umask % 2 + `;; + *) mkdir_umask=$umask,go-w;; + esac + + # With -d, create the new directory with the user-specified mode. + # Otherwise, rely on $mkdir_umask. + if test -n "$dir_arg"; then + mkdir_mode=-m$mode + else + mkdir_mode= + fi + + posix_mkdir=false + case $umask in + *[123567][0-7][0-7]) + # POSIX mkdir -p sets u+wx bits regardless of umask, which + # is incompatible with FreeBSD 'install' when (umask & 300) != 0. + ;; + *) + tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ + trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0 + + if (umask $mkdir_umask && + exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1 + then + if test -z "$dir_arg" || { + # Check for POSIX incompatibilities with -m. + # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or + # other-writable bit of parent directory when it shouldn't. + # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. + ls_ld_tmpdir=`ls -ld "$tmpdir"` + case $ls_ld_tmpdir in + d????-?r-*) different_mode=700;; + d????-?--*) different_mode=755;; + *) false;; + esac && + $mkdirprog -m$different_mode -p -- "$tmpdir" && { + ls_ld_tmpdir_1=`ls -ld "$tmpdir"` + test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" + } + } + then posix_mkdir=: + fi + rmdir "$tmpdir/d" "$tmpdir" + else + # Remove any dirs left behind by ancient mkdir implementations. + rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null + fi + trap '' 0;; + esac;; + esac + + if + $posix_mkdir && ( + umask $mkdir_umask && + $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" + ) + then : + else + + # The umask is ridiculous, or mkdir does not conform to POSIX, + # or it failed possibly due to a race condition. Create the + # directory the slow way, step by step, checking for races as we go. + + case $dstdir in + /*) prefix='/';; + [-=\(\)!]*) prefix='./';; + *) prefix='';; + esac + + eval "$initialize_posix_glob" + + oIFS=$IFS + IFS=/ + $posix_glob set -f + set fnord $dstdir + shift + $posix_glob set +f + IFS=$oIFS + + prefixes= + + for d + do + test X"$d" = X && continue + + prefix=$prefix$d + if test -d "$prefix"; then + prefixes= + else + if $posix_mkdir; then + (umask=$mkdir_umask && + $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break + # Don't fail if two instances are running concurrently. + test -d "$prefix" || exit 1 + else + case $prefix in + *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; + *) qprefix=$prefix;; + esac + prefixes="$prefixes '$qprefix'" + fi + fi + prefix=$prefix/ + done + + if test -n "$prefixes"; then + # Don't fail if two instances are running concurrently. + (umask $mkdir_umask && + eval "\$doit_exec \$mkdirprog $prefixes") || + test -d "$dstdir" || exit 1 + obsolete_mkdir_used=true + fi + fi + fi + + if test -n "$dir_arg"; then + { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && + { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && + { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || + test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 + else + + # Make a couple of temp file names in the proper directory. + dsttmp=$dstdir/_inst.$$_ + rmtmp=$dstdir/_rm.$$_ + + # Trap to clean up those temp files at exit. + trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 + + # Copy the file name to the temp name. + (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && + + # and set any options; do chmod last to preserve setuid bits. + # + # If any of these fail, we abort the whole thing. If we want to + # ignore errors from any of these, just make sure not to ignore + # errors from the above "$doit $cpprog $src $dsttmp" command. + # + { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } && + { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } && + { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } && + { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && + + # If -C, don't bother to copy if it wouldn't change the file. + if $copy_on_change && + old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` && + new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` && + + eval "$initialize_posix_glob" && + $posix_glob set -f && + set X $old && old=:$2:$4:$5:$6 && + set X $new && new=:$2:$4:$5:$6 && + $posix_glob set +f && + + test "$old" = "$new" && + $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1 + then + rm -f "$dsttmp" + else + # Rename the file to the real destination. + $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || + + # The rename failed, perhaps because mv can't rename something else + # to itself, or perhaps because mv is so ancient that it does not + # support -f. + { + # Now remove or move aside any old file at destination location. + # We try this two ways since rm can't unlink itself on some + # systems and the destination file might be busy for other + # reasons. In this case, the final cleanup might fail but the new + # file should still install successfully. + { + test ! -f "$dst" || + $doit $rmcmd -f "$dst" 2>/dev/null || + { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && + { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; } + } || + { echo "$0: cannot unlink or rename $dst" >&2 + (exit 1); exit 1 + } + } && + + # Now rename the file to the real destination. + $doit $mvcmd "$dsttmp" "$dst" + } + fi || exit 1 + + trap '' 0 + fi +done + +# Local variables: +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/resources/3rdparty/cudd-3.0.0/build-aux/ltmain.sh b/resources/3rdparty/cudd-3.0.0/build-aux/ltmain.sh new file mode 100644 index 000000000..bffda5418 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/build-aux/ltmain.sh @@ -0,0 +1,9661 @@ + +# libtool (GNU libtool) 2.4.2 +# Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996 + +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, +# 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# GNU Libtool 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 of the License, or +# (at your option) any later version. +# +# As a special exception to the GNU General Public License, +# if you distribute this file as part of a program or library that +# is built using GNU Libtool, you may include this file under the +# same distribution terms that you use for the rest of that program. +# +# GNU Libtool 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. +# +# You should have received a copy of the GNU General Public License +# along with GNU Libtool; see the file COPYING. If not, a copy +# can be downloaded from http://www.gnu.org/licenses/gpl.html, +# or obtained by writing to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + +# Usage: $progname [OPTION]... [MODE-ARG]... +# +# Provide generalized library-building support services. +# +# --config show all configuration variables +# --debug enable verbose shell tracing +# -n, --dry-run display commands without modifying any files +# --features display basic configuration information and exit +# --mode=MODE use operation mode MODE +# --preserve-dup-deps don't remove duplicate dependency libraries +# --quiet, --silent don't print informational messages +# --no-quiet, --no-silent +# print informational messages (default) +# --no-warn don't display warning messages +# --tag=TAG use configuration variables from tag TAG +# -v, --verbose print more informational messages than default +# --no-verbose don't print the extra informational messages +# --version print version information +# -h, --help, --help-all print short, long, or detailed help message +# +# MODE must be one of the following: +# +# clean remove files from the build directory +# compile compile a source file into a libtool object +# execute automatically set library path, then run a program +# finish complete the installation of libtool libraries +# install install libraries or executables +# link create a library or an executable +# uninstall remove libraries from an installed directory +# +# MODE-ARGS vary depending on the MODE. When passed as first option, +# `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that. +# Try `$progname --help --mode=MODE' for a more detailed description of MODE. +# +# When reporting a bug, please describe a test case to reproduce it and +# include the following information: +# +# host-triplet: $host +# shell: $SHELL +# compiler: $LTCC +# compiler flags: $LTCFLAGS +# linker: $LD (gnu? $with_gnu_ld) +# $progname: (GNU libtool) 2.4.2 Debian-2.4.2-1.11 +# automake: $automake_version +# autoconf: $autoconf_version +# +# Report bugs to <bug-libtool@gnu.org>. +# GNU libtool home page: <http://www.gnu.org/software/libtool/>. +# General help using GNU software: <http://www.gnu.org/gethelp/>. + +PROGRAM=libtool +PACKAGE=libtool +VERSION="2.4.2 Debian-2.4.2-1.11" +TIMESTAMP="" +package_revision=1.3337 + +# Be Bourne compatible +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: + # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac +fi +BIN_SH=xpg4; export BIN_SH # for Tru64 +DUALCASE=1; export DUALCASE # for MKS sh + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' +} + +# NLS nuisances: We save the old values to restore during execute mode. +lt_user_locale= +lt_safe_locale= +for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES +do + eval "if test \"\${$lt_var+set}\" = set; then + save_$lt_var=\$$lt_var + $lt_var=C + export $lt_var + lt_user_locale=\"$lt_var=\\\$save_\$lt_var; \$lt_user_locale\" + lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\" + fi" +done +LC_ALL=C +LANGUAGE=C +export LANGUAGE LC_ALL + +$lt_unset CDPATH + + +# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh +# is ksh but when the shell is invoked as "sh" and the current value of +# the _XPG environment variable is not equal to 1 (one), the special +# positional parameter $0, within a function call, is the name of the +# function. +progpath="$0" + + + +: ${CP="cp -f"} +test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'} +: ${MAKE="make"} +: ${MKDIR="mkdir"} +: ${MV="mv -f"} +: ${RM="rm -f"} +: ${SHELL="${CONFIG_SHELL-/bin/sh}"} +: ${Xsed="$SED -e 1s/^X//"} + +# Global variables: +EXIT_SUCCESS=0 +EXIT_FAILURE=1 +EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. +EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. + +exit_status=$EXIT_SUCCESS + +# Make sure IFS has a sensible default +lt_nl=' +' +IFS=" $lt_nl" + +dirname="s,/[^/]*$,," +basename="s,^.*/,," + +# func_dirname file append nondir_replacement +# Compute the dirname of FILE. If nonempty, add APPEND to the result, +# otherwise set result to NONDIR_REPLACEMENT. +func_dirname () +{ + func_dirname_result=`$ECHO "${1}" | $SED "$dirname"` + if test "X$func_dirname_result" = "X${1}"; then + func_dirname_result="${3}" + else + func_dirname_result="$func_dirname_result${2}" + fi +} # func_dirname may be replaced by extended shell implementation + + +# func_basename file +func_basename () +{ + func_basename_result=`$ECHO "${1}" | $SED "$basename"` +} # func_basename may be replaced by extended shell implementation + + +# func_dirname_and_basename file append nondir_replacement +# perform func_basename and func_dirname in a single function +# call: +# dirname: Compute the dirname of FILE. If nonempty, +# add APPEND to the result, otherwise set result +# to NONDIR_REPLACEMENT. +# value returned in "$func_dirname_result" +# basename: Compute filename of FILE. +# value retuned in "$func_basename_result" +# Implementation must be kept synchronized with func_dirname +# and func_basename. For efficiency, we do not delegate to +# those functions but instead duplicate the functionality here. +func_dirname_and_basename () +{ + # Extract subdirectory from the argument. + func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"` + if test "X$func_dirname_result" = "X${1}"; then + func_dirname_result="${3}" + else + func_dirname_result="$func_dirname_result${2}" + fi + func_basename_result=`$ECHO "${1}" | $SED -e "$basename"` +} # func_dirname_and_basename may be replaced by extended shell implementation + + +# func_stripname prefix suffix name +# strip PREFIX and SUFFIX off of NAME. +# PREFIX and SUFFIX must not contain globbing or regex special +# characters, hashes, percent signs, but SUFFIX may contain a leading +# dot (in which case that matches only a dot). +# func_strip_suffix prefix name +func_stripname () +{ + case ${2} in + .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; + *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; + esac +} # func_stripname may be replaced by extended shell implementation + + +# These SED scripts presuppose an absolute path with a trailing slash. +pathcar='s,^/\([^/]*\).*$,\1,' +pathcdr='s,^/[^/]*,,' +removedotparts=':dotsl + s@/\./@/@g + t dotsl + s,/\.$,/,' +collapseslashes='s@/\{1,\}@/@g' +finalslash='s,/*$,/,' + +# func_normal_abspath PATH +# Remove doubled-up and trailing slashes, "." path components, +# and cancel out any ".." path components in PATH after making +# it an absolute path. +# value returned in "$func_normal_abspath_result" +func_normal_abspath () +{ + # Start from root dir and reassemble the path. + func_normal_abspath_result= + func_normal_abspath_tpath=$1 + func_normal_abspath_altnamespace= + case $func_normal_abspath_tpath in + "") + # Empty path, that just means $cwd. + func_stripname '' '/' "`pwd`" + func_normal_abspath_result=$func_stripname_result + return + ;; + # The next three entries are used to spot a run of precisely + # two leading slashes without using negated character classes; + # we take advantage of case's first-match behaviour. + ///*) + # Unusual form of absolute path, do nothing. + ;; + //*) + # Not necessarily an ordinary path; POSIX reserves leading '//' + # and for example Cygwin uses it to access remote file shares + # over CIFS/SMB, so we conserve a leading double slash if found. + func_normal_abspath_altnamespace=/ + ;; + /*) + # Absolute path, do nothing. + ;; + *) + # Relative path, prepend $cwd. + func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath + ;; + esac + # Cancel out all the simple stuff to save iterations. We also want + # the path to end with a slash for ease of parsing, so make sure + # there is one (and only one) here. + func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$removedotparts" -e "$collapseslashes" -e "$finalslash"` + while :; do + # Processed it all yet? + if test "$func_normal_abspath_tpath" = / ; then + # If we ascended to the root using ".." the result may be empty now. + if test -z "$func_normal_abspath_result" ; then + func_normal_abspath_result=/ + fi + break + fi + func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$pathcar"` + func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$pathcdr"` + # Figure out what to do with it + case $func_normal_abspath_tcomponent in + "") + # Trailing empty path component, ignore it. + ;; + ..) + # Parent dir; strip last assembled component from result. + func_dirname "$func_normal_abspath_result" + func_normal_abspath_result=$func_dirname_result + ;; + *) + # Actual path component, append it. + func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent + ;; + esac + done + # Restore leading double-slash if one was found on entry. + func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result +} + +# func_relative_path SRCDIR DSTDIR +# generates a relative path from SRCDIR to DSTDIR, with a trailing +# slash if non-empty, suitable for immediately appending a filename +# without needing to append a separator. +# value returned in "$func_relative_path_result" +func_relative_path () +{ + func_relative_path_result= + func_normal_abspath "$1" + func_relative_path_tlibdir=$func_normal_abspath_result + func_normal_abspath "$2" + func_relative_path_tbindir=$func_normal_abspath_result + + # Ascend the tree starting from libdir + while :; do + # check if we have found a prefix of bindir + case $func_relative_path_tbindir in + $func_relative_path_tlibdir) + # found an exact match + func_relative_path_tcancelled= + break + ;; + $func_relative_path_tlibdir*) + # found a matching prefix + func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir" + func_relative_path_tcancelled=$func_stripname_result + if test -z "$func_relative_path_result"; then + func_relative_path_result=. + fi + break + ;; + *) + func_dirname $func_relative_path_tlibdir + func_relative_path_tlibdir=${func_dirname_result} + if test "x$func_relative_path_tlibdir" = x ; then + # Have to descend all the way to the root! + func_relative_path_result=../$func_relative_path_result + func_relative_path_tcancelled=$func_relative_path_tbindir + break + fi + func_relative_path_result=../$func_relative_path_result + ;; + esac + done + + # Now calculate path; take care to avoid doubling-up slashes. + func_stripname '' '/' "$func_relative_path_result" + func_relative_path_result=$func_stripname_result + func_stripname '/' '/' "$func_relative_path_tcancelled" + if test "x$func_stripname_result" != x ; then + func_relative_path_result=${func_relative_path_result}/${func_stripname_result} + fi + + # Normalisation. If bindir is libdir, return empty string, + # else relative path ending with a slash; either way, target + # file name can be directly appended. + if test ! -z "$func_relative_path_result"; then + func_stripname './' '' "$func_relative_path_result/" + func_relative_path_result=$func_stripname_result + fi +} + +# The name of this program: +func_dirname_and_basename "$progpath" +progname=$func_basename_result + +# Make sure we have an absolute path for reexecution: +case $progpath in + [\\/]*|[A-Za-z]:\\*) ;; + *[\\/]*) + progdir=$func_dirname_result + progdir=`cd "$progdir" && pwd` + progpath="$progdir/$progname" + ;; + *) + save_IFS="$IFS" + IFS=${PATH_SEPARATOR-:} + for progdir in $PATH; do + IFS="$save_IFS" + test -x "$progdir/$progname" && break + done + IFS="$save_IFS" + test -n "$progdir" || progdir=`pwd` + progpath="$progdir/$progname" + ;; +esac + +# Sed substitution that helps us do robust quoting. It backslashifies +# metacharacters that are still active within double-quoted strings. +Xsed="${SED}"' -e 1s/^X//' +sed_quote_subst='s/\([`"$\\]\)/\\\1/g' + +# Same as above, but do not quote variable references. +double_quote_subst='s/\(["`\\]\)/\\\1/g' + +# Sed substitution that turns a string into a regex matching for the +# string literally. +sed_make_literal_regex='s,[].[^$\\*\/],\\&,g' + +# Sed substitution that converts a w32 file name or path +# which contains forward slashes, into one that contains +# (escaped) backslashes. A very naive implementation. +lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' + +# Re-`\' parameter expansions in output of double_quote_subst that were +# `\'-ed in input to the same. If an odd number of `\' preceded a '$' +# in input to double_quote_subst, that '$' was protected from expansion. +# Since each input `\' is now two `\'s, look for any number of runs of +# four `\'s followed by two `\'s and then a '$'. `\' that '$'. +bs='\\' +bs2='\\\\' +bs4='\\\\\\\\' +dollar='\$' +sed_double_backslash="\ + s/$bs4/&\\ +/g + s/^$bs2$dollar/$bs&/ + s/\\([^$bs]\\)$bs2$dollar/\\1$bs2$bs$dollar/g + s/\n//g" + +# Standard options: +opt_dry_run=false +opt_help=false +opt_quiet=false +opt_verbose=false +opt_warning=: + +# func_echo arg... +# Echo program name prefixed message, along with the current mode +# name if it has been set yet. +func_echo () +{ + $ECHO "$progname: ${opt_mode+$opt_mode: }$*" +} + +# func_verbose arg... +# Echo program name prefixed message in verbose mode only. +func_verbose () +{ + $opt_verbose && func_echo ${1+"$@"} + + # A bug in bash halts the script if the last line of a function + # fails when set -e is in force, so we need another command to + # work around that: + : +} + +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "$*" +} + +# func_error arg... +# Echo program name prefixed message to standard error. +func_error () +{ + $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2 +} + +# func_warning arg... +# Echo program name prefixed warning message to standard error. +func_warning () +{ + $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2 + + # bash bug again: + : +} + +# func_fatal_error arg... +# Echo program name prefixed message to standard error, and exit. +func_fatal_error () +{ + func_error ${1+"$@"} + exit $EXIT_FAILURE +} + +# func_fatal_help arg... +# Echo program name prefixed message to standard error, followed by +# a help hint, and exit. +func_fatal_help () +{ + func_error ${1+"$@"} + func_fatal_error "$help" +} +help="Try \`$progname --help' for more information." ## default + + +# func_grep expression filename +# Check whether EXPRESSION matches any line of FILENAME, without output. +func_grep () +{ + $GREP "$1" "$2" >/dev/null 2>&1 +} + + +# func_mkdir_p directory-path +# Make sure the entire path to DIRECTORY-PATH is available. +func_mkdir_p () +{ + my_directory_path="$1" + my_dir_list= + + if test -n "$my_directory_path" && test "$opt_dry_run" != ":"; then + + # Protect directory names starting with `-' + case $my_directory_path in + -*) my_directory_path="./$my_directory_path" ;; + esac + + # While some portion of DIR does not yet exist... + while test ! -d "$my_directory_path"; do + # ...make a list in topmost first order. Use a colon delimited + # list incase some portion of path contains whitespace. + my_dir_list="$my_directory_path:$my_dir_list" + + # If the last portion added has no slash in it, the list is done + case $my_directory_path in */*) ;; *) break ;; esac + + # ...otherwise throw away the child directory and loop + my_directory_path=`$ECHO "$my_directory_path" | $SED -e "$dirname"` + done + my_dir_list=`$ECHO "$my_dir_list" | $SED 's,:*$,,'` + + save_mkdir_p_IFS="$IFS"; IFS=':' + for my_dir in $my_dir_list; do + IFS="$save_mkdir_p_IFS" + # mkdir can fail with a `File exist' error if two processes + # try to create one of the directories concurrently. Don't + # stop in that case! + $MKDIR "$my_dir" 2>/dev/null || : + done + IFS="$save_mkdir_p_IFS" + + # Bail out if we (or some other process) failed to create a directory. + test -d "$my_directory_path" || \ + func_fatal_error "Failed to create \`$1'" + fi +} + + +# func_mktempdir [string] +# Make a temporary directory that won't clash with other running +# libtool processes, and avoids race conditions if possible. If +# given, STRING is the basename for that directory. +func_mktempdir () +{ + my_template="${TMPDIR-/tmp}/${1-$progname}" + + if test "$opt_dry_run" = ":"; then + # Return a directory name, but don't create it in dry-run mode + my_tmpdir="${my_template}-$$" + else + + # If mktemp works, use that first and foremost + my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` + + if test ! -d "$my_tmpdir"; then + # Failing that, at least try and use $RANDOM to avoid a race + my_tmpdir="${my_template}-${RANDOM-0}$$" + + save_mktempdir_umask=`umask` + umask 0077 + $MKDIR "$my_tmpdir" + umask $save_mktempdir_umask + fi + + # If we're not in dry-run mode, bomb out on failure + test -d "$my_tmpdir" || \ + func_fatal_error "cannot create temporary directory \`$my_tmpdir'" + fi + + $ECHO "$my_tmpdir" +} + + +# func_quote_for_eval arg +# Aesthetically quote ARG to be evaled later. +# This function returns two values: FUNC_QUOTE_FOR_EVAL_RESULT +# is double-quoted, suitable for a subsequent eval, whereas +# FUNC_QUOTE_FOR_EVAL_UNQUOTED_RESULT has merely all characters +# which are still active within double quotes backslashified. +func_quote_for_eval () +{ + case $1 in + *[\\\`\"\$]*) + func_quote_for_eval_unquoted_result=`$ECHO "$1" | $SED "$sed_quote_subst"` ;; + *) + func_quote_for_eval_unquoted_result="$1" ;; + esac + + case $func_quote_for_eval_unquoted_result in + # Double-quote args containing shell metacharacters to delay + # word splitting, command substitution and and variable + # expansion for a subsequent eval. + # Many Bourne shells cannot handle close brackets correctly + # in scan sets, so we specify it separately. + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + func_quote_for_eval_result="\"$func_quote_for_eval_unquoted_result\"" + ;; + *) + func_quote_for_eval_result="$func_quote_for_eval_unquoted_result" + esac +} + + +# func_quote_for_expand arg +# Aesthetically quote ARG to be evaled later; same as above, +# but do not quote variable references. +func_quote_for_expand () +{ + case $1 in + *[\\\`\"]*) + my_arg=`$ECHO "$1" | $SED \ + -e "$double_quote_subst" -e "$sed_double_backslash"` ;; + *) + my_arg="$1" ;; + esac + + case $my_arg in + # Double-quote args containing shell metacharacters to delay + # word splitting and command substitution for a subsequent eval. + # Many Bourne shells cannot handle close brackets correctly + # in scan sets, so we specify it separately. + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + my_arg="\"$my_arg\"" + ;; + esac + + func_quote_for_expand_result="$my_arg" +} + + +# func_show_eval cmd [fail_exp] +# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is +# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP +# is given, then evaluate it. +func_show_eval () +{ + my_cmd="$1" + my_fail_exp="${2-:}" + + ${opt_silent-false} || { + func_quote_for_expand "$my_cmd" + eval "func_echo $func_quote_for_expand_result" + } + + if ${opt_dry_run-false}; then :; else + eval "$my_cmd" + my_status=$? + if test "$my_status" -eq 0; then :; else + eval "(exit $my_status); $my_fail_exp" + fi + fi +} + + +# func_show_eval_locale cmd [fail_exp] +# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is +# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP +# is given, then evaluate it. Use the saved locale for evaluation. +func_show_eval_locale () +{ + my_cmd="$1" + my_fail_exp="${2-:}" + + ${opt_silent-false} || { + func_quote_for_expand "$my_cmd" + eval "func_echo $func_quote_for_expand_result" + } + + if ${opt_dry_run-false}; then :; else + eval "$lt_user_locale + $my_cmd" + my_status=$? + eval "$lt_safe_locale" + if test "$my_status" -eq 0; then :; else + eval "(exit $my_status); $my_fail_exp" + fi + fi +} + +# func_tr_sh +# Turn $1 into a string suitable for a shell variable name. +# Result is stored in $func_tr_sh_result. All characters +# not in the set a-zA-Z0-9_ are replaced with '_'. Further, +# if $1 begins with a digit, a '_' is prepended as well. +func_tr_sh () +{ + case $1 in + [0-9]* | *[!a-zA-Z0-9_]*) + func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'` + ;; + * ) + func_tr_sh_result=$1 + ;; + esac +} + + +# func_version +# Echo version message to standard output and exit. +func_version () +{ + $opt_debug + + $SED -n '/(C)/!b go + :more + /\./!{ + N + s/\n# / / + b more + } + :go + /^# '$PROGRAM' (GNU /,/# warranty; / { + s/^# // + s/^# *$// + s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/ + p + }' < "$progpath" + exit $? +} + +# func_usage +# Echo short help message to standard output and exit. +func_usage () +{ + $opt_debug + + $SED -n '/^# Usage:/,/^# *.*--help/ { + s/^# // + s/^# *$// + s/\$progname/'$progname'/ + p + }' < "$progpath" + echo + $ECHO "run \`$progname --help | more' for full usage" + exit $? +} + +# func_help [NOEXIT] +# Echo long help message to standard output and exit, +# unless 'noexit' is passed as argument. +func_help () +{ + $opt_debug + + $SED -n '/^# Usage:/,/# Report bugs to/ { + :print + s/^# // + s/^# *$// + s*\$progname*'$progname'* + s*\$host*'"$host"'* + s*\$SHELL*'"$SHELL"'* + s*\$LTCC*'"$LTCC"'* + s*\$LTCFLAGS*'"$LTCFLAGS"'* + s*\$LD*'"$LD"'* + s/\$with_gnu_ld/'"$with_gnu_ld"'/ + s/\$automake_version/'"`(${AUTOMAKE-automake} --version) 2>/dev/null |$SED 1q`"'/ + s/\$autoconf_version/'"`(${AUTOCONF-autoconf} --version) 2>/dev/null |$SED 1q`"'/ + p + d + } + /^# .* home page:/b print + /^# General help using/b print + ' < "$progpath" + ret=$? + if test -z "$1"; then + exit $ret + fi +} + +# func_missing_arg argname +# Echo program name prefixed message to standard error and set global +# exit_cmd. +func_missing_arg () +{ + $opt_debug + + func_error "missing argument for $1." + exit_cmd=exit +} + + +# func_split_short_opt shortopt +# Set func_split_short_opt_name and func_split_short_opt_arg shell +# variables after splitting SHORTOPT after the 2nd character. +func_split_short_opt () +{ + my_sed_short_opt='1s/^\(..\).*$/\1/;q' + my_sed_short_rest='1s/^..\(.*\)$/\1/;q' + + func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"` + func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"` +} # func_split_short_opt may be replaced by extended shell implementation + + +# func_split_long_opt longopt +# Set func_split_long_opt_name and func_split_long_opt_arg shell +# variables after splitting LONGOPT at the `=' sign. +func_split_long_opt () +{ + my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q' + my_sed_long_arg='1s/^--[^=]*=//' + + func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"` + func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"` +} # func_split_long_opt may be replaced by extended shell implementation + +exit_cmd=: + + + + + +magic="%%%MAGIC variable%%%" +magic_exe="%%%MAGIC EXE variable%%%" + +# Global variables. +nonopt= +preserve_args= +lo2o="s/\\.lo\$/.${objext}/" +o2lo="s/\\.${objext}\$/.lo/" +extracted_archives= +extracted_serial=0 + +# If this variable is set in any of the actions, the command in it +# will be execed at the end. This prevents here-documents from being +# left over by shells. +exec_cmd= + +# func_append var value +# Append VALUE to the end of shell variable VAR. +func_append () +{ + eval "${1}=\$${1}\${2}" +} # func_append may be replaced by extended shell implementation + +# func_append_quoted var value +# Quote VALUE and append to the end of shell variable VAR, separated +# by a space. +func_append_quoted () +{ + func_quote_for_eval "${2}" + eval "${1}=\$${1}\\ \$func_quote_for_eval_result" +} # func_append_quoted may be replaced by extended shell implementation + + +# func_arith arithmetic-term... +func_arith () +{ + func_arith_result=`expr "${@}"` +} # func_arith may be replaced by extended shell implementation + + +# func_len string +# STRING may not start with a hyphen. +func_len () +{ + func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len` +} # func_len may be replaced by extended shell implementation + + +# func_lo2o object +func_lo2o () +{ + func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` +} # func_lo2o may be replaced by extended shell implementation + + +# func_xform libobj-or-source +func_xform () +{ + func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'` +} # func_xform may be replaced by extended shell implementation + + +# func_fatal_configuration arg... +# Echo program name prefixed message to standard error, followed by +# a configuration failure hint, and exit. +func_fatal_configuration () +{ + func_error ${1+"$@"} + func_error "See the $PACKAGE documentation for more information." + func_fatal_error "Fatal configuration error." +} + + +# func_config +# Display the configuration for all the tags in this script. +func_config () +{ + re_begincf='^# ### BEGIN LIBTOOL' + re_endcf='^# ### END LIBTOOL' + + # Default configuration. + $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" + + # Now print the configurations for the tags. + for tagname in $taglist; do + $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" + done + + exit $? +} + +# func_features +# Display the features supported by this script. +func_features () +{ + echo "host: $host" + if test "$build_libtool_libs" = yes; then + echo "enable shared libraries" + else + echo "disable shared libraries" + fi + if test "$build_old_libs" = yes; then + echo "enable static libraries" + else + echo "disable static libraries" + fi + + exit $? +} + +# func_enable_tag tagname +# Verify that TAGNAME is valid, and either flag an error and exit, or +# enable the TAGNAME tag. We also add TAGNAME to the global $taglist +# variable here. +func_enable_tag () +{ + # Global variable: + tagname="$1" + + re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" + re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" + sed_extractcf="/$re_begincf/,/$re_endcf/p" + + # Validate tagname. + case $tagname in + *[!-_A-Za-z0-9,/]*) + func_fatal_error "invalid tag name: $tagname" + ;; + esac + + # Don't test for the "default" C tag, as we know it's + # there but not specially marked. + case $tagname in + CC) ;; + *) + if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then + taglist="$taglist $tagname" + + # Evaluate the configuration. Be careful to quote the path + # and the sed script, to avoid splitting on whitespace, but + # also don't use non-portable quotes within backquotes within + # quotes we have to do it in 2 steps: + extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` + eval "$extractedcf" + else + func_error "ignoring unknown tag $tagname" + fi + ;; + esac +} + +# func_check_version_match +# Ensure that we are using m4 macros, and libtool script from the same +# release of libtool. +func_check_version_match () +{ + if test "$package_revision" != "$macro_revision"; then + if test "$VERSION" != "$macro_version"; then + if test -z "$macro_version"; then + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, but the +$progname: definition of this LT_INIT comes from an older release. +$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION +$progname: and run autoconf again. +_LT_EOF + else + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, but the +$progname: definition of this LT_INIT comes from $PACKAGE $macro_version. +$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION +$progname: and run autoconf again. +_LT_EOF + fi + else + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, +$progname: but the definition of this LT_INIT comes from revision $macro_revision. +$progname: You should recreate aclocal.m4 with macros from revision $package_revision +$progname: of $PACKAGE $VERSION and run autoconf again. +_LT_EOF + fi + + exit $EXIT_MISMATCH + fi +} + + +# Shorthand for --mode=foo, only valid as the first argument +case $1 in +clean|clea|cle|cl) + shift; set dummy --mode clean ${1+"$@"}; shift + ;; +compile|compil|compi|comp|com|co|c) + shift; set dummy --mode compile ${1+"$@"}; shift + ;; +execute|execut|execu|exec|exe|ex|e) + shift; set dummy --mode execute ${1+"$@"}; shift + ;; +finish|finis|fini|fin|fi|f) + shift; set dummy --mode finish ${1+"$@"}; shift + ;; +install|instal|insta|inst|ins|in|i) + shift; set dummy --mode install ${1+"$@"}; shift + ;; +link|lin|li|l) + shift; set dummy --mode link ${1+"$@"}; shift + ;; +uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) + shift; set dummy --mode uninstall ${1+"$@"}; shift + ;; +esac + + + +# Option defaults: +opt_debug=: +opt_dry_run=false +opt_config=false +opt_preserve_dup_deps=false +opt_features=false +opt_finish=false +opt_help=false +opt_help_all=false +opt_silent=: +opt_warning=: +opt_verbose=: +opt_silent=false +opt_verbose=false + + +# Parse options once, thoroughly. This comes as soon as possible in the +# script to make things like `--version' happen as quickly as we can. +{ + # this just eases exit handling + while test $# -gt 0; do + opt="$1" + shift + case $opt in + --debug|-x) opt_debug='set -x' + func_echo "enabling shell trace mode" + $opt_debug + ;; + --dry-run|--dryrun|-n) + opt_dry_run=: + ;; + --config) + opt_config=: +func_config + ;; + --dlopen|-dlopen) + optarg="$1" + opt_dlopen="${opt_dlopen+$opt_dlopen +}$optarg" + shift + ;; + --preserve-dup-deps) + opt_preserve_dup_deps=: + ;; + --features) + opt_features=: +func_features + ;; + --finish) + opt_finish=: +set dummy --mode finish ${1+"$@"}; shift + ;; + --help) + opt_help=: + ;; + --help-all) + opt_help_all=: +opt_help=': help-all' + ;; + --mode) + test $# = 0 && func_missing_arg $opt && break + optarg="$1" + opt_mode="$optarg" +case $optarg in + # Valid mode arguments: + clean|compile|execute|finish|install|link|relink|uninstall) ;; + + # Catch anything else as an error + *) func_error "invalid argument for $opt" + exit_cmd=exit + break + ;; +esac + shift + ;; + --no-silent|--no-quiet) + opt_silent=false +func_append preserve_args " $opt" + ;; + --no-warning|--no-warn) + opt_warning=false +func_append preserve_args " $opt" + ;; + --no-verbose) + opt_verbose=false +func_append preserve_args " $opt" + ;; + --silent|--quiet) + opt_silent=: +func_append preserve_args " $opt" + opt_verbose=false + ;; + --verbose|-v) + opt_verbose=: +func_append preserve_args " $opt" +opt_silent=false + ;; + --tag) + test $# = 0 && func_missing_arg $opt && break + optarg="$1" + opt_tag="$optarg" +func_append preserve_args " $opt $optarg" +func_enable_tag "$optarg" + shift + ;; + + -\?|-h) func_usage ;; + --help) func_help ;; + --version) func_version ;; + + # Separate optargs to long options: + --*=*) + func_split_long_opt "$opt" + set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"} + shift + ;; + + # Separate non-argument short options: + -\?*|-h*|-n*|-v*) + func_split_short_opt "$opt" + set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"} + shift + ;; + + --) break ;; + -*) func_fatal_help "unrecognized option \`$opt'" ;; + *) set dummy "$opt" ${1+"$@"}; shift; break ;; + esac + done + + # Validate options: + + # save first non-option argument + if test "$#" -gt 0; then + nonopt="$opt" + shift + fi + + # preserve --debug + test "$opt_debug" = : || func_append preserve_args " --debug" + + case $host in + *cygwin* | *mingw* | *pw32* | *cegcc*) + # don't eliminate duplications in $postdeps and $predeps + opt_duplicate_compiler_generated_deps=: + ;; + *) + opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps + ;; + esac + + $opt_help || { + # Sanity checks first: + func_check_version_match + + if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then + func_fatal_configuration "not configured to build any kind of library" + fi + + # Darwin sucks + eval std_shrext=\"$shrext_cmds\" + + # Only execute mode is allowed to have -dlopen flags. + if test -n "$opt_dlopen" && test "$opt_mode" != execute; then + func_error "unrecognized option \`-dlopen'" + $ECHO "$help" 1>&2 + exit $EXIT_FAILURE + fi + + # Change the help message to a mode-specific one. + generic_help="$help" + help="Try \`$progname --help --mode=$opt_mode' for more information." + } + + + # Bail if the options were screwed + $exit_cmd $EXIT_FAILURE +} + + + + +## ----------- ## +## Main. ## +## ----------- ## + +# func_lalib_p file +# True iff FILE is a libtool `.la' library or `.lo' object file. +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_lalib_p () +{ + test -f "$1" && + $SED -e 4q "$1" 2>/dev/null \ + | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 +} + +# func_lalib_unsafe_p file +# True iff FILE is a libtool `.la' library or `.lo' object file. +# This function implements the same check as func_lalib_p without +# resorting to external programs. To this end, it redirects stdin and +# closes it afterwards, without saving the original file descriptor. +# As a safety measure, use it only where a negative result would be +# fatal anyway. Works if `file' does not exist. +func_lalib_unsafe_p () +{ + lalib_p=no + if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then + for lalib_p_l in 1 2 3 4 + do + read lalib_p_line + case "$lalib_p_line" in + \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; + esac + done + exec 0<&5 5<&- + fi + test "$lalib_p" = yes +} + +# func_ltwrapper_script_p file +# True iff FILE is a libtool wrapper script +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_script_p () +{ + func_lalib_p "$1" +} + +# func_ltwrapper_executable_p file +# True iff FILE is a libtool wrapper executable +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_executable_p () +{ + func_ltwrapper_exec_suffix= + case $1 in + *.exe) ;; + *) func_ltwrapper_exec_suffix=.exe ;; + esac + $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 +} + +# func_ltwrapper_scriptname file +# Assumes file is an ltwrapper_executable +# uses $file to determine the appropriate filename for a +# temporary ltwrapper_script. +func_ltwrapper_scriptname () +{ + func_dirname_and_basename "$1" "" "." + func_stripname '' '.exe' "$func_basename_result" + func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper" +} + +# func_ltwrapper_p file +# True iff FILE is a libtool wrapper script or wrapper executable +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_p () +{ + func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" +} + + +# func_execute_cmds commands fail_cmd +# Execute tilde-delimited COMMANDS. +# If FAIL_CMD is given, eval that upon failure. +# FAIL_CMD may read-access the current command in variable CMD! +func_execute_cmds () +{ + $opt_debug + save_ifs=$IFS; IFS='~' + for cmd in $1; do + IFS=$save_ifs + eval cmd=\"$cmd\" + func_show_eval "$cmd" "${2-:}" + done + IFS=$save_ifs +} + + +# func_source file +# Source FILE, adding directory component if necessary. +# Note that it is not necessary on cygwin/mingw to append a dot to +# FILE even if both FILE and FILE.exe exist: automatic-append-.exe +# behavior happens only for exec(3), not for open(2)! Also, sourcing +# `FILE.' does not work on cygwin managed mounts. +func_source () +{ + $opt_debug + case $1 in + */* | *\\*) . "$1" ;; + *) . "./$1" ;; + esac +} + + +# func_resolve_sysroot PATH +# Replace a leading = in PATH with a sysroot. Store the result into +# func_resolve_sysroot_result +func_resolve_sysroot () +{ + func_resolve_sysroot_result=$1 + case $func_resolve_sysroot_result in + =*) + func_stripname '=' '' "$func_resolve_sysroot_result" + func_resolve_sysroot_result=$lt_sysroot$func_stripname_result + ;; + esac +} + +# func_replace_sysroot PATH +# If PATH begins with the sysroot, replace it with = and +# store the result into func_replace_sysroot_result. +func_replace_sysroot () +{ + case "$lt_sysroot:$1" in + ?*:"$lt_sysroot"*) + func_stripname "$lt_sysroot" '' "$1" + func_replace_sysroot_result="=$func_stripname_result" + ;; + *) + # Including no sysroot. + func_replace_sysroot_result=$1 + ;; + esac +} + +# func_infer_tag arg +# Infer tagged configuration to use if any are available and +# if one wasn't chosen via the "--tag" command line option. +# Only attempt this if the compiler in the base compile +# command doesn't match the default compiler. +# arg is usually of the form 'gcc ...' +func_infer_tag () +{ + $opt_debug + if test -n "$available_tags" && test -z "$tagname"; then + CC_quoted= + for arg in $CC; do + func_append_quoted CC_quoted "$arg" + done + CC_expanded=`func_echo_all $CC` + CC_quoted_expanded=`func_echo_all $CC_quoted` + case $@ in + # Blanks in the command may have been stripped by the calling shell, + # but not from the CC environment variable when configure was run. + " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ + " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; + # Blanks at the start of $base_compile will cause this to fail + # if we don't check for them as well. + *) + for z in $available_tags; do + if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then + # Evaluate the configuration. + eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" + CC_quoted= + for arg in $CC; do + # Double-quote args containing other shell metacharacters. + func_append_quoted CC_quoted "$arg" + done + CC_expanded=`func_echo_all $CC` + CC_quoted_expanded=`func_echo_all $CC_quoted` + case "$@ " in + " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ + " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) + # The compiler in the base compile command matches + # the one in the tagged configuration. + # Assume this is the tagged configuration we want. + tagname=$z + break + ;; + esac + fi + done + # If $tagname still isn't set, then no tagged configuration + # was found and let the user know that the "--tag" command + # line option must be used. + if test -z "$tagname"; then + func_echo "unable to infer tagged configuration" + func_fatal_error "specify a tag with \`--tag'" +# else +# func_verbose "using $tagname tagged configuration" + fi + ;; + esac + fi +} + + + +# func_write_libtool_object output_name pic_name nonpic_name +# Create a libtool object file (analogous to a ".la" file), +# but don't create it if we're doing a dry run. +func_write_libtool_object () +{ + write_libobj=${1} + if test "$build_libtool_libs" = yes; then + write_lobj=\'${2}\' + else + write_lobj=none + fi + + if test "$build_old_libs" = yes; then + write_oldobj=\'${3}\' + else + write_oldobj=none + fi + + $opt_dry_run || { + cat >${write_libobj}T <<EOF +# $write_libobj - a libtool object file +# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION +# +# Please DO NOT delete this file! +# It is necessary for linking the library. + +# Name of the PIC object. +pic_object=$write_lobj + +# Name of the non-PIC object +non_pic_object=$write_oldobj + +EOF + $MV "${write_libobj}T" "${write_libobj}" + } +} + + +################################################## +# FILE NAME AND PATH CONVERSION HELPER FUNCTIONS # +################################################## + +# func_convert_core_file_wine_to_w32 ARG +# Helper function used by file name conversion functions when $build is *nix, +# and $host is mingw, cygwin, or some other w32 environment. Relies on a +# correctly configured wine environment available, with the winepath program +# in $build's $PATH. +# +# ARG is the $build file name to be converted to w32 format. +# Result is available in $func_convert_core_file_wine_to_w32_result, and will +# be empty on error (or when ARG is empty) +func_convert_core_file_wine_to_w32 () +{ + $opt_debug + func_convert_core_file_wine_to_w32_result="$1" + if test -n "$1"; then + # Unfortunately, winepath does not exit with a non-zero error code, so we + # are forced to check the contents of stdout. On the other hand, if the + # command is not found, the shell will set an exit code of 127 and print + # *an error message* to stdout. So we must check for both error code of + # zero AND non-empty stdout, which explains the odd construction: + func_convert_core_file_wine_to_w32_tmp=`winepath -w "$1" 2>/dev/null` + if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then + func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | + $SED -e "$lt_sed_naive_backslashify"` + else + func_convert_core_file_wine_to_w32_result= + fi + fi +} +# end: func_convert_core_file_wine_to_w32 + + +# func_convert_core_path_wine_to_w32 ARG +# Helper function used by path conversion functions when $build is *nix, and +# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly +# configured wine environment available, with the winepath program in $build's +# $PATH. Assumes ARG has no leading or trailing path separator characters. +# +# ARG is path to be converted from $build format to win32. +# Result is available in $func_convert_core_path_wine_to_w32_result. +# Unconvertible file (directory) names in ARG are skipped; if no directory names +# are convertible, then the result may be empty. +func_convert_core_path_wine_to_w32 () +{ + $opt_debug + # unfortunately, winepath doesn't convert paths, only file names + func_convert_core_path_wine_to_w32_result="" + if test -n "$1"; then + oldIFS=$IFS + IFS=: + for func_convert_core_path_wine_to_w32_f in $1; do + IFS=$oldIFS + func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" + if test -n "$func_convert_core_file_wine_to_w32_result" ; then + if test -z "$func_convert_core_path_wine_to_w32_result"; then + func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result" + else + func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" + fi + fi + done + IFS=$oldIFS + fi +} +# end: func_convert_core_path_wine_to_w32 + + +# func_cygpath ARGS... +# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when +# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) +# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or +# (2), returns the Cygwin file name or path in func_cygpath_result (input +# file name or path is assumed to be in w32 format, as previously converted +# from $build's *nix or MSYS format). In case (3), returns the w32 file name +# or path in func_cygpath_result (input file name or path is assumed to be in +# Cygwin format). Returns an empty string on error. +# +# ARGS are passed to cygpath, with the last one being the file name or path to +# be converted. +# +# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH +# environment variable; do not put it in $PATH. +func_cygpath () +{ + $opt_debug + if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then + func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` + if test "$?" -ne 0; then + # on failure, ensure result is empty + func_cygpath_result= + fi + else + func_cygpath_result= + func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'" + fi +} +#end: func_cygpath + + +# func_convert_core_msys_to_w32 ARG +# Convert file name or path ARG from MSYS format to w32 format. Return +# result in func_convert_core_msys_to_w32_result. +func_convert_core_msys_to_w32 () +{ + $opt_debug + # awkward: cmd appends spaces to result + func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | + $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"` +} +#end: func_convert_core_msys_to_w32 + + +# func_convert_file_check ARG1 ARG2 +# Verify that ARG1 (a file name in $build format) was converted to $host +# format in ARG2. Otherwise, emit an error message, but continue (resetting +# func_to_host_file_result to ARG1). +func_convert_file_check () +{ + $opt_debug + if test -z "$2" && test -n "$1" ; then + func_error "Could not determine host file name corresponding to" + func_error " \`$1'" + func_error "Continuing, but uninstalled executables may not work." + # Fallback: + func_to_host_file_result="$1" + fi +} +# end func_convert_file_check + + +# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH +# Verify that FROM_PATH (a path in $build format) was converted to $host +# format in TO_PATH. Otherwise, emit an error message, but continue, resetting +# func_to_host_file_result to a simplistic fallback value (see below). +func_convert_path_check () +{ + $opt_debug + if test -z "$4" && test -n "$3"; then + func_error "Could not determine the host path corresponding to" + func_error " \`$3'" + func_error "Continuing, but uninstalled executables may not work." + # Fallback. This is a deliberately simplistic "conversion" and + # should not be "improved". See libtool.info. + if test "x$1" != "x$2"; then + lt_replace_pathsep_chars="s|$1|$2|g" + func_to_host_path_result=`echo "$3" | + $SED -e "$lt_replace_pathsep_chars"` + else + func_to_host_path_result="$3" + fi + fi +} +# end func_convert_path_check + + +# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG +# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT +# and appending REPL if ORIG matches BACKPAT. +func_convert_path_front_back_pathsep () +{ + $opt_debug + case $4 in + $1 ) func_to_host_path_result="$3$func_to_host_path_result" + ;; + esac + case $4 in + $2 ) func_append func_to_host_path_result "$3" + ;; + esac +} +# end func_convert_path_front_back_pathsep + + +################################################## +# $build to $host FILE NAME CONVERSION FUNCTIONS # +################################################## +# invoked via `$to_host_file_cmd ARG' +# +# In each case, ARG is the path to be converted from $build to $host format. +# Result will be available in $func_to_host_file_result. + + +# func_to_host_file ARG +# Converts the file name ARG from $build format to $host format. Return result +# in func_to_host_file_result. +func_to_host_file () +{ + $opt_debug + $to_host_file_cmd "$1" +} +# end func_to_host_file + + +# func_to_tool_file ARG LAZY +# converts the file name ARG from $build format to toolchain format. Return +# result in func_to_tool_file_result. If the conversion in use is listed +# in (the comma separated) LAZY, no conversion takes place. +func_to_tool_file () +{ + $opt_debug + case ,$2, in + *,"$to_tool_file_cmd",*) + func_to_tool_file_result=$1 + ;; + *) + $to_tool_file_cmd "$1" + func_to_tool_file_result=$func_to_host_file_result + ;; + esac +} +# end func_to_tool_file + + +# func_convert_file_noop ARG +# Copy ARG to func_to_host_file_result. +func_convert_file_noop () +{ + func_to_host_file_result="$1" +} +# end func_convert_file_noop + + +# func_convert_file_msys_to_w32 ARG +# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic +# conversion to w32 is not available inside the cwrapper. Returns result in +# func_to_host_file_result. +func_convert_file_msys_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_msys_to_w32 "$1" + func_to_host_file_result="$func_convert_core_msys_to_w32_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_msys_to_w32 + + +# func_convert_file_cygwin_to_w32 ARG +# Convert file name ARG from Cygwin to w32 format. Returns result in +# func_to_host_file_result. +func_convert_file_cygwin_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + # because $build is cygwin, we call "the" cygpath in $PATH; no need to use + # LT_CYGPATH in this case. + func_to_host_file_result=`cygpath -m "$1"` + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_cygwin_to_w32 + + +# func_convert_file_nix_to_w32 ARG +# Convert file name ARG from *nix to w32 format. Requires a wine environment +# and a working winepath. Returns result in func_to_host_file_result. +func_convert_file_nix_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_file_wine_to_w32 "$1" + func_to_host_file_result="$func_convert_core_file_wine_to_w32_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_nix_to_w32 + + +# func_convert_file_msys_to_cygwin ARG +# Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. +# Returns result in func_to_host_file_result. +func_convert_file_msys_to_cygwin () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_msys_to_w32 "$1" + func_cygpath -u "$func_convert_core_msys_to_w32_result" + func_to_host_file_result="$func_cygpath_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_msys_to_cygwin + + +# func_convert_file_nix_to_cygwin ARG +# Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed +# in a wine environment, working winepath, and LT_CYGPATH set. Returns result +# in func_to_host_file_result. +func_convert_file_nix_to_cygwin () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. + func_convert_core_file_wine_to_w32 "$1" + func_cygpath -u "$func_convert_core_file_wine_to_w32_result" + func_to_host_file_result="$func_cygpath_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_nix_to_cygwin + + +############################################# +# $build to $host PATH CONVERSION FUNCTIONS # +############################################# +# invoked via `$to_host_path_cmd ARG' +# +# In each case, ARG is the path to be converted from $build to $host format. +# The result will be available in $func_to_host_path_result. +# +# Path separators are also converted from $build format to $host format. If +# ARG begins or ends with a path separator character, it is preserved (but +# converted to $host format) on output. +# +# All path conversion functions are named using the following convention: +# file name conversion function : func_convert_file_X_to_Y () +# path conversion function : func_convert_path_X_to_Y () +# where, for any given $build/$host combination the 'X_to_Y' value is the +# same. If conversion functions are added for new $build/$host combinations, +# the two new functions must follow this pattern, or func_init_to_host_path_cmd +# will break. + + +# func_init_to_host_path_cmd +# Ensures that function "pointer" variable $to_host_path_cmd is set to the +# appropriate value, based on the value of $to_host_file_cmd. +to_host_path_cmd= +func_init_to_host_path_cmd () +{ + $opt_debug + if test -z "$to_host_path_cmd"; then + func_stripname 'func_convert_file_' '' "$to_host_file_cmd" + to_host_path_cmd="func_convert_path_${func_stripname_result}" + fi +} + + +# func_to_host_path ARG +# Converts the path ARG from $build format to $host format. Return result +# in func_to_host_path_result. +func_to_host_path () +{ + $opt_debug + func_init_to_host_path_cmd + $to_host_path_cmd "$1" +} +# end func_to_host_path + + +# func_convert_path_noop ARG +# Copy ARG to func_to_host_path_result. +func_convert_path_noop () +{ + func_to_host_path_result="$1" +} +# end func_convert_path_noop + + +# func_convert_path_msys_to_w32 ARG +# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic +# conversion to w32 is not available inside the cwrapper. Returns result in +# func_to_host_path_result. +func_convert_path_msys_to_w32 () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # Remove leading and trailing path separator characters from ARG. MSYS + # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; + # and winepath ignores them completely. + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" + func_to_host_path_result="$func_convert_core_msys_to_w32_result" + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_msys_to_w32 + + +# func_convert_path_cygwin_to_w32 ARG +# Convert path ARG from Cygwin to w32 format. Returns result in +# func_to_host_file_result. +func_convert_path_cygwin_to_w32 () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_cygwin_to_w32 + + +# func_convert_path_nix_to_w32 ARG +# Convert path ARG from *nix to w32 format. Requires a wine environment and +# a working winepath. Returns result in func_to_host_file_result. +func_convert_path_nix_to_w32 () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" + func_to_host_path_result="$func_convert_core_path_wine_to_w32_result" + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_nix_to_w32 + + +# func_convert_path_msys_to_cygwin ARG +# Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. +# Returns result in func_to_host_file_result. +func_convert_path_msys_to_cygwin () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" + func_cygpath -u -p "$func_convert_core_msys_to_w32_result" + func_to_host_path_result="$func_cygpath_result" + func_convert_path_check : : \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" : "$1" + fi +} +# end func_convert_path_msys_to_cygwin + + +# func_convert_path_nix_to_cygwin ARG +# Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a +# a wine environment, working winepath, and LT_CYGPATH set. Returns result in +# func_to_host_file_result. +func_convert_path_nix_to_cygwin () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # Remove leading and trailing path separator characters from + # ARG. msys behavior is inconsistent here, cygpath turns them + # into '.;' and ';.', and winepath ignores them completely. + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" + func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" + func_to_host_path_result="$func_cygpath_result" + func_convert_path_check : : \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" : "$1" + fi +} +# end func_convert_path_nix_to_cygwin + + +# func_mode_compile arg... +func_mode_compile () +{ + $opt_debug + # Get the compilation command and the source file. + base_compile= + srcfile="$nonopt" # always keep a non-empty value in "srcfile" + suppress_opt=yes + suppress_output= + arg_mode=normal + libobj= + later= + pie_flag= + + for arg + do + case $arg_mode in + arg ) + # do not "continue". Instead, add this to base_compile + lastarg="$arg" + arg_mode=normal + ;; + + target ) + libobj="$arg" + arg_mode=normal + continue + ;; + + normal ) + # Accept any command-line options. + case $arg in + -o) + test -n "$libobj" && \ + func_fatal_error "you cannot specify \`-o' more than once" + arg_mode=target + continue + ;; + + -pie | -fpie | -fPIE) + func_append pie_flag " $arg" + continue + ;; + + -shared | -static | -prefer-pic | -prefer-non-pic) + func_append later " $arg" + continue + ;; + + -no-suppress) + suppress_opt=no + continue + ;; + + -Xcompiler) + arg_mode=arg # the next one goes into the "base_compile" arg list + continue # The current "srcfile" will either be retained or + ;; # replaced later. I would guess that would be a bug. + + -Wc,*) + func_stripname '-Wc,' '' "$arg" + args=$func_stripname_result + lastarg= + save_ifs="$IFS"; IFS=',' + for arg in $args; do + IFS="$save_ifs" + func_append_quoted lastarg "$arg" + done + IFS="$save_ifs" + func_stripname ' ' '' "$lastarg" + lastarg=$func_stripname_result + + # Add the arguments to base_compile. + func_append base_compile " $lastarg" + continue + ;; + + *) + # Accept the current argument as the source file. + # The previous "srcfile" becomes the current argument. + # + lastarg="$srcfile" + srcfile="$arg" + ;; + esac # case $arg + ;; + esac # case $arg_mode + + # Aesthetically quote the previous argument. + func_append_quoted base_compile "$lastarg" + done # for arg + + case $arg_mode in + arg) + func_fatal_error "you must specify an argument for -Xcompile" + ;; + target) + func_fatal_error "you must specify a target with \`-o'" + ;; + *) + # Get the name of the library object. + test -z "$libobj" && { + func_basename "$srcfile" + libobj="$func_basename_result" + } + ;; + esac + + # Recognize several different file suffixes. + # If the user specifies -o file.o, it is replaced with file.lo + case $libobj in + *.[cCFSifmso] | \ + *.ada | *.adb | *.ads | *.asm | \ + *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ + *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup) + func_xform "$libobj" + libobj=$func_xform_result + ;; + esac + + case $libobj in + *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; + *) + func_fatal_error "cannot determine name of library object from \`$libobj'" + ;; + esac + + func_infer_tag $base_compile + + for arg in $later; do + case $arg in + -shared) + test "$build_libtool_libs" != yes && \ + func_fatal_configuration "can not build a shared library" + build_old_libs=no + continue + ;; + + -static) + build_libtool_libs=no + build_old_libs=yes + continue + ;; + + -prefer-pic) + pic_mode=yes + continue + ;; + + -prefer-non-pic) + pic_mode=no + continue + ;; + esac + done + + func_quote_for_eval "$libobj" + test "X$libobj" != "X$func_quote_for_eval_result" \ + && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ + && func_warning "libobj name \`$libobj' may not contain shell special characters." + func_dirname_and_basename "$obj" "/" "" + objname="$func_basename_result" + xdir="$func_dirname_result" + lobj=${xdir}$objdir/$objname + + test -z "$base_compile" && \ + func_fatal_help "you must specify a compilation command" + + # Delete any leftover library objects. + if test "$build_old_libs" = yes; then + removelist="$obj $lobj $libobj ${libobj}T" + else + removelist="$lobj $libobj ${libobj}T" + fi + + # On Cygwin there's no "real" PIC flag so we must build both object types + case $host_os in + cygwin* | mingw* | pw32* | os2* | cegcc*) + pic_mode=default + ;; + esac + if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then + # non-PIC code in shared libraries is not supported + pic_mode=default + fi + + # Calculate the filename of the output object if compiler does + # not support -o with -c + if test "$compiler_c_o" = no; then + output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.${objext} + lockfile="$output_obj.lock" + else + output_obj= + need_locks=no + lockfile= + fi + + # Lock this critical section if it is needed + # We use this script file to make the link, it avoids creating a new file + if test "$need_locks" = yes; then + until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do + func_echo "Waiting for $lockfile to be removed" + sleep 2 + done + elif test "$need_locks" = warn; then + if test -f "$lockfile"; then + $ECHO "\ +*** ERROR, $lockfile exists and contains: +`cat $lockfile 2>/dev/null` + +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support \`-c' and \`-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." + + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE + fi + func_append removelist " $output_obj" + $ECHO "$srcfile" > "$lockfile" + fi + + $opt_dry_run || $RM $removelist + func_append removelist " $lockfile" + trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 + + func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 + srcfile=$func_to_tool_file_result + func_quote_for_eval "$srcfile" + qsrcfile=$func_quote_for_eval_result + + # Only build a PIC object if we are building libtool libraries. + if test "$build_libtool_libs" = yes; then + # Without this assignment, base_compile gets emptied. + fbsd_hideous_sh_bug=$base_compile + + if test "$pic_mode" != no; then + command="$base_compile $qsrcfile $pic_flag" + else + # Don't build PIC code + command="$base_compile $qsrcfile" + fi + + func_mkdir_p "$xdir$objdir" + + if test -z "$output_obj"; then + # Place PIC objects in $objdir + func_append command " -o $lobj" + fi + + func_show_eval_locale "$command" \ + 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' + + if test "$need_locks" = warn && + test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then + $ECHO "\ +*** ERROR, $lockfile contains: +`cat $lockfile 2>/dev/null` + +but it should contain: +$srcfile + +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support \`-c' and \`-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." + + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE + fi + + # Just move the object if needed, then go on to compile the next one + if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then + func_show_eval '$MV "$output_obj" "$lobj"' \ + 'error=$?; $opt_dry_run || $RM $removelist; exit $error' + fi + + # Allow error messages only from the first compilation. + if test "$suppress_opt" = yes; then + suppress_output=' >/dev/null 2>&1' + fi + fi + + # Only build a position-dependent object if we build old libraries. + if test "$build_old_libs" = yes; then + if test "$pic_mode" != yes; then + # Don't build PIC code + command="$base_compile $qsrcfile$pie_flag" + else + command="$base_compile $qsrcfile $pic_flag" + fi + if test "$compiler_c_o" = yes; then + func_append command " -o $obj" + fi + + # Suppress compiler output if we already did a PIC compilation. + func_append command "$suppress_output" + func_show_eval_locale "$command" \ + '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' + + if test "$need_locks" = warn && + test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then + $ECHO "\ +*** ERROR, $lockfile contains: +`cat $lockfile 2>/dev/null` + +but it should contain: +$srcfile + +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support \`-c' and \`-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." + + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE + fi + + # Just move the object if needed + if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then + func_show_eval '$MV "$output_obj" "$obj"' \ + 'error=$?; $opt_dry_run || $RM $removelist; exit $error' + fi + fi + + $opt_dry_run || { + func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" + + # Unlock the critical section if it was locked + if test "$need_locks" != no; then + removelist=$lockfile + $RM "$lockfile" + fi + } + + exit $EXIT_SUCCESS +} + +$opt_help || { + test "$opt_mode" = compile && func_mode_compile ${1+"$@"} +} + +func_mode_help () +{ + # We need to display help for each of the modes. + case $opt_mode in + "") + # Generic help is extracted from the usage comments + # at the start of this file. + func_help + ;; + + clean) + $ECHO \ +"Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE... + +Remove files from the build directory. + +RM is the name of the program to use to delete files associated with each FILE +(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed +to RM. + +If FILE is a libtool library, object or program, all the files associated +with it are deleted. Otherwise, only FILE itself is deleted using RM." + ;; + + compile) + $ECHO \ +"Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE + +Compile a source file into a libtool library object. + +This mode accepts the following additional options: + + -o OUTPUT-FILE set the output file name to OUTPUT-FILE + -no-suppress do not suppress compiler output for multiple passes + -prefer-pic try to build PIC objects only + -prefer-non-pic try to build non-PIC objects only + -shared do not build a \`.o' file suitable for static linking + -static only build a \`.o' file suitable for static linking + -Wc,FLAG pass FLAG directly to the compiler + +COMPILE-COMMAND is a command to be used in creating a \`standard' object file +from the given SOURCEFILE. + +The output file name is determined by removing the directory component from +SOURCEFILE, then substituting the C source code suffix \`.c' with the +library object suffix, \`.lo'." + ;; + + execute) + $ECHO \ +"Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]... + +Automatically set library path, then run a program. + +This mode accepts the following additional options: + + -dlopen FILE add the directory containing FILE to the library path + +This mode sets the library path environment variable according to \`-dlopen' +flags. + +If any of the ARGS are libtool executable wrappers, then they are translated +into their corresponding uninstalled binary, and any of their required library +directories are added to the library path. + +Then, COMMAND is executed, with ARGS as arguments." + ;; + + finish) + $ECHO \ +"Usage: $progname [OPTION]... --mode=finish [LIBDIR]... + +Complete the installation of libtool libraries. + +Each LIBDIR is a directory that contains libtool libraries. + +The commands that this mode executes may require superuser privileges. Use +the \`--dry-run' option if you just want to see what would be executed." + ;; + + install) + $ECHO \ +"Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... + +Install executables or libraries. + +INSTALL-COMMAND is the installation command. The first component should be +either the \`install' or \`cp' program. + +The following components of INSTALL-COMMAND are treated specially: + + -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation + +The rest of the components are interpreted as arguments to that command (only +BSD-compatible install options are recognized)." + ;; + + link) + $ECHO \ +"Usage: $progname [OPTION]... --mode=link LINK-COMMAND... + +Link object files or libraries together to form another library, or to +create an executable program. + +LINK-COMMAND is a command using the C compiler that you would use to create +a program from several object files. + +The following components of LINK-COMMAND are treated specially: + + -all-static do not do any dynamic linking at all + -avoid-version do not add a version suffix if possible + -bindir BINDIR specify path to binaries directory (for systems where + libraries must be found in the PATH setting at runtime) + -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime + -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols + -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) + -export-symbols SYMFILE + try to export only the symbols listed in SYMFILE + -export-symbols-regex REGEX + try to export only the symbols matching REGEX + -LLIBDIR search LIBDIR for required installed libraries + -lNAME OUTPUT-FILE requires the installed library libNAME + -module build a library that can dlopened + -no-fast-install disable the fast-install mode + -no-install link a not-installable executable + -no-undefined declare that a library does not refer to external symbols + -o OUTPUT-FILE create OUTPUT-FILE from the specified objects + -objectlist FILE Use a list of object files found in FILE to specify objects + -precious-files-regex REGEX + don't remove output files matching REGEX + -release RELEASE specify package release information + -rpath LIBDIR the created library will eventually be installed in LIBDIR + -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries + -shared only do dynamic linking of libtool libraries + -shrext SUFFIX override the standard shared library file extension + -static do not do any dynamic linking of uninstalled libtool libraries + -static-libtool-libs + do not do any dynamic linking of libtool libraries + -version-info CURRENT[:REVISION[:AGE]] + specify library version info [each variable defaults to 0] + -weak LIBNAME declare that the target provides the LIBNAME interface + -Wc,FLAG + -Xcompiler FLAG pass linker-specific FLAG directly to the compiler + -Wl,FLAG + -Xlinker FLAG pass linker-specific FLAG directly to the linker + -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) + +All other options (arguments beginning with \`-') are ignored. + +Every other argument is treated as a filename. Files ending in \`.la' are +treated as uninstalled libtool libraries, other files are standard or library +object files. + +If the OUTPUT-FILE ends in \`.la', then a libtool library is created, +only library objects (\`.lo' files) may be specified, and \`-rpath' is +required, except when creating a convenience library. + +If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created +using \`ar' and \`ranlib', or on Windows using \`lib'. + +If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file +is created, otherwise an executable program is created." + ;; + + uninstall) + $ECHO \ +"Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... + +Remove libraries from an installation directory. + +RM is the name of the program to use to delete files associated with each FILE +(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed +to RM. + +If FILE is a libtool library, all the files associated with it are deleted. +Otherwise, only FILE itself is deleted using RM." + ;; + + *) + func_fatal_help "invalid operation mode \`$opt_mode'" + ;; + esac + + echo + $ECHO "Try \`$progname --help' for more information about other modes." +} + +# Now that we've collected a possible --mode arg, show help if necessary +if $opt_help; then + if test "$opt_help" = :; then + func_mode_help + else + { + func_help noexit + for opt_mode in compile link execute install finish uninstall clean; do + func_mode_help + done + } | sed -n '1p; 2,$s/^Usage:/ or: /p' + { + func_help noexit + for opt_mode in compile link execute install finish uninstall clean; do + echo + func_mode_help + done + } | + sed '1d + /^When reporting/,/^Report/{ + H + d + } + $x + /information about other modes/d + /more detailed .*MODE/d + s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' + fi + exit $? +fi + + +# func_mode_execute arg... +func_mode_execute () +{ + $opt_debug + # The first argument is the command name. + cmd="$nonopt" + test -z "$cmd" && \ + func_fatal_help "you must specify a COMMAND" + + # Handle -dlopen flags immediately. + for file in $opt_dlopen; do + test -f "$file" \ + || func_fatal_help "\`$file' is not a file" + + dir= + case $file in + *.la) + func_resolve_sysroot "$file" + file=$func_resolve_sysroot_result + + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$file" \ + || func_fatal_help "\`$lib' is not a valid libtool archive" + + # Read the libtool library. + dlname= + library_names= + func_source "$file" + + # Skip this library if it cannot be dlopened. + if test -z "$dlname"; then + # Warn if it was a shared library. + test -n "$library_names" && \ + func_warning "\`$file' was not linked with \`-export-dynamic'" + continue + fi + + func_dirname "$file" "" "." + dir="$func_dirname_result" + + if test -f "$dir/$objdir/$dlname"; then + func_append dir "/$objdir" + else + if test ! -f "$dir/$dlname"; then + func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" + fi + fi + ;; + + *.lo) + # Just add the directory containing the .lo file. + func_dirname "$file" "" "." + dir="$func_dirname_result" + ;; + + *) + func_warning "\`-dlopen' is ignored for non-libtool libraries and objects" + continue + ;; + esac + + # Get the absolute pathname. + absdir=`cd "$dir" && pwd` + test -n "$absdir" && dir="$absdir" + + # Now add the directory to shlibpath_var. + if eval "test -z \"\$$shlibpath_var\""; then + eval "$shlibpath_var=\"\$dir\"" + else + eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" + fi + done + + # This variable tells wrapper scripts just to set shlibpath_var + # rather than running their programs. + libtool_execute_magic="$magic" + + # Check if any of the arguments is a wrapper script. + args= + for file + do + case $file in + -* | *.la | *.lo ) ;; + *) + # Do a test to see if this is really a libtool program. + if func_ltwrapper_script_p "$file"; then + func_source "$file" + # Transform arg to wrapped name. + file="$progdir/$program" + elif func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + func_source "$func_ltwrapper_scriptname_result" + # Transform arg to wrapped name. + file="$progdir/$program" + fi + ;; + esac + # Quote arguments (to preserve shell metacharacters). + func_append_quoted args "$file" + done + + if test "X$opt_dry_run" = Xfalse; then + if test -n "$shlibpath_var"; then + # Export the shlibpath_var. + eval "export $shlibpath_var" + fi + + # Restore saved environment variables + for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES + do + eval "if test \"\${save_$lt_var+set}\" = set; then + $lt_var=\$save_$lt_var; export $lt_var + else + $lt_unset $lt_var + fi" + done + + # Now prepare to actually exec the command. + exec_cmd="\$cmd$args" + else + # Display what would be done. + if test -n "$shlibpath_var"; then + eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" + echo "export $shlibpath_var" + fi + $ECHO "$cmd$args" + exit $EXIT_SUCCESS + fi +} + +test "$opt_mode" = execute && func_mode_execute ${1+"$@"} + + +# func_mode_finish arg... +func_mode_finish () +{ + $opt_debug + libs= + libdirs= + admincmds= + + for opt in "$nonopt" ${1+"$@"} + do + if test -d "$opt"; then + func_append libdirs " $opt" + + elif test -f "$opt"; then + if func_lalib_unsafe_p "$opt"; then + func_append libs " $opt" + else + func_warning "\`$opt' is not a valid libtool archive" + fi + + else + func_fatal_error "invalid argument \`$opt'" + fi + done + + if test -n "$libs"; then + if test -n "$lt_sysroot"; then + sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` + sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" + else + sysroot_cmd= + fi + + # Remove sysroot references + if $opt_dry_run; then + for lib in $libs; do + echo "removing references to $lt_sysroot and \`=' prefixes from $lib" + done + else + tmpdir=`func_mktempdir` + for lib in $libs; do + sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ + > $tmpdir/tmp-la + mv -f $tmpdir/tmp-la $lib + done + ${RM}r "$tmpdir" + fi + fi + + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then + for libdir in $libdirs; do + if test -n "$finish_cmds"; then + # Do each command in the finish commands. + func_execute_cmds "$finish_cmds" 'admincmds="$admincmds +'"$cmd"'"' + fi + if test -n "$finish_eval"; then + # Do the single finish_eval. + eval cmds=\"$finish_eval\" + $opt_dry_run || eval "$cmds" || func_append admincmds " + $cmds" + fi + done + fi + + # Exit here if they wanted silent mode. + $opt_silent && exit $EXIT_SUCCESS + + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then + echo "----------------------------------------------------------------------" + echo "Libraries have been installed in:" + for libdir in $libdirs; do + $ECHO " $libdir" + done + echo + echo "If you ever happen to want to link against installed libraries" + echo "in a given directory, LIBDIR, you must either use libtool, and" + echo "specify the full pathname of the library, or use the \`-LLIBDIR'" + echo "flag during linking and do at least one of the following:" + if test -n "$shlibpath_var"; then + echo " - add LIBDIR to the \`$shlibpath_var' environment variable" + echo " during execution" + fi + if test -n "$runpath_var"; then + echo " - add LIBDIR to the \`$runpath_var' environment variable" + echo " during linking" + fi + if test -n "$hardcode_libdir_flag_spec"; then + libdir=LIBDIR + eval flag=\"$hardcode_libdir_flag_spec\" + + $ECHO " - use the \`$flag' linker flag" + fi + if test -n "$admincmds"; then + $ECHO " - have your system administrator run these commands:$admincmds" + fi + if test -f /etc/ld.so.conf; then + echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" + fi + echo + + echo "See any operating system documentation about shared libraries for" + case $host in + solaris2.[6789]|solaris2.1[0-9]) + echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" + echo "pages." + ;; + *) + echo "more information, such as the ld(1) and ld.so(8) manual pages." + ;; + esac + echo "----------------------------------------------------------------------" + fi + exit $EXIT_SUCCESS +} + +test "$opt_mode" = finish && func_mode_finish ${1+"$@"} + + +# func_mode_install arg... +func_mode_install () +{ + $opt_debug + # There may be an optional sh(1) argument at the beginning of + # install_prog (especially on Windows NT). + if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || + # Allow the use of GNU shtool's install command. + case $nonopt in *shtool*) :;; *) false;; esac; then + # Aesthetically quote it. + func_quote_for_eval "$nonopt" + install_prog="$func_quote_for_eval_result " + arg=$1 + shift + else + install_prog= + arg=$nonopt + fi + + # The real first argument should be the name of the installation program. + # Aesthetically quote it. + func_quote_for_eval "$arg" + func_append install_prog "$func_quote_for_eval_result" + install_shared_prog=$install_prog + case " $install_prog " in + *[\\\ /]cp\ *) install_cp=: ;; + *) install_cp=false ;; + esac + + # We need to accept at least all the BSD install flags. + dest= + files= + opts= + prev= + install_type= + isdir=no + stripme= + no_mode=: + for arg + do + arg2= + if test -n "$dest"; then + func_append files " $dest" + dest=$arg + continue + fi + + case $arg in + -d) isdir=yes ;; + -f) + if $install_cp; then :; else + prev=$arg + fi + ;; + -g | -m | -o) + prev=$arg + ;; + -s) + stripme=" -s" + continue + ;; + -*) + ;; + *) + # If the previous option needed an argument, then skip it. + if test -n "$prev"; then + if test "x$prev" = x-m && test -n "$install_override_mode"; then + arg2=$install_override_mode + no_mode=false + fi + prev= + else + dest=$arg + continue + fi + ;; + esac + + # Aesthetically quote the argument. + func_quote_for_eval "$arg" + func_append install_prog " $func_quote_for_eval_result" + if test -n "$arg2"; then + func_quote_for_eval "$arg2" + fi + func_append install_shared_prog " $func_quote_for_eval_result" + done + + test -z "$install_prog" && \ + func_fatal_help "you must specify an install program" + + test -n "$prev" && \ + func_fatal_help "the \`$prev' option requires an argument" + + if test -n "$install_override_mode" && $no_mode; then + if $install_cp; then :; else + func_quote_for_eval "$install_override_mode" + func_append install_shared_prog " -m $func_quote_for_eval_result" + fi + fi + + if test -z "$files"; then + if test -z "$dest"; then + func_fatal_help "no file or destination specified" + else + func_fatal_help "you must specify a destination" + fi + fi + + # Strip any trailing slash from the destination. + func_stripname '' '/' "$dest" + dest=$func_stripname_result + + # Check to see that the destination is a directory. + test -d "$dest" && isdir=yes + if test "$isdir" = yes; then + destdir="$dest" + destname= + else + func_dirname_and_basename "$dest" "" "." + destdir="$func_dirname_result" + destname="$func_basename_result" + + # Not a directory, so check to see that there is only one file specified. + set dummy $files; shift + test "$#" -gt 1 && \ + func_fatal_help "\`$dest' is not a directory" + fi + case $destdir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + for file in $files; do + case $file in + *.lo) ;; + *) + func_fatal_help "\`$destdir' must be an absolute directory name" + ;; + esac + done + ;; + esac + + # This variable tells wrapper scripts just to set variables rather + # than running their programs. + libtool_install_magic="$magic" + + staticlibs= + future_libdirs= + current_libdirs= + for file in $files; do + + # Do each installation. + case $file in + *.$libext) + # Do the static libraries later. + func_append staticlibs " $file" + ;; + + *.la) + func_resolve_sysroot "$file" + file=$func_resolve_sysroot_result + + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$file" \ + || func_fatal_help "\`$file' is not a valid libtool archive" + + library_names= + old_library= + relink_command= + func_source "$file" + + # Add the libdir to current_libdirs if it is the destination. + if test "X$destdir" = "X$libdir"; then + case "$current_libdirs " in + *" $libdir "*) ;; + *) func_append current_libdirs " $libdir" ;; + esac + else + # Note the libdir as a future libdir. + case "$future_libdirs " in + *" $libdir "*) ;; + *) func_append future_libdirs " $libdir" ;; + esac + fi + + func_dirname "$file" "/" "" + dir="$func_dirname_result" + func_append dir "$objdir" + + if test -n "$relink_command"; then + # Determine the prefix the user has applied to our future dir. + inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` + + # Don't allow the user to place us outside of our expected + # location b/c this prevents finding dependent libraries that + # are installed to the same prefix. + # At present, this check doesn't affect windows .dll's that + # are installed into $libdir/../bin (currently, that works fine) + # but it's something to keep an eye on. + test "$inst_prefix_dir" = "$destdir" && \ + func_fatal_error "error: cannot install \`$file' to a directory not ending in $libdir" + + if test -n "$inst_prefix_dir"; then + # Stick the inst_prefix_dir data into the link command. + relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` + else + relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` + fi + + func_warning "relinking \`$file'" + func_show_eval "$relink_command" \ + 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"' + fi + + # See the names of the shared library. + set dummy $library_names; shift + if test -n "$1"; then + realname="$1" + shift + + srcname="$realname" + test -n "$relink_command" && srcname="$realname"T + + # Install the shared library and build the symlinks. + func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ + 'exit $?' + tstripme="$stripme" + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + case $realname in + *.dll.a) + tstripme="" + ;; + esac + ;; + esac + if test -n "$tstripme" && test -n "$striplib"; then + func_show_eval "$striplib $destdir/$realname" 'exit $?' + fi + + if test "$#" -gt 0; then + # Delete the old symlinks, and create new ones. + # Try `ln -sf' first, because the `ln' binary might depend on + # the symlink we replace! Solaris /bin/ln does not understand -f, + # so we also need to try rm && ln -s. + for linkname + do + test "$linkname" != "$realname" \ + && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" + done + fi + + # Do each command in the postinstall commands. + lib="$destdir/$realname" + func_execute_cmds "$postinstall_cmds" 'exit $?' + fi + + # Install the pseudo-library for information purposes. + func_basename "$file" + name="$func_basename_result" + instname="$dir/$name"i + func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' + + # Maybe install the static library, too. + test -n "$old_library" && func_append staticlibs " $dir/$old_library" + ;; + + *.lo) + # Install (i.e. copy) a libtool object. + + # Figure out destination file name, if it wasn't already specified. + if test -n "$destname"; then + destfile="$destdir/$destname" + else + func_basename "$file" + destfile="$func_basename_result" + destfile="$destdir/$destfile" + fi + + # Deduce the name of the destination old-style object file. + case $destfile in + *.lo) + func_lo2o "$destfile" + staticdest=$func_lo2o_result + ;; + *.$objext) + staticdest="$destfile" + destfile= + ;; + *) + func_fatal_help "cannot copy a libtool object to \`$destfile'" + ;; + esac + + # Install the libtool object if requested. + test -n "$destfile" && \ + func_show_eval "$install_prog $file $destfile" 'exit $?' + + # Install the old object if enabled. + if test "$build_old_libs" = yes; then + # Deduce the name of the old-style object file. + func_lo2o "$file" + staticobj=$func_lo2o_result + func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' + fi + exit $EXIT_SUCCESS + ;; + + *) + # Figure out destination file name, if it wasn't already specified. + if test -n "$destname"; then + destfile="$destdir/$destname" + else + func_basename "$file" + destfile="$func_basename_result" + destfile="$destdir/$destfile" + fi + + # If the file is missing, and there is a .exe on the end, strip it + # because it is most likely a libtool script we actually want to + # install + stripped_ext="" + case $file in + *.exe) + if test ! -f "$file"; then + func_stripname '' '.exe' "$file" + file=$func_stripname_result + stripped_ext=".exe" + fi + ;; + esac + + # Do a test to see if this is really a libtool program. + case $host in + *cygwin* | *mingw*) + if func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + wrapper=$func_ltwrapper_scriptname_result + else + func_stripname '' '.exe' "$file" + wrapper=$func_stripname_result + fi + ;; + *) + wrapper=$file + ;; + esac + if func_ltwrapper_script_p "$wrapper"; then + notinst_deplibs= + relink_command= + + func_source "$wrapper" + + # Check the variables that should have been set. + test -z "$generated_by_libtool_version" && \ + func_fatal_error "invalid libtool wrapper script \`$wrapper'" + + finalize=yes + for lib in $notinst_deplibs; do + # Check to see that each library is installed. + libdir= + if test -f "$lib"; then + func_source "$lib" + fi + libfile="$libdir/"`$ECHO "$lib" | $SED 's%^.*/%%g'` ### testsuite: skip nested quoting test + if test -n "$libdir" && test ! -f "$libfile"; then + func_warning "\`$lib' has not been installed in \`$libdir'" + finalize=no + fi + done + + relink_command= + func_source "$wrapper" + + outputname= + if test "$fast_install" = no && test -n "$relink_command"; then + $opt_dry_run || { + if test "$finalize" = yes; then + tmpdir=`func_mktempdir` + func_basename "$file$stripped_ext" + file="$func_basename_result" + outputname="$tmpdir/$file" + # Replace the output file specification. + relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` + + $opt_silent || { + func_quote_for_expand "$relink_command" + eval "func_echo $func_quote_for_expand_result" + } + if eval "$relink_command"; then : + else + func_error "error: relink \`$file' with the above command before installing it" + $opt_dry_run || ${RM}r "$tmpdir" + continue + fi + file="$outputname" + else + func_warning "cannot relink \`$file'" + fi + } + else + # Install the binary that we compiled earlier. + file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` + fi + fi + + # remove .exe since cygwin /usr/bin/install will append another + # one anyway + case $install_prog,$host in + */usr/bin/install*,*cygwin*) + case $file:$destfile in + *.exe:*.exe) + # this is ok + ;; + *.exe:*) + destfile=$destfile.exe + ;; + *:*.exe) + func_stripname '' '.exe' "$destfile" + destfile=$func_stripname_result + ;; + esac + ;; + esac + func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' + $opt_dry_run || if test -n "$outputname"; then + ${RM}r "$tmpdir" + fi + ;; + esac + done + + for file in $staticlibs; do + func_basename "$file" + name="$func_basename_result" + + # Set up the ranlib parameters. + oldlib="$destdir/$name" + func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 + tool_oldlib=$func_to_tool_file_result + + func_show_eval "$install_prog \$file \$oldlib" 'exit $?' + + if test -n "$stripme" && test -n "$old_striplib"; then + func_show_eval "$old_striplib $tool_oldlib" 'exit $?' + fi + + # Do each command in the postinstall commands. + func_execute_cmds "$old_postinstall_cmds" 'exit $?' + done + + test -n "$future_libdirs" && \ + func_warning "remember to run \`$progname --finish$future_libdirs'" + + if test -n "$current_libdirs"; then + # Maybe just do a dry run. + $opt_dry_run && current_libdirs=" -n$current_libdirs" + exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' + else + exit $EXIT_SUCCESS + fi +} + +test "$opt_mode" = install && func_mode_install ${1+"$@"} + + +# func_generate_dlsyms outputname originator pic_p +# Extract symbols from dlprefiles and create ${outputname}S.o with +# a dlpreopen symbol table. +func_generate_dlsyms () +{ + $opt_debug + my_outputname="$1" + my_originator="$2" + my_pic_p="${3-no}" + my_prefix=`$ECHO "$my_originator" | sed 's%[^a-zA-Z0-9]%_%g'` + my_dlsyms= + + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + if test -n "$NM" && test -n "$global_symbol_pipe"; then + my_dlsyms="${my_outputname}S.c" + else + func_error "not configured to extract global symbols from dlpreopened files" + fi + fi + + if test -n "$my_dlsyms"; then + case $my_dlsyms in + "") ;; + *.c) + # Discover the nlist of each of the dlfiles. + nlist="$output_objdir/${my_outputname}.nm" + + func_show_eval "$RM $nlist ${nlist}S ${nlist}T" + + # Parse the name list into a source file. + func_verbose "creating $output_objdir/$my_dlsyms" + + $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ +/* $my_dlsyms - symbol resolution table for \`$my_outputname' dlsym emulation. */ +/* Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION */ + +#ifdef __cplusplus +extern \"C\" { +#endif + +#if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) +#pragma GCC diagnostic ignored \"-Wstrict-prototypes\" +#endif + +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif + +/* External symbol declarations for the compiler. */\ +" + + if test "$dlself" = yes; then + func_verbose "generating symbol list for \`$output'" + + $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" + + # Add our own program objects to the symbol list. + progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` + for progfile in $progfiles; do + func_to_tool_file "$progfile" func_convert_file_msys_to_w32 + func_verbose "extracting global C symbols from \`$func_to_tool_file_result'" + $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" + done + + if test -n "$exclude_expsyms"; then + $opt_dry_run || { + eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + } + fi + + if test -n "$export_symbols_regex"; then + $opt_dry_run || { + eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + } + fi + + # Prepare the list of exported symbols + if test -z "$export_symbols"; then + export_symbols="$output_objdir/$outputname.exp" + $opt_dry_run || { + $RM $export_symbols + eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' + case $host in + *cygwin* | *mingw* | *cegcc* ) + eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' + eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' + ;; + esac + } + else + $opt_dry_run || { + eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' + eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + case $host in + *cygwin* | *mingw* | *cegcc* ) + eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' + eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' + ;; + esac + } + fi + fi + + for dlprefile in $dlprefiles; do + func_verbose "extracting global C symbols from \`$dlprefile'" + func_basename "$dlprefile" + name="$func_basename_result" + case $host in + *cygwin* | *mingw* | *cegcc* ) + # if an import library, we need to obtain dlname + if func_win32_import_lib_p "$dlprefile"; then + func_tr_sh "$dlprefile" + eval "curr_lafile=\$libfile_$func_tr_sh_result" + dlprefile_dlbasename="" + if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then + # Use subshell, to avoid clobbering current variable values + dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` + if test -n "$dlprefile_dlname" ; then + func_basename "$dlprefile_dlname" + dlprefile_dlbasename="$func_basename_result" + else + # no lafile. user explicitly requested -dlpreopen <import library>. + $sharedlib_from_linklib_cmd "$dlprefile" + dlprefile_dlbasename=$sharedlib_from_linklib_result + fi + fi + $opt_dry_run || { + if test -n "$dlprefile_dlbasename" ; then + eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' + else + func_warning "Could not compute DLL name from $name" + eval '$ECHO ": $name " >> "$nlist"' + fi + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | + $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" + } + else # not an import lib + $opt_dry_run || { + eval '$ECHO ": $name " >> "$nlist"' + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" + } + fi + ;; + *) + $opt_dry_run || { + eval '$ECHO ": $name " >> "$nlist"' + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" + } + ;; + esac + done + + $opt_dry_run || { + # Make sure we have at least an empty file. + test -f "$nlist" || : > "$nlist" + + if test -n "$exclude_expsyms"; then + $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T + $MV "$nlist"T "$nlist" + fi + + # Try sorting and uniquifying the output. + if $GREP -v "^: " < "$nlist" | + if sort -k 3 </dev/null >/dev/null 2>&1; then + sort -k 3 + else + sort +2 + fi | + uniq > "$nlist"S; then + : + else + $GREP -v "^: " < "$nlist" > "$nlist"S + fi + + if test -f "$nlist"S; then + eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' + else + echo '/* NONE */' >> "$output_objdir/$my_dlsyms" + fi + + echo >> "$output_objdir/$my_dlsyms" "\ + +/* The mapping between symbol names and symbols. */ +typedef struct { + const char *name; + void *address; +} lt_dlsymlist; +extern LT_DLSYM_CONST lt_dlsymlist +lt_${my_prefix}_LTX_preloaded_symbols[]; +LT_DLSYM_CONST lt_dlsymlist +lt_${my_prefix}_LTX_preloaded_symbols[] = +{\ + { \"$my_originator\", (void *) 0 }," + + case $need_lib_prefix in + no) + eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" + ;; + *) + eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" + ;; + esac + echo >> "$output_objdir/$my_dlsyms" "\ + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt_${my_prefix}_LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif\ +" + } # !$opt_dry_run + + pic_flag_for_symtable= + case "$compile_command " in + *" -static "*) ;; + *) + case $host in + # compiling the symbol table file with pic_flag works around + # a FreeBSD bug that causes programs to crash when -lm is + # linked before any other PIC object. But we must not use + # pic_flag when linking with -static. The problem exists in + # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. + *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) + pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; + *-*-hpux*) + pic_flag_for_symtable=" $pic_flag" ;; + *) + if test "X$my_pic_p" != Xno; then + pic_flag_for_symtable=" $pic_flag" + fi + ;; + esac + ;; + esac + symtab_cflags= + for arg in $LTCFLAGS; do + case $arg in + -pie | -fpie | -fPIE) ;; + *) func_append symtab_cflags " $arg" ;; + esac + done + + # Now compile the dynamic symbol file. + func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' + + # Clean up the generated files. + func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T"' + + # Transform the symbol file into the correct name. + symfileobj="$output_objdir/${my_outputname}S.$objext" + case $host in + *cygwin* | *mingw* | *cegcc* ) + if test -f "$output_objdir/$my_outputname.def"; then + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` + else + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` + fi + ;; + *) + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` + ;; + esac + ;; + *) + func_fatal_error "unknown suffix for \`$my_dlsyms'" + ;; + esac + else + # We keep going just in case the user didn't refer to + # lt_preloaded_symbols. The linker will fail if global_symbol_pipe + # really was required. + + # Nullify the symbol file. + compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` + fi +} + +# func_win32_libid arg +# return the library type of file 'arg' +# +# Need a lot of goo to handle *both* DLLs and import libs +# Has to be a shell function in order to 'eat' the argument +# that is supplied when $file_magic_command is called. +# Despite the name, also deal with 64 bit binaries. +func_win32_libid () +{ + $opt_debug + win32_libid_type="unknown" + win32_fileres=`file -L $1 2>/dev/null` + case $win32_fileres in + *ar\ archive\ import\ library*) # definitely import + win32_libid_type="x86 archive import" + ;; + *ar\ archive*) # could be an import, or static + # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. + if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | + $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then + func_to_tool_file "$1" func_convert_file_msys_to_w32 + win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | + $SED -n -e ' + 1,100{ + / I /{ + s,.*,import, + p + q + } + }'` + case $win32_nmres in + import*) win32_libid_type="x86 archive import";; + *) win32_libid_type="x86 archive static";; + esac + fi + ;; + *DLL*) + win32_libid_type="x86 DLL" + ;; + *executable*) # but shell scripts are "executable" too... + case $win32_fileres in + *MS\ Windows\ PE\ Intel*) + win32_libid_type="x86 DLL" + ;; + esac + ;; + esac + $ECHO "$win32_libid_type" +} + +# func_cygming_dll_for_implib ARG +# +# Platform-specific function to extract the +# name of the DLL associated with the specified +# import library ARG. +# Invoked by eval'ing the libtool variable +# $sharedlib_from_linklib_cmd +# Result is available in the variable +# $sharedlib_from_linklib_result +func_cygming_dll_for_implib () +{ + $opt_debug + sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` +} + +# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs +# +# The is the core of a fallback implementation of a +# platform-specific function to extract the name of the +# DLL associated with the specified import library LIBNAME. +# +# SECTION_NAME is either .idata$6 or .idata$7, depending +# on the platform and compiler that created the implib. +# +# Echos the name of the DLL associated with the +# specified import library. +func_cygming_dll_for_implib_fallback_core () +{ + $opt_debug + match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` + $OBJDUMP -s --section "$1" "$2" 2>/dev/null | + $SED '/^Contents of section '"$match_literal"':/{ + # Place marker at beginning of archive member dllname section + s/.*/====MARK====/ + p + d + } + # These lines can sometimes be longer than 43 characters, but + # are always uninteresting + /:[ ]*file format pe[i]\{,1\}-/d + /^In archive [^:]*:/d + # Ensure marker is printed + /^====MARK====/p + # Remove all lines with less than 43 characters + /^.\{43\}/!d + # From remaining lines, remove first 43 characters + s/^.\{43\}//' | + $SED -n ' + # Join marker and all lines until next marker into a single line + /^====MARK====/ b para + H + $ b para + b + :para + x + s/\n//g + # Remove the marker + s/^====MARK====// + # Remove trailing dots and whitespace + s/[\. \t]*$// + # Print + /./p' | + # we now have a list, one entry per line, of the stringified + # contents of the appropriate section of all members of the + # archive which possess that section. Heuristic: eliminate + # all those which have a first or second character that is + # a '.' (that is, objdump's representation of an unprintable + # character.) This should work for all archives with less than + # 0x302f exports -- but will fail for DLLs whose name actually + # begins with a literal '.' or a single character followed by + # a '.'. + # + # Of those that remain, print the first one. + $SED -e '/^\./d;/^.\./d;q' +} + +# func_cygming_gnu_implib_p ARG +# This predicate returns with zero status (TRUE) if +# ARG is a GNU/binutils-style import library. Returns +# with nonzero status (FALSE) otherwise. +func_cygming_gnu_implib_p () +{ + $opt_debug + func_to_tool_file "$1" func_convert_file_msys_to_w32 + func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'` + test -n "$func_cygming_gnu_implib_tmp" +} + +# func_cygming_ms_implib_p ARG +# This predicate returns with zero status (TRUE) if +# ARG is an MS-style import library. Returns +# with nonzero status (FALSE) otherwise. +func_cygming_ms_implib_p () +{ + $opt_debug + func_to_tool_file "$1" func_convert_file_msys_to_w32 + func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` + test -n "$func_cygming_ms_implib_tmp" +} + +# func_cygming_dll_for_implib_fallback ARG +# Platform-specific function to extract the +# name of the DLL associated with the specified +# import library ARG. +# +# This fallback implementation is for use when $DLLTOOL +# does not support the --identify-strict option. +# Invoked by eval'ing the libtool variable +# $sharedlib_from_linklib_cmd +# Result is available in the variable +# $sharedlib_from_linklib_result +func_cygming_dll_for_implib_fallback () +{ + $opt_debug + if func_cygming_gnu_implib_p "$1" ; then + # binutils import library + sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` + elif func_cygming_ms_implib_p "$1" ; then + # ms-generated import library + sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` + else + # unknown + sharedlib_from_linklib_result="" + fi +} + + +# func_extract_an_archive dir oldlib +func_extract_an_archive () +{ + $opt_debug + f_ex_an_ar_dir="$1"; shift + f_ex_an_ar_oldlib="$1" + if test "$lock_old_archive_extraction" = yes; then + lockfile=$f_ex_an_ar_oldlib.lock + until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do + func_echo "Waiting for $lockfile to be removed" + sleep 2 + done + fi + func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ + 'stat=$?; rm -f "$lockfile"; exit $stat' + if test "$lock_old_archive_extraction" = yes; then + $opt_dry_run || rm -f "$lockfile" + fi + if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then + : + else + func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" + fi +} + + +# func_extract_archives gentop oldlib ... +func_extract_archives () +{ + $opt_debug + my_gentop="$1"; shift + my_oldlibs=${1+"$@"} + my_oldobjs="" + my_xlib="" + my_xabs="" + my_xdir="" + + for my_xlib in $my_oldlibs; do + # Extract the objects. + case $my_xlib in + [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; + *) my_xabs=`pwd`"/$my_xlib" ;; + esac + func_basename "$my_xlib" + my_xlib="$func_basename_result" + my_xlib_u=$my_xlib + while :; do + case " $extracted_archives " in + *" $my_xlib_u "*) + func_arith $extracted_serial + 1 + extracted_serial=$func_arith_result + my_xlib_u=lt$extracted_serial-$my_xlib ;; + *) break ;; + esac + done + extracted_archives="$extracted_archives $my_xlib_u" + my_xdir="$my_gentop/$my_xlib_u" + + func_mkdir_p "$my_xdir" + + case $host in + *-darwin*) + func_verbose "Extracting $my_xabs" + # Do not bother doing anything if just a dry run + $opt_dry_run || { + darwin_orig_dir=`pwd` + cd $my_xdir || exit $? + darwin_archive=$my_xabs + darwin_curdir=`pwd` + darwin_base_archive=`basename "$darwin_archive"` + darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` + if test -n "$darwin_arches"; then + darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` + darwin_arch= + func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" + for darwin_arch in $darwin_arches ; do + func_mkdir_p "unfat-$$/${darwin_base_archive}-${darwin_arch}" + $LIPO -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" + cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" + func_extract_an_archive "`pwd`" "${darwin_base_archive}" + cd "$darwin_curdir" + $RM "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" + done # $darwin_arches + ## Okay now we've a bunch of thin objects, gotta fatten them up :) + darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$basename" | sort -u` + darwin_file= + darwin_files= + for darwin_file in $darwin_filelist; do + darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` + $LIPO -create -output "$darwin_file" $darwin_files + done # $darwin_filelist + $RM -rf unfat-$$ + cd "$darwin_orig_dir" + else + cd $darwin_orig_dir + func_extract_an_archive "$my_xdir" "$my_xabs" + fi # $darwin_arches + } # !$opt_dry_run + ;; + *) + func_extract_an_archive "$my_xdir" "$my_xabs" + ;; + esac + my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` + done + + func_extract_archives_result="$my_oldobjs" +} + + +# func_emit_wrapper [arg=no] +# +# Emit a libtool wrapper script on stdout. +# Don't directly open a file because we may want to +# incorporate the script contents within a cygwin/mingw +# wrapper executable. Must ONLY be called from within +# func_mode_link because it depends on a number of variables +# set therein. +# +# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR +# variable will take. If 'yes', then the emitted script +# will assume that the directory in which it is stored is +# the $objdir directory. This is a cygwin/mingw-specific +# behavior. +func_emit_wrapper () +{ + func_emit_wrapper_arg1=${1-no} + + $ECHO "\ +#! $SHELL + +# $output - temporary wrapper script for $objdir/$outputname +# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION +# +# The $output program cannot be directly executed until all the libtool +# libraries that it depends on are installed. +# +# This wrapper script should never be moved out of the build directory. +# If it is, it will not operate correctly. + +# Sed substitution that helps us do robust quoting. It backslashifies +# metacharacters that are still active within double-quoted strings. +sed_quote_subst='$sed_quote_subst' + +# Be Bourne compatible +if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: + # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which + # is contrary to our usage. Disable this feature. + alias -g '\${1+\"\$@\"}'='\"\$@\"' + setopt NO_GLOB_SUBST +else + case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac +fi +BIN_SH=xpg4; export BIN_SH # for Tru64 +DUALCASE=1; export DUALCASE # for MKS sh + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +relink_command=\"$relink_command\" + +# This environment variable determines our operation mode. +if test \"\$libtool_install_magic\" = \"$magic\"; then + # install mode needs the following variables: + generated_by_libtool_version='$macro_version' + notinst_deplibs='$notinst_deplibs' +else + # When we are sourced in execute mode, \$file and \$ECHO are already set. + if test \"\$libtool_execute_magic\" != \"$magic\"; then + file=\"\$0\"" + + qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"` + $ECHO "\ + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} + ECHO=\"$qECHO\" + fi + +# Very basic option parsing. These options are (a) specific to +# the libtool wrapper, (b) are identical between the wrapper +# /script/ and the wrapper /executable/ which is used only on +# windows platforms, and (c) all begin with the string "--lt-" +# (application programs are unlikely to have options which match +# this pattern). +# +# There are only two supported options: --lt-debug and +# --lt-dump-script. There is, deliberately, no --lt-help. +# +# The first argument to this parsing function should be the +# script's $0 value, followed by "$@". +lt_option_debug= +func_parse_lt_options () +{ + lt_script_arg0=\$0 + shift + for lt_opt + do + case \"\$lt_opt\" in + --lt-debug) lt_option_debug=1 ;; + --lt-dump-script) + lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` + test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. + lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` + cat \"\$lt_dump_D/\$lt_dump_F\" + exit 0 + ;; + --lt-*) + \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 + exit 1 + ;; + esac + done + + # Print the debug banner immediately: + if test -n \"\$lt_option_debug\"; then + echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2 + fi +} + +# Used when --lt-debug. Prints its arguments to stdout +# (redirection is the responsibility of the caller) +func_lt_dump_args () +{ + lt_dump_args_N=1; + for lt_arg + do + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\" + lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` + done +} + +# Core function for launching the target application +func_exec_program_core () +{ +" + case $host in + # Backslashes separate directories on plain windows + *-*-mingw | *-*-os2* | *-cegcc*) + $ECHO "\ + if test -n \"\$lt_option_debug\"; then + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2 + func_lt_dump_args \${1+\"\$@\"} 1>&2 + fi + exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} +" + ;; + + *) + $ECHO "\ + if test -n \"\$lt_option_debug\"; then + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2 + func_lt_dump_args \${1+\"\$@\"} 1>&2 + fi + exec \"\$progdir/\$program\" \${1+\"\$@\"} +" + ;; + esac + $ECHO "\ + \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 + exit 1 +} + +# A function to encapsulate launching the target application +# Strips options in the --lt-* namespace from \$@ and +# launches target application with the remaining arguments. +func_exec_program () +{ + case \" \$* \" in + *\\ --lt-*) + for lt_wr_arg + do + case \$lt_wr_arg in + --lt-*) ;; + *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; + esac + shift + done ;; + esac + func_exec_program_core \${1+\"\$@\"} +} + + # Parse options + func_parse_lt_options \"\$0\" \${1+\"\$@\"} + + # Find the directory that this script lives in. + thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\` + test \"x\$thisdir\" = \"x\$file\" && thisdir=. + + # Follow symbolic links until we get to the real thisdir. + file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` + while test -n \"\$file\"; do + destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` + + # If there was a directory component, then change thisdir. + if test \"x\$destdir\" != \"x\$file\"; then + case \"\$destdir\" in + [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; + *) thisdir=\"\$thisdir/\$destdir\" ;; + esac + fi + + file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` + file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` + done + + # Usually 'no', except on cygwin/mingw when embedded into + # the cwrapper. + WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 + if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then + # special case for '.' + if test \"\$thisdir\" = \".\"; then + thisdir=\`pwd\` + fi + # remove .libs from thisdir + case \"\$thisdir\" in + *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; + $objdir ) thisdir=. ;; + esac + fi + + # Try to get the absolute directory name. + absdir=\`cd \"\$thisdir\" && pwd\` + test -n \"\$absdir\" && thisdir=\"\$absdir\" +" + + if test "$fast_install" = yes; then + $ECHO "\ + program=lt-'$outputname'$exeext + progdir=\"\$thisdir/$objdir\" + + if test ! -f \"\$progdir/\$program\" || + { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ + test \"X\$file\" != \"X\$progdir/\$program\"; }; then + + file=\"\$\$-\$program\" + + if test ! -d \"\$progdir\"; then + $MKDIR \"\$progdir\" + else + $RM \"\$progdir/\$file\" + fi" + + $ECHO "\ + + # relink executable if necessary + if test -n \"\$relink_command\"; then + if relink_command_output=\`eval \$relink_command 2>&1\`; then : + else + $ECHO \"\$relink_command_output\" >&2 + $RM \"\$progdir/\$file\" + exit 1 + fi + fi + + $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || + { $RM \"\$progdir/\$program\"; + $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } + $RM \"\$progdir/\$file\" + fi" + else + $ECHO "\ + program='$outputname' + progdir=\"\$thisdir/$objdir\" +" + fi + + $ECHO "\ + + if test -f \"\$progdir/\$program\"; then" + + # fixup the dll searchpath if we need to. + # + # Fix the DLL searchpath if we need to. Do this before prepending + # to shlibpath, because on Windows, both are PATH and uninstalled + # libraries must come first. + if test -n "$dllsearchpath"; then + $ECHO "\ + # Add the dll search path components to the executable PATH + PATH=$dllsearchpath:\$PATH +" + fi + + # Export our shlibpath_var if we have one. + if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then + $ECHO "\ + # Add our own library path to $shlibpath_var + $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" + + # Some systems cannot cope with colon-terminated $shlibpath_var + # The second colon is a workaround for a bug in BeOS R4 sed + $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` + + export $shlibpath_var +" + fi + + $ECHO "\ + if test \"\$libtool_execute_magic\" != \"$magic\"; then + # Run the actual program with our arguments. + func_exec_program \${1+\"\$@\"} + fi + else + # The program doesn't exist. + \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 + \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 + \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 + exit 1 + fi +fi\ +" +} + + +# func_emit_cwrapperexe_src +# emit the source code for a wrapper executable on stdout +# Must ONLY be called from within func_mode_link because +# it depends on a number of variable set therein. +func_emit_cwrapperexe_src () +{ + cat <<EOF + +/* $cwrappersource - temporary wrapper executable for $objdir/$outputname + Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION + + The $output program cannot be directly executed until all the libtool + libraries that it depends on are installed. + + This wrapper executable should never be moved out of the build directory. + If it is, it will not operate correctly. +*/ +EOF + cat <<"EOF" +#ifdef _MSC_VER +# define _CRT_SECURE_NO_DEPRECATE 1 +#endif +#include <stdio.h> +#include <stdlib.h> +#ifdef _MSC_VER +# include <direct.h> +# include <process.h> +# include <io.h> +#else +# include <unistd.h> +# include <stdint.h> +# ifdef __CYGWIN__ +# include <io.h> +# endif +#endif +#include <malloc.h> +#include <stdarg.h> +#include <assert.h> +#include <string.h> +#include <ctype.h> +#include <errno.h> +#include <fcntl.h> +#include <sys/stat.h> + +/* declarations of non-ANSI functions */ +#if defined(__MINGW32__) +# ifdef __STRICT_ANSI__ +int _putenv (const char *); +# endif +#elif defined(__CYGWIN__) +# ifdef __STRICT_ANSI__ +char *realpath (const char *, char *); +int putenv (char *); +int setenv (const char *, const char *, int); +# endif +/* #elif defined (other platforms) ... */ +#endif + +/* portability defines, excluding path handling macros */ +#if defined(_MSC_VER) +# define setmode _setmode +# define stat _stat +# define chmod _chmod +# define getcwd _getcwd +# define putenv _putenv +# define S_IXUSR _S_IEXEC +# ifndef _INTPTR_T_DEFINED +# define _INTPTR_T_DEFINED +# define intptr_t int +# endif +#elif defined(__MINGW32__) +# define setmode _setmode +# define stat _stat +# define chmod _chmod +# define getcwd _getcwd +# define putenv _putenv +#elif defined(__CYGWIN__) +# define HAVE_SETENV +# define FOPEN_WB "wb" +/* #elif defined (other platforms) ... */ +#endif + +#if defined(PATH_MAX) +# define LT_PATHMAX PATH_MAX +#elif defined(MAXPATHLEN) +# define LT_PATHMAX MAXPATHLEN +#else +# define LT_PATHMAX 1024 +#endif + +#ifndef S_IXOTH +# define S_IXOTH 0 +#endif +#ifndef S_IXGRP +# define S_IXGRP 0 +#endif + +/* path handling portability macros */ +#ifndef DIR_SEPARATOR +# define DIR_SEPARATOR '/' +# define PATH_SEPARATOR ':' +#endif + +#if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ + defined (__OS2__) +# define HAVE_DOS_BASED_FILE_SYSTEM +# define FOPEN_WB "wb" +# ifndef DIR_SEPARATOR_2 +# define DIR_SEPARATOR_2 '\\' +# endif +# ifndef PATH_SEPARATOR_2 +# define PATH_SEPARATOR_2 ';' +# endif +#endif + +#ifndef DIR_SEPARATOR_2 +# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) +#else /* DIR_SEPARATOR_2 */ +# define IS_DIR_SEPARATOR(ch) \ + (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) +#endif /* DIR_SEPARATOR_2 */ + +#ifndef PATH_SEPARATOR_2 +# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) +#else /* PATH_SEPARATOR_2 */ +# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) +#endif /* PATH_SEPARATOR_2 */ + +#ifndef FOPEN_WB +# define FOPEN_WB "w" +#endif +#ifndef _O_BINARY +# define _O_BINARY 0 +#endif + +#define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) +#define XFREE(stale) do { \ + if (stale) { free ((void *) stale); stale = 0; } \ +} while (0) + +#if defined(LT_DEBUGWRAPPER) +static int lt_debug = 1; +#else +static int lt_debug = 0; +#endif + +const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ + +void *xmalloc (size_t num); +char *xstrdup (const char *string); +const char *base_name (const char *name); +char *find_executable (const char *wrapper); +char *chase_symlinks (const char *pathspec); +int make_executable (const char *path); +int check_executable (const char *path); +char *strendzap (char *str, const char *pat); +void lt_debugprintf (const char *file, int line, const char *fmt, ...); +void lt_fatal (const char *file, int line, const char *message, ...); +static const char *nonnull (const char *s); +static const char *nonempty (const char *s); +void lt_setenv (const char *name, const char *value); +char *lt_extend_str (const char *orig_value, const char *add, int to_end); +void lt_update_exe_path (const char *name, const char *value); +void lt_update_lib_path (const char *name, const char *value); +char **prepare_spawn (char **argv); +void lt_dump_script (FILE *f); +EOF + + cat <<EOF +volatile const char * MAGIC_EXE = "$magic_exe"; +const char * LIB_PATH_VARNAME = "$shlibpath_var"; +EOF + + if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then + func_to_host_path "$temp_rpath" + cat <<EOF +const char * LIB_PATH_VALUE = "$func_to_host_path_result"; +EOF + else + cat <<"EOF" +const char * LIB_PATH_VALUE = ""; +EOF + fi + + if test -n "$dllsearchpath"; then + func_to_host_path "$dllsearchpath:" + cat <<EOF +const char * EXE_PATH_VARNAME = "PATH"; +const char * EXE_PATH_VALUE = "$func_to_host_path_result"; +EOF + else + cat <<"EOF" +const char * EXE_PATH_VARNAME = ""; +const char * EXE_PATH_VALUE = ""; +EOF + fi + + if test "$fast_install" = yes; then + cat <<EOF +const char * TARGET_PROGRAM_NAME = "lt-$outputname"; /* hopefully, no .exe */ +EOF + else + cat <<EOF +const char * TARGET_PROGRAM_NAME = "$outputname"; /* hopefully, no .exe */ +EOF + fi + + + cat <<"EOF" + +#define LTWRAPPER_OPTION_PREFIX "--lt-" + +static const char *ltwrapper_option_prefix = LTWRAPPER_OPTION_PREFIX; +static const char *dumpscript_opt = LTWRAPPER_OPTION_PREFIX "dump-script"; +static const char *debug_opt = LTWRAPPER_OPTION_PREFIX "debug"; + +int +main (int argc, char *argv[]) +{ + char **newargz; + int newargc; + char *tmp_pathspec; + char *actual_cwrapper_path; + char *actual_cwrapper_name; + char *target_name; + char *lt_argv_zero; + intptr_t rval = 127; + + int i; + + program_name = (char *) xstrdup (base_name (argv[0])); + newargz = XMALLOC (char *, argc + 1); + + /* very simple arg parsing; don't want to rely on getopt + * also, copy all non cwrapper options to newargz, except + * argz[0], which is handled differently + */ + newargc=0; + for (i = 1; i < argc; i++) + { + if (strcmp (argv[i], dumpscript_opt) == 0) + { +EOF + case "$host" in + *mingw* | *cygwin* ) + # make stdout use "unix" line endings + echo " setmode(1,_O_BINARY);" + ;; + esac + + cat <<"EOF" + lt_dump_script (stdout); + return 0; + } + if (strcmp (argv[i], debug_opt) == 0) + { + lt_debug = 1; + continue; + } + if (strcmp (argv[i], ltwrapper_option_prefix) == 0) + { + /* however, if there is an option in the LTWRAPPER_OPTION_PREFIX + namespace, but it is not one of the ones we know about and + have already dealt with, above (inluding dump-script), then + report an error. Otherwise, targets might begin to believe + they are allowed to use options in the LTWRAPPER_OPTION_PREFIX + namespace. The first time any user complains about this, we'll + need to make LTWRAPPER_OPTION_PREFIX a configure-time option + or a configure.ac-settable value. + */ + lt_fatal (__FILE__, __LINE__, + "unrecognized %s option: '%s'", + ltwrapper_option_prefix, argv[i]); + } + /* otherwise ... */ + newargz[++newargc] = xstrdup (argv[i]); + } + newargz[++newargc] = NULL; + +EOF + cat <<EOF + /* The GNU banner must be the first non-error debug message */ + lt_debugprintf (__FILE__, __LINE__, "libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\n"); +EOF + cat <<"EOF" + lt_debugprintf (__FILE__, __LINE__, "(main) argv[0]: %s\n", argv[0]); + lt_debugprintf (__FILE__, __LINE__, "(main) program_name: %s\n", program_name); + + tmp_pathspec = find_executable (argv[0]); + if (tmp_pathspec == NULL) + lt_fatal (__FILE__, __LINE__, "couldn't find %s", argv[0]); + lt_debugprintf (__FILE__, __LINE__, + "(main) found exe (before symlink chase) at: %s\n", + tmp_pathspec); + + actual_cwrapper_path = chase_symlinks (tmp_pathspec); + lt_debugprintf (__FILE__, __LINE__, + "(main) found exe (after symlink chase) at: %s\n", + actual_cwrapper_path); + XFREE (tmp_pathspec); + + actual_cwrapper_name = xstrdup (base_name (actual_cwrapper_path)); + strendzap (actual_cwrapper_path, actual_cwrapper_name); + + /* wrapper name transforms */ + strendzap (actual_cwrapper_name, ".exe"); + tmp_pathspec = lt_extend_str (actual_cwrapper_name, ".exe", 1); + XFREE (actual_cwrapper_name); + actual_cwrapper_name = tmp_pathspec; + tmp_pathspec = 0; + + /* target_name transforms -- use actual target program name; might have lt- prefix */ + target_name = xstrdup (base_name (TARGET_PROGRAM_NAME)); + strendzap (target_name, ".exe"); + tmp_pathspec = lt_extend_str (target_name, ".exe", 1); + XFREE (target_name); + target_name = tmp_pathspec; + tmp_pathspec = 0; + + lt_debugprintf (__FILE__, __LINE__, + "(main) libtool target name: %s\n", + target_name); +EOF + + cat <<EOF + newargz[0] = + XMALLOC (char, (strlen (actual_cwrapper_path) + + strlen ("$objdir") + 1 + strlen (actual_cwrapper_name) + 1)); + strcpy (newargz[0], actual_cwrapper_path); + strcat (newargz[0], "$objdir"); + strcat (newargz[0], "/"); +EOF + + cat <<"EOF" + /* stop here, and copy so we don't have to do this twice */ + tmp_pathspec = xstrdup (newargz[0]); + + /* do NOT want the lt- prefix here, so use actual_cwrapper_name */ + strcat (newargz[0], actual_cwrapper_name); + + /* DO want the lt- prefix here if it exists, so use target_name */ + lt_argv_zero = lt_extend_str (tmp_pathspec, target_name, 1); + XFREE (tmp_pathspec); + tmp_pathspec = NULL; +EOF + + case $host_os in + mingw*) + cat <<"EOF" + { + char* p; + while ((p = strchr (newargz[0], '\\')) != NULL) + { + *p = '/'; + } + while ((p = strchr (lt_argv_zero, '\\')) != NULL) + { + *p = '/'; + } + } +EOF + ;; + esac + + cat <<"EOF" + XFREE (target_name); + XFREE (actual_cwrapper_path); + XFREE (actual_cwrapper_name); + + lt_setenv ("BIN_SH", "xpg4"); /* for Tru64 */ + lt_setenv ("DUALCASE", "1"); /* for MSK sh */ + /* Update the DLL searchpath. EXE_PATH_VALUE ($dllsearchpath) must + be prepended before (that is, appear after) LIB_PATH_VALUE ($temp_rpath) + because on Windows, both *_VARNAMEs are PATH but uninstalled + libraries must come first. */ + lt_update_exe_path (EXE_PATH_VARNAME, EXE_PATH_VALUE); + lt_update_lib_path (LIB_PATH_VARNAME, LIB_PATH_VALUE); + + lt_debugprintf (__FILE__, __LINE__, "(main) lt_argv_zero: %s\n", + nonnull (lt_argv_zero)); + for (i = 0; i < newargc; i++) + { + lt_debugprintf (__FILE__, __LINE__, "(main) newargz[%d]: %s\n", + i, nonnull (newargz[i])); + } + +EOF + + case $host_os in + mingw*) + cat <<"EOF" + /* execv doesn't actually work on mingw as expected on unix */ + newargz = prepare_spawn (newargz); + rval = _spawnv (_P_WAIT, lt_argv_zero, (const char * const *) newargz); + if (rval == -1) + { + /* failed to start process */ + lt_debugprintf (__FILE__, __LINE__, + "(main) failed to launch target \"%s\": %s\n", + lt_argv_zero, nonnull (strerror (errno))); + return 127; + } + return rval; +EOF + ;; + *) + cat <<"EOF" + execv (lt_argv_zero, newargz); + return rval; /* =127, but avoids unused variable warning */ +EOF + ;; + esac + + cat <<"EOF" +} + +void * +xmalloc (size_t num) +{ + void *p = (void *) malloc (num); + if (!p) + lt_fatal (__FILE__, __LINE__, "memory exhausted"); + + return p; +} + +char * +xstrdup (const char *string) +{ + return string ? strcpy ((char *) xmalloc (strlen (string) + 1), + string) : NULL; +} + +const char * +base_name (const char *name) +{ + const char *base; + +#if defined (HAVE_DOS_BASED_FILE_SYSTEM) + /* Skip over the disk name in MSDOS pathnames. */ + if (isalpha ((unsigned char) name[0]) && name[1] == ':') + name += 2; +#endif + + for (base = name; *name; name++) + if (IS_DIR_SEPARATOR (*name)) + base = name + 1; + return base; +} + +int +check_executable (const char *path) +{ + struct stat st; + + lt_debugprintf (__FILE__, __LINE__, "(check_executable): %s\n", + nonempty (path)); + if ((!path) || (!*path)) + return 0; + + if ((stat (path, &st) >= 0) + && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) + return 1; + else + return 0; +} + +int +make_executable (const char *path) +{ + int rval = 0; + struct stat st; + + lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n", + nonempty (path)); + if ((!path) || (!*path)) + return 0; + + if (stat (path, &st) >= 0) + { + rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); + } + return rval; +} + +/* Searches for the full path of the wrapper. Returns + newly allocated full path name if found, NULL otherwise + Does not chase symlinks, even on platforms that support them. +*/ +char * +find_executable (const char *wrapper) +{ + int has_slash = 0; + const char *p; + const char *p_next; + /* static buffer for getcwd */ + char tmp[LT_PATHMAX + 1]; + int tmp_len; + char *concat_name; + + lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n", + nonempty (wrapper)); + + if ((wrapper == NULL) || (*wrapper == '\0')) + return NULL; + + /* Absolute path? */ +#if defined (HAVE_DOS_BASED_FILE_SYSTEM) + if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') + { + concat_name = xstrdup (wrapper); + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + } + else + { +#endif + if (IS_DIR_SEPARATOR (wrapper[0])) + { + concat_name = xstrdup (wrapper); + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + } +#if defined (HAVE_DOS_BASED_FILE_SYSTEM) + } +#endif + + for (p = wrapper; *p; p++) + if (*p == '/') + { + has_slash = 1; + break; + } + if (!has_slash) + { + /* no slashes; search PATH */ + const char *path = getenv ("PATH"); + if (path != NULL) + { + for (p = path; *p; p = p_next) + { + const char *q; + size_t p_len; + for (q = p; *q; q++) + if (IS_PATH_SEPARATOR (*q)) + break; + p_len = q - p; + p_next = (*q == '\0' ? q : q + 1); + if (p_len == 0) + { + /* empty path: current directory */ + if (getcwd (tmp, LT_PATHMAX) == NULL) + lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", + nonnull (strerror (errno))); + tmp_len = strlen (tmp); + concat_name = + XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); + memcpy (concat_name, tmp, tmp_len); + concat_name[tmp_len] = '/'; + strcpy (concat_name + tmp_len + 1, wrapper); + } + else + { + concat_name = + XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); + memcpy (concat_name, p, p_len); + concat_name[p_len] = '/'; + strcpy (concat_name + p_len + 1, wrapper); + } + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + } + } + /* not found in PATH; assume curdir */ + } + /* Relative path | not found in path: prepend cwd */ + if (getcwd (tmp, LT_PATHMAX) == NULL) + lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", + nonnull (strerror (errno))); + tmp_len = strlen (tmp); + concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); + memcpy (concat_name, tmp, tmp_len); + concat_name[tmp_len] = '/'; + strcpy (concat_name + tmp_len + 1, wrapper); + + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + return NULL; +} + +char * +chase_symlinks (const char *pathspec) +{ +#ifndef S_ISLNK + return xstrdup (pathspec); +#else + char buf[LT_PATHMAX]; + struct stat s; + char *tmp_pathspec = xstrdup (pathspec); + char *p; + int has_symlinks = 0; + while (strlen (tmp_pathspec) && !has_symlinks) + { + lt_debugprintf (__FILE__, __LINE__, + "checking path component for symlinks: %s\n", + tmp_pathspec); + if (lstat (tmp_pathspec, &s) == 0) + { + if (S_ISLNK (s.st_mode) != 0) + { + has_symlinks = 1; + break; + } + + /* search backwards for last DIR_SEPARATOR */ + p = tmp_pathspec + strlen (tmp_pathspec) - 1; + while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) + p--; + if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) + { + /* no more DIR_SEPARATORS left */ + break; + } + *p = '\0'; + } + else + { + lt_fatal (__FILE__, __LINE__, + "error accessing file \"%s\": %s", + tmp_pathspec, nonnull (strerror (errno))); + } + } + XFREE (tmp_pathspec); + + if (!has_symlinks) + { + return xstrdup (pathspec); + } + + tmp_pathspec = realpath (pathspec, buf); + if (tmp_pathspec == 0) + { + lt_fatal (__FILE__, __LINE__, + "could not follow symlinks for %s", pathspec); + } + return xstrdup (tmp_pathspec); +#endif +} + +char * +strendzap (char *str, const char *pat) +{ + size_t len, patlen; + + assert (str != NULL); + assert (pat != NULL); + + len = strlen (str); + patlen = strlen (pat); + + if (patlen <= len) + { + str += len - patlen; + if (strcmp (str, pat) == 0) + *str = '\0'; + } + return str; +} + +void +lt_debugprintf (const char *file, int line, const char *fmt, ...) +{ + va_list args; + if (lt_debug) + { + (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line); + va_start (args, fmt); + (void) vfprintf (stderr, fmt, args); + va_end (args); + } +} + +static void +lt_error_core (int exit_status, const char *file, + int line, const char *mode, + const char *message, va_list ap) +{ + fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode); + vfprintf (stderr, message, ap); + fprintf (stderr, ".\n"); + + if (exit_status >= 0) + exit (exit_status); +} + +void +lt_fatal (const char *file, int line, const char *message, ...) +{ + va_list ap; + va_start (ap, message); + lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap); + va_end (ap); +} + +static const char * +nonnull (const char *s) +{ + return s ? s : "(null)"; +} + +static const char * +nonempty (const char *s) +{ + return (s && !*s) ? "(empty)" : nonnull (s); +} + +void +lt_setenv (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_setenv) setting '%s' to '%s'\n", + nonnull (name), nonnull (value)); + { +#ifdef HAVE_SETENV + /* always make a copy, for consistency with !HAVE_SETENV */ + char *str = xstrdup (value); + setenv (name, str, 1); +#else + int len = strlen (name) + 1 + strlen (value) + 1; + char *str = XMALLOC (char, len); + sprintf (str, "%s=%s", name, value); + if (putenv (str) != EXIT_SUCCESS) + { + XFREE (str); + } +#endif + } +} + +char * +lt_extend_str (const char *orig_value, const char *add, int to_end) +{ + char *new_value; + if (orig_value && *orig_value) + { + int orig_value_len = strlen (orig_value); + int add_len = strlen (add); + new_value = XMALLOC (char, add_len + orig_value_len + 1); + if (to_end) + { + strcpy (new_value, orig_value); + strcpy (new_value + orig_value_len, add); + } + else + { + strcpy (new_value, add); + strcpy (new_value + add_len, orig_value); + } + } + else + { + new_value = xstrdup (add); + } + return new_value; +} + +void +lt_update_exe_path (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_update_exe_path) modifying '%s' by prepending '%s'\n", + nonnull (name), nonnull (value)); + + if (name && *name && value && *value) + { + char *new_value = lt_extend_str (getenv (name), value, 0); + /* some systems can't cope with a ':'-terminated path #' */ + int len = strlen (new_value); + while (((len = strlen (new_value)) > 0) && IS_PATH_SEPARATOR (new_value[len-1])) + { + new_value[len-1] = '\0'; + } + lt_setenv (name, new_value); + XFREE (new_value); + } +} + +void +lt_update_lib_path (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", + nonnull (name), nonnull (value)); + + if (name && *name && value && *value) + { + char *new_value = lt_extend_str (getenv (name), value, 0); + lt_setenv (name, new_value); + XFREE (new_value); + } +} + +EOF + case $host_os in + mingw*) + cat <<"EOF" + +/* Prepares an argument vector before calling spawn(). + Note that spawn() does not by itself call the command interpreter + (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : + ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); + GetVersionEx(&v); + v.dwPlatformId == VER_PLATFORM_WIN32_NT; + }) ? "cmd.exe" : "command.com"). + Instead it simply concatenates the arguments, separated by ' ', and calls + CreateProcess(). We must quote the arguments since Win32 CreateProcess() + interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a + special way: + - Space and tab are interpreted as delimiters. They are not treated as + delimiters if they are surrounded by double quotes: "...". + - Unescaped double quotes are removed from the input. Their only effect is + that within double quotes, space and tab are treated like normal + characters. + - Backslashes not followed by double quotes are not special. + - But 2*n+1 backslashes followed by a double quote become + n backslashes followed by a double quote (n >= 0): + \" -> " + \\\" -> \" + \\\\\" -> \\" + */ +#define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" +#define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" +char ** +prepare_spawn (char **argv) +{ + size_t argc; + char **new_argv; + size_t i; + + /* Count number of arguments. */ + for (argc = 0; argv[argc] != NULL; argc++) + ; + + /* Allocate new argument vector. */ + new_argv = XMALLOC (char *, argc + 1); + + /* Put quoted arguments into the new argument vector. */ + for (i = 0; i < argc; i++) + { + const char *string = argv[i]; + + if (string[0] == '\0') + new_argv[i] = xstrdup ("\"\""); + else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) + { + int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); + size_t length; + unsigned int backslashes; + const char *s; + char *quoted_string; + char *p; + + length = 0; + backslashes = 0; + if (quote_around) + length++; + for (s = string; *s != '\0'; s++) + { + char c = *s; + if (c == '"') + length += backslashes + 1; + length++; + if (c == '\\') + backslashes++; + else + backslashes = 0; + } + if (quote_around) + length += backslashes + 1; + + quoted_string = XMALLOC (char, length + 1); + + p = quoted_string; + backslashes = 0; + if (quote_around) + *p++ = '"'; + for (s = string; *s != '\0'; s++) + { + char c = *s; + if (c == '"') + { + unsigned int j; + for (j = backslashes + 1; j > 0; j--) + *p++ = '\\'; + } + *p++ = c; + if (c == '\\') + backslashes++; + else + backslashes = 0; + } + if (quote_around) + { + unsigned int j; + for (j = backslashes; j > 0; j--) + *p++ = '\\'; + *p++ = '"'; + } + *p = '\0'; + + new_argv[i] = quoted_string; + } + else + new_argv[i] = (char *) string; + } + new_argv[argc] = NULL; + + return new_argv; +} +EOF + ;; + esac + + cat <<"EOF" +void lt_dump_script (FILE* f) +{ +EOF + func_emit_wrapper yes | + $SED -n -e ' +s/^\(.\{79\}\)\(..*\)/\1\ +\2/ +h +s/\([\\"]\)/\\\1/g +s/$/\\n/ +s/\([^\n]*\).*/ fputs ("\1", f);/p +g +D' + cat <<"EOF" +} +EOF +} +# end: func_emit_cwrapperexe_src + +# func_win32_import_lib_p ARG +# True if ARG is an import lib, as indicated by $file_magic_cmd +func_win32_import_lib_p () +{ + $opt_debug + case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in + *import*) : ;; + *) false ;; + esac +} + +# func_mode_link arg... +func_mode_link () +{ + $opt_debug + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + # It is impossible to link a dll without this setting, and + # we shouldn't force the makefile maintainer to figure out + # which system we are compiling for in order to pass an extra + # flag for every libtool invocation. + # allow_undefined=no + + # FIXME: Unfortunately, there are problems with the above when trying + # to make a dll which has undefined symbols, in which case not + # even a static library is built. For now, we need to specify + # -no-undefined on the libtool link line when we can be certain + # that all symbols are satisfied, otherwise we get a static library. + allow_undefined=yes + ;; + *) + allow_undefined=yes + ;; + esac + libtool_args=$nonopt + base_compile="$nonopt $@" + compile_command=$nonopt + finalize_command=$nonopt + + compile_rpath= + finalize_rpath= + compile_shlibpath= + finalize_shlibpath= + convenience= + old_convenience= + deplibs= + old_deplibs= + compiler_flags= + linker_flags= + dllsearchpath= + lib_search_path=`pwd` + inst_prefix_dir= + new_inherited_linker_flags= + + avoid_version=no + bindir= + dlfiles= + dlprefiles= + dlself=no + export_dynamic=no + export_symbols= + export_symbols_regex= + generated= + libobjs= + ltlibs= + module=no + no_install=no + objs= + non_pic_objects= + precious_files_regex= + prefer_static_libs=no + preload=no + prev= + prevarg= + release= + rpath= + xrpath= + perm_rpath= + temp_rpath= + thread_safe=no + vinfo= + vinfo_number=no + weak_libs= + single_module="${wl}-single_module" + func_infer_tag $base_compile + + # We need to know -static, to get the right output filenames. + for arg + do + case $arg in + -shared) + test "$build_libtool_libs" != yes && \ + func_fatal_configuration "can not build a shared library" + build_old_libs=no + break + ;; + -all-static | -static | -static-libtool-libs) + case $arg in + -all-static) + if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then + func_warning "complete static linking is impossible in this configuration" + fi + if test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=yes + ;; + -static) + if test -z "$pic_flag" && test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=built + ;; + -static-libtool-libs) + if test -z "$pic_flag" && test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=yes + ;; + esac + build_libtool_libs=no + build_old_libs=yes + break + ;; + esac + done + + # See if our shared archives depend on static archives. + test -n "$old_archive_from_new_cmds" && build_old_libs=yes + + # Go through the arguments, transforming them on the way. + while test "$#" -gt 0; do + arg="$1" + shift + func_quote_for_eval "$arg" + qarg=$func_quote_for_eval_unquoted_result + func_append libtool_args " $func_quote_for_eval_result" + + # If the previous option needs an argument, assign it. + if test -n "$prev"; then + case $prev in + output) + func_append compile_command " @OUTPUT@" + func_append finalize_command " @OUTPUT@" + ;; + esac + + case $prev in + bindir) + bindir="$arg" + prev= + continue + ;; + dlfiles|dlprefiles) + if test "$preload" = no; then + # Add the symbol object into the linking commands. + func_append compile_command " @SYMFILE@" + func_append finalize_command " @SYMFILE@" + preload=yes + fi + case $arg in + *.la | *.lo) ;; # We handle these cases below. + force) + if test "$dlself" = no; then + dlself=needless + export_dynamic=yes + fi + prev= + continue + ;; + self) + if test "$prev" = dlprefiles; then + dlself=yes + elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then + dlself=yes + else + dlself=needless + export_dynamic=yes + fi + prev= + continue + ;; + *) + if test "$prev" = dlfiles; then + func_append dlfiles " $arg" + else + func_append dlprefiles " $arg" + fi + prev= + continue + ;; + esac + ;; + expsyms) + export_symbols="$arg" + test -f "$arg" \ + || func_fatal_error "symbol file \`$arg' does not exist" + prev= + continue + ;; + expsyms_regex) + export_symbols_regex="$arg" + prev= + continue + ;; + framework) + case $host in + *-*-darwin*) + case "$deplibs " in + *" $qarg.ltframework "*) ;; + *) func_append deplibs " $qarg.ltframework" # this is fixed later + ;; + esac + ;; + esac + prev= + continue + ;; + inst_prefix) + inst_prefix_dir="$arg" + prev= + continue + ;; + objectlist) + if test -f "$arg"; then + save_arg=$arg + moreargs= + for fil in `cat "$save_arg"` + do +# func_append moreargs " $fil" + arg=$fil + # A libtool-controlled object. + + # Check to see that this really is a libtool object. + if func_lalib_unsafe_p "$arg"; then + pic_object= + non_pic_object= + + # Read the .lo file + func_source "$arg" + + if test -z "$pic_object" || + test -z "$non_pic_object" || + test "$pic_object" = none && + test "$non_pic_object" = none; then + func_fatal_error "cannot find name of object for \`$arg'" + fi + + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + if test "$pic_object" != none; then + # Prepend the subdirectory the object is found in. + pic_object="$xdir$pic_object" + + if test "$prev" = dlfiles; then + if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then + func_append dlfiles " $pic_object" + prev= + continue + else + # If libtool objects are unsupported, then we need to preload. + prev=dlprefiles + fi + fi + + # CHECK ME: I think I busted this. -Ossama + if test "$prev" = dlprefiles; then + # Preload the old-style object. + func_append dlprefiles " $pic_object" + prev= + fi + + # A PIC object. + func_append libobjs " $pic_object" + arg="$pic_object" + fi + + # Non-PIC object. + if test "$non_pic_object" != none; then + # Prepend the subdirectory the object is found in. + non_pic_object="$xdir$non_pic_object" + + # A standard non-PIC object + func_append non_pic_objects " $non_pic_object" + if test -z "$pic_object" || test "$pic_object" = none ; then + arg="$non_pic_object" + fi + else + # If the PIC object exists, use it instead. + # $xdir was prepended to $pic_object above. + non_pic_object="$pic_object" + func_append non_pic_objects " $non_pic_object" + fi + else + # Only an error if not doing a dry-run. + if $opt_dry_run; then + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + func_lo2o "$arg" + pic_object=$xdir$objdir/$func_lo2o_result + non_pic_object=$xdir$func_lo2o_result + func_append libobjs " $pic_object" + func_append non_pic_objects " $non_pic_object" + else + func_fatal_error "\`$arg' is not a valid libtool object" + fi + fi + done + else + func_fatal_error "link input file \`$arg' does not exist" + fi + arg=$save_arg + prev= + continue + ;; + precious_regex) + precious_files_regex="$arg" + prev= + continue + ;; + release) + release="-$arg" + prev= + continue + ;; + rpath | xrpath) + # We need an absolute path. + case $arg in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + func_fatal_error "only absolute run-paths are allowed" + ;; + esac + if test "$prev" = rpath; then + case "$rpath " in + *" $arg "*) ;; + *) func_append rpath " $arg" ;; + esac + else + case "$xrpath " in + *" $arg "*) ;; + *) func_append xrpath " $arg" ;; + esac + fi + prev= + continue + ;; + shrext) + shrext_cmds="$arg" + prev= + continue + ;; + weak) + func_append weak_libs " $arg" + prev= + continue + ;; + xcclinker) + func_append linker_flags " $qarg" + func_append compiler_flags " $qarg" + prev= + func_append compile_command " $qarg" + func_append finalize_command " $qarg" + continue + ;; + xcompiler) + func_append compiler_flags " $qarg" + prev= + func_append compile_command " $qarg" + func_append finalize_command " $qarg" + continue + ;; + xlinker) + func_append linker_flags " $qarg" + func_append compiler_flags " $wl$qarg" + prev= + func_append compile_command " $wl$qarg" + func_append finalize_command " $wl$qarg" + continue + ;; + *) + eval "$prev=\"\$arg\"" + prev= + continue + ;; + esac + fi # test -n "$prev" + + prevarg="$arg" + + case $arg in + -all-static) + if test -n "$link_static_flag"; then + # See comment for -static flag below, for more details. + func_append compile_command " $link_static_flag" + func_append finalize_command " $link_static_flag" + fi + continue + ;; + + -allow-undefined) + # FIXME: remove this flag sometime in the future. + func_fatal_error "\`-allow-undefined' must not be used because it is the default" + ;; + + -avoid-version) + avoid_version=yes + continue + ;; + + -bindir) + prev=bindir + continue + ;; + + -dlopen) + prev=dlfiles + continue + ;; + + -dlpreopen) + prev=dlprefiles + continue + ;; + + -export-dynamic) + export_dynamic=yes + continue + ;; + + -export-symbols | -export-symbols-regex) + if test -n "$export_symbols" || test -n "$export_symbols_regex"; then + func_fatal_error "more than one -exported-symbols argument is not allowed" + fi + if test "X$arg" = "X-export-symbols"; then + prev=expsyms + else + prev=expsyms_regex + fi + continue + ;; + + -framework) + prev=framework + continue + ;; + + -inst-prefix-dir) + prev=inst_prefix + continue + ;; + + # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* + # so, if we see these flags be careful not to treat them like -L + -L[A-Z][A-Z]*:*) + case $with_gcc/$host in + no/*-*-irix* | /*-*-irix*) + func_append compile_command " $arg" + func_append finalize_command " $arg" + ;; + esac + continue + ;; + + -L*) + func_stripname "-L" '' "$arg" + if test -z "$func_stripname_result"; then + if test "$#" -gt 0; then + func_fatal_error "require no space between \`-L' and \`$1'" + else + func_fatal_error "need path for \`-L' option" + fi + fi + func_resolve_sysroot "$func_stripname_result" + dir=$func_resolve_sysroot_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + absdir=`cd "$dir" && pwd` + test -z "$absdir" && \ + func_fatal_error "cannot determine absolute directory name of \`$dir'" + dir="$absdir" + ;; + esac + case "$deplibs " in + *" -L$dir "* | *" $arg "*) + # Will only happen for absolute or sysroot arguments + ;; + *) + # Preserve sysroot, but never include relative directories + case $dir in + [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; + *) func_append deplibs " -L$dir" ;; + esac + func_append lib_search_path " $dir" + ;; + esac + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` + case :$dllsearchpath: in + *":$dir:"*) ;; + ::) dllsearchpath=$dir;; + *) func_append dllsearchpath ":$dir";; + esac + case :$dllsearchpath: in + *":$testbindir:"*) ;; + ::) dllsearchpath=$testbindir;; + *) func_append dllsearchpath ":$testbindir";; + esac + ;; + esac + continue + ;; + + -l*) + if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) + # These systems don't actually have a C or math library (as such) + continue + ;; + *-*-os2*) + # These systems don't actually have a C library (as such) + test "X$arg" = "X-lc" && continue + ;; + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc due to us having libc/libc_r. + test "X$arg" = "X-lc" && continue + ;; + *-*-rhapsody* | *-*-darwin1.[012]) + # Rhapsody C and math libraries are in the System framework + func_append deplibs " System.ltframework" + continue + ;; + *-*-sco3.2v5* | *-*-sco5v6*) + # Causes problems with __ctype + test "X$arg" = "X-lc" && continue + ;; + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) + # Compiler inserts libc in the correct place for threads to work + test "X$arg" = "X-lc" && continue + ;; + esac + elif test "X$arg" = "X-lc_r"; then + case $host in + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc_r directly, use -pthread flag. + continue + ;; + esac + fi + func_append deplibs " $arg" + continue + ;; + + -module) + module=yes + continue + ;; + + # Tru64 UNIX uses -model [arg] to determine the layout of C++ + # classes, name mangling, and exception handling. + # Darwin uses the -arch flag to determine output architecture. + -model|-arch|-isysroot|--sysroot) + func_append compiler_flags " $arg" + func_append compile_command " $arg" + func_append finalize_command " $arg" + prev=xcompiler + continue + ;; + + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ + |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) + func_append compiler_flags " $arg" + func_append compile_command " $arg" + func_append finalize_command " $arg" + case "$new_inherited_linker_flags " in + *" $arg "*) ;; + * ) func_append new_inherited_linker_flags " $arg" ;; + esac + continue + ;; + + -multi_module) + single_module="${wl}-multi_module" + continue + ;; + + -no-fast-install) + fast_install=no + continue + ;; + + -no-install) + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) + # The PATH hackery in wrapper scripts is required on Windows + # and Darwin in order for the loader to find any dlls it needs. + func_warning "\`-no-install' is ignored for $host" + func_warning "assuming \`-no-fast-install' instead" + fast_install=no + ;; + *) no_install=yes ;; + esac + continue + ;; + + -no-undefined) + allow_undefined=no + continue + ;; + + -objectlist) + prev=objectlist + continue + ;; + + -o) prev=output ;; + + -precious-files-regex) + prev=precious_regex + continue + ;; + + -release) + prev=release + continue + ;; + + -rpath) + prev=rpath + continue + ;; + + -R) + prev=xrpath + continue + ;; + + -R*) + func_stripname '-R' '' "$arg" + dir=$func_stripname_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + =*) + func_stripname '=' '' "$dir" + dir=$lt_sysroot$func_stripname_result + ;; + *) + func_fatal_error "only absolute run-paths are allowed" + ;; + esac + case "$xrpath " in + *" $dir "*) ;; + *) func_append xrpath " $dir" ;; + esac + continue + ;; + + -shared) + # The effects of -shared are defined in a previous loop. + continue + ;; + + -shrext) + prev=shrext + continue + ;; + + -static | -static-libtool-libs) + # The effects of -static are defined in a previous loop. + # We used to do the same as -all-static on platforms that + # didn't have a PIC flag, but the assumption that the effects + # would be equivalent was wrong. It would break on at least + # Digital Unix and AIX. + continue + ;; + + -thread-safe) + thread_safe=yes + continue + ;; + + -version-info) + prev=vinfo + continue + ;; + + -version-number) + prev=vinfo + vinfo_number=yes + continue + ;; + + -weak) + prev=weak + continue + ;; + + -Wc,*) + func_stripname '-Wc,' '' "$arg" + args=$func_stripname_result + arg= + save_ifs="$IFS"; IFS=',' + for flag in $args; do + IFS="$save_ifs" + func_quote_for_eval "$flag" + func_append arg " $func_quote_for_eval_result" + func_append compiler_flags " $func_quote_for_eval_result" + done + IFS="$save_ifs" + func_stripname ' ' '' "$arg" + arg=$func_stripname_result + ;; + + -Wl,*) + func_stripname '-Wl,' '' "$arg" + args=$func_stripname_result + arg= + save_ifs="$IFS"; IFS=',' + for flag in $args; do + IFS="$save_ifs" + func_quote_for_eval "$flag" + func_append arg " $wl$func_quote_for_eval_result" + func_append compiler_flags " $wl$func_quote_for_eval_result" + func_append linker_flags " $func_quote_for_eval_result" + done + IFS="$save_ifs" + func_stripname ' ' '' "$arg" + arg=$func_stripname_result + ;; + + -Xcompiler) + prev=xcompiler + continue + ;; + + -Xlinker) + prev=xlinker + continue + ;; + + -XCClinker) + prev=xcclinker + continue + ;; + + # -msg_* for osf cc + -msg_*) + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + ;; + + # Flags to be passed through unchanged, with rationale: + # -64, -mips[0-9] enable 64-bit mode for the SGI compiler + # -r[0-9][0-9]* specify processor for the SGI compiler + # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler + # +DA*, +DD* enable 64-bit mode for the HP compiler + # -q* compiler args for the IBM compiler + # -m*, -t[45]*, -txscale* architecture-specific flags for GCC + # -F/path path to uninstalled frameworks, gcc on darwin + # -p, -pg, --coverage, -fprofile-* profiling flags for GCC + # @file GCC response files + # -tp=* Portland pgcc target processor selection + # --sysroot=* for sysroot support + # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization + -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ + -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ + -O*|-flto*|-fwhopr*|-fuse-linker-plugin) + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + func_append compile_command " $arg" + func_append finalize_command " $arg" + func_append compiler_flags " $arg" + continue + ;; + + # Some other compiler flag. + -* | +*) + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + ;; + + *.$objext) + # A standard object. + func_append objs " $arg" + ;; + + *.lo) + # A libtool-controlled object. + + # Check to see that this really is a libtool object. + if func_lalib_unsafe_p "$arg"; then + pic_object= + non_pic_object= + + # Read the .lo file + func_source "$arg" + + if test -z "$pic_object" || + test -z "$non_pic_object" || + test "$pic_object" = none && + test "$non_pic_object" = none; then + func_fatal_error "cannot find name of object for \`$arg'" + fi + + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + if test "$pic_object" != none; then + # Prepend the subdirectory the object is found in. + pic_object="$xdir$pic_object" + + if test "$prev" = dlfiles; then + if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then + func_append dlfiles " $pic_object" + prev= + continue + else + # If libtool objects are unsupported, then we need to preload. + prev=dlprefiles + fi + fi + + # CHECK ME: I think I busted this. -Ossama + if test "$prev" = dlprefiles; then + # Preload the old-style object. + func_append dlprefiles " $pic_object" + prev= + fi + + # A PIC object. + func_append libobjs " $pic_object" + arg="$pic_object" + fi + + # Non-PIC object. + if test "$non_pic_object" != none; then + # Prepend the subdirectory the object is found in. + non_pic_object="$xdir$non_pic_object" + + # A standard non-PIC object + func_append non_pic_objects " $non_pic_object" + if test -z "$pic_object" || test "$pic_object" = none ; then + arg="$non_pic_object" + fi + else + # If the PIC object exists, use it instead. + # $xdir was prepended to $pic_object above. + non_pic_object="$pic_object" + func_append non_pic_objects " $non_pic_object" + fi + else + # Only an error if not doing a dry-run. + if $opt_dry_run; then + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + func_lo2o "$arg" + pic_object=$xdir$objdir/$func_lo2o_result + non_pic_object=$xdir$func_lo2o_result + func_append libobjs " $pic_object" + func_append non_pic_objects " $non_pic_object" + else + func_fatal_error "\`$arg' is not a valid libtool object" + fi + fi + ;; + + *.$libext) + # An archive. + func_append deplibs " $arg" + func_append old_deplibs " $arg" + continue + ;; + + *.la) + # A libtool-controlled library. + + func_resolve_sysroot "$arg" + if test "$prev" = dlfiles; then + # This library was specified with -dlopen. + func_append dlfiles " $func_resolve_sysroot_result" + prev= + elif test "$prev" = dlprefiles; then + # The library was specified with -dlpreopen. + func_append dlprefiles " $func_resolve_sysroot_result" + prev= + else + func_append deplibs " $func_resolve_sysroot_result" + fi + continue + ;; + + # Some other compiler argument. + *) + # Unknown arguments in both finalize_command and compile_command need + # to be aesthetically quoted because they are evaled later. + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + ;; + esac # arg + + # Now actually substitute the argument into the commands. + if test -n "$arg"; then + func_append compile_command " $arg" + func_append finalize_command " $arg" + fi + done # argument parsing loop + + test -n "$prev" && \ + func_fatal_help "the \`$prevarg' option requires an argument" + + if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then + eval arg=\"$export_dynamic_flag_spec\" + func_append compile_command " $arg" + func_append finalize_command " $arg" + fi + + oldlibs= + # calculate the name of the file, without its directory + func_basename "$output" + outputname="$func_basename_result" + libobjs_save="$libobjs" + + if test -n "$shlibpath_var"; then + # get the directories listed in $shlibpath_var + eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$SED \'s/:/ /g\'\` + else + shlib_search_path= + fi + eval sys_lib_search_path=\"$sys_lib_search_path_spec\" + eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" + + func_dirname "$output" "/" "" + output_objdir="$func_dirname_result$objdir" + func_to_tool_file "$output_objdir/" + tool_output_objdir=$func_to_tool_file_result + # Create the object directory. + func_mkdir_p "$output_objdir" + + # Determine the type of output + case $output in + "") + func_fatal_help "you must specify an output file" + ;; + *.$libext) linkmode=oldlib ;; + *.lo | *.$objext) linkmode=obj ;; + *.la) linkmode=lib ;; + *) linkmode=prog ;; # Anything else should be a program. + esac + + specialdeplibs= + + libs= + # Find all interdependent deplibs by searching for libraries + # that are linked more than once (e.g. -la -lb -la) + for deplib in $deplibs; do + if $opt_preserve_dup_deps ; then + case "$libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append libs " $deplib" + done + + if test "$linkmode" = lib; then + libs="$predeps $libs $compiler_lib_search_path $postdeps" + + # Compute libraries that are listed more than once in $predeps + # $postdeps and mark them as special (i.e., whose duplicates are + # not to be eliminated). + pre_post_deps= + if $opt_duplicate_compiler_generated_deps; then + for pre_post_dep in $predeps $postdeps; do + case "$pre_post_deps " in + *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; + esac + func_append pre_post_deps " $pre_post_dep" + done + fi + pre_post_deps= + fi + + deplibs= + newdependency_libs= + newlib_search_path= + need_relink=no # whether we're linking any uninstalled libtool libraries + notinst_deplibs= # not-installed libtool libraries + notinst_path= # paths that contain not-installed libtool libraries + + case $linkmode in + lib) + passes="conv dlpreopen link" + for file in $dlfiles $dlprefiles; do + case $file in + *.la) ;; + *) + func_fatal_help "libraries can \`-dlopen' only libtool libraries: $file" + ;; + esac + done + ;; + prog) + compile_deplibs= + finalize_deplibs= + alldeplibs=no + newdlfiles= + newdlprefiles= + passes="conv scan dlopen dlpreopen link" + ;; + *) passes="conv" + ;; + esac + + for pass in $passes; do + # The preopen pass in lib mode reverses $deplibs; put it back here + # so that -L comes before libs that need it for instance... + if test "$linkmode,$pass" = "lib,link"; then + ## FIXME: Find the place where the list is rebuilt in the wrong + ## order, and fix it there properly + tmp_deplibs= + for deplib in $deplibs; do + tmp_deplibs="$deplib $tmp_deplibs" + done + deplibs="$tmp_deplibs" + fi + + if test "$linkmode,$pass" = "lib,link" || + test "$linkmode,$pass" = "prog,scan"; then + libs="$deplibs" + deplibs= + fi + if test "$linkmode" = prog; then + case $pass in + dlopen) libs="$dlfiles" ;; + dlpreopen) libs="$dlprefiles" ;; + link) + libs="$deplibs %DEPLIBS%" + test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs" + ;; + esac + fi + if test "$linkmode,$pass" = "lib,dlpreopen"; then + # Collect and forward deplibs of preopened libtool libs + for lib in $dlprefiles; do + # Ignore non-libtool-libs + dependency_libs= + func_resolve_sysroot "$lib" + case $lib in + *.la) func_source "$func_resolve_sysroot_result" ;; + esac + + # Collect preopened libtool deplibs, except any this library + # has declared as weak libs + for deplib in $dependency_libs; do + func_basename "$deplib" + deplib_base=$func_basename_result + case " $weak_libs " in + *" $deplib_base "*) ;; + *) func_append deplibs " $deplib" ;; + esac + done + done + libs="$dlprefiles" + fi + if test "$pass" = dlopen; then + # Collect dlpreopened libraries + save_deplibs="$deplibs" + deplibs= + fi + + for deplib in $libs; do + lib= + found=no + case $deplib in + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ + |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + func_append compiler_flags " $deplib" + if test "$linkmode" = lib ; then + case "$new_inherited_linker_flags " in + *" $deplib "*) ;; + * ) func_append new_inherited_linker_flags " $deplib" ;; + esac + fi + fi + continue + ;; + -l*) + if test "$linkmode" != lib && test "$linkmode" != prog; then + func_warning "\`-l' is ignored for archives/objects" + continue + fi + func_stripname '-l' '' "$deplib" + name=$func_stripname_result + if test "$linkmode" = lib; then + searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" + else + searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" + fi + for searchdir in $searchdirs; do + for search_ext in .la $std_shrext .so .a; do + # Search the libtool library + lib="$searchdir/lib${name}${search_ext}" + if test -f "$lib"; then + if test "$search_ext" = ".la"; then + found=yes + else + found=no + fi + break 2 + fi + done + done + if test "$found" != yes; then + # deplib doesn't seem to be a libtool library + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" + fi + continue + else # deplib is a libtool library + # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, + # We need to do some special things here, and not later. + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + case " $predeps $postdeps " in + *" $deplib "*) + if func_lalib_p "$lib"; then + library_names= + old_library= + func_source "$lib" + for l in $old_library $library_names; do + ll="$l" + done + if test "X$ll" = "X$old_library" ; then # only static version available + found=no + func_dirname "$lib" "" "." + ladir="$func_dirname_result" + lib=$ladir/$old_library + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" + fi + continue + fi + fi + ;; + *) ;; + esac + fi + fi + ;; # -l + *.ltframework) + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + if test "$linkmode" = lib ; then + case "$new_inherited_linker_flags " in + *" $deplib "*) ;; + * ) func_append new_inherited_linker_flags " $deplib" ;; + esac + fi + fi + continue + ;; + -L*) + case $linkmode in + lib) + deplibs="$deplib $deplibs" + test "$pass" = conv && continue + newdependency_libs="$deplib $newdependency_libs" + func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + prog) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + continue + fi + if test "$pass" = scan; then + deplibs="$deplib $deplibs" + else + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + fi + func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + *) + func_warning "\`-L' is ignored for archives/objects" + ;; + esac # linkmode + continue + ;; # -L + -R*) + if test "$pass" = link; then + func_stripname '-R' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + dir=$func_resolve_sysroot_result + # Make sure the xrpath contains only unique directories. + case "$xrpath " in + *" $dir "*) ;; + *) func_append xrpath " $dir" ;; + esac + fi + deplibs="$deplib $deplibs" + continue + ;; + *.la) + func_resolve_sysroot "$deplib" + lib=$func_resolve_sysroot_result + ;; + *.$libext) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + continue + fi + case $linkmode in + lib) + # Linking convenience modules into shared libraries is allowed, + # but linking other static libraries is non-portable. + case " $dlpreconveniencelibs " in + *" $deplib "*) ;; + *) + valid_a_lib=no + case $deplibs_check_method in + match_pattern*) + set dummy $deplibs_check_method; shift + match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` + if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ + | $EGREP "$match_pattern_regex" > /dev/null; then + valid_a_lib=yes + fi + ;; + pass_all) + valid_a_lib=yes + ;; + esac + if test "$valid_a_lib" != yes; then + echo + $ECHO "*** Warning: Trying to link with static lib archive $deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because the file extensions .$libext of this argument makes me believe" + echo "*** that it is just a static archive that I should not use here." + else + echo + $ECHO "*** Warning: Linking the shared library $output against the" + $ECHO "*** static library $deplib is not portable!" + deplibs="$deplib $deplibs" + fi + ;; + esac + continue + ;; + prog) + if test "$pass" != link; then + deplibs="$deplib $deplibs" + else + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + fi + continue + ;; + esac # linkmode + ;; # *.$libext + *.lo | *.$objext) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + elif test "$linkmode" = prog; then + if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then + # If there is no dlopen support or we're linking statically, + # we need to preload. + func_append newdlprefiles " $deplib" + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + func_append newdlfiles " $deplib" + fi + fi + continue + ;; + %DEPLIBS%) + alldeplibs=yes + continue + ;; + esac # case $deplib + + if test "$found" = yes || test -f "$lib"; then : + else + func_fatal_error "cannot find the library \`$lib' or unhandled argument \`$deplib'" + fi + + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$lib" \ + || func_fatal_error "\`$lib' is not a valid libtool archive" + + func_dirname "$lib" "" "." + ladir="$func_dirname_result" + + dlname= + dlopen= + dlpreopen= + libdir= + library_names= + old_library= + inherited_linker_flags= + # If the library was installed with an old release of libtool, + # it will not redefine variables installed, or shouldnotlink + installed=yes + shouldnotlink=no + avoidtemprpath= + + + # Read the .la file + func_source "$lib" + + # Convert "-framework foo" to "foo.ltframework" + if test -n "$inherited_linker_flags"; then + tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'` + for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do + case " $new_inherited_linker_flags " in + *" $tmp_inherited_linker_flag "*) ;; + *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; + esac + done + fi + dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + if test "$linkmode,$pass" = "lib,link" || + test "$linkmode,$pass" = "prog,scan" || + { test "$linkmode" != prog && test "$linkmode" != lib; }; then + test -n "$dlopen" && func_append dlfiles " $dlopen" + test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" + fi + + if test "$pass" = conv; then + # Only check for convenience libraries + deplibs="$lib $deplibs" + if test -z "$libdir"; then + if test -z "$old_library"; then + func_fatal_error "cannot find name of link library for \`$lib'" + fi + # It is a libtool convenience library, so add in its objects. + func_append convenience " $ladir/$objdir/$old_library" + func_append old_convenience " $ladir/$objdir/$old_library" + tmp_libs= + for deplib in $dependency_libs; do + deplibs="$deplib $deplibs" + if $opt_preserve_dup_deps ; then + case "$tmp_libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append tmp_libs " $deplib" + done + elif test "$linkmode" != prog && test "$linkmode" != lib; then + func_fatal_error "\`$lib' is not a convenience library" + fi + continue + fi # $pass = conv + + + # Get the name of the library we link against. + linklib= + if test -n "$old_library" && + { test "$prefer_static_libs" = yes || + test "$prefer_static_libs,$installed" = "built,no"; }; then + linklib=$old_library + else + for l in $old_library $library_names; do + linklib="$l" + done + fi + if test -z "$linklib"; then + func_fatal_error "cannot find name of link library for \`$lib'" + fi + + # This library was specified with -dlopen. + if test "$pass" = dlopen; then + if test -z "$libdir"; then + func_fatal_error "cannot -dlopen a convenience library: \`$lib'" + fi + if test -z "$dlname" || + test "$dlopen_support" != yes || + test "$build_libtool_libs" = no; then + # If there is no dlname, no dlopen support or we're linking + # statically, we need to preload. We also need to preload any + # dependent libraries so libltdl's deplib preloader doesn't + # bomb out in the load deplibs phase. + func_append dlprefiles " $lib $dependency_libs" + else + func_append newdlfiles " $lib" + fi + continue + fi # $pass = dlopen + + # We need an absolute path. + case $ladir in + [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; + *) + abs_ladir=`cd "$ladir" && pwd` + if test -z "$abs_ladir"; then + func_warning "cannot determine absolute directory name of \`$ladir'" + func_warning "passing it literally to the linker, although it might fail" + abs_ladir="$ladir" + fi + ;; + esac + func_basename "$lib" + laname="$func_basename_result" + + # Find the relevant object directory and library name. + if test "X$installed" = Xyes; then + if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then + func_warning "library \`$lib' was moved." + dir="$ladir" + absdir="$abs_ladir" + libdir="$abs_ladir" + else + dir="$lt_sysroot$libdir" + absdir="$lt_sysroot$libdir" + fi + test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes + else + if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then + dir="$ladir" + absdir="$abs_ladir" + # Remove this search path later + func_append notinst_path " $abs_ladir" + else + dir="$ladir/$objdir" + absdir="$abs_ladir/$objdir" + # Remove this search path later + func_append notinst_path " $abs_ladir" + fi + fi # $installed = yes + func_stripname 'lib' '.la' "$laname" + name=$func_stripname_result + + # This library was specified with -dlpreopen. + if test "$pass" = dlpreopen; then + if test -z "$libdir" && test "$linkmode" = prog; then + func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'" + fi + case "$host" in + # special handling for platforms with PE-DLLs. + *cygwin* | *mingw* | *cegcc* ) + # Linker will automatically link against shared library if both + # static and shared are present. Therefore, ensure we extract + # symbols from the import library if a shared library is present + # (otherwise, the dlopen module name will be incorrect). We do + # this by putting the import library name into $newdlprefiles. + # We recover the dlopen module name by 'saving' the la file + # name in a special purpose variable, and (later) extracting the + # dlname from the la file. + if test -n "$dlname"; then + func_tr_sh "$dir/$linklib" + eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" + func_append newdlprefiles " $dir/$linklib" + else + func_append newdlprefiles " $dir/$old_library" + # Keep a list of preopened convenience libraries to check + # that they are being used correctly in the link pass. + test -z "$libdir" && \ + func_append dlpreconveniencelibs " $dir/$old_library" + fi + ;; + * ) + # Prefer using a static library (so that no silly _DYNAMIC symbols + # are required to link). + if test -n "$old_library"; then + func_append newdlprefiles " $dir/$old_library" + # Keep a list of preopened convenience libraries to check + # that they are being used correctly in the link pass. + test -z "$libdir" && \ + func_append dlpreconveniencelibs " $dir/$old_library" + # Otherwise, use the dlname, so that lt_dlopen finds it. + elif test -n "$dlname"; then + func_append newdlprefiles " $dir/$dlname" + else + func_append newdlprefiles " $dir/$linklib" + fi + ;; + esac + fi # $pass = dlpreopen + + if test -z "$libdir"; then + # Link the convenience library + if test "$linkmode" = lib; then + deplibs="$dir/$old_library $deplibs" + elif test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$dir/$old_library $compile_deplibs" + finalize_deplibs="$dir/$old_library $finalize_deplibs" + else + deplibs="$lib $deplibs" # used for prog,scan pass + fi + continue + fi + + + if test "$linkmode" = prog && test "$pass" != link; then + func_append newlib_search_path " $ladir" + deplibs="$lib $deplibs" + + linkalldeplibs=no + if test "$link_all_deplibs" != no || test -z "$library_names" || + test "$build_libtool_libs" = no; then + linkalldeplibs=yes + fi + + tmp_libs= + for deplib in $dependency_libs; do + case $deplib in + -L*) func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + esac + # Need to link against all dependency_libs? + if test "$linkalldeplibs" = yes; then + deplibs="$deplib $deplibs" + else + # Need to hardcode shared library paths + # or/and link against static libraries + newdependency_libs="$deplib $newdependency_libs" + fi + if $opt_preserve_dup_deps ; then + case "$tmp_libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append tmp_libs " $deplib" + done # for deplib + continue + fi # $linkmode = prog... + + if test "$linkmode,$pass" = "prog,link"; then + if test -n "$library_names" && + { { test "$prefer_static_libs" = no || + test "$prefer_static_libs,$installed" = "built,yes"; } || + test -z "$old_library"; }; then + # We need to hardcode the library path + if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then + # Make sure the rpath contains only unique directories. + case "$temp_rpath:" in + *"$absdir:"*) ;; + *) func_append temp_rpath "$absdir:" ;; + esac + fi + + # Hardcode the library path. + # Skip directories that are in the system default run-time + # search path. + case " $sys_lib_dlsearch_path " in + *" $absdir "*) ;; + *) + case "$compile_rpath " in + *" $absdir "*) ;; + *) func_append compile_rpath " $absdir" ;; + esac + ;; + esac + case " $sys_lib_dlsearch_path " in + *" $libdir "*) ;; + *) + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + ;; + esac + fi # $linkmode,$pass = prog,link... + + if test "$alldeplibs" = yes && + { test "$deplibs_check_method" = pass_all || + { test "$build_libtool_libs" = yes && + test -n "$library_names"; }; }; then + # We only need to search for static libraries + continue + fi + fi + + link_static=no # Whether the deplib will be linked statically + use_static_libs=$prefer_static_libs + if test "$use_static_libs" = built && test "$installed" = yes; then + use_static_libs=no + fi + if test -n "$library_names" && + { test "$use_static_libs" = no || test -z "$old_library"; }; then + case $host in + *cygwin* | *mingw* | *cegcc*) + # No point in relinking DLLs because paths are not encoded + func_append notinst_deplibs " $lib" + need_relink=no + ;; + *) + if test "$installed" = no; then + func_append notinst_deplibs " $lib" + need_relink=yes + fi + ;; + esac + # This is a shared library + + # Warn about portability, can't link against -module's on some + # systems (darwin). Don't bleat about dlopened modules though! + dlopenmodule="" + for dlpremoduletest in $dlprefiles; do + if test "X$dlpremoduletest" = "X$lib"; then + dlopenmodule="$dlpremoduletest" + break + fi + done + if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then + echo + if test "$linkmode" = prog; then + $ECHO "*** Warning: Linking the executable $output against the loadable module" + else + $ECHO "*** Warning: Linking the shared library $output against the loadable module" + fi + $ECHO "*** $linklib is not portable!" + fi + if test "$linkmode" = lib && + test "$hardcode_into_libs" = yes; then + # Hardcode the library path. + # Skip directories that are in the system default run-time + # search path. + case " $sys_lib_dlsearch_path " in + *" $absdir "*) ;; + *) + case "$compile_rpath " in + *" $absdir "*) ;; + *) func_append compile_rpath " $absdir" ;; + esac + ;; + esac + case " $sys_lib_dlsearch_path " in + *" $libdir "*) ;; + *) + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + ;; + esac + fi + + if test -n "$old_archive_from_expsyms_cmds"; then + # figure out the soname + set dummy $library_names + shift + realname="$1" + shift + libname=`eval "\\$ECHO \"$libname_spec\""` + # use dlname if we got it. it's perfectly good, no? + if test -n "$dlname"; then + soname="$dlname" + elif test -n "$soname_spec"; then + # bleh windows + case $host in + *cygwin* | mingw* | *cegcc*) + func_arith $current - $age + major=$func_arith_result + versuffix="-$major" + ;; + esac + eval soname=\"$soname_spec\" + else + soname="$realname" + fi + + # Make a new name for the extract_expsyms_cmds to use + soroot="$soname" + func_basename "$soroot" + soname="$func_basename_result" + func_stripname 'lib' '.dll' "$soname" + newlib=libimp-$func_stripname_result.a + + # If the library has no export list, then create one now + if test -f "$output_objdir/$soname-def"; then : + else + func_verbose "extracting exported symbol list from \`$soname'" + func_execute_cmds "$extract_expsyms_cmds" 'exit $?' + fi + + # Create $newlib + if test -f "$output_objdir/$newlib"; then :; else + func_verbose "generating import library for \`$soname'" + func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' + fi + # make sure the library variables are pointing to the new library + dir=$output_objdir + linklib=$newlib + fi # test -n "$old_archive_from_expsyms_cmds" + + if test "$linkmode" = prog || test "$opt_mode" != relink; then + add_shlibpath= + add_dir= + add= + lib_linked=yes + case $hardcode_action in + immediate | unsupported) + if test "$hardcode_direct" = no; then + add="$dir/$linklib" + case $host in + *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; + *-*-sysv4*uw2*) add_dir="-L$dir" ;; + *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ + *-*-unixware7*) add_dir="-L$dir" ;; + *-*-darwin* ) + # if the lib is a (non-dlopened) module then we can not + # link against it, someone is ignoring the earlier warnings + if /usr/bin/file -L $add 2> /dev/null | + $GREP ": [^:]* bundle" >/dev/null ; then + if test "X$dlopenmodule" != "X$lib"; then + $ECHO "*** Warning: lib $linklib is a module, not a shared library" + if test -z "$old_library" ; then + echo + echo "*** And there doesn't seem to be a static archive available" + echo "*** The link will probably fail, sorry" + else + add="$dir/$old_library" + fi + elif test -n "$old_library"; then + add="$dir/$old_library" + fi + fi + esac + elif test "$hardcode_minus_L" = no; then + case $host in + *-*-sunos*) add_shlibpath="$dir" ;; + esac + add_dir="-L$dir" + add="-l$name" + elif test "$hardcode_shlibpath_var" = no; then + add_shlibpath="$dir" + add="-l$name" + else + lib_linked=no + fi + ;; + relink) + if test "$hardcode_direct" = yes && + test "$hardcode_direct_absolute" = no; then + add="$dir/$linklib" + elif test "$hardcode_minus_L" = yes; then + add_dir="-L$absdir" + # Try looking first in the location we're being installed to. + if test -n "$inst_prefix_dir"; then + case $libdir in + [\\/]*) + func_append add_dir " -L$inst_prefix_dir$libdir" + ;; + esac + fi + add="-l$name" + elif test "$hardcode_shlibpath_var" = yes; then + add_shlibpath="$dir" + add="-l$name" + else + lib_linked=no + fi + ;; + *) lib_linked=no ;; + esac + + if test "$lib_linked" != yes; then + func_fatal_configuration "unsupported hardcode properties" + fi + + if test -n "$add_shlibpath"; then + case :$compile_shlibpath: in + *":$add_shlibpath:"*) ;; + *) func_append compile_shlibpath "$add_shlibpath:" ;; + esac + fi + if test "$linkmode" = prog; then + test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" + test -n "$add" && compile_deplibs="$add $compile_deplibs" + else + test -n "$add_dir" && deplibs="$add_dir $deplibs" + test -n "$add" && deplibs="$add $deplibs" + if test "$hardcode_direct" != yes && + test "$hardcode_minus_L" != yes && + test "$hardcode_shlibpath_var" = yes; then + case :$finalize_shlibpath: in + *":$libdir:"*) ;; + *) func_append finalize_shlibpath "$libdir:" ;; + esac + fi + fi + fi + + if test "$linkmode" = prog || test "$opt_mode" = relink; then + add_shlibpath= + add_dir= + add= + # Finalize command for both is simple: just hardcode it. + if test "$hardcode_direct" = yes && + test "$hardcode_direct_absolute" = no; then + add="$libdir/$linklib" + elif test "$hardcode_minus_L" = yes; then + add_dir="-L$libdir" + add="-l$name" + elif test "$hardcode_shlibpath_var" = yes; then + case :$finalize_shlibpath: in + *":$libdir:"*) ;; + *) func_append finalize_shlibpath "$libdir:" ;; + esac + add="-l$name" + elif test "$hardcode_automatic" = yes; then + if test -n "$inst_prefix_dir" && + test -f "$inst_prefix_dir$libdir/$linklib" ; then + add="$inst_prefix_dir$libdir/$linklib" + else + add="$libdir/$linklib" + fi + else + # We cannot seem to hardcode it, guess we'll fake it. + add_dir="-L$libdir" + # Try looking first in the location we're being installed to. + if test -n "$inst_prefix_dir"; then + case $libdir in + [\\/]*) + func_append add_dir " -L$inst_prefix_dir$libdir" + ;; + esac + fi + add="-l$name" + fi + + if test "$linkmode" = prog; then + test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" + test -n "$add" && finalize_deplibs="$add $finalize_deplibs" + else + test -n "$add_dir" && deplibs="$add_dir $deplibs" + test -n "$add" && deplibs="$add $deplibs" + fi + fi + elif test "$linkmode" = prog; then + # Here we assume that one of hardcode_direct or hardcode_minus_L + # is not unsupported. This is valid on all known static and + # shared platforms. + if test "$hardcode_direct" != unsupported; then + test -n "$old_library" && linklib="$old_library" + compile_deplibs="$dir/$linklib $compile_deplibs" + finalize_deplibs="$dir/$linklib $finalize_deplibs" + else + compile_deplibs="-l$name -L$dir $compile_deplibs" + finalize_deplibs="-l$name -L$dir $finalize_deplibs" + fi + elif test "$build_libtool_libs" = yes; then + # Not a shared library + if test "$deplibs_check_method" != pass_all; then + # We're trying link a shared library against a static one + # but the system doesn't support it. + + # Just print a warning and add the library to dependency_libs so + # that the program can be linked against the static library. + echo + $ECHO "*** Warning: This system can not link to static lib archive $lib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have." + if test "$module" = yes; then + echo "*** But as you try to build a module library, libtool will still create " + echo "*** a static module, that should work as long as the dlopening application" + echo "*** is linked with the -dlopen flag to resolve symbols at runtime." + if test -z "$global_symbol_pipe"; then + echo + echo "*** However, this would only work if libtool was able to extract symbol" + echo "*** lists from a program, using \`nm' or equivalent, but libtool could" + echo "*** not find such a program. So, this module is probably useless." + echo "*** \`nm' from GNU binutils and a full rebuild may help." + fi + if test "$build_old_libs" = no; then + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + fi + else + deplibs="$dir/$old_library $deplibs" + link_static=yes + fi + fi # link shared/static library? + + if test "$linkmode" = lib; then + if test -n "$dependency_libs" && + { test "$hardcode_into_libs" != yes || + test "$build_old_libs" = yes || + test "$link_static" = yes; }; then + # Extract -R from dependency_libs + temp_deplibs= + for libdir in $dependency_libs; do + case $libdir in + -R*) func_stripname '-R' '' "$libdir" + temp_xrpath=$func_stripname_result + case " $xrpath " in + *" $temp_xrpath "*) ;; + *) func_append xrpath " $temp_xrpath";; + esac;; + *) func_append temp_deplibs " $libdir";; + esac + done + dependency_libs="$temp_deplibs" + fi + + func_append newlib_search_path " $absdir" + # Link against this library + test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" + # ... and its dependency_libs + tmp_libs= + for deplib in $dependency_libs; do + newdependency_libs="$deplib $newdependency_libs" + case $deplib in + -L*) func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result";; + *) func_resolve_sysroot "$deplib" ;; + esac + if $opt_preserve_dup_deps ; then + case "$tmp_libs " in + *" $func_resolve_sysroot_result "*) + func_append specialdeplibs " $func_resolve_sysroot_result" ;; + esac + fi + func_append tmp_libs " $func_resolve_sysroot_result" + done + + if test "$link_all_deplibs" != no; then + # Add the search paths of all dependency libraries + for deplib in $dependency_libs; do + path= + case $deplib in + -L*) path="$deplib" ;; + *.la) + func_resolve_sysroot "$deplib" + deplib=$func_resolve_sysroot_result + func_dirname "$deplib" "" "." + dir=$func_dirname_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; + *) + absdir=`cd "$dir" && pwd` + if test -z "$absdir"; then + func_warning "cannot determine absolute directory name of \`$dir'" + absdir="$dir" + fi + ;; + esac + if $GREP "^installed=no" $deplib > /dev/null; then + case $host in + *-*-darwin*) + depdepl= + eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` + if test -n "$deplibrary_names" ; then + for tmp in $deplibrary_names ; do + depdepl=$tmp + done + if test -f "$absdir/$objdir/$depdepl" ; then + depdepl="$absdir/$objdir/$depdepl" + darwin_install_name=`${OTOOL} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` + if test -z "$darwin_install_name"; then + darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` + fi + func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}" + func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}" + path= + fi + fi + ;; + *) + path="-L$absdir/$objdir" + ;; + esac + else + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` + test -z "$libdir" && \ + func_fatal_error "\`$deplib' is not a valid libtool archive" + test "$absdir" != "$libdir" && \ + func_warning "\`$deplib' seems to be moved" + + path="-L$absdir" + fi + ;; + esac + case " $deplibs " in + *" $path "*) ;; + *) deplibs="$path $deplibs" ;; + esac + done + fi # link_all_deplibs != no + fi # linkmode = lib + done # for deplib in $libs + if test "$pass" = link; then + if test "$linkmode" = "prog"; then + compile_deplibs="$new_inherited_linker_flags $compile_deplibs" + finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" + else + compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + fi + fi + dependency_libs="$newdependency_libs" + if test "$pass" = dlpreopen; then + # Link the dlpreopened libraries before other libraries + for deplib in $save_deplibs; do + deplibs="$deplib $deplibs" + done + fi + if test "$pass" != dlopen; then + if test "$pass" != conv; then + # Make sure lib_search_path contains only unique directories. + lib_search_path= + for dir in $newlib_search_path; do + case "$lib_search_path " in + *" $dir "*) ;; + *) func_append lib_search_path " $dir" ;; + esac + done + newlib_search_path= + fi + + if test "$linkmode,$pass" != "prog,link"; then + vars="deplibs" + else + vars="compile_deplibs finalize_deplibs" + fi + for var in $vars dependency_libs; do + # Add libraries to $var in reverse order + eval tmp_libs=\"\$$var\" + new_libs= + for deplib in $tmp_libs; do + # FIXME: Pedantically, this is the right thing to do, so + # that some nasty dependency loop isn't accidentally + # broken: + #new_libs="$deplib $new_libs" + # Pragmatically, this seems to cause very few problems in + # practice: + case $deplib in + -L*) new_libs="$deplib $new_libs" ;; + -R*) ;; + *) + # And here is the reason: when a library appears more + # than once as an explicit dependence of a library, or + # is implicitly linked in more than once by the + # compiler, it is considered special, and multiple + # occurrences thereof are not removed. Compare this + # with having the same library being listed as a + # dependency of multiple other libraries: in this case, + # we know (pedantically, we assume) the library does not + # need to be listed more than once, so we keep only the + # last copy. This is not always right, but it is rare + # enough that we require users that really mean to play + # such unportable linking tricks to link the library + # using -Wl,-lname, so that libtool does not consider it + # for duplicate removal. + case " $specialdeplibs " in + *" $deplib "*) new_libs="$deplib $new_libs" ;; + *) + case " $new_libs " in + *" $deplib "*) ;; + *) new_libs="$deplib $new_libs" ;; + esac + ;; + esac + ;; + esac + done + tmp_libs= + for deplib in $new_libs; do + case $deplib in + -L*) + case " $tmp_libs " in + *" $deplib "*) ;; + *) func_append tmp_libs " $deplib" ;; + esac + ;; + *) func_append tmp_libs " $deplib" ;; + esac + done + eval $var=\"$tmp_libs\" + done # for var + fi + # Last step: remove runtime libs from dependency_libs + # (they stay in deplibs) + tmp_libs= + for i in $dependency_libs ; do + case " $predeps $postdeps $compiler_lib_search_path " in + *" $i "*) + i="" + ;; + esac + if test -n "$i" ; then + func_append tmp_libs " $i" + fi + done + dependency_libs=$tmp_libs + done # for pass + if test "$linkmode" = prog; then + dlfiles="$newdlfiles" + fi + if test "$linkmode" = prog || test "$linkmode" = lib; then + dlprefiles="$newdlprefiles" + fi + + case $linkmode in + oldlib) + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + func_warning "\`-dlopen' is ignored for archives" + fi + + case " $deplibs" in + *\ -l* | *\ -L*) + func_warning "\`-l' and \`-L' are ignored for archives" ;; + esac + + test -n "$rpath" && \ + func_warning "\`-rpath' is ignored for archives" + + test -n "$xrpath" && \ + func_warning "\`-R' is ignored for archives" + + test -n "$vinfo" && \ + func_warning "\`-version-info/-version-number' is ignored for archives" + + test -n "$release" && \ + func_warning "\`-release' is ignored for archives" + + test -n "$export_symbols$export_symbols_regex" && \ + func_warning "\`-export-symbols' is ignored for archives" + + # Now set the variables for building old libraries. + build_libtool_libs=no + oldlibs="$output" + func_append objs "$old_deplibs" + ;; + + lib) + # Make sure we only generate libraries of the form `libNAME.la'. + case $outputname in + lib*) + func_stripname 'lib' '.la' "$outputname" + name=$func_stripname_result + eval shared_ext=\"$shrext_cmds\" + eval libname=\"$libname_spec\" + ;; + *) + test "$module" = no && \ + func_fatal_help "libtool library \`$output' must begin with \`lib'" + + if test "$need_lib_prefix" != no; then + # Add the "lib" prefix for modules if required + func_stripname '' '.la' "$outputname" + name=$func_stripname_result + eval shared_ext=\"$shrext_cmds\" + eval libname=\"$libname_spec\" + else + func_stripname '' '.la' "$outputname" + libname=$func_stripname_result + fi + ;; + esac + + if test -n "$objs"; then + if test "$deplibs_check_method" != pass_all; then + func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs" + else + echo + $ECHO "*** Warning: Linking the shared library $output against the non-libtool" + $ECHO "*** objects $objs is not portable!" + func_append libobjs " $objs" + fi + fi + + test "$dlself" != no && \ + func_warning "\`-dlopen self' is ignored for libtool libraries" + + set dummy $rpath + shift + test "$#" -gt 1 && \ + func_warning "ignoring multiple \`-rpath's for a libtool library" + + install_libdir="$1" + + oldlibs= + if test -z "$rpath"; then + if test "$build_libtool_libs" = yes; then + # Building a libtool convenience library. + # Some compilers have problems with a `.al' extension so + # convenience libraries should have the same extension an + # archive normally would. + oldlibs="$output_objdir/$libname.$libext $oldlibs" + build_libtool_libs=convenience + build_old_libs=yes + fi + + test -n "$vinfo" && \ + func_warning "\`-version-info/-version-number' is ignored for convenience libraries" + + test -n "$release" && \ + func_warning "\`-release' is ignored for convenience libraries" + else + + # Parse the version information argument. + save_ifs="$IFS"; IFS=':' + set dummy $vinfo 0 0 0 + shift + IFS="$save_ifs" + + test -n "$7" && \ + func_fatal_help "too many parameters to \`-version-info'" + + # convert absolute version numbers to libtool ages + # this retains compatibility with .la files and attempts + # to make the code below a bit more comprehensible + + case $vinfo_number in + yes) + number_major="$1" + number_minor="$2" + number_revision="$3" + # + # There are really only two kinds -- those that + # use the current revision as the major version + # and those that subtract age and use age as + # a minor version. But, then there is irix + # which has an extra 1 added just for fun + # + case $version_type in + # correct linux to gnu/linux during the next big refactor + darwin|linux|osf|windows|none) + func_arith $number_major + $number_minor + current=$func_arith_result + age="$number_minor" + revision="$number_revision" + ;; + freebsd-aout|freebsd-elf|qnx|sunos) + current="$number_major" + revision="$number_minor" + age="0" + ;; + irix|nonstopux) + func_arith $number_major + $number_minor + current=$func_arith_result + age="$number_minor" + revision="$number_minor" + lt_irix_increment=no + ;; + *) + func_fatal_configuration "$modename: unknown library version type \`$version_type'" + ;; + esac + ;; + no) + current="$1" + revision="$2" + age="$3" + ;; + esac + + # Check that each of the things are valid numbers. + case $current in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "CURRENT \`$current' must be a nonnegative integer" + func_fatal_error "\`$vinfo' is not valid version information" + ;; + esac + + case $revision in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "REVISION \`$revision' must be a nonnegative integer" + func_fatal_error "\`$vinfo' is not valid version information" + ;; + esac + + case $age in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "AGE \`$age' must be a nonnegative integer" + func_fatal_error "\`$vinfo' is not valid version information" + ;; + esac + + if test "$age" -gt "$current"; then + func_error "AGE \`$age' is greater than the current interface number \`$current'" + func_fatal_error "\`$vinfo' is not valid version information" + fi + + # Calculate the version variables. + major= + versuffix= + verstring= + case $version_type in + none) ;; + + darwin) + # Like Linux, but with the current version available in + # verstring for coding it into the library header + func_arith $current - $age + major=.$func_arith_result + versuffix="$major.$age.$revision" + # Darwin ld doesn't like 0 for these options... + func_arith $current + 1 + minor_current=$func_arith_result + xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision" + verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" + ;; + + freebsd-aout) + major=".$current" + versuffix=".$current.$revision"; + ;; + + freebsd-elf) + major=".$current" + versuffix=".$current" + ;; + + irix | nonstopux) + if test "X$lt_irix_increment" = "Xno"; then + func_arith $current - $age + else + func_arith $current - $age + 1 + fi + major=$func_arith_result + + case $version_type in + nonstopux) verstring_prefix=nonstopux ;; + *) verstring_prefix=sgi ;; + esac + verstring="$verstring_prefix$major.$revision" + + # Add in all the interfaces that we are compatible with. + loop=$revision + while test "$loop" -ne 0; do + func_arith $revision - $loop + iface=$func_arith_result + func_arith $loop - 1 + loop=$func_arith_result + verstring="$verstring_prefix$major.$iface:$verstring" + done + + # Before this point, $major must not contain `.'. + major=.$major + versuffix="$major.$revision" + ;; + + linux) # correct to gnu/linux during the next big refactor + func_arith $current - $age + major=.$func_arith_result + versuffix="$major.$age.$revision" + ;; + + osf) + func_arith $current - $age + major=.$func_arith_result + versuffix=".$current.$age.$revision" + verstring="$current.$age.$revision" + + # Add in all the interfaces that we are compatible with. + loop=$age + while test "$loop" -ne 0; do + func_arith $current - $loop + iface=$func_arith_result + func_arith $loop - 1 + loop=$func_arith_result + verstring="$verstring:${iface}.0" + done + + # Make executables depend on our current version. + func_append verstring ":${current}.0" + ;; + + qnx) + major=".$current" + versuffix=".$current" + ;; + + sunos) + major=".$current" + versuffix=".$current.$revision" + ;; + + windows) + # Use '-' rather than '.', since we only want one + # extension on DOS 8.3 filesystems. + func_arith $current - $age + major=$func_arith_result + versuffix="-$major" + ;; + + *) + func_fatal_configuration "unknown library version type \`$version_type'" + ;; + esac + + # Clear the version info if we defaulted, and they specified a release. + if test -z "$vinfo" && test -n "$release"; then + major= + case $version_type in + darwin) + # we can't check for "0.0" in archive_cmds due to quoting + # problems, so we reset it completely + verstring= + ;; + *) + verstring="0.0" + ;; + esac + if test "$need_version" = no; then + versuffix= + else + versuffix=".0.0" + fi + fi + + # Remove version info from name if versioning should be avoided + if test "$avoid_version" = yes && test "$need_version" = no; then + major= + versuffix= + verstring="" + fi + + # Check to see if the archive will have undefined symbols. + if test "$allow_undefined" = yes; then + if test "$allow_undefined_flag" = unsupported; then + func_warning "undefined symbols not allowed in $host shared libraries" + build_libtool_libs=no + build_old_libs=yes + fi + else + # Don't allow undefined symbols. + allow_undefined_flag="$no_undefined_flag" + fi + + fi + + func_generate_dlsyms "$libname" "$libname" "yes" + func_append libobjs " $symfileobj" + test "X$libobjs" = "X " && libobjs= + + if test "$opt_mode" != relink; then + # Remove our outputs, but don't remove object files since they + # may have been created when compiling PIC objects. + removelist= + tempremovelist=`$ECHO "$output_objdir/*"` + for p in $tempremovelist; do + case $p in + *.$objext | *.gcno) + ;; + $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) + if test "X$precious_files_regex" != "X"; then + if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 + then + continue + fi + fi + func_append removelist " $p" + ;; + *) ;; + esac + done + test -n "$removelist" && \ + func_show_eval "${RM}r \$removelist" + fi + + # Now set the variables for building old libraries. + if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then + func_append oldlibs " $output_objdir/$libname.$libext" + + # Transform .lo files to .o files. + oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP` + fi + + # Eliminate all temporary directories. + #for path in $notinst_path; do + # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` + # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` + # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"` + #done + + if test -n "$xrpath"; then + # If the user specified any rpath flags, then add them. + temp_xrpath= + for libdir in $xrpath; do + func_replace_sysroot "$libdir" + func_append temp_xrpath " -R$func_replace_sysroot_result" + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + done + if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then + dependency_libs="$temp_xrpath $dependency_libs" + fi + fi + + # Make sure dlfiles contains only unique files that won't be dlpreopened + old_dlfiles="$dlfiles" + dlfiles= + for lib in $old_dlfiles; do + case " $dlprefiles $dlfiles " in + *" $lib "*) ;; + *) func_append dlfiles " $lib" ;; + esac + done + + # Make sure dlprefiles contains only unique files + old_dlprefiles="$dlprefiles" + dlprefiles= + for lib in $old_dlprefiles; do + case "$dlprefiles " in + *" $lib "*) ;; + *) func_append dlprefiles " $lib" ;; + esac + done + + if test "$build_libtool_libs" = yes; then + if test -n "$rpath"; then + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) + # these systems don't actually have a c library (as such)! + ;; + *-*-rhapsody* | *-*-darwin1.[012]) + # Rhapsody C library is in the System framework + func_append deplibs " System.ltframework" + ;; + *-*-netbsd*) + # Don't link with libc until the a.out ld.so is fixed. + ;; + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc due to us having libc/libc_r. + ;; + *-*-sco3.2v5* | *-*-sco5v6*) + # Causes problems with __ctype + ;; + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) + # Compiler inserts libc in the correct place for threads to work + ;; + *) + # Add libc to deplibs on all other systems if necessary. + if test "$build_libtool_need_lc" = "yes"; then + func_append deplibs " -lc" + fi + ;; + esac + fi + + # Transform deplibs into only deplibs that can be linked in shared. + name_save=$name + libname_save=$libname + release_save=$release + versuffix_save=$versuffix + major_save=$major + # I'm not sure if I'm treating the release correctly. I think + # release should show up in the -l (ie -lgmp5) so we don't want to + # add it in twice. Is that correct? + release="" + versuffix="" + major="" + newdeplibs= + droppeddeps=no + case $deplibs_check_method in + pass_all) + # Don't check for shared/static. Everything works. + # This might be a little naive. We might want to check + # whether the library exists or not. But this is on + # osf3 & osf4 and I'm not really sure... Just + # implementing what was already the behavior. + newdeplibs=$deplibs + ;; + test_compile) + # This code stresses the "libraries are programs" paradigm to its + # limits. Maybe even breaks it. We compile a program, linking it + # against the deplibs as a proxy for the library. Then we can check + # whether they linked in statically or dynamically with ldd. + $opt_dry_run || $RM conftest.c + cat > conftest.c <<EOF + int main() { return 0; } +EOF + $opt_dry_run || $RM conftest + if $LTCC $LTCFLAGS -o conftest conftest.c $deplibs; then + ldd_output=`ldd conftest` + for i in $deplibs; do + case $i in + -l*) + func_stripname -l '' "$i" + name=$func_stripname_result + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + case " $predeps $postdeps " in + *" $i "*) + func_append newdeplibs " $i" + i="" + ;; + esac + fi + if test -n "$i" ; then + libname=`eval "\\$ECHO \"$libname_spec\""` + deplib_matches=`eval "\\$ECHO \"$library_names_spec\""` + set dummy $deplib_matches; shift + deplib_match=$1 + if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then + func_append newdeplibs " $i" + else + droppeddeps=yes + echo + $ECHO "*** Warning: dynamic linker does not accept needed library $i." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which I believe you do not have" + echo "*** because a test_compile did reveal that the linker did not use it for" + echo "*** its dynamic dependency list that programs get resolved with at runtime." + fi + fi + ;; + *) + func_append newdeplibs " $i" + ;; + esac + done + else + # Error occurred in the first compile. Let's try to salvage + # the situation: Compile a separate program for each library. + for i in $deplibs; do + case $i in + -l*) + func_stripname -l '' "$i" + name=$func_stripname_result + $opt_dry_run || $RM conftest + if $LTCC $LTCFLAGS -o conftest conftest.c $i; then + ldd_output=`ldd conftest` + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + case " $predeps $postdeps " in + *" $i "*) + func_append newdeplibs " $i" + i="" + ;; + esac + fi + if test -n "$i" ; then + libname=`eval "\\$ECHO \"$libname_spec\""` + deplib_matches=`eval "\\$ECHO \"$library_names_spec\""` + set dummy $deplib_matches; shift + deplib_match=$1 + if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then + func_append newdeplibs " $i" + else + droppeddeps=yes + echo + $ECHO "*** Warning: dynamic linker does not accept needed library $i." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because a test_compile did reveal that the linker did not use this one" + echo "*** as a dynamic dependency that programs can get resolved with at runtime." + fi + fi + else + droppeddeps=yes + echo + $ECHO "*** Warning! Library $i is needed by this library but I was not able to" + echo "*** make it link in! You will probably need to install it or some" + echo "*** library that it depends on before this library will be fully" + echo "*** functional. Installing it before continuing would be even better." + fi + ;; + *) + func_append newdeplibs " $i" + ;; + esac + done + fi + ;; + file_magic*) + set dummy $deplibs_check_method; shift + file_magic_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` + for a_deplib in $deplibs; do + case $a_deplib in + -l*) + func_stripname -l '' "$a_deplib" + name=$func_stripname_result + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + case " $predeps $postdeps " in + *" $a_deplib "*) + func_append newdeplibs " $a_deplib" + a_deplib="" + ;; + esac + fi + if test -n "$a_deplib" ; then + libname=`eval "\\$ECHO \"$libname_spec\""` + if test -n "$file_magic_glob"; then + libnameglob=`func_echo_all "$libname" | $SED -e $file_magic_glob` + else + libnameglob=$libname + fi + test "$want_nocaseglob" = yes && nocaseglob=`shopt -p nocaseglob` + for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do + if test "$want_nocaseglob" = yes; then + shopt -s nocaseglob + potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` + $nocaseglob + else + potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` + fi + for potent_lib in $potential_libs; do + # Follow soft links. + if ls -lLd "$potent_lib" 2>/dev/null | + $GREP " -> " >/dev/null; then + continue + fi + # The statement above tries to avoid entering an + # endless loop below, in case of cyclic links. + # We might still enter an endless loop, since a link + # loop can be closed while we follow links, + # but so what? + potlib="$potent_lib" + while test -h "$potlib" 2>/dev/null; do + potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` + case $potliblink in + [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; + *) potlib=`$ECHO "$potlib" | $SED 's,[^/]*$,,'`"$potliblink";; + esac + done + if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | + $SED -e 10q | + $EGREP "$file_magic_regex" > /dev/null; then + func_append newdeplibs " $a_deplib" + a_deplib="" + break 2 + fi + done + done + fi + if test -n "$a_deplib" ; then + droppeddeps=yes + echo + $ECHO "*** Warning: linker path does not have real file for library $a_deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because I did check the linker path looking for a file starting" + if test -z "$potlib" ; then + $ECHO "*** with $libname but no candidates were found. (...for file magic test)" + else + $ECHO "*** with $libname and none of the candidates passed a file format test" + $ECHO "*** using a file magic. Last file checked: $potlib" + fi + fi + ;; + *) + # Add a -L argument. + func_append newdeplibs " $a_deplib" + ;; + esac + done # Gone through all deplibs. + ;; + match_pattern*) + set dummy $deplibs_check_method; shift + match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` + for a_deplib in $deplibs; do + case $a_deplib in + -l*) + func_stripname -l '' "$a_deplib" + name=$func_stripname_result + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + case " $predeps $postdeps " in + *" $a_deplib "*) + func_append newdeplibs " $a_deplib" + a_deplib="" + ;; + esac + fi + if test -n "$a_deplib" ; then + libname=`eval "\\$ECHO \"$libname_spec\""` + for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do + potential_libs=`ls $i/$libname[.-]* 2>/dev/null` + for potent_lib in $potential_libs; do + potlib="$potent_lib" # see symlink-check above in file_magic test + if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ + $EGREP "$match_pattern_regex" > /dev/null; then + func_append newdeplibs " $a_deplib" + a_deplib="" + break 2 + fi + done + done + fi + if test -n "$a_deplib" ; then + droppeddeps=yes + echo + $ECHO "*** Warning: linker path does not have real file for library $a_deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because I did check the linker path looking for a file starting" + if test -z "$potlib" ; then + $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" + else + $ECHO "*** with $libname and none of the candidates passed a file format test" + $ECHO "*** using a regex pattern. Last file checked: $potlib" + fi + fi + ;; + *) + # Add a -L argument. + func_append newdeplibs " $a_deplib" + ;; + esac + done # Gone through all deplibs. + ;; + none | unknown | *) + newdeplibs="" + tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'` + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + for i in $predeps $postdeps ; do + # can't use Xsed below, because $i might contain '/' + tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s,$i,,"` + done + fi + case $tmp_deplibs in + *[!\ \ ]*) + echo + if test "X$deplibs_check_method" = "Xnone"; then + echo "*** Warning: inter-library dependencies are not supported in this platform." + else + echo "*** Warning: inter-library dependencies are not known to be supported." + fi + echo "*** All declared inter-library dependencies are being dropped." + droppeddeps=yes + ;; + esac + ;; + esac + versuffix=$versuffix_save + major=$major_save + release=$release_save + libname=$libname_save + name=$name_save + + case $host in + *-*-rhapsody* | *-*-darwin1.[012]) + # On Rhapsody replace the C library with the System framework + newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'` + ;; + esac + + if test "$droppeddeps" = yes; then + if test "$module" = yes; then + echo + echo "*** Warning: libtool could not satisfy all declared inter-library" + $ECHO "*** dependencies of module $libname. Therefore, libtool will create" + echo "*** a static module, that should work as long as the dlopening" + echo "*** application is linked with the -dlopen flag." + if test -z "$global_symbol_pipe"; then + echo + echo "*** However, this would only work if libtool was able to extract symbol" + echo "*** lists from a program, using \`nm' or equivalent, but libtool could" + echo "*** not find such a program. So, this module is probably useless." + echo "*** \`nm' from GNU binutils and a full rebuild may help." + fi + if test "$build_old_libs" = no; then + oldlibs="$output_objdir/$libname.$libext" + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + else + echo "*** The inter-library dependencies that have been dropped here will be" + echo "*** automatically added whenever a program is linked with this library" + echo "*** or is declared to -dlopen it." + + if test "$allow_undefined" = no; then + echo + echo "*** Since this library must not contain undefined symbols," + echo "*** because either the platform does not support them or" + echo "*** it was explicitly requested with -no-undefined," + echo "*** libtool will only create a static version of it." + if test "$build_old_libs" = no; then + oldlibs="$output_objdir/$libname.$libext" + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + fi + fi + fi + # Done checking deplibs! + deplibs=$newdeplibs + fi + # Time to change all our "foo.ltframework" stuff back to "-framework foo" + case $host in + *-*-darwin*) + newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + ;; + esac + + # move library search paths that coincide with paths to not yet + # installed libraries to the beginning of the library search list + new_libs= + for path in $notinst_path; do + case " $new_libs " in + *" -L$path/$objdir "*) ;; + *) + case " $deplibs " in + *" -L$path/$objdir "*) + func_append new_libs " -L$path/$objdir" ;; + esac + ;; + esac + done + for deplib in $deplibs; do + case $deplib in + -L*) + case " $new_libs " in + *" $deplib "*) ;; + *) func_append new_libs " $deplib" ;; + esac + ;; + *) func_append new_libs " $deplib" ;; + esac + done + deplibs="$new_libs" + + # All the library-specific variables (install_libdir is set above). + library_names= + old_library= + dlname= + + # Test again, we may have decided not to build it any more + if test "$build_libtool_libs" = yes; then + # Remove ${wl} instances when linking with ld. + # FIXME: should test the right _cmds variable. + case $archive_cmds in + *\$LD\ *) wl= ;; + esac + if test "$hardcode_into_libs" = yes; then + # Hardcode the library paths + hardcode_libdirs= + dep_rpath= + rpath="$finalize_rpath" + test "$opt_mode" != relink && rpath="$compile_rpath$rpath" + for libdir in $rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + func_replace_sysroot "$libdir" + libdir=$func_replace_sysroot_result + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + func_append dep_rpath " $flag" + fi + elif test -n "$runpath_var"; then + case "$perm_rpath " in + *" $libdir "*) ;; + *) func_append perm_rpath " $libdir" ;; + esac + fi + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + eval "dep_rpath=\"$hardcode_libdir_flag_spec\"" + fi + if test -n "$runpath_var" && test -n "$perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $perm_rpath; do + func_append rpath "$dir:" + done + eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" + fi + test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" + fi + + shlibpath="$finalize_shlibpath" + test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath" + if test -n "$shlibpath"; then + eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" + fi + + # Get the real and link names of the library. + eval shared_ext=\"$shrext_cmds\" + eval library_names=\"$library_names_spec\" + set dummy $library_names + shift + realname="$1" + shift + + if test -n "$soname_spec"; then + eval soname=\"$soname_spec\" + else + soname="$realname" + fi + if test -z "$dlname"; then + dlname=$soname + fi + + lib="$output_objdir/$realname" + linknames= + for link + do + func_append linknames " $link" + done + + # Use standard objects if they are pic + test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP` + test "X$libobjs" = "X " && libobjs= + + delfiles= + if test -n "$export_symbols" && test -n "$include_expsyms"; then + $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" + export_symbols="$output_objdir/$libname.uexp" + func_append delfiles " $export_symbols" + fi + + orig_export_symbols= + case $host_os in + cygwin* | mingw* | cegcc*) + if test -n "$export_symbols" && test -z "$export_symbols_regex"; then + # exporting using user supplied symfile + if test "x`$SED 1q $export_symbols`" != xEXPORTS; then + # and it's NOT already a .def file. Must figure out + # which of the given symbols are data symbols and tag + # them as such. So, trigger use of export_symbols_cmds. + # export_symbols gets reassigned inside the "prepare + # the list of exported symbols" if statement, so the + # include_expsyms logic still works. + orig_export_symbols="$export_symbols" + export_symbols= + always_export_symbols=yes + fi + fi + ;; + esac + + # Prepare the list of exported symbols + if test -z "$export_symbols"; then + if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then + func_verbose "generating symbol list for \`$libname.la'" + export_symbols="$output_objdir/$libname.exp" + $opt_dry_run || $RM $export_symbols + cmds=$export_symbols_cmds + save_ifs="$IFS"; IFS='~' + for cmd1 in $cmds; do + IFS="$save_ifs" + # Take the normal branch if the nm_file_list_spec branch + # doesn't work or if tool conversion is not needed. + case $nm_file_list_spec~$to_tool_file_cmd in + *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) + try_normal_branch=yes + eval cmd=\"$cmd1\" + func_len " $cmd" + len=$func_len_result + ;; + *) + try_normal_branch=no + ;; + esac + if test "$try_normal_branch" = yes \ + && { test "$len" -lt "$max_cmd_len" \ + || test "$max_cmd_len" -le -1; } + then + func_show_eval "$cmd" 'exit $?' + skipped_export=false + elif test -n "$nm_file_list_spec"; then + func_basename "$output" + output_la=$func_basename_result + save_libobjs=$libobjs + save_output=$output + output=${output_objdir}/${output_la}.nm + func_to_tool_file "$output" + libobjs=$nm_file_list_spec$func_to_tool_file_result + func_append delfiles " $output" + func_verbose "creating $NM input file list: $output" + for obj in $save_libobjs; do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" + done > "$output" + eval cmd=\"$cmd1\" + func_show_eval "$cmd" 'exit $?' + output=$save_output + libobjs=$save_libobjs + skipped_export=false + else + # The command line is too long to execute in one step. + func_verbose "using reloadable object file for export list..." + skipped_export=: + # Break out early, otherwise skipped_export may be + # set to false by a later but shorter cmd. + break + fi + done + IFS="$save_ifs" + if test -n "$export_symbols_regex" && test "X$skipped_export" != "X:"; then + func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' + func_show_eval '$MV "${export_symbols}T" "$export_symbols"' + fi + fi + fi + + if test -n "$export_symbols" && test -n "$include_expsyms"; then + tmp_export_symbols="$export_symbols" + test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" + $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' + fi + + if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then + # The given exports_symbols file has to be filtered, so filter it. + func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" + # FIXME: $output_objdir/$libname.filter potentially contains lots of + # 's' commands which not all seds can handle. GNU sed should be fine + # though. Also, the filter scales superlinearly with the number of + # global variables. join(1) would be nice here, but unfortunately + # isn't a blessed tool. + $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter + func_append delfiles " $export_symbols $output_objdir/$libname.filter" + export_symbols=$output_objdir/$libname.def + $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols + fi + + tmp_deplibs= + for test_deplib in $deplibs; do + case " $convenience " in + *" $test_deplib "*) ;; + *) + func_append tmp_deplibs " $test_deplib" + ;; + esac + done + deplibs="$tmp_deplibs" + + if test -n "$convenience"; then + if test -n "$whole_archive_flag_spec" && + test "$compiler_needs_object" = yes && + test -z "$libobjs"; then + # extract the archives, so we have objects to list. + # TODO: could optimize this to just extract one archive. + whole_archive_flag_spec= + fi + if test -n "$whole_archive_flag_spec"; then + save_libobjs=$libobjs + eval libobjs=\"\$libobjs $whole_archive_flag_spec\" + test "X$libobjs" = "X " && libobjs= + else + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" + + func_extract_archives $gentop $convenience + func_append libobjs " $func_extract_archives_result" + test "X$libobjs" = "X " && libobjs= + fi + fi + + if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then + eval flag=\"$thread_safe_flag_spec\" + func_append linker_flags " $flag" + fi + + # Make a backup of the uninstalled library when relinking + if test "$opt_mode" = relink; then + $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? + fi + + # Do each of the archive commands. + if test "$module" = yes && test -n "$module_cmds" ; then + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then + eval test_cmds=\"$module_expsym_cmds\" + cmds=$module_expsym_cmds + else + eval test_cmds=\"$module_cmds\" + cmds=$module_cmds + fi + else + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then + eval test_cmds=\"$archive_expsym_cmds\" + cmds=$archive_expsym_cmds + else + eval test_cmds=\"$archive_cmds\" + cmds=$archive_cmds + fi + fi + + if test "X$skipped_export" != "X:" && + func_len " $test_cmds" && + len=$func_len_result && + test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then + : + else + # The command line is too long to link in one step, link piecewise + # or, if using GNU ld and skipped_export is not :, use a linker + # script. + + # Save the value of $output and $libobjs because we want to + # use them later. If we have whole_archive_flag_spec, we + # want to use save_libobjs as it was before + # whole_archive_flag_spec was expanded, because we can't + # assume the linker understands whole_archive_flag_spec. + # This may have to be revisited, in case too many + # convenience libraries get linked in and end up exceeding + # the spec. + if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then + save_libobjs=$libobjs + fi + save_output=$output + func_basename "$output" + output_la=$func_basename_result + + # Clear the reloadable object creation command queue and + # initialize k to one. + test_cmds= + concat_cmds= + objlist= + last_robj= + k=1 + + if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then + output=${output_objdir}/${output_la}.lnkscript + func_verbose "creating GNU ld script: $output" + echo 'INPUT (' > $output + for obj in $save_libobjs + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" >> $output + done + echo ')' >> $output + func_append delfiles " $output" + func_to_tool_file "$output" + output=$func_to_tool_file_result + elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then + output=${output_objdir}/${output_la}.lnk + func_verbose "creating linker input file list: $output" + : > $output + set x $save_libobjs + shift + firstobj= + if test "$compiler_needs_object" = yes; then + firstobj="$1 " + shift + fi + for obj + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" >> $output + done + func_append delfiles " $output" + func_to_tool_file "$output" + output=$firstobj\"$file_list_spec$func_to_tool_file_result\" + else + if test -n "$save_libobjs"; then + func_verbose "creating reloadable object files..." + output=$output_objdir/$output_la-${k}.$objext + eval test_cmds=\"$reload_cmds\" + func_len " $test_cmds" + len0=$func_len_result + len=$len0 + + # Loop over the list of objects to be linked. + for obj in $save_libobjs + do + func_len " $obj" + func_arith $len + $func_len_result + len=$func_arith_result + if test "X$objlist" = X || + test "$len" -lt "$max_cmd_len"; then + func_append objlist " $obj" + else + # The command $test_cmds is almost too long, add a + # command to the queue. + if test "$k" -eq 1 ; then + # The first file doesn't have a previous command to add. + reload_objs=$objlist + eval concat_cmds=\"$reload_cmds\" + else + # All subsequent reloadable object files will link in + # the last one created. + reload_objs="$objlist $last_robj" + eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\" + fi + last_robj=$output_objdir/$output_la-${k}.$objext + func_arith $k + 1 + k=$func_arith_result + output=$output_objdir/$output_la-${k}.$objext + objlist=" $obj" + func_len " $last_robj" + func_arith $len0 + $func_len_result + len=$func_arith_result + fi + done + # Handle the remaining objects by creating one last + # reloadable object file. All subsequent reloadable object + # files will link in the last one created. + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + reload_objs="$objlist $last_robj" + eval concat_cmds=\"\${concat_cmds}$reload_cmds\" + if test -n "$last_robj"; then + eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\" + fi + func_append delfiles " $output" + + else + output= + fi + + if ${skipped_export-false}; then + func_verbose "generating symbol list for \`$libname.la'" + export_symbols="$output_objdir/$libname.exp" + $opt_dry_run || $RM $export_symbols + libobjs=$output + # Append the command to create the export file. + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" + if test -n "$last_robj"; then + eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" + fi + fi + + test -n "$save_libobjs" && + func_verbose "creating a temporary reloadable object file: $output" + + # Loop through the commands generated above and execute them. + save_ifs="$IFS"; IFS='~' + for cmd in $concat_cmds; do + IFS="$save_ifs" + $opt_silent || { + func_quote_for_expand "$cmd" + eval "func_echo $func_quote_for_expand_result" + } + $opt_dry_run || eval "$cmd" || { + lt_exit=$? + + # Restore the uninstalled library and exit + if test "$opt_mode" = relink; then + ( cd "$output_objdir" && \ + $RM "${realname}T" && \ + $MV "${realname}U" "$realname" ) + fi + + exit $lt_exit + } + done + IFS="$save_ifs" + + if test -n "$export_symbols_regex" && ${skipped_export-false}; then + func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' + func_show_eval '$MV "${export_symbols}T" "$export_symbols"' + fi + fi + + if ${skipped_export-false}; then + if test -n "$export_symbols" && test -n "$include_expsyms"; then + tmp_export_symbols="$export_symbols" + test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" + $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' + fi + + if test -n "$orig_export_symbols"; then + # The given exports_symbols file has to be filtered, so filter it. + func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" + # FIXME: $output_objdir/$libname.filter potentially contains lots of + # 's' commands which not all seds can handle. GNU sed should be fine + # though. Also, the filter scales superlinearly with the number of + # global variables. join(1) would be nice here, but unfortunately + # isn't a blessed tool. + $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter + func_append delfiles " $export_symbols $output_objdir/$libname.filter" + export_symbols=$output_objdir/$libname.def + $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols + fi + fi + + libobjs=$output + # Restore the value of output. + output=$save_output + + if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then + eval libobjs=\"\$libobjs $whole_archive_flag_spec\" + test "X$libobjs" = "X " && libobjs= + fi + # Expand the library linking commands again to reset the + # value of $libobjs for piecewise linking. + + # Do each of the archive commands. + if test "$module" = yes && test -n "$module_cmds" ; then + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then + cmds=$module_expsym_cmds + else + cmds=$module_cmds + fi + else + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then + cmds=$archive_expsym_cmds + else + cmds=$archive_cmds + fi + fi + fi + + if test -n "$delfiles"; then + # Append the command to remove temporary files to $cmds. + eval cmds=\"\$cmds~\$RM $delfiles\" + fi + + # Add any objects from preloaded convenience libraries + if test -n "$dlprefiles"; then + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" + + func_extract_archives $gentop $dlprefiles + func_append libobjs " $func_extract_archives_result" + test "X$libobjs" = "X " && libobjs= + fi + + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $opt_silent || { + func_quote_for_expand "$cmd" + eval "func_echo $func_quote_for_expand_result" + } + $opt_dry_run || eval "$cmd" || { + lt_exit=$? + + # Restore the uninstalled library and exit + if test "$opt_mode" = relink; then + ( cd "$output_objdir" && \ + $RM "${realname}T" && \ + $MV "${realname}U" "$realname" ) + fi + + exit $lt_exit + } + done + IFS="$save_ifs" + + # Restore the uninstalled library and exit + if test "$opt_mode" = relink; then + $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? + + if test -n "$convenience"; then + if test -z "$whole_archive_flag_spec"; then + func_show_eval '${RM}r "$gentop"' + fi + fi + + exit $EXIT_SUCCESS + fi + + # Create links to the real library. + for linkname in $linknames; do + if test "$realname" != "$linkname"; then + func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' + fi + done + + # If -module or -export-dynamic was specified, set the dlname. + if test "$module" = yes || test "$export_dynamic" = yes; then + # On all known operating systems, these are identical. + dlname="$soname" + fi + fi + ;; + + obj) + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + func_warning "\`-dlopen' is ignored for objects" + fi + + case " $deplibs" in + *\ -l* | *\ -L*) + func_warning "\`-l' and \`-L' are ignored for objects" ;; + esac + + test -n "$rpath" && \ + func_warning "\`-rpath' is ignored for objects" + + test -n "$xrpath" && \ + func_warning "\`-R' is ignored for objects" + + test -n "$vinfo" && \ + func_warning "\`-version-info' is ignored for objects" + + test -n "$release" && \ + func_warning "\`-release' is ignored for objects" + + case $output in + *.lo) + test -n "$objs$old_deplibs" && \ + func_fatal_error "cannot build library object \`$output' from non-libtool objects" + + libobj=$output + func_lo2o "$libobj" + obj=$func_lo2o_result + ;; + *) + libobj= + obj="$output" + ;; + esac + + # Delete the old objects. + $opt_dry_run || $RM $obj $libobj + + # Objects from convenience libraries. This assumes + # single-version convenience libraries. Whenever we create + # different ones for PIC/non-PIC, this we'll have to duplicate + # the extraction. + reload_conv_objs= + gentop= + # reload_cmds runs $LD directly, so let us get rid of + # -Wl from whole_archive_flag_spec and hope we can get by with + # turning comma into space.. + wl= + + if test -n "$convenience"; then + if test -n "$whole_archive_flag_spec"; then + eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" + reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` + else + gentop="$output_objdir/${obj}x" + func_append generated " $gentop" + + func_extract_archives $gentop $convenience + reload_conv_objs="$reload_objs $func_extract_archives_result" + fi + fi + + # If we're not building shared, we need to use non_pic_objs + test "$build_libtool_libs" != yes && libobjs="$non_pic_objects" + + # Create the old-style object. + reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test + + output="$obj" + func_execute_cmds "$reload_cmds" 'exit $?' + + # Exit if we aren't doing a library object file. + if test -z "$libobj"; then + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + exit $EXIT_SUCCESS + fi + + if test "$build_libtool_libs" != yes; then + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + # Create an invalid libtool object if no PIC, so that we don't + # accidentally link it into a program. + # $show "echo timestamp > $libobj" + # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? + exit $EXIT_SUCCESS + fi + + if test -n "$pic_flag" || test "$pic_mode" != default; then + # Only do commands if we really have different PIC objects. + reload_objs="$libobjs $reload_conv_objs" + output="$libobj" + func_execute_cmds "$reload_cmds" 'exit $?' + fi + + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + exit $EXIT_SUCCESS + ;; + + prog) + case $host in + *cygwin*) func_stripname '' '.exe' "$output" + output=$func_stripname_result.exe;; + esac + test -n "$vinfo" && \ + func_warning "\`-version-info' is ignored for programs" + + test -n "$release" && \ + func_warning "\`-release' is ignored for programs" + + test "$preload" = yes \ + && test "$dlopen_support" = unknown \ + && test "$dlopen_self" = unknown \ + && test "$dlopen_self_static" = unknown && \ + func_warning "\`LT_INIT([dlopen])' not used. Assuming no dlopen support." + + case $host in + *-*-rhapsody* | *-*-darwin1.[012]) + # On Rhapsody replace the C library is the System framework + compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` + finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` + ;; + esac + + case $host in + *-*-darwin*) + # Don't allow lazy linking, it breaks C++ global constructors + # But is supposedly fixed on 10.4 or later (yay!). + if test "$tagname" = CXX ; then + case ${MACOSX_DEPLOYMENT_TARGET-10.0} in + 10.[0123]) + func_append compile_command " ${wl}-bind_at_load" + func_append finalize_command " ${wl}-bind_at_load" + ;; + esac + fi + # Time to change all our "foo.ltframework" stuff back to "-framework foo" + compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + ;; + esac + + + # move library search paths that coincide with paths to not yet + # installed libraries to the beginning of the library search list + new_libs= + for path in $notinst_path; do + case " $new_libs " in + *" -L$path/$objdir "*) ;; + *) + case " $compile_deplibs " in + *" -L$path/$objdir "*) + func_append new_libs " -L$path/$objdir" ;; + esac + ;; + esac + done + for deplib in $compile_deplibs; do + case $deplib in + -L*) + case " $new_libs " in + *" $deplib "*) ;; + *) func_append new_libs " $deplib" ;; + esac + ;; + *) func_append new_libs " $deplib" ;; + esac + done + compile_deplibs="$new_libs" + + + func_append compile_command " $compile_deplibs" + func_append finalize_command " $finalize_deplibs" + + if test -n "$rpath$xrpath"; then + # If the user specified any rpath flags, then add them. + for libdir in $rpath $xrpath; do + # This is the magic to use -rpath. + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + done + fi + + # Now hardcode the library paths + rpath= + hardcode_libdirs= + for libdir in $compile_rpath $finalize_rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + func_append rpath " $flag" + fi + elif test -n "$runpath_var"; then + case "$perm_rpath " in + *" $libdir "*) ;; + *) func_append perm_rpath " $libdir" ;; + esac + fi + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'` + case :$dllsearchpath: in + *":$libdir:"*) ;; + ::) dllsearchpath=$libdir;; + *) func_append dllsearchpath ":$libdir";; + esac + case :$dllsearchpath: in + *":$testbindir:"*) ;; + ::) dllsearchpath=$testbindir;; + *) func_append dllsearchpath ":$testbindir";; + esac + ;; + esac + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + eval rpath=\" $hardcode_libdir_flag_spec\" + fi + compile_rpath="$rpath" + + rpath= + hardcode_libdirs= + for libdir in $finalize_rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + func_append rpath " $flag" + fi + elif test -n "$runpath_var"; then + case "$finalize_perm_rpath " in + *" $libdir "*) ;; + *) func_append finalize_perm_rpath " $libdir" ;; + esac + fi + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + eval rpath=\" $hardcode_libdir_flag_spec\" + fi + finalize_rpath="$rpath" + + if test -n "$libobjs" && test "$build_old_libs" = yes; then + # Transform all the library objects into standard objects. + compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` + finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` + fi + + func_generate_dlsyms "$outputname" "@PROGRAM@" "no" + + # template prelinking step + if test -n "$prelink_cmds"; then + func_execute_cmds "$prelink_cmds" 'exit $?' + fi + + wrappers_required=yes + case $host in + *cegcc* | *mingw32ce*) + # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. + wrappers_required=no + ;; + *cygwin* | *mingw* ) + if test "$build_libtool_libs" != yes; then + wrappers_required=no + fi + ;; + *) + if test "$need_relink" = no || test "$build_libtool_libs" != yes; then + wrappers_required=no + fi + ;; + esac + if test "$wrappers_required" = no; then + # Replace the output file specification. + compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'` + link_command="$compile_command$compile_rpath" + + # We have no uninstalled library dependencies, so finalize right now. + exit_status=0 + func_show_eval "$link_command" 'exit_status=$?' + + if test -n "$postlink_cmds"; then + func_to_tool_file "$output" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + + # Delete the generated files. + if test -f "$output_objdir/${outputname}S.${objext}"; then + func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"' + fi + + exit $exit_status + fi + + if test -n "$compile_shlibpath$finalize_shlibpath"; then + compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" + fi + if test -n "$finalize_shlibpath"; then + finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" + fi + + compile_var= + finalize_var= + if test -n "$runpath_var"; then + if test -n "$perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $perm_rpath; do + func_append rpath "$dir:" + done + compile_var="$runpath_var=\"$rpath\$$runpath_var\" " + fi + if test -n "$finalize_perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $finalize_perm_rpath; do + func_append rpath "$dir:" + done + finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " + fi + fi + + if test "$no_install" = yes; then + # We don't need to create a wrapper script. + link_command="$compile_var$compile_command$compile_rpath" + # Replace the output file specification. + link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'` + # Delete the old output file. + $opt_dry_run || $RM $output + # Link the executable and exit + func_show_eval "$link_command" 'exit $?' + + if test -n "$postlink_cmds"; then + func_to_tool_file "$output" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + + exit $EXIT_SUCCESS + fi + + if test "$hardcode_action" = relink; then + # Fast installation is not supported + link_command="$compile_var$compile_command$compile_rpath" + relink_command="$finalize_var$finalize_command$finalize_rpath" + + func_warning "this platform does not like uninstalled shared libraries" + func_warning "\`$output' will be relinked during installation" + else + if test "$fast_install" != no; then + link_command="$finalize_var$compile_command$finalize_rpath" + if test "$fast_install" = yes; then + relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` + else + # fast_install is set to needless + relink_command= + fi + else + link_command="$compile_var$compile_command$compile_rpath" + relink_command="$finalize_var$finalize_command$finalize_rpath" + fi + fi + + # Replace the output file specification. + link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` + + # Delete the old output files. + $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname + + func_show_eval "$link_command" 'exit $?' + + if test -n "$postlink_cmds"; then + func_to_tool_file "$output_objdir/$outputname" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + + # Now create the wrapper script. + func_verbose "creating $output" + + # Quote the relink command for shipping. + if test -n "$relink_command"; then + # Preserve any variables that may affect compiler behavior + for var in $variables_saved_for_relink; do + if eval test -z \"\${$var+set}\"; then + relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" + elif eval var_value=\$$var; test -z "$var_value"; then + relink_command="$var=; export $var; $relink_command" + else + func_quote_for_eval "$var_value" + relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" + fi + done + relink_command="(cd `pwd`; $relink_command)" + relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` + fi + + # Only actually do things if not in dry run mode. + $opt_dry_run || { + # win32 will think the script is a binary if it has + # a .exe suffix, so we strip it off here. + case $output in + *.exe) func_stripname '' '.exe' "$output" + output=$func_stripname_result ;; + esac + # test for cygwin because mv fails w/o .exe extensions + case $host in + *cygwin*) + exeext=.exe + func_stripname '' '.exe' "$outputname" + outputname=$func_stripname_result ;; + *) exeext= ;; + esac + case $host in + *cygwin* | *mingw* ) + func_dirname_and_basename "$output" "" "." + output_name=$func_basename_result + output_path=$func_dirname_result + cwrappersource="$output_path/$objdir/lt-$output_name.c" + cwrapper="$output_path/$output_name.exe" + $RM $cwrappersource $cwrapper + trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 + + func_emit_cwrapperexe_src > $cwrappersource + + # The wrapper executable is built using the $host compiler, + # because it contains $host paths and files. If cross- + # compiling, it, like the target executable, must be + # executed on the $host or under an emulation environment. + $opt_dry_run || { + $LTCC $LTCFLAGS -o $cwrapper $cwrappersource + $STRIP $cwrapper + } + + # Now, create the wrapper script for func_source use: + func_ltwrapper_scriptname $cwrapper + $RM $func_ltwrapper_scriptname_result + trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 + $opt_dry_run || { + # note: this script will not be executed, so do not chmod. + if test "x$build" = "x$host" ; then + $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result + else + func_emit_wrapper no > $func_ltwrapper_scriptname_result + fi + } + ;; + * ) + $RM $output + trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 + + func_emit_wrapper no > $output + chmod +x $output + ;; + esac + } + exit $EXIT_SUCCESS + ;; + esac + + # See if we need to build an old-fashioned archive. + for oldlib in $oldlibs; do + + if test "$build_libtool_libs" = convenience; then + oldobjs="$libobjs_save $symfileobj" + addlibs="$convenience" + build_libtool_libs=no + else + if test "$build_libtool_libs" = module; then + oldobjs="$libobjs_save" + build_libtool_libs=no + else + oldobjs="$old_deplibs $non_pic_objects" + if test "$preload" = yes && test -f "$symfileobj"; then + func_append oldobjs " $symfileobj" + fi + fi + addlibs="$old_convenience" + fi + + if test -n "$addlibs"; then + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" + + func_extract_archives $gentop $addlibs + func_append oldobjs " $func_extract_archives_result" + fi + + # Do each command in the archive commands. + if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then + cmds=$old_archive_from_new_cmds + else + + # Add any objects from preloaded convenience libraries + if test -n "$dlprefiles"; then + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" + + func_extract_archives $gentop $dlprefiles + func_append oldobjs " $func_extract_archives_result" + fi + + # POSIX demands no paths to be encoded in archives. We have + # to avoid creating archives with duplicate basenames if we + # might have to extract them afterwards, e.g., when creating a + # static archive out of a convenience library, or when linking + # the entirety of a libtool archive into another (currently + # not supported by libtool). + if (for obj in $oldobjs + do + func_basename "$obj" + $ECHO "$func_basename_result" + done | sort | sort -uc >/dev/null 2>&1); then + : + else + echo "copying selected object files to avoid basename conflicts..." + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" + func_mkdir_p "$gentop" + save_oldobjs=$oldobjs + oldobjs= + counter=1 + for obj in $save_oldobjs + do + func_basename "$obj" + objbase="$func_basename_result" + case " $oldobjs " in + " ") oldobjs=$obj ;; + *[\ /]"$objbase "*) + while :; do + # Make sure we don't pick an alternate name that also + # overlaps. + newobj=lt$counter-$objbase + func_arith $counter + 1 + counter=$func_arith_result + case " $oldobjs " in + *[\ /]"$newobj "*) ;; + *) if test ! -f "$gentop/$newobj"; then break; fi ;; + esac + done + func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" + func_append oldobjs " $gentop/$newobj" + ;; + *) func_append oldobjs " $obj" ;; + esac + done + fi + func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 + tool_oldlib=$func_to_tool_file_result + eval cmds=\"$old_archive_cmds\" + + func_len " $cmds" + len=$func_len_result + if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then + cmds=$old_archive_cmds + elif test -n "$archiver_list_spec"; then + func_verbose "using command file archive linking..." + for obj in $oldobjs + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" + done > $output_objdir/$libname.libcmd + func_to_tool_file "$output_objdir/$libname.libcmd" + oldobjs=" $archiver_list_spec$func_to_tool_file_result" + cmds=$old_archive_cmds + else + # the command line is too long to link in one step, link in parts + func_verbose "using piecewise archive linking..." + save_RANLIB=$RANLIB + RANLIB=: + objlist= + concat_cmds= + save_oldobjs=$oldobjs + oldobjs= + # Is there a better way of finding the last object in the list? + for obj in $save_oldobjs + do + last_oldobj=$obj + done + eval test_cmds=\"$old_archive_cmds\" + func_len " $test_cmds" + len0=$func_len_result + len=$len0 + for obj in $save_oldobjs + do + func_len " $obj" + func_arith $len + $func_len_result + len=$func_arith_result + func_append objlist " $obj" + if test "$len" -lt "$max_cmd_len"; then + : + else + # the above command should be used before it gets too long + oldobjs=$objlist + if test "$obj" = "$last_oldobj" ; then + RANLIB=$save_RANLIB + fi + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" + objlist= + len=$len0 + fi + done + RANLIB=$save_RANLIB + oldobjs=$objlist + if test "X$oldobjs" = "X" ; then + eval cmds=\"\$concat_cmds\" + else + eval cmds=\"\$concat_cmds~\$old_archive_cmds\" + fi + fi + fi + func_execute_cmds "$cmds" 'exit $?' + done + + test -n "$generated" && \ + func_show_eval "${RM}r$generated" + + # Now create the libtool archive. + case $output in + *.la) + old_library= + test "$build_old_libs" = yes && old_library="$libname.$libext" + func_verbose "creating $output" + + # Preserve any variables that may affect compiler behavior + for var in $variables_saved_for_relink; do + if eval test -z \"\${$var+set}\"; then + relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" + elif eval var_value=\$$var; test -z "$var_value"; then + relink_command="$var=; export $var; $relink_command" + else + func_quote_for_eval "$var_value" + relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" + fi + done + # Quote the link command for shipping. + relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" + relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` + if test "$hardcode_automatic" = yes ; then + relink_command= + fi + + # Only create the output if not a dry run. + $opt_dry_run || { + for installed in no yes; do + if test "$installed" = yes; then + if test -z "$install_libdir"; then + break + fi + output="$output_objdir/$outputname"i + # Replace all uninstalled libtool libraries with the installed ones + newdependency_libs= + for deplib in $dependency_libs; do + case $deplib in + *.la) + func_basename "$deplib" + name="$func_basename_result" + func_resolve_sysroot "$deplib" + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result` + test -z "$libdir" && \ + func_fatal_error "\`$deplib' is not a valid libtool archive" + func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" + ;; + -L*) + func_stripname -L '' "$deplib" + func_replace_sysroot "$func_stripname_result" + func_append newdependency_libs " -L$func_replace_sysroot_result" + ;; + -R*) + func_stripname -R '' "$deplib" + func_replace_sysroot "$func_stripname_result" + func_append newdependency_libs " -R$func_replace_sysroot_result" + ;; + *) func_append newdependency_libs " $deplib" ;; + esac + done + dependency_libs="$newdependency_libs" + newdlfiles= + + for lib in $dlfiles; do + case $lib in + *.la) + func_basename "$lib" + name="$func_basename_result" + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` + test -z "$libdir" && \ + func_fatal_error "\`$lib' is not a valid libtool archive" + func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" + ;; + *) func_append newdlfiles " $lib" ;; + esac + done + dlfiles="$newdlfiles" + newdlprefiles= + for lib in $dlprefiles; do + case $lib in + *.la) + # Only pass preopened files to the pseudo-archive (for + # eventual linking with the app. that links it) if we + # didn't already link the preopened objects directly into + # the library: + func_basename "$lib" + name="$func_basename_result" + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` + test -z "$libdir" && \ + func_fatal_error "\`$lib' is not a valid libtool archive" + func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" + ;; + esac + done + dlprefiles="$newdlprefiles" + else + newdlfiles= + for lib in $dlfiles; do + case $lib in + [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; + *) abs=`pwd`"/$lib" ;; + esac + func_append newdlfiles " $abs" + done + dlfiles="$newdlfiles" + newdlprefiles= + for lib in $dlprefiles; do + case $lib in + [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; + *) abs=`pwd`"/$lib" ;; + esac + func_append newdlprefiles " $abs" + done + dlprefiles="$newdlprefiles" + fi + $RM $output + # place dlname in correct position for cygwin + # In fact, it would be nice if we could use this code for all target + # systems that can't hard-code library paths into their executables + # and that have no shared library path variable independent of PATH, + # but it turns out we can't easily determine that from inspecting + # libtool variables, so we have to hard-code the OSs to which it + # applies here; at the moment, that means platforms that use the PE + # object format with DLL files. See the long comment at the top of + # tests/bindir.at for full details. + tdlname=$dlname + case $host,$output,$installed,$module,$dlname in + *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) + # If a -bindir argument was supplied, place the dll there. + if test "x$bindir" != x ; + then + func_relative_path "$install_libdir" "$bindir" + tdlname=$func_relative_path_result$dlname + else + # Otherwise fall back on heuristic. + tdlname=../bin/$dlname + fi + ;; + esac + $ECHO > $output "\ +# $outputname - a libtool library file +# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION +# +# Please DO NOT delete this file! +# It is necessary for linking the library. + +# The name that we can dlopen(3). +dlname='$tdlname' + +# Names of this library. +library_names='$library_names' + +# The name of the static archive. +old_library='$old_library' + +# Linker flags that can not go in dependency_libs. +inherited_linker_flags='$new_inherited_linker_flags' + +# Libraries that this one depends upon. +dependency_libs='$dependency_libs' + +# Names of additional weak libraries provided by this library +weak_library_names='$weak_libs' + +# Version information for $libname. +current=$current +age=$age +revision=$revision + +# Is this an already installed library? +installed=$installed + +# Should we warn about portability when linking against -modules? +shouldnotlink=$module + +# Files to dlopen/dlpreopen +dlopen='$dlfiles' +dlpreopen='$dlprefiles' + +# Directory that this library needs to be installed in: +libdir='$install_libdir'" + if test "$installed" = no && test "$need_relink" = yes; then + $ECHO >> $output "\ +relink_command=\"$relink_command\"" + fi + done + } + + # Do a symbolic link so that the libtool archive can be found in + # LD_LIBRARY_PATH before the program is installed. + func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' + ;; + esac + exit $EXIT_SUCCESS +} + +{ test "$opt_mode" = link || test "$opt_mode" = relink; } && + func_mode_link ${1+"$@"} + + +# func_mode_uninstall arg... +func_mode_uninstall () +{ + $opt_debug + RM="$nonopt" + files= + rmforce= + exit_status=0 + + # This variable tells wrapper scripts just to set variables rather + # than running their programs. + libtool_install_magic="$magic" + + for arg + do + case $arg in + -f) func_append RM " $arg"; rmforce=yes ;; + -*) func_append RM " $arg" ;; + *) func_append files " $arg" ;; + esac + done + + test -z "$RM" && \ + func_fatal_help "you must specify an RM program" + + rmdirs= + + for file in $files; do + func_dirname "$file" "" "." + dir="$func_dirname_result" + if test "X$dir" = X.; then + odir="$objdir" + else + odir="$dir/$objdir" + fi + func_basename "$file" + name="$func_basename_result" + test "$opt_mode" = uninstall && odir="$dir" + + # Remember odir for removal later, being careful to avoid duplicates + if test "$opt_mode" = clean; then + case " $rmdirs " in + *" $odir "*) ;; + *) func_append rmdirs " $odir" ;; + esac + fi + + # Don't error if the file doesn't exist and rm -f was used. + if { test -L "$file"; } >/dev/null 2>&1 || + { test -h "$file"; } >/dev/null 2>&1 || + test -f "$file"; then + : + elif test -d "$file"; then + exit_status=1 + continue + elif test "$rmforce" = yes; then + continue + fi + + rmfiles="$file" + + case $name in + *.la) + # Possibly a libtool archive, so verify it. + if func_lalib_p "$file"; then + func_source $dir/$name + + # Delete the libtool libraries and symlinks. + for n in $library_names; do + func_append rmfiles " $odir/$n" + done + test -n "$old_library" && func_append rmfiles " $odir/$old_library" + + case "$opt_mode" in + clean) + case " $library_names " in + *" $dlname "*) ;; + *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; + esac + test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" + ;; + uninstall) + if test -n "$library_names"; then + # Do each command in the postuninstall commands. + func_execute_cmds "$postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' + fi + + if test -n "$old_library"; then + # Do each command in the old_postuninstall commands. + func_execute_cmds "$old_postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' + fi + # FIXME: should reinstall the best remaining shared library. + ;; + esac + fi + ;; + + *.lo) + # Possibly a libtool object, so verify it. + if func_lalib_p "$file"; then + + # Read the .lo file + func_source $dir/$name + + # Add PIC object to the list of files to remove. + if test -n "$pic_object" && + test "$pic_object" != none; then + func_append rmfiles " $dir/$pic_object" + fi + + # Add non-PIC object to the list of files to remove. + if test -n "$non_pic_object" && + test "$non_pic_object" != none; then + func_append rmfiles " $dir/$non_pic_object" + fi + fi + ;; + + *) + if test "$opt_mode" = clean ; then + noexename=$name + case $file in + *.exe) + func_stripname '' '.exe' "$file" + file=$func_stripname_result + func_stripname '' '.exe' "$name" + noexename=$func_stripname_result + # $file with .exe has already been added to rmfiles, + # add $file without .exe + func_append rmfiles " $file" + ;; + esac + # Do a test to see if this is a libtool program. + if func_ltwrapper_p "$file"; then + if func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + relink_command= + func_source $func_ltwrapper_scriptname_result + func_append rmfiles " $func_ltwrapper_scriptname_result" + else + relink_command= + func_source $dir/$noexename + fi + + # note $name still contains .exe if it was in $file originally + # as does the version of $file that was added into $rmfiles + func_append rmfiles " $odir/$name $odir/${name}S.${objext}" + if test "$fast_install" = yes && test -n "$relink_command"; then + func_append rmfiles " $odir/lt-$name" + fi + if test "X$noexename" != "X$name" ; then + func_append rmfiles " $odir/lt-${noexename}.c" + fi + fi + fi + ;; + esac + func_show_eval "$RM $rmfiles" 'exit_status=1' + done + + # Try to remove the ${objdir}s in the directories where we deleted files + for dir in $rmdirs; do + if test -d "$dir"; then + func_show_eval "rmdir $dir >/dev/null 2>&1" + fi + done + + exit $exit_status +} + +{ test "$opt_mode" = uninstall || test "$opt_mode" = clean; } && + func_mode_uninstall ${1+"$@"} + +test -z "$opt_mode" && { + help="$generic_help" + func_fatal_help "you must specify a MODE" +} + +test -z "$exec_cmd" && \ + func_fatal_help "invalid operation mode \`$opt_mode'" + +if test -n "$exec_cmd"; then + eval exec "$exec_cmd" + exit $EXIT_FAILURE +fi + +exit $exit_status + + +# The TAGs below are defined such that we never get into a situation +# in which we disable both kinds of libraries. Given conflicting +# choices, we go for a static library, that is the most portable, +# since we can't tell whether shared libraries were disabled because +# the user asked for that or because the platform doesn't support +# them. This is particularly important on AIX, because we don't +# support having both static and shared libraries enabled at the same +# time on that platform, so we default to a shared-only configuration. +# If a disable-shared tag is given, we'll fallback to a static-only +# configuration. But we'll never go from static-only to shared-only. + +# ### BEGIN LIBTOOL TAG CONFIG: disable-shared +build_libtool_libs=no +build_old_libs=yes +# ### END LIBTOOL TAG CONFIG: disable-shared + +# ### BEGIN LIBTOOL TAG CONFIG: disable-static +build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` +# ### END LIBTOOL TAG CONFIG: disable-static + +# Local Variables: +# mode:shell-script +# sh-indentation:2 +# End: +# vi:sw=2 + diff --git a/resources/3rdparty/cudd-3.0.0/build-aux/missing b/resources/3rdparty/cudd-3.0.0/build-aux/missing new file mode 100755 index 000000000..db98974ff --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/build-aux/missing @@ -0,0 +1,215 @@ +#! /bin/sh +# Common wrapper for a few potentially missing GNU programs. + +scriptversion=2013-10-28.13; # UTC + +# Copyright (C) 1996-2013 Free Software Foundation, Inc. +# Originally written by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996. + +# 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. + +# 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. + +# You should have received a copy of the GNU General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +if test $# -eq 0; then + echo 1>&2 "Try '$0 --help' for more information" + exit 1 +fi + +case $1 in + + --is-lightweight) + # Used by our autoconf macros to check whether the available missing + # script is modern enough. + exit 0 + ;; + + --run) + # Back-compat with the calling convention used by older automake. + shift + ;; + + -h|--h|--he|--hel|--help) + echo "\ +$0 [OPTION]... PROGRAM [ARGUMENT]... + +Run 'PROGRAM [ARGUMENT]...', returning a proper advice when this fails due +to PROGRAM being missing or too old. + +Options: + -h, --help display this help and exit + -v, --version output version information and exit + +Supported PROGRAM values: + aclocal autoconf autoheader autom4te automake makeinfo + bison yacc flex lex help2man + +Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and +'g' are ignored when checking the name. + +Send bug reports to <bug-automake@gnu.org>." + exit $? + ;; + + -v|--v|--ve|--ver|--vers|--versi|--versio|--version) + echo "missing $scriptversion (GNU Automake)" + exit $? + ;; + + -*) + echo 1>&2 "$0: unknown '$1' option" + echo 1>&2 "Try '$0 --help' for more information" + exit 1 + ;; + +esac + +# Run the given program, remember its exit status. +"$@"; st=$? + +# If it succeeded, we are done. +test $st -eq 0 && exit 0 + +# Also exit now if we it failed (or wasn't found), and '--version' was +# passed; such an option is passed most likely to detect whether the +# program is present and works. +case $2 in --version|--help) exit $st;; esac + +# Exit code 63 means version mismatch. This often happens when the user +# tries to use an ancient version of a tool on a file that requires a +# minimum version. +if test $st -eq 63; then + msg="probably too old" +elif test $st -eq 127; then + # Program was missing. + msg="missing on your system" +else + # Program was found and executed, but failed. Give up. + exit $st +fi + +perl_URL=http://www.perl.org/ +flex_URL=http://flex.sourceforge.net/ +gnu_software_URL=http://www.gnu.org/software + +program_details () +{ + case $1 in + aclocal|automake) + echo "The '$1' program is part of the GNU Automake package:" + echo "<$gnu_software_URL/automake>" + echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:" + echo "<$gnu_software_URL/autoconf>" + echo "<$gnu_software_URL/m4/>" + echo "<$perl_URL>" + ;; + autoconf|autom4te|autoheader) + echo "The '$1' program is part of the GNU Autoconf package:" + echo "<$gnu_software_URL/autoconf/>" + echo "It also requires GNU m4 and Perl in order to run:" + echo "<$gnu_software_URL/m4/>" + echo "<$perl_URL>" + ;; + esac +} + +give_advice () +{ + # Normalize program name to check for. + normalized_program=`echo "$1" | sed ' + s/^gnu-//; t + s/^gnu//; t + s/^g//; t'` + + printf '%s\n' "'$1' is $msg." + + configure_deps="'configure.ac' or m4 files included by 'configure.ac'" + case $normalized_program in + autoconf*) + echo "You should only need it if you modified 'configure.ac'," + echo "or m4 files included by it." + program_details 'autoconf' + ;; + autoheader*) + echo "You should only need it if you modified 'acconfig.h' or" + echo "$configure_deps." + program_details 'autoheader' + ;; + automake*) + echo "You should only need it if you modified 'Makefile.am' or" + echo "$configure_deps." + program_details 'automake' + ;; + aclocal*) + echo "You should only need it if you modified 'acinclude.m4' or" + echo "$configure_deps." + program_details 'aclocal' + ;; + autom4te*) + echo "You might have modified some maintainer files that require" + echo "the 'autom4te' program to be rebuilt." + program_details 'autom4te' + ;; + bison*|yacc*) + echo "You should only need it if you modified a '.y' file." + echo "You may want to install the GNU Bison package:" + echo "<$gnu_software_URL/bison/>" + ;; + lex*|flex*) + echo "You should only need it if you modified a '.l' file." + echo "You may want to install the Fast Lexical Analyzer package:" + echo "<$flex_URL>" + ;; + help2man*) + echo "You should only need it if you modified a dependency" \ + "of a man page." + echo "You may want to install the GNU Help2man package:" + echo "<$gnu_software_URL/help2man/>" + ;; + makeinfo*) + echo "You should only need it if you modified a '.texi' file, or" + echo "any other file indirectly affecting the aspect of the manual." + echo "You might want to install the Texinfo package:" + echo "<$gnu_software_URL/texinfo/>" + echo "The spurious makeinfo call might also be the consequence of" + echo "using a buggy 'make' (AIX, DU, IRIX), in which case you might" + echo "want to install GNU make:" + echo "<$gnu_software_URL/make/>" + ;; + *) + echo "You might have modified some files without having the proper" + echo "tools for further handling them. Check the 'README' file, it" + echo "often tells you about the needed prerequisites for installing" + echo "this package. You may also peek at any GNU archive site, in" + echo "case some other package contains this missing '$1' program." + ;; + esac +} + +give_advice "$1" | sed -e '1s/^/WARNING: /' \ + -e '2,$s/^/ /' >&2 + +# Propagate the correct exit status (expected to be 127 for a program +# not found, 63 for a program that failed due to version mismatch). +exit $st + +# Local variables: +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/resources/3rdparty/cudd-3.0.0/build-aux/tap-driver.sh b/resources/3rdparty/cudd-3.0.0/build-aux/tap-driver.sh new file mode 100755 index 000000000..ee61fc112 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/build-aux/tap-driver.sh @@ -0,0 +1,651 @@ +#! /bin/sh +# Copyright (C) 2011-2013 Free Software Foundation, Inc. +# +# 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. +# +# 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. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# This file is maintained in Automake, please report +# bugs to <bug-automake@gnu.org> or send patches to +# <automake-patches@gnu.org>. + +scriptversion=2013-12-23.17; # UTC + +# Make unconditional expansion of undefined variables an error. This +# helps a lot in preventing typo-related bugs. +set -u + +me=tap-driver.sh + +fatal () +{ + echo "$me: fatal: $*" >&2 + exit 1 +} + +usage_error () +{ + echo "$me: $*" >&2 + print_usage >&2 + exit 2 +} + +print_usage () +{ + cat <<END +Usage: + tap-driver.sh --test-name=NAME --log-file=PATH --trs-file=PATH + [--expect-failure={yes|no}] [--color-tests={yes|no}] + [--enable-hard-errors={yes|no}] [--ignore-exit] + [--diagnostic-string=STRING] [--merge|--no-merge] + [--comments|--no-comments] [--] TEST-COMMAND +The '--test-name', '-log-file' and '--trs-file' options are mandatory. +END +} + +# TODO: better error handling in option parsing (in particular, ensure +# TODO: $log_file, $trs_file and $test_name are defined). +test_name= # Used for reporting. +log_file= # Where to save the result and output of the test script. +trs_file= # Where to save the metadata of the test run. +expect_failure=0 +color_tests=0 +merge=0 +ignore_exit=0 +comments=0 +diag_string='#' +while test $# -gt 0; do + case $1 in + --help) print_usage; exit $?;; + --version) echo "$me $scriptversion"; exit $?;; + --test-name) test_name=$2; shift;; + --log-file) log_file=$2; shift;; + --trs-file) trs_file=$2; shift;; + --color-tests) color_tests=$2; shift;; + --expect-failure) expect_failure=$2; shift;; + --enable-hard-errors) shift;; # No-op. + --merge) merge=1;; + --no-merge) merge=0;; + --ignore-exit) ignore_exit=1;; + --comments) comments=1;; + --no-comments) comments=0;; + --diagnostic-string) diag_string=$2; shift;; + --) shift; break;; + -*) usage_error "invalid option: '$1'";; + esac + shift +done + +test $# -gt 0 || usage_error "missing test command" + +case $expect_failure in + yes) expect_failure=1;; + *) expect_failure=0;; +esac + +if test $color_tests = yes; then + init_colors=' + color_map["red"]="[0;31m" # Red. + color_map["grn"]="[0;32m" # Green. + color_map["lgn"]="[1;32m" # Light green. + color_map["blu"]="[1;34m" # Blue. + color_map["mgn"]="[0;35m" # Magenta. + color_map["std"]="[m" # No color. + color_for_result["ERROR"] = "mgn" + color_for_result["PASS"] = "grn" + color_for_result["XPASS"] = "red" + color_for_result["FAIL"] = "red" + color_for_result["XFAIL"] = "lgn" + color_for_result["SKIP"] = "blu"' +else + init_colors='' +fi + +# :; is there to work around a bug in bash 3.2 (and earlier) which +# does not always set '$?' properly on redirection failure. +# See the Autoconf manual for more details. +:;{ + ( + # Ignore common signals (in this subshell only!), to avoid potential + # problems with Korn shells. Some Korn shells are known to propagate + # to themselves signals that have killed a child process they were + # waiting for; this is done at least for SIGINT (and usually only for + # it, in truth). Without the `trap' below, such a behaviour could + # cause a premature exit in the current subshell, e.g., in case the + # test command it runs gets terminated by a SIGINT. Thus, the awk + # script we are piping into would never seen the exit status it + # expects on its last input line (which is displayed below by the + # last `echo $?' statement), and would thus die reporting an internal + # error. + # For more information, see the Autoconf manual and the threads: + # <http://lists.gnu.org/archive/html/bug-autoconf/2011-09/msg00004.html> + # <http://mail.opensolaris.org/pipermail/ksh93-integration-discuss/2009-February/004121.html> + trap : 1 3 2 13 15 + if test $merge -gt 0; then + exec 2>&1 + else + exec 2>&3 + fi + "$@" + echo $? + ) | LC_ALL=C ${AM_TAP_AWK-awk} \ + -v me="$me" \ + -v test_script_name="$test_name" \ + -v log_file="$log_file" \ + -v trs_file="$trs_file" \ + -v expect_failure="$expect_failure" \ + -v merge="$merge" \ + -v ignore_exit="$ignore_exit" \ + -v comments="$comments" \ + -v diag_string="$diag_string" \ +' +# TODO: the usages of "cat >&3" below could be optimized when using +# GNU awk, and/on on systems that supports /dev/fd/. + +# Implementation note: in what follows, `result_obj` will be an +# associative array that (partly) simulates a TAP result object +# from the `TAP::Parser` perl module. + +## ----------- ## +## FUNCTIONS ## +## ----------- ## + +function fatal(msg) +{ + print me ": " msg | "cat >&2" + exit 1 +} + +function abort(where) +{ + fatal("internal error " where) +} + +# Convert a boolean to a "yes"/"no" string. +function yn(bool) +{ + return bool ? "yes" : "no"; +} + +function add_test_result(result) +{ + if (!test_results_index) + test_results_index = 0 + test_results_list[test_results_index] = result + test_results_index += 1 + test_results_seen[result] = 1; +} + +# Whether the test script should be re-run by "make recheck". +function must_recheck() +{ + for (k in test_results_seen) + if (k != "XFAIL" && k != "PASS" && k != "SKIP") + return 1 + return 0 +} + +# Whether the content of the log file associated to this test should +# be copied into the "global" test-suite.log. +function copy_in_global_log() +{ + for (k in test_results_seen) + if (k != "PASS") + return 1 + return 0 +} + +function get_global_test_result() +{ + if ("ERROR" in test_results_seen) + return "ERROR" + if ("FAIL" in test_results_seen || "XPASS" in test_results_seen) + return "FAIL" + all_skipped = 1 + for (k in test_results_seen) + if (k != "SKIP") + all_skipped = 0 + if (all_skipped) + return "SKIP" + return "PASS"; +} + +function stringify_result_obj(result_obj) +{ + if (result_obj["is_unplanned"] || result_obj["number"] != testno) + return "ERROR" + + if (plan_seen == LATE_PLAN) + return "ERROR" + + if (result_obj["directive"] == "TODO") + return result_obj["is_ok"] ? "XPASS" : "XFAIL" + + if (result_obj["directive"] == "SKIP") + return result_obj["is_ok"] ? "SKIP" : COOKED_FAIL; + + if (length(result_obj["directive"])) + abort("in function stringify_result_obj()") + + return result_obj["is_ok"] ? COOKED_PASS : COOKED_FAIL +} + +function decorate_result(result) +{ + color_name = color_for_result[result] + if (color_name) + return color_map[color_name] "" result "" color_map["std"] + # If we are not using colorized output, or if we do not know how + # to colorize the given result, we should return it unchanged. + return result +} + +function report(result, details) +{ + if (result ~ /^(X?(PASS|FAIL)|SKIP|ERROR)/) + { + msg = ": " test_script_name + add_test_result(result) + } + else if (result == "#") + { + msg = " " test_script_name ":" + } + else + { + abort("in function report()") + } + if (length(details)) + msg = msg " " details + # Output on console might be colorized. + print decorate_result(result) msg + # Log the result in the log file too, to help debugging (this is + # especially true when said result is a TAP error or "Bail out!"). + print result msg | "cat >&3"; +} + +function testsuite_error(error_message) +{ + report("ERROR", "- " error_message) +} + +function handle_tap_result() +{ + details = result_obj["number"]; + if (length(result_obj["description"])) + details = details " " result_obj["description"] + + if (plan_seen == LATE_PLAN) + { + details = details " # AFTER LATE PLAN"; + } + else if (result_obj["is_unplanned"]) + { + details = details " # UNPLANNED"; + } + else if (result_obj["number"] != testno) + { + details = sprintf("%s # OUT-OF-ORDER (expecting %d)", + details, testno); + } + else if (result_obj["directive"]) + { + details = details " # " result_obj["directive"]; + if (length(result_obj["explanation"])) + details = details " " result_obj["explanation"] + } + + report(stringify_result_obj(result_obj), details) +} + +# `skip_reason` should be empty whenever planned > 0. +function handle_tap_plan(planned, skip_reason) +{ + planned += 0 # Avoid getting confused if, say, `planned` is "00" + if (length(skip_reason) && planned > 0) + abort("in function handle_tap_plan()") + if (plan_seen) + { + # Error, only one plan per stream is acceptable. + testsuite_error("multiple test plans") + return; + } + planned_tests = planned + # The TAP plan can come before or after *all* the TAP results; we speak + # respectively of an "early" or a "late" plan. If we see the plan line + # after at least one TAP result has been seen, assume we have a late + # plan; in this case, any further test result seen after the plan will + # be flagged as an error. + plan_seen = (testno >= 1 ? LATE_PLAN : EARLY_PLAN) + # If testno > 0, we have an error ("too many tests run") that will be + # automatically dealt with later, so do not worry about it here. If + # $plan_seen is true, we have an error due to a repeated plan, and that + # has already been dealt with above. Otherwise, we have a valid "plan + # with SKIP" specification, and should report it as a particular kind + # of SKIP result. + if (planned == 0 && testno == 0) + { + if (length(skip_reason)) + skip_reason = "- " skip_reason; + report("SKIP", skip_reason); + } +} + +function extract_tap_comment(line) +{ + if (index(line, diag_string) == 1) + { + # Strip leading `diag_string` from `line`. + line = substr(line, length(diag_string) + 1) + # And strip any leading and trailing whitespace left. + sub("^[ \t]*", "", line) + sub("[ \t]*$", "", line) + # Return what is left (if any). + return line; + } + return ""; +} + +# When this function is called, we know that line is a TAP result line, +# so that it matches the (perl) RE "^(not )?ok\b". +function setup_result_obj(line) +{ + # Get the result, and remove it from the line. + result_obj["is_ok"] = (substr(line, 1, 2) == "ok" ? 1 : 0) + sub("^(not )?ok[ \t]*", "", line) + + # If the result has an explicit number, get it and strip it; otherwise, + # automatically assing the next progresive number to it. + if (line ~ /^[0-9]+$/ || line ~ /^[0-9]+[^a-zA-Z0-9_]/) + { + match(line, "^[0-9]+") + # The final `+ 0` is to normalize numbers with leading zeros. + result_obj["number"] = substr(line, 1, RLENGTH) + 0 + line = substr(line, RLENGTH + 1) + } + else + { + result_obj["number"] = testno + } + + if (plan_seen == LATE_PLAN) + # No further test results are acceptable after a "late" TAP plan + # has been seen. + result_obj["is_unplanned"] = 1 + else if (plan_seen && testno > planned_tests) + result_obj["is_unplanned"] = 1 + else + result_obj["is_unplanned"] = 0 + + # Strip trailing and leading whitespace. + sub("^[ \t]*", "", line) + sub("[ \t]*$", "", line) + + # This will have to be corrected if we have a "TODO"/"SKIP" directive. + result_obj["description"] = line + result_obj["directive"] = "" + result_obj["explanation"] = "" + + if (index(line, "#") == 0) + return # No possible directive, nothing more to do. + + # Directives are case-insensitive. + rx = "[ \t]*#[ \t]*([tT][oO][dD][oO]|[sS][kK][iI][pP])[ \t]*" + + # See whether we have the directive, and if yes, where. + pos = match(line, rx "$") + if (!pos) + pos = match(line, rx "[^a-zA-Z0-9_]") + + # If there was no TAP directive, we have nothing more to do. + if (!pos) + return + + # Let`s now see if the TAP directive has been escaped. For example: + # escaped: ok \# SKIP + # not escaped: ok \\# SKIP + # escaped: ok \\\\\# SKIP + # not escaped: ok \ # SKIP + if (substr(line, pos, 1) == "#") + { + bslash_count = 0 + for (i = pos; i > 1 && substr(line, i - 1, 1) == "\\"; i--) + bslash_count += 1 + if (bslash_count % 2) + return # Directive was escaped. + } + + # Strip the directive and its explanation (if any) from the test + # description. + result_obj["description"] = substr(line, 1, pos - 1) + # Now remove the test description from the line, that has been dealt + # with already. + line = substr(line, pos) + # Strip the directive, and save its value (normalized to upper case). + sub("^[ \t]*#[ \t]*", "", line) + result_obj["directive"] = toupper(substr(line, 1, 4)) + line = substr(line, 5) + # Now get the explanation for the directive (if any), with leading + # and trailing whitespace removed. + sub("^[ \t]*", "", line) + sub("[ \t]*$", "", line) + result_obj["explanation"] = line +} + +function get_test_exit_message(status) +{ + if (status == 0) + return "" + if (status !~ /^[1-9][0-9]*$/) + abort("getting exit status") + if (status < 127) + exit_details = "" + else if (status == 127) + exit_details = " (command not found?)" + else if (status >= 128 && status <= 255) + exit_details = sprintf(" (terminated by signal %d?)", status - 128) + else if (status > 256 && status <= 384) + # We used to report an "abnormal termination" here, but some Korn + # shells, when a child process die due to signal number n, can leave + # in $? an exit status of 256+n instead of the more standard 128+n. + # Apparently, both behaviours are allowed by POSIX (2008), so be + # prepared to handle them both. See also Austing Group report ID + # 0000051 <http://www.austingroupbugs.net/view.php?id=51> + exit_details = sprintf(" (terminated by signal %d?)", status - 256) + else + # Never seen in practice. + exit_details = " (abnormal termination)" + return sprintf("exited with status %d%s", status, exit_details) +} + +function write_test_results() +{ + print ":global-test-result: " get_global_test_result() > trs_file + print ":recheck: " yn(must_recheck()) > trs_file + print ":copy-in-global-log: " yn(copy_in_global_log()) > trs_file + for (i = 0; i < test_results_index; i += 1) + print ":test-result: " test_results_list[i] > trs_file + close(trs_file); +} + +BEGIN { + +## ------- ## +## SETUP ## +## ------- ## + +'"$init_colors"' + +# Properly initialized once the TAP plan is seen. +planned_tests = 0 + +COOKED_PASS = expect_failure ? "XPASS": "PASS"; +COOKED_FAIL = expect_failure ? "XFAIL": "FAIL"; + +# Enumeration-like constants to remember which kind of plan (if any) +# has been seen. It is important that NO_PLAN evaluates "false" as +# a boolean. +NO_PLAN = 0 +EARLY_PLAN = 1 +LATE_PLAN = 2 + +testno = 0 # Number of test results seen so far. +bailed_out = 0 # Whether a "Bail out!" directive has been seen. + +# Whether the TAP plan has been seen or not, and if yes, which kind +# it is ("early" is seen before any test result, "late" otherwise). +plan_seen = NO_PLAN + +## --------- ## +## PARSING ## +## --------- ## + +is_first_read = 1 + +while (1) + { + # Involutions required so that we are able to read the exit status + # from the last input line. + st = getline + if (st < 0) # I/O error. + fatal("I/O error while reading from input stream") + else if (st == 0) # End-of-input + { + if (is_first_read) + abort("in input loop: only one input line") + break + } + if (is_first_read) + { + is_first_read = 0 + nextline = $0 + continue + } + else + { + curline = nextline + nextline = $0 + $0 = curline + } + # Copy any input line verbatim into the log file. + print | "cat >&3" + # Parsing of TAP input should stop after a "Bail out!" directive. + if (bailed_out) + continue + + # TAP test result. + if ($0 ~ /^(not )?ok$/ || $0 ~ /^(not )?ok[^a-zA-Z0-9_]/) + { + testno += 1 + setup_result_obj($0) + handle_tap_result() + } + # TAP plan (normal or "SKIP" without explanation). + else if ($0 ~ /^1\.\.[0-9]+[ \t]*$/) + { + # The next two lines will put the number of planned tests in $0. + sub("^1\\.\\.", "") + sub("[^0-9]*$", "") + handle_tap_plan($0, "") + continue + } + # TAP "SKIP" plan, with an explanation. + else if ($0 ~ /^1\.\.0+[ \t]*#/) + { + # The next lines will put the skip explanation in $0, stripping + # any leading and trailing whitespace. This is a little more + # tricky in truth, since we want to also strip a potential leading + # "SKIP" string from the message. + sub("^[^#]*#[ \t]*(SKIP[: \t][ \t]*)?", "") + sub("[ \t]*$", ""); + handle_tap_plan(0, $0) + } + # "Bail out!" magic. + # Older versions of prove and TAP::Harness (e.g., 3.17) did not + # recognize a "Bail out!" directive when preceded by leading + # whitespace, but more modern versions (e.g., 3.23) do. So we + # emulate the latter, "more modern" behaviour. + else if ($0 ~ /^[ \t]*Bail out!/) + { + bailed_out = 1 + # Get the bailout message (if any), with leading and trailing + # whitespace stripped. The message remains stored in `$0`. + sub("^[ \t]*Bail out![ \t]*", ""); + sub("[ \t]*$", ""); + # Format the error message for the + bailout_message = "Bail out!" + if (length($0)) + bailout_message = bailout_message " " $0 + testsuite_error(bailout_message) + } + # Maybe we have too look for dianogtic comments too. + else if (comments != 0) + { + comment = extract_tap_comment($0); + if (length(comment)) + report("#", comment); + } + } + +## -------- ## +## FINISH ## +## -------- ## + +# A "Bail out!" directive should cause us to ignore any following TAP +# error, as well as a non-zero exit status from the TAP producer. +if (!bailed_out) + { + if (!plan_seen) + { + testsuite_error("missing test plan") + } + else if (planned_tests != testno) + { + bad_amount = testno > planned_tests ? "many" : "few" + testsuite_error(sprintf("too %s tests run (expected %d, got %d)", + bad_amount, planned_tests, testno)) + } + if (!ignore_exit) + { + # Fetch exit status from the last line. + exit_message = get_test_exit_message(nextline) + if (exit_message) + testsuite_error(exit_message) + } + } + +write_test_results() + +exit 0 + +} # End of "BEGIN" block. +' + +# TODO: document that we consume the file descriptor 3 :-( +} 3>"$log_file" + +test $? -eq 0 || fatal "I/O or internal error" + +# Local Variables: +# mode: shell-script +# sh-indentation: 2 +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/resources/3rdparty/cudd-3.0.0/config.h.in b/resources/3rdparty/cudd-3.0.0/config.h.in new file mode 100644 index 000000000..1bea1dd11 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/config.h.in @@ -0,0 +1,186 @@ +/* config.h.in. Generated from configure.ac by autoheader. */ + +/* Define if building universal (internal helper macro) */ +#undef AC_APPLE_UNIVERSAL_BUILD + +/* Define to 1 if you have the <assert.h> header file. */ +#undef HAVE_ASSERT_H + +/* Define to 1 if you have the <dlfcn.h> header file. */ +#undef HAVE_DLFCN_H + +/* Define to 1 if you have the <float.h> header file. */ +#undef HAVE_FLOAT_H + +/* Define to 1 if you have the `gethostname' function. */ +#undef HAVE_GETHOSTNAME + +/* Define to 1 if you have the `getrlimit' function. */ +#undef HAVE_GETRLIMIT + +/* Define to 1 if you have the `getrusage' function. */ +#undef HAVE_GETRUSAGE + +/* Define to 1 if you have working floating-point infinities */ +#undef HAVE_IEEE_754 + +/* Define to 1 if you have the <inttypes.h> header file. */ +#undef HAVE_INTTYPES_H + +/* Define to 1 if you have the <limits.h> header file. */ +#undef HAVE_LIMITS_H + +/* Define to 1 if you have the <math.h> header file. */ +#undef HAVE_MATH_H + +/* Define to 1 if you have the <memory.h> header file. */ +#undef HAVE_MEMORY_H + +/* Define to 1 if your compiler supports enough C++11 */ +#undef HAVE_MODERN_CXX + +/* Define to 1 if you have the `pow' function. */ +#undef HAVE_POW + +/* Define to 1 if you have the `powl' function. */ +#undef HAVE_POWL + +/* Define to 1 if the system has the type `ptrdiff_t'. */ +#undef HAVE_PTRDIFF_T + +/* Define to 1 if you have the `sqrt' function. */ +#undef HAVE_SQRT + +/* Define to 1 if you have the <stddef.h> header file. */ +#undef HAVE_STDDEF_H + +/* Define to 1 if you have the <stdint.h> header file. */ +#undef HAVE_STDINT_H + +/* Define to 1 if you have the <stdlib.h> header file. */ +#undef HAVE_STDLIB_H + +/* Define to 1 if you have the `strchr' function. */ +#undef HAVE_STRCHR + +/* Define to 1 if you have the <strings.h> header file. */ +#undef HAVE_STRINGS_H + +/* Define to 1 if you have the <string.h> header file. */ +#undef HAVE_STRING_H + +/* Define to 1 if you have the `strstr' function. */ +#undef HAVE_STRSTR + +/* Define to 1 if you have the `sysconf' function. */ +#undef HAVE_SYSCONF + +/* Define to 1 if you have the <sys/resource.h> header file. */ +#undef HAVE_SYS_RESOURCE_H + +/* Define to 1 if you have the <sys/stat.h> header file. */ +#undef HAVE_SYS_STAT_H + +/* Define to 1 if you have the <sys/times.h> header file. */ +#undef HAVE_SYS_TIMES_H + +/* Define to 1 if you have the <sys/time.h> header file. */ +#undef HAVE_SYS_TIME_H + +/* Define to 1 if you have the <sys/types.h> header file. */ +#undef HAVE_SYS_TYPES_H + +/* Define to 1 if you have the <sys/wait.h> header file. */ +#undef HAVE_SYS_WAIT_H + +/* Define to 1 if you have the <unistd.h> header file. */ +#undef HAVE_UNISTD_H + +/* Define to 1 if C++ thread header is usable */ +#undef HAVE_WORKING_THREAD + +/* Define to 1 if the system has the type `_Bool'. */ +#undef HAVE__BOOL + +/* Define to the sub-directory in which libtool stores uninstalled libraries. + */ +#undef LT_OBJDIR + +/* Name of package */ +#undef PACKAGE + +/* Define to the address where bug reports for this package should be sent. */ +#undef PACKAGE_BUGREPORT + +/* Define to the full name of this package. */ +#undef PACKAGE_NAME + +/* Define to the full name and version of this package. */ +#undef PACKAGE_STRING + +/* Define to the one symbol short name of this package. */ +#undef PACKAGE_TARNAME + +/* Define to the home page for this package. */ +#undef PACKAGE_URL + +/* Define to the version of this package. */ +#undef PACKAGE_VERSION + +/* The size of `int', as computed by sizeof. */ +#undef SIZEOF_INT + +/* The size of `long', as computed by sizeof. */ +#undef SIZEOF_LONG + +/* The size of `long double', as computed by sizeof. */ +#undef SIZEOF_LONG_DOUBLE + +/* The size of `void *', as computed by sizeof. */ +#undef SIZEOF_VOID_P + +/* Define to 1 if you have the ANSI C header files. */ +#undef STDC_HEADERS + +/* Define to 1 to use system qsort */ +#undef USE_SYSTEM_QSORT + +/* Version number of package */ +#undef VERSION + +/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most + significant byte first (like Motorola and SPARC, unlike Intel). */ +#if defined AC_APPLE_UNIVERSAL_BUILD +# if defined __BIG_ENDIAN__ +# define WORDS_BIGENDIAN 1 +# endif +#else +# ifndef WORDS_BIGENDIAN +# undef WORDS_BIGENDIAN +# endif +#endif + +/* Define for Solaris 2.5.1 so the uint32_t typedef from <sys/synch.h>, + <pthread.h>, or <semaphore.h> is not used. If the typedef were allowed, the + #define below would cause a syntax error. */ +#undef _UINT32_T + +/* Define to 1 to enable C99-compliant printf on MinGW-w64 */ +#undef __USE_MINGW_ANSI_STDIO + +/* Define to `__inline__' or `__inline' if that's what the C compiler + calls it, or to nothing if 'inline' is not supported under any name. */ +#ifndef __cplusplus +#undef inline +#endif + +/* Define to `unsigned int' if <sys/types.h> does not define. */ +#undef size_t + +/* Define to the type of an unsigned integer type of width exactly 16 bits if + such a type exists and the standard includes do not define it. */ +#undef uint16_t + +/* Define to the type of an unsigned integer type of width exactly 32 bits if + such a type exists and the standard includes do not define it. */ +#undef uint32_t diff --git a/resources/3rdparty/cudd-3.0.0/configure b/resources/3rdparty/cudd-3.0.0/configure new file mode 100755 index 000000000..f0e0e742e --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/configure @@ -0,0 +1,19889 @@ +#! /bin/sh +# Guess values for system-dependent variables and create Makefiles. +# Generated by GNU Autoconf 2.69 for cudd 3.0.0. +# +# Report bugs to <Fabio@Colorado.EDU>. +# +# +# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. +# +# +# This configure script is free software; the Free Software Foundation +# gives unlimited permission to copy, distribute and modify it. +## -------------------- ## +## M4sh Initialization. ## +## -------------------- ## + +# Be more Bourne compatible +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi + + +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' +else + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' + else + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in #( + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' + fi + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' +fi + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi + + +# IFS +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent editors from complaining about space-tab. +# (If _AS_PATH_WALK were called with IFS unset, it would disable word +# splitting by setting IFS to empty value.) +IFS=" "" $as_nl" + +# Find who we are. Look in the path if we contain no directory separator. +as_myself= +case $0 in #(( + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done +IFS=$as_save_IFS + + ;; +esac +# We did not find ourselves, most probably we were run as `sh COMMAND' +# in which case we are not to be found in the path. +if test "x$as_myself" = x; then + as_myself=$0 +fi +if test ! -f "$as_myself"; then + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + exit 1 +fi + +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : +done +PS1='$ ' +PS2='> ' +PS4='+ ' + +# NLS nuisances. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE + +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +# Use a proper internal environment variable to ensure we don't fall + # into an infinite loop, continuously re-executing ourselves. + if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then + _as_can_reexec=no; export _as_can_reexec; + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +as_fn_exit 255 + fi + # We don't want this to propagate to other subprocesses. + { _as_can_reexec=; unset _as_can_reexec;} +if test "x$CONFIG_SHELL" = x; then + as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which + # is contrary to our usage. Disable this feature. + alias -g '\${1+\"\$@\"}'='\"\$@\"' + setopt NO_GLOB_SUBST +else + case \`(set -o) 2>/dev/null\` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi +" + as_required="as_fn_return () { (exit \$1); } +as_fn_success () { as_fn_return 0; } +as_fn_failure () { as_fn_return 1; } +as_fn_ret_success () { return 0; } +as_fn_ret_failure () { return 1; } + +exitcode=0 +as_fn_success || { exitcode=1; echo as_fn_success failed.; } +as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } +as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } +as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } +if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : + +else + exitcode=1; echo positional parameters were not saved. +fi +test x\$exitcode = x0 || exit 1 +test -x / || exit 1" + as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO + as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO + eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && + test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 + + test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ + || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1 +test \$(( 1 + 1 )) = 2 || exit 1" + if (eval "$as_required") 2>/dev/null; then : + as_have_required=yes +else + as_have_required=no +fi + if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : + +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +as_found=false +for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + as_found=: + case $as_dir in #( + /*) + for as_base in sh bash ksh sh5; do + # Try only shells that exist, to save several forks. + as_shell=$as_dir/$as_base + if { test -f "$as_shell" || test -f "$as_shell.exe"; } && + { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : + CONFIG_SHELL=$as_shell as_have_required=yes + if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : + break 2 +fi +fi + done;; + esac + as_found=false +done +$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && + { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : + CONFIG_SHELL=$SHELL as_have_required=yes +fi; } +IFS=$as_save_IFS + + + if test "x$CONFIG_SHELL" != x; then : + export CONFIG_SHELL + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +exit 255 +fi + + if test x$as_have_required = xno; then : + $as_echo "$0: This script requires a shell more modern than all" + $as_echo "$0: the shells that I found on your system." + if test x${ZSH_VERSION+set} = xset ; then + $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" + $as_echo "$0: be upgraded to zsh 4.3.4 or later." + else + $as_echo "$0: Please tell bug-autoconf@gnu.org and Fabio@Colorado.EDU +$0: about your system, including any error possibly output +$0: before this message. Then install a modern shell, or +$0: manually run the script under such a shell if you do +$0: have one." + fi + exit 1 +fi +fi +fi +SHELL=${CONFIG_SHELL-/bin/sh} +export SHELL +# Unset more variables known to interfere with behavior of common tools. +CLICOLOR_FORCE= GREP_OPTIONS= +unset CLICOLOR_FORCE GREP_OPTIONS + +## --------------------- ## +## M4sh Shell Functions. ## +## --------------------- ## +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset + +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status + +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit + +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ + + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" + + +} # as_fn_mkdir_p + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append + +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith + + +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error + +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi + +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi + +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi + +as_me=`$as_basename -- "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ + s//\1/ + q + } + /^X\/\(\/\/\)$/{ + s//\1/ + q + } + /^X\/\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + + + as_lineno_1=$LINENO as_lineno_1a=$LINENO + as_lineno_2=$LINENO as_lineno_2a=$LINENO + eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && + test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { + # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) + sed -n ' + p + /[$]LINENO/= + ' <$as_myself | + sed ' + s/[$]LINENO.*/&-/ + t lineno + b + :lineno + N + :loop + s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ + t loop + s/-\n.*// + ' >$as_me.lineno && + chmod +x "$as_me.lineno" || + { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } + + # If we had to re-execute with $CONFIG_SHELL, we're ensured to have + # already done that, so ensure we don't try to do so again and fall + # in an infinite loop. This has already happened in practice. + _as_can_reexec=no; export _as_can_reexec + # Don't try to exec as it changes $[0], causing all sort of problems + # (the dirname of $[0] is not the place where we might find the + # original and so on. Autoconf is especially sensitive to this). + . "./$as_me.lineno" + # Exit status is that of the last command. + exit +} + +ECHO_C= ECHO_N= ECHO_T= +case `echo -n x` in #((((( +-n*) + case `echo 'xy\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; + esac;; +*) + ECHO_N='-n';; +esac + +rm -f conf$$ conf$$.exe conf$$.file +if test -d conf$$.dir; then + rm -f conf$$.dir/conf$$.file +else + rm -f conf$$.dir + mkdir conf$$.dir 2>/dev/null +fi +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -pR'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -pR' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else + as_ln_s='cp -pR' + fi +else + as_ln_s='cp -pR' +fi +rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file +rmdir conf$$.dir 2>/dev/null + +if mkdir -p . 2>/dev/null; then + as_mkdir_p='mkdir -p "$as_dir"' +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi + +as_test_x='test -x' +as_executable_p=as_fn_executable_p + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" + +SHELL=${CONFIG_SHELL-/bin/sh} + + +test -n "$DJDIR" || exec 7<&0 </dev/null +exec 6>&1 + +# Name of the host. +# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, +# so uname gets run too. +ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` + +# +# Initializations. +# +ac_default_prefix=/usr/local +ac_clean_files= +ac_config_libobj_dir=. +LIBOBJS= +cross_compiling=no +subdirs= +MFLAGS= +MAKEFLAGS= + +# Identity of this package. +PACKAGE_NAME='cudd' +PACKAGE_TARNAME='cudd' +PACKAGE_VERSION='3.0.0' +PACKAGE_STRING='cudd 3.0.0' +PACKAGE_BUGREPORT='Fabio@Colorado.EDU' +PACKAGE_URL='' + +# Factoring default headers for most tests. +ac_includes_default="\ +#include <stdio.h> +#ifdef HAVE_SYS_TYPES_H +# include <sys/types.h> +#endif +#ifdef HAVE_SYS_STAT_H +# include <sys/stat.h> +#endif +#ifdef STDC_HEADERS +# include <stdlib.h> +# include <stddef.h> +#else +# ifdef HAVE_STDLIB_H +# include <stdlib.h> +# endif +#endif +#ifdef HAVE_STRING_H +# if !defined STDC_HEADERS && defined HAVE_MEMORY_H +# include <memory.h> +# endif +# include <string.h> +#endif +#ifdef HAVE_STRINGS_H +# include <strings.h> +#endif +#ifdef HAVE_INTTYPES_H +# include <inttypes.h> +#endif +#ifdef HAVE_STDINT_H +# include <stdint.h> +#endif +#ifdef HAVE_UNISTD_H +# include <unistd.h> +#endif" + +ac_unique_file="st/st.c" +ac_subst_vars='am__EXEEXT_FALSE +am__EXEEXT_TRUE +LTLIBOBJS +LIBOBJS +MINGW64_FALSE +MINGW64_TRUE +HAVE_PTHREADS_FALSE +HAVE_PTHREADS_TRUE +HAVE_PDFLATEX_FALSE +HAVE_PDFLATEX_TRUE +MAKEINDEX +PDFLATEX +HAVE_DOXYGEN_FALSE +HAVE_DOXYGEN_TRUE +DOXYGEN +CROSS_COMPILING_FALSE +CROSS_COMPILING_TRUE +CXXCPP +CPP +OTOOL64 +OTOOL +LIPO +NMEDIT +DSYMUTIL +MANIFEST_TOOL +RANLIB +LN_S +NM +ac_ct_DUMPBIN +DUMPBIN +LD +FGREP +EGREP +GREP +SED +LIBTOOL +OBJDUMP +DLLTOOL +AS +ac_ct_AR +AR +am__fastdepCXX_FALSE +am__fastdepCXX_TRUE +CXXDEPMODE +ac_ct_CXX +CXXFLAGS +CXX +am__fastdepCC_FALSE +am__fastdepCC_TRUE +CCDEPMODE +am__nodep +AMDEPBACKSLASH +AMDEP_FALSE +AMDEP_TRUE +am__quote +am__include +DEPDIR +OBJEXT +EXEEXT +ac_ct_CC +CPPFLAGS +LDFLAGS +CFLAGS +CC +OBJ_FALSE +OBJ_TRUE +DDDMP_FALSE +DDDMP_TRUE +AM_BACKSLASH +AM_DEFAULT_VERBOSITY +AM_DEFAULT_V +AM_V +am__untar +am__tar +AMTAR +am__leading_dot +SET_MAKE +AWK +mkdir_p +MKDIR_P +INSTALL_STRIP_PROGRAM +STRIP +install_sh +MAKEINFO +AUTOHEADER +AUTOMAKE +AUTOCONF +ACLOCAL +VERSION +PACKAGE +CYGPATH_W +am__isrc +INSTALL_DATA +INSTALL_SCRIPT +INSTALL_PROGRAM +host_os +host_vendor +host_cpu +host +build_os +build_vendor +build_cpu +build +target_alias +host_alias +build_alias +LIBS +ECHO_T +ECHO_N +ECHO_C +DEFS +mandir +localedir +libdir +psdir +pdfdir +dvidir +htmldir +infodir +docdir +oldincludedir +includedir +localstatedir +sharedstatedir +sysconfdir +datadir +datarootdir +libexecdir +sbindir +bindir +program_transform_name +prefix +exec_prefix +PACKAGE_URL +PACKAGE_BUGREPORT +PACKAGE_STRING +PACKAGE_VERSION +PACKAGE_TARNAME +PACKAGE_NAME +PATH_SEPARATOR +SHELL' +ac_subst_files='' +ac_user_opts=' +enable_option_checking +enable_silent_rules +enable_dddmp +enable_obj +with_system_qsort +enable_dependency_tracking +enable_shared +enable_static +with_pic +enable_fast_install +with_gnu_ld +with_sysroot +enable_libtool_lock +' + ac_precious_vars='build_alias +host_alias +target_alias +CC +CFLAGS +LDFLAGS +LIBS +CPPFLAGS +CXX +CXXFLAGS +CCC +CPP +CXXCPP' + + +# Initialize some variables set by options. +ac_init_help= +ac_init_version=false +ac_unrecognized_opts= +ac_unrecognized_sep= +# The variables have the same names as the options, with +# dashes changed to underlines. +cache_file=/dev/null +exec_prefix=NONE +no_create= +no_recursion= +prefix=NONE +program_prefix=NONE +program_suffix=NONE +program_transform_name=s,x,x, +silent= +site= +srcdir= +verbose= +x_includes=NONE +x_libraries=NONE + +# Installation directory options. +# These are left unexpanded so users can "make install exec_prefix=/foo" +# and all the variables that are supposed to be based on exec_prefix +# by default will actually change. +# Use braces instead of parens because sh, perl, etc. also accept them. +# (The list follows the same order as the GNU Coding Standards.) +bindir='${exec_prefix}/bin' +sbindir='${exec_prefix}/sbin' +libexecdir='${exec_prefix}/libexec' +datarootdir='${prefix}/share' +datadir='${datarootdir}' +sysconfdir='${prefix}/etc' +sharedstatedir='${prefix}/com' +localstatedir='${prefix}/var' +includedir='${prefix}/include' +oldincludedir='/usr/include' +docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' +infodir='${datarootdir}/info' +htmldir='${docdir}' +dvidir='${docdir}' +pdfdir='${docdir}' +psdir='${docdir}' +libdir='${exec_prefix}/lib' +localedir='${datarootdir}/locale' +mandir='${datarootdir}/man' + +ac_prev= +ac_dashdash= +for ac_option +do + # If the previous option needs an argument, assign it. + if test -n "$ac_prev"; then + eval $ac_prev=\$ac_option + ac_prev= + continue + fi + + case $ac_option in + *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; + *=) ac_optarg= ;; + *) ac_optarg=yes ;; + esac + + # Accept the important Cygnus configure options, so we can diagnose typos. + + case $ac_dashdash$ac_option in + --) + ac_dashdash=yes ;; + + -bindir | --bindir | --bindi | --bind | --bin | --bi) + ac_prev=bindir ;; + -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) + bindir=$ac_optarg ;; + + -build | --build | --buil | --bui | --bu) + ac_prev=build_alias ;; + -build=* | --build=* | --buil=* | --bui=* | --bu=*) + build_alias=$ac_optarg ;; + + -cache-file | --cache-file | --cache-fil | --cache-fi \ + | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) + ac_prev=cache_file ;; + -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ + | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) + cache_file=$ac_optarg ;; + + --config-cache | -C) + cache_file=config.cache ;; + + -datadir | --datadir | --datadi | --datad) + ac_prev=datadir ;; + -datadir=* | --datadir=* | --datadi=* | --datad=*) + datadir=$ac_optarg ;; + + -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ + | --dataroo | --dataro | --datar) + ac_prev=datarootdir ;; + -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ + | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) + datarootdir=$ac_optarg ;; + + -disable-* | --disable-*) + ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid feature name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"enable_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval enable_$ac_useropt=no ;; + + -docdir | --docdir | --docdi | --doc | --do) + ac_prev=docdir ;; + -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) + docdir=$ac_optarg ;; + + -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) + ac_prev=dvidir ;; + -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) + dvidir=$ac_optarg ;; + + -enable-* | --enable-*) + ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid feature name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"enable_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval enable_$ac_useropt=\$ac_optarg ;; + + -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ + | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ + | --exec | --exe | --ex) + ac_prev=exec_prefix ;; + -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ + | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ + | --exec=* | --exe=* | --ex=*) + exec_prefix=$ac_optarg ;; + + -gas | --gas | --ga | --g) + # Obsolete; use --with-gas. + with_gas=yes ;; + + -help | --help | --hel | --he | -h) + ac_init_help=long ;; + -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) + ac_init_help=recursive ;; + -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) + ac_init_help=short ;; + + -host | --host | --hos | --ho) + ac_prev=host_alias ;; + -host=* | --host=* | --hos=* | --ho=*) + host_alias=$ac_optarg ;; + + -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) + ac_prev=htmldir ;; + -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ + | --ht=*) + htmldir=$ac_optarg ;; + + -includedir | --includedir | --includedi | --included | --include \ + | --includ | --inclu | --incl | --inc) + ac_prev=includedir ;; + -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ + | --includ=* | --inclu=* | --incl=* | --inc=*) + includedir=$ac_optarg ;; + + -infodir | --infodir | --infodi | --infod | --info | --inf) + ac_prev=infodir ;; + -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) + infodir=$ac_optarg ;; + + -libdir | --libdir | --libdi | --libd) + ac_prev=libdir ;; + -libdir=* | --libdir=* | --libdi=* | --libd=*) + libdir=$ac_optarg ;; + + -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ + | --libexe | --libex | --libe) + ac_prev=libexecdir ;; + -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ + | --libexe=* | --libex=* | --libe=*) + libexecdir=$ac_optarg ;; + + -localedir | --localedir | --localedi | --localed | --locale) + ac_prev=localedir ;; + -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) + localedir=$ac_optarg ;; + + -localstatedir | --localstatedir | --localstatedi | --localstated \ + | --localstate | --localstat | --localsta | --localst | --locals) + ac_prev=localstatedir ;; + -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ + | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) + localstatedir=$ac_optarg ;; + + -mandir | --mandir | --mandi | --mand | --man | --ma | --m) + ac_prev=mandir ;; + -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) + mandir=$ac_optarg ;; + + -nfp | --nfp | --nf) + # Obsolete; use --without-fp. + with_fp=no ;; + + -no-create | --no-create | --no-creat | --no-crea | --no-cre \ + | --no-cr | --no-c | -n) + no_create=yes ;; + + -no-recursion | --no-recursion | --no-recursio | --no-recursi \ + | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) + no_recursion=yes ;; + + -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ + | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ + | --oldin | --oldi | --old | --ol | --o) + ac_prev=oldincludedir ;; + -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ + | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ + | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) + oldincludedir=$ac_optarg ;; + + -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) + ac_prev=prefix ;; + -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) + prefix=$ac_optarg ;; + + -program-prefix | --program-prefix | --program-prefi | --program-pref \ + | --program-pre | --program-pr | --program-p) + ac_prev=program_prefix ;; + -program-prefix=* | --program-prefix=* | --program-prefi=* \ + | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) + program_prefix=$ac_optarg ;; + + -program-suffix | --program-suffix | --program-suffi | --program-suff \ + | --program-suf | --program-su | --program-s) + ac_prev=program_suffix ;; + -program-suffix=* | --program-suffix=* | --program-suffi=* \ + | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) + program_suffix=$ac_optarg ;; + + -program-transform-name | --program-transform-name \ + | --program-transform-nam | --program-transform-na \ + | --program-transform-n | --program-transform- \ + | --program-transform | --program-transfor \ + | --program-transfo | --program-transf \ + | --program-trans | --program-tran \ + | --progr-tra | --program-tr | --program-t) + ac_prev=program_transform_name ;; + -program-transform-name=* | --program-transform-name=* \ + | --program-transform-nam=* | --program-transform-na=* \ + | --program-transform-n=* | --program-transform-=* \ + | --program-transform=* | --program-transfor=* \ + | --program-transfo=* | --program-transf=* \ + | --program-trans=* | --program-tran=* \ + | --progr-tra=* | --program-tr=* | --program-t=*) + program_transform_name=$ac_optarg ;; + + -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) + ac_prev=pdfdir ;; + -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) + pdfdir=$ac_optarg ;; + + -psdir | --psdir | --psdi | --psd | --ps) + ac_prev=psdir ;; + -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) + psdir=$ac_optarg ;; + + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil) + silent=yes ;; + + -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) + ac_prev=sbindir ;; + -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ + | --sbi=* | --sb=*) + sbindir=$ac_optarg ;; + + -sharedstatedir | --sharedstatedir | --sharedstatedi \ + | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ + | --sharedst | --shareds | --shared | --share | --shar \ + | --sha | --sh) + ac_prev=sharedstatedir ;; + -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ + | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ + | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ + | --sha=* | --sh=*) + sharedstatedir=$ac_optarg ;; + + -site | --site | --sit) + ac_prev=site ;; + -site=* | --site=* | --sit=*) + site=$ac_optarg ;; + + -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) + ac_prev=srcdir ;; + -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) + srcdir=$ac_optarg ;; + + -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ + | --syscon | --sysco | --sysc | --sys | --sy) + ac_prev=sysconfdir ;; + -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ + | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) + sysconfdir=$ac_optarg ;; + + -target | --target | --targe | --targ | --tar | --ta | --t) + ac_prev=target_alias ;; + -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) + target_alias=$ac_optarg ;; + + -v | -verbose | --verbose | --verbos | --verbo | --verb) + verbose=yes ;; + + -version | --version | --versio | --versi | --vers | -V) + ac_init_version=: ;; + + -with-* | --with-*) + ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid package name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"with_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval with_$ac_useropt=\$ac_optarg ;; + + -without-* | --without-*) + ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid package name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"with_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval with_$ac_useropt=no ;; + + --x) + # Obsolete; use --with-x. + with_x=yes ;; + + -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ + | --x-incl | --x-inc | --x-in | --x-i) + ac_prev=x_includes ;; + -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ + | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) + x_includes=$ac_optarg ;; + + -x-libraries | --x-libraries | --x-librarie | --x-librari \ + | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) + ac_prev=x_libraries ;; + -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ + | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) + x_libraries=$ac_optarg ;; + + -*) as_fn_error $? "unrecognized option: \`$ac_option' +Try \`$0 --help' for more information" + ;; + + *=*) + ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` + # Reject names that are not valid shell variable names. + case $ac_envvar in #( + '' | [0-9]* | *[!_$as_cr_alnum]* ) + as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; + esac + eval $ac_envvar=\$ac_optarg + export $ac_envvar ;; + + *) + # FIXME: should be removed in autoconf 3.0. + $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 + expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && + $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 + : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" + ;; + + esac +done + +if test -n "$ac_prev"; then + ac_option=--`echo $ac_prev | sed 's/_/-/g'` + as_fn_error $? "missing argument to $ac_option" +fi + +if test -n "$ac_unrecognized_opts"; then + case $enable_option_checking in + no) ;; + fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; + *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; + esac +fi + +# Check all directory arguments for consistency. +for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ + datadir sysconfdir sharedstatedir localstatedir includedir \ + oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ + libdir localedir mandir +do + eval ac_val=\$$ac_var + # Remove trailing slashes. + case $ac_val in + */ ) + ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` + eval $ac_var=\$ac_val;; + esac + # Be sure to have absolute directory names. + case $ac_val in + [\\/$]* | ?:[\\/]* ) continue;; + NONE | '' ) case $ac_var in *prefix ) continue;; esac;; + esac + as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" +done + +# There might be people who depend on the old broken behavior: `$host' +# used to hold the argument of --host etc. +# FIXME: To remove some day. +build=$build_alias +host=$host_alias +target=$target_alias + +# FIXME: To remove some day. +if test "x$host_alias" != x; then + if test "x$build_alias" = x; then + cross_compiling=maybe + elif test "x$build_alias" != "x$host_alias"; then + cross_compiling=yes + fi +fi + +ac_tool_prefix= +test -n "$host_alias" && ac_tool_prefix=$host_alias- + +test "$silent" = yes && exec 6>/dev/null + + +ac_pwd=`pwd` && test -n "$ac_pwd" && +ac_ls_di=`ls -di .` && +ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || + as_fn_error $? "working directory cannot be determined" +test "X$ac_ls_di" = "X$ac_pwd_ls_di" || + as_fn_error $? "pwd does not report name of working directory" + + +# Find the source files, if location was not specified. +if test -z "$srcdir"; then + ac_srcdir_defaulted=yes + # Try the directory containing this script, then the parent directory. + ac_confdir=`$as_dirname -- "$as_myself" || +$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_myself" : 'X\(//\)[^/]' \| \ + X"$as_myself" : 'X\(//\)$' \| \ + X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_myself" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + srcdir=$ac_confdir + if test ! -r "$srcdir/$ac_unique_file"; then + srcdir=.. + fi +else + ac_srcdir_defaulted=no +fi +if test ! -r "$srcdir/$ac_unique_file"; then + test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." + as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" +fi +ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" +ac_abs_confdir=`( + cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" + pwd)` +# When building in place, set srcdir=. +if test "$ac_abs_confdir" = "$ac_pwd"; then + srcdir=. +fi +# Remove unnecessary trailing slashes from srcdir. +# Double slashes in file names in object file debugging info +# mess up M-x gdb in Emacs. +case $srcdir in +*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; +esac +for ac_var in $ac_precious_vars; do + eval ac_env_${ac_var}_set=\${${ac_var}+set} + eval ac_env_${ac_var}_value=\$${ac_var} + eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} + eval ac_cv_env_${ac_var}_value=\$${ac_var} +done + +# +# Report the --help message. +# +if test "$ac_init_help" = "long"; then + # Omit some internal or obsolete options to make the list less imposing. + # This message is too long to be a string in the A/UX 3.1 sh. + cat <<_ACEOF +\`configure' configures cudd 3.0.0 to adapt to many kinds of systems. + +Usage: $0 [OPTION]... [VAR=VALUE]... + +To assign environment variables (e.g., CC, CFLAGS...), specify them as +VAR=VALUE. See below for descriptions of some of the useful variables. + +Defaults for the options are specified in brackets. + +Configuration: + -h, --help display this help and exit + --help=short display options specific to this package + --help=recursive display the short help of all the included packages + -V, --version display version information and exit + -q, --quiet, --silent do not print \`checking ...' messages + --cache-file=FILE cache test results in FILE [disabled] + -C, --config-cache alias for \`--cache-file=config.cache' + -n, --no-create do not create output files + --srcdir=DIR find the sources in DIR [configure dir or \`..'] + +Installation directories: + --prefix=PREFIX install architecture-independent files in PREFIX + [$ac_default_prefix] + --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX + [PREFIX] + +By default, \`make install' will install all the files in +\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify +an installation prefix other than \`$ac_default_prefix' using \`--prefix', +for instance \`--prefix=\$HOME'. + +For better control, use the options below. + +Fine tuning of the installation directories: + --bindir=DIR user executables [EPREFIX/bin] + --sbindir=DIR system admin executables [EPREFIX/sbin] + --libexecdir=DIR program executables [EPREFIX/libexec] + --sysconfdir=DIR read-only single-machine data [PREFIX/etc] + --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] + --localstatedir=DIR modifiable single-machine data [PREFIX/var] + --libdir=DIR object code libraries [EPREFIX/lib] + --includedir=DIR C header files [PREFIX/include] + --oldincludedir=DIR C header files for non-gcc [/usr/include] + --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] + --datadir=DIR read-only architecture-independent data [DATAROOTDIR] + --infodir=DIR info documentation [DATAROOTDIR/info] + --localedir=DIR locale-dependent data [DATAROOTDIR/locale] + --mandir=DIR man documentation [DATAROOTDIR/man] + --docdir=DIR documentation root [DATAROOTDIR/doc/cudd] + --htmldir=DIR html documentation [DOCDIR] + --dvidir=DIR dvi documentation [DOCDIR] + --pdfdir=DIR pdf documentation [DOCDIR] + --psdir=DIR ps documentation [DOCDIR] +_ACEOF + + cat <<\_ACEOF + +Program names: + --program-prefix=PREFIX prepend PREFIX to installed program names + --program-suffix=SUFFIX append SUFFIX to installed program names + --program-transform-name=PROGRAM run sed PROGRAM on installed program names + +System types: + --build=BUILD configure for building on BUILD [guessed] + --host=HOST cross-compile to build programs to run on HOST [BUILD] +_ACEOF +fi + +if test -n "$ac_init_help"; then + case $ac_init_help in + short | recursive ) echo "Configuration of cudd 3.0.0:";; + esac + cat <<\_ACEOF + +Optional Features: + --disable-option-checking ignore unrecognized --enable/--with options + --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) + --enable-FEATURE[=ARG] include FEATURE [ARG=yes] + --enable-silent-rules less verbose build output (undo: "make V=1") + --disable-silent-rules verbose build output (undo: "make V=0") + --enable-dddmp include libdddmp in libcudd + --enable-obj include libobj in libcudd + --enable-dependency-tracking + do not reject slow dependency extractors + --disable-dependency-tracking + speeds up one-time build + --enable-shared[=PKGS] build shared libraries [default=no] + --enable-static[=PKGS] build static libraries [default=yes] + --enable-fast-install[=PKGS] + optimize for fast installation [default=yes] + --disable-libtool-lock avoid locking (might break parallel builds) + +Optional Packages: + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --with-system-qsort use system qsort instead of portable one + --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use + both] + --with-gnu-ld assume the C compiler uses GNU ld [default=no] + --with-sysroot=DIR Search for dependent libraries within DIR + (or the compiler's sysroot if not specified). + +Some influential environment variables: + CC C compiler command + CFLAGS C compiler flags + LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a + nonstandard directory <lib dir> + LIBS libraries to pass to the linker, e.g. -l<library> + CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if + you have headers in a nonstandard directory <include dir> + CXX C++ compiler command + CXXFLAGS C++ compiler flags + CPP C preprocessor + CXXCPP C++ preprocessor + +Use these variables to override the choices made by `configure' or to help +it to find libraries and programs with nonstandard names/locations. + +Report bugs to <Fabio@Colorado.EDU>. +_ACEOF +ac_status=$? +fi + +if test "$ac_init_help" = "recursive"; then + # If there are subdirs, report their specific --help. + for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue + test -d "$ac_dir" || + { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || + continue + ac_builddir=. + +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix + +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix + + cd "$ac_dir" || { ac_status=$?; continue; } + # Check for guested configure. + if test -f "$ac_srcdir/configure.gnu"; then + echo && + $SHELL "$ac_srcdir/configure.gnu" --help=recursive + elif test -f "$ac_srcdir/configure"; then + echo && + $SHELL "$ac_srcdir/configure" --help=recursive + else + $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 + fi || ac_status=$? + cd "$ac_pwd" || { ac_status=$?; break; } + done +fi + +test -n "$ac_init_help" && exit $ac_status +if $ac_init_version; then + cat <<\_ACEOF +cudd configure 3.0.0 +generated by GNU Autoconf 2.69 + +Copyright (C) 2012 Free Software Foundation, Inc. +This configure script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it. +_ACEOF + exit +fi + +## ------------------------ ## +## Autoconf initialization. ## +## ------------------------ ## + +# ac_fn_c_try_compile LINENO +# -------------------------- +# Try to compile conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext + if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_compile + +# ac_fn_cxx_try_compile LINENO +# ---------------------------- +# Try to compile conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext + if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_compile + +# ac_fn_c_try_link LINENO +# ----------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext conftest$ac_exeext + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + test -x conftest$ac_exeext + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_link + +# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES +# ------------------------------------------------------- +# Tests whether HEADER exists and can be compiled using the include files in +# INCLUDES, setting the cache variable VAR accordingly. +ac_fn_c_check_header_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +#include <$2> +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_header_compile + +# ac_fn_c_try_cpp LINENO +# ---------------------- +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_cpp () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } > conftest.i && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_cpp + +# ac_fn_c_try_run LINENO +# ---------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes +# that executables *can* be run. +ac_fn_c_try_run () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' + { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then : + ac_retval=0 +else + $as_echo "$as_me: program exited with status $ac_status" >&5 + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=$ac_status +fi + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_run + +# ac_fn_c_check_func LINENO FUNC VAR +# ---------------------------------- +# Tests whether FUNC exists, setting the cache variable VAR accordingly +ac_fn_c_check_func () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Define $2 to an innocuous variant, in case <limits.h> declares $2. + For example, HP-UX 11i <limits.h> declares gettimeofday. */ +#define $2 innocuous_$2 + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $2 (); below. + Prefer <limits.h> to <assert.h> if __STDC__ is defined, since + <limits.h> exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include <limits.h> +#else +# include <assert.h> +#endif + +#undef $2 + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char $2 (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_$2 || defined __stub___$2 +choke me +#endif + +int +main () +{ +return $2 (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_func + +# ac_fn_cxx_try_cpp LINENO +# ------------------------ +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_cpp () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } > conftest.i && { + test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || + test ! -s conftest.err + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_cpp + +# ac_fn_cxx_try_link LINENO +# ------------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext conftest$ac_exeext + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + test -x conftest$ac_exeext + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_link + +# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES +# ------------------------------------------------------- +# Tests whether HEADER exists, giving a warning if it cannot be compiled using +# the include files in INCLUDES and setting the cache variable VAR +# accordingly. +ac_fn_c_check_header_mongrel () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if eval \${$3+:} false; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +else + # Is the header compilable? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 +$as_echo_n "checking $2 usability... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +#include <$2> +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_header_compiler=yes +else + ac_header_compiler=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 +$as_echo "$ac_header_compiler" >&6; } + +# Is the header present? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 +$as_echo_n "checking $2 presence... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <$2> +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + ac_header_preproc=yes +else + ac_header_preproc=no +fi +rm -f conftest.err conftest.i conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 +$as_echo "$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( + yes:no: ) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 +$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} + ;; + no:yes:* ) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 +$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 +$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 +$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 +$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} +( $as_echo "## --------------------------------- ## +## Report this to Fabio@Colorado.EDU ## +## --------------------------------- ##" + ) | sed "s/^/$as_me: WARNING: /" >&2 + ;; +esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=\$ac_header_compiler" +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_header_mongrel + +# ac_fn_c_check_type LINENO TYPE VAR INCLUDES +# ------------------------------------------- +# Tests whether TYPE exists after having included INCLUDES, setting cache +# variable VAR accordingly. +ac_fn_c_check_type () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof ($2)) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof (($2))) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + eval "$3=yes" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_type + +# ac_fn_c_find_uintX_t LINENO BITS VAR +# ------------------------------------ +# Finds an unsigned integer type with width BITS, setting cache variable VAR +# accordingly. +ac_fn_c_find_uintX_t () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5 +$as_echo_n "checking for uint$2_t... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + # Order is important - never check a type that is potentially smaller + # than half of the expected target width. + for ac_type in uint$2_t 'unsigned int' 'unsigned long int' \ + 'unsigned long long int' 'unsigned short int' 'unsigned char'; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !((($ac_type) -1 >> ($2 / 2 - 1)) >> ($2 / 2 - 1) == 3)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + case $ac_type in #( + uint$2_t) : + eval "$3=yes" ;; #( + *) : + eval "$3=\$ac_type" ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + if eval test \"x\$"$3"\" = x"no"; then : + +else + break +fi + done +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_find_uintX_t + +# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES +# -------------------------------------------- +# Tries to find the compile-time value of EXPR in a program that includes +# INCLUDES, setting VAR accordingly. Returns whether the value could be +# computed +ac_fn_c_compute_int () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if test "$cross_compiling" = yes; then + # Depending upon the size, compute the lo and hi bounds. +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) >= 0)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_lo=0 ac_mid=0 + while :; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) <= $ac_mid)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_hi=$ac_mid; break +else + as_fn_arith $ac_mid + 1 && ac_lo=$as_val + if test $ac_lo -le $ac_mid; then + ac_lo= ac_hi= + break + fi + as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + done +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) < 0)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_hi=-1 ac_mid=-1 + while :; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) >= $ac_mid)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_lo=$ac_mid; break +else + as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val + if test $ac_mid -le $ac_hi; then + ac_lo= ac_hi= + break + fi + as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + done +else + ac_lo= ac_hi= +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +# Binary search between lo and hi bounds. +while test "x$ac_lo" != "x$ac_hi"; do + as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) <= $ac_mid)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_hi=$ac_mid +else + as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +done +case $ac_lo in #(( +?*) eval "$3=\$ac_lo"; ac_retval=0 ;; +'') ac_retval=1 ;; +esac + else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +static long int longval () { return $2; } +static unsigned long int ulongval () { return $2; } +#include <stdio.h> +#include <stdlib.h> +int +main () +{ + + FILE *f = fopen ("conftest.val", "w"); + if (! f) + return 1; + if (($2) < 0) + { + long int i = longval (); + if (i != ($2)) + return 1; + fprintf (f, "%ld", i); + } + else + { + unsigned long int i = ulongval (); + if (i != ($2)) + return 1; + fprintf (f, "%lu", i); + } + /* Do not output a trailing newline, as this causes \r\n confusion + on some platforms. */ + return ferror (f) || fclose (f) != 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + echo >>conftest.val; read $3 <conftest.val; ac_retval=0 +else + ac_retval=1 +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +rm -f conftest.val + + fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_compute_int +cat >config.log <<_ACEOF +This file contains any messages produced by compilers while +running configure, to aid debugging if configure makes a mistake. + +It was created by cudd $as_me 3.0.0, which was +generated by GNU Autoconf 2.69. Invocation command line was + + $ $0 $@ + +_ACEOF +exec 5>>config.log +{ +cat <<_ASUNAME +## --------- ## +## Platform. ## +## --------- ## + +hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` +uname -m = `(uname -m) 2>/dev/null || echo unknown` +uname -r = `(uname -r) 2>/dev/null || echo unknown` +uname -s = `(uname -s) 2>/dev/null || echo unknown` +uname -v = `(uname -v) 2>/dev/null || echo unknown` + +/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` +/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` + +/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` +/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` +/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` +/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` +/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` +/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` +/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` + +_ASUNAME + +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + $as_echo "PATH: $as_dir" + done +IFS=$as_save_IFS + +} >&5 + +cat >&5 <<_ACEOF + + +## ----------- ## +## Core tests. ## +## ----------- ## + +_ACEOF + + +# Keep a trace of the command line. +# Strip out --no-create and --no-recursion so they do not pile up. +# Strip out --silent because we don't want to record it for future runs. +# Also quote any args containing shell meta-characters. +# Make two passes to allow for proper duplicate-argument suppression. +ac_configure_args= +ac_configure_args0= +ac_configure_args1= +ac_must_keep_next=false +for ac_pass in 1 2 +do + for ac_arg + do + case $ac_arg in + -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil) + continue ;; + *\'*) + ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + case $ac_pass in + 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; + 2) + as_fn_append ac_configure_args1 " '$ac_arg'" + if test $ac_must_keep_next = true; then + ac_must_keep_next=false # Got value, back to normal. + else + case $ac_arg in + *=* | --config-cache | -C | -disable-* | --disable-* \ + | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ + | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ + | -with-* | --with-* | -without-* | --without-* | --x) + case "$ac_configure_args0 " in + "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; + esac + ;; + -* ) ac_must_keep_next=true ;; + esac + fi + as_fn_append ac_configure_args " '$ac_arg'" + ;; + esac + done +done +{ ac_configure_args0=; unset ac_configure_args0;} +{ ac_configure_args1=; unset ac_configure_args1;} + +# When interrupted or exit'd, cleanup temporary files, and complete +# config.log. We remove comments because anyway the quotes in there +# would cause problems or look ugly. +# WARNING: Use '\'' to represent an apostrophe within the trap. +# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. +trap 'exit_status=$? + # Save into config.log some information that might help in debugging. + { + echo + + $as_echo "## ---------------- ## +## Cache variables. ## +## ---------------- ##" + echo + # The following way of writing the cache mishandles newlines in values, +( + for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do + eval ac_val=\$$ac_var + case $ac_val in #( + *${as_nl}*) + case $ac_var in #( + *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + esac + case $ac_var in #( + _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( + *) { eval $ac_var=; unset $ac_var;} ;; + esac ;; + esac + done + (set) 2>&1 | + case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( + *${as_nl}ac_space=\ *) + sed -n \ + "s/'\''/'\''\\\\'\'''\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" + ;; #( + *) + sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" + ;; + esac | + sort +) + echo + + $as_echo "## ----------------- ## +## Output variables. ## +## ----------------- ##" + echo + for ac_var in $ac_subst_vars + do + eval ac_val=\$$ac_var + case $ac_val in + *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + esac + $as_echo "$ac_var='\''$ac_val'\''" + done | sort + echo + + if test -n "$ac_subst_files"; then + $as_echo "## ------------------- ## +## File substitutions. ## +## ------------------- ##" + echo + for ac_var in $ac_subst_files + do + eval ac_val=\$$ac_var + case $ac_val in + *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + esac + $as_echo "$ac_var='\''$ac_val'\''" + done | sort + echo + fi + + if test -s confdefs.h; then + $as_echo "## ----------- ## +## confdefs.h. ## +## ----------- ##" + echo + cat confdefs.h + echo + fi + test "$ac_signal" != 0 && + $as_echo "$as_me: caught signal $ac_signal" + $as_echo "$as_me: exit $exit_status" + } >&5 + rm -f core *.core core.conftest.* && + rm -f -r conftest* confdefs* conf$$* $ac_clean_files && + exit $exit_status +' 0 +for ac_signal in 1 2 13 15; do + trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal +done +ac_signal=0 + +# confdefs.h avoids OS command line length limits that DEFS can exceed. +rm -f -r conftest* confdefs.h + +$as_echo "/* confdefs.h */" > confdefs.h + +# Predefined preprocessor variables. + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_NAME "$PACKAGE_NAME" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_TARNAME "$PACKAGE_TARNAME" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_VERSION "$PACKAGE_VERSION" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_STRING "$PACKAGE_STRING" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_URL "$PACKAGE_URL" +_ACEOF + + +# Let the site file select an alternate cache file if it wants to. +# Prefer an explicitly selected file to automatically selected ones. +ac_site_file1=NONE +ac_site_file2=NONE +if test -n "$CONFIG_SITE"; then + # We do not want a PATH search for config.site. + case $CONFIG_SITE in #(( + -*) ac_site_file1=./$CONFIG_SITE;; + */*) ac_site_file1=$CONFIG_SITE;; + *) ac_site_file1=./$CONFIG_SITE;; + esac +elif test "x$prefix" != xNONE; then + ac_site_file1=$prefix/share/config.site + ac_site_file2=$prefix/etc/config.site +else + ac_site_file1=$ac_default_prefix/share/config.site + ac_site_file2=$ac_default_prefix/etc/config.site +fi +for ac_site_file in "$ac_site_file1" "$ac_site_file2" +do + test "x$ac_site_file" = xNONE && continue + if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 +$as_echo "$as_me: loading site script $ac_site_file" >&6;} + sed 's/^/| /' "$ac_site_file" >&5 + . "$ac_site_file" \ + || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "failed to load site script $ac_site_file +See \`config.log' for more details" "$LINENO" 5; } + fi +done + +if test -r "$cache_file"; then + # Some versions of bash will fail to source /dev/null (special files + # actually), so we avoid doing that. DJGPP emulates it as a regular file. + if test /dev/null != "$cache_file" && test -f "$cache_file"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 +$as_echo "$as_me: loading cache $cache_file" >&6;} + case $cache_file in + [\\/]* | ?:[\\/]* ) . "$cache_file";; + *) . "./$cache_file";; + esac + fi +else + { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 +$as_echo "$as_me: creating cache $cache_file" >&6;} + >$cache_file +fi + +# Check that the precious variables saved in the cache have kept the same +# value. +ac_cache_corrupted=false +for ac_var in $ac_precious_vars; do + eval ac_old_set=\$ac_cv_env_${ac_var}_set + eval ac_new_set=\$ac_env_${ac_var}_set + eval ac_old_val=\$ac_cv_env_${ac_var}_value + eval ac_new_val=\$ac_env_${ac_var}_value + case $ac_old_set,$ac_new_set in + set,) + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 +$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,set) + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 +$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,);; + *) + if test "x$ac_old_val" != "x$ac_new_val"; then + # differences in whitespace do not lead to failure. + ac_old_val_w=`echo x $ac_old_val` + ac_new_val_w=`echo x $ac_new_val` + if test "$ac_old_val_w" != "$ac_new_val_w"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 +$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} + ac_cache_corrupted=: + else + { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 +$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} + eval $ac_var=\$ac_old_val + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 +$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 +$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} + fi;; + esac + # Pass precious variables to config.status. + if test "$ac_new_set" = set; then + case $ac_new_val in + *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; + *) ac_arg=$ac_var=$ac_new_val ;; + esac + case " $ac_configure_args " in + *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. + *) as_fn_append ac_configure_args " '$ac_arg'" ;; + esac + fi +done +if $ac_cache_corrupted; then + { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 +$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} + as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 +fi +## -------------------- ## +## Main body of script. ## +## -------------------- ## + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +ac_aux_dir= +for ac_dir in build-aux "$srcdir"/build-aux; do + if test -f "$ac_dir/install-sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install-sh -c" + break + elif test -f "$ac_dir/install.sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install.sh -c" + break + elif test -f "$ac_dir/shtool"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/shtool install -c" + break + fi +done +if test -z "$ac_aux_dir"; then + as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5 +fi + +# These three variables are undocumented and unsupported, +# and are intended to be withdrawn in a future Autoconf release. +# They can cause serious problems if a builder's source tree is in a directory +# whose full name contains unusual characters. +ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. +ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. +ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. + + + +# Make sure we can run config.sub. +$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || + as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 +$as_echo_n "checking build system type... " >&6; } +if ${ac_cv_build+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_build_alias=$build_alias +test "x$ac_build_alias" = x && + ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` +test "x$ac_build_alias" = x && + as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 +ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 +$as_echo "$ac_cv_build" >&6; } +case $ac_cv_build in +*-*-*) ;; +*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; +esac +build=$ac_cv_build +ac_save_IFS=$IFS; IFS='-' +set x $ac_cv_build +shift +build_cpu=$1 +build_vendor=$2 +shift; shift +# Remember, the first character of IFS is used to create $*, +# except with old shells: +build_os=$* +IFS=$ac_save_IFS +case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 +$as_echo_n "checking host system type... " >&6; } +if ${ac_cv_host+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "x$host_alias" = x; then + ac_cv_host=$ac_cv_build +else + ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 +$as_echo "$ac_cv_host" >&6; } +case $ac_cv_host in +*-*-*) ;; +*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; +esac +host=$ac_cv_host +ac_save_IFS=$IFS; IFS='-' +set x $ac_cv_host +shift +host_cpu=$1 +host_vendor=$2 +shift; shift +# Remember, the first character of IFS is used to create $*, +# except with old shells: +host_os=$* +IFS=$ac_save_IFS +case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac + + +am__api_version='1.15' + +# Find a good install program. We prefer a C program (faster), +# so one script is as good as another. But avoid the broken or +# incompatible versions: +# SysV /etc/install, /usr/sbin/install +# SunOS /usr/etc/install +# IRIX /sbin/install +# AIX /bin/install +# AmigaOS /C/install, which installs bootblocks on floppy discs +# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag +# AFS /usr/afsws/bin/install, which mishandles nonexistent args +# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" +# OS/2's system install, which has a completely different semantic +# ./install, which can be erroneously created by make from ./install.sh. +# Reject install programs that cannot install multiple files. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 +$as_echo_n "checking for a BSD-compatible install... " >&6; } +if test -z "$INSTALL"; then +if ${ac_cv_path_install+:} false; then : + $as_echo_n "(cached) " >&6 +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + # Account for people who put trailing slashes in PATH elements. +case $as_dir/ in #(( + ./ | .// | /[cC]/* | \ + /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ + ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ + /usr/ucb/* ) ;; + *) + # OSF1 and SCO ODT 3.0 have their own names for install. + # Don't use installbsd from OSF since it installs stuff as root + # by default. + for ac_prog in ginstall scoinst install; do + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then + if test $ac_prog = install && + grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then + # AIX install. It has an incompatible calling convention. + : + elif test $ac_prog = install && + grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then + # program-specific install script used by HP pwplus--don't use. + : + else + rm -rf conftest.one conftest.two conftest.dir + echo one > conftest.one + echo two > conftest.two + mkdir conftest.dir + if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && + test -s conftest.one && test -s conftest.two && + test -s conftest.dir/conftest.one && + test -s conftest.dir/conftest.two + then + ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" + break 3 + fi + fi + fi + done + done + ;; +esac + + done +IFS=$as_save_IFS + +rm -rf conftest.one conftest.two conftest.dir + +fi + if test "${ac_cv_path_install+set}" = set; then + INSTALL=$ac_cv_path_install + else + # As a last resort, use the slow shell script. Don't cache a + # value for INSTALL within a source directory, because that will + # break other packages using the cache if that directory is + # removed, or if the value is a relative name. + INSTALL=$ac_install_sh + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 +$as_echo "$INSTALL" >&6; } + +# Use test -z because SunOS4 sh mishandles braces in ${var-val}. +# It thinks the first close brace ends the variable substitution. +test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' + +test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' + +test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 +$as_echo_n "checking whether build environment is sane... " >&6; } +# Reject unsafe characters in $srcdir or the absolute working directory +# name. Accept space and tab only in the latter. +am_lf=' +' +case `pwd` in + *[\\\"\#\$\&\'\`$am_lf]*) + as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; +esac +case $srcdir in + *[\\\"\#\$\&\'\`$am_lf\ \ ]*) + as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; +esac + +# Do 'set' in a subshell so we don't clobber the current shell's +# arguments. Must try -L first in case configure is actually a +# symlink; some systems play weird games with the mod time of symlinks +# (eg FreeBSD returns the mod time of the symlink's containing +# directory). +if ( + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$*" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$*" != "X $srcdir/configure conftest.file" \ + && test "$*" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + as_fn_error $? "ls -t appears to fail. Make sure there is not a broken + alias in your environment" "$LINENO" 5 + fi + if test "$2" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done + test "$2" = conftest.file + ) +then + # Ok. + : +else + as_fn_error $? "newly created file is older than distributed files! +Check your system clock" "$LINENO" 5 +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi + +rm -f conftest.file + +test "$program_prefix" != NONE && + program_transform_name="s&^&$program_prefix&;$program_transform_name" +# Use a double $ so make ignores it. +test "$program_suffix" != NONE && + program_transform_name="s&\$&$program_suffix&;$program_transform_name" +# Double any \ or $. +# By default was `s,x,x', remove it if useless. +ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' +program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` + +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` + +if test x"${MISSING+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; + *) + MISSING="\${SHELL} $am_aux_dir/missing" ;; + esac +fi +# Use eval to expand $SHELL +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " +else + am_missing_run= + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 +$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} +fi + +if test x"${install_sh+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; + *) + install_sh="\${SHELL} $am_aux_dir/install-sh" + esac +fi + +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right +# tool to use in cross-compilation environments, therefore Automake +# will honor the 'STRIP' environment variable to overrule this program. +if test "$cross_compiling" != no; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. +set dummy ${ac_tool_prefix}strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$STRIP"; then + ac_cv_prog_STRIP="$STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_STRIP="${ac_tool_prefix}strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_STRIP"; then + ac_ct_STRIP=$STRIP + # Extract the first word of "strip", so it can be a program name with args. +set dummy strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_STRIP"; then + ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_STRIP="strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP +if test -n "$ac_ct_STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_STRIP" = x; then + STRIP=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + STRIP=$ac_ct_STRIP + fi +else + STRIP="$ac_cv_prog_STRIP" +fi + +fi +INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 +$as_echo_n "checking for a thread-safe mkdir -p... " >&6; } +if test -z "$MKDIR_P"; then + if ${ac_cv_path_mkdir+:} false; then : + $as_echo_n "(cached) " >&6 +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in mkdir gmkdir; do + for ac_exec_ext in '' $ac_executable_extensions; do + as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue + case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( + 'mkdir (GNU coreutils) '* | \ + 'mkdir (coreutils) '* | \ + 'mkdir (fileutils) '4.1*) + ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext + break 3;; + esac + done + done + done +IFS=$as_save_IFS + +fi + + test -d ./--version && rmdir ./--version + if test "${ac_cv_path_mkdir+set}" = set; then + MKDIR_P="$ac_cv_path_mkdir -p" + else + # As a last resort, use the slow shell script. Don't cache a + # value for MKDIR_P within a source directory, because that will + # break other packages using the cache if that directory is + # removed, or if the value is a relative name. + MKDIR_P="$ac_install_sh -d" + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 +$as_echo "$MKDIR_P" >&6; } + +for ac_prog in gawk mawk nawk awk +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AWK+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AWK"; then + ac_cv_prog_AWK="$AWK" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AWK="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AWK=$ac_cv_prog_AWK +if test -n "$AWK"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 +$as_echo "$AWK" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$AWK" && break +done + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 +$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } +set x ${MAKE-make} +ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` +if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat >conftest.make <<\_ACEOF +SHELL = /bin/sh +all: + @echo '@@@%%%=$(MAKE)=@@@%%%' +_ACEOF +# GNU make sometimes prints "make[1]: Entering ...", which would confuse us. +case `${MAKE-make} -f conftest.make 2>/dev/null` in + *@@@%%%=?*=@@@%%%*) + eval ac_cv_prog_make_${ac_make}_set=yes;; + *) + eval ac_cv_prog_make_${ac_make}_set=no;; +esac +rm -f conftest.make +fi +if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + SET_MAKE= +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + SET_MAKE="MAKE=${MAKE-make}" +fi + +rm -rf .tst 2>/dev/null +mkdir .tst 2>/dev/null +if test -d .tst; then + am__leading_dot=. +else + am__leading_dot=_ +fi +rmdir .tst 2>/dev/null + +# Check whether --enable-silent-rules was given. +if test "${enable_silent_rules+set}" = set; then : + enableval=$enable_silent_rules; +fi + +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=1;; +esac +am_make=${MAKE-make} +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 +$as_echo_n "checking whether $am_make supports nested variables... " >&6; } +if ${am_cv_make_support_nested_variables+:} false; then : + $as_echo_n "(cached) " >&6 +else + if $as_echo 'TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 +$as_echo "$am_cv_make_support_nested_variables" >&6; } +if test $am_cv_make_support_nested_variables = yes; then + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AM_BACKSLASH='\' + +if test "`cd $srcdir && pwd`" != "`pwd`"; then + # Use -I$(srcdir) only when $(srcdir) != ., so that make's output + # is not polluted with repeated "-I." + am__isrc=' -I$(srcdir)' + # test to see if srcdir already configured + if test -f $srcdir/config.status; then + as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 + fi +fi + +# test whether we have cygpath +if test -z "$CYGPATH_W"; then + if (cygpath --version) >/dev/null 2>/dev/null; then + CYGPATH_W='cygpath -w' + else + CYGPATH_W=echo + fi +fi + + +# Define the identity of the package. + PACKAGE='cudd' + VERSION='3.0.0' + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE "$PACKAGE" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define VERSION "$VERSION" +_ACEOF + +# Some tools Automake needs. + +ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} + + +AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} + + +AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} + + +AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} + + +MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} + +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html> +# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html> +mkdir_p='$(MKDIR_P)' + +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. +# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AMTAR='$${TAR-tar}' + + +# We'll loop over all known methods to create a tar archive until one works. +_am_tools='gnutar pax cpio none' + +am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' + + + + + + +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542> + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: <http://www.gnu.org/software/coreutils/>. + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 + fi +fi + + + +# Check whether --enable-dddmp was given. +if test "${enable_dddmp+set}" = set; then : + enableval=$enable_dddmp; +fi + + if test x$enable_dddmp = xyes; then + DDDMP_TRUE= + DDDMP_FALSE='#' +else + DDDMP_TRUE='#' + DDDMP_FALSE= +fi + + +# Check whether --enable-obj was given. +if test "${enable_obj+set}" = set; then : + enableval=$enable_obj; +fi + + if test x$enable_obj = xyes; then + OBJ_TRUE= + OBJ_FALSE='#' +else + OBJ_TRUE='#' + OBJ_FALSE= +fi + + + +# Check whether --with-system-qsort was given. +if test "${with_system_qsort+set}" = set; then : + withval=$with_system_qsort; +else + with_system_qsort=no +fi + +if test x$with_system_qsort != xno ; then + +$as_echo "#define USE_SYSTEM_QSORT 1" >>confdefs.h + +fi + +# Set our own default (instead of "-g -O2") unless CFLAGS is already defined. +: ${CFLAGS="-Wall -Wextra -g -O3"} +: ${CXXFLAGS="-Wall -Wextra -std=c++0x -g -O3"} + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. +set dummy ${ac_tool_prefix}gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}gcc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_CC"; then + ac_ct_CC=$CC + # Extract the first word of "gcc", so it can be a program name with args. +set dummy gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="gcc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CC=$ac_ct_CC + fi +else + CC="$ac_cv_prog_CC" +fi + +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. +set dummy ${ac_tool_prefix}cc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}cc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + fi +fi +if test -z "$CC"; then + # Extract the first word of "cc", so it can be a program name with args. +set dummy cc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + ac_prog_rejected=no +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then + ac_prog_rejected=yes + continue + fi + ac_cv_prog_CC="cc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +if test $ac_prog_rejected = yes; then + # We found a bogon in the path, so make sure we never use it. + set dummy $ac_cv_prog_CC + shift + if test $# != 0; then + # We chose a different compiler from the bogus one. + # However, it has the same basename, so the bogon will be chosen + # first if we set CC to just the basename; use the full file name. + shift + ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" + fi +fi +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + for ac_prog in cl.exe + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$CC" && break + done +fi +if test -z "$CC"; then + ac_ct_CC=$CC + for ac_prog in cl.exe +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_CC" && break +done + + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CC=$ac_ct_CC + fi +fi + +fi + + +test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "no acceptable C compiler found in \$PATH +See \`config.log' for more details" "$LINENO" 5; } + +# Provide some information about the compiler. +$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +for ac_option in --version -v -V -qversion; do + { { ac_try="$ac_compiler $ac_option >&5" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +done + +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" +# Try to create an executable without -o first, disregard a.out. +# It will help us diagnose broken compilers, and finding out an intuition +# of exeext. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 +$as_echo_n "checking whether the C compiler works... " >&6; } +ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` + +# The possible output files: +ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" + +ac_rmfiles= +for ac_file in $ac_files +do + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; + * ) ac_rmfiles="$ac_rmfiles $ac_file";; + esac +done +rm -f $ac_rmfiles + +if { { ac_try="$ac_link_default" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link_default") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. +# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' +# in a Makefile. We should not override ac_cv_exeext if it was cached, +# so that the user can short-circuit this test for compilers unknown to +# Autoconf. +for ac_file in $ac_files '' +do + test -f "$ac_file" || continue + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) + ;; + [ab].out ) + # We found the default executable, but exeext='' is most + # certainly right. + break;; + *.* ) + if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; + then :; else + ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` + fi + # We set ac_cv_exeext here because the later test for it is not + # safe: cross compilers may not add the suffix if given an `-o' + # argument, so we may need to know it at that point already. + # Even if this section looks crufty: it has the advantage of + # actually working. + break;; + * ) + break;; + esac +done +test "$ac_cv_exeext" = no && ac_cv_exeext= + +else + ac_file='' +fi +if test -z "$ac_file"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +$as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "C compiler cannot create executables +See \`config.log' for more details" "$LINENO" 5; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 +$as_echo_n "checking for C compiler default output file name... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 +$as_echo "$ac_file" >&6; } +ac_exeext=$ac_cv_exeext + +rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out +ac_clean_files=$ac_clean_files_save +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 +$as_echo_n "checking for suffix of executables... " >&6; } +if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + # If both `conftest.exe' and `conftest' are `present' (well, observable) +# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will +# work properly (i.e., refer to `conftest.exe'), while it won't with +# `rm'. +for ac_file in conftest.exe conftest conftest.*; do + test -f "$ac_file" || continue + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; + *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` + break;; + * ) break;; + esac +done +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot compute suffix of executables: cannot compile and link +See \`config.log' for more details" "$LINENO" 5; } +fi +rm -f conftest conftest$ac_cv_exeext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 +$as_echo "$ac_cv_exeext" >&6; } + +rm -f conftest.$ac_ext +EXEEXT=$ac_cv_exeext +ac_exeext=$EXEEXT +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <stdio.h> +int +main () +{ +FILE *f = fopen ("conftest.out", "w"); + return ferror (f) || fclose (f) != 0; + + ; + return 0; +} +_ACEOF +ac_clean_files="$ac_clean_files conftest.out" +# Check that the compiler produces executables we can run. If not, either +# the compiler is broken, or we cross compile. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 +$as_echo_n "checking whether we are cross compiling... " >&6; } +if test "$cross_compiling" != yes; then + { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if { ac_try='./conftest$ac_cv_exeext' + { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then + cross_compiling=no + else + if test "$cross_compiling" = maybe; then + cross_compiling=yes + else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot run C compiled programs. +If you meant to cross compile, use \`--host'. +See \`config.log' for more details" "$LINENO" 5; } + fi + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 +$as_echo "$cross_compiling" >&6; } + +rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out +ac_clean_files=$ac_clean_files_save +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 +$as_echo_n "checking for suffix of object files... " >&6; } +if ${ac_cv_objext+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +rm -f conftest.o conftest.obj +if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + for ac_file in conftest.o conftest.obj conftest.*; do + test -f "$ac_file" || continue; + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; + *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` + break;; + esac +done +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot compute suffix of object files: cannot compile +See \`config.log' for more details" "$LINENO" 5; } +fi +rm -f conftest.$ac_cv_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 +$as_echo "$ac_cv_objext" >&6; } +OBJEXT=$ac_cv_objext +ac_objext=$OBJEXT +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 +$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } +if ${ac_cv_c_compiler_gnu+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ +#ifndef __GNUC__ + choke me +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_compiler_gnu=yes +else + ac_compiler_gnu=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_c_compiler_gnu=$ac_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 +$as_echo "$ac_cv_c_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GCC=yes +else + GCC= +fi +ac_test_CFLAGS=${CFLAGS+set} +ac_save_CFLAGS=$CFLAGS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 +$as_echo_n "checking whether $CC accepts -g... " >&6; } +if ${ac_cv_prog_cc_g+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_save_c_werror_flag=$ac_c_werror_flag + ac_c_werror_flag=yes + ac_cv_prog_cc_g=no + CFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_g=yes +else + CFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + ac_c_werror_flag=$ac_save_c_werror_flag + CFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_g=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_c_werror_flag=$ac_save_c_werror_flag +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 +$as_echo "$ac_cv_prog_cc_g" >&6; } +if test "$ac_test_CFLAGS" = set; then + CFLAGS=$ac_save_CFLAGS +elif test $ac_cv_prog_cc_g = yes; then + if test "$GCC" = yes; then + CFLAGS="-g -O2" + else + CFLAGS="-g" + fi +else + if test "$GCC" = yes; then + CFLAGS="-O2" + else + CFLAGS= + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 +$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } +if ${ac_cv_prog_cc_c89+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_prog_cc_c89=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <stdarg.h> +#include <stdio.h> +struct stat; +/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ +struct buf { int x; }; +FILE * (*rcsopen) (struct buf *, struct stat *, int); +static char *e (p, i) + char **p; + int i; +{ + return p[i]; +} +static char *f (char * (*g) (char **, int), char **p, ...) +{ + char *s; + va_list v; + va_start (v,p); + s = g (p, va_arg (v,int)); + va_end (v); + return s; +} + +/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has + function prototypes and stuff, but not '\xHH' hex character constants. + These don't provoke an error unfortunately, instead are silently treated + as 'x'. The following induces an error, until -std is added to get + proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an + array size at least. It's necessary to write '\x00'==0 to get something + that's true only with -std. */ +int osf4_cc_array ['\x00' == 0 ? 1 : -1]; + +/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters + inside strings and character constants. */ +#define FOO(x) 'x' +int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; + +int test (int i, double x); +struct s1 {int (*f) (int a);}; +struct s2 {int (*f) (double a);}; +int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); +int argc; +char **argv; +int +main () +{ +return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; + ; + return 0; +} +_ACEOF +for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ + -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_c89=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c89" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC + +fi +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c89" in + x) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c89" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 +$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; +esac +if test "x$ac_cv_prog_cc_c89" != xno; then : + +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 +$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } +if ${am_cv_prog_cc_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 + ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 +$as_echo "$am_cv_prog_cc_c_o" >&6; } +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +DEPDIR="${am__leading_dot}deps" + +ac_config_commands="$ac_config_commands depfiles" + + +am_make=${MAKE-make} +cat > confinc << 'END' +am__doit: + @echo this is the am__doit target +.PHONY: am__doit +END +# If we don't find an include directive, just comment out the code. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 +$as_echo_n "checking for style of include used by $am_make... " >&6; } +am__include="#" +am__quote= +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# Ignore all kinds of additional output from 'make'. +case `$am_make -s -f confmf 2> /dev/null` in #( +*the\ am__doit\ target*) + am__include=include + am__quote= + _am_result=GNU + ;; +esac +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + case `$am_make -s -f confmf 2> /dev/null` in #( + *the\ am__doit\ target*) + am__include=.include + am__quote="\"" + _am_result=BSD + ;; + esac +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 +$as_echo "$_am_result" >&6; } +rm -f confinc confmf + +# Check whether --enable-dependency-tracking was given. +if test "${enable_dependency_tracking+set}" = set; then : + enableval=$enable_dependency_tracking; +fi + +if test "x$enable_dependency_tracking" != xno; then + am_depcomp="$ac_aux_dir/depcomp" + AMDEPBACKSLASH='\' + am__nodep='_no' +fi + if test "x$enable_dependency_tracking" != xno; then + AMDEP_TRUE= + AMDEP_FALSE='#' +else + AMDEP_TRUE='#' + AMDEP_FALSE= +fi + + + +depcc="$CC" am_compiler_list= + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if ${am_cv_CC_dependencies_compiler_type+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_CC_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CC_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_CC_dependencies_compiler_type=none +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } +CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type + + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then + am__fastdepCC_TRUE= + am__fastdepCC_FALSE='#' +else + am__fastdepCC_TRUE='#' + am__fastdepCC_FALSE= +fi + + +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +if test -z "$CXX"; then + if test -n "$CCC"; then + CXX=$CCC + else + if test -n "$ac_tool_prefix"; then + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CXX"; then + ac_cv_prog_CXX="$CXX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CXX=$ac_cv_prog_CXX +if test -n "$CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 +$as_echo "$CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$CXX" && break + done +fi +if test -z "$CXX"; then + ac_ct_CXX=$CXX + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CXX"; then + ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CXX="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CXX=$ac_cv_prog_ac_ct_CXX +if test -n "$ac_ct_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 +$as_echo "$ac_ct_CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_CXX" && break +done + + if test "x$ac_ct_CXX" = x; then + CXX="g++" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CXX=$ac_ct_CXX + fi +fi + + fi +fi +# Provide some information about the compiler. +$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +for ac_option in --version -v -V -qversion; do + { { ac_try="$ac_compiler $ac_option >&5" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +done + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 +$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } +if ${ac_cv_cxx_compiler_gnu+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ +#ifndef __GNUC__ + choke me +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_compiler_gnu=yes +else + ac_compiler_gnu=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_cxx_compiler_gnu=$ac_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 +$as_echo "$ac_cv_cxx_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GXX=yes +else + GXX= +fi +ac_test_CXXFLAGS=${CXXFLAGS+set} +ac_save_CXXFLAGS=$CXXFLAGS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 +$as_echo_n "checking whether $CXX accepts -g... " >&6; } +if ${ac_cv_prog_cxx_g+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_save_cxx_werror_flag=$ac_cxx_werror_flag + ac_cxx_werror_flag=yes + ac_cv_prog_cxx_g=no + CXXFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_cv_prog_cxx_g=yes +else + CXXFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + +else + ac_cxx_werror_flag=$ac_save_cxx_werror_flag + CXXFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_cv_prog_cxx_g=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_cxx_werror_flag=$ac_save_cxx_werror_flag +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 +$as_echo "$ac_cv_prog_cxx_g" >&6; } +if test "$ac_test_CXXFLAGS" = set; then + CXXFLAGS=$ac_save_CXXFLAGS +elif test $ac_cv_prog_cxx_g = yes; then + if test "$GXX" = yes; then + CXXFLAGS="-g -O2" + else + CXXFLAGS="-g" + fi +else + if test "$GXX" = yes; then + CXXFLAGS="-O2" + else + CXXFLAGS= + fi +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +depcc="$CXX" am_compiler_list= + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if ${am_cv_CXX_dependencies_compiler_type+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_CXX_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CXX_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_CXX_dependencies_compiler_type=none +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; } +CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type + + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then + am__fastdepCXX_TRUE= + am__fastdepCXX_FALSE='#' +else + am__fastdepCXX_TRUE='#' + am__fastdepCXX_FALSE= +fi + + + +if test -n "$ac_tool_prefix"; then + for ac_prog in ar lib "link -lib" + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AR="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +$as_echo "$AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$AR" && break + done +fi +if test -z "$AR"; then + ac_ct_AR=$AR + for ac_prog in ar lib "link -lib" +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AR"; then + ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_AR="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_AR=$ac_cv_prog_ac_ct_AR +if test -n "$ac_ct_AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +$as_echo "$ac_ct_AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_AR" && break +done + + if test "x$ac_ct_AR" = x; then + AR="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AR=$ac_ct_AR + fi +fi + +: ${AR=ar} + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the archiver ($AR) interface" >&5 +$as_echo_n "checking the archiver ($AR) interface... " >&6; } +if ${am_cv_ar_interface+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + am_cv_ar_interface=ar + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int some_variable = 0; +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5 + (eval $am_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -eq 0; then + am_cv_ar_interface=ar + else + am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5 + (eval $am_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -eq 0; then + am_cv_ar_interface=lib + else + am_cv_ar_interface=unknown + fi + fi + rm -f conftest.lib libconftest.a + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_ar_interface" >&5 +$as_echo "$am_cv_ar_interface" >&6; } + +case $am_cv_ar_interface in +ar) + ;; +lib) + # Microsoft lib, so override with the ar-lib wrapper script. + # FIXME: It is wrong to rewrite AR. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__AR in this case, + # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something + # similar. + AR="$am_aux_dir/ar-lib $AR" + ;; +unknown) + as_fn_error $? "could not determine $AR interface" "$LINENO" 5 + ;; +esac + + +case `pwd` in + *\ * | *\ *) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 +$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; +esac + + + +macro_version='2.4.2' +macro_revision='1.3337' + + + + + + + + + + + + + +ltmain="$ac_aux_dir/ltmain.sh" + +# Backslashify metacharacters that are still active within +# double-quoted strings. +sed_quote_subst='s/\(["`$\\]\)/\\\1/g' + +# Same as above, but do not quote variable references. +double_quote_subst='s/\(["`\\]\)/\\\1/g' + +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' + +# Sed substitution to delay expansion of an escaped single quote. +delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' + +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' + +ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 +$as_echo_n "checking how to print strings... " >&6; } +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' +else + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' +fi + +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "" +} + +case "$ECHO" in + printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 +$as_echo "printf" >&6; } ;; + print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 +$as_echo "print -r" >&6; } ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 +$as_echo "cat" >&6; } ;; +esac + + + + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if ${ac_cv_path_SED+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + { ac_script=; unset ac_script;} + if test -z "$SED"; then + ac_path_SED_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_SED" || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in +*GNU*) + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_SED_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_SED_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 + fi +else + ac_cv_path_SED=$SED +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +$as_echo "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed + +test -z "$SED" && SED=sed +Xsed="$SED -e 1s/^X//" + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 +$as_echo_n "checking for grep that handles long lines and -e... " >&6; } +if ${ac_cv_path_GREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$GREP"; then + ac_path_GREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in grep ggrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_GREP" || continue +# Check for GNU ac_path_GREP and select it if it is found. + # Check for GNU $ac_path_GREP +case `"$ac_path_GREP" --version 2>&1` in +*GNU*) + ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'GREP' >> "conftest.nl" + "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_GREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_GREP="$ac_path_GREP" + ac_path_GREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_GREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_GREP"; then + as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_GREP=$GREP +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 +$as_echo "$ac_cv_path_GREP" >&6; } + GREP="$ac_cv_path_GREP" + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 +$as_echo_n "checking for egrep... " >&6; } +if ${ac_cv_path_EGREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 + then ac_cv_path_EGREP="$GREP -E" + else + if test -z "$EGREP"; then + ac_path_EGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in egrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_EGREP" || continue +# Check for GNU ac_path_EGREP and select it if it is found. + # Check for GNU $ac_path_EGREP +case `"$ac_path_EGREP" --version 2>&1` in +*GNU*) + ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'EGREP' >> "conftest.nl" + "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_EGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_EGREP="$ac_path_EGREP" + ac_path_EGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_EGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_EGREP"; then + as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_EGREP=$EGREP +fi + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 +$as_echo "$ac_cv_path_EGREP" >&6; } + EGREP="$ac_cv_path_EGREP" + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 +$as_echo_n "checking for fgrep... " >&6; } +if ${ac_cv_path_FGREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 + then ac_cv_path_FGREP="$GREP -F" + else + if test -z "$FGREP"; then + ac_path_FGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in fgrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_FGREP" || continue +# Check for GNU ac_path_FGREP and select it if it is found. + # Check for GNU $ac_path_FGREP +case `"$ac_path_FGREP" --version 2>&1` in +*GNU*) + ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'FGREP' >> "conftest.nl" + "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_FGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_FGREP="$ac_path_FGREP" + ac_path_FGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_FGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_FGREP"; then + as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_FGREP=$FGREP +fi + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 +$as_echo "$ac_cv_path_FGREP" >&6; } + FGREP="$ac_cv_path_FGREP" + + +test -z "$GREP" && GREP=grep + + + + + + + + + + + + + + + + + + + +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes +else + with_gnu_ld=no +fi + +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in + *GNU* | *'with BFD'*) + test "$with_gnu_ld" != no && break + ;; + *) + test "$with_gnu_ld" != yes && break + ;; + esac + fi + done + IFS="$lt_save_ifs" +else + lt_cv_path_LD="$LD" # Let the user override the test with a path. +fi +fi + +LD="$lt_cv_path_LD" +if test -n "$LD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 </dev/null` in +*GNU* | *'with BFD'*) + lt_cv_prog_gnu_ld=yes + ;; +*) + lt_cv_prog_gnu_ld=no + ;; +esac +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 +$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } +if ${lt_cv_path_NM+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM="$NM" +else + lt_nm_to_check="${ac_tool_prefix}nm" + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + tmp_nm="$ac_dir/$lt_tmp_nm" + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the `sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in + */dev/null* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break + ;; + *) + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac + ;; + esac + fi + done + IFS="$lt_save_ifs" + done + : ${lt_cv_path_NM=no} +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 +$as_echo "$lt_cv_path_NM" >&6; } +if test "$lt_cv_path_NM" != "no"; then + NM="$lt_cv_path_NM" +else + # Didn't find any BSD compatible name lister, look for dumpbin. + if test -n "$DUMPBIN"; then : + # Let the user override the test. + else + if test -n "$ac_tool_prefix"; then + for ac_prog in dumpbin "link -dump" + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DUMPBIN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DUMPBIN"; then + ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DUMPBIN=$ac_cv_prog_DUMPBIN +if test -n "$DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 +$as_echo "$DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$DUMPBIN" && break + done +fi +if test -z "$DUMPBIN"; then + ac_ct_DUMPBIN=$DUMPBIN + for ac_prog in dumpbin "link -dump" +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DUMPBIN"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN +if test -n "$ac_ct_DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 +$as_echo "$ac_ct_DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_DUMPBIN" && break +done + + if test "x$ac_ct_DUMPBIN" = x; then + DUMPBIN=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DUMPBIN=$ac_ct_DUMPBIN + fi +fi + + case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols" + ;; + *) + DUMPBIN=: + ;; + esac + fi + + if test "$DUMPBIN" != ":"; then + NM="$DUMPBIN" + fi +fi +test -z "$NM" && NM=nm + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 +$as_echo_n "checking the name lister ($NM) interface... " >&6; } +if ${lt_cv_nm_interface+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_nm_interface="BSD nm" + echo "int some_variable = 0;" > conftest.$ac_ext + (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: output\"" >&5) + cat conftest.out >&5 + if $GREP 'External.*some_variable' conftest.out > /dev/null; then + lt_cv_nm_interface="MS dumpbin" + fi + rm -f conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 +$as_echo "$lt_cv_nm_interface" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 +$as_echo_n "checking whether ln -s works... " >&6; } +LN_S=$as_ln_s +if test "$LN_S" = "ln -s"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 +$as_echo "no, using $LN_S" >&6; } +fi + +# find the maximum length of command line arguments +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 +$as_echo_n "checking the maximum length of command line arguments... " >&6; } +if ${lt_cv_sys_max_cmd_len+:} false; then : + $as_echo_n "(cached) " >&6 +else + i=0 + teststring="ABCD" + + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; + + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; + + cygwin* | mingw* | cegcc*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; + + mint*) + # On MiNT this can take a long time and run out of memory. + lt_cv_sys_max_cmd_len=8192; + ;; + + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; + + netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + + os2*) + # The test takes a long time on OS/2. + lt_cv_sys_max_cmd_len=8192 + ;; + + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi + ;; + *) + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len" && \ + test undefined != "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + # Make teststring a little bigger before we do anything with it. + # a 1K string should be a reasonable start. + for i in 1 2 3 4 5 6 7 8 ; do + teststring=$teststring$teststring + done + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + # If test is not a shell built-in, we'll probably end up computing a + # maximum length that is only half of the actual maximum length, but + # we can't tell. + while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \ + = "X$teststring$teststring"; } >/dev/null 2>&1 && + test $i != 17 # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + # Only check the string length outside the loop. + lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` + teststring= + # Add a significant safety factor because C++ compilers can tack on + # massive amounts of additional arguments before passing them to the + # linker. It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi + ;; + esac + +fi + +if test -n $lt_cv_sys_max_cmd_len ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 +$as_echo "$lt_cv_sys_max_cmd_len" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 +$as_echo "none" >&6; } +fi +max_cmd_len=$lt_cv_sys_max_cmd_len + + + + + + +: ${CP="cp -f"} +: ${MV="mv -f"} +: ${RM="rm -f"} + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5 +$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; } +# Try some XSI features +xsi_shell=no +( _lt_dummy="a/b/c" + test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ + = c,a/b,b/c, \ + && eval 'test $(( 1 + 1 )) -eq 2 \ + && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ + && xsi_shell=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5 +$as_echo "$xsi_shell" >&6; } + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5 +$as_echo_n "checking whether the shell understands \"+=\"... " >&6; } +lt_shell_append=no +( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \ + >/dev/null 2>&1 \ + && lt_shell_append=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5 +$as_echo "$lt_shell_append" >&6; } + + +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + lt_unset=unset +else + lt_unset=false +fi + + + + + +# test EBCDIC or ASCII +case `echo X|tr X '\101'` in + A) # ASCII based system + # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr + lt_SP2NL='tr \040 \012' + lt_NL2SP='tr \015\012 \040\040' + ;; + *) # EBCDIC based system + lt_SP2NL='tr \100 \n' + lt_NL2SP='tr \r\n \100\100' + ;; +esac + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; } +if ${lt_cv_to_host_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; + esac + ;; + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; + esac + ;; + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; +esac + +fi + +to_host_file_cmd=$lt_cv_to_host_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 +$as_echo "$lt_cv_to_host_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } +if ${lt_cv_to_tool_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + #assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 + ;; + esac + ;; +esac + +fi + +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 +$as_echo "$lt_cv_to_tool_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 +$as_echo_n "checking for $LD option to reload object files... " >&6; } +if ${lt_cv_ld_reload_flag+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_reload_flag='-r' +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 +$as_echo "$lt_cv_ld_reload_flag" >&6; } +reload_flag=$lt_cv_ld_reload_flag +case $reload_flag in +"" | " "*) ;; +*) reload_flag=" $reload_flag" ;; +esac +reload_cmds='$LD$reload_flag -o $output$reload_objs' +case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + if test "$GCC" != yes; then + reload_cmds=false + fi + ;; + darwin*) + if test "$GCC" = yes; then + reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' + else + reload_cmds='$LD$reload_flag -o $output$reload_objs' + fi + ;; +esac + + + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. +set dummy ${ac_tool_prefix}objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OBJDUMP"; then + ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OBJDUMP=$ac_cv_prog_OBJDUMP +if test -n "$OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 +$as_echo "$OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OBJDUMP"; then + ac_ct_OBJDUMP=$OBJDUMP + # Extract the first word of "objdump", so it can be a program name with args. +set dummy objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OBJDUMP"; then + ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OBJDUMP="objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP +if test -n "$ac_ct_OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 +$as_echo "$ac_ct_OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OBJDUMP" = x; then + OBJDUMP="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OBJDUMP=$ac_ct_OBJDUMP + fi +else + OBJDUMP="$ac_cv_prog_OBJDUMP" +fi + +test -z "$OBJDUMP" && OBJDUMP=objdump + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 +$as_echo_n "checking how to recognize dependent libraries... " >&6; } +if ${lt_cv_deplibs_check_method+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_file_magic_cmd='$MAGIC_CMD' +lt_cv_file_magic_test_file= +lt_cv_deplibs_check_method='unknown' +# Need to set the preceding variable on all platforms that support +# interlibrary dependencies. +# 'none' -- dependencies not supported. +# `unknown' -- same as none, but documents that we really don't know. +# 'pass_all' -- all dependencies passed with no checks. +# 'test_compile' -- check by making test program. +# 'file_magic [[regex]]' -- check by looking for files in library path +# which responds to the $file_magic_cmd with a given extended regex. +# If you have `file' or equivalent on your system and you're not sure +# whether `pass_all' will *always* work, you probably want this one. + +case $host_os in +aix[4-9]*) + lt_cv_deplibs_check_method=pass_all + ;; + +beos*) + lt_cv_deplibs_check_method=pass_all + ;; + +bsdi[45]*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' + lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_test_file=/shlib/libc.so + ;; + +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; + +mingw* | pw32*) + # Base MSYS/MinGW do not provide the 'file' command needed by + # func_win32_libid shell function, so use a weaker test based on 'objdump', + # unless we find 'file', for example because we are cross-compiling. + # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. + if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + else + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_file_magic_cmd='$OBJDUMP -f' + fi + ;; + +cegcc*) + # use the weaker test based on 'objdump'. See mingw*. + lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + ;; + +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; + +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; + esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; + +haiku*) + lt_cv_deplibs_check_method=pass_all + ;; + +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; + +interix[3-9]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' + ;; + +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + lt_cv_deplibs_check_method=pass_all + ;; + +netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' + fi + ;; + +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; + +*nto* | *qnx*) + lt_cv_deplibs_check_method=pass_all + ;; + +openbsd*) + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + fi + ;; + +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; + +rdos*) + lt_cv_deplibs_check_method=pass_all + ;; + +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv4 | sysv4.3*) + case $host_vendor in + motorola) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` + ;; + ncr) + lt_cv_deplibs_check_method=pass_all + ;; + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' + ;; + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so + ;; + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + pc) + lt_cv_deplibs_check_method=pass_all + ;; + esac + ;; + +tpf*) + lt_cv_deplibs_check_method=pass_all + ;; +esac + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 +$as_echo "$lt_cv_deplibs_check_method" >&6; } + +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` + fi + ;; + esac +fi + +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown + + + + + + + + + + + + + + + + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. +set dummy ${ac_tool_prefix}dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DLLTOOL"; then + ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DLLTOOL=$ac_cv_prog_DLLTOOL +if test -n "$DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 +$as_echo "$DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DLLTOOL"; then + ac_ct_DLLTOOL=$DLLTOOL + # Extract the first word of "dlltool", so it can be a program name with args. +set dummy dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DLLTOOL"; then + ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DLLTOOL="dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL +if test -n "$ac_ct_DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 +$as_echo "$ac_ct_DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DLLTOOL" = x; then + DLLTOOL="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DLLTOOL=$ac_ct_DLLTOOL + fi +else + DLLTOOL="$ac_cv_prog_DLLTOOL" +fi + +test -z "$DLLTOOL" && DLLTOOL=dlltool + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; } +if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_sharedlib_from_linklib_cmd='unknown' + +case $host_os in +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh + # decide which to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib + ;; + *) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback + ;; + esac + ;; +*) + # fallback: assume linklib IS sharedlib + lt_cv_sharedlib_from_linklib_cmd="$ECHO" + ;; +esac + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 +$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO + + + + + + + +if test -n "$ac_tool_prefix"; then + for ac_prog in ar + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AR="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +$as_echo "$AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$AR" && break + done +fi +if test -z "$AR"; then + ac_ct_AR=$AR + for ac_prog in ar +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AR"; then + ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_AR="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_AR=$ac_cv_prog_ac_ct_AR +if test -n "$ac_ct_AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +$as_echo "$ac_ct_AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_AR" && break +done + + if test "x$ac_ct_AR" = x; then + AR="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AR=$ac_ct_AR + fi +fi + +: ${AR=ar} +: ${AR_FLAGS=cru} + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 +$as_echo_n "checking for archiver @FILE support... " >&6; } +if ${lt_cv_ar_at_file+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ar_at_file=no + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -eq 0; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -ne 0; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 +$as_echo "$lt_cv_ar_at_file" >&6; } + +if test "x$lt_cv_ar_at_file" = xno; then + archiver_list_spec= +else + archiver_list_spec=$lt_cv_ar_at_file +fi + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. +set dummy ${ac_tool_prefix}strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$STRIP"; then + ac_cv_prog_STRIP="$STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_STRIP="${ac_tool_prefix}strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_STRIP"; then + ac_ct_STRIP=$STRIP + # Extract the first word of "strip", so it can be a program name with args. +set dummy strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_STRIP"; then + ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_STRIP="strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP +if test -n "$ac_ct_STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_STRIP" = x; then + STRIP=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + STRIP=$ac_ct_STRIP + fi +else + STRIP="$ac_cv_prog_STRIP" +fi + +test -z "$STRIP" && STRIP=: + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. +set dummy ${ac_tool_prefix}ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_RANLIB+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +RANLIB=$ac_cv_prog_RANLIB +if test -n "$RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 +$as_echo "$RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_RANLIB"; then + ac_ct_RANLIB=$RANLIB + # Extract the first word of "ranlib", so it can be a program name with args. +set dummy ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_RANLIB"; then + ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_RANLIB="ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB +if test -n "$ac_ct_RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 +$as_echo "$ac_ct_RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_RANLIB" = x; then + RANLIB=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + RANLIB=$ac_ct_RANLIB + fi +else + RANLIB="$ac_cv_prog_RANLIB" +fi + +test -z "$RANLIB" && RANLIB=: + + + + + + +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= + +if test -n "$RANLIB"; then + case $host_os in + openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" + ;; + *) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" +fi + +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + + +# Check for command to grab the raw symbol name followed by C symbol from nm. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 +$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } +if ${lt_cv_sys_global_symbol_pipe+:} false; then : + $as_echo_n "(cached) " >&6 +else + +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] + +# Character class describing NM global symbol codes. +symcode='[BCDEGRST]' + +# Regexp to match symbols that can be accessed directly from C. +sympat='\([_A-Za-z][_A-Za-z0-9]*\)' + +# Define system-specific variables. +case $host_os in +aix*) + symcode='[BCDT]' + ;; +cygwin* | mingw* | pw32* | cegcc*) + symcode='[ABCDGISTW]' + ;; +hpux*) + if test "$host_cpu" = ia64; then + symcode='[ABCDEGRST]' + fi + ;; +irix* | nonstopux*) + symcode='[BCDEGRST]' + ;; +osf*) + symcode='[BCDEGQRST]' + ;; +solaris*) + symcode='[BDRT]' + ;; +sco3.2v5*) + symcode='[DT]' + ;; +sysv4.2uw2*) + symcode='[DT]' + ;; +sysv5* | sco5v6* | unixware* | OpenUNIX*) + symcode='[ABDT]' + ;; +sysv4) + symcode='[DFNSTU]' + ;; +esac + +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[ABCDGIRSTW]' ;; +esac + +# Transform an extracted symbol line into a proper C declaration. +# Some systems (esp. on ia64) link data and code symbols differently, +# so use this general approach. +lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" + +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'" +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'" + +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac + +# Try without a prefix underscore, then with it. +for ac_symprfx in "" "_"; do + + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" + + # Write the raw and C identifiers. + if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Fake it for dumpbin and say T for any non-static function + # and D for any global variable. + # Also find C++ and __fastcall symbols from MSVC++, + # which start with @ or ?. + lt_cv_sys_global_symbol_pipe="$AWK '"\ +" {last_section=section; section=\$ 3};"\ +" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ +" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" \$ 0!~/External *\|/{next};"\ +" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ +" {if(hide[section]) next};"\ +" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ +" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ +" s[1]~/^[@?]/{print s[1], s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ +" ' prfx=^$ac_symprfx" + else + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + + # Check to see that the pipe works correctly. + pipe_works=no + + rm -f conftest* + cat > conftest.$ac_ext <<_LT_EOF +#ifdef __cplusplus +extern "C" { +#endif +char nm_test_var; +void nm_test_func(void); +void nm_test_func(void){} +#ifdef __cplusplus +} +#endif +int main(){nm_test_var='a';nm_test_func();return(0);} +_LT_EOF + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Now try to grab the symbols. + nlist=conftest.nm + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 + (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi + + # Make sure that we snagged all the symbols we need. + if $GREP ' nm_test_var$' "$nlist" >/dev/null; then + if $GREP ' nm_test_func$' "$nlist" >/dev/null; then + cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +_LT_EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' + + cat <<_LT_EOF >> conftest.$ac_ext + +/* The mapping between symbol names and symbols. */ +LT_DLSYM_CONST struct { + const char *name; + void *address; +} +lt__PROGRAM__LTX_preloaded_symbols[] = +{ + { "@PROGRAM@", (void *) 0 }, +_LT_EOF + $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + cat <<\_LT_EOF >> conftest.$ac_ext + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt__PROGRAM__LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif +_LT_EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_globsym_save_LIBS=$LIBS + lt_globsym_save_CFLAGS=$CFLAGS + LIBS="conftstm.$ac_objext" + CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext}; then + pipe_works=yes + fi + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS + else + echo "cannot find nm_test_func in $nlist" >&5 + fi + else + echo "cannot find nm_test_var in $nlist" >&5 + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 + fi + else + echo "$progname: failed program was:" >&5 + cat conftest.$ac_ext >&5 + fi + rm -rf conftest* conftst* + + # Do not use the global_symbol_pipe unless it works. + if test "$pipe_works" = yes; then + break + else + lt_cv_sys_global_symbol_pipe= + fi +done + +fi + +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 +$as_echo "failed" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 +$as_echo "ok" >&6; } +fi + +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then + nm_file_list_spec='@' +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 +$as_echo_n "checking for sysroot... " >&6; } + +# Check whether --with-sysroot was given. +if test "${with_sysroot+set}" = set; then : + withval=$with_sysroot; +else + with_sysroot=no +fi + + +lt_sysroot= +case ${with_sysroot} in #( + yes) + if test "$GCC" = yes; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` + fi + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5 +$as_echo "${with_sysroot}" >&6; } + as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 + ;; +esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 +$as_echo "${lt_sysroot:-no}" >&6; } + + + + + +# Check whether --enable-libtool-lock was given. +if test "${enable_libtool_lock+set}" = set; then : + enableval=$enable_libtool_lock; +fi + +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes + +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE="32" + ;; + *ELF-64*) + HPUX_IA64_MODE="64" + ;; + esac + fi + rm -rf conftest* + ;; +*-*-irix6*) + # Find out which ABI we are using. + echo '#line '$LINENO' "configure"' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + if test "$lt_cv_prog_gnu_ld" = yes; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ +s390*-*linux*|s390*-*tpf*|sparc*-*linux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + case `/usr/bin/file conftest.o` in + *x86-64*) + LD="${LD-ld} -m elf32_x86_64" + ;; + *) + LD="${LD-ld} -m elf_i386" + ;; + esac + ;; + powerpc64le-*) + LD="${LD-ld} -m elf32lppclinux" + ;; + powerpc64-*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + powerpcle-*) + LD="${LD-ld} -m elf64lppc" + ;; + powerpc-*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*|s390*-*tpf*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; + +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -belf" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 +$as_echo_n "checking whether the C compiler needs -belf... " >&6; } +if ${lt_cv_cc_needs_belf+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_cc_needs_belf=yes +else + lt_cv_cc_needs_belf=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 +$as_echo "$lt_cv_cc_needs_belf" >&6; } + if test x"$lt_cv_cc_needs_belf" != x"yes"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS="$SAVE_CFLAGS" + fi + ;; +*-*solaris*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) + case $host in + i?86-*-solaris*) + LD="${LD-ld} -m elf_x86_64" + ;; + sparc*-*-solaris*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + # GNU ld 2.21 introduced _sol2 emulations. Use them if available. + if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then + LD="${LD-ld}_sol2" + fi + ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; +esac + +need_locks="$enable_libtool_lock" + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. +set dummy ${ac_tool_prefix}mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$MANIFEST_TOOL"; then + ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL +if test -n "$MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 +$as_echo "$MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_MANIFEST_TOOL"; then + ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL + # Extract the first word of "mt", so it can be a program name with args. +set dummy mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_MANIFEST_TOOL"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL +if test -n "$ac_ct_MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 +$as_echo "$ac_ct_MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_MANIFEST_TOOL" = x; then + MANIFEST_TOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL + fi +else + MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" +fi + +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } +if ${lt_cv_path_mainfest_tool+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&5 + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 +$as_echo "$lt_cv_path_mainfest_tool" >&6; } +if test "x$lt_cv_path_mainfest_tool" != xyes; then + MANIFEST_TOOL=: +fi + + + + + + + case $host_os in + rhapsody* | darwin*) + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. +set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DSYMUTIL"; then + ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DSYMUTIL=$ac_cv_prog_DSYMUTIL +if test -n "$DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 +$as_echo "$DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DSYMUTIL"; then + ac_ct_DSYMUTIL=$DSYMUTIL + # Extract the first word of "dsymutil", so it can be a program name with args. +set dummy dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DSYMUTIL"; then + ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL +if test -n "$ac_ct_DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 +$as_echo "$ac_ct_DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DSYMUTIL" = x; then + DSYMUTIL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DSYMUTIL=$ac_ct_DSYMUTIL + fi +else + DSYMUTIL="$ac_cv_prog_DSYMUTIL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. +set dummy ${ac_tool_prefix}nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NMEDIT"; then + ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +NMEDIT=$ac_cv_prog_NMEDIT +if test -n "$NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 +$as_echo "$NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_NMEDIT"; then + ac_ct_NMEDIT=$NMEDIT + # Extract the first word of "nmedit", so it can be a program name with args. +set dummy nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_NMEDIT"; then + ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_NMEDIT="nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT +if test -n "$ac_ct_NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 +$as_echo "$ac_ct_NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_NMEDIT" = x; then + NMEDIT=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + NMEDIT=$ac_ct_NMEDIT + fi +else + NMEDIT="$ac_cv_prog_NMEDIT" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. +set dummy ${ac_tool_prefix}lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$LIPO"; then + ac_cv_prog_LIPO="$LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_LIPO="${ac_tool_prefix}lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +LIPO=$ac_cv_prog_LIPO +if test -n "$LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 +$as_echo "$LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_LIPO"; then + ac_ct_LIPO=$LIPO + # Extract the first word of "lipo", so it can be a program name with args. +set dummy lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_LIPO"; then + ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_LIPO="lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO +if test -n "$ac_ct_LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 +$as_echo "$ac_ct_LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_LIPO" = x; then + LIPO=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + LIPO=$ac_ct_LIPO + fi +else + LIPO="$ac_cv_prog_LIPO" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL"; then + ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL="${ac_tool_prefix}otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL=$ac_cv_prog_OTOOL +if test -n "$OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 +$as_echo "$OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL"; then + ac_ct_OTOOL=$OTOOL + # Extract the first word of "otool", so it can be a program name with args. +set dummy otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL"; then + ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL="otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL +if test -n "$ac_ct_OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 +$as_echo "$ac_ct_OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL" = x; then + OTOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL=$ac_ct_OTOOL + fi +else + OTOOL="$ac_cv_prog_OTOOL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL64"; then + ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL64=$ac_cv_prog_OTOOL64 +if test -n "$OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 +$as_echo "$OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL64"; then + ac_ct_OTOOL64=$OTOOL64 + # Extract the first word of "otool64", so it can be a program name with args. +set dummy otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL64"; then + ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL64="otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 +if test -n "$ac_ct_OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 +$as_echo "$ac_ct_OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL64" = x; then + OTOOL64=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL64=$ac_ct_OTOOL64 + fi +else + OTOOL64="$ac_cv_prog_OTOOL64" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 +$as_echo_n "checking for -single_module linker flag... " >&6; } +if ${lt_cv_apple_cc_single_mod+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_apple_cc_single_mod=no + if test -z "${LT_MULTI_MODULE}"; then + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + rm -rf libconftest.dylib* + echo "int foo(void){return 1;}" > conftest.c + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ +-dynamiclib -Wl,-single_module conftest.c" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err + _lt_result=$? + # If there is a non-empty error log, and "single_module" + # appears in it, assume the flag caused a linker warning + if test -s conftest.err && $GREP single_module conftest.err; then + cat conftest.err >&5 + # Otherwise, if the output was created with a 0 exit code from + # the compiler, it worked. + elif test -f libconftest.dylib && test $_lt_result -eq 0; then + lt_cv_apple_cc_single_mod=yes + else + cat conftest.err >&5 + fi + rm -rf libconftest.dylib* + rm -f conftest.* + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 +$as_echo "$lt_cv_apple_cc_single_mod" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 +$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } +if ${lt_cv_ld_exported_symbols_list+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_ld_exported_symbols_list=yes +else + lt_cv_ld_exported_symbols_list=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 +$as_echo "$lt_cv_ld_exported_symbols_list" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 +$as_echo_n "checking for -force_load linker flag... " >&6; } +if ${lt_cv_ld_force_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 + echo "$AR cru libconftest.a conftest.o" >&5 + $AR cru libconftest.a conftest.o 2>&5 + echo "$RANLIB libconftest.a" >&5 + $RANLIB libconftest.a 2>&5 + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -s conftest.err && $GREP force_load conftest.err; then + cat conftest.err >&5 + elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&5 + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 +$as_echo "$lt_cv_ld_force_load" >&6; } + case $host_os in + rhapsody* | darwin1.[012]) + _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; + darwin1.*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + darwin*) # darwin 5.x on + # if running on 10.5 or later, the deployment target defaults + # to the OS version, if on x86, and 10.4, the deployment + # target defaults to 10.4. Don't you love it? + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*86*-darwin8*|10.0,*-darwin[91]*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + 10.[012]*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + esac + ;; + esac + if test "$lt_cv_apple_cc_single_mod" = "yes"; then + _lt_dar_single_mod='$single_module' + fi + if test "$lt_cv_ld_exported_symbols_list" = "yes"; then + _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' + else + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' + fi + if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then + _lt_dsymutil='~$DSYMUTIL $lib || :' + else + _lt_dsymutil= + fi + ;; + esac + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 +$as_echo_n "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi +if test -z "$CPP"; then + if ${ac_cv_prog_CPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CPP needs to be expanded + for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" + do + ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since + # <limits.h> exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include <limits.h> +#else +# include <assert.h> +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <ac_nonexistent.h> +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + + done + ac_cv_prog_CPP=$CPP + +fi + CPP=$ac_cv_prog_CPP +else + ac_cv_prog_CPP=$CPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 +$as_echo "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since + # <limits.h> exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include <limits.h> +#else +# include <assert.h> +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <ac_nonexistent.h> +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 +$as_echo_n "checking for ANSI C header files... " >&6; } +if ${ac_cv_header_stdc+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <stdlib.h> +#include <stdarg.h> +#include <string.h> +#include <float.h> + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdc=yes +else + ac_cv_header_stdc=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <string.h> + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "memchr" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <stdlib.h> + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "free" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <ctype.h> +#include <stdlib.h> +#if ((' ' & 0x0FF) == 0x020) +# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#else +# define ISLOWER(c) \ + (('a' <= (c) && (c) <= 'i') \ + || ('j' <= (c) && (c) <= 'r') \ + || ('s' <= (c) && (c) <= 'z')) +# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) +#endif + +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +int +main () +{ + int i; + for (i = 0; i < 256; i++) + if (XOR (islower (i), ISLOWER (i)) + || toupper (i) != TOUPPER (i)) + return 2; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + +else + ac_cv_header_stdc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 +$as_echo "$ac_cv_header_stdc" >&6; } +if test $ac_cv_header_stdc = yes; then + +$as_echo "#define STDC_HEADERS 1" >>confdefs.h + +fi + +# On IRIX 5.3, sys/types and inttypes.h are conflicting. +for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ + inttypes.h stdint.h unistd.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + +for ac_header in dlfcn.h +do : + ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default +" +if test "x$ac_cv_header_dlfcn_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_DLFCN_H 1 +_ACEOF + +fi + +done + + + + +func_stripname_cnf () +{ + case ${2} in + .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; + *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; + esac +} # func_stripname_cnf + + + + + +# Set options +enable_win32_dll=yes + +case $host in +*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args. +set dummy ${ac_tool_prefix}as; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AS+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AS"; then + ac_cv_prog_AS="$AS" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AS="${ac_tool_prefix}as" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AS=$ac_cv_prog_AS +if test -n "$AS"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 +$as_echo "$AS" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_AS"; then + ac_ct_AS=$AS + # Extract the first word of "as", so it can be a program name with args. +set dummy as; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_AS+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AS"; then + ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_AS="as" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_AS=$ac_cv_prog_ac_ct_AS +if test -n "$ac_ct_AS"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AS" >&5 +$as_echo "$ac_ct_AS" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_AS" = x; then + AS="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AS=$ac_ct_AS + fi +else + AS="$ac_cv_prog_AS" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. +set dummy ${ac_tool_prefix}dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DLLTOOL"; then + ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DLLTOOL=$ac_cv_prog_DLLTOOL +if test -n "$DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 +$as_echo "$DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DLLTOOL"; then + ac_ct_DLLTOOL=$DLLTOOL + # Extract the first word of "dlltool", so it can be a program name with args. +set dummy dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DLLTOOL"; then + ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DLLTOOL="dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL +if test -n "$ac_ct_DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 +$as_echo "$ac_ct_DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DLLTOOL" = x; then + DLLTOOL="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DLLTOOL=$ac_ct_DLLTOOL + fi +else + DLLTOOL="$ac_cv_prog_DLLTOOL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. +set dummy ${ac_tool_prefix}objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OBJDUMP"; then + ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OBJDUMP=$ac_cv_prog_OBJDUMP +if test -n "$OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 +$as_echo "$OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OBJDUMP"; then + ac_ct_OBJDUMP=$OBJDUMP + # Extract the first word of "objdump", so it can be a program name with args. +set dummy objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OBJDUMP"; then + ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OBJDUMP="objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP +if test -n "$ac_ct_OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 +$as_echo "$ac_ct_OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OBJDUMP" = x; then + OBJDUMP="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OBJDUMP=$ac_ct_OBJDUMP + fi +else + OBJDUMP="$ac_cv_prog_OBJDUMP" +fi + + ;; +esac + +test -z "$AS" && AS=as + + + + + +test -z "$DLLTOOL" && DLLTOOL=dlltool + + + + + +test -z "$OBJDUMP" && OBJDUMP=objdump + + + + +# Check whether --enable-shared was given. +if test "${enable_shared+set}" = set; then : + enableval=$enable_shared; p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_shared=no +fi + + + + + + + + + + + enable_dlopen=no + + + + + # Check whether --enable-static was given. +if test "${enable_static+set}" = set; then : + enableval=$enable_static; p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_static=yes +fi + + + + + + + + + + +# Check whether --with-pic was given. +if test "${with_pic+set}" = set; then : + withval=$with_pic; lt_p=${PACKAGE-default} + case $withval in + yes|no) pic_mode=$withval ;; + *) + pic_mode=default + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for lt_pkg in $withval; do + IFS="$lt_save_ifs" + if test "X$lt_pkg" = "X$lt_p"; then + pic_mode=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + pic_mode=default +fi + + +test -z "$pic_mode" && pic_mode=default + + + + + + + + # Check whether --enable-fast-install was given. +if test "${enable_fast_install+set}" = set; then : + enableval=$enable_fast_install; p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_fast_install=yes +fi + + + + + + + + + + + +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS="$ltmain" + +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +test -z "$LN_S" && LN_S="ln -s" + + + + + + + + + + + + + + +if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 +$as_echo_n "checking for objdir... " >&6; } +if ${lt_cv_objdir+:} false; then : + $as_echo_n "(cached) " >&6 +else + rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 +$as_echo "$lt_cv_objdir" >&6; } +objdir=$lt_cv_objdir + + + + + +cat >>confdefs.h <<_ACEOF +#define LT_OBJDIR "$lt_cv_objdir/" +_ACEOF + + + + +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac + +# Global variables: +ofile=libtool +can_build_shared=yes + +# All known linkers require a `.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a + +with_gnu_ld="$lt_cv_prog_gnu_ld" + +old_CC="$CC" +old_CFLAGS="$CFLAGS" + +# Set sane defaults for various variables +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$LD" && LD=ld +test -z "$ac_objext" && ac_objext=o + +for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` + + +# Only perform the check for file, if the check method requires it +test -z "$MAGIC_CMD" && MAGIC_CMD=file +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 +$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/${ac_tool_prefix}file; then + lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac +fi + +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + + + +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 +$as_echo_n "checking for file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/file; then + lt_cv_path_MAGIC_CMD="$ac_dir/file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac +fi + +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + else + MAGIC_CMD=: + fi +fi + + fi + ;; +esac + +# Use C for the default configuration in the libtool script + +lt_save_CC="$CC" +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +# Source file extension for C test sources. +ac_ext=c + +# Object file extension for compiled C test sources. +objext=o +objext=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' + + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + +# Save the default compiler, since it gets overwritten when the other +# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. +compiler_DEFAULT=$CC + +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* + +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* + + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + +lt_prog_compiler_no_builtin_flag= + +if test "$GCC" = yes; then + case $cc_basename in + nvcc*) + lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; + *) + lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 +$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } +if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_rtti_exceptions=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="-fno-rtti -fno-exceptions" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_rtti_exceptions=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } + +if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then + lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" +else + : +fi + +fi + + + + + + + lt_prog_compiler_wl= +lt_prog_compiler_pic= +lt_prog_compiler_static= + + + if test "$GCC" = yes; then + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_static='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' + ;; + + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static= + ;; + + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + ;; + + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared=no + enable_shared=no + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic=-Kconform_pic + fi + ;; + + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + lt_prog_compiler_wl='-Xlinker ' + if test -n "$lt_prog_compiler_pic"; then + lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" + fi + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + else + lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' + fi + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; + + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static='${wl}-a ${wl}archive' + ;; + + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static='-non_shared' + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + # old Intel for x86_64 which still supported -KPIC. + ecc*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-static' + ;; + # icc used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + icc* | ifort*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + # Lahey Fortran 8.1. + lf95*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='--shared' + lt_prog_compiler_static='--static' + ;; + nagfor*) + # NAG Fortran compiler + lt_prog_compiler_wl='-Wl,-Wl,,' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-qpic' + lt_prog_compiler_static='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='' + ;; + *Sun\ F* | *Sun*Fortran*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Qoption ld ' + ;; + *Sun\ C*) + # Sun C 5.9 + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Wl,' + ;; + *Intel*\ [CF]*Compiler*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + *Portland\ Group*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + esac + ;; + esac + ;; + + newsos6) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + osf3* | osf4* | osf5*) + lt_prog_compiler_wl='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + + rdos*) + lt_prog_compiler_static='-non_shared' + ;; + + solaris*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + case $cc_basename in + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) + lt_prog_compiler_wl='-Qoption ld ';; + *) + lt_prog_compiler_wl='-Wl,';; + esac + ;; + + sunos4*) + lt_prog_compiler_wl='-Qoption ld ' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4 | sysv4.2uw2* | sysv4.3*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4*MP*) + if test -d /usr/nec ;then + lt_prog_compiler_pic='-Kconform_pic' + lt_prog_compiler_static='-Bstatic' + fi + ;; + + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + unicos*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_can_build_shared=no + ;; + + uts4*) + lt_prog_compiler_pic='-pic' + lt_prog_compiler_static='-Bstatic' + ;; + + *) + lt_prog_compiler_can_build_shared=no + ;; + esac + fi + +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic= + ;; + *) + lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic=$lt_prog_compiler_pic +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 +$as_echo "$lt_cv_prog_compiler_pic" >&6; } +lt_prog_compiler_pic=$lt_cv_prog_compiler_pic + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } +if ${lt_cv_prog_compiler_pic_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic -DPIC" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } + +if test x"$lt_cv_prog_compiler_pic_works" = xyes; then + case $lt_prog_compiler_pic in + "" | " "*) ;; + *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; + esac +else + lt_prog_compiler_pic= + lt_prog_compiler_can_build_shared=no +fi + +fi + + + + + + + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if ${lt_cv_prog_compiler_static_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works=yes + fi + else + lt_cv_prog_compiler_static_works=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 +$as_echo "$lt_cv_prog_compiler_static_works" >&6; } + +if test x"$lt_cv_prog_compiler_static_works" = xyes; then + : +else + lt_prog_compiler_static= +fi + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + + runpath_var= + allow_undefined_flag= + always_export_symbols=no + archive_cmds= + archive_expsym_cmds= + compiler_needs_object=no + enable_shared_with_static_runtimes=no + export_dynamic_flag_spec= + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + hardcode_automatic=no + hardcode_direct=no + hardcode_direct_absolute=no + hardcode_libdir_flag_spec= + hardcode_libdir_separator= + hardcode_minus_L=no + hardcode_shlibpath_var=unsupported + inherit_rpath=no + link_all_deplibs=unknown + module_cmds= + module_expsym_cmds= + old_archive_from_new_cmds= + old_archive_from_expsyms_cmds= + thread_safe_flag_spec= + whole_archive_flag_spec= + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + include_expsyms= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. + extract_expsyms_cmds= + + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd*) + with_gnu_ld=no + ;; + linux* | k*bsd*-gnu | gnu*) + link_all_deplibs=no + ;; + esac + + ld_shlibs=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no + if test "$with_gnu_ld" = yes; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; + *\ \(GNU\ Binutils\)\ [3-9]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test "$lt_use_gnu_ld_interface" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' + + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + export_dynamic_flag_spec='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec= + fi + supports_anon_versioning=no + case `$LD -v 2>&1` in + *GNU\ gold*) supports_anon_versioning=yes ;; + *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + + # See if GNU ld supports shared libraries. + case $host_os in + aix[3-9]*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: the GNU linker, at least up to release 2.19, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. + +_LT_EOF + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag=unsupported + # Joseph Beckenbach <jrb3@best.com> says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs=no + fi + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec='-L$libdir' + export_dynamic_flag_spec='${wl}--export-all-symbols' + allow_undefined_flag=unsupported + always_export_symbols=no + enable_shared_with_static_runtimes=yes + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs=no + fi + ;; + + haiku*) + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + link_all_deplibs=yes + ;; + + interix[3-9]*) + hardcode_direct=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + export_dynamic_flag_spec='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) + tmp_diet=no + if test "$host_os" = linux-dietlibc; then + case $cc_basename in + diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) + esac + fi + if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ + && test "$tmp_diet" = no + then + tmp_addflag=' $pic_flag' + tmp_sharedflag='-shared' + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group f77 and f90 compilers + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + lf95*) # Lahey Fortran 8.1 + whole_archive_flag_spec= + tmp_sharedflag='--shared' ;; + xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) + tmp_sharedflag='-qmkshrobj' + tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object=yes + ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object=yes + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + esac + archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + + if test "x$supports_anon_versioning" = xyes; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + + case $cc_basename in + xlf* | bgf* | bgxlf* | mpixlf*) + # IBM XL Fortran 10.1 on PPC cannot create shared libs itself + whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' + if test "x$supports_anon_versioning" = xyes; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + fi + ;; + esac + else + ld_shlibs=no + fi + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + + solaris*) + if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + ;; + *) + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + ;; + + sunos4*) + archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + *) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + + if test "$ld_shlibs" = no; then + runpath_var= + hardcode_libdir_flag_spec= + export_dynamic_flag_spec= + whole_archive_flag_spec= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + allow_undefined_flag=unsupported + always_export_symbols=yes + archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + hardcode_minus_L=yes + if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + hardcode_direct=unsupported + fi + ;; + + aix[4-9]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + # Also, AIX nm treats weak defined symbols like other global + # defined symbols, whereas GNU nm marks them as "W". + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds='' + hardcode_direct=yes + hardcode_direct_absolute=yes + hardcode_libdir_separator=':' + link_all_deplibs=yes + file_list_spec='${wl}-f,' + + if test "$GCC" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L=yes + hardcode_libdir_flag_spec='-L$libdir' + hardcode_libdir_separator= + fi + ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + link_all_deplibs=no + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + export_dynamic_flag_spec='${wl}-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag='-berok' + # Determine the default libpath from the value encoded in an + # empty executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag="-z nodefs" + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag=' ${wl}-bernotok' + allow_undefined_flag=' ${wl}-berok' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec='$convenience' + fi + archive_cmds_need_lc=yes + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + bsdi[45]*) + export_dynamic_flag_spec=-rdynamic + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + case $cc_basename in + cl*) + # Native MSVC + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + always_export_symbols=yes + file_list_spec='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, )='true' + enable_shared_with_static_runtimes=yes + exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' + # Don't use ranlib + old_postinstall_cmds='chmod 644 $oldlib' + postlink_cmds='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + old_archive_from_new_cmds='true' + # FIXME: Should let the user specify the lib program. + old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' + enable_shared_with_static_runtimes=yes + ;; + esac + ;; + + darwin* | rhapsody*) + + + archive_cmds_need_lc=no + hardcode_direct=no + hardcode_automatic=yes + hardcode_shlibpath_var=unsupported + if test "$lt_cv_ld_force_load" = "yes"; then + whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + + else + whole_archive_flag_spec='' + fi + link_all_deplibs=yes + allow_undefined_flag="$_lt_dar_allow_undefined" + case $cc_basename in + ifort*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test "$_lt_dar_can_shared" = "yes"; then + output_verbose_link_cmd=func_echo_all + archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + + else + ld_shlibs=no + fi + + ;; + + dgux*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2.*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + hpux9*) + if test "$GCC" = yes; then + archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + fi + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + export_dynamic_flag_spec='${wl}-E' + ;; + + hpux10*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='${wl}-E' + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + fi + ;; + + hpux11*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 +$as_echo_n "checking if $CC understands -b... " >&6; } +if ${lt_cv_prog_compiler__b+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler__b=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -b" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler__b=yes + fi + else + lt_cv_prog_compiler__b=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 +$as_echo "$lt_cv_prog_compiler__b" >&6; } + +if test x"$lt_cv_prog_compiler__b" = xyes; then + archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' +else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' +fi + + ;; + esac + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct=no + hardcode_shlibpath_var=no + ;; + *) + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='${wl}-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + ;; + esac + fi + ;; + + irix5* | irix6* | nonstopux*) + if test "$GCC" = yes; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + # Try to use the -exported_symbol ld option, if it does not + # work, assume that -exports_file does not work either and + # implicitly export all symbols. + # This should be the same for all languages, so no per-tag cache variable. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } +if ${lt_cv_irix_exported_symbol+:} false; then : + $as_echo_n "(cached) " >&6 +else + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int foo (void) { return 0; } +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_irix_exported_symbol=yes +else + lt_cv_irix_exported_symbol=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS="$save_LDFLAGS" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 +$as_echo "$lt_cv_irix_exported_symbol" >&6; } + if test "$lt_cv_irix_exported_symbol" = yes; then + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' + fi + else + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + inherit_rpath=yes + link_all_deplibs=yes + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + newsos6) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_shlibpath_var=no + ;; + + *nto* | *qnx*) + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + hardcode_direct=yes + hardcode_shlibpath_var=no + hardcode_direct_absolute=yes + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + export_dynamic_flag_spec='${wl}-E' + else + case $host_os in + openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-R$libdir' + ;; + *) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + ;; + esac + fi + else + ld_shlibs=no + fi + ;; + + os2*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + allow_undefined_flag=unsupported + archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + ;; + + osf3*) + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + ;; + + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ + $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' + + # Both c and cxx compiler support -rpath directly + hardcode_libdir_flag_spec='-rpath $libdir' + fi + archive_cmds_need_lc='no' + hardcode_libdir_separator=: + ;; + + solaris*) + no_undefined_flag=' -z defs' + if test "$GCC" = yes; then + wlarc='${wl}' + archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + else + case `$CC -V 2>&1` in + *"Compilers 5.0"*) + wlarc='' + archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + ;; + *) + wlarc='${wl}' + archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + ;; + esac + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_shlibpath_var=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. GCC discards it without `$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test "$GCC" = yes; then + whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + else + whole_archive_flag_spec='-z allextract$convenience -z defaultextract' + fi + ;; + esac + link_all_deplibs=yes + ;; + + sunos4*) + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + hardcode_libdir_flag_spec='-L$libdir' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + sysv4) + case $host_vendor in + sni) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' + reload_cmds='$CC -r -o $output$reload_objs' + hardcode_direct=no + ;; + motorola) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var=no + ;; + + sysv4.3*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + export_dynamic_flag_spec='-Bexport' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ld_shlibs=yes + fi + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag='${wl}-z,text' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag='${wl}-z,text' + allow_undefined_flag='${wl}-z,nodefs' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='${wl}-R,$libdir' + hardcode_libdir_separator=':' + link_all_deplibs=yes + export_dynamic_flag_spec='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + uts4*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + *) + ld_shlibs=no + ;; + esac + + if test x$host_vendor = xsni; then + case $host in + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + export_dynamic_flag_spec='${wl}-Blargedynsym' + ;; + esac + fi + fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 +$as_echo "$ld_shlibs" >&6; } +test "$ld_shlibs" = no && can_build_shared=no + +with_gnu_ld=$with_gnu_ld + + + + + + + + + + + + + + + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc=yes + + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } +if ${lt_cv_archive_cmds_need_lc+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl + pic_flag=$lt_prog_compiler_pic + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag + allow_undefined_flag= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc=no + else + lt_cv_archive_cmds_need_lc=yes + fi + allow_undefined_flag=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc" >&6; } + archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc + ;; + esac + fi + ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } + +if test "$GCC" = yes; then + case $host_os in + darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; + *) lt_awk_arg="/^libraries:/" ;; + esac + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;; + *) lt_sed_strip_eq="s,=/,/,g" ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary. + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path/$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" + else + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' +BEGIN {RS=" "; FS="/|\n";} { + lt_foo=""; + lt_count=0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo="/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[lt_foo]++; } + if (lt_freq[lt_foo] == 1) { print lt_foo; } +}'` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's,/\([A-Za-z]:\),\1,g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +case $host_os in +aix3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; + +aix[4-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib<name>.so + # instead of lib<name>.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; + esac + ;; + +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + library_names_spec='${libname}.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec="$LIB" + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[23].*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2.*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +haiku*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=yes + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[3-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux # correct to gnu/linux during the next big refactor + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes +fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + +fi + + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; + +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +fi +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action= +if test -n "$hardcode_libdir_flag_spec" || + test -n "$runpath_var" || + test "X$hardcode_automatic" = "Xyes" ; then + + # We can hardcode non-existent directories. + if test "$hardcode_direct" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no && + test "$hardcode_minus_L" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 +$as_echo "$hardcode_action" >&6; } + +if test "$hardcode_action" = relink || + test "$inherit_rpath" = yes; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi + + + + + + + if test "x$enable_dlopen" != xyes; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen="load_add_on" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32* | cegcc*) + lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen="dlopen" + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + + lt_cv_dlopen="dyld" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + +fi + + ;; + + *) + ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" +if test "x$ac_cv_func_shl_load" = xyes; then : + lt_cv_dlopen="shl_load" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 +$as_echo_n "checking for shl_load in -ldld... " >&6; } +if ${ac_cv_lib_dld_shl_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shl_load (); +int +main () +{ +return shl_load (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_shl_load=yes +else + ac_cv_lib_dld_shl_load=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 +$as_echo "$ac_cv_lib_dld_shl_load" >&6; } +if test "x$ac_cv_lib_dld_shl_load" = xyes; then : + lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" +else + ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" +if test "x$ac_cv_func_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 +$as_echo_n "checking for dlopen in -lsvld... " >&6; } +if ${ac_cv_lib_svld_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsvld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_svld_dlopen=yes +else + ac_cv_lib_svld_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 +$as_echo "$ac_cv_lib_svld_dlopen" >&6; } +if test "x$ac_cv_lib_svld_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 +$as_echo_n "checking for dld_link in -ldld... " >&6; } +if ${ac_cv_lib_dld_dld_link+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dld_link (); +int +main () +{ +return dld_link (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_dld_link=yes +else + ac_cv_lib_dld_dld_link=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 +$as_echo "$ac_cv_lib_dld_dld_link" >&6; } +if test "x$ac_cv_lib_dld_dld_link" = xyes; then : + lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" +fi + + +fi + + +fi + + +fi + + +fi + + +fi + + ;; + esac + + if test "x$lt_cv_dlopen" != xno; then + enable_dlopen=yes + else + enable_dlopen=no + fi + + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS="$CPPFLAGS" + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + + save_LDFLAGS="$LDFLAGS" + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + + save_LIBS="$LIBS" + LIBS="$lt_cv_dlopen_libs $LIBS" + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 +$as_echo_n "checking whether a program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include <dlfcn.h> +#endif + +#include <stdio.h> + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 +$as_echo "$lt_cv_dlopen_self" >&6; } + + if test "x$lt_cv_dlopen_self" = xyes; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 +$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self_static+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self_static=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include <dlfcn.h> +#endif + +#include <stdio.h> + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self_static=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 +$as_echo "$lt_cv_dlopen_self_static" >&6; } + fi + + CPPFLAGS="$save_CPPFLAGS" + LDFLAGS="$save_LDFLAGS" + LIBS="$save_LIBS" + ;; + esac + + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi + + + + + + + + + + + + + + + + + +striplib= +old_striplib= +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 +$as_echo_n "checking whether stripping libraries is possible... " >&6; } +if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP" ; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + esac +fi + + + + + + + + + + + + + # Report which library types will actually be built + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 +$as_echo_n "checking if libtool supports shared libraries... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 +$as_echo "$can_build_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 +$as_echo_n "checking whether to build shared libraries... " >&6; } + test "$can_build_shared" = "no" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + + aix[4-9]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 +$as_echo "$enable_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 +$as_echo_n "checking whether to build static libraries... " >&6; } + # Make sure either enable_shared or enable_static is yes. + test "$enable_shared" = yes || enable_static=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 +$as_echo "$enable_static" >&6; } + + + + +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +CC="$lt_save_CC" + + if test -n "$CXX" && ( test "X$CXX" != "Xno" && + ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || + (test "X$CXX" != "Xg++"))) ; then + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 +$as_echo_n "checking how to run the C++ preprocessor... " >&6; } +if test -z "$CXXCPP"; then + if ${ac_cv_prog_CXXCPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CXXCPP needs to be expanded + for CXXCPP in "$CXX -E" "/lib/cpp" + do + ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since + # <limits.h> exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include <limits.h> +#else +# include <assert.h> +#endif + Syntax error +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <ac_nonexistent.h> +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + + done + ac_cv_prog_CXXCPP=$CXXCPP + +fi + CXXCPP=$ac_cv_prog_CXXCPP +else + ac_cv_prog_CXXCPP=$CXXCPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 +$as_echo "$CXXCPP" >&6; } +ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since + # <limits.h> exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include <limits.h> +#else +# include <assert.h> +#endif + Syntax error +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <ac_nonexistent.h> +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +else + _lt_caught_CXX_error=yes +fi + +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + +archive_cmds_need_lc_CXX=no +allow_undefined_flag_CXX= +always_export_symbols_CXX=no +archive_expsym_cmds_CXX= +compiler_needs_object_CXX=no +export_dynamic_flag_spec_CXX= +hardcode_direct_CXX=no +hardcode_direct_absolute_CXX=no +hardcode_libdir_flag_spec_CXX= +hardcode_libdir_separator_CXX= +hardcode_minus_L_CXX=no +hardcode_shlibpath_var_CXX=unsupported +hardcode_automatic_CXX=no +inherit_rpath_CXX=no +module_cmds_CXX= +module_expsym_cmds_CXX= +link_all_deplibs_CXX=unknown +old_archive_cmds_CXX=$old_archive_cmds +reload_flag_CXX=$reload_flag +reload_cmds_CXX=$reload_cmds +no_undefined_flag_CXX= +whole_archive_flag_spec_CXX= +enable_shared_with_static_runtimes_CXX=no + +# Source file extension for C++ test sources. +ac_ext=cpp + +# Object file extension for compiled C++ test sources. +objext=o +objext_CXX=$objext + +# No sense in running all these tests if we already determined that +# the CXX compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test "$_lt_caught_CXX_error" != yes; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="int some_variable = 0;" + + # Code to be used in simple link tests + lt_simple_link_test_code='int main(int, char *[]) { return(0); }' + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + + + # save warnings/boilerplate of simple test code + ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* + + ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* + + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_CFLAGS=$CFLAGS + lt_save_LD=$LD + lt_save_GCC=$GCC + GCC=$GXX + lt_save_with_gnu_ld=$with_gnu_ld + lt_save_path_LD=$lt_cv_path_LD + if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then + lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx + else + $as_unset lt_cv_prog_gnu_ld + fi + if test -n "${lt_cv_path_LDCXX+set}"; then + lt_cv_path_LD=$lt_cv_path_LDCXX + else + $as_unset lt_cv_path_LD + fi + test -z "${LDCXX+set}" || LD=$LDCXX + CC=${CXX-"c++"} + CFLAGS=$CXXFLAGS + compiler=$CC + compiler_CXX=$CC + for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` + + + if test -n "$compiler"; then + # We don't want -fno-exception when compiling C++ code, so set the + # no_builtin_flag separately + if test "$GXX" = yes; then + lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' + else + lt_prog_compiler_no_builtin_flag_CXX= + fi + + if test "$GXX" = yes; then + # Set up default GNU C++ configuration + + + +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes +else + with_gnu_ld=no +fi + +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in + *GNU* | *'with BFD'*) + test "$with_gnu_ld" != no && break + ;; + *) + test "$with_gnu_ld" != yes && break + ;; + esac + fi + done + IFS="$lt_save_ifs" +else + lt_cv_path_LD="$LD" # Let the user override the test with a path. +fi +fi + +LD="$lt_cv_path_LD" +if test -n "$LD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 </dev/null` in +*GNU* | *'with BFD'*) + lt_cv_prog_gnu_ld=yes + ;; +*) + lt_cv_prog_gnu_ld=no + ;; +esac +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld + + + + + + + + # Check if GNU C++ uses GNU ld as the underlying linker, since the + # archiving commands below assume that GNU ld is being used. + if test "$with_gnu_ld" = yes; then + archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + + # If archive_cmds runs LD, not CC, wlarc should be empty + # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to + # investigate it a little bit more. (MM) + wlarc='${wl}' + + # ancient GNU ld didn't support --whole-archive et. al. + if eval "`$CC -print-prog-name=ld` --help 2>&1" | + $GREP 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec_CXX= + fi + else + with_gnu_ld=no + wlarc= + + # A generic and very simple default shared library creation + # command for GNU C++ for the case where it uses the native + # linker, instead of GNU ld. If possible, this setting should + # overridden to take advantage of the native linker features on + # the platform it is being used on. + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + fi + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + GXX=no + with_gnu_ld=no + wlarc= + fi + + # PORTME: fill in a description of your system's C++ link characteristics + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + ld_shlibs_CXX=yes + case $host_os in + aix3*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aix[4-9]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + case $ld_flag in + *-brtl*) + aix_use_runtimelinking=yes + break + ;; + esac + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds_CXX='' + hardcode_direct_CXX=yes + hardcode_direct_absolute_CXX=yes + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + file_list_spec_CXX='${wl}-f,' + + if test "$GXX" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct_CXX=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L_CXX=yes + hardcode_libdir_flag_spec_CXX='-L$libdir' + hardcode_libdir_separator_CXX= + fi + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + export_dynamic_flag_spec_CXX='${wl}-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to + # export. + always_export_symbols_CXX=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag_CXX='-berok' + # Determine the default libpath from the value encoded in an empty + # executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath__CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath__CXX +fi + + hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" + + archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag_CXX="-z nodefs" + archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath__CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath__CXX +fi + + hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag_CXX=' ${wl}-bernotok' + allow_undefined_flag_CXX=' ${wl}-berok' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec_CXX='$convenience' + fi + archive_cmds_need_lc_CXX=yes + # This is similar to how AIX traditionally builds its shared + # libraries. + archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag_CXX=unsupported + # Joseph Beckenbach <jrb3@best.com> says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs_CXX=no + fi + ;; + + chorus*) + case $cc_basename in + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + cygwin* | mingw* | pw32* | cegcc*) + case $GXX,$cc_basename in + ,cl* | no,cl*) + # Native MSVC + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + hardcode_libdir_flag_spec_CXX=' ' + allow_undefined_flag_CXX=unsupported + always_export_symbols_CXX=yes + file_list_spec_CXX='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true' + enable_shared_with_static_runtimes_CXX=yes + # Don't use ranlib + old_postinstall_cmds_CXX='chmod 644 $oldlib' + postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # g++ + # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec_CXX='-L$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-all-symbols' + allow_undefined_flag_CXX=unsupported + always_export_symbols_CXX=no + enable_shared_with_static_runtimes_CXX=yes + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs_CXX=no + fi + ;; + esac + ;; + darwin* | rhapsody*) + + + archive_cmds_need_lc_CXX=no + hardcode_direct_CXX=no + hardcode_automatic_CXX=yes + hardcode_shlibpath_var_CXX=unsupported + if test "$lt_cv_ld_force_load" = "yes"; then + whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + + else + whole_archive_flag_spec_CXX='' + fi + link_all_deplibs_CXX=yes + allow_undefined_flag_CXX="$_lt_dar_allow_undefined" + case $cc_basename in + ifort*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test "$_lt_dar_can_shared" = "yes"; then + output_verbose_link_cmd=func_echo_all + archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + module_expsym_cmds_CXX="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + if test "$lt_cv_apple_cc_single_mod" != "yes"; then + archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" + archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" + fi + + else + ld_shlibs_CXX=no + fi + + ;; + + dgux*) + case $cc_basename in + ec++*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + ghcx*) + # Green Hills C++ Compiler + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + freebsd2.*) + # C++ shared libraries reported to be fairly broken before + # switch to ELF + ld_shlibs_CXX=no + ;; + + freebsd-elf*) + archive_cmds_need_lc_CXX=no + ;; + + freebsd* | dragonfly*) + # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF + # conventions + ld_shlibs_CXX=yes + ;; + + haiku*) + archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + link_all_deplibs_CXX=yes + ;; + + hpux9*) + hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_CXX=: + export_dynamic_flag_spec_CXX='${wl}-E' + hardcode_direct_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aCC*) + archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes; then + archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + hpux10*|hpux11*) + if test $with_gnu_ld = no; then + hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_CXX=: + + case $host_cpu in + hppa*64*|ia64*) + ;; + *) + export_dynamic_flag_spec_CXX='${wl}-E' + ;; + esac + fi + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + ;; + *) + hardcode_direct_CXX=yes + hardcode_direct_absolute_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + ;; + esac + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aCC*) + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes; then + if test $with_gnu_ld = no; then + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + fi + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + interix[3-9]*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + irix5* | irix6*) + case $cc_basename in + CC*) + # SGI C++ + archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + + # Archives containing C++ object files must be created using + # "CC -ar", where "CC" is the IRIX C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' + ;; + *) + if test "$GXX" = yes; then + if test "$with_gnu_ld" = no; then + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' + fi + fi + link_all_deplibs_CXX=yes + ;; + esac + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_CXX=: + inherit_rpath_CXX=yes + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' + ;; + icpc* | ecpc* ) + # Intel C++ + with_gnu_ld=yes + # version 8.0 and above of icpc choke on multiply defined symbols + # if we add $predep_objects and $postdep_objects, however 7.1 and + # earlier do not add the objects themselves. + case `$CC -V 2>&1` in + *"Version 7."*) + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 8.0 or newer + tmp_idyn= + case $host_cpu in + ia64*) tmp_idyn=' -i_dynamic';; + esac + archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + archive_cmds_need_lc_CXX=no + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + case `$CC -V` in + *pgCC\ [1-5].* | *pgcpp\ [1-5].*) + prelink_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ + compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' + old_archive_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ + $RANLIB $oldlib' + archive_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + archive_expsym_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + ;; + *) # Version 6 and above use weak symbols + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + ;; + esac + + hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + ;; + cxx*) + # Compaq C++ + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' + + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' + ;; + xl* | mpixl* | bgxl*) + # IBM XL 8.0 on PPC, with GNU ld + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + if test "x$supports_anon_versioning" = xyes; then + archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' + hardcode_libdir_flag_spec_CXX='-R$libdir' + whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object_CXX=yes + + # Not sure whether something based on + # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 + # would be better. + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + esac + ;; + esac + ;; + + lynxos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + m88k*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + mvs*) + case $cc_basename in + cxx*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' + wlarc= + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + fi + # Workaround some broken pre-1.5 toolchains + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + ;; + + *nto* | *qnx*) + ld_shlibs_CXX=yes + ;; + + openbsd2*) + # C++ shared libraries are fairly broken + ld_shlibs_CXX=no + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + hardcode_direct_absolute_CXX=yes + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' + export_dynamic_flag_spec_CXX='${wl}-E' + whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + fi + output_verbose_link_cmd=func_echo_all + else + ld_shlibs_CXX=no + fi + ;; + + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + hardcode_libdir_separator_CXX=: + + # Archives containing C++ object files must be created using + # the KAI C++ compiler. + case $host in + osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; + *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; + esac + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + cxx*) + case $host in + osf3*) + allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + ;; + *) + allow_undefined_flag_CXX=' -expect_unresolved \*' + archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~ + $RM $lib.exp' + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + ;; + esac + + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' + case $host in + osf3*) + archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + ;; + *) + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + ;; + esac + + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + psos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + lcc*) + # Lucid + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + archive_cmds_need_lc_CXX=yes + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_shlibpath_var_CXX=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. + # Supported since Solaris 2.6 (maybe 2.5.1?) + whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' + ;; + esac + link_all_deplibs_CXX=yes + + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + gcx*) + # Green Hills C++ Compiler + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + + # The C++ compiler must be used to create the archive. + old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' + ;; + *) + # GNU C++ compiler with Solaris linker + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + no_undefined_flag_CXX=' ${wl}-z ${wl}defs' + if $CC --version | $GREP -v '^2\.7' > /dev/null; then + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + else + # g++ 2.7 appears to require `-G' NOT `-shared' on this + # platform. + archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + fi + + hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir' + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + ;; + esac + fi + ;; + esac + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag_CXX='${wl}-z,text' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag_CXX='${wl}-z,text' + allow_undefined_flag_CXX='${wl}-z,nodefs' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='${wl}-R,$libdir' + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + export_dynamic_flag_spec_CXX='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~ + '"$old_archive_cmds_CXX" + reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~ + '"$reload_cmds_CXX" + ;; + *) + archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + vxworks*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } + test "$ld_shlibs_CXX" = no && can_build_shared=no + + GCC_CXX="$GXX" + LD_CXX="$LD" + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + # Dependencies to place before and after the object being linked: +predep_objects_CXX= +postdep_objects_CXX= +predeps_CXX= +postdeps_CXX= +compiler_lib_search_path_CXX= + +cat > conftest.$ac_ext <<_LT_EOF +class Foo +{ +public: + Foo (void) { a = 0; } +private: + int a; +}; +_LT_EOF + + +_lt_libdeps_save_CFLAGS=$CFLAGS +case "$CC $CFLAGS " in #( +*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; +*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; +*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; +esac + +if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Parse the compiler output and extract the necessary + # objects, libraries and library flags. + + # Sentinel used to keep track of whether or not we are before + # the conftest object file. + pre_test_object_deps_done=no + + for p in `eval "$output_verbose_link_cmd"`; do + case ${prev}${p} in + + -L* | -R* | -l*) + # Some compilers place space between "-{L,R}" and the path. + # Remove the space. + if test $p = "-L" || + test $p = "-R"; then + prev=$p + continue + fi + + # Expand the sysroot to ease extracting the directories later. + if test -z "$prev"; then + case $p in + -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; + -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; + -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; + esac + fi + case $p in + =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; + esac + if test "$pre_test_object_deps_done" = no; then + case ${prev} in + -L | -R) + # Internal compiler library paths should come after those + # provided the user. The postdeps already come after the + # user supplied libs so there is no need to process them. + if test -z "$compiler_lib_search_path_CXX"; then + compiler_lib_search_path_CXX="${prev}${p}" + else + compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}" + fi + ;; + # The "-l" case would never come before the object being + # linked, so don't bother handling this case. + esac + else + if test -z "$postdeps_CXX"; then + postdeps_CXX="${prev}${p}" + else + postdeps_CXX="${postdeps_CXX} ${prev}${p}" + fi + fi + prev= + ;; + + *.lto.$objext) ;; # Ignore GCC LTO objects + *.$objext) + # This assumes that the test object file only shows up + # once in the compiler output. + if test "$p" = "conftest.$objext"; then + pre_test_object_deps_done=yes + continue + fi + + if test "$pre_test_object_deps_done" = no; then + if test -z "$predep_objects_CXX"; then + predep_objects_CXX="$p" + else + predep_objects_CXX="$predep_objects_CXX $p" + fi + else + if test -z "$postdep_objects_CXX"; then + postdep_objects_CXX="$p" + else + postdep_objects_CXX="$postdep_objects_CXX $p" + fi + fi + ;; + + *) ;; # Ignore the rest. + + esac + done + + # Clean up. + rm -f a.out a.exe +else + echo "libtool.m4: error: problem compiling CXX test program" +fi + +$RM -f confest.$objext +CFLAGS=$_lt_libdeps_save_CFLAGS + +# PORTME: override above test on systems where it is broken +case $host_os in +interix[3-9]*) + # Interix 3.5 installs completely hosed .la files for C++, so rather than + # hack all around it, let's just trust "g++" to DTRT. + predep_objects_CXX= + postdep_objects_CXX= + postdeps_CXX= + ;; + +linux*) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + + if test "$solaris_use_stlport4" != yes; then + postdeps_CXX='-library=Cstd -library=Crun' + fi + ;; + esac + ;; + +solaris*) + case $cc_basename in + CC* | sunCC*) + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + + # Adding this requires a known-good setup of shared libraries for + # Sun compiler versions before 5.6, else PIC objects from an old + # archive will be linked into the output, leading to subtle bugs. + if test "$solaris_use_stlport4" != yes; then + postdeps_CXX='-library=Cstd -library=Crun' + fi + ;; + esac + ;; +esac + + +case " $postdeps_CXX " in +*" -lc "*) archive_cmds_need_lc_CXX=no ;; +esac + compiler_lib_search_dirs_CXX= +if test -n "${compiler_lib_search_path_CXX}"; then + compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + lt_prog_compiler_wl_CXX= +lt_prog_compiler_pic_CXX= +lt_prog_compiler_static_CXX= + + + # C++ specific cases for pic, static, wl, etc. + if test "$GXX" = yes; then + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic_CXX='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic_CXX='-DDLL_EXPORT' + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic_CXX='-fno-common' + ;; + *djgpp*) + # DJGPP does not support shared libraries at all + lt_prog_compiler_pic_CXX= + ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static_CXX= + ;; + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic_CXX=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic_CXX='-fPIC -shared' + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + else + case $host_os in + aix[4-9]*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + else + lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' + fi + ;; + chorus*) + case $cc_basename in + cxch68*) + # Green Hills C++ Compiler + # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" + ;; + esac + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic_CXX='-DDLL_EXPORT' + ;; + dgux*) + case $cc_basename in + ec++*) + lt_prog_compiler_pic_CXX='-KPIC' + ;; + ghcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + freebsd* | dragonfly*) + # FreeBSD uses GNU C++ + ;; + hpux9* | hpux10* | hpux11*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' + if test "$host_cpu" != ia64; then + lt_prog_compiler_pic_CXX='+Z' + fi + ;; + aCC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_CXX='+Z' + ;; + esac + ;; + *) + ;; + esac + ;; + interix*) + # This is c89, which is MS Visual C++ (no shared libs) + # Anyone wants to do a port? + ;; + irix5* | irix6* | nonstopux*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-non_shared' + # CC pic flag -KPIC is the default. + ;; + *) + ;; + esac + ;; + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # KAI C++ Compiler + lt_prog_compiler_wl_CXX='--backend -Wl,' + lt_prog_compiler_pic_CXX='-fPIC' + ;; + ecpc* ) + # old Intel C++ for x86_64 which still supported -KPIC. + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-static' + ;; + icpc* ) + # Intel C++, used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-fPIC' + lt_prog_compiler_static_CXX='-static' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-fpic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + cxx*) + # Compaq C++ + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + xlc* | xlC* | bgxl[cC]* | mpixl[cC]*) + # IBM XL 8.0, 9.0 on PPC and BlueGene + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-qpic' + lt_prog_compiler_static_CXX='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + esac + ;; + esac + ;; + lynxos*) + ;; + m88k*) + ;; + mvs*) + case $cc_basename in + cxx*) + lt_prog_compiler_pic_CXX='-W c,exportall' + ;; + *) + ;; + esac + ;; + netbsd* | netbsdelf*-gnu) + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic_CXX='-fPIC -shared' + ;; + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + lt_prog_compiler_wl_CXX='--backend -Wl,' + ;; + RCC*) + # Rational C++ 2.4.1 + lt_prog_compiler_pic_CXX='-pic' + ;; + cxx*) + # Digital/Compaq C++ + lt_prog_compiler_wl_CXX='-Wl,' + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + *) + ;; + esac + ;; + psos*) + ;; + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + gcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-PIC' + ;; + *) + ;; + esac + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + lt_prog_compiler_pic_CXX='-pic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + lcc*) + # Lucid + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + lt_prog_compiler_pic_CXX='-KPIC' + ;; + *) + ;; + esac + ;; + vxworks*) + ;; + *) + lt_prog_compiler_can_build_shared_CXX=no + ;; + esac + fi + +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic_CXX= + ;; + *) + lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; } +lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; } +if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works_CXX=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works_CXX=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; } + +if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then + case $lt_prog_compiler_pic_CXX in + "" | " "*) ;; + *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; + esac +else + lt_prog_compiler_pic_CXX= + lt_prog_compiler_can_build_shared_CXX=no +fi + +fi + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if ${lt_cv_prog_compiler_static_works_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works_CXX=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works_CXX=yes + fi + else + lt_cv_prog_compiler_static_works_CXX=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; } + +if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then + : +else + lt_prog_compiler_static_CXX= +fi + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o_CXX=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_CXX=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o_CXX=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_CXX=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } + + + + +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + case $host_os in + aix[4-9]*) + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + # Also, AIX nm treats weak defined symbols like other global defined + # symbols, whereas GNU nm marks them as "W". + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + fi + ;; + pw32*) + export_symbols_cmds_CXX="$ltdll_cmds" + ;; + cygwin* | mingw* | cegcc*) + case $cc_basename in + cl*) + exclude_expsyms_CXX='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + ;; + *) + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + ;; + esac + ;; + linux* | k*bsd*-gnu | gnu*) + link_all_deplibs_CXX=no + ;; + *) + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + ;; + esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } +test "$ld_shlibs_CXX" = no && can_build_shared=no + +with_gnu_ld_CXX=$with_gnu_ld + + + + + + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc_CXX" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc_CXX=yes + + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds_CXX in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } +if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl_CXX + pic_flag=$lt_prog_compiler_pic_CXX + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag_CXX + allow_undefined_flag_CXX= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc_CXX=no + else + lt_cv_archive_cmds_need_lc_CXX=yes + fi + allow_undefined_flag_CXX=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; } + archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX + ;; + esac + fi + ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } + +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +case $host_os in +aix3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; + +aix[4-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib<name>.so + # instead of lib<name>.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; + esac + ;; + +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + library_names_spec='${libname}.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec="$LIB" + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[23].*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2.*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +haiku*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=yes + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[3-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux # correct to gnu/linux during the next big refactor + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes +fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + +fi + + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; + +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +fi +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action_CXX= +if test -n "$hardcode_libdir_flag_spec_CXX" || + test -n "$runpath_var_CXX" || + test "X$hardcode_automatic_CXX" = "Xyes" ; then + + # We can hardcode non-existent directories. + if test "$hardcode_direct_CXX" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" != no && + test "$hardcode_minus_L_CXX" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action_CXX=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action_CXX=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action_CXX=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5 +$as_echo "$hardcode_action_CXX" >&6; } + +if test "$hardcode_action_CXX" = relink || + test "$inherit_rpath_CXX" = yes; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi + + + + + + + + fi # test -n "$compiler" + + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS + LDCXX=$LD + LD=$lt_save_LD + GCC=$lt_save_GCC + with_gnu_ld=$lt_save_with_gnu_ld + lt_cv_path_LDCXX=$lt_cv_path_LD + lt_cv_path_LD=$lt_save_path_LD + lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld + lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld +fi # test "$_lt_caught_CXX_error" != yes + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + + + + + + + + + + + + + + ac_config_commands="$ac_config_commands libtool" + + + + +# Only expand once: + + + + +ac_config_headers="$ac_config_headers config.h" + + +# Checks for programs. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 +$as_echo_n "checking whether byte ordering is bigendian... " >&6; } +if ${ac_cv_c_bigendian+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_c_bigendian=unknown + # See if we're dealing with a universal compiler. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __APPLE_CC__ + not a universal capable compiler + #endif + typedef int dummy; + +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + + # Check for potential -arch flags. It is not universal unless + # there are at least two -arch flags with different values. + ac_arch= + ac_prev= + for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do + if test -n "$ac_prev"; then + case $ac_word in + i?86 | x86_64 | ppc | ppc64) + if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then + ac_arch=$ac_word + else + ac_cv_c_bigendian=universal + break + fi + ;; + esac + ac_prev= + elif test "x$ac_word" = "x-arch"; then + ac_prev=arch + fi + done +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + if test $ac_cv_c_bigendian = unknown; then + # See if sys/param.h defines the BYTE_ORDER macro. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <sys/types.h> + #include <sys/param.h> + +int +main () +{ +#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ + && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ + && LITTLE_ENDIAN) + bogus endian macros + #endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + # It does; now see whether it defined to BIG_ENDIAN or not. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <sys/types.h> + #include <sys/param.h> + +int +main () +{ +#if BYTE_ORDER != BIG_ENDIAN + not big endian + #endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_bigendian=yes +else + ac_cv_c_bigendian=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi + if test $ac_cv_c_bigendian = unknown; then + # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <limits.h> + +int +main () +{ +#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) + bogus endian macros + #endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + # It does; now see whether it defined to _BIG_ENDIAN or not. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <limits.h> + +int +main () +{ +#ifndef _BIG_ENDIAN + not big endian + #endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_bigendian=yes +else + ac_cv_c_bigendian=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi + if test $ac_cv_c_bigendian = unknown; then + # Compile a test program. + if test "$cross_compiling" = yes; then : + # Try to guess by grepping values from an object file. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +short int ascii_mm[] = + { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; + short int ascii_ii[] = + { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; + int use_ascii (int i) { + return ascii_mm[i] + ascii_ii[i]; + } + short int ebcdic_ii[] = + { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; + short int ebcdic_mm[] = + { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; + int use_ebcdic (int i) { + return ebcdic_mm[i] + ebcdic_ii[i]; + } + extern int foo; + +int +main () +{ +return use_ascii (foo) == use_ebcdic (foo); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then + ac_cv_c_bigendian=yes + fi + if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then + if test "$ac_cv_c_bigendian" = unknown; then + ac_cv_c_bigendian=no + else + # finding both strings is unlikely to happen, but who knows? + ac_cv_c_bigendian=unknown + fi + fi +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ + + /* Are we little or big endian? From Harbison&Steele. */ + union + { + long int l; + char c[sizeof (long int)]; + } u; + u.l = 1; + return u.c[sizeof (long int) - 1] == 1; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_c_bigendian=no +else + ac_cv_c_bigendian=yes +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 +$as_echo "$ac_cv_c_bigendian" >&6; } + case $ac_cv_c_bigendian in #( + yes) + $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h +;; #( + no) + ;; #( + universal) + +$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h + + ;; #( + *) + as_fn_error $? "unknown endianness + presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; + esac + + if test x$cross_compiling = xyes; then + CROSS_COMPILING_TRUE= + CROSS_COMPILING_FALSE='#' +else + CROSS_COMPILING_TRUE='#' + CROSS_COMPILING_FALSE= +fi + + +# Building documentation requires doxygen, pdflatex, and makeindex. +for ac_prog in doxygen +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DOXYGEN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DOXYGEN"; then + ac_cv_prog_DOXYGEN="$DOXYGEN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DOXYGEN="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DOXYGEN=$ac_cv_prog_DOXYGEN +if test -n "$DOXYGEN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOXYGEN" >&5 +$as_echo "$DOXYGEN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$DOXYGEN" && break +done + +if test -z "$DOXYGEN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Doxygen not found - continuing without Doxygen support" >&5 +$as_echo "$as_me: WARNING: Doxygen not found - continuing without Doxygen support" >&2;} +fi + if test -n "$DOXYGEN"; then + HAVE_DOXYGEN_TRUE= + HAVE_DOXYGEN_FALSE='#' +else + HAVE_DOXYGEN_TRUE='#' + HAVE_DOXYGEN_FALSE= +fi + +if test -z "$HAVE_DOXYGEN_TRUE"; then : + ac_config_files="$ac_config_files Doxyfile" + +fi + +for ac_prog in pdflatex +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_PDFLATEX+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$PDFLATEX"; then + ac_cv_prog_PDFLATEX="$PDFLATEX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_PDFLATEX="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +PDFLATEX=$ac_cv_prog_PDFLATEX +if test -n "$PDFLATEX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PDFLATEX" >&5 +$as_echo "$PDFLATEX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$PDFLATEX" && break +done + +if test -z "$PDFLATEX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pdflatex not found - unable to compile manual to PDF" >&5 +$as_echo "$as_me: WARNING: pdflatex not found - unable to compile manual to PDF" >&2;} +fi +for ac_prog in makeindex +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_MAKEINDEX+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$MAKEINDEX"; then + ac_cv_prog_MAKEINDEX="$MAKEINDEX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_MAKEINDEX="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +MAKEINDEX=$ac_cv_prog_MAKEINDEX +if test -n "$MAKEINDEX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINDEX" >&5 +$as_echo "$MAKEINDEX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$MAKEINDEX" && break +done + +if test -z "$MAKEINDEX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: makeindex not found - unable to compile manual to PDF" >&5 +$as_echo "$as_me: WARNING: makeindex not found - unable to compile manual to PDF" >&2;} +fi + if test -n "$PDFLATEX" && test -n "$MAKEINDEX"; then + HAVE_PDFLATEX_TRUE= + HAVE_PDFLATEX_FALSE='#' +else + HAVE_PDFLATEX_TRUE='#' + HAVE_PDFLATEX_FALSE= +fi + +if test -z "$HAVE_PDFLATEX_TRUE"; then : + ac_config_files="$ac_config_files doc/cudd.tex" + +fi + +# Checks for libraries. +#AC_CHECK_LIB([m],[pow]) +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing pow" >&5 +$as_echo_n "checking for library containing pow... " >&6; } +if ${ac_cv_search_pow+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char pow (); +int +main () +{ +return pow (); + ; + return 0; +} +_ACEOF +for ac_lib in '' m; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_pow=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_pow+:} false; then : + break +fi +done +if ${ac_cv_search_pow+:} false; then : + +else + ac_cv_search_pow=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_pow" >&5 +$as_echo "$ac_cv_search_pow" >&6; } +ac_res=$ac_cv_search_pow +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5 +$as_echo_n "checking for pthread_create in -lpthread... " >&6; } +if ${ac_cv_lib_pthread_pthread_create+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lpthread $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char pthread_create (); +int +main () +{ +return pthread_create (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_pthread_pthread_create=yes +else + ac_cv_lib_pthread_pthread_create=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_create" >&5 +$as_echo "$ac_cv_lib_pthread_pthread_create" >&6; } +if test "x$ac_cv_lib_pthread_pthread_create" = xyes; then : + have_pthreads=yes +else + have_pthreads=no +fi + + if test x$have_pthreads = xyes; then + HAVE_PTHREADS_TRUE= + HAVE_PTHREADS_FALSE='#' +else + HAVE_PTHREADS_TRUE='#' + HAVE_PTHREADS_FALSE= +fi + +# Check for Windows API functions. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing WSAStartup" >&5 +$as_echo_n "checking for library containing WSAStartup... " >&6; } +if ${ac_cv_search_WSAStartup+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char WSAStartup (); +int +main () +{ +return WSAStartup (); + ; + return 0; +} +_ACEOF +for ac_lib in '' ws2_32; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_WSAStartup=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_WSAStartup+:} false; then : + break +fi +done +if ${ac_cv_search_WSAStartup+:} false; then : + +else + ac_cv_search_WSAStartup=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_WSAStartup" >&5 +$as_echo "$ac_cv_search_WSAStartup" >&6; } +ac_res=$ac_cv_search_WSAStartup +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing GetProcessMemoryInfo" >&5 +$as_echo_n "checking for library containing GetProcessMemoryInfo... " >&6; } +if ${ac_cv_search_GetProcessMemoryInfo+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char GetProcessMemoryInfo (); +int +main () +{ +return GetProcessMemoryInfo (); + ; + return 0; +} +_ACEOF +for ac_lib in '' psapi; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_GetProcessMemoryInfo=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_GetProcessMemoryInfo+:} false; then : + break +fi +done +if ${ac_cv_search_GetProcessMemoryInfo+:} false; then : + +else + ac_cv_search_GetProcessMemoryInfo=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_GetProcessMemoryInfo" >&5 +$as_echo "$ac_cv_search_GetProcessMemoryInfo" >&6; } +ac_res=$ac_cv_search_GetProcessMemoryInfo +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + + +# Checks for header files. +# First check for mandatory headers... +for ac_header in float.h inttypes.h limits.h stddef.h stdlib.h string.h assert.h math.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +else + have_mandatory_headers=no +fi + +done + +if test "x${have_mandatory_headers}" = xno; then + as_fn_error $? "One or more mandatory headers missing. Check 'config.log'." "$LINENO" 5 +fi +# ...then check for optional C headers. +for ac_header in unistd.h sys/time.h sys/times.h sys/resource.h sys/wait.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + +# Finally, check C++ optional headers. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working C++ thread header" >&5 +$as_echo_n "checking for working C++ thread header... " >&6; } +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <thread> +int +main () +{ + std::thread([] {}).join() + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + have_working_thread=yes +else + have_working_thread=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +if test x$have_working_thread = xyes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + +$as_echo "#define HAVE_WORKING_THREAD 1" >>confdefs.h + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + +# Checks for typedefs, structures, and compiler characteristics. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5 +$as_echo_n "checking for stdbool.h that conforms to C99... " >&6; } +if ${ac_cv_header_stdbool_h+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include <stdbool.h> + #ifndef bool + "error: bool is not defined" + #endif + #ifndef false + "error: false is not defined" + #endif + #if false + "error: false is not 0" + #endif + #ifndef true + "error: true is not defined" + #endif + #if true != 1 + "error: true is not 1" + #endif + #ifndef __bool_true_false_are_defined + "error: __bool_true_false_are_defined is not defined" + #endif + + struct s { _Bool s: 1; _Bool t; } s; + + char a[true == 1 ? 1 : -1]; + char b[false == 0 ? 1 : -1]; + char c[__bool_true_false_are_defined == 1 ? 1 : -1]; + char d[(bool) 0.5 == true ? 1 : -1]; + /* See body of main program for 'e'. */ + char f[(_Bool) 0.0 == false ? 1 : -1]; + char g[true]; + char h[sizeof (_Bool)]; + char i[sizeof s.t]; + enum { j = false, k = true, l = false * true, m = true * 256 }; + /* The following fails for + HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */ + _Bool n[m]; + char o[sizeof n == m * sizeof n[0] ? 1 : -1]; + char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1]; + /* Catch a bug in an HP-UX C compiler. See + http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html + http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html + */ + _Bool q = true; + _Bool *pq = &q; + +int +main () +{ + + bool e = &s; + *pq |= q; + *pq |= ! q; + /* Refer to every declared value, to avoid compiler optimizations. */ + return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l + + !m + !n + !o + !p + !q + !pq); + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdbool_h=yes +else + ac_cv_header_stdbool_h=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5 +$as_echo "$ac_cv_header_stdbool_h" >&6; } + ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default" +if test "x$ac_cv_type__Bool" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE__BOOL 1 +_ACEOF + + +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 +$as_echo_n "checking for inline... " >&6; } +if ${ac_cv_c_inline+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_c_inline=no +for ac_kw in inline __inline__ __inline; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __cplusplus +typedef int foo_t; +static $ac_kw foo_t static_foo () {return 0; } +$ac_kw foo_t foo () {return 0; } +#endif + +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_inline=$ac_kw +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + test "$ac_cv_c_inline" != no && break +done + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 +$as_echo "$ac_cv_c_inline" >&6; } + +case $ac_cv_c_inline in + inline | yes) ;; + *) + case $ac_cv_c_inline in + no) ac_val=;; + *) ac_val=$ac_cv_c_inline;; + esac + cat >>confdefs.h <<_ACEOF +#ifndef __cplusplus +#define inline $ac_val +#endif +_ACEOF + ;; +esac + +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define size_t unsigned int +_ACEOF + +fi + +ac_fn_c_find_uintX_t "$LINENO" "16" "ac_cv_c_uint16_t" +case $ac_cv_c_uint16_t in #( + no|yes) ;; #( + *) + + +cat >>confdefs.h <<_ACEOF +#define uint16_t $ac_cv_c_uint16_t +_ACEOF +;; + esac + +ac_fn_c_find_uintX_t "$LINENO" "32" "ac_cv_c_uint32_t" +case $ac_cv_c_uint32_t in #( + no|yes) ;; #( + *) + +$as_echo "#define _UINT32_T 1" >>confdefs.h + + +cat >>confdefs.h <<_ACEOF +#define uint32_t $ac_cv_c_uint32_t +_ACEOF +;; + esac + +ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" +if test "x$ac_cv_type_ptrdiff_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_PTRDIFF_T 1 +_ACEOF + + +fi + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 +$as_echo_n "checking size of int... " >&6; } +if ${ac_cv_sizeof_int+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_int" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (int) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_int=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 +$as_echo "$ac_cv_sizeof_int" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_INT $ac_cv_sizeof_int +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 +$as_echo_n "checking size of long... " >&6; } +if ${ac_cv_sizeof_long+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (long) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_long=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 +$as_echo "$ac_cv_sizeof_long" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG $ac_cv_sizeof_long +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5 +$as_echo_n "checking size of void *... " >&6; } +if ${ac_cv_sizeof_void_p+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_void_p" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (void *) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_void_p=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5 +$as_echo "$ac_cv_sizeof_void_p" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_VOID_P $ac_cv_sizeof_void_p +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long double" >&5 +$as_echo_n "checking size of long double... " >&6; } +if ${ac_cv_sizeof_long_double+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long double))" "ac_cv_sizeof_long_double" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_long_double" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (long double) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_long_double=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_double" >&5 +$as_echo "$ac_cv_sizeof_long_double" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double +_ACEOF + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are building for a Win32 host" >&5 +$as_echo_n "checking whether we are building for a Win32 host... " >&6; } +if ${mingw_cv_win32_host+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#ifdef _WIN32 + choke me +#endif +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + mingw_cv_win32_host=no +else + mingw_cv_win32_host=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $mingw_cv_win32_host" >&5 +$as_echo "$mingw_cv_win32_host" >&6; } + if test x$mingw_cv_win32_host = xyes; then + MINGW64_TRUE= + MINGW64_FALSE='#' +else + MINGW64_TRUE='#' + MINGW64_FALSE= +fi + +if test x$mingw_cv_win32_host = xyes ; then + +$as_echo "#define __USE_MINGW_ANSI_STDIO 1" >>confdefs.h + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether enough of C++11 is supported" >&5 +$as_echo_n "checking whether enough of C++11 is supported... " >&6; } +if ${ac_cv_have_modern_cxx+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +class Myclass { explicit operator bool() const { return true; } }; +int main() { + void *p = nullptr; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_cv_have_modern_cxx=yes +else + ac_cv_have_modern_cxx=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_modern_cxx" >&5 +$as_echo "$ac_cv_have_modern_cxx" >&6; } +if test x$ac_cv_have_modern_cxx = xyes ; then + +$as_echo "#define HAVE_MODERN_CXX 1" >>confdefs.h + +fi + +# Checks for library functions. +# First the mandatory functions... +for ac_func in pow sqrt strchr strstr +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +else + have_mandatory_functions=no +fi +done + +if test "x${have_mandatory_functions}" = xno; then + as_fn_error $? "One or more mandatory functions missing. Check 'config.log'." "$LINENO" 5 +fi +# ...then check for optional functions. +for ac_func in powl gethostname getrlimit getrusage sysconf +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + + +# Check for a working implementation of IEEE 754 floating point +# Specifically, check for correct treatment of +Infinity +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for +Infinity (IEEE 754 floating point)" >&5 +$as_echo_n "checking for +Infinity (IEEE 754 floating point)... " >&6; } +if ${ac_cv_have_ieee_754+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_have_ieee_754=maybe +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#include <math.h> +main(void) +{ + if (HUGE_VAL != HUGE_VAL * 3 || HUGE_VAL != HUGE_VAL / 3) return 1; + return 0; +} + +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_have_ieee_754=yes +else + ac_cv_have_ieee_754=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi + +if test x$ac_cv_have_ieee_754 = xmaybe ; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <math.h> +int +main () +{ + double x = INFINITY + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_have_ieee_754=yes +else + ac_cv_have_ieee_754=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +if test x$ac_cv_have_ieee_754 = xyes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + +$as_echo "#define HAVE_IEEE_754 1" >>confdefs.h + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +ac_config_files="$ac_config_files Makefile" + +ac_config_files="$ac_config_files dddmp/exp/test1.sh" + +ac_config_files="$ac_config_files dddmp/exp/test2.sh" + +ac_config_files="$ac_config_files dddmp/exp/test3.sh" + +ac_config_files="$ac_config_files dddmp/exp/test4.sh" + +ac_config_files="$ac_config_files dddmp/exp/test5.sh" + +ac_config_files="$ac_config_files dddmp/exp/test6.sh" + +ac_config_files="$ac_config_files dddmp/exp/test7.sh" + + +cat >confcache <<\_ACEOF +# This file is a shell script that caches the results of configure +# tests run on this system so they can be shared between configure +# scripts and configure runs, see configure's option --config-cache. +# It is not useful on other systems. If it contains results you don't +# want to keep, you may remove or edit it. +# +# config.status only pays attention to the cache file if you give it +# the --recheck option to rerun configure. +# +# `ac_cv_env_foo' variables (set or unset) will be overridden when +# loading this file, other *unset* `ac_cv_foo' will be assigned the +# following values. + +_ACEOF + +# The following way of writing the cache mishandles newlines in values, +# but we know of no workaround that is simple, portable, and efficient. +# So, we kill variables containing newlines. +# Ultrix sh set writes to stderr and can't be redirected directly, +# and sets the high bit in the cache file unless we assign to the vars. +( + for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do + eval ac_val=\$$ac_var + case $ac_val in #( + *${as_nl}*) + case $ac_var in #( + *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + esac + case $ac_var in #( + _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( + *) { eval $ac_var=; unset $ac_var;} ;; + esac ;; + esac + done + + (set) 2>&1 | + case $as_nl`(ac_space=' '; set) 2>&1` in #( + *${as_nl}ac_space=\ *) + # `set' does not quote correctly, so add quotes: double-quote + # substitution turns \\\\ into \\, and sed turns \\ into \. + sed -n \ + "s/'/'\\\\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" + ;; #( + *) + # `set' quotes correctly as required by POSIX, so do not add quotes. + sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" + ;; + esac | + sort +) | + sed ' + /^ac_cv_env_/b end + t clear + :clear + s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ + t end + s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ + :end' >>confcache +if diff "$cache_file" confcache >/dev/null 2>&1; then :; else + if test -w "$cache_file"; then + if test "x$cache_file" != "x/dev/null"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 +$as_echo "$as_me: updating cache $cache_file" >&6;} + if test ! -f "$cache_file" || test -h "$cache_file"; then + cat confcache >"$cache_file" + else + case $cache_file in #( + */* | ?:*) + mv -f confcache "$cache_file"$$ && + mv -f "$cache_file"$$ "$cache_file" ;; #( + *) + mv -f confcache "$cache_file" ;; + esac + fi + fi + else + { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 +$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} + fi +fi +rm -f confcache + +test "x$prefix" = xNONE && prefix=$ac_default_prefix +# Let make expand exec_prefix. +test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' + +DEFS=-DHAVE_CONFIG_H + +ac_libobjs= +ac_ltlibobjs= +U= +for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue + # 1. Remove the extension, and $U if already installed. + ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' + ac_i=`$as_echo "$ac_i" | sed "$ac_script"` + # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR + # will be set to the directory where LIBOBJS objects are built. + as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" + as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' +done +LIBOBJS=$ac_libobjs + +LTLIBOBJS=$ac_ltlibobjs + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 +$as_echo_n "checking that generated files are newer than configure... " >&6; } + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 +$as_echo "done" >&6; } + if test -n "$EXEEXT"; then + am__EXEEXT_TRUE= + am__EXEEXT_FALSE='#' +else + am__EXEEXT_TRUE='#' + am__EXEEXT_FALSE= +fi + +if test -z "${DDDMP_TRUE}" && test -z "${DDDMP_FALSE}"; then + as_fn_error $? "conditional \"DDDMP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${OBJ_TRUE}" && test -z "${OBJ_FALSE}"; then + as_fn_error $? "conditional \"OBJ\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then + as_fn_error $? "conditional \"AMDEP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCC\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCXX\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi + +if test -z "${CROSS_COMPILING_TRUE}" && test -z "${CROSS_COMPILING_FALSE}"; then + as_fn_error $? "conditional \"CROSS_COMPILING\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${HAVE_DOXYGEN_TRUE}" && test -z "${HAVE_DOXYGEN_FALSE}"; then + as_fn_error $? "conditional \"HAVE_DOXYGEN\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${HAVE_PDFLATEX_TRUE}" && test -z "${HAVE_PDFLATEX_FALSE}"; then + as_fn_error $? "conditional \"HAVE_PDFLATEX\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${HAVE_PTHREADS_TRUE}" && test -z "${HAVE_PTHREADS_FALSE}"; then + as_fn_error $? "conditional \"HAVE_PTHREADS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${MINGW64_TRUE}" && test -z "${MINGW64_FALSE}"; then + as_fn_error $? "conditional \"MINGW64\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi + +: "${CONFIG_STATUS=./config.status}" +ac_write_fail=0 +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files $CONFIG_STATUS" +{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 +$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} +as_write_fail=0 +cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 +#! $SHELL +# Generated by $as_me. +# Run this file to recreate the current configuration. +# Compiler output produced by configure, useful for debugging +# configure, is in config.log if it exists. + +debug=false +ac_cs_recheck=false +ac_cs_silent=false + +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 +## -------------------- ## +## M4sh Initialization. ## +## -------------------- ## + +# Be more Bourne compatible +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi + + +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' +else + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' + else + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in #( + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' + fi + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' +fi + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi + + +# IFS +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent editors from complaining about space-tab. +# (If _AS_PATH_WALK were called with IFS unset, it would disable word +# splitting by setting IFS to empty value.) +IFS=" "" $as_nl" + +# Find who we are. Look in the path if we contain no directory separator. +as_myself= +case $0 in #(( + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done +IFS=$as_save_IFS + + ;; +esac +# We did not find ourselves, most probably we were run as `sh COMMAND' +# in which case we are not to be found in the path. +if test "x$as_myself" = x; then + as_myself=$0 +fi +if test ! -f "$as_myself"; then + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + exit 1 +fi + +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : +done +PS1='$ ' +PS2='> ' +PS4='+ ' + +# NLS nuisances. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE + +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + + +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error + + +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status + +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit + +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append + +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith + + +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi + +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi + +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi + +as_me=`$as_basename -- "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ + s//\1/ + q + } + /^X\/\(\/\/\)$/{ + s//\1/ + q + } + /^X\/\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + +ECHO_C= ECHO_N= ECHO_T= +case `echo -n x` in #((((( +-n*) + case `echo 'xy\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; + esac;; +*) + ECHO_N='-n';; +esac + +rm -f conf$$ conf$$.exe conf$$.file +if test -d conf$$.dir; then + rm -f conf$$.dir/conf$$.file +else + rm -f conf$$.dir + mkdir conf$$.dir 2>/dev/null +fi +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -pR'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -pR' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else + as_ln_s='cp -pR' + fi +else + as_ln_s='cp -pR' +fi +rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file +rmdir conf$$.dir 2>/dev/null + + +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ + + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" + + +} # as_fn_mkdir_p +if mkdir -p . 2>/dev/null; then + as_mkdir_p='mkdir -p "$as_dir"' +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi + + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p +as_test_x='test -x' +as_executable_p=as_fn_executable_p + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" + + +exec 6>&1 +## ----------------------------------- ## +## Main body of $CONFIG_STATUS script. ## +## ----------------------------------- ## +_ASEOF +test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# Save the log message, to keep $0 and so on meaningful, and to +# report actual input values of CONFIG_FILES etc. instead of their +# values after options handling. +ac_log=" +This file was extended by cudd $as_me 3.0.0, which was +generated by GNU Autoconf 2.69. Invocation command line was + + CONFIG_FILES = $CONFIG_FILES + CONFIG_HEADERS = $CONFIG_HEADERS + CONFIG_LINKS = $CONFIG_LINKS + CONFIG_COMMANDS = $CONFIG_COMMANDS + $ $0 $@ + +on `(hostname || uname -n) 2>/dev/null | sed 1q` +" + +_ACEOF + +case $ac_config_files in *" +"*) set x $ac_config_files; shift; ac_config_files=$*;; +esac + +case $ac_config_headers in *" +"*) set x $ac_config_headers; shift; ac_config_headers=$*;; +esac + + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# Files that config.status was made for. +config_files="$ac_config_files" +config_headers="$ac_config_headers" +config_commands="$ac_config_commands" + +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +ac_cs_usage="\ +\`$as_me' instantiates files and other configuration actions +from templates according to the current configuration. Unless the files +and actions are specified as TAGs, all are instantiated by default. + +Usage: $0 [OPTION]... [TAG]... + + -h, --help print this help, then exit + -V, --version print version number and configuration settings, then exit + --config print configuration, then exit + -q, --quiet, --silent + do not print progress messages + -d, --debug don't remove temporary files + --recheck update $as_me by reconfiguring in the same conditions + --file=FILE[:TEMPLATE] + instantiate the configuration file FILE + --header=FILE[:TEMPLATE] + instantiate the configuration header FILE + +Configuration files: +$config_files + +Configuration headers: +$config_headers + +Configuration commands: +$config_commands + +Report bugs to <Fabio@Colorado.EDU>." + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" +ac_cs_version="\\ +cudd config.status 3.0.0 +configured by $0, generated by GNU Autoconf 2.69, + with options \\"\$ac_cs_config\\" + +Copyright (C) 2012 Free Software Foundation, Inc. +This config.status script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it." + +ac_pwd='$ac_pwd' +srcdir='$srcdir' +INSTALL='$INSTALL' +MKDIR_P='$MKDIR_P' +AWK='$AWK' +test -n "\$AWK" || AWK=awk +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# The default lists apply if the user does not specify any file. +ac_need_defaults=: +while test $# != 0 +do + case $1 in + --*=?*) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` + ac_shift=: + ;; + --*=) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg= + ac_shift=: + ;; + *) + ac_option=$1 + ac_optarg=$2 + ac_shift=shift + ;; + esac + + case $ac_option in + # Handling of the options. + -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) + ac_cs_recheck=: ;; + --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) + $as_echo "$ac_cs_version"; exit ;; + --config | --confi | --conf | --con | --co | --c ) + $as_echo "$ac_cs_config"; exit ;; + --debug | --debu | --deb | --de | --d | -d ) + debug=: ;; + --file | --fil | --fi | --f ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + '') as_fn_error $? "missing file argument" ;; + esac + as_fn_append CONFIG_FILES " '$ac_optarg'" + ac_need_defaults=false;; + --header | --heade | --head | --hea ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + as_fn_append CONFIG_HEADERS " '$ac_optarg'" + ac_need_defaults=false;; + --he | --h) + # Conflict between --help and --header + as_fn_error $? "ambiguous option: \`$1' +Try \`$0 --help' for more information.";; + --help | --hel | -h ) + $as_echo "$ac_cs_usage"; exit ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil | --si | --s) + ac_cs_silent=: ;; + + # This is an error. + -*) as_fn_error $? "unrecognized option: \`$1' +Try \`$0 --help' for more information." ;; + + *) as_fn_append ac_config_targets " $1" + ac_need_defaults=false ;; + + esac + shift +done + +ac_configure_extra_args= + +if $ac_cs_silent; then + exec 6>/dev/null + ac_configure_extra_args="$ac_configure_extra_args --silent" +fi + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +if \$ac_cs_recheck; then + set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion + shift + \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 + CONFIG_SHELL='$SHELL' + export CONFIG_SHELL + exec "\$@" +fi + +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +exec 5>>config.log +{ + echo + sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX +## Running $as_me. ## +_ASBOX + $as_echo "$ac_log" +} >&5 + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# +# INIT-COMMANDS +# +AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" + + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +sed_quote_subst='$sed_quote_subst' +double_quote_subst='$double_quote_subst' +delay_variable_subst='$delay_variable_subst' +macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' +macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' +AS='`$ECHO "$AS" | $SED "$delay_single_quote_subst"`' +DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' +OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' +enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' +enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' +pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' +enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' +SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' +ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' +PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`' +host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' +host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' +host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' +build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' +build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' +build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' +SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' +Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' +GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' +EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' +FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' +LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' +NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' +LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' +max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' +ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' +exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' +lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' +lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' +lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' +lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' +lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' +reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' +reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' +deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' +file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' +file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' +want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' +sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' +AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' +AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' +archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' +STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' +RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' +old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' +old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' +lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' +CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' +CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' +compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' +GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' +nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' +lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' +objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' +MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' +need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' +MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' +DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' +NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' +LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' +OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' +OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' +libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' +shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' +extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' +compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' +module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' +with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' +no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' +hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' +hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' +inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' +link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' +always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' +exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' +include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' +prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' +postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' +file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' +variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' +need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' +need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' +version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' +runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' +libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' +library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' +soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' +install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' +postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' +postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' +finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' +hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' +sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' +sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`' +hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' +enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' +old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' +striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`' +predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`' +postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`' +predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`' +postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`' +LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`' +reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`' +reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' +compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`' +GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`' +archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' +module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' +with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' +no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`' +inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`' +link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`' +always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`' +exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`' +include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`' +prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`' +postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`' +file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`' +predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`' +postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`' +predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`' +postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`' + +LTCC='$LTCC' +LTCFLAGS='$LTCFLAGS' +compiler='$compiler_DEFAULT' + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} + +# Quote evaled strings. +for var in AS \ +DLLTOOL \ +OBJDUMP \ +SHELL \ +ECHO \ +PATH_SEPARATOR \ +SED \ +GREP \ +EGREP \ +FGREP \ +LD \ +NM \ +LN_S \ +lt_SP2NL \ +lt_NL2SP \ +reload_flag \ +deplibs_check_method \ +file_magic_cmd \ +file_magic_glob \ +want_nocaseglob \ +sharedlib_from_linklib_cmd \ +AR \ +AR_FLAGS \ +archiver_list_spec \ +STRIP \ +RANLIB \ +CC \ +CFLAGS \ +compiler \ +lt_cv_sys_global_symbol_pipe \ +lt_cv_sys_global_symbol_to_cdecl \ +lt_cv_sys_global_symbol_to_c_name_address \ +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ +nm_file_list_spec \ +lt_prog_compiler_no_builtin_flag \ +lt_prog_compiler_pic \ +lt_prog_compiler_wl \ +lt_prog_compiler_static \ +lt_cv_prog_compiler_c_o \ +need_locks \ +MANIFEST_TOOL \ +DSYMUTIL \ +NMEDIT \ +LIPO \ +OTOOL \ +OTOOL64 \ +shrext_cmds \ +export_dynamic_flag_spec \ +whole_archive_flag_spec \ +compiler_needs_object \ +with_gnu_ld \ +allow_undefined_flag \ +no_undefined_flag \ +hardcode_libdir_flag_spec \ +hardcode_libdir_separator \ +exclude_expsyms \ +include_expsyms \ +file_list_spec \ +variables_saved_for_relink \ +libname_spec \ +library_names_spec \ +soname_spec \ +install_override_mode \ +finish_eval \ +old_striplib \ +striplib \ +compiler_lib_search_dirs \ +predep_objects \ +postdep_objects \ +predeps \ +postdeps \ +compiler_lib_search_path \ +LD_CXX \ +reload_flag_CXX \ +compiler_CXX \ +lt_prog_compiler_no_builtin_flag_CXX \ +lt_prog_compiler_pic_CXX \ +lt_prog_compiler_wl_CXX \ +lt_prog_compiler_static_CXX \ +lt_cv_prog_compiler_c_o_CXX \ +export_dynamic_flag_spec_CXX \ +whole_archive_flag_spec_CXX \ +compiler_needs_object_CXX \ +with_gnu_ld_CXX \ +allow_undefined_flag_CXX \ +no_undefined_flag_CXX \ +hardcode_libdir_flag_spec_CXX \ +hardcode_libdir_separator_CXX \ +exclude_expsyms_CXX \ +include_expsyms_CXX \ +file_list_spec_CXX \ +compiler_lib_search_dirs_CXX \ +predep_objects_CXX \ +postdep_objects_CXX \ +predeps_CXX \ +postdeps_CXX \ +compiler_lib_search_path_CXX; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +# Double-quote double-evaled strings. +for var in reload_cmds \ +old_postinstall_cmds \ +old_postuninstall_cmds \ +old_archive_cmds \ +extract_expsyms_cmds \ +old_archive_from_new_cmds \ +old_archive_from_expsyms_cmds \ +archive_cmds \ +archive_expsym_cmds \ +module_cmds \ +module_expsym_cmds \ +export_symbols_cmds \ +prelink_cmds \ +postlink_cmds \ +postinstall_cmds \ +postuninstall_cmds \ +finish_cmds \ +sys_lib_search_path_spec \ +sys_lib_dlsearch_path_spec \ +reload_cmds_CXX \ +old_archive_cmds_CXX \ +old_archive_from_new_cmds_CXX \ +old_archive_from_expsyms_cmds_CXX \ +archive_cmds_CXX \ +archive_expsym_cmds_CXX \ +module_cmds_CXX \ +module_expsym_cmds_CXX \ +export_symbols_cmds_CXX \ +prelink_cmds_CXX \ +postlink_cmds_CXX; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +ac_aux_dir='$ac_aux_dir' +xsi_shell='$xsi_shell' +lt_shell_append='$lt_shell_append' + +# See if we are running on zsh, and set the options which allow our +# commands through without removal of \ escapes INIT. +if test -n "\${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi + + + PACKAGE='$PACKAGE' + VERSION='$VERSION' + TIMESTAMP='$TIMESTAMP' + RM='$RM' + ofile='$ofile' + + + + + + +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + +# Handling of arguments. +for ac_config_target in $ac_config_targets +do + case $ac_config_target in + "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; + "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; + "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; + "Doxyfile") CONFIG_FILES="$CONFIG_FILES Doxyfile" ;; + "doc/cudd.tex") CONFIG_FILES="$CONFIG_FILES doc/cudd.tex" ;; + "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; + "dddmp/exp/test1.sh") CONFIG_FILES="$CONFIG_FILES dddmp/exp/test1.sh" ;; + "dddmp/exp/test2.sh") CONFIG_FILES="$CONFIG_FILES dddmp/exp/test2.sh" ;; + "dddmp/exp/test3.sh") CONFIG_FILES="$CONFIG_FILES dddmp/exp/test3.sh" ;; + "dddmp/exp/test4.sh") CONFIG_FILES="$CONFIG_FILES dddmp/exp/test4.sh" ;; + "dddmp/exp/test5.sh") CONFIG_FILES="$CONFIG_FILES dddmp/exp/test5.sh" ;; + "dddmp/exp/test6.sh") CONFIG_FILES="$CONFIG_FILES dddmp/exp/test6.sh" ;; + "dddmp/exp/test7.sh") CONFIG_FILES="$CONFIG_FILES dddmp/exp/test7.sh" ;; + + *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; + esac +done + + +# If the user did not use the arguments to specify the items to instantiate, +# then the envvar interface is used. Set only those that are not. +# We use the long form for the default assignment because of an extremely +# bizarre bug on SunOS 4.1.3. +if $ac_need_defaults; then + test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files + test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers + test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands +fi + +# Have a temporary directory for convenience. Make it in the build tree +# simply because there is no reason against having it here, and in addition, +# creating and moving files from /tmp can sometimes cause problems. +# Hook for its removal unless debugging. +# Note that there is a small window in which the directory will not be cleaned: +# after its creation but before its name has been assigned to `$tmp'. +$debug || +{ + tmp= ac_tmp= + trap 'exit_status=$? + : "${ac_tmp:=$tmp}" + { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status +' 0 + trap 'as_fn_exit 1' 1 2 13 15 +} +# Create a (secure) tmp directory for tmp files. + +{ + tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && + test -d "$tmp" +} || +{ + tmp=./conf$$-$RANDOM + (umask 077 && mkdir "$tmp") +} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 +ac_tmp=$tmp + +# Set up the scripts for CONFIG_FILES section. +# No need to generate them if there are no CONFIG_FILES. +# This happens for instance with `./config.status config.h'. +if test -n "$CONFIG_FILES"; then + + +ac_cr=`echo X | tr X '\015'` +# On cygwin, bash can eat \r inside `` if the user requested igncr. +# But we know of no other shell where ac_cr would be empty at this +# point, so we can use a bashism as a fallback. +if test "x$ac_cr" = x; then + eval ac_cr=\$\'\\r\' +fi +ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` +if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then + ac_cs_awk_cr='\\r' +else + ac_cs_awk_cr=$ac_cr +fi + +echo 'BEGIN {' >"$ac_tmp/subs1.awk" && +_ACEOF + + +{ + echo "cat >conf$$subs.awk <<_ACEOF" && + echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && + echo "_ACEOF" +} >conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 +ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` +ac_delim='%!_!# ' +for ac_last_try in false false false false false :; do + . ./conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 + + ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` + if test $ac_delim_n = $ac_delim_num; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done +rm -f conf$$subs.sh + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && +_ACEOF +sed -n ' +h +s/^/S["/; s/!.*/"]=/ +p +g +s/^[^!]*!// +:repl +t repl +s/'"$ac_delim"'$// +t delim +:nl +h +s/\(.\{148\}\)..*/\1/ +t more1 +s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ +p +n +b repl +:more1 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t nl +:delim +h +s/\(.\{148\}\)..*/\1/ +t more2 +s/["\\]/\\&/g; s/^/"/; s/$/"/ +p +b +:more2 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t delim +' <conf$$subs.awk | sed ' +/^[^""]/{ + N + s/\n// +} +' >>$CONFIG_STATUS || ac_write_fail=1 +rm -f conf$$subs.awk +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +_ACAWK +cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && + for (key in S) S_is_set[key] = 1 + FS = "" + +} +{ + line = $ 0 + nfields = split(line, field, "@") + substed = 0 + len = length(field[1]) + for (i = 2; i < nfields; i++) { + key = field[i] + keylen = length(key) + if (S_is_set[key]) { + value = S[key] + line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) + len += length(value) + length(field[++i]) + substed = 1 + } else + len += 1 + keylen + } + + print line +} + +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then + sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" +else + cat +fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ + || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 +_ACEOF + +# VPATH may cause trouble with some makes, so we remove sole $(srcdir), +# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and +# trailing colons and then remove the whole line if VPATH becomes empty +# (actually we leave an empty line to preserve line numbers). +if test "x$srcdir" = x.; then + ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ +h +s/// +s/^/:/ +s/[ ]*$/:/ +s/:\$(srcdir):/:/g +s/:\${srcdir}:/:/g +s/:@srcdir@:/:/g +s/^:*// +s/:*$// +x +s/\(=[ ]*\).*/\1/ +G +s/\n// +s/^[^=]*=[ ]*$// +}' +fi + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +fi # test -n "$CONFIG_FILES" + +# Set up the scripts for CONFIG_HEADERS section. +# No need to generate them if there are no CONFIG_HEADERS. +# This happens for instance with `./config.status Makefile'. +if test -n "$CONFIG_HEADERS"; then +cat >"$ac_tmp/defines.awk" <<\_ACAWK || +BEGIN { +_ACEOF + +# Transform confdefs.h into an awk script `defines.awk', embedded as +# here-document in config.status, that substitutes the proper values into +# config.h.in to produce config.h. + +# Create a delimiter string that does not exist in confdefs.h, to ease +# handling of long lines. +ac_delim='%!_!# ' +for ac_last_try in false false :; do + ac_tt=`sed -n "/$ac_delim/p" confdefs.h` + if test -z "$ac_tt"; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done + +# For the awk script, D is an array of macro values keyed by name, +# likewise P contains macro parameters if any. Preserve backslash +# newline sequences. + +ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* +sed -n ' +s/.\{148\}/&'"$ac_delim"'/g +t rset +:rset +s/^[ ]*#[ ]*define[ ][ ]*/ / +t def +d +:def +s/\\$// +t bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3"/p +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p +d +:bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3\\\\\\n"\\/p +t cont +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p +t cont +d +:cont +n +s/.\{148\}/&'"$ac_delim"'/g +t clear +:clear +s/\\$// +t bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/"/p +d +:bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p +b cont +' <confdefs.h | sed ' +s/'"$ac_delim"'/"\\\ +"/g' >>$CONFIG_STATUS || ac_write_fail=1 + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + for (key in D) D_is_set[key] = 1 + FS = "" +} +/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { + line = \$ 0 + split(line, arg, " ") + if (arg[1] == "#") { + defundef = arg[2] + mac1 = arg[3] + } else { + defundef = substr(arg[1], 2) + mac1 = arg[2] + } + split(mac1, mac2, "(") #) + macro = mac2[1] + prefix = substr(line, 1, index(line, defundef) - 1) + if (D_is_set[macro]) { + # Preserve the white space surrounding the "#". + print prefix "define", macro P[macro] D[macro] + next + } else { + # Replace #undef with comments. This is necessary, for example, + # in the case of _POSIX_SOURCE, which is predefined and required + # on some systems where configure will not decide to define it. + if (defundef == "undef") { + print "/*", prefix defundef, macro, "*/" + next + } + } +} +{ print } +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 +fi # test -n "$CONFIG_HEADERS" + + +eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" +shift +for ac_tag +do + case $ac_tag in + :[FHLC]) ac_mode=$ac_tag; continue;; + esac + case $ac_mode$ac_tag in + :[FHL]*:*);; + :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; + :[FH]-) ac_tag=-:-;; + :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; + esac + ac_save_IFS=$IFS + IFS=: + set x $ac_tag + IFS=$ac_save_IFS + shift + ac_file=$1 + shift + + case $ac_mode in + :L) ac_source=$1;; + :[FH]) + ac_file_inputs= + for ac_f + do + case $ac_f in + -) ac_f="$ac_tmp/stdin";; + *) # Look for the file first in the build tree, then in the source tree + # (if the path is not absolute). The absolute path cannot be DOS-style, + # because $ac_f cannot contain `:'. + test -f "$ac_f" || + case $ac_f in + [\\/$]*) false;; + *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; + esac || + as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; + esac + case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac + as_fn_append ac_file_inputs " '$ac_f'" + done + + # Let's still pretend it is `configure' which instantiates (i.e., don't + # use $as_me), people would be surprised to read: + # /* config.h. Generated by config.status. */ + configure_input='Generated from '` + $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' + `' by configure.' + if test x"$ac_file" != x-; then + configure_input="$ac_file. $configure_input" + { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 +$as_echo "$as_me: creating $ac_file" >&6;} + fi + # Neutralize special characters interpreted by sed in replacement strings. + case $configure_input in #( + *\&* | *\|* | *\\* ) + ac_sed_conf_input=`$as_echo "$configure_input" | + sed 's/[\\\\&|]/\\\\&/g'`;; #( + *) ac_sed_conf_input=$configure_input;; + esac + + case $ac_tag in + *:-:* | *:-) cat >"$ac_tmp/stdin" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; + esac + ;; + esac + + ac_dir=`$as_dirname -- "$ac_file" || +$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$ac_file" : 'X\(//\)[^/]' \| \ + X"$ac_file" : 'X\(//\)$' \| \ + X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$ac_file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir="$ac_dir"; as_fn_mkdir_p + ac_builddir=. + +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix + +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix + + + case $ac_mode in + :F) + # + # CONFIG_FILE + # + + case $INSTALL in + [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; + *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; + esac + ac_MKDIR_P=$MKDIR_P + case $MKDIR_P in + [\\/$]* | ?:[\\/]* ) ;; + */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; + esac +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# If the template does not know about datarootdir, expand it. +# FIXME: This hack should be removed a few years after 2.60. +ac_datarootdir_hack=; ac_datarootdir_seen= +ac_sed_dataroot=' +/datarootdir/ { + p + q +} +/@datadir@/p +/@docdir@/p +/@infodir@/p +/@localedir@/p +/@mandir@/p' +case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in +*datarootdir*) ac_datarootdir_seen=yes;; +*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 +$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + ac_datarootdir_hack=' + s&@datadir@&$datadir&g + s&@docdir@&$docdir&g + s&@infodir@&$infodir&g + s&@localedir@&$localedir&g + s&@mandir@&$mandir&g + s&\\\${datarootdir}&$datarootdir&g' ;; +esac +_ACEOF + +# Neutralize VPATH when `$srcdir' = `.'. +# Shell code in configure.ac might set extrasub. +# FIXME: do we really want to maintain this feature? +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_sed_extra="$ac_vpsub +$extrasub +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +:t +/@[a-zA-Z_][a-zA-Z_0-9]*@/!b +s|@configure_input@|$ac_sed_conf_input|;t t +s&@top_builddir@&$ac_top_builddir_sub&;t t +s&@top_build_prefix@&$ac_top_build_prefix&;t t +s&@srcdir@&$ac_srcdir&;t t +s&@abs_srcdir@&$ac_abs_srcdir&;t t +s&@top_srcdir@&$ac_top_srcdir&;t t +s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t +s&@builddir@&$ac_builddir&;t t +s&@abs_builddir@&$ac_abs_builddir&;t t +s&@abs_top_builddir@&$ac_abs_top_builddir&;t t +s&@INSTALL@&$ac_INSTALL&;t t +s&@MKDIR_P@&$ac_MKDIR_P&;t t +$ac_datarootdir_hack +" +eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ + >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + +test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && + { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && + { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ + "$ac_tmp/out"`; test -z "$ac_out"; } && + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&5 +$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&2;} + + rm -f "$ac_tmp/stdin" + case $ac_file in + -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; + *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; + esac \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + ;; + :H) + # + # CONFIG_HEADER + # + if test x"$ac_file" != x-; then + { + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" + } >"$ac_tmp/config.h" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then + { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 +$as_echo "$as_me: $ac_file is unchanged" >&6;} + else + rm -f "$ac_file" + mv "$ac_tmp/config.h" "$ac_file" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + fi + else + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ + || as_fn_error $? "could not create -" "$LINENO" 5 + fi +# Compute "$ac_file"'s index in $config_headers. +_am_arg="$ac_file" +_am_stamp_count=1 +for _am_header in $config_headers :; do + case $_am_header in + $_am_arg | $_am_arg:* ) + break ;; + * ) + _am_stamp_count=`expr $_am_stamp_count + 1` ;; + esac +done +echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || +$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$_am_arg" : 'X\(//\)[^/]' \| \ + X"$_am_arg" : 'X\(//\)$' \| \ + X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$_am_arg" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'`/stamp-h$_am_stamp_count + ;; + + :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 +$as_echo "$as_me: executing $ac_file commands" >&6;} + ;; + esac + + + case $ac_file$ac_mode in + "depfiles":C) test x"$AMDEP_TRUE" != x"" || { + # Older Autoconf quotes --file arguments for eval, but not when files + # are listed without --file. Let's play safe and only enable the eval + # if we detect the quoting. + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac + shift + for mf + do + # Strip MF so we end up with the name of the file. + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named 'Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line + # limit of 2048, but all sed's we know have understand at least 4000. + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`$as_dirname -- "$mf" || +$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$mf" : 'X\(//\)[^/]' \| \ + X"$mf" : 'X\(//\)$' \| \ + X"$mf" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$mf" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running 'make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "$am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`$as_dirname -- "$file" || +$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$file" : 'X\(//\)[^/]' \| \ + X"$file" : 'X\(//\)$' \| \ + X"$file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir=$dirpart/$fdir; as_fn_mkdir_p + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done + done +} + ;; + "libtool":C) + + # See if we are running on zsh, and set the options which allow our + # commands through without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + + cfgfile="${ofile}T" + trap "$RM \"$cfgfile\"; exit 1" 1 2 15 + $RM "$cfgfile" + + cat <<_LT_EOF >> "$cfgfile" +#! $SHELL + +# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. +# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# NOTE: Changes made to this file will be lost: look at ltmain.sh. +# +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, +# 2006, 2007, 2008, 2009, 2010, 2011 Free Software +# Foundation, Inc. +# Written by Gordon Matzigkeit, 1996 +# +# This file is part of GNU Libtool. +# +# GNU Libtool 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 of +# the License, or (at your option) any later version. +# +# As a special exception to the GNU General Public License, +# if you distribute this file as part of a program or library that +# is built using GNU Libtool, you may include this file under the +# same distribution terms that you use for the rest of that program. +# +# GNU Libtool 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. +# +# You should have received a copy of the GNU General Public License +# along with GNU Libtool; see the file COPYING. If not, a copy +# can be downloaded from http://www.gnu.org/licenses/gpl.html, or +# obtained by writing to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + + +# The names of the tagged configurations supported by this script. +available_tags="CXX " + +# ### BEGIN LIBTOOL CONFIG + +# Which release of libtool.m4 was used? +macro_version=$macro_version +macro_revision=$macro_revision + +# Assembler program. +AS=$lt_AS + +# DLL creation program. +DLLTOOL=$lt_DLLTOOL + +# Object dumper program. +OBJDUMP=$lt_OBJDUMP + +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared + +# Whether or not to build static libraries. +build_old_libs=$enable_static + +# What type of objects to build. +pic_mode=$pic_mode + +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install + +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL + +# An echo program that protects backslashes. +ECHO=$lt_ECHO + +# The PATH separator for the build system. +PATH_SEPARATOR=$lt_PATH_SEPARATOR + +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os + +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os + +# A sed program that does not truncate output. +SED=$lt_SED + +# Sed that helps us avoid accidentally triggering echo(1) options like -n. +Xsed="\$SED -e 1s/^X//" + +# A grep program that handles long lines. +GREP=$lt_GREP + +# An ERE matcher. +EGREP=$lt_EGREP + +# A literal string matcher. +FGREP=$lt_FGREP + +# A BSD- or MS-compatible name lister. +NM=$lt_NM + +# Whether we need soft or hard links. +LN_S=$lt_LN_S + +# What is the maximum length of a command? +max_cmd_len=$max_cmd_len + +# Object file suffix (normally "o"). +objext=$ac_objext + +# Executable file suffix (normally ""). +exeext=$exeext + +# whether the shell understands "unset". +lt_unset=$lt_unset + +# turn spaces into newlines. +SP2NL=$lt_lt_SP2NL + +# turn newlines into spaces. +NL2SP=$lt_lt_NL2SP + +# convert \$build file names to \$host format. +to_host_file_cmd=$lt_cv_to_host_file_cmd + +# convert \$build files to toolchain format. +to_tool_file_cmd=$lt_cv_to_tool_file_cmd + +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method + +# Command to use when deplibs_check_method = "file_magic". +file_magic_cmd=$lt_file_magic_cmd + +# How to find potential files when deplibs_check_method = "file_magic". +file_magic_glob=$lt_file_magic_glob + +# Find potential files using nocaseglob when deplibs_check_method = "file_magic". +want_nocaseglob=$lt_want_nocaseglob + +# Command to associate shared and link libraries. +sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd + +# The archiver. +AR=$lt_AR + +# Flags to create an archive. +AR_FLAGS=$lt_AR_FLAGS + +# How to feed a file listing to the archiver. +archiver_list_spec=$lt_archiver_list_spec + +# A symbol stripping program. +STRIP=$lt_STRIP + +# Commands used to install an old-style archive. +RANLIB=$lt_RANLIB +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds + +# Whether to use a lock for old archive extraction. +lock_old_archive_extraction=$lock_old_archive_extraction + +# A C compiler. +LTCC=$lt_CC + +# LTCC compiler flags. +LTCFLAGS=$lt_CFLAGS + +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe + +# Transform the output of nm in a proper C declaration. +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl + +# Transform the output of nm in a C name address pair. +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address + +# Transform the output of nm in a C name address pair when lib prefix is needed. +global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix + +# Specify filename containing input files for \$NM. +nm_file_list_spec=$lt_nm_file_list_spec + +# The root where to search for dependent libraries,and in which our libraries should be installed. +lt_sysroot=$lt_sysroot + +# The name of the directory that contains temporary libtool files. +objdir=$objdir + +# Used to examine libraries when file_magic_cmd begins with "file". +MAGIC_CMD=$MAGIC_CMD + +# Must we lock files when doing compilation? +need_locks=$lt_need_locks + +# Manifest tool. +MANIFEST_TOOL=$lt_MANIFEST_TOOL + +# Tool to manipulate archived DWARF debug symbol files on Mac OS X. +DSYMUTIL=$lt_DSYMUTIL + +# Tool to change global to local symbols on Mac OS X. +NMEDIT=$lt_NMEDIT + +# Tool to manipulate fat objects and archives on Mac OS X. +LIPO=$lt_LIPO + +# ldd/readelf like tool for Mach-O binaries on Mac OS X. +OTOOL=$lt_OTOOL + +# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. +OTOOL64=$lt_OTOOL64 + +# Old archive suffix (normally "a"). +libext=$libext + +# Shared library suffix (normally ".so"). +shrext_cmds=$lt_shrext_cmds + +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds + +# Variables whose values should be saved in libtool wrapper scripts and +# restored at link time. +variables_saved_for_relink=$lt_variables_saved_for_relink + +# Do we need the "lib" prefix for modules? +need_lib_prefix=$need_lib_prefix + +# Do we need a version for libraries? +need_version=$need_version + +# Library versioning type. +version_type=$version_type + +# Shared library runtime path variable. +runpath_var=$runpath_var + +# Shared library path variable. +shlibpath_var=$shlibpath_var + +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath + +# Format of library name prefix. +libname_spec=$lt_libname_spec + +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME +library_names_spec=$lt_library_names_spec + +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec + +# Permission mode override for installation of shared libraries. +install_override_mode=$lt_install_override_mode + +# Command to use after installation of a shared archive. +postinstall_cmds=$lt_postinstall_cmds + +# Command to use after uninstallation of a shared archive. +postuninstall_cmds=$lt_postuninstall_cmds + +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds + +# As "finish_cmds", except a single script fragment to be evaled but +# not shown. +finish_eval=$lt_finish_eval + +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs + +# Compile-time system search path for libraries. +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec + +# Run-time system search path for libraries. +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec + +# Whether dlopen is supported. +dlopen_support=$enable_dlopen + +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self + +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static + +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib + + +# The linker used to build libraries. +LD=$lt_LD + +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds + +# Commands used to build an old-style archive. +old_archive_cmds=$lt_old_archive_cmds + +# A language specific compiler. +CC=$lt_compiler + +# Is the compiler the GNU compiler? +with_gcc=$GCC + +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag + +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic + +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl + +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static + +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o + +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc + +# Whether or not to disallow shared libs when runtime libs are static. +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes + +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec + +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec + +# Whether the compiler copes with passing no objects directly. +compiler_needs_object=$lt_compiler_needs_object + +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds + +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds + +# Commands used to build a shared archive. +archive_cmds=$lt_archive_cmds +archive_expsym_cmds=$lt_archive_expsym_cmds + +# Commands used to build a loadable module if different from building +# a shared archive. +module_cmds=$lt_module_cmds +module_expsym_cmds=$lt_module_expsym_cmds + +# Whether we are building with GNU ld or not. +with_gnu_ld=$lt_with_gnu_ld + +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag + +# Flag that enforces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag + +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec + +# Whether we need a single "-rpath" flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator + +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary. +hardcode_direct=$hardcode_direct + +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary and the resulting library dependency is +# "absolute",i.e impossible to change by setting \${shlibpath_var} if the +# library is relocated. +hardcode_direct_absolute=$hardcode_direct_absolute + +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR +# into the resulting binary. +hardcode_minus_L=$hardcode_minus_L + +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR +# into the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var + +# Set to "yes" if building a shared library automatically hardcodes DIR +# into the library and all subsequent libraries and executables linked +# against it. +hardcode_automatic=$hardcode_automatic + +# Set to yes if linker adds runtime paths of dependent libraries +# to runtime path list. +inherit_rpath=$inherit_rpath + +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs + +# Set to "yes" if exported symbols are required. +always_export_symbols=$always_export_symbols + +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds + +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms + +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms + +# Commands necessary for linking programs (against libraries) with templates. +prelink_cmds=$lt_prelink_cmds + +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds + +# Specify filename containing input files. +file_list_spec=$lt_file_list_spec + +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action + +# The directories searched by this compiler when creating a shared library. +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs + +# Dependencies to place before and after the objects being linked to +# create a shared library. +predep_objects=$lt_predep_objects +postdep_objects=$lt_postdep_objects +predeps=$lt_predeps +postdeps=$lt_postdeps + +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path + +# ### END LIBTOOL CONFIG + +_LT_EOF + + case $host_os in + aix3*) + cat <<\_LT_EOF >> "$cfgfile" +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +_LT_EOF + ;; + esac + + +ltmain="$ac_aux_dir/ltmain.sh" + + + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) + + if test x"$xsi_shell" = xyes; then + sed -e '/^func_dirname ()$/,/^} # func_dirname /c\ +func_dirname ()\ +{\ +\ case ${1} in\ +\ */*) func_dirname_result="${1%/*}${2}" ;;\ +\ * ) func_dirname_result="${3}" ;;\ +\ esac\ +} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_basename ()$/,/^} # func_basename /c\ +func_basename ()\ +{\ +\ func_basename_result="${1##*/}"\ +} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\ +func_dirname_and_basename ()\ +{\ +\ case ${1} in\ +\ */*) func_dirname_result="${1%/*}${2}" ;;\ +\ * ) func_dirname_result="${3}" ;;\ +\ esac\ +\ func_basename_result="${1##*/}"\ +} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_stripname ()$/,/^} # func_stripname /c\ +func_stripname ()\ +{\ +\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\ +\ # positional parameters, so assign one to ordinary parameter first.\ +\ func_stripname_result=${3}\ +\ func_stripname_result=${func_stripname_result#"${1}"}\ +\ func_stripname_result=${func_stripname_result%"${2}"}\ +} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\ +func_split_long_opt ()\ +{\ +\ func_split_long_opt_name=${1%%=*}\ +\ func_split_long_opt_arg=${1#*=}\ +} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\ +func_split_short_opt ()\ +{\ +\ func_split_short_opt_arg=${1#??}\ +\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\ +} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\ +func_lo2o ()\ +{\ +\ case ${1} in\ +\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\ +\ *) func_lo2o_result=${1} ;;\ +\ esac\ +} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_xform ()$/,/^} # func_xform /c\ +func_xform ()\ +{\ + func_xform_result=${1%.*}.lo\ +} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_arith ()$/,/^} # func_arith /c\ +func_arith ()\ +{\ + func_arith_result=$(( $* ))\ +} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_len ()$/,/^} # func_len /c\ +func_len ()\ +{\ + func_len_result=${#1}\ +} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + +fi + +if test x"$lt_shell_append" = xyes; then + sed -e '/^func_append ()$/,/^} # func_append /c\ +func_append ()\ +{\ + eval "${1}+=\\${2}"\ +} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\ +func_append_quoted ()\ +{\ +\ func_quote_for_eval "${2}"\ +\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\ +} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + # Save a `func_append' function call where possible by direct use of '+=' + sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +else + # Save a `func_append' function call even when '+=' is not available + sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +fi + +if test x"$_lt_function_replace_fail" = x":"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;} +fi + + + mv -f "$cfgfile" "$ofile" || + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" + + + cat <<_LT_EOF >> "$ofile" + +# ### BEGIN LIBTOOL TAG CONFIG: CXX + +# The linker used to build libraries. +LD=$lt_LD_CXX + +# How to create reloadable object files. +reload_flag=$lt_reload_flag_CXX +reload_cmds=$lt_reload_cmds_CXX + +# Commands used to build an old-style archive. +old_archive_cmds=$lt_old_archive_cmds_CXX + +# A language specific compiler. +CC=$lt_compiler_CXX + +# Is the compiler the GNU compiler? +with_gcc=$GCC_CXX + +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX + +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic_CXX + +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl_CXX + +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static_CXX + +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX + +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc_CXX + +# Whether or not to disallow shared libs when runtime libs are static. +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX + +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX + +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX + +# Whether the compiler copes with passing no objects directly. +compiler_needs_object=$lt_compiler_needs_object_CXX + +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX + +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX + +# Commands used to build a shared archive. +archive_cmds=$lt_archive_cmds_CXX +archive_expsym_cmds=$lt_archive_expsym_cmds_CXX + +# Commands used to build a loadable module if different from building +# a shared archive. +module_cmds=$lt_module_cmds_CXX +module_expsym_cmds=$lt_module_expsym_cmds_CXX + +# Whether we are building with GNU ld or not. +with_gnu_ld=$lt_with_gnu_ld_CXX + +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag_CXX + +# Flag that enforces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag_CXX + +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX + +# Whether we need a single "-rpath" flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX + +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary. +hardcode_direct=$hardcode_direct_CXX + +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary and the resulting library dependency is +# "absolute",i.e impossible to change by setting \${shlibpath_var} if the +# library is relocated. +hardcode_direct_absolute=$hardcode_direct_absolute_CXX + +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR +# into the resulting binary. +hardcode_minus_L=$hardcode_minus_L_CXX + +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR +# into the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX + +# Set to "yes" if building a shared library automatically hardcodes DIR +# into the library and all subsequent libraries and executables linked +# against it. +hardcode_automatic=$hardcode_automatic_CXX + +# Set to yes if linker adds runtime paths of dependent libraries +# to runtime path list. +inherit_rpath=$inherit_rpath_CXX + +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs_CXX + +# Set to "yes" if exported symbols are required. +always_export_symbols=$always_export_symbols_CXX + +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds_CXX + +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms_CXX + +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms_CXX + +# Commands necessary for linking programs (against libraries) with templates. +prelink_cmds=$lt_prelink_cmds_CXX + +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds_CXX + +# Specify filename containing input files. +file_list_spec=$lt_file_list_spec_CXX + +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action_CXX + +# The directories searched by this compiler when creating a shared library. +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX + +# Dependencies to place before and after the objects being linked to +# create a shared library. +predep_objects=$lt_predep_objects_CXX +postdep_objects=$lt_postdep_objects_CXX +predeps=$lt_predeps_CXX +postdeps=$lt_postdeps_CXX + +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path_CXX + +# ### END LIBTOOL TAG CONFIG: CXX +_LT_EOF + + ;; + "dddmp/exp/test1.sh":F) chmod +x dddmp/exp/test1.sh ;; + "dddmp/exp/test2.sh":F) chmod +x dddmp/exp/test2.sh ;; + "dddmp/exp/test3.sh":F) chmod +x dddmp/exp/test3.sh ;; + "dddmp/exp/test4.sh":F) chmod +x dddmp/exp/test4.sh ;; + "dddmp/exp/test5.sh":F) chmod +x dddmp/exp/test5.sh ;; + "dddmp/exp/test6.sh":F) chmod +x dddmp/exp/test6.sh ;; + "dddmp/exp/test7.sh":F) chmod +x dddmp/exp/test7.sh ;; + + esac +done # for ac_tag + + +as_fn_exit 0 +_ACEOF +ac_clean_files=$ac_clean_files_save + +test $ac_write_fail = 0 || + as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 + + +# configure is writing to config.log, and then calls config.status. +# config.status does its own redirection, appending to config.log. +# Unfortunately, on DOS this fails, as config.log is still kept open +# by configure, so config.status won't be able to write to it; its +# output is simply discarded. So we exec the FD to /dev/null, +# effectively closing config.log, so it can be properly (re)opened and +# appended to by config.status. When coming back to configure, we +# need to make the FD available again. +if test "$no_create" != yes; then + ac_cs_success=: + ac_config_status_args= + test "$silent" = yes && + ac_config_status_args="$ac_config_status_args --quiet" + exec 5>/dev/null + $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false + exec 5>>config.log + # Use ||, not &&, to avoid exiting from the if with $? = 1, which + # would make configure fail if this is the last instruction. + $ac_cs_success || as_fn_exit 1 +fi +if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 +$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} +fi + + +echo \ +"-------------------------------------------------- +Configuration summary for ${PACKAGE_NAME} ${PACKAGE_VERSION} + +Build system : ${build} +Host system : ${host} +Prefix : '${prefix}' +Compilers : '${CC} ${AM_CPPFLAGS} ${CPPFLAGS} ${AM_CFLAGS} ${CFLAGS}' + : '${CXX} ${AM_CPPFLAGS} ${CPPFLAGS} ${AM_CXXFLAGS} ${CXXFLAGS}' +Shared library : ${enable_shared} + dddmp enabled : ${enable_dddmp:-no} + obj enabled : ${enable_obj:-no} +--------------------------------------------------" diff --git a/resources/3rdparty/cudd-3.0.0/configure.ac b/resources/3rdparty/cudd-3.0.0/configure.ac new file mode 100644 index 000000000..25331173c --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/configure.ac @@ -0,0 +1,176 @@ +# -*- Autoconf -*- +# Process this file with autoconf to produce a configure script. + +AC_PREREQ([2.69]) +AC_INIT([cudd], [3.0.0], [Fabio@Colorado.EDU]) +AC_CONFIG_AUX_DIR([build-aux]) +AC_CONFIG_MACRO_DIR([m4]) +AC_CANONICAL_HOST +AM_INIT_AUTOMAKE( + [1.14 -Wall -Werror foreign subdir-objects color-tests silent-rules] +) +AC_REQUIRE_AUX_FILE([tap-driver.sh]) + +AC_ARG_ENABLE([dddmp], + [AS_HELP_STRING([--enable-dddmp],[include libdddmp in libcudd])]) +AM_CONDITIONAL([DDDMP], [test x$enable_dddmp = xyes]) + +AC_ARG_ENABLE([obj], + [AS_HELP_STRING([--enable-obj],[include libobj in libcudd])]) +AM_CONDITIONAL([OBJ], [test x$enable_obj = xyes]) + +AC_ARG_WITH([system-qsort], + [AS_HELP_STRING([--with-system-qsort], + [use system qsort instead of portable one])], + [],[with_system_qsort=no]) +if test x$with_system_qsort != xno ; then + AC_DEFINE([USE_SYSTEM_QSORT], [1], [Define to 1 to use system qsort]) +fi + +# Set our own default (instead of "-g -O2") unless CFLAGS is already defined. +: ${CFLAGS="-Wall -Wextra -g -O3"} +: ${CXXFLAGS="-Wall -Wextra -std=c++0x -g -O3"} + +AC_PROG_CC +AC_PROG_CXX +AM_PROG_AR +LT_PREREQ([2.4]) +LT_INIT([win32-dll disable-shared]) + +AC_CONFIG_SRCDIR([st/st.c]) +AC_CONFIG_HEADERS([config.h]) + +# Checks for programs. +AC_C_BIGENDIAN +AM_CONDITIONAL([CROSS_COMPILING],[test x$cross_compiling = xyes]) + +# Building documentation requires doxygen, pdflatex, and makeindex. +AC_CHECK_PROGS([DOXYGEN], [doxygen]) +if test -z "$DOXYGEN"; then + AC_MSG_WARN([Doxygen not found - continuing without Doxygen support]) +fi +AM_CONDITIONAL([HAVE_DOXYGEN],[test -n "$DOXYGEN"]) +AM_COND_IF([HAVE_DOXYGEN], [AC_CONFIG_FILES([Doxyfile])]) + +AC_CHECK_PROGS([PDFLATEX], [pdflatex]) +if test -z "$PDFLATEX"; then + AC_MSG_WARN([pdflatex not found - unable to compile manual to PDF]) +fi +AC_CHECK_PROGS([MAKEINDEX], [makeindex]) +if test -z "$MAKEINDEX"; then + AC_MSG_WARN([makeindex not found - unable to compile manual to PDF]) +fi +AM_CONDITIONAL([HAVE_PDFLATEX],[test -n "$PDFLATEX" && test -n "$MAKEINDEX"]) +AM_COND_IF([HAVE_PDFLATEX], [AC_CONFIG_FILES([doc/cudd.tex])]) + +# Checks for libraries. +#AC_CHECK_LIB([m],[pow]) +AC_SEARCH_LIBS([pow],[m]) +AC_CHECK_LIB([pthread],[pthread_create],[have_pthreads=yes],[have_pthreads=no]) +AM_CONDITIONAL([HAVE_PTHREADS],[test x$have_pthreads = xyes]) +# Check for Windows API functions. +AC_SEARCH_LIBS([WSAStartup],[ws2_32]) +AC_SEARCH_LIBS([GetProcessMemoryInfo],[psapi]) + +# Checks for header files. +# First check for mandatory headers... +AC_CHECK_HEADERS([float.h inttypes.h limits.h stddef.h stdlib.h string.h assert.h math.h], [], [have_mandatory_headers=no]) +if test "x${have_mandatory_headers}" = xno; then + AC_MSG_ERROR([One or more mandatory headers missing. Check 'config.log'.]) +fi +# ...then check for optional C headers. +AC_CHECK_HEADERS([unistd.h sys/time.h sys/times.h sys/resource.h sys/wait.h]) +# Finally, check C++ optional headers. +AC_MSG_CHECKING([for working C++ thread header]) +AC_LANG_PUSH([C++]) +AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([#include <thread>], [[ std::thread([] {}).join()]])], + [have_working_thread=yes],[have_working_thread=no]) +AC_LANG_POP([C++]) +if test x$have_working_thread = xyes ; then + AC_MSG_RESULT(yes) + AC_DEFINE([HAVE_WORKING_THREAD], [1], [Define to 1 if C++ thread header is usable]) +else + AC_MSG_RESULT(no) +fi + +# Checks for typedefs, structures, and compiler characteristics. +AC_CHECK_HEADER_STDBOOL +AC_C_INLINE +AC_TYPE_SIZE_T +AC_TYPE_UINT16_T +AC_TYPE_UINT32_T +AC_CHECK_TYPES([ptrdiff_t]) +AC_CHECK_SIZEOF([int]) +AC_CHECK_SIZEOF([long]) +AC_CHECK_SIZEOF([void *]) +AC_CHECK_SIZEOF([long double]) +MINGW_AC_WIN32_NATIVE_HOST +AM_CONDITIONAL([MINGW64], [test x$mingw_cv_win32_host = xyes]) +if test x$mingw_cv_win32_host = xyes ; then + AC_DEFINE([__USE_MINGW_ANSI_STDIO], [1], [Define to 1 to enable C99-compliant printf on MinGW-w64]) +fi +MODERN_CXX +if test x$ac_cv_have_modern_cxx = xyes ; then + AC_DEFINE([HAVE_MODERN_CXX], [1], [Define to 1 if your compiler supports enough C++11]) +fi + +# Checks for library functions. +# First the mandatory functions... +AC_CHECK_FUNCS([pow sqrt strchr strstr], + [], [have_mandatory_functions=no]) +if test "x${have_mandatory_functions}" = xno; then + AC_MSG_ERROR([One or more mandatory functions missing. Check 'config.log'.]) +fi +# ...then check for optional functions. +AC_CHECK_FUNCS([powl gethostname getrlimit getrusage sysconf]) + +# Check for a working implementation of IEEE 754 floating point +# Specifically, check for correct treatment of +Infinity +AC_MSG_CHECKING([for +Infinity (IEEE 754 floating point)]) +AC_CACHE_VAL(ac_cv_have_ieee_754, +[ AC_TRY_RUN([ +#include <math.h> +main(void) +{ + if (HUGE_VAL != HUGE_VAL * 3 || HUGE_VAL != HUGE_VAL / 3) return 1; + return 0; +} +],ac_cv_have_ieee_754=yes,ac_cv_have_ieee_754=no,ac_cv_have_ieee_754=maybe)]) +if test x$ac_cv_have_ieee_754 = xmaybe ; then + AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([#include <math.h>], [ double x = INFINITY])], + [ac_cv_have_ieee_754=yes],[ac_cv_have_ieee_754=no]) +fi +if test x$ac_cv_have_ieee_754 = xyes ; then + AC_MSG_RESULT(yes) + AC_DEFINE([HAVE_IEEE_754], [1], [Define to 1 if you have working floating-point infinities]) +else + AC_MSG_RESULT(no) +fi + + +AC_CONFIG_FILES([Makefile]) +AC_CONFIG_FILES([dddmp/exp/test1.sh], [chmod +x dddmp/exp/test1.sh]) +AC_CONFIG_FILES([dddmp/exp/test2.sh], [chmod +x dddmp/exp/test2.sh]) +AC_CONFIG_FILES([dddmp/exp/test3.sh], [chmod +x dddmp/exp/test3.sh]) +AC_CONFIG_FILES([dddmp/exp/test4.sh], [chmod +x dddmp/exp/test4.sh]) +AC_CONFIG_FILES([dddmp/exp/test5.sh], [chmod +x dddmp/exp/test5.sh]) +AC_CONFIG_FILES([dddmp/exp/test6.sh], [chmod +x dddmp/exp/test6.sh]) +AC_CONFIG_FILES([dddmp/exp/test7.sh], [chmod +x dddmp/exp/test7.sh]) + +AC_OUTPUT + +echo \ +"-------------------------------------------------- +Configuration summary for ${PACKAGE_NAME} ${PACKAGE_VERSION} + +Build system : ${build} +Host system : ${host} +Prefix : '${prefix}' +Compilers : '${CC} ${AM_CPPFLAGS} ${CPPFLAGS} ${AM_CFLAGS} ${CFLAGS}' + : '${CXX} ${AM_CPPFLAGS} ${CPPFLAGS} ${AM_CXXFLAGS} ${CXXFLAGS}' +Shared library : ${enable_shared} + dddmp enabled : ${enable_dddmp:-no} + obj enabled : ${enable_obj:-no} +--------------------------------------------------" diff --git a/resources/3rdparty/cudd-3.0.0/cplusplus/Included.am b/resources/3rdparty/cudd-3.0.0/cplusplus/Included.am new file mode 100644 index 000000000..91feba131 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cplusplus/Included.am @@ -0,0 +1,48 @@ +cplusplus_sources = cplusplus/cuddObj.hh cplusplus/cuddObj.cc + +if OBJ +cudd_libcudd_la_SOURCES += $(cplusplus_sources) +else +noinst_LTLIBRARIES += cplusplus/libobj.la +cplusplus_libobj_la_SOURCES = $(cplusplus_sources) +cplusplus_libobj_la_CPPFLAGS = -I$(top_srcdir)/cudd -I$(top_srcdir)/mtr \ + -I$(top_srcdir)/epd -I$(top_srcdir)/st +endif !OBJ + +check_PROGRAMS += cplusplus/testobj cplusplus/testmulti + +cplusplus_testobj_SOURCES = cplusplus/testobj.cc +if OBJ +cplusplus_testobj_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +cplusplus_testobj_LDADD = +else +cplusplus_testobj_CPPFLAGS = $(cplusplus_libobj_la_CPPFLAGS) +cplusplus_testobj_LDADD = cplusplus/libobj.la +endif !OBJ +cplusplus_testobj_LDADD += cudd/libcudd.la + +cplusplus_testmulti_SOURCES = cplusplus/testmulti.cc +if OBJ +cplusplus_testmulti_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +cplusplus_testmulti_LDADD = +else +cplusplus_testmulti_CPPFLAGS = $(cplusplus_libobj_la_CPPFLAGS) +cplusplus_testmulti_LDADD = cplusplus/libobj.la +endif !OBJ +cplusplus_testmulti_LDADD += cudd/libcudd.la +if HAVE_PTHREADS +cplusplus_testmulti_LDFLAGS = -pthread +endif HAVE_PTHREADS + +check_SCRIPTS += cplusplus/test_obj.test +dist_check_DATA += cplusplus/test.out cplusplus/multi.out +EXTRA_DIST += cplusplus/test_obj.test.in +if !CROSS_COMPILING +TESTS += cplusplus/test_obj.test +endif !CROSS_COMPILING + +cplusplus/test_obj.test: cplusplus/test_obj.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ + +CLEANFILES += cplusplus/test.tst cplusplus/multi.tst diff --git a/resources/3rdparty/cudd-2.5.0/src/obj/cuddObj.cc b/resources/3rdparty/cudd-3.0.0/cplusplus/cuddObj.cc similarity index 79% rename from resources/3rdparty/cudd-2.5.0/src/obj/cuddObj.cc rename to resources/3rdparty/cudd-3.0.0/cplusplus/cuddObj.cc index e15f399f6..e1c9807d8 100644 --- a/resources/3rdparty/cudd-2.5.0/src/obj/cuddObj.cc +++ b/resources/3rdparty/cudd-3.0.0/cplusplus/cuddObj.cc @@ -1,18 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddObj.cc] + @ingroup cplusplus - PackageName [cuddObj] + @brief Functions for the C++ object-oriented encapsulation of CUDD. - Synopsis [Functions for the C++ object-oriented encapsulation of CUDD.] + @author Fabio Somenzi - Description [] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,45 +38,125 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include <iostream> #include <sstream> #include <cassert> #include <cstdlib> +#include <cstring> #include <algorithm> +#include <stdexcept> +#include "epdInt.h" +#include "cuddInt.h" #include "cuddObj.hh" using std::cout; using std::cerr; +using std::ostream; using std::endl; using std::hex; +using std::dec; using std::string; using std::vector; using std::sort; +namespace cudd { + // --------------------------------------------------------------------------- // Variable declarations // --------------------------------------------------------------------------- -#ifndef lint -static char rcsid[] UNUSED = "$Id: cuddObj.cc,v 1.15 2012/02/05 01:06:40 fabio Exp fabio $"; +// --------------------------------------------------------------------------- +// Members of class Capsule +// --------------------------------------------------------------------------- + +/** + @brief Class for reference counting of CUDD managers. + + @see Cudd DD ABDD ADD BDD ZDD + +*/ +class Capsule { +public: + Capsule(unsigned int numVars, unsigned int numVarsZ, + unsigned int numSlots, unsigned int cacheSize, + unsigned long maxMemory, PFC defaultHandler); + ~Capsule(); +#if HAVE_MODERN_CXX == 1 + Capsule(Capsule const &) = delete; + Capsule & operator=(Capsule const &) = delete; +#else +private: + Capsule(Capsule const &); // not defined + Capsule & operator=(Capsule const &); // not defined +public: +#endif + DdManager *manager; + PFC errorHandler; + PFC timeoutHandler; + PFC terminationHandler; + std::vector<char *> varnames; + int ref; + bool verbose; +}; + + +Capsule::Capsule( + unsigned int numVars, + unsigned int numVarsZ, + unsigned int numSlots, + unsigned int cacheSize, + unsigned long maxMemory, + PFC defaultHandler) +{ + errorHandler = defaultHandler; + timeoutHandler = defaultHandler; + terminationHandler = defaultHandler; + manager = Cudd_Init(numVars, numVarsZ, numSlots, cacheSize, maxMemory); + if (!manager) + errorHandler("Out of memory"); + verbose = 0; // initially terse + ref = 1; + +} // Capsule::Capsule + + +Capsule::~Capsule() +{ +#ifdef DD_DEBUG + if (manager) { + int retval = Cudd_CheckZeroRef(manager); + if (retval != 0) { + cerr << retval << " unexpected non-zero reference counts" << endl; + } else if (verbose) { + cerr << "All went well" << endl; + } + } #endif + for (vector<char *>::iterator it = varnames.begin(); + it != varnames.end(); ++it) { + delete [] *it; + } + Cudd_Quit(manager); + +} // Capsule::~Capsule + // --------------------------------------------------------------------------- // Members of class DD // --------------------------------------------------------------------------- -namespace cudd { DD::DD() : p(0), node(0) {} DD::DD(Capsule *cap, DdNode *ddNode) : p(cap), node(ddNode) { - if (node != 0) Cudd_Ref(node); + if (node) Cudd_Ref(node); if (p->verbose) { - cout << "Standard DD constructor for node " << hex << long(node) << + cout << "Standard DD constructor for node " << hex << node << dec << " ref = " << Cudd_Regular(node)->ref << "\n"; } @@ -89,9 +165,9 @@ DD::DD(Capsule *cap, DdNode *ddNode) : p(cap), node(ddNode) { DD::DD(Cudd const & manager, DdNode *ddNode) : p(manager.p), node(ddNode) { checkReturnValue(ddNode); - if (node != 0) Cudd_Ref(node); + if (node) Cudd_Ref(node); if (p->verbose) { - cout << "Standard DD constructor for node " << hex << long(node) << + cout << "Standard DD constructor for node " << hex << node << dec << " ref = " << Cudd_Regular(node)->ref << "\n"; } @@ -101,10 +177,10 @@ DD::DD(Cudd const & manager, DdNode *ddNode) : p(manager.p), node(ddNode) { DD::DD(const DD &from) { p = from.p; node = from.node; - if (node != 0) { + if (node) { Cudd_Ref(node); if (p->verbose) { - cout << "Copy DD constructor for node " << hex << long(node) << + cout << "Copy DD constructor for node " << hex << node << dec << " ref = " << Cudd_Regular(node)->ref << "\n"; } } @@ -130,7 +206,7 @@ DD::checkSameManager( inline void DD::checkReturnValue( - const DdNode *result) const + const void *result) const { if (result == 0) { DdManager *mgr = p->manager; @@ -149,10 +225,17 @@ DD::checkReturnValue( std::ostringstream msg; unsigned long lag = Cudd_ReadElapsedTime(mgr) - Cudd_ReadTimeLimit(mgr); - msg << "Timeout expired. Lag = " << lag << " ms.\n"; + msg << "Timeout expired. Lag = " << lag << " ms."; p->timeoutHandler(msg.str()); } break; + case CUDD_TERMINATION: + { + std::ostringstream msg; + msg << "Terminated.\n"; + p->terminationHandler(msg.str()); + } + break; case CUDD_INVALID_ARG: p->errorHandler("Invalid argument."); break; @@ -160,7 +243,6 @@ DD::checkReturnValue( p->errorHandler("Internal error."); break; case CUDD_NO_ERROR: - default: p->errorHandler("Unexpected error."); break; } @@ -171,8 +253,8 @@ DD::checkReturnValue( inline void DD::checkReturnValue( - const int result, - const int expected) const + int result, + int expected) const { if (result != expected) { DdManager *mgr = p->manager; @@ -195,6 +277,13 @@ DD::checkReturnValue( p->timeoutHandler(msg.str()); } break; + case CUDD_TERMINATION: + { + std::ostringstream msg; + msg << "Terminated.\n"; + p->terminationHandler(msg.str()); + } + break; case CUDD_INVALID_ARG: p->errorHandler("Invalid argument."); break; @@ -202,7 +291,6 @@ DD::checkReturnValue( p->errorHandler("Internal error."); break; case CUDD_NO_ERROR: - default: p->errorHandler("Unexpected error."); break; } @@ -263,11 +351,11 @@ ABDD::ABDD(const ABDD &from) : DD(from) {} ABDD::~ABDD() { - if (node != 0) { + if (node) { Cudd_RecursiveDeref(p->manager,node); if (p->verbose) { - cout << "ADD/BDD destructor called for node " << hex << - long(node) << " ref = " << Cudd_Regular(node)->ref << "\n"; + cout << "ADD/BDD destructor called for node " << hex << dec << + node << " ref = " << Cudd_Regular(node)->ref << "\n"; } } @@ -308,11 +396,26 @@ ABDD::print( int verbosity) const { cout.flush(); + if (!node) defaultError("empty DD."); int retval = Cudd_PrintDebug(p->manager,node,nvars,verbosity); - if (retval == 0) p->errorHandler("print failed"); + fflush(Cudd_ReadStdout(p->manager)); + checkReturnValue(retval); + //if (retval == 0) p->errorHandler("print failed"); } // ABDD::print +void +ABDD::summary( + int nvars, + int mode) const +{ + cout.flush(); + if (!node) defaultError("empty DD."); + int retval = Cudd_PrintSummary(p->manager,node,nvars,mode); + fflush(Cudd_ReadStdout(p->manager)); + checkReturnValue(retval); + +} // ABDD::summary // --------------------------------------------------------------------------- // Members of class BDD @@ -329,18 +432,18 @@ BDD::operator=( const BDD& right) { if (this == &right) return *this; - if (right.node != 0) Cudd_Ref(right.node); - if (node != 0) { + if (right.node) Cudd_Ref(right.node); + if (node) { Cudd_RecursiveDeref(p->manager,node); if (p->verbose) { - cout << "BDD dereferencing for node " << hex << long(node) << + cout << "BDD dereferencing for node " << hex << node << dec << " ref = " << Cudd_Regular(node)->ref << "\n"; } } node = right.node; p = right.p; - if (node != 0 && p->verbose) { - cout << "BDD assignment for node " << hex << long(node) << + if (node && p->verbose) { + cout << "BDD assignment for node " << hex << node << dec << " ref = " << Cudd_Regular(node)->ref << "\n"; } return *this; @@ -353,7 +456,7 @@ BDD::operator<=( const BDD& other) const { DdManager *mgr = checkSameManager(other); - return Cudd_bddLeq(mgr,node,other.node) != 0; + return Cudd_bddLeq(mgr,node,other.node); } // BDD::operator<= @@ -363,7 +466,7 @@ BDD::operator>=( const BDD& other) const { DdManager *mgr = checkSameManager(other); - return Cudd_bddLeq(mgr,other.node,node) != 0; + return Cudd_bddLeq(mgr,other.node,node); } // BDD::operator>= @@ -373,7 +476,7 @@ BDD::operator<( const BDD& other) const { DdManager *mgr = checkSameManager(other); - return node != other.node && (Cudd_bddLeq(mgr,node,other.node) != 0); + return node != other.node && Cudd_bddLeq(mgr,node,other.node); } // BDD::operator< @@ -383,7 +486,7 @@ BDD::operator>( const BDD& other) const { DdManager *mgr = checkSameManager(other); - return node != other.node && (Cudd_bddLeq(mgr,other.node,node) != 0); + return node != other.node && Cudd_bddLeq(mgr,other.node,node); } // BDD::operator> @@ -566,6 +669,22 @@ BDD::operator-=( } // BDD::operator-= +ostream & operator<<(ostream & os, BDD const & f) +{ + if (!f.node) defaultError("empty DD."); + DdManager *mgr = f.p->manager; + vector<char *> const & vn = f.p->varnames; + char const * const *inames = vn.size() == (size_t) Cudd_ReadSize(mgr) ? + &vn[0] : 0; + char * str = Cudd_FactoredFormString(mgr, f.node, inames); + f.checkReturnValue(str); + os << string(str); + free(str); + return os; + +} // operator<< + + bool BDD::IsZero() const { @@ -574,6 +693,14 @@ BDD::IsZero() const } // BDD::IsZero +bool +BDD::IsVar() const +{ + return Cudd_bddIsVar(p->manager, node); + +} // BDD::IsVar + + // --------------------------------------------------------------------------- // Members of class ADD // --------------------------------------------------------------------------- @@ -590,8 +717,8 @@ ADD::operator=( const ADD& right) { if (this == &right) return *this; - if (right.node != 0) Cudd_Ref(right.node); - if (node != 0) { + if (right.node) Cudd_Ref(right.node); + if (node) { Cudd_RecursiveDeref(p->manager,node); } node = right.node; @@ -606,7 +733,7 @@ ADD::operator<=( const ADD& other) const { DdManager *mgr = checkSameManager(other); - return Cudd_addLeq(mgr,node,other.node) != 0; + return Cudd_addLeq(mgr,node,other.node); } // ADD::operator<= @@ -616,7 +743,7 @@ ADD::operator>=( const ADD& other) const { DdManager *mgr = checkSameManager(other); - return Cudd_addLeq(mgr,other.node,node) != 0; + return Cudd_addLeq(mgr,other.node,node); } // ADD::operator>= @@ -626,7 +753,7 @@ ADD::operator<( const ADD& other) const { DdManager *mgr = checkSameManager(other); - return node != other.node && (Cudd_addLeq(mgr,node,other.node) != 0); + return node != other.node && Cudd_addLeq(mgr,node,other.node); } // ADD::operator< @@ -636,7 +763,7 @@ ADD::operator>( const ADD& other) const { DdManager *mgr = checkSameManager(other); - return node != other.node && (Cudd_addLeq(mgr,other.node,node) != 0); + return node != other.node && Cudd_addLeq(mgr,other.node,node); } // ADD::operator> @@ -811,10 +938,10 @@ ZDD::ZDD(const ZDD &from) : DD(from) {} ZDD::~ZDD() { - if (node != 0) { + if (node) { Cudd_RecursiveDerefZdd(p->manager,node); if (p->verbose) { - cout << "ZDD destructor called for node " << hex << long(node) << + cout << "ZDD destructor called for node " << hex << node << dec << " ref = " << Cudd_Regular(node)->ref << "\n"; } } @@ -827,18 +954,18 @@ ZDD::operator=( const ZDD& right) { if (this == &right) return *this; - if (right.node != 0) Cudd_Ref(right.node); - if (node != 0) { + if (right.node) Cudd_Ref(right.node); + if (node) { Cudd_RecursiveDerefZdd(p->manager,node); if (p->verbose) { - cout << "ZDD dereferencing for node " << hex << long(node) << + cout << "ZDD dereferencing for node " << hex << node << dec << " ref = " << node->ref << "\n"; } } node = right.node; p = right.p; - if (node != 0 && p->verbose) { - cout << "ZDD assignment for node " << hex << long(node) << + if (node && p->verbose) { + cout << "ZDD assignment for node " << hex << node << dec << " ref = " << node->ref << "\n"; } return *this; @@ -915,6 +1042,7 @@ ZDD::print( { cout.flush(); int retval = Cudd_zddPrintDebug(p->manager,node,nvars,verbosity); + fflush(Cudd_ReadStdout(p->manager)); if (retval == 0) p->errorHandler("print failed"); } // ZDD::print @@ -1065,14 +1193,10 @@ Cudd::Cudd( unsigned int numVarsZ, unsigned int numSlots, unsigned int cacheSize, - unsigned long maxMemory) + unsigned long maxMemory, + PFC defaultHandler) { - p = new Capsule; - p->manager = Cudd_Init(numVars,numVarsZ,numSlots,cacheSize,maxMemory); - p->errorHandler = defaultError; - p->timeoutHandler = defaultError; - p->verbose = 0; // initially terse - p->ref = 1; + p = new Capsule(numVars,numVarsZ,numSlots,cacheSize,maxMemory,defaultHandler); } // Cudd::Cudd @@ -1091,34 +1215,50 @@ Cudd::Cudd( Cudd::~Cudd() { if (--p->ref == 0) { -#ifdef DD_DEBUG - int retval = Cudd_CheckZeroRef(p->manager); - if (retval != 0) { - cerr << retval << " unexpected non-zero reference counts" << endl; - } else if (p->verbose) { - cerr << "All went well" << endl; - } -#endif - Cudd_Quit(p->manager); delete p; } } // Cudd::~Cudd +DdManager * +Cudd::getManager(void) const +{ + return p->manager; + +} // Cudd::getManager + + +void +Cudd::makeVerbose(void) const +{ + p->verbose = 1; + +} // Cudd::makeVerbose + + +void +Cudd::makeTerse(void) const +{ + p->verbose = 0; + +} // Cudd::makeTerse + + +bool +Cudd::isVerbose(void) const +{ + return p->verbose; + +} // Cudd::isVerbose + + Cudd& Cudd::operator=( const Cudd& right) { right.p->ref++; if (--p->ref == 0) { // disconnect self - int retval = Cudd_CheckZeroRef(p->manager); - if (retval != 0) { - cerr << retval << " unexpected non-zero reference counts" << endl; - } else if (p->verbose) { - cerr << "All went well\n"; - } - Cudd_Quit(p->manager); delete p; } p = right.p; @@ -1165,9 +1305,55 @@ Cudd::getTimeoutHandler() const } // Cudd::getTimeourHandler +PFC +Cudd::setTerminationHandler( + PFC newHandler) const +{ + PFC oldHandler = p->terminationHandler; + p->terminationHandler = newHandler; + return oldHandler; + +} // Cudd::setTerminationHandler + + +PFC +Cudd::getTerminationHandler() const +{ + return p->terminationHandler; + +} // Cudd::getTerminationHandler + + +void +Cudd::pushVariableName(std::string s) const +{ + char * cstr = new char[s.length() + 1]; + strcpy(cstr, s.c_str()); + p->varnames.push_back(cstr); +} + + +void +Cudd::clearVariableNames(void) const +{ + for (vector<char *>::iterator it = p->varnames.begin(); + it != p->varnames.end(); ++it) { + delete [] *it; + } + p->varnames.clear(); +} + + +std::string +Cudd::getVariableName(size_t i) const +{ + return std::string(p->varnames.at(i)); +} + + inline void Cudd::checkReturnValue( - const DdNode *result) const + const void *result) const { if (result == 0) { if (Cudd_ReadErrorCode(p->manager) == CUDD_MEMORY_OUT) { @@ -1183,6 +1369,10 @@ Cudd::checkReturnValue( Cudd_ReadElapsedTime(mgr) - Cudd_ReadTimeLimit(mgr); msg << "Timeout expired. Lag = " << lag << " ms.\n"; p->timeoutHandler(msg.str()); + } else if (Cudd_ReadErrorCode(p->manager) == CUDD_TERMINATION) { + std::ostringstream msg; + msg << "Terminated.\n"; + p->terminationHandler(msg.str()); } else if (Cudd_ReadErrorCode(p->manager) == CUDD_INVALID_ARG) { p->errorHandler("Invalid argument."); } else if (Cudd_ReadErrorCode(p->manager) == CUDD_INTERNAL_ERROR) { @@ -1213,6 +1403,10 @@ Cudd::checkReturnValue( Cudd_ReadElapsedTime(mgr) - Cudd_ReadTimeLimit(mgr); msg << "Timeout expired. Lag = " << lag << " ms.\n"; p->timeoutHandler(msg.str()); + } else if (Cudd_ReadErrorCode(p->manager) == CUDD_TERMINATION) { + std::ostringstream msg; + msg << "Terminated.\n"; + p->terminationHandler(msg.str()); } else if (Cudd_ReadErrorCode(p->manager) == CUDD_INVALID_ARG) { p->errorHandler("Invalid argument."); } else if (Cudd_ReadErrorCode(p->manager) == CUDD_INTERNAL_ERROR) { @@ -1384,8 +1578,7 @@ void defaultError( string message) { - cerr << message << endl; - assert(false); + throw std::logic_error(message); } // defaultError @@ -1395,7 +1588,6 @@ defaultError( // --------------------------------------------------------------------------- - ADD Cudd::addNewVarAtLevel( int level) const @@ -1469,11 +1661,11 @@ Cudd::ReadTimeLimit() const } // Cudd::ReadTimeLimit -void +unsigned long Cudd::SetTimeLimit( unsigned long tl) const { - Cudd_SetTimeLimit(p->manager, tl); + return Cudd_SetTimeLimit(p->manager, tl); } // Cudd::SetTimeLimit @@ -1506,11 +1698,46 @@ Cudd::UnsetTimeLimit() const bool Cudd::TimeLimited() const { - return Cudd_TimeLimited(p->manager) != 0; + return Cudd_TimeLimited(p->manager); } // Cudd::TimeLimited +void +Cudd::RegisterTerminationCallback( + DD_THFP callback, + void * callback_arg) const +{ + Cudd_RegisterTerminationCallback(p->manager, callback, callback_arg); + +} // Cudd::RegisterTerminationCallback + + +void +Cudd::UnregisterTerminationCallback() const +{ + Cudd_UnregisterTerminationCallback(p->manager); + +} // Cudd::UnregisterTerminationCallback + + +DD_OOMFP +Cudd::RegisterOutOfMemoryCallback( + DD_OOMFP callback) const +{ + return Cudd_RegisterOutOfMemoryCallback(p->manager, callback); + +} // Cudd::RegisterOutOfMemoryCallback + + +void +Cudd::UnregisterOutOfMemoryCallback() const +{ + Cudd_UnregisterOutOfMemoryCallback(p->manager); + +} // Cudd::UnregisterOutOfMemoryCallback + + void Cudd::AutodynEnable( Cudd_ReorderingType method) const @@ -1532,7 +1759,7 @@ bool Cudd::ReorderingStatus( Cudd_ReorderingType * method) const { - return Cudd_ReorderingStatus(p->manager, method) != 0; + return Cudd_ReorderingStatus(p->manager, method); } // Cudd::ReorderingStatus @@ -1558,7 +1785,7 @@ bool Cudd::ReorderingStatusZdd( Cudd_ReorderingType * method) const { - return Cudd_ReorderingStatusZdd(p->manager, method) != 0; + return Cudd_ReorderingStatusZdd(p->manager, method); } // Cudd::ReorderingStatusZdd @@ -1566,7 +1793,7 @@ Cudd::ReorderingStatusZdd( bool Cudd::zddRealignmentEnabled() const { - return Cudd_zddRealignmentEnabled(p->manager) != 0; + return Cudd_zddRealignmentEnabled(p->manager); } // Cudd::zddRealignmentEnabled @@ -1590,7 +1817,7 @@ Cudd::zddRealignDisable() const bool Cudd::bddRealignmentEnabled() const { - return Cudd_bddRealignmentEnabled(p->manager) != 0; + return Cudd_bddRealignmentEnabled(p->manager); } // Cudd::bddRealignmentEnabled @@ -2005,7 +2232,7 @@ Cudd::SetGroupcheck( bool Cudd::GarbageCollectionEnabled() const { - return Cudd_GarbageCollectionEnabled(p->manager) != 0; + return Cudd_GarbageCollectionEnabled(p->manager); } // Cudd::GarbageCollectionEnabled @@ -2029,7 +2256,7 @@ Cudd::DisableGarbageCollection() const bool Cudd::DeadAreCounted() const { - return Cudd_DeadAreCounted(p->manager) != 0; + return Cudd_DeadAreCounted(p->manager); } // Cudd::DeadAreCounted @@ -2211,7 +2438,7 @@ Cudd::IsInHook( DD_HFP f, Cudd_HookType where) const { - return Cudd_IsInHook(p->manager, f, where) != 0; + return Cudd_IsInHook(p->manager, f, where); } // Cudd::IsInHook @@ -2237,7 +2464,7 @@ Cudd::DisableReorderingReporting() const bool Cudd::ReorderingReporting() const { - return Cudd_ReorderingReporting(p->manager) != 0; + return Cudd_ReorderingReporting(p->manager); } // Cudd::ReorderingReporting @@ -2258,6 +2485,13 @@ Cudd::ClearErrorCode() const } // Cudd::ClearErrorCode +DD_OOMFP Cudd::InstallOutOfMemoryHandler(DD_OOMFP newHandler) const +{ + return Cudd_InstallOutOfMemoryHandler(newHandler); + +} // Cudd::InstallOutOfMemoryHandler + + FILE * Cudd::ReadStdout() const { @@ -2331,7 +2565,7 @@ Cudd::SetMaxLive(unsigned int maxLive) const } // Cudd::SetMaxLive -unsigned long +size_t Cudd::ReadMaxMemory() const { return Cudd_ReadMaxMemory(p->manager); @@ -2339,10 +2573,10 @@ Cudd::ReadMaxMemory() const } // Cudd::ReadMaxMemory -void -Cudd::SetMaxMemory(unsigned long maxMem) const +size_t +Cudd::SetMaxMemory(size_t maxMem) const { - Cudd_SetMaxMemory(p->manager, maxMem); + return Cudd_SetMaxMemory(p->manager, maxMem); } // Cudd::SetMaxMemory @@ -2366,7 +2600,7 @@ Cudd::bddUnbindVar(int index) const bool Cudd::bddVarIsBound(int index) const { - return Cudd_bddVarIsBound(p->manager, index) != 0; + return Cudd_bddVarIsBound(p->manager, index); } // Cudd::bddVarIsBound @@ -2414,7 +2648,7 @@ ADD::MinAbstract(const ADD& cube) const checkReturnValue(result); return ADD(p, result); } // ADD::MinAbstract - + ADD ADD::MaxAbstract(const ADD& cube) const { @@ -2623,9 +2857,9 @@ ADD::Pow( DdNode *result = Cudd_addApply(mgr, Cudd_addPow, node, g.node); checkReturnValue(result); return ADD(p, result); - + } // ADD::Pow - + ADD ADD::Mod( const ADD& g) const @@ -2634,9 +2868,9 @@ ADD::Mod( DdNode *result = Cudd_addApply(mgr, Cudd_addMod, node, g.node); checkReturnValue(result); return ADD(p, result); - + } // ADD::Mod - + ADD ADD::LogXY( const ADD& g) const @@ -2645,9 +2879,9 @@ ADD::LogXY( DdNode *result = Cudd_addApply(mgr, Cudd_addLogXY, node, g.node); checkReturnValue(result); return ADD(p, result); - + } // ADD::LogXY - + ADD ADD::Log() const { @@ -2655,9 +2889,9 @@ ADD::Log() const DdNode *result = Cudd_addMonadicApply(mgr, Cudd_addLog, node); checkReturnValue(result); return ADD(p, result); - + } // ADD::Log - + ADD ADD::Floor() const { @@ -2665,9 +2899,9 @@ ADD::Floor() const DdNode *result = Cudd_addMonadicApply(mgr, Cudd_addFloor, node); checkReturnValue(result); return ADD(p, result); - + } // ADD::Floor - + ADD ADD::Ceil() const { @@ -2675,7 +2909,7 @@ ADD::Ceil() const DdNode *result = Cudd_addMonadicApply(mgr, Cudd_addCeil, node); checkReturnValue(result); return ADD(p, result); - + } // ADD::Ceil ADD @@ -2769,7 +3003,7 @@ ADD::Leq( const ADD& g) const { DdManager *mgr = checkSameManager(g); - return Cudd_addLeq(mgr, node, g.node) != 0; + return Cudd_addLeq(mgr, node, g.node); } // ADD::Leq @@ -2810,8 +3044,8 @@ ADD::RoundOff( ADD Cudd::Walsh( - vector<ADD> x, - vector<ADD> y) + std::vector<ADD> x, + std::vector<ADD> y) const { size_t n = x.size(); DdNode **X = new DdNode *[n]; @@ -2820,7 +3054,7 @@ Cudd::Walsh( X[i] = x[i].getNode(); Y[i] = y[i].getNode(); } - DdNode *result = Cudd_addWalsh(p->manager, X, Y, static_cast<int>(n)); + DdNode *result = Cudd_addWalsh(p->manager, X, Y, (int) n); delete [] X; delete [] Y; checkReturnValue(result); @@ -2834,7 +3068,7 @@ Cudd::addResidue( int n, int m, int options, - int top) + int top) const { DdNode *result = Cudd_addResidue(p->manager, n, m, options, top); checkReturnValue(result); @@ -2849,9 +3083,9 @@ ADD::Equals(const ADD& g) const DdNode *result = Cudd_addApply(mgr, Cudd_addEquals, node, g.node); checkReturnValue(result); return ADD(p, result); - + } // ADD::Equals - + ADD ADD::NotEquals(const ADD& g) const { @@ -2859,7 +3093,7 @@ ADD::NotEquals(const ADD& g) const DdNode *result = Cudd_addApply(mgr, Cudd_addNotEquals, node, g.node); checkReturnValue(result); return ADD(p, result); - + } // ADD::NotEquals ADD @@ -2869,9 +3103,9 @@ ADD::LessThan(const ADD& g) const DdNode *result = Cudd_addApply(mgr, Cudd_addLessThan, node, g.node); checkReturnValue(result); return ADD(p, result); - + } // ADD::LessThan - + ADD ADD::LessThanOrEqual(const ADD& g) const { @@ -2879,9 +3113,9 @@ ADD::LessThanOrEqual(const ADD& g) const DdNode *result = Cudd_addApply(mgr, Cudd_addLessThanEquals, node, g.node); checkReturnValue(result); return ADD(p, result); - + } // ADD::LessThanOrEqual - + ADD ADD::GreaterThan(const ADD& g) const { @@ -2889,9 +3123,9 @@ ADD::GreaterThan(const ADD& g) const DdNode *result = Cudd_addApply(mgr, Cudd_addGreaterThan, node, g.node); checkReturnValue(result); return ADD(p, result); - + } // ADD::GreaterThan - + ADD ADD::GreaterThanOrEqual(const ADD& g) const { @@ -2899,10 +3133,9 @@ ADD::GreaterThanOrEqual(const ADD& g) const DdNode *result = Cudd_addApply(mgr, Cudd_addGreaterThanEquals, node, g.node); checkReturnValue(result); return ADD(p, result); - + } // ADD::GreaterThanOrEqual - BDD BDD::AndAbstract( const BDD& g, @@ -3024,9 +3257,9 @@ Cudd::ApaPowerOfTwo( void Cudd::ApaPrintHex( - FILE * fp, int digits, - DdApaNumber number) const + DdApaNumber number, + FILE * fp) const { cout.flush(); int result = Cudd_ApaPrintHex(fp, digits, number); @@ -3037,9 +3270,9 @@ Cudd::ApaPrintHex( void Cudd::ApaPrintDecimal( - FILE * fp, int digits, - DdApaNumber number) const + DdApaNumber number, + FILE * fp) const { cout.flush(); int result = Cudd_ApaPrintDecimal(fp, digits, number); @@ -3048,6 +3281,34 @@ Cudd::ApaPrintDecimal( } // Cudd::ApaPrintDecimal +std::string +Cudd::ApaStringDecimal( + int digits, + DdApaNumber number) const +{ + char * result = Cudd_ApaStringDecimal(digits, number); + checkReturnValue(result); + std::string ret = std::string(result); + free(result); + return ret; + +} // Cudd::ApaStringDecimal + + +void +Cudd::ApaPrintExponential( + int digits, + DdApaNumber number, + int precision, + FILE * fp) const +{ + cout.flush(); + int result = Cudd_ApaPrintExponential(fp, digits, number, precision); + checkReturnValue(result); + +} // Cudd::ApaPrintExponential + + DdApaNumber ABDD::ApaCountMinterm( int nvars, @@ -3072,6 +3333,20 @@ ABDD::ApaPrintMinterm( } // ABDD::ApaPrintMinterm +void +ABDD::ApaPrintMintermExp( + int nvars, + int precision, + FILE * fp) const +{ + cout.flush(); + DdManager *mgr = p->manager; + int result = Cudd_ApaPrintMintermExp(fp, mgr, node, nvars, precision); + checkReturnValue(result); + +} // ABDD::ApaPrintMintermExp + + void ABDD::EpdPrintMinterm( int nvars, @@ -3084,9 +3359,22 @@ ABDD::EpdPrintMinterm( int result = Cudd_EpdCountMinterm(mgr, node, nvars, &count); checkReturnValue(result,0); EpdGetString(&count, str); - fprintf(fp, "%s\n", str); + fprintf(fp, "%s", str); -} // ABDD::ApaPrintMinterm +} // ABDD::EpdPrintMinterm + + +long double +ABDD::LdblCountMinterm( + int nvars) const +{ + cout.flush(); + DdManager *mgr = p->manager; + long double result = Cudd_LdblCountMinterm(mgr, node, nvars); + checkReturnValue(result != (long double) CUDD_OUT_OF_MEM); + return result; + +} // ABDD::LdblCountMinterm BDD @@ -3241,7 +3529,7 @@ BDD::VarIsDependent( const BDD& var) const { DdManager *mgr = p->manager; - return Cudd_bddVarIsDependent(mgr, node, var.node) != 0; + return Cudd_bddVarIsDependent(mgr, node, var.node); } // BDD::VarIsDependent @@ -3404,7 +3692,7 @@ BDD::Leq( const BDD& g) const { DdManager *mgr = checkSameManager(g); - return Cudd_bddLeq(mgr, node, g.node) != 0; + return Cudd_bddLeq(mgr, node, g.node); } // BDD::Leq @@ -3493,7 +3781,7 @@ BDD::Transfer( void -Cudd::DebugCheck() +Cudd::DebugCheck() const { int result = Cudd_DebugCheck(p->manager); checkReturnValue(result == 0); @@ -3502,7 +3790,7 @@ Cudd::DebugCheck() void -Cudd::CheckKeys() +Cudd::CheckKeys() const { int result = Cudd_CheckKeys(p->manager); checkReturnValue(result == 0); @@ -3566,6 +3854,13 @@ BDD::Cofactor( } // BDD::Cofactor +bool +BDD::VarAreSymmetric(int index1, int index2) const +{ + return Cudd_VarsAreSymmetric(p->manager, node, index1, index2); + +} // BDD::VarAreSymmetric + BDD BDD::Compose( const BDD& g, @@ -3606,8 +3901,8 @@ ADD::Permute( ADD ADD::SwapVariables( - vector<ADD> x, - vector<ADD> y) const + std::vector<ADD> x, + std::vector<ADD> y) const { size_t n = x.size(); DdManager *mgr = p->manager; @@ -3617,7 +3912,7 @@ ADD::SwapVariables( X[i] = x[i].node; Y[i] = y[i].node; } - DdNode *result = Cudd_addSwapVariables(mgr, node, X, Y, static_cast<int>(n)); + DdNode *result = Cudd_addSwapVariables(mgr, node, X, Y, (int) n); delete [] X; delete [] Y; checkReturnValue(result); @@ -3651,7 +3946,7 @@ BDD::SwapVariables( X[i] = x[i].node; Y[i] = y[i].node; } - DdNode *result = Cudd_bddSwapVariables(mgr, node, X, Y, static_cast<int>(n)); + DdNode *result = Cudd_bddSwapVariables(mgr, node, X, Y, (int) n); delete [] X; delete [] Y; checkReturnValue(result); @@ -3662,7 +3957,7 @@ BDD::SwapVariables( BDD BDD::AdjPermuteX( - vector<BDD> x) const + std::vector<BDD> x) const { size_t n = x.size(); DdManager *mgr = p->manager; @@ -3670,7 +3965,7 @@ BDD::AdjPermuteX( for (size_t i = 0; i < n; i++) { X[i] = x[i].node; } - DdNode *result = Cudd_bddAdjPermuteX(mgr, node, X, static_cast<int>(n)); + DdNode *result = Cudd_bddAdjPermuteX(mgr, node, X, (int) n); delete [] X; checkReturnValue(result); return BDD(p, result); @@ -3680,13 +3975,13 @@ BDD::AdjPermuteX( ADD ADD::VectorCompose( - vector<ADD> vector) const + std::vector<ADD> vect) const { DdManager *mgr = p->manager; - int n = Cudd_ReadSize(mgr); + size_t n = (size_t) Cudd_ReadSize(mgr); DdNode **X = new DdNode *[n]; - for (int i = 0; i < n; i++) { - X[i] = vector[i].node; + for (size_t i = 0; i < n; i++) { + X[i] = vect[i].node; } DdNode *result = Cudd_addVectorCompose(mgr, node, X); delete [] X; @@ -3698,13 +3993,13 @@ ADD::VectorCompose( ADD ADD::NonSimCompose( - vector<ADD> vector) const + std::vector<ADD> vect) const { DdManager *mgr = p->manager; - int n = Cudd_ReadSize(mgr); + size_t n = (size_t) Cudd_ReadSize(mgr); DdNode **X = new DdNode *[n]; - for (int i = 0; i < n; i++) { - X[i] = vector[i].node; + for (size_t i = 0; i < n; i++) { + X[i] = vect[i].node; } DdNode *result = Cudd_addNonSimCompose(mgr, node, X); delete [] X; @@ -3716,13 +4011,13 @@ ADD::NonSimCompose( BDD BDD::VectorCompose( - vector<BDD> vector) const + std::vector<BDD> vect) const { DdManager *mgr = p->manager; - int n = Cudd_ReadSize(mgr); + size_t n = (size_t) Cudd_ReadSize(mgr); DdNode **X = new DdNode *[n]; - for (int i = 0; i < n; i++) { - X[i] = vector[i].node; + for (size_t i = 0; i < n; i++) { + X[i] = vect[i].node; } DdNode *result = Cudd_bddVectorCompose(mgr, node, X); delete [] X; @@ -3880,7 +4175,7 @@ bool ABDD::IsCube() const { DdManager *mgr = p->manager; - return Cudd_CheckCube(mgr, node) != 0; + return Cudd_CheckCube(mgr, node); } // ABDD::IsCube @@ -3902,7 +4197,7 @@ BDD::IsVarEssential( int phase) const { DdManager *mgr = p->manager; - return Cudd_bddIsVarEssential(mgr, node, id, phase) != 0; + return Cudd_bddIsVarEssential(mgr, node, id, phase); } // BDD::IsVarEssential @@ -3921,9 +4216,9 @@ ABDD::PrintTwoLiteralClauses( void Cudd::DumpBlif( - const vector<BDD>& nodes, - char ** inames, - char ** onames, + const std::vector<BDD>& nodes, + char const * const * inames, + char const * const * onames, char * mname, FILE * fp, int mv) const @@ -3934,131 +4229,158 @@ Cudd::DumpBlif( for (size_t i = 0; i < n; i ++) { F[i] = nodes[i].getNode(); } - int result = Cudd_DumpBlif(mgr, static_cast<int>(n), F, inames, onames, mname, fp, mv); + int result = Cudd_DumpBlif(mgr, (int) n, F, inames, onames, mname, fp, mv); delete [] F; checkReturnValue(result); -} // vector<BDD>::DumpBlif +} // Cudd::DumpBlif void Cudd::DumpDot( - const vector<BDD>& nodes, - char ** inames, - char ** onames, + const std::vector<BDD>& nodes, + char const * const * inames, + char const * const * onames, FILE * fp) const { DdManager *mgr = p->manager; - int n = nodes.size(); + size_t n = nodes.size(); DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i ++) { + for (size_t i = 0; i < n; i ++) { F[i] = nodes[i].getNode(); } - int result = Cudd_DumpDot(mgr, n, F, inames, onames, fp); + int result = Cudd_DumpDot(mgr, (int) n, F, inames, onames, fp); delete [] F; checkReturnValue(result); -} // vector<BDD>::DumpDot +} // Cudd::DumpDot void Cudd::DumpDot( - const vector<ADD>& nodes, - char ** inames, - char ** onames, + const std::vector<ADD>& nodes, + char const * const * inames, + char const * const * onames, FILE * fp) const { DdManager *mgr = p->manager; - int n = nodes.size(); + size_t n = nodes.size(); DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i ++) { + for (size_t i = 0; i < n; i ++) { F[i] = nodes[i].getNode(); } - int result = Cudd_DumpDot(mgr, n, F, inames, onames, fp); + int result = Cudd_DumpDot(mgr, (int) n, F, inames, onames, fp); delete [] F; checkReturnValue(result); -} // vector<ADD>::DumpDot +} // Cudd::DumpDot void Cudd::DumpDaVinci( - const vector<BDD>& nodes, - char ** inames, - char ** onames, + const std::vector<BDD>& nodes, + char const * const * inames, + char const * const * onames, FILE * fp) const { DdManager *mgr = p->manager; - int n = nodes.size(); + size_t n = nodes.size(); DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i ++) { + for (size_t i = 0; i < n; i ++) { F[i] = nodes[i].getNode(); } - int result = Cudd_DumpDaVinci(mgr, n, F, inames, onames, fp); + int result = Cudd_DumpDaVinci(mgr, (int) n, F, inames, onames, fp); delete [] F; checkReturnValue(result); -} // vector<BDD>::DumpDaVinci +} // Cudd::DumpDaVinci void Cudd::DumpDaVinci( - const vector<ADD>& nodes, - char ** inames, - char ** onames, + const std::vector<ADD>& nodes, + char const * const * inames, + char const * const * onames, FILE * fp) const { DdManager *mgr = p->manager; - int n = nodes.size(); + size_t n = nodes.size(); DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i ++) { + for (size_t i = 0; i < n; i ++) { F[i] = nodes[i].getNode(); } - int result = Cudd_DumpDaVinci(mgr, n, F, inames, onames, fp); + int result = Cudd_DumpDaVinci(mgr, (int) n, F, inames, onames, fp); delete [] F; checkReturnValue(result); -} // vector<ADD>::DumpDaVinci +} // Cudd::DumpDaVinci void Cudd::DumpDDcal( - const vector<BDD>& nodes, - char ** inames, - char ** onames, + const std::vector<BDD>& nodes, + char const * const * inames, + char const * const * onames, FILE * fp) const { DdManager *mgr = p->manager; - int n = nodes.size(); + size_t n = nodes.size(); DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i ++) { + for (size_t i = 0; i < n; i ++) { F[i] = nodes[i].getNode(); } - int result = Cudd_DumpDDcal(mgr, n, F, inames, onames, fp); + int result = Cudd_DumpDDcal(mgr, (int) n, F, inames, onames, fp); delete [] F; checkReturnValue(result); -} // vector<BDD>::DumpDDcal +} // Cudd::DumpDDcal void Cudd::DumpFactoredForm( - const vector<BDD>& nodes, - char ** inames, - char ** onames, + const std::vector<BDD>& nodes, + char const * const * inames, + char const * const * onames, FILE * fp) const { DdManager *mgr = p->manager; - int n = nodes.size(); + size_t n = nodes.size(); DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i ++) { + for (size_t i = 0; i < n; i ++) { F[i] = nodes[i].getNode(); } - int result = Cudd_DumpFactoredForm(mgr, n, F, inames, onames, fp); + int result = Cudd_DumpFactoredForm(mgr, (int) n, F, inames, onames, fp); delete [] F; checkReturnValue(result); -} // vector<BDD>::DumpFactoredForm +} // Cudd::DumpFactoredForm + + +void +BDD::PrintFactoredForm( + char const * const * inames, + FILE * fp) const +{ + DdManager *mgr = p->manager; + DdNode *f = node; + int result = Cudd_DumpFactoredForm(mgr, 0, &f, inames, 0, fp); + checkReturnValue(result); + +} // BDD::PrintFactoredForm + + +string +BDD::FactoredFormString(char const * const * inames) const +{ + DdManager *mgr = p->manager; + DdNode *f = node; + char *cstr = Cudd_FactoredFormString(mgr, f, inames); + checkReturnValue(cstr); + string str(cstr); + free(cstr); + return str; + +} // BDD::FactoredFormString BDD @@ -4109,12 +4431,12 @@ ADD::Constrain( } // ADD::Constrain -vector<BDD> +std::vector<BDD> BDD::ConstrainDecomp() const { DdManager *mgr = p->manager; DdNode **result = Cudd_bddConstrainDecomp(mgr, node); - checkReturnValue((DdNode *)result); + checkReturnValue(result); int size = Cudd_ReadSize(mgr); vector<BDD> vect; for (int i = 0; i < size; i++) { @@ -4139,12 +4461,12 @@ ADD::Restrict( } // ADD::Restrict -vector<BDD> +std::vector<BDD> BDD::CharToVect() const { DdManager *mgr = p->manager; DdNode **result = Cudd_bddCharToVect(mgr, node); - checkReturnValue((DdNode *)result); + checkReturnValue(result); int size = Cudd_ReadSize(mgr); vector<BDD> vect; for (int i = 0; i < size; i++) { @@ -4181,6 +4503,18 @@ BDD::Squeeze( } // BDD::Squeeze +BDD +BDD::Interpolate( + const BDD& u) const +{ + DdManager *mgr = checkSameManager(u); + DdNode *result = Cudd_bddInterpolate(mgr, node, u.node); + checkReturnValue(result); + return BDD(p, result); + +} // BDD::Interpolate + + BDD BDD::Minimize( const BDD& c) const @@ -4230,36 +4564,82 @@ Cudd::MakeTreeNode( } // Cudd::MakeTreeNode -/* This is incorrect, but we'll wait for this one. -void +ADD Cudd::Harwell( FILE * fp, - DdManager * dd, - ADD* E, - ADD** x, - ADD** y, - ADD** xn, - ADD** yn_, - int * nx, - int * ny, + std::vector<ADD>& x, + std::vector<ADD>& y, + std::vector<ADD>& xn, + std::vector<ADD>& yn_, int * m, int * n, int bx, int sx, int by, int sy, - int pr) + int pr) const { DdManager *mgr = p->manager; - int result = Cudd_addHarwell(fp, mgr, E, x, y, xn, yn_, nx, ny, m, n, bx, sx, by, sy, pr); + DdNode *E; + DdNode **xa = 0, **ya = 0, **xna = 0, **yna = 0; + int nx = x.size(), ny = y.size(); + if (nx > 0) { + xa = (DdNode **) malloc(nx * sizeof(DdNode *)); + if (!xa) { + p->errorHandler("Out of memory."); + } + xna = (DdNode **) malloc(nx * sizeof(DdNode *)); + if (!xna) { + free(xa); + p->errorHandler("Out of memory."); + } + for (int i = 0; i < nx; ++i) { + xa[i] = x.at(i).node; + xna[i] = xn.at(i).node; + } + } + if (ny > 0) { + ya = (DdNode **) malloc(ny * sizeof(DdNode *)); + if (!ya) { + free(xa); + free(xna); + p->errorHandler("Out of memory."); + } + yna = (DdNode **) malloc(ny * sizeof(DdNode *)); + if (!yna) { + free(xa); + free(xna); + free(ya); + p->errorHandler("Out of memory."); + } + for (int j = 0; j < ny; ++j) { + ya[j] = y.at(j).node; + yna[j] = yn_.at(j).node; + } + } + int result = Cudd_addHarwell(fp, mgr, &E, &xa, &ya, &xna, &yna, &nx, &ny, + m, n, bx, sx, by, sy, pr); checkReturnValue(result); + for (int i = x.size(); i < nx; ++i) { + x.push_back(ADD(p, xa[i])); + xn.push_back(ADD(p, xna[i])); + } + free(xa); + free(xna); + for (int j = y.size(); j < ny; ++j) { + y.push_back(ADD(p, ya[j])); + yn_.push_back(ADD(p, yna[j])); + } + free(ya); + free(yna); + Cudd_Deref(E); + return ADD(p, E); } // Cudd::Harwell -*/ void -Cudd::PrintLinear() +Cudd::PrintLinear(void) const { cout.flush(); int result = Cudd_PrintLinear(p->manager); @@ -4271,7 +4651,7 @@ Cudd::PrintLinear() int Cudd::ReadLinear( int x, - int y) + int y) const { return Cudd_ReadLinear(p->manager, x, y); @@ -4293,15 +4673,15 @@ BDD::LiteralSetIntersection( ADD ADD::MatrixMultiply( const ADD& B, - vector<ADD> z) const + std::vector<ADD> z) const { - int nz = z.size(); + size_t nz = z.size(); DdManager *mgr = checkSameManager(B); DdNode **Z = new DdNode *[nz]; - for (int i = 0; i < nz; i++) { + for (size_t i = 0; i < nz; i++) { Z[i] = z[i].node; } - DdNode *result = Cudd_addMatrixMultiply(mgr, node, B.node, Z, nz); + DdNode *result = Cudd_addMatrixMultiply(mgr, node, B.node, Z, (int) nz); delete [] Z; checkReturnValue(result); return ADD(p, result); @@ -4312,15 +4692,15 @@ ADD::MatrixMultiply( ADD ADD::TimesPlus( const ADD& B, - vector<ADD> z) const + std::vector<ADD> z) const { - int nz = z.size(); + size_t nz = z.size(); DdManager *mgr = checkSameManager(B); DdNode **Z = new DdNode *[nz]; - for (int i = 0; i < nz; i++) { + for (size_t i = 0; i < nz; i++) { Z[i] = z[i].node; } - DdNode *result = Cudd_addTimesPlus(mgr, node, B.node, Z, nz); + DdNode *result = Cudd_addTimesPlus(mgr, node, B.node, Z, (int) nz); delete [] Z; checkReturnValue(result); return ADD(p, result); @@ -4331,15 +4711,15 @@ ADD::TimesPlus( ADD ADD::Triangle( const ADD& g, - vector<ADD> z) const + std::vector<ADD> z) const { - int nz = z.size(); + size_t nz = z.size(); DdManager *mgr = checkSameManager(g); DdNode **Z = new DdNode *[nz]; - for (int i = 0; i < nz; i++) { + for (size_t i = 0; i < nz; i++) { Z[i] = z[i].node; } - DdNode *result = Cudd_addTriangle(mgr, node, g.node, Z, nz); + DdNode *result = Cudd_addTriangle(mgr, node, g.node, Z, (int) nz); delete [] Z; checkReturnValue(result); return ADD(p, result); @@ -4349,23 +4729,24 @@ ADD::Triangle( BDD BDD::PrioritySelect( - vector<BDD> x, - vector<BDD> y, - vector<BDD> z, + std::vector<BDD> x, + std::vector<BDD> y, + std::vector<BDD> z, const BDD& Pi, DD_PRFP Pifunc) const { - int n = x.size(); + size_t n = x.size(); DdManager *mgr = p->manager; DdNode **X = new DdNode *[n]; DdNode **Y = new DdNode *[n]; DdNode **Z = new DdNode *[n]; - for (int i = 0; i < n; i++) { + for (size_t i = 0; i < n; i++) { X[i] = x[i].node; Y[i] = y[i].node; Z[i] = z[i].node; } - DdNode *result = Cudd_PrioritySelect(mgr, node, X, Y, Z, Pi.node, n, Pifunc); + DdNode *result = Cudd_PrioritySelect(mgr, node, X, Y, Z, Pi.node, + (int) n, Pifunc); delete [] X; delete [] Y; delete [] Z; @@ -4377,21 +4758,21 @@ BDD::PrioritySelect( BDD Cudd::Xgty( - vector<BDD> z, - vector<BDD> x, - vector<BDD> y) + std::vector<BDD> z, + std::vector<BDD> x, + std::vector<BDD> y) const { - int N = z.size(); + size_t N = z.size(); DdManager *mgr = p->manager; DdNode **X = new DdNode *[N]; DdNode **Y = new DdNode *[N]; DdNode **Z = new DdNode *[N]; - for (int i = 0; i < N; i++) { + for (size_t i = 0; i < N; i++) { X[i] = x[i].getNode(); Y[i] = y[i].getNode(); Z[i] = z[i].getNode(); } - DdNode *result = Cudd_Xgty(mgr, N, Z, X, Y); + DdNode *result = Cudd_Xgty(mgr, (int) N, Z, X, Y); delete [] X; delete [] Y; delete [] Z; @@ -4403,18 +4784,18 @@ Cudd::Xgty( BDD Cudd::Xeqy( - vector<BDD> x, - vector<BDD> y) + std::vector<BDD> x, + std::vector<BDD> y) const { - int N = x.size(); + size_t N = x.size(); DdManager *mgr = p->manager; DdNode **X = new DdNode *[N]; DdNode **Y = new DdNode *[N]; - for (int i = 0; i < N; i++) { + for (size_t i = 0; i < N; i++) { X[i] = x[i].getNode(); Y[i] = y[i].getNode(); } - DdNode *result = Cudd_Xeqy(mgr, N, X, Y); + DdNode *result = Cudd_Xeqy(mgr, (int) N, X, Y); delete [] X; delete [] Y; checkReturnValue(result); @@ -4425,18 +4806,18 @@ Cudd::Xeqy( ADD Cudd::Xeqy( - vector<ADD> x, - vector<ADD> y) + std::vector<ADD> x, + std::vector<ADD> y) const { - int N = x.size(); + size_t N = x.size(); DdManager *mgr = p->manager; DdNode **X = new DdNode *[N]; DdNode **Y = new DdNode *[N]; - for (int i = 0; i < N; i++) { + for (size_t i = 0; i < N; i++) { X[i] = x[i].getNode(); Y[i] = y[i].getNode(); } - DdNode *result = Cudd_addXeqy(mgr, N, X, X); + DdNode *result = Cudd_addXeqy(mgr, (int) N, X, X); delete [] X; delete [] Y; checkReturnValue(result); @@ -4447,21 +4828,21 @@ Cudd::Xeqy( BDD Cudd::Dxygtdxz( - vector<BDD> x, - vector<BDD> y, - vector<BDD> z) + std::vector<BDD> x, + std::vector<BDD> y, + std::vector<BDD> z) const { - int N = x.size(); + size_t N = x.size(); DdManager *mgr = p->manager; DdNode **X = new DdNode *[N]; DdNode **Y = new DdNode *[N]; DdNode **Z = new DdNode *[N]; - for (int i = 0; i < N; i++) { + for (size_t i = 0; i < N; i++) { X[i] = x[i].getNode(); Y[i] = y[i].getNode(); Z[i] = z[i].getNode(); } - DdNode *result = Cudd_Dxygtdxz(mgr, N, X, Y, Z); + DdNode *result = Cudd_Dxygtdxz(mgr, (int) N, X, Y, Z); delete [] X; delete [] Y; delete [] Z; @@ -4473,21 +4854,21 @@ Cudd::Dxygtdxz( BDD Cudd::Dxygtdyz( - vector<BDD> x, - vector<BDD> y, - vector<BDD> z) + std::vector<BDD> x, + std::vector<BDD> y, + std::vector<BDD> z) const { - int N = x.size(); + size_t N = x.size(); DdManager *mgr = p->manager; DdNode **X = new DdNode *[N]; DdNode **Y = new DdNode *[N]; DdNode **Z = new DdNode *[N]; - for (int i = 0; i < N; i++) { + for (size_t i = 0; i < N; i++) { X[i] = x[i].getNode(); Y[i] = y[i].getNode(); Z[i] = z[i].getNode(); } - DdNode *result = Cudd_Dxygtdyz(mgr, N, X, Y, Z); + DdNode *result = Cudd_Dxygtdyz(mgr, (int) N, X, Y, Z); delete [] X; delete [] Y; delete [] Z; @@ -4500,18 +4881,18 @@ Cudd::Dxygtdyz( BDD Cudd::Inequality( int c, - vector<BDD> x, - vector<BDD> y) + std::vector<BDD> x, + std::vector<BDD> y) const { - int N = x.size(); + size_t N = x.size(); DdManager *mgr = p->manager; DdNode **X = new DdNode *[N]; DdNode **Y = new DdNode *[N]; - for (int i = 0; i < N; i++) { + for (size_t i = 0; i < N; i++) { X[i] = x[i].getNode(); Y[i] = y[i].getNode(); } - DdNode *result = Cudd_Inequality(mgr, N, c, X, Y); + DdNode *result = Cudd_Inequality(mgr, (int) N, c, X, Y); delete [] X; delete [] Y; checkReturnValue(result); @@ -4523,18 +4904,18 @@ Cudd::Inequality( BDD Cudd::Disequality( int c, - vector<BDD> x, - vector<BDD> y) + std::vector<BDD> x, + std::vector<BDD> y) const { - int N = x.size(); + size_t N = x.size(); DdManager *mgr = p->manager; DdNode **X = new DdNode *[N]; DdNode **Y = new DdNode *[N]; - for (int i = 0; i < N; i++) { + for (size_t i = 0; i < N; i++) { X[i] = x[i].getNode(); Y[i] = y[i].getNode(); } - DdNode *result = Cudd_Disequality(mgr, N, c, X, Y); + DdNode *result = Cudd_Disequality(mgr, (int) N, c, X, Y); delete [] X; delete [] Y; checkReturnValue(result); @@ -4545,17 +4926,17 @@ Cudd::Disequality( BDD Cudd::Interval( - vector<BDD> x, + std::vector<BDD> x, unsigned int lowerB, - unsigned int upperB) + unsigned int upperB) const { - int N = x.size(); + size_t N = x.size(); DdManager *mgr = p->manager; DdNode **X = new DdNode *[N]; - for (int i = 0; i < N; i++) { + for (size_t i = 0; i < N; i++) { X[i] = x[i].getNode(); } - DdNode *result = Cudd_bddInterval(mgr, N, X, lowerB, upperB); + DdNode *result = Cudd_bddInterval(mgr, (int) N, X, lowerB, upperB); delete [] X; checkReturnValue(result); return BDD(p, result); @@ -4589,18 +4970,18 @@ BDD::MinHammingDist( ADD Cudd::Hamming( - vector<ADD> xVars, - vector<ADD> yVars) + std::vector<ADD> xVars, + std::vector<ADD> yVars) const { - int nVars = xVars.size(); + size_t nVars = xVars.size(); DdManager *mgr = p->manager; DdNode **X = new DdNode *[nVars]; DdNode **Y = new DdNode *[nVars]; - for (int i = 0; i < nVars; i++) { + for (size_t i = 0; i < nVars; i++) { X[i] = xVars[i].getNode(); Y[i] = yVars[i].getNode(); } - DdNode *result = Cudd_addHamming(mgr, X, Y, nVars); + DdNode *result = Cudd_addHamming(mgr, X, Y, (int) nVars); delete [] X; delete [] Y; checkReturnValue(result); @@ -4609,58 +4990,135 @@ Cudd::Hamming( } // Cudd::Hamming -/* We'll leave these two out for the time being. -void +ADD Cudd::Read( FILE * fp, - ADD* E, - ADD** x, - ADD** y, - ADD** xn, - ADD** yn_, - int * nx, - int * ny, + std::vector<ADD>& x, + std::vector<ADD>& y, + std::vector<ADD>& xn, + std::vector<ADD>& yn_, int * m, int * n, int bx, int sx, int by, - int sy) + int sy) const { DdManager *mgr = p->manager; - int result = Cudd_addRead(fp, mgr, E, x, y, xn, yn_, nx, ny, m, n, bx, sx, by, sy); + DdNode *E; + DdNode **xa = 0, **ya = 0, **xna = 0, **yna = 0; + int nx = x.size(), ny = y.size(); + if (nx > 0) { + xa = (DdNode **) malloc(nx * sizeof(DdNode *)); + if (!xa) { + p->errorHandler("Out of memory."); + } + xna = (DdNode **) malloc(nx * sizeof(DdNode *)); + if (!xna) { + free(xa); + p->errorHandler("Out of memory."); + } + for (int i = 0; i < nx; ++i) { + xa[i] = x.at(i).node; + xna[i] = xn.at(i).node; + } + } + if (ny > 0) { + ya = (DdNode **) malloc(ny * sizeof(DdNode *)); + if (!ya) { + free(xa); + free(xna); + p->errorHandler("Out of memory."); + } + yna = (DdNode **) malloc(ny * sizeof(DdNode *)); + if (!yna) { + free(xa); + free(xna); + free(ya); + p->errorHandler("Out of memory."); + } + for (int j = 0; j < ny; ++j) { + ya[j] = y.at(j).node; + yna[j] = yn_.at(j).node; + } + } + int result = Cudd_addRead(fp, mgr, &E, &xa, &ya, &xna, &yna, &nx, &ny, + m, n, bx, sx, by, sy); checkReturnValue(result); + for (int i = x.size(); i < nx; ++i) { + x.push_back(ADD(p, xa[i])); + xn.push_back(ADD(p, xna[i])); + } + free(xa); + free(xna); + for (int j = y.size(); j < ny; ++j) { + y.push_back(ADD(p, ya[j])); + yn_.push_back(ADD(p, yna[j])); + } + free(ya); + free(yna); + Cudd_Deref(E); + return ADD(p, E); } // Cudd::Read -void +BDD Cudd::Read( FILE * fp, - BDD* E, - BDD** x, - BDD** y, - int * nx, - int * ny, + std::vector<BDD>& x, + std::vector<BDD>& y, int * m, int * n, int bx, int sx, int by, - int sy) + int sy) const { DdManager *mgr = p->manager; - int result = Cudd_bddRead(fp, mgr, E, x, y, nx, ny, m, n, bx, sx, by, sy); + DdNode *E; + DdNode **xa = 0, **ya = 0; + int nx = x.size(), ny = y.size(); + if (nx > 0) { + xa = (DdNode **) malloc(nx * sizeof(DdNode *)); + if (!xa) { + p->errorHandler("Out of memory."); + } + for (int i = 0; i < nx; ++i) { + xa[i] = x.at(i).node; + } + } + if (ny > 0) { + ya = (DdNode **) malloc(ny * sizeof(DdNode *)); + if (!ya) { + free(xa); + p->errorHandler("Out of memory."); + } + for (int j = 0; j < nx; ++j) { + ya[j] = y.at(j).node; + } + } + int result = Cudd_bddRead(fp, mgr, &E, &xa, &ya, &nx, &ny, + m, n, bx, sx, by, sy); checkReturnValue(result); + for (int i = x.size(); i < nx; ++i) { + x.push_back(BDD(p, xa[i])); + } + free(xa); + for (int j = y.size(); j < ny; ++j) { + y.push_back(BDD(p, ya[j])); + } + free(ya); + Cudd_Deref(E); + return BDD(p, E); } // Cudd::Read -*/ void Cudd::ReduceHeap( Cudd_ReorderingType heuristic, - int minsize) + int minsize) const { int result = Cudd_ReduceHeap(p->manager, heuristic, minsize); checkReturnValue(result); @@ -4670,7 +5128,7 @@ Cudd::ReduceHeap( void Cudd::ShuffleHeap( - int * permutation) + int * permutation) const { int result = Cudd_ShuffleHeap(p->manager, permutation); checkReturnValue(result); @@ -4771,7 +5229,7 @@ ABDD::EquivDC( { DdManager *mgr = checkSameManager(G); checkSameManager(D); - return Cudd_EquivDC(mgr, node, G.node, D.node) != 0; + return Cudd_EquivDC(mgr, node, G.node, D.node); } // ABDD::EquivDC @@ -4783,7 +5241,7 @@ BDD::LeqUnless( DdManager *mgr = checkSameManager(G); checkSameManager(D); int res = Cudd_bddLeqUnless(mgr, node, G.node, D.node); - return res != 0; + return res; } // BDD::LeqUnless @@ -4795,7 +5253,7 @@ ADD::EqualSupNorm( int pr) const { DdManager *mgr = checkSameManager(g); - return Cudd_EqualSupNorm(mgr, node, g.node, tolerance, pr) != 0; + return Cudd_EqualSupNorm(mgr, node, g.node, tolerance, pr); } // ADD::EqualSupNorm @@ -4807,7 +5265,7 @@ ADD::EqualSupNormRel( { DdManager *mgr = checkSameManager(g); return Cudd_EqualSupNormRel(mgr, node, g.node, tolerance, pr) != 0; - + } // ADD::EqualSupNormRel BDD @@ -4856,7 +5314,7 @@ ABDD::CofMinterm() const { DdManager *mgr = p->manager; double *result = Cudd_CofMinterm(mgr, node); - checkReturnValue((DdNode *)result); + checkReturnValue(result); return result; } // ABDD::CofMinterm @@ -4865,7 +5323,7 @@ ABDD::CofMinterm() const BDD BDD::SolveEqn( const BDD& Y, - BDD* G, + std::vector<BDD> & G, int ** yIndex, int n) const { @@ -4874,7 +5332,7 @@ BDD::SolveEqn( DdNode *result = Cudd_SolveEqn(mgr, node, Y.node, g, yIndex, n); checkReturnValue(result); for (int i = 0; i < n; i++) { - G[i] = BDD(p, g[i]); + G.push_back(BDD(p, g[i])); Cudd_RecursiveDeref(mgr,g[i]); } delete [] g; @@ -4885,16 +5343,16 @@ BDD::SolveEqn( BDD BDD::VerifySol( - BDD* G, - int * yIndex, - int n) const + std::vector<BDD> const & G, + int * yIndex) const { + size_t n = G.size(); DdManager *mgr = p->manager; DdNode **g = new DdNode *[n]; - for (int i = 0; i < n; i++) { + for (size_t i = 0; i < n; i++) { g[i] = G[i].node; } - DdNode *result = Cudd_VerifySol(mgr, node, g, yIndex, n); + DdNode *result = Cudd_VerifySol(mgr, node, g, yIndex, (int) n); delete [] g; checkReturnValue(result); return BDD(p, result); @@ -4904,16 +5362,16 @@ BDD::VerifySol( BDD BDD::SplitSet( - vector<BDD> xVars, + std::vector<BDD> xVars, double m) const { - int n = xVars.size(); + size_t n = xVars.size(); DdManager *mgr = p->manager; DdNode **X = new DdNode *[n]; - for (int i = 0; i < n; i++) { + for (size_t i = 0; i < n; i++) { X[i] = xVars[i].node; } - DdNode *result = Cudd_SplitSet(mgr, node, X, n, m); + DdNode *result = Cudd_SplitSet(mgr, node, X, (int) n, m); delete [] X; checkReturnValue(result); return BDD(p, result); @@ -5081,14 +5539,14 @@ Cudd::SharingSize( int Cudd::SharingSize( - const vector<BDD>& v) const + const std::vector<BDD>& v) const { vector<BDD>::size_type n = v.size(); DdNode **nodeArray = new DdNode *[n]; for (vector<BDD>::size_type i = 0; i != n; ++i) { nodeArray[i] = v[i].getNode(); } - int result = Cudd_SharingSize(nodeArray, static_cast<int>(n)); + int result = Cudd_SharingSize(nodeArray, (int) n); delete [] nodeArray; checkReturnValue(n == 0 || result > 0); return result; @@ -5141,15 +5599,15 @@ ABDD::SupportSize() const BDD -Cudd::VectorSupport(const vector<BDD>& roots) const +Cudd::VectorSupport(const std::vector<BDD>& roots) const { - int n = roots.size(); + size_t n = roots.size(); DdManager *mgr = p->manager; DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i++) { + for (size_t i = 0; i < n; i++) { F[i] = roots[i].getNode(); } - DdNode *result = Cudd_VectorSupport(mgr, F, n); + DdNode *result = Cudd_VectorSupport(mgr, F, (int) n); delete [] F; checkReturnValue(result); return BDD(p, result); @@ -5157,7 +5615,7 @@ Cudd::VectorSupport(const vector<BDD>& roots) const } // Cudd::VectorSupport -vector<unsigned int> +std::vector<unsigned int> ABDD::SupportIndices() const { unsigned int *support; @@ -5172,17 +5630,38 @@ ABDD::SupportIndices() const } // ABDD::SupportIndices -vector<unsigned int> -Cudd::SupportIndices(const vector<ABDD>& roots) const +std::vector<unsigned int> +Cudd::SupportIndices(const std::vector<BDD>& roots) const { unsigned int *support; - int n = roots.size(); + size_t n = roots.size(); DdManager *mgr = p->manager; DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i++) { + for (size_t i = 0; i < n; i++) { + F[i] = roots[i].getNode(); + } + int size = Cudd_VectorSupportIndices(mgr, F, (int) n, (int **)&support); + delete [] F; + checkReturnValue(size >= 0); + // size could be 0, in which case support is 0 too! + vector<unsigned int> indices(support, support+size); + if (support) free(support); + return indices; + +} // Cudd::SupportIndices + + +std::vector<unsigned int> +Cudd::SupportIndices(const std::vector<ADD>& roots) const +{ + unsigned int *support; + size_t n = roots.size(); + DdManager *mgr = p->manager; + DdNode **F = new DdNode *[n]; + for (size_t i = 0; i < n; i++) { F[i] = roots[i].getNode(); } - int size = Cudd_VectorSupportIndices(mgr, F, n, (int **)&support); + int size = Cudd_VectorSupportIndices(mgr, F, (int) n, (int **)&support); delete [] F; checkReturnValue(size >= 0); // size could be 0, in which case support is 0 too! @@ -5194,70 +5673,70 @@ Cudd::SupportIndices(const vector<ABDD>& roots) const int -Cudd::nodeCount(const vector<BDD>& roots) const +Cudd::nodeCount(const std::vector<BDD>& roots) const { - int n = roots.size(); + size_t n = roots.size(); DdNode **nodeArray = new DdNode *[n]; - for (int i = 0; i < n; i++) { + for (size_t i = 0; i < n; i++) { nodeArray[i] = roots[i].getNode(); } - int result = Cudd_SharingSize(nodeArray, n); + int result = Cudd_SharingSize(nodeArray, (int) n); delete [] nodeArray; checkReturnValue(result > 0); return result; -} // vector<BDD>::nodeCount +} // Cudd::nodeCount BDD -Cudd::VectorSupport(const vector<ADD>& roots) const +Cudd::VectorSupport(const std::vector<ADD>& roots) const { - int n = roots.size(); + size_t n = roots.size(); DdManager *mgr = p->manager; DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i++) { + for (size_t i = 0; i < n; i++) { F[i] = roots[i].getNode(); } - DdNode *result = Cudd_VectorSupport(mgr, F, n); + DdNode *result = Cudd_VectorSupport(mgr, F, (int) n); delete [] F; checkReturnValue(result); return BDD(p, result); -} // vector<ADD>::VectorSupport +} // Cudd::VectorSupport int -Cudd::VectorSupportSize(const vector<BDD>& roots) const +Cudd::VectorSupportSize(const std::vector<BDD>& roots) const { - int n = roots.size(); + size_t n = roots.size(); DdManager *mgr = p->manager; DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i++) { + for (size_t i = 0; i < n; i++) { F[i] = roots[i].getNode(); } - int result = Cudd_VectorSupportSize(mgr, F, n); + int result = Cudd_VectorSupportSize(mgr, F, (int) n); delete [] F; checkReturnValue(result != CUDD_OUT_OF_MEM); return result; -} // vector<BDD>::VectorSupportSize +} // Cudd::VectorSupportSize int -Cudd::VectorSupportSize(const vector<ADD>& roots) const +Cudd::VectorSupportSize(const std::vector<ADD>& roots) const { - int n = roots.size(); + size_t n = roots.size(); DdManager *mgr = p->manager; DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i++) { + for (size_t i = 0; i < n; i++) { F[i] = roots[i].getNode(); } - int result = Cudd_VectorSupportSize(mgr, F, n); + int result = Cudd_VectorSupportSize(mgr, F, (int) n); delete [] F; checkReturnValue(result != CUDD_OUT_OF_MEM); return result; -} // vector<ADD>::VectorSupportSize +} // Cudd::VectorSupportSize void @@ -5285,6 +5764,28 @@ ABDD::CountLeaves() const } // ABDD::CountLeaves +DdGen * +ABDD::FirstCube( + int ** cube, + CUDD_VALUE_TYPE * value) const +{ + DdManager *mgr = p->manager; + DdGen *result = Cudd_FirstCube(mgr, node, cube, value); + checkReturnValue((DdNode *)result); + return result; + +} // ABDD::FirstCube + + +int +ABDD::NextCube( + DdGen * gen, + int ** cube, + CUDD_VALUE_TYPE * value) +{ + return Cudd_NextCube(gen, cube, value); + +} // ABDD::NextCube void BDD::PickOneCube( @@ -5299,15 +5800,15 @@ BDD::PickOneCube( BDD BDD::PickOneMinterm( - vector<BDD> vars) const + std::vector<BDD> vars) const { - int n = vars.size(); + size_t n = vars.size(); DdManager *mgr = p->manager; DdNode **V = new DdNode *[n]; - for (int i = 0; i < n; i++) { + for (size_t i = 0; i < n; i++) { V[i] = vars[i].node; } - DdNode *result = Cudd_bddPickOneMinterm(mgr, node, V, n); + DdNode *result = Cudd_bddPickOneMinterm(mgr, node, V, (int) n); delete [] V; checkReturnValue(result); return BDD(p, result); @@ -5315,30 +5816,6 @@ BDD::PickOneMinterm( } // BDD::PickOneMinterm -DdGen * -ABDD::FirstCube( - int ** cube, - CUDD_VALUE_TYPE * value) const -{ - DdManager *mgr = p->manager; - DdGen *result = Cudd_FirstCube(mgr, node, cube, value); - checkReturnValue((DdNode *)result); - return result; - -} // ABDD::FirstCube - - -int -ABDD::NextCube( - DdGen * gen, - int ** cube, - CUDD_VALUE_TYPE * value) -{ - return Cudd_NextCube(gen, cube, value); - -} // ABDD::NextCube - - BDD Cudd::bddComputeCube( BDD * vars, @@ -5358,11 +5835,29 @@ Cudd::bddComputeCube( } // Cudd::bddComputeCube +BDD +Cudd::computeCube( + std::vector<BDD> const & vars) const +{ + DdManager *mgr = p->manager; + size_t n = vars.size(); + DdNode **V = new DdNode *[n]; + for (size_t i = 0; i < n; i++) { + V[i] = vars[i].getNode(); + } + DdNode *result = Cudd_bddComputeCube(mgr, V, 0, n); + delete [] V; + checkReturnValue(result); + return BDD(p, result); + +} // Cudd::computeCube + + ADD Cudd::addComputeCube( ADD * vars, int * phase, - int n) + int n) const { DdManager *mgr = p->manager; DdNode **V = new DdNode *[n]; @@ -5377,55 +5872,28 @@ Cudd::addComputeCube( } // Cudd::addComputeCube -DdGen * -BDD::FirstNode( - BDD* fnode) const +ADD +Cudd::computeCube( + std::vector<ADD> const & vars) const { DdManager *mgr = p->manager; - DdNode *Fn; - DdGen *result = Cudd_FirstNode(mgr, node, &Fn); - checkReturnValue((DdNode *)result); - *fnode = BDD(p, Fn); - return result; - -} // DD::FirstNode - - -int -Cudd::NextNode( - DdGen * gen, - BDD * nnode) -{ - DdNode *nn; - int result = Cudd_NextNode(gen, &nn); - *nnode = BDD(p, nn); - return result; - -} // Cudd::NextNode - - -int -GenFree( - DdGen * gen) -{ - return Cudd_GenFree(gen); - -} // GenFree - - -int -IsGenEmpty( - DdGen * gen) -{ - return Cudd_IsGenEmpty(gen); + size_t n = vars.size(); + DdNode **V = new DdNode *[n]; + for (size_t i = 0; i < n; i++) { + V[i] = vars[i].getNode(); + } + DdNode *result = Cudd_addComputeCube(mgr, V, 0, n); + delete [] V; + checkReturnValue(result); + return ADD(p, result); -} // IsGenEmpty +} // Cudd::computeCube BDD Cudd::IndicesToCube( int * array, - int n) + int n) const { DdNode *result = Cudd_IndicesToCube(p->manager, array, n); checkReturnValue(result); @@ -5452,19 +5920,19 @@ Cudd::AverageDistance() const } // Cudd::AverageDistance -long +int32_t Cudd::Random() const { - return Cudd_Random(); + return Cudd_Random(p->manager); } // Cudd::Random void Cudd::Srandom( - long seed) const + int32_t seed) const { - Cudd_Srandom(seed); + Cudd_Srandom(p->manager,seed); } // Cudd::Srandom @@ -5579,7 +6047,7 @@ MtrNode * Cudd::MakeZddTreeNode( unsigned int low, unsigned int size, - unsigned int type) + unsigned int type) const { return Cudd_MakeZddTreeNode(p->manager, low, size, type); @@ -5659,7 +6127,7 @@ ZDD::PortToBdd() const void Cudd::zddReduceHeap( Cudd_ReorderingType heuristic, - int minsize) + int minsize) const { int result = Cudd_zddReduceHeap(p->manager, heuristic, minsize); checkReturnValue(result); @@ -5669,7 +6137,7 @@ Cudd::zddReduceHeap( void Cudd::zddShuffleHeap( - int * permutation) + int * permutation) const { int result = Cudd_zddShuffleHeap(p->manager, permutation); checkReturnValue(result); @@ -5820,21 +6288,44 @@ ZDD::Support() const void Cudd::DumpDot( - const vector<ZDD>& nodes, - char ** inames, - char ** onames, + const std::vector<ZDD>& nodes, + char const * const * inames, + char const * const * onames, FILE * fp) const { DdManager *mgr = p->manager; - int n = nodes.size(); + size_t n = nodes.size(); DdNode **F = new DdNode *[n]; - for (int i = 0; i < n; i++) { + for (size_t i = 0; i < n; i++) { F[i] = nodes[i].getNode(); } - int result = Cudd_zddDumpDot(mgr, n, F, inames, onames, fp); + int result = Cudd_zddDumpDot(mgr, (int) n, F, inames, onames, fp); delete [] F; checkReturnValue(result); } // vector<ZDD>::DumpDot + + +std::string +Cudd::OrderString(void) const +{ + DdManager * mgr = p->manager; + int nvars = Cudd_ReadSize(mgr); + bool hasNames = p->varnames.size() == (size_t) nvars; + std::ostringstream oss; + std::string separ = ""; + for (int level = 0; level != nvars; ++level) { + oss << separ; + separ = " "; + int index = Cudd_ReadInvPerm(mgr, level); + if (hasNames) { + oss << p->varnames.at(index); + } else { + oss << "x" << index; + } + } + return oss.str(); + +} // Cudd::OrderString -} // end namespace cudd +} // end namespace storm diff --git a/resources/3rdparty/cudd-2.5.0/src/obj/cuddObj.hh b/resources/3rdparty/cudd-3.0.0/cplusplus/cuddObj.hh similarity index 66% rename from resources/3rdparty/cudd-2.5.0/src/obj/cuddObj.hh rename to resources/3rdparty/cudd-3.0.0/cplusplus/cuddObj.hh index 9302688b9..f180320bd 100644 --- a/resources/3rdparty/cudd-2.5.0/src/obj/cuddObj.hh +++ b/resources/3rdparty/cudd-3.0.0/cplusplus/cuddObj.hh @@ -1,20 +1,15 @@ -/**CHeaderFile*************************************************************** +/** + @file - FileName [cuddObj.hh] + @ingroup cplusplus - PackageName [cudd] + @brief Class definitions for C++ object-oriented encapsulation of + CUDD. - Synopsis [Class definitions for C++ object-oriented encapsulation of - CUDD.] + @author Fabio Somenzi - Description [Class definitions for C++ object-oriented encapsulation of - CUDD.] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -44,24 +39,13 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock - Revision [$Id: cuddObj.hh,v 1.13 2012/02/05 01:06:40 fabio Exp fabio $] +*/ -******************************************************************************/ - -#ifndef _CPPCUDD -#define _CPPCUDD - -#if defined (__GNUC__) -#if (__GNUC__ >2 || __GNUC_MINOR__ >=7) && !defined(UNUSED) -#define UNUSED __attribute__ ((unused)) -#else -#define UNUSED -#endif -#else -#define UNUSED -#endif +#ifndef CUDD_OBJ_H_ +#define CUDD_OBJ_H_ /*---------------------------------------------------------------------------*/ /* Nested includes */ @@ -70,6 +54,7 @@ #include <cstdio> #include <string> #include <vector> +#include "mtr.h" #include "cudd.h" namespace cudd { @@ -88,60 +73,33 @@ typedef void (*PFC)(std::string); // handler function type /* Class definitions */ /*---------------------------------------------------------------------------*/ -/**Class*********************************************************************** - - Synopsis [Class for reference counting of CUDD managers.] - - Description [] - - SeeAlso [Cudd DD ABDD ADD BDD ZDD] - -******************************************************************************/ -class Capsule { - friend class DD; - friend class ABDD; - friend class BDD; - friend class ADD; - friend class ZDD; - friend class Cudd; -private: - DdManager *manager; - PFC errorHandler; - PFC timeoutHandler; - bool verbose; - int ref; -}; - - -/**Class*********************************************************************** +class Capsule; - Synopsis [Base class for all decision diagrams in CUDD.] - Description [] +/** + @brief Base class for all decision diagrams in CUDD. - SeeAlso [Cudd ABDD ADD BDD ZDD] + @see Cudd ABDD ADD BDD ZDD -******************************************************************************/ +*/ class DD { - friend class ABDD; - friend class BDD; - friend class ADD; - friend class ZDD; -private: +protected: Capsule *p; DdNode *node; inline DdManager * checkSameManager(const DD &other) const; - inline void checkReturnValue(const DdNode *result) const; - inline void checkReturnValue(const int result, const int expected = 1) + inline void checkReturnValue(const void *result) const; + inline void checkReturnValue(int result, int expected = 1) const; -public: DD(); DD(Capsule *cap, DdNode *ddNode); DD(Cudd const & manager, DdNode *ddNode); DD(const DD &from); - virtual ~DD(); - operator bool() const { return node != 0; } - DdManager *manager() const; + ~DD(); +public: + // This operator should be declared explicit, but there are still too many + // compilers out there that do not support this C++11 feature. + operator bool() const { return node; } + DdManager * manager() const; DdNode * getNode() const; DdNode * getRegularNode() const; int nodeCount() const; @@ -150,38 +108,37 @@ public: }; // DD -/**Class*********************************************************************** - - Synopsis [Class for ADDs and BDDs.] +/** + @brief Class for ADDs and BDDs. - Description [] + @see Cudd ADD BDD - SeeAlso [Cudd ADD BDD] - -******************************************************************************/ +*/ class ABDD : public DD { - friend class BDD; - friend class ADD; friend class Cudd; -public: +protected: ABDD(); ABDD(Capsule *cap, DdNode *bddNode); ABDD(Cudd const & manager, DdNode *ddNode); ABDD(const ABDD &from); - virtual ~ABDD(); + ~ABDD(); +public: bool operator==(const ABDD &other) const; bool operator!=(const ABDD &other) const; void print(int nvars, int verbosity = 1) const; + void summary(int nvars, int mode = 0) const; DdApaNumber ApaCountMinterm(int nvars, int * digits) const; void ApaPrintMinterm(int nvars, FILE * fp = stdout) const; + void ApaPrintMintermExp(int nvars, int precision = 6, FILE * fp = stdout) const; void EpdPrintMinterm(int nvars, FILE * fp = stdout) const; + long double LdblCountMinterm(int nvars) const; bool IsOne() const; bool IsCube() const; BDD FindEssential() const; - void PrintTwoLiteralClauses(char ** names, FILE * fp = stdout) const; + void PrintTwoLiteralClauses(char ** names = 0, FILE * fp = stdout) const; BDD ShortestPath(int * weight, int * support, int * length) const; BDD LargestCube(int * length = 0) const; - int ShortestLength(int * weight) const; + int ShortestLength(int * weight = 0) const; bool EquivDC(const ABDD& G, const ABDD& D) const; double * CofMinterm() const; void PrintMinterm() const; @@ -200,15 +157,12 @@ public: }; // ABDD -/**Class*********************************************************************** +/** + @brief Class for BDDs. - Synopsis [Class for BDDs.] + @see Cudd - Description [] - - SeeAlso [Cudd] - -******************************************************************************/ +*/ class BDD : public ABDD { friend class Cudd; public: @@ -235,7 +189,9 @@ public: BDD operator^=(const BDD& other); BDD operator-(const BDD& other) const; BDD operator-=(const BDD& other); + friend std::ostream & operator<<(std::ostream & os, BDD const & f); bool IsZero() const; + bool IsVar() const; BDD AndAbstract(const BDD& g, const BDD& cube, unsigned int limit = 0) const; BDD UnderApprox( @@ -275,10 +231,11 @@ public: bool Leq(const BDD& g) const; ADD Add() const; BDD Transfer(Cudd& destination) const; - BDD ClippingAnd(const BDD& g, int maxDepth, int direction) const; + BDD ClippingAnd(const BDD& g, int maxDepth, int direction = 0) const; BDD ClippingAndAbstract(const BDD& g, const BDD& cube, int maxDepth, - int direction) const; + int direction = 0) const; BDD Cofactor(const BDD& g) const; + bool VarAreSymmetric(int index1, int index2) const; BDD Compose(const BDD& g, int v) const; BDD Permute(int * permut) const; BDD SwapVariables(std::vector<BDD> x, std::vector<BDD> y) const; @@ -300,6 +257,7 @@ public: std::vector<BDD> CharToVect() const; BDD LICompaction(const BDD& c) const; BDD Squeeze(const BDD& u) const; + BDD Interpolate(const BDD& u) const; BDD Minimize(const BDD& c) const; BDD SubsetCompress(int nvars, int threshold) const; BDD SupersetCompress(int nvars, int threshold) const; @@ -315,8 +273,8 @@ public: BDD MakePrime(const BDD& F) const; BDD MaximallyExpand(const BDD& ub, const BDD& f); BDD LargestPrimeUnate(const BDD& phases); - BDD SolveEqn(const BDD& Y, BDD* G, int ** yIndex, int n) const; - BDD VerifySol(BDD* G, int * yIndex, int n) const; + BDD SolveEqn(const BDD& Y, std::vector<BDD> & G, int ** yIndex, int n) const; + BDD VerifySol(std::vector<BDD> const & G, int * yIndex) const; BDD SplitSet(std::vector<BDD> xVars, double m) const; BDD SubsetHeavyBranch(int numVars, int threshold) const; BDD SupersetHeavyBranch(int numVars, int threshold) const; @@ -328,23 +286,21 @@ public: int EstimateCofactorSimple(int i) const; void PickOneCube(char * string) const; BDD PickOneMinterm(std::vector<BDD> vars) const; - DdGen * FirstNode(BDD* fnode) const; BDD zddIsop(const BDD& U, ZDD* zdd_I) const; BDD Isop(const BDD& U) const; ZDD PortToZdd() const; + void PrintFactoredForm(char const * const * inames = 0, FILE * fp = stdout) const; + std::string FactoredFormString(char const * const * inames = 0) const; }; // BDD -/**Class*********************************************************************** - - Synopsis [Class for ADDs.] +/** + @brief Class for ADDs. - Description [] + @see Cudd - SeeAlso [Cudd] - -******************************************************************************/ +*/ class ADD : public ABDD { friend class Cudd; public: @@ -439,15 +395,12 @@ public: }; // ADD -/**Class*********************************************************************** - - Synopsis [Class for ZDDs.] - - Description [] +/** + @brief Class for ZDDs. - SeeAlso [Cudd] + @see Cudd -******************************************************************************/ +*/ class ZDD : public DD { friend class Cudd; public: @@ -498,21 +451,25 @@ public: }; // ZDD -/**Class*********************************************************************** +/** + @brief Default error handler. +*/ +extern void defaultError(std::string message); - Synopsis [Class for CUDD managers.] - Description [] +/** + @brief Class for CUDD managers. - SeeAlso [DD] + @see DD -******************************************************************************/ +*/ class Cudd { friend class DD; friend class ABDD; friend class BDD; friend class ADD; friend class ZDD; + friend std::ostream & operator<<(std::ostream & os, BDD const & f); private: Capsule *p; public: @@ -521,152 +478,170 @@ public: unsigned int numVarsZ = 0, unsigned int numSlots = CUDD_UNIQUE_SLOTS, unsigned int cacheSize = CUDD_CACHE_SLOTS, - unsigned long maxMemory = 0); + unsigned long maxMemory = 0, + PFC defaultHandler = defaultError); Cudd(const Cudd& x); - ~Cudd(); + ~Cudd(void); PFC setHandler(PFC newHandler) const; - PFC getHandler() const; + PFC getHandler(void) const; PFC setTimeoutHandler(PFC newHandler) const; - PFC getTimeoutHandler() const; - DdManager *getManager() const {return p->manager;} - inline void makeVerbose() const {p->verbose = 1;} - inline void makeTerse() {p->verbose = 0;} - inline bool isVerbose() const {return p->verbose;} - inline void checkReturnValue(const DdNode *result) const; - inline void checkReturnValue(const int result) const; + PFC getTimeoutHandler(void) const; + PFC setTerminationHandler(PFC newHandler) const; + PFC getTerminationHandler(void) const; + void pushVariableName(std::string s) const; + void clearVariableNames(void) const; + std::string getVariableName(size_t i) const; + DdManager *getManager(void) const; + void makeVerbose(void) const; + void makeTerse(void) const; + bool isVerbose(void) const; + void checkReturnValue(const void *result) const; + void checkReturnValue(const int result) const; Cudd& operator=(const Cudd& right); - void info() const; - BDD bddVar() const; + void info(void) const; + BDD bddVar(void) const; BDD bddVar(int index) const; - BDD bddOne() const; - BDD bddZero() const; - ADD addVar() const; + BDD bddOne(void) const; + BDD bddZero(void) const; + ADD addVar(void) const; ADD addVar(int index) const; - ADD addOne() const; - ADD addZero() const; + ADD addOne(void) const; + ADD addZero(void) const; ADD constant(CUDD_VALUE_TYPE c) const; - ADD plusInfinity() const; - ADD minusInfinity() const; + ADD plusInfinity(void) const; + ADD minusInfinity(void) const; ZDD zddVar(int index) const; ZDD zddOne(int i) const; - ZDD zddZero() const; + ZDD zddZero(void) const; ADD addNewVarAtLevel(int level) const; BDD bddNewVarAtLevel(int level) const; void zddVarsFromBddVars(int multiplicity) const; - unsigned long ReadStartTime() const; - unsigned long ReadElapsedTime() const; + unsigned long ReadStartTime(void) const; + unsigned long ReadElapsedTime(void) const; void SetStartTime(unsigned long st) const; - void ResetStartTime() const; - unsigned long ReadTimeLimit() const; - void SetTimeLimit(unsigned long tl) const; - void UpdateTimeLimit() const; + void ResetStartTime(void) const; + unsigned long ReadTimeLimit(void) const; + unsigned long SetTimeLimit(unsigned long tl) const; + void UpdateTimeLimit(void) const; void IncreaseTimeLimit(unsigned long increase) const; - void UnsetTimeLimit() const; - bool TimeLimited() const; - void AutodynEnable(Cudd_ReorderingType method) const; - void AutodynDisable() const; + void UnsetTimeLimit(void) const; + bool TimeLimited(void) const; + void RegisterTerminationCallback(DD_THFP callback, + void * callback_arg) const; + void UnregisterTerminationCallback(void) const; + DD_OOMFP RegisterOutOfMemoryCallback(DD_OOMFP callback) const; + void UnregisterOutOfMemoryCallback(void) const; + void AutodynEnable(Cudd_ReorderingType method = CUDD_REORDER_SIFT) const; + void AutodynDisable(void) const; bool ReorderingStatus(Cudd_ReorderingType * method) const; - void AutodynEnableZdd(Cudd_ReorderingType method) const; - void AutodynDisableZdd() const; + void AutodynEnableZdd(Cudd_ReorderingType method = CUDD_REORDER_SIFT) const; + void AutodynDisableZdd(void) const; bool ReorderingStatusZdd(Cudd_ReorderingType * method) const; - bool zddRealignmentEnabled() const; - void zddRealignEnable() const; - void zddRealignDisable() const; - bool bddRealignmentEnabled() const; - void bddRealignEnable() const; - void bddRealignDisable() const; - ADD background() const; + bool zddRealignmentEnabled(void) const; + void zddRealignEnable(void) const; + void zddRealignDisable(void) const; + bool bddRealignmentEnabled(void) const; + void bddRealignEnable(void) const; + void bddRealignDisable(void) const; + ADD background(void) const; void SetBackground(ADD bg) const; - unsigned int ReadCacheSlots() const; - double ReadCacheUsedSlots() const; - double ReadCacheLookUps() const; - double ReadCacheHits() const; - unsigned int ReadMinHit() const; + unsigned int ReadCacheSlots(void) const; + double ReadCacheUsedSlots(void) const; + double ReadCacheLookUps(void) const; + double ReadCacheHits(void) const; + unsigned int ReadMinHit(void) const; void SetMinHit(unsigned int hr) const; - unsigned int ReadLooseUpTo() const; + unsigned int ReadLooseUpTo(void) const; void SetLooseUpTo(unsigned int lut) const; - unsigned int ReadMaxCache() const; - unsigned int ReadMaxCacheHard() const; + unsigned int ReadMaxCache(void) const; + unsigned int ReadMaxCacheHard(void) const; void SetMaxCacheHard(unsigned int mc) const; - int ReadSize() const; - int ReadZddSize() const; - unsigned int ReadSlots() const; - unsigned int ReadKeys() const; - unsigned int ReadDead() const; - unsigned int ReadMinDead() const; - unsigned int ReadReorderings() const; - unsigned int ReadMaxReorderings() const; + int ReadSize(void) const; + int ReadZddSize(void) const; + unsigned int ReadSlots(void) const; + unsigned int ReadKeys(void) const; + unsigned int ReadDead(void) const; + unsigned int ReadMinDead(void) const; + unsigned int ReadReorderings(void) const; + unsigned int ReadMaxReorderings(void) const; void SetMaxReorderings(unsigned int mr) const; - long ReadReorderingTime() const; - int ReadGarbageCollections() const; - long ReadGarbageCollectionTime() const; - int ReadSiftMaxVar() const; + long ReadReorderingTime(void) const; + int ReadGarbageCollections(void) const; + long ReadGarbageCollectionTime(void) const; + int ReadSiftMaxVar(void) const; void SetSiftMaxVar(int smv) const; - int ReadSiftMaxSwap() const; + int ReadSiftMaxSwap(void) const; void SetSiftMaxSwap(int sms) const; - double ReadMaxGrowth() const; + double ReadMaxGrowth(void) const; void SetMaxGrowth(double mg) const; - MtrNode * ReadTree() const; +#ifdef MTR_H_ + MtrNode * ReadTree(void) const; void SetTree(MtrNode * tree) const; - void FreeTree() const; - MtrNode * ReadZddTree() const; + void FreeTree(void) const; + MtrNode * ReadZddTree(void) const; void SetZddTree(MtrNode * tree) const; - void FreeZddTree() const; + void FreeZddTree(void) const; + MtrNode * MakeTreeNode(unsigned int low, unsigned int size, + unsigned int type) const; + MtrNode * MakeZddTreeNode(unsigned int low, unsigned int size, + unsigned int type) const; +#endif int ReadPerm(int i) const; int ReadPermZdd(int i) const; int ReadInvPerm(int i) const; int ReadInvPermZdd(int i) const; BDD ReadVars(int i) const; - CUDD_VALUE_TYPE ReadEpsilon() const; + CUDD_VALUE_TYPE ReadEpsilon(void) const; void SetEpsilon(CUDD_VALUE_TYPE ep) const; - Cudd_AggregationType ReadGroupcheck() const; + Cudd_AggregationType ReadGroupcheck(void) const; void SetGroupcheck(Cudd_AggregationType gc) const; - bool GarbageCollectionEnabled() const; - void EnableGarbageCollection() const; - void DisableGarbageCollection() const; - bool DeadAreCounted() const; - void TurnOnCountDead() const; - void TurnOffCountDead() const; - int ReadRecomb() const; + bool GarbageCollectionEnabled(void) const; + void EnableGarbageCollection(void) const; + void DisableGarbageCollection(void) const; + bool DeadAreCounted(void) const; + void TurnOnCountDead(void) const; + void TurnOffCountDead(void) const; + int ReadRecomb(void) const; void SetRecomb(int recomb) const; - int ReadSymmviolation() const; + int ReadSymmviolation(void) const; void SetSymmviolation(int symmviolation) const; - int ReadArcviolation() const; + int ReadArcviolation(void) const; void SetArcviolation(int arcviolation) const; - int ReadPopulationSize() const; + int ReadPopulationSize(void) const; void SetPopulationSize(int populationSize) const; - int ReadNumberXovers() const; + int ReadNumberXovers(void) const; void SetNumberXovers(int numberXovers) const; - unsigned int ReadOrderRandomization() const; + unsigned int ReadOrderRandomization(void) const; void SetOrderRandomization(unsigned int factor) const; - unsigned long ReadMemoryInUse() const; - long ReadPeakNodeCount() const; - long ReadNodeCount() const; - long zddReadNodeCount() const; + unsigned long ReadMemoryInUse(void) const; + long ReadPeakNodeCount(void) const; + long ReadNodeCount(void) const; + long zddReadNodeCount(void) const; void AddHook(DD_HFP f, Cudd_HookType where) const; void RemoveHook(DD_HFP f, Cudd_HookType where) const; bool IsInHook(DD_HFP f, Cudd_HookType where) const; - void EnableReorderingReporting() const; - void DisableReorderingReporting() const; - bool ReorderingReporting() const; - int ReadErrorCode() const; - void ClearErrorCode() const; - FILE *ReadStdout() const; - void SetStdout(FILE *) const; - FILE *ReadStderr() const; - void SetStderr(FILE *) const; - unsigned int ReadNextReordering() const; + void EnableReorderingReporting(void) const; + void DisableReorderingReporting(void) const; + bool ReorderingReporting(void) const; + int ReadErrorCode(void) const; + DD_OOMFP InstallOutOfMemoryHandler(DD_OOMFP newHandler) const; + void ClearErrorCode(void) const; + FILE *ReadStdout(void) const; + void SetStdout(FILE * fp) const; + FILE *ReadStderr(void) const; + void SetStderr(FILE * fp) const; + unsigned int ReadNextReordering(void) const; void SetNextReordering(unsigned int) const; - double ReadSwapSteps() const; - unsigned int ReadMaxLive() const; + double ReadSwapSteps(void) const; + unsigned int ReadMaxLive(void) const; void SetMaxLive(unsigned int) const; - unsigned long ReadMaxMemory() const; - void SetMaxMemory(unsigned long) const; + size_t ReadMaxMemory(void) const; + size_t SetMaxMemory(size_t) const; int bddBindVar(int) const; int bddUnbindVar(int) const; bool bddVarIsBound(int) const; - ADD Walsh(std::vector<ADD> x, std::vector<ADD> y); - ADD addResidue(int n, int m, int options, int top); + ADD Walsh(std::vector<ADD> x, std::vector<ADD> y) const; + ADD addResidue(int n, int m, int options, int top) const; int ApaNumberOfDigits(int binaryDigits) const; DdApaNumber NewApaNumber(int digits) const; void ApaCopy(int digits, DdApaNumber source, DdApaNumber dest) const; @@ -681,99 +656,114 @@ public: void ApaSetToLiteral(int digits, DdApaNumber number, DdApaDigit literal) const; void ApaPowerOfTwo(int digits, DdApaNumber number, int power) const; - void ApaPrintHex(FILE * fp, int digits, DdApaNumber number) const; - void ApaPrintDecimal(FILE * fp, int digits, DdApaNumber number) const; - void DebugCheck(); - void CheckKeys(); - MtrNode * MakeTreeNode(unsigned int low, unsigned int size, unsigned int type) const; - // void Harwell(FILE * fp, ADD* E, ADD** x, ADD** y, ADD** xn, ADD** yn_, int * nx, int * ny, int * m, int * n, int bx, int sx, int by, int sy, int pr); - void PrintLinear(); - int ReadLinear(int x, int y); - BDD Xgty(std::vector<BDD> z, std::vector<BDD> x, std::vector<BDD> y); - BDD Xeqy(std::vector<BDD> x, std::vector<BDD> y); - ADD Xeqy(std::vector<ADD> x, std::vector<ADD> y); - BDD Dxygtdxz(std::vector<BDD> x, std::vector<BDD> y, std::vector<BDD> z); - BDD Dxygtdyz(std::vector<BDD> x, std::vector<BDD> y, std::vector<BDD> z); - BDD Inequality(int c, std::vector<BDD> x, std::vector<BDD> y); - BDD Disequality(int c, std::vector<BDD> x, std::vector<BDD> y); - BDD Interval(std::vector<BDD> x, unsigned int lowerB, unsigned int upperB); - ADD Hamming(std::vector<ADD> xVars, std::vector<ADD> yVars); - // void Read(FILE * fp, ADD* E, ADD** x, ADD** y, ADD** xn, ADD** yn_, int * nx, int * ny, int * m, int * n, int bx, int sx, int by, int sy); - // void Read(FILE * fp, BDD* E, BDD** x, BDD** y, int * nx, int * ny, int * m, int * n, int bx, int sx, int by, int sy); - void ReduceHeap(Cudd_ReorderingType heuristic, int minsize); - void ShuffleHeap(int * permutation); + void ApaPrintHex(int digits, DdApaNumber number, FILE * fp = stdout) const; + void ApaPrintDecimal(int digits, DdApaNumber number, FILE * fp = stdout) const; + std::string ApaStringDecimal(int digits, DdApaNumber number) const; + void ApaPrintExponential(int digits, DdApaNumber number, + int precision = 6, FILE * fp = stdout) const; + void DebugCheck(void) const; + void CheckKeys(void) const; + ADD Harwell(FILE * fp, std::vector<ADD>& x, std::vector<ADD>& y, + std::vector<ADD>& xn, std::vector<ADD>& yn_, + int * m, int * n, int bx = 0, int sx = 2, int by = 1, + int sy = 2, int pr = 0) const; + void PrintLinear(void) const; + int ReadLinear(int x, int y) const; + BDD Xgty(std::vector<BDD> z, std::vector<BDD> x, std::vector<BDD> y) const; + BDD Xeqy(std::vector<BDD> x, std::vector<BDD> y) const; + ADD Xeqy(std::vector<ADD> x, std::vector<ADD> y) const; + BDD Dxygtdxz(std::vector<BDD> x, std::vector<BDD> y, + std::vector<BDD> z) const; + BDD Dxygtdyz(std::vector<BDD> x, std::vector<BDD> y, + std::vector<BDD> z) const; + BDD Inequality(int c, std::vector<BDD> x, std::vector<BDD> y) const; + BDD Disequality(int c, std::vector<BDD> x, std::vector<BDD> y) const; + BDD Interval(std::vector<BDD> x, unsigned int lowerB, + unsigned int upperB) const; + ADD Hamming(std::vector<ADD> xVars, std::vector<ADD> yVars) const; + ADD Read(FILE * fp, std::vector<ADD>& x, std::vector<ADD>& y, std::vector<ADD>& xn, + std::vector<ADD>& yn_, int * m, int * n, int bx = 0, int sx = 2, + int by = 1, int sy = 2) const; + BDD Read(FILE * fp, std::vector<BDD>& x, std::vector<BDD>& y, + int * m, int * n, int bx = 0, int sx = 2, int by = 1, + int sy = 2) const; + void ReduceHeap(Cudd_ReorderingType heuristic = CUDD_REORDER_SIFT, + int minsize = 0) const; + void ShuffleHeap(int * permutation) const; void SymmProfile(int lower, int upper) const; unsigned int Prime(unsigned int pr) const; void Reserve(int amount) const; int SharingSize(DD* nodes, int n) const; int SharingSize(const std::vector<BDD>& v) const; BDD bddComputeCube(BDD * vars, int * phase, int n) const; - ADD addComputeCube(ADD * vars, int * phase, int n); - int NextNode(DdGen * gen, BDD * nnode); - BDD IndicesToCube(int * array, int n); + BDD computeCube(std::vector<BDD> const & vars) const; + ADD addComputeCube(ADD * vars, int * phase, int n) const; + ADD computeCube(std::vector<ADD> const & vars) const; + BDD IndicesToCube(int * array, int n) const; void PrintVersion(FILE * fp) const; - double AverageDistance() const; - long Random() const; - void Srandom(long seed) const; - MtrNode * MakeZddTreeNode(unsigned int low, unsigned int size, unsigned int type); + double AverageDistance(void) const; + int32_t Random(void) const; + void Srandom(int32_t seed) const; void zddPrintSubtable() const; - void zddReduceHeap(Cudd_ReorderingType heuristic, int minsize); - void zddShuffleHeap(int * permutation); + void zddReduceHeap(Cudd_ReorderingType heuristic = CUDD_REORDER_SIFT, + int minsize = 0) const; + void zddShuffleHeap(int * permutation) const; void zddSymmProfile(int lower, int upper) const; void DumpDot( const std::vector<BDD>& nodes, - char ** inames = 0, - char ** onames = 0, + char const * const * inames = 0, + char const * const * onames = 0, FILE * fp = stdout) const; void DumpDaVinci( const std::vector<BDD>& nodes, - char ** inames = 0, - char ** onames = 0, + char const * const * inames = 0, + char const * const * onames = 0, FILE * fp = stdout) const; void DumpBlif( const std::vector<BDD>& nodes, - char ** inames = 0, - char ** onames = 0, + char const * const * inames = 0, + char const * const * onames = 0, char * mname = 0, FILE * fp = stdout, int mv = 0) const; void DumpDDcal( const std::vector<BDD>& nodes, - char ** inames = 0, - char ** onames = 0, + char const * const * inames = 0, + char const * const * onames = 0, FILE * fp = stdout) const; void DumpFactoredForm( const std::vector<BDD>& nodes, - char ** inames = 0, - char ** onames = 0, + char const * const * inames = 0, + char const * const * onames = 0, FILE * fp = stdout) const; BDD VectorSupport(const std::vector<BDD>& roots) const; std::vector<unsigned int> - SupportIndices(const std::vector<ABDD>& roots) const; + SupportIndices(const std::vector<BDD>& roots) const; + std::vector<unsigned int> + SupportIndices(const std::vector<ADD>& roots) const; int nodeCount(const std::vector<BDD>& roots) const; int VectorSupportSize(const std::vector<BDD>& roots) const; void DumpDot( const std::vector<ADD>& nodes, - char ** inames = 0, - char ** onames = 0, + char const * const * inames = 0, + char const * const * onames = 0, FILE * fp = stdout) const; void DumpDaVinci( const std::vector<ADD>& nodes, - char ** inames = 0, - char ** onames = 0, + char const * const * inames = 0, + char const * const * onames = 0, FILE * fp = stdout) const; BDD VectorSupport(const std::vector<ADD>& roots) const; int VectorSupportSize(const std::vector<ADD>& roots) const; void DumpDot( const std::vector<ZDD>& nodes, - char ** inames = 0, - char ** onames = 0, + char const * const * inames = 0, + char const * const * onames = 0, FILE * fp = stdout) const; + std::string OrderString(void) const; }; // Cudd -extern void defaultError(std::string message); - -} // end namespace cudd +} // end of namespace cudd #endif diff --git a/resources/3rdparty/cudd-3.0.0/cplusplus/test_obj.test.in b/resources/3rdparty/cudd-3.0.0/cplusplus/test_obj.test.in new file mode 100644 index 000000000..6ba4734be --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cplusplus/test_obj.test.in @@ -0,0 +1,71 @@ +#! /bin/sh + +EXE=@EXEEXT@ +srcdir=@srcdir@ + +file=test +mfile=multi +verbosity=2 +nthreads=4 + +sed_command='-r:-e:s/0x[0-9a-f][0-9a-f]*//g:-e:s/dashed//:-e:s/dotted//:-e:s/[0-9][0-9]*.bytes//:-e:/[0-9][0-9]* ms//:-e:/modifiable/,$d' + +echo TAP version 13 +echo 1..2 +exitstatus=0 +# Create empty file. +: > ./cplusplus/differences + +cplusplus/testobj$EXE $verbosity > ./cplusplus/${file}.tst 2>&1 +failed=`expr $? != 0` +if test x$failed = x0; then + echo "# comparing ./cplusplus/${file}.tst to ${srcdir}/cplusplus/${file}.out" + mkfifo ./cplusplus/tst_fifo ./cplusplus/out_fifo + OIFS=$IFS + IFS=: + `sed ${sed_command} ./cplusplus/${file}.tst > ./cplusplus/tst_fifo &\ + sed ${sed_command} ${srcdir}/cplusplus/${file}.out > ./cplusplus/out_fifo &\ + diff -b ./cplusplus/tst_fifo ./cplusplus/out_fifo >> ./cplusplus/differences` + failed=`expr $? != 0` + rm ./cplusplus/tst_fifo ./cplusplus/out_fifo + IFS=$OIFS +fi +if test x$failed = x0 ; then + echo "ok 1 BDD ADD ZDD basic test" +else + echo "not ok 1 base" +fi +exitstatus=`expr $exitstatus + $failed` + +cplusplus/testmulti$EXE $nthreads > ./cplusplus/${mfile}.tst 2>&1 +retval=$? +failed=`expr $retval != 0` +if test x$failed = x0; then + echo "# comparing ./cplusplus/${mfile}.tst to ${srcdir}/cplusplus/${mfile}.out" + mkfifo ./cplusplus/tst_fifo ./cplusplus/out_fifo + OIFS=$IFS + IFS=: + `sed ${sed_command} ./cplusplus/${mfile}.tst > ./cplusplus/tst_fifo &\ + sed ${sed_command} ${srcdir}/cplusplus/${mfile}.out > ./cplusplus/out_fifo &\ + diff -b ./cplusplus/tst_fifo ./cplusplus/out_fifo >> ./cplusplus/differences` + failed=`expr $? != 0` + rm ./cplusplus/tst_fifo ./cplusplus/out_fifo + IFS=$OIFS +fi +if test x$failed = x0 ; then + echo "ok 2 multi-threaded multiple managers" +elif test x$retval = x77 ; then + failed=0 + echo "ok 2 multiple managers #SKIP thread header broken" +else + echo "not ok $count 2 multiple managers" +fi +exitstatus=`expr $exitstatus + $failed` + +if test x$exitstatus = x0; then + rm -rf ./cplusplus/differences +else + echo '# Check file "./cplusplus/differences"' +fi + +exit 0 diff --git a/resources/3rdparty/cudd-3.0.0/cplusplus/testmulti.cc b/resources/3rdparty/cudd-3.0.0/cplusplus/testmulti.cc new file mode 100644 index 000000000..f3f3a1d72 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cplusplus/testmulti.cc @@ -0,0 +1,192 @@ +/** + @file + + @ingroup cplusplus + + @brief Test program for multiple managers (one per thread). + + @details This program tests the ability to run different CUDD managers + in different threads. Each thread builds the hidden weight bit function + for a certain number of variables and then reorders the variables. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "config.h" +#include "cuddObj.hh" +#include <cstdlib> +#include <iostream> +#include <sstream> +#if HAVE_WORKING_THREAD == 1 +#include <thread> + +/** + * @brief Taks performed by each thread. + */ +class Task { +public: + /** Constructor. */ + Task(int n, std::ostringstream & os) : n(n), os(os) {} + /** Builds the hidden weight bit function and reorders the variables. */ + void operator()(void) { + Cudd mgr; + mgr.AutodynEnable(); + int nvars = n + 32; + std::vector<BDD> vars; + for (int i = 0; i != nvars; ++i) { + vars.push_back(mgr.bddVar()); + } + os << "Report from thread " << n << " with " << nvars << " variables: "; + // The hidden weight bit function is built from a tally circuit and + // a multiplexer. First the tally circuit... + std::vector<BDD> oldt; + oldt.push_back(mgr.bddOne()); + std::vector<BDD> t; + for (int i = 1; i != nvars + 1; ++i) { + t.clear(); + t.push_back(oldt.at(0) & !vars.at(i-1)); + for (int j = 1; j != i; ++j) { + t.push_back(vars.at(i-1).Ite(oldt.at(j-1), oldt.at(j))); + } + t.push_back(oldt.at(i-1) & vars.at(i-1)); + oldt = t; + } +#if 0 + // Diagnostic print. + for (int i = 0; i != nvars + 1; ++i) { + os << "t(" << i << ") = " << t.at(i).FactoredFormString() + << std::endl; + } +#endif + // ...then the multiplexer. + BDD hwb = mgr.bddZero(); + for (int i = 0; i != nvars; ++i) { + hwb |= t.at(i+1) & vars.at(i); + } + mgr.ReduceHeap(CUDD_REORDER_SIFT_CONVERGE); + + int nodes = hwb.nodeCount(); + os << nodes << " nodes and "; + int digits; + DdApaNumber apa_minterms = hwb.ApaCountMinterm(nvars, &digits); + os << mgr.ApaStringDecimal(digits, apa_minterms) << " minterms\n"; + free(apa_minterms); + os << "Variable order: " << mgr.OrderString() << "\n"; + mgr.Srandom(n+11); + os << "A random number from our generator: " << mgr.Random() << "\n"; +#if 0 + // Diagnostic prints. + hwb.summary(nvars); + os << hwb.FactoredFormString() << std::endl; +#endif + } +private: + int n; + std::ostringstream & os; +}; + + +/** + * @brief Class to join threads in RAII fashion. + */ +class joinThreads { +public: + explicit joinThreads(std::vector<std::thread>& t) : threads_(t) {} + /** It completes once all threads have been joined. */ + ~joinThreads() { + for (std::vector<std::thread>::iterator it = threads_.begin(); + it != threads_.end(); ++it) + if (it->joinable()) + it->join(); + } + joinThreads(joinThreads const &) = delete; + joinThreads& operator=(joinThreads const &) = delete; +private: + std::vector<std::thread>& threads_; /**< vector of threads to be joined. */ +}; +#endif + +/** + @brief Main program for testmulti. +*/ +int main(int argc, char **argv) +{ + int nthreads = 4; // default value + + // If there's an argument, it's the number of threads. + if (argc == 2) { + int nread; + int retval = sscanf(argv[1], "%d%n", &nthreads, &nread); + if (retval != 1 || argv[1][nread]) { + std::cerr << "The argument should be an integer." << std::endl; + return 1; + } + } else if (argc != 1) { + std::cerr << "Either no arguments or one argument." << std::endl; + return 1; + } + +#if HAVE_WORKING_THREAD == 1 + // Each thread has its own output stream, so that main can print thread + // reports without interleaving. We can't use an std::vector here because + // old versions of g++ don't support move semantics (and streams can't + // be copied). We can't use a variable-length array either because it's + // a g++ extension and clang++ rejects it. Hence we use new/delete. + std::ostringstream *oss = new std::ostringstream[nthreads]; + + // Multi-threaded code in this block. + { + std::vector<std::thread> t; + joinThreads joiner(t); // threads are joined by its destructor + for (int n = 0; n != nthreads; ++n) { + t.push_back(std::thread(Task(n, oss[n]))); + } + } + + // Print the reports. + for (int n = 0; n != nthreads; ++n) { + std::cout << oss[n].str(); + } + + delete [] oss; + + return 0; +#else + return 77; // test skipped +#endif +} diff --git a/resources/3rdparty/cudd-3.0.0/cplusplus/testobj.cc b/resources/3rdparty/cudd-3.0.0/cplusplus/testobj.cc new file mode 100644 index 000000000..a83e1c7a3 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cplusplus/testobj.cc @@ -0,0 +1,832 @@ +/** + @file + + @ingroup cplusplus + + @brief Test program for the C++ object-oriented encapsulation of CUDD. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "cuddObj.hh" +#include <math.h> +#include <iostream> +#include <sstream> +#include <cassert> +#include <stdexcept> + +using namespace std; + +/*---------------------------------------------------------------------------*/ +/* Variable declarations */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Static function prototypes */ +/*---------------------------------------------------------------------------*/ + +static void testBdd(Cudd& mgr, int verbosity); +static void testAdd(Cudd& mgr, int verbosity); +static void testAdd2(Cudd& mgr, int verbosity); +static void testZdd(Cudd& mgr, int verbosity); +static void testBdd2(Cudd& mgr, int verbosity); +static void testBdd3(Cudd& mgr, int verbosity); +static void testZdd2(Cudd& mgr, int verbosity); +static void testBdd4(Cudd& mgr, int verbosity); +static void testBdd5(Cudd& mgr, int verbosity); +static void testInterpolation(Cudd& mgr, int verbosity); +static void testErrorHandling(Cudd& mgr, int verbosity); + +/*---------------------------------------------------------------------------*/ +/* Definition of exported functions */ +/*---------------------------------------------------------------------------*/ + +/** + @brief Main program for testobj. +*/ +int +main(int argc, char **argv) +{ + int verbosity = 0; + + if (argc == 2) { + int cnt; + int retval = sscanf(argv[1], "%d %n", &verbosity, &cnt); + if (retval != 1 || argv[1][cnt]) + return 1; + } else if (argc != 1) { + return 1; + } + + Cudd mgr(0,2); + if (verbosity > 2) mgr.makeVerbose(); // trace constructors and destructors + testBdd(mgr,verbosity); + testAdd(mgr,verbosity); + testAdd2(mgr,verbosity); + testZdd(mgr,verbosity); + testBdd2(mgr,verbosity); + testBdd3(mgr,verbosity); + testZdd2(mgr,verbosity); + testBdd4(mgr,verbosity); + testBdd5(mgr,verbosity); + testInterpolation(mgr,verbosity); + testErrorHandling(mgr,verbosity); + if (verbosity) mgr.info(); + return 0; + +} // main + + +/** + @brief Test basic operators on BDDs. + + @details The function returns void + because it relies on the error handling done by the interface. The + default error handler causes program termination. + + @sideeffect Creates BDD variables in the manager. + + @see testBdd2 testBdd3 testBdd4 testBdd5 + +*/ +static void +testBdd( + Cudd& mgr, + int verbosity) +{ + if (verbosity) cout << "Entering testBdd\n"; + // Create two new variables in the manager. If testBdd is called before + // any variable is created in mgr, then x gets index 0 and y gets index 1. + BDD x = mgr.bddVar(); + BDD y = mgr.bddVar(); + + BDD f = x * y; + if (verbosity) cout << "f"; f.print(2,verbosity); + + BDD g = y + !x; + if (verbosity) cout << "g"; g.print(2,verbosity); + + if (verbosity) + cout << "f and g are" << (f == !g ? "" : " not") << " complementary\n"; + if (verbosity) + cout << "f is" << (f <= g ? "" : " not") << " less than or equal to g\n"; + + g = f | ~g; + if (verbosity) cout << "g"; g.print(2,verbosity); + + BDD h = f = y; + if (verbosity) cout << "h"; h.print(2,verbosity); + + if (verbosity) cout << "x + h has " << (x+h).nodeCount() << " nodes\n"; + + h += x; + if (verbosity) cout << "h"; h.print(2,verbosity); + +} // testBdd + + +/** + @brief Test basic operators on ADDs. + + @details The function returns void because it relies on the error + handling done by the interface. The default error handler causes + program termination. + + @sideeffect May create ADD variables in the manager. + + @see testAdd2 + +*/ +static void +testAdd( + Cudd& mgr, + int verbosity) +{ + if (verbosity) cout << "Entering testAdd\n"; + // Create two ADD variables. If we called method addVar without an + // argument, we would get two new indices. If testAdd is indeed called + // after testBdd, then those indices would be 2 and 3. By specifying the + // arguments, on the other hand, we avoid creating new unnecessary BDD + // variables. + ADD p = mgr.addVar(0); + ADD q = mgr.addVar(1); + + // Test arithmetic operators. + ADD r = p + q; + if (verbosity) cout << "r"; r.print(2,verbosity); + + // CUDD_VALUE_TYPE is double. + ADD s = mgr.constant(3.0); + s *= p * q; + if (verbosity) cout << "s"; s.print(2,verbosity); + + s += mgr.plusInfinity(); + if (verbosity) cout << "s"; s.print(2,verbosity); + + // Test relational operators. + if (verbosity) + cout << "p is" << (p <= r ? "" : " not") << " less than or equal to r\n"; + + // Test logical operators. + r = p | q; + if (verbosity) cout << "r"; r.print(2,verbosity); + +} // testAdd + + +/** + @brief Test some more operators on ADDs. + + @details The function returns void because it relies on the error + handling done by the interface. The default error handler causes + program termination. + + @sideeffect May create ADD variables in the manager. + + @see testAdd + +*/ +static void +testAdd2( + Cudd& mgr, + int verbosity) +{ + if (verbosity) cout << "Entering testAdd2\n"; + // Create two ADD variables. If we called method addVar without an + // argument, we would get two new indices. + vector<ADD> x(2); + for (size_t i = 0; i < 2; ++i) { + x[i] = mgr.addVar((int) i); + } + + // Build a probability density function: [0.1, 0.2, 0.3, 0.4]. + ADD f0 = x[1].Ite(mgr.constant(0.2), mgr.constant(0.1)); + ADD f1 = x[1].Ite(mgr.constant(0.4), mgr.constant(0.3)); + ADD f = x[0].Ite(f1, f0); + if (verbosity) cout << "f"; f.print(2,verbosity); + + // Compute the entropy. + ADD l = f.Log(); + if (verbosity) cout << "l"; l.print(2,verbosity); + ADD r = f * l; + if (verbosity) cout << "r"; r.print(2,verbosity); + + ADD e = r.MatrixMultiply(mgr.constant(-1.0/log(2.0)),x); + if (verbosity) cout << "e"; e.print(2,verbosity); + +} // testAdd2 + + +/** + @brief Test basic operators on ZDDs. + + @details The function returns void because it relies on the error + handling done by the interface. The default error handler causes + program termination. + + @sideeffect May create ZDD variables in the manager. + + @see testZdd2 + +*/ +static void +testZdd( + Cudd& mgr, + int verbosity) +{ + if (verbosity) cout << "Entering testZdd\n"; + ZDD v = mgr.zddVar(0); + ZDD w = mgr.zddVar(1); + + ZDD s = v + w; + if (verbosity) cout << "s"; s.print(2,verbosity); + + if (verbosity) cout << "v is" << (v < s ? "" : " not") << " less than s\n"; + + s -= v; + if (verbosity) cout << "s"; s.print(2,verbosity); + +} // testZdd + + +/** + @brief Test vector operators on BDDs. + + @details The function returns void because it relies on the error + handling done by the interface. The default error handler causes + program termination. + + @sideeffect May create BDD variables in the manager. + + @see testBdd testBdd3 testBdd4 testBdd5 + +*/ +static void +testBdd2( + Cudd& mgr, + int verbosity) +{ + if (verbosity) cout << "Entering testBdd2\n"; + vector<BDD> x(4); + for (size_t i = 0; i < 4; ++i) { + x[i] = mgr.bddVar((int) i); + } + + // Create the BDD for the Achilles' Heel function. + BDD p1 = x[0] * x[2]; + BDD p2 = x[1] * x[3]; + BDD f = p1 + p2; + const char* inames[] = {"x0", "x1", "x2", "x3"}; + if (verbosity) { + cout << "f"; f.print(4,verbosity); + cout << "Irredundant cover of f:" << endl; f.PrintCover(); + cout << "Number of minterms (arbitrary precision): "; f.ApaPrintMinterm(4); + cout << "Number of minterms (extended precision): "; f.EpdPrintMinterm(4); + cout << "Two-literal clauses of f:" << endl; + f.PrintTwoLiteralClauses((char **)inames); cout << endl; + } + + vector<BDD> vect = f.CharToVect(); + if (verbosity) { + for (size_t i = 0; i < vect.size(); i++) { + cout << "vect[" << i << "]" << endl; vect[i].PrintCover(); + } + } + + // v0,...,v3 suffice if testBdd2 is called before testBdd3. + if (verbosity) { + const char* onames[] = {"v0", "v1", "v2", "v3", "v4", "v5"}; + mgr.DumpDot(vect, (char **)inames,(char **)onames); + } + +} // testBdd2 + + +/** + @brief Test additional operators on BDDs. + + @details The function returns void because it relies on the error + handling done by the interface. The default error handler causes + program termination. + + @sideeffect May create BDD variables in the manager. + + @see testBdd testBdd2 testBdd4 testBdd5 + +*/ +static void +testBdd3( + Cudd& mgr, + int verbosity) +{ + if (verbosity) cout << "Entering testBdd3\n"; + vector<BDD> x(6); + for (size_t i = 0; i < 6; ++i) { + x[i] = mgr.bddVar((int) i); + } + + BDD G = x[4] + !x[5]; + BDD H = x[4] * x[5]; + BDD E = x[3].Ite(G,!x[5]); + BDD F = x[3] + !H; + BDD D = x[2].Ite(F,!H); + BDD C = x[2].Ite(E,!F); + BDD B = x[1].Ite(C,!F); + BDD A = x[0].Ite(B,!D); + BDD f = !A; + if (verbosity) cout << "f"; f.print(6,verbosity); + + BDD f1 = f.RemapUnderApprox(6); + if (verbosity) cout << "f1"; f1.print(6,verbosity); + if (verbosity) + cout << "f1 is" << (f1 <= f ? "" : " not") << " less than or equal to f\n"; + + BDD g; + BDD h; + f.GenConjDecomp(&g,&h); + if (verbosity) { + cout << "g"; g.print(6,verbosity); + cout << "h"; h.print(6,verbosity); + cout << "g * h " << (g * h == f ? "==" : "!=") << " f\n"; + } + +} // testBdd3 + + +/** + @brief Test cover manipulation with BDDs and ZDDs. + + @details The function returns void because it relies on the error + handling done by the interface. The default error handler causes + program termination. This function builds the BDDs for a + transformed adder: one in which the inputs are transformations of + the original inputs. It then creates ZDDs for the covers from the + BDDs. + + @sideeffect May create BDD and ZDD variables in the manager. + + @see testZdd + +*/ +static void +testZdd2( + Cudd& mgr, + int verbosity) +{ + if (verbosity) cout << "Entering testZdd2\n"; + size_t N = 3; // number of bits + // Create variables. + vector<BDD> a(N); + vector<BDD> b(N); + vector<BDD> c(N+1); + for (size_t i = 0; i < N; ++i) { + a[N-1-i] = mgr.bddVar(2*(int)i); + b[N-1-i] = mgr.bddVar(2*(int)i+1); + } + c[0] = mgr.bddVar(2*(int)N); + // Build functions. + vector<BDD> s(N); + for (size_t i = 0; i < N; ++i) { + s[i] = a[i].Xnor(c[i]); + c[i+1] = a[i].Ite(b[i],c[i]); + } + + // Create array of outputs and print it. + vector<BDD> p(N+1); + for (size_t i = 0; i < N; ++i) { + p[i] = s[i]; + } + p[N] = c[N]; + if (verbosity) { + for (size_t i = 0; i < p.size(); ++i) { + cout << "p[" << i << "]"; p[i].print(2*(int)N+1,verbosity); + } + } + const char* onames[] = {"s0", "s1", "s2", "c3"}; + if (verbosity) { + const char* inames[] = {"a2", "b2", "a1", "b1", "a0", "b0", "c0"}; + mgr.DumpDot(p, (char **)inames,(char **)onames); + } + + // Create ZDD variables and build ZDD covers from BDDs. + mgr.zddVarsFromBddVars(2); + vector<ZDD> z(N+1); + for (size_t i = 0; i < N+1; ++i) { + ZDD temp; + BDD dummy = p[i].zddIsop(p[i],&temp); + z[i] = temp; + } + + // Print out covers. + if (verbosity) { + DdGen *gen; + int *path; + for (size_t i = 0; i < z.size(); i++) { + cout << "z[" << i << "]"; z[i].print(4*(int)N+2,verbosity); + } + // Print cover in two different ways: with PrintCover and with + // enumeration over the paths. The only difference should be + // a reversal in the order of the cubes. + for (size_t i = 0; i < z.size(); i++) { + cout << "z[" << i << "]\n"; z[i].PrintCover(); + cout << "z[" << i << "]\n"; + DdNode *f = Cudd_Not(z[i].getNode()); + Cudd_zddForeachPath(z[i].manager(), f, gen, path) { + for (size_t q = 0; q < 4*N+2; q += 2) { + int v = path[q] * 4 + path[q+1]; + switch (v) { + case 0: + case 2: + case 8: + case 10: + cout << "-"; + break; + case 1: + case 9: + cout << "0"; + break; + case 6: + cout << "1"; + break; + default: + cout << "?"; + } + } + cout << " 1\n"; + } + } + const char* znames[] = {"a2+", "a2-", "b2+", "b2-", "a1+", "a1-", "b1+", + "b1-", "a0+", "a0-", "b0+", "b0-", "c0+", "c0-"}; + mgr.DumpDot(z, (char **)znames,(char **)onames); + } + +} // testZdd2 + + +/** + @brief Test transfer between BDD managers. + + @details The function returns void because it relies on the error + handling done by the interface. The default error handler causes + program termination. + + @sideeffect May create BDD variables in the manager. + + @see testBdd testBdd2 testBdd3 testBdd5 + +*/ +static void +testBdd4( + Cudd& mgr, + int verbosity) +{ + if (verbosity) cout << "Entering testBdd4\n"; + BDD x = mgr.bddVar(0); + BDD y = mgr.bddVar(1); + BDD z = mgr.bddVar(2); + + BDD f = (~x & ~y & ~z) | (x & y); + if (verbosity) cout << "f"; f.print(3,verbosity); + + Cudd otherMgr(0,0); + BDD g = f.Transfer(otherMgr); + if (verbosity) cout << "g"; g.print(3,verbosity); + + BDD h = g.Transfer(mgr); + if (verbosity) + cout << "f and h are" << (f == h ? "" : " not") << " identical\n"; + +} // testBdd4 + + +/** + @brief Test maximal expansion of cubes. + + @details The function returns void because it relies on the error + handling done by the interface. The default error handler causes + program termination. + + @sideeffect May create BDD variables in the manager. + + @see testBdd testBdd2 testBdd3 testBdd4 + +*/ +static void +testBdd5( + Cudd& mgr, + int verbosity) +{ + if (verbosity) cout << "Entering testBdd5\n"; + vector<BDD> x; + x.reserve(4); + for (int i = 0; i < 4; i++) { + x.push_back(mgr.bddVar(i)); + } + const char* inames[] = {"a", "b", "c", "d"}; + BDD f = (x[1] & x[3]) | (x[0] & ~x[2] & x[3]) | (~x[0] & x[1] & ~x[2]); + BDD lb = x[1] & ~x[2] & x[3]; + BDD ub = x[3]; + BDD primes = lb.MaximallyExpand(ub,f); + assert(primes == (x[1] & x[3])); + BDD lprime = primes.LargestPrimeUnate(lb); + assert(lprime == primes); + if (verbosity) { + const char * onames[] = {"lb", "ub", "f", "primes", "lprime"}; + vector<BDD> z; + z.reserve(5); + z.push_back(lb); + z.push_back(ub); + z.push_back(f); + z.push_back(primes); + z.push_back(lprime); + mgr.DumpDot(z, (char **)inames, (char **)onames); + cout << "primes(1)"; primes.print(4,verbosity); + } + + lb = ~x[0] & x[2] & x[3]; + primes = lb.MaximallyExpand(ub,f); + assert(primes == mgr.bddZero()); + if (verbosity) { + cout << "primes(2)"; primes.print(4,verbosity); + } + + lb = x[0] & ~x[2] & x[3]; + primes = lb.MaximallyExpand(ub,f); + assert(primes == lb); + lprime = primes.LargestPrimeUnate(lb); + assert(lprime == primes); + if (verbosity) { + cout << "primes(3)"; primes.print(4,verbosity); + } + + lb = ~x[0] & x[1] & ~x[2] & x[3]; + ub = mgr.bddOne(); + primes = lb.MaximallyExpand(ub,f); + assert(primes == ((x[1] & x[3]) | (~x[0] & x[1] & ~x[2]))); + lprime = primes.LargestPrimeUnate(lb); + assert(lprime == (x[1] & x[3])); + if (verbosity) { + cout << "primes(4)"; primes.print(4,1); primes.PrintCover(); + } + + ub = ~x[0] & x[3]; + primes = lb.MaximallyExpand(ub,f); + assert(primes == (~x[0] & x[1] & x[3])); + lprime = primes.LargestPrimeUnate(lb); + assert(lprime == primes); + if (verbosity) { + cout << "primes(5)"; primes.print(4,verbosity); + } + +} // testBdd5 + + +/** + @brief Test BDD interpolation. +*/ +static void +testInterpolation( + Cudd& mgr, + int verbosity) +{ + BDD a = mgr.bddVar(0); + BDD b = mgr.bddVar(1); + BDD c = mgr.bddVar(2); + BDD d = mgr.bddVar(3); + + BDD l1 = (a | d) & b & c; + BDD u1 = (~a & ~b & ~c) | ((a | b) & c); + BDD ip1 = l1.Interpolate(u1); + if (verbosity) { + cout << "l1"; l1.print(4,verbosity); + cout << "u1"; u1.print(4,verbosity); + cout << "interpolant1"; ip1.print(4,verbosity); + } + + BDD l2 = (~a | ~b) & (a | c) & (b | c) & (a | ~b | ~d); + BDD u2 = (~b & ~d) | (~b & c & d) | (b & c & ~d); + BDD ip2 = l2.Interpolate(u2); + if (verbosity) { + cout << "l2"; l2.print(4,verbosity); + cout << "u2"; u2.print(4,verbosity); + cout << "interpolant2"; ip2.print(4,verbosity); + } + + BDD l3 = ~a & ~b & d; + BDD u3 = ~b & d; + BDD ip3 = l3.Interpolate(u3); + if (verbosity) { + cout << "l3"; l3.print(4,verbosity); + cout << "u3"; u3.print(4,verbosity); + cout << "interpolant3"; ip3.print(4,verbosity); + } + +} // testInterpolation + + +/** + @brief Basic test of error handling. + + @details This function also illustrates the use of the overloading of the + stream insertion operator (operator<<) for BDDs. +*/ +static void +testErrorHandling( + Cudd& mgr, + int verbosity) +{ + // Setup. + + if (verbosity) cout << "Entering testErrorHandling\n"; + + FILE *savefp = 0; + if (verbosity == 0) { + // Suppress error messages coming from CUDD. + savefp = mgr.ReadStderr(); +#ifndef _WIN32 + FILE * devnull = fopen("/dev/null", "w"); +#else + FILE * devnull = fopen("NUL", "w"); +#endif + if (devnull) + mgr.SetStderr(devnull); + } + + size_t const N = 60; + vector<BDD> vars; + vars.reserve(N); + for (size_t i = 0; i < N; ++i) { + vars.push_back(mgr.bddVar((int) i)); + } + + // It is necessary to give names to all the BDD variables in the manager + // for the names to be used by operator<<. + for (int i = 0; i < mgr.ReadSize(); ++i) { + ostringstream os; + os << "var[" << i << "]"; + mgr.pushVariableName(os.str()); + } + + // Tests. + + // Trying to print the expression of an empty BDD. + try { + BDD empty; + if (verbosity > 0) + cout << "Oops! "; + cout << empty << endl; + } catch (logic_error const & e) { + if (verbosity > 0) + cerr << "Caught: " << e.what() << endl; + } + + // Trying to extract a minterm from the zero BDD. + try { + BDD zero = mgr.bddZero(); + BDD minterm = zero.PickOneMinterm(vars); + } catch (logic_error const & e) { + if (verbosity > 0) + cerr << "Caught: " << e.what() << endl; + mgr.ClearErrorCode(); + } + + // Passing a non-cube second argument to Cofactor. + try { + BDD f = vars.at(1) | (vars.at(2) & vars.at(3)); + if (verbosity > 0) + cout << "f = " << f << endl; + BDD notAcube = vars.at(0) | vars.at(1); + if (verbosity > 0) + cout << notAcube << " is not a cube" << endl; + BDD fc = f.Cofactor(notAcube); + if (verbosity > 0) { + cout << "The cofactor is: "; fc.summary(3); + } + } catch (logic_error const & e) { + if (verbosity > 0) + cerr << "Caught: " << e.what() << endl; + mgr.ClearErrorCode(); + } + +#if 0 + // This attempt to allocate over 100 GB may succeed on machines with + // enough memory; hence we exclude it from "make check." + // Failing malloc. + // Don't let the memory manager kill the program if malloc fails. + DD_OOMFP saveHandler = mgr.InstallOutOfMemoryHandler(Cudd_OutOfMemSilent); + try { + mgr.Reserve(2000000000); + } catch (logic_error const & e) { + if (verbosity > 0) + cerr << "Caught: " << e.what() << endl; + mgr.ClearErrorCode(); + } + (void) mgr.InstallOutOfMemoryHandler(saveHandler); +#endif + + // Forgetting to check for empty result when setting a limit on + // the number of new nodes. + try { + BDD f = mgr.bddOne(); + BDD g = f; + for (size_t i = 0; i < N/2; i += 4) { + f &= vars.at(i) | vars.at(i+N/2); + g &= vars.at(i+1) | vars.at(i+N/2+1); + } + if (verbosity > 0) { + cout << "f "; f.summary(N); + cout << "g "; g.summary(N); + } + BDD h = f.And(g, /* max new nodes */ 1); + if (verbosity > 0) { + cout << "h "; h.summary(N); + } + } catch (logic_error const & e) { + if (verbosity > 0) + cerr << "Caught: " << e.what() << endl; + mgr.ClearErrorCode(); + } + + // Using more memory than the set limit. + size_t saveLimit = mgr.SetMaxMemory((size_t) 1); + try { + // The limit is ridiculously low (1 byte), but CUDD is resourceful. + // Therefore we can still create a few BDDs. + BDD f = mgr.Interval(vars, 122346345U, 348353453U); + if (verbosity > 0) { + cout << "f "; f.summary(N); + } + BDD g = mgr.Interval(vars, 34234U, 3143534534U); + if (verbosity > 0) { + cout << "g "; g.summary(N); + } + BDD h = f ^ g; + if (verbosity > 0) { + cout << "h "; h.summary(N); + } + // But if we really insist... + BDD extra = mgr.bddVar(60000); + // Here we would have to fix the variable names. + } catch (logic_error const & e) { + if (verbosity > 0) + cerr << "Caught: " << e.what() << endl; + mgr.ClearErrorCode(); + } + (void) mgr.SetMaxMemory(saveLimit); + + // Timing out. + unsigned long saveTl = mgr.SetTimeLimit(1UL); // 1 ms + try { + BDD f = mgr.bddOne(); + for (size_t i = 0; i < N/2; ++i) { + f &= vars.at(i) | vars.at(i+N/2); + } + } catch (logic_error const & e) { + if (verbosity > 0) + cerr << "Caught: " << e.what() << endl; + mgr.ClearErrorCode(); + } + (void) mgr.SetTimeLimit(saveTl); + + // Let's clean up after ourselves. + mgr.clearVariableNames(); + if (verbosity == 0) { + mgr.SetStderr(savefp); + } + +} // testErrorHandling diff --git a/resources/3rdparty/cudd-3.0.0/cudd/Included.am b/resources/3rdparty/cudd-3.0.0/cudd/Included.am new file mode 100644 index 000000000..c93baf112 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cudd/Included.am @@ -0,0 +1,46 @@ +lib_LTLIBRARIES = cudd/libcudd.la +cudd_libcudd_la_SOURCES = cudd/cudd.h cudd/cuddInt.h \ + cudd/cuddAddAbs.c cudd/cuddAddApply.c cudd/cuddAddFind.c cudd/cuddAddInv.c \ + cudd/cuddAddIte.c cudd/cuddAddNeg.c cudd/cuddAddWalsh.c cudd/cuddAndAbs.c \ + cudd/cuddAnneal.c cudd/cuddApa.c cudd/cuddAPI.c cudd/cuddApprox.c \ + cudd/cuddBddAbs.c cudd/cuddBddCorr.c cudd/cuddBddIte.c cudd/cuddBridge.c \ + cudd/cuddCache.c cudd/cuddCheck.c cudd/cuddClip.c cudd/cuddCof.c \ + cudd/cuddCompose.c cudd/cuddDecomp.c cudd/cuddEssent.c cudd/cuddExact.c \ + cudd/cuddExport.c cudd/cuddGenCof.c cudd/cuddGenetic.c cudd/cuddGroup.c \ + cudd/cuddHarwell.c cudd/cuddInit.c cudd/cuddInteract.c cudd/cuddLCache.c \ + cudd/cuddLevelQ.c cudd/cuddLinear.c cudd/cuddLiteral.c cudd/cuddMatMult.c \ + cudd/cuddPriority.c cudd/cuddRead.c cudd/cuddRef.c cudd/cuddReorder.c \ + cudd/cuddSat.c cudd/cuddSign.c cudd/cuddSolve.c cudd/cuddSplit.c \ + cudd/cuddSubsetHB.c cudd/cuddSubsetSP.c cudd/cuddSymmetry.c cudd/cuddTable.c \ + cudd/cuddUtil.c cudd/cuddWindow.c cudd/cuddZddCount.c cudd/cuddZddFuncs.c \ + cudd/cuddZddGroup.c cudd/cuddZddIsop.c cudd/cuddZddLin.c cudd/cuddZddMisc.c \ + cudd/cuddZddPort.c cudd/cuddZddReord.c cudd/cuddZddSetop.c \ + cudd/cuddZddSymm.c cudd/cuddZddUtil.c +cudd_libcudd_la_CPPFLAGS = -I$(top_srcdir)/cudd -I$(top_srcdir)/st \ + -I$(top_srcdir)/epd -I$(top_srcdir)/mtr -I$(top_srcdir)/util +if OBJ +cudd_libcudd_la_LIBTOOLFLAGS=--tag=CXX +endif OBJ +cudd_libcudd_la_LDFLAGS = -release @PACKAGE_VERSION@ -version-info 0:0:0 \ + -no-undefined + +check_PROGRAMS += cudd/testcudd cudd/testextra +cudd_testcudd_SOURCES = cudd/testcudd.c +cudd_testcudd_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +cudd_testcudd_LDADD = cudd/libcudd.la +cudd_testextra_SOURCES = cudd/testextra.c +cudd_testextra_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +cudd_testextra_LDADD = cudd/libcudd.la + +check_SCRIPTS += cudd/test_cudd.test +EXTRA_DIST += cudd/test_cudd.test.in +dist_check_DATA += cudd/r7x8.1.mat cudd/r7x8.1.out cudd/extra.out +if !CROSS_COMPILING +TESTS += cudd/test_cudd.test +endif !CROSS_COMPILING + +cudd/test_cudd.test: cudd/test_cudd.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ + +CLEANFILES += cudd/r7x8.1.tst cudd/extra.tst diff --git a/resources/3rdparty/cudd-3.0.0/cudd/cudd.h b/resources/3rdparty/cudd-3.0.0/cudd/cudd.h new file mode 100644 index 000000000..e2447c878 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cudd/cudd.h @@ -0,0 +1,999 @@ +/** + @file + + @ingroup cudd + + @brief The University of Colorado decision diagram package. + + @details External functions and data strucures of the CUDD package. + <ul> + <li> To turn on the gathering of statistics, define DD_STATS. + <li> To turn on additional debugging code, define DD_DEBUG. + </ul> + + @author Fabio Somenzi + @author Modified by Abelardo Pardo to interface it to VIS + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#ifndef CUDD_H_ +#define CUDD_H_ + +/*---------------------------------------------------------------------------*/ +/* Nested includes */ +/*---------------------------------------------------------------------------*/ + +#include <inttypes.h> + +/*---------------------------------------------------------------------------*/ +/* Constant declarations */ +/*---------------------------------------------------------------------------*/ + +#define CUDD_TRUE 1 /**< readable true */ +#define CUDD_FALSE 0 /**< readable false */ + +/** + * @brief Value returned my many functions when memory is exhausted. + */ +#define CUDD_OUT_OF_MEM -1 +/* The sizes of the subtables and the cache must be powers of two. */ +#define CUDD_UNIQUE_SLOTS 256 /**< Initial size of subtables */ +#define CUDD_CACHE_SLOTS 262144 /**< Default size of the cache */ + +/* Constants for residue functions. */ +#define CUDD_RESIDUE_DEFAULT 0 +#define CUDD_RESIDUE_MSB 1 +#define CUDD_RESIDUE_TC 2 + +/*---------------------------------------------------------------------------*/ +/* Stucture declarations */ +/*---------------------------------------------------------------------------*/ + + +/*---------------------------------------------------------------------------*/ +/* Type declarations */ +/*---------------------------------------------------------------------------*/ + +/** + @brief Type of reordering algorithm. +*/ +typedef enum { + CUDD_REORDER_SAME, + CUDD_REORDER_NONE, + CUDD_REORDER_RANDOM, + CUDD_REORDER_RANDOM_PIVOT, + CUDD_REORDER_SIFT, + CUDD_REORDER_SIFT_CONVERGE, + CUDD_REORDER_SYMM_SIFT, + CUDD_REORDER_SYMM_SIFT_CONV, + CUDD_REORDER_WINDOW2, + CUDD_REORDER_WINDOW3, + CUDD_REORDER_WINDOW4, + CUDD_REORDER_WINDOW2_CONV, + CUDD_REORDER_WINDOW3_CONV, + CUDD_REORDER_WINDOW4_CONV, + CUDD_REORDER_GROUP_SIFT, + CUDD_REORDER_GROUP_SIFT_CONV, + CUDD_REORDER_ANNEALING, + CUDD_REORDER_GENETIC, + CUDD_REORDER_LINEAR, + CUDD_REORDER_LINEAR_CONVERGE, + CUDD_REORDER_LAZY_SIFT, + CUDD_REORDER_EXACT +} Cudd_ReorderingType; + + +/** + @brief Type of aggregation methods. +*/ +typedef enum { + CUDD_NO_CHECK, + CUDD_GROUP_CHECK, + CUDD_GROUP_CHECK2, + CUDD_GROUP_CHECK3, + CUDD_GROUP_CHECK4, + CUDD_GROUP_CHECK5, + CUDD_GROUP_CHECK6, + CUDD_GROUP_CHECK7, + CUDD_GROUP_CHECK8, + CUDD_GROUP_CHECK9 +} Cudd_AggregationType; + + +/** + @brief Type of hooks. +*/ +typedef enum { + CUDD_PRE_GC_HOOK, + CUDD_POST_GC_HOOK, + CUDD_PRE_REORDERING_HOOK, + CUDD_POST_REORDERING_HOOK +} Cudd_HookType; + + +/** + @brief Type of error codes. +*/ +typedef enum { + CUDD_NO_ERROR, + CUDD_MEMORY_OUT, + CUDD_TOO_MANY_NODES, + CUDD_MAX_MEM_EXCEEDED, + CUDD_TIMEOUT_EXPIRED, + CUDD_TERMINATION, + CUDD_INVALID_ARG, + CUDD_INTERNAL_ERROR +} Cudd_ErrorType; + + +/** + @brief Group type for lazy sifting. +*/ +typedef enum { + CUDD_LAZY_NONE, + CUDD_LAZY_SOFT_GROUP, + CUDD_LAZY_HARD_GROUP, + CUDD_LAZY_UNGROUP +} Cudd_LazyGroupType; + + +/** + @brief Variable type. + + @details Used only in lazy sifting. + +*/ +typedef enum { + CUDD_VAR_PRIMARY_INPUT, + CUDD_VAR_PRESENT_STATE, + CUDD_VAR_NEXT_STATE +} Cudd_VariableType; + +/** + @brief Type of the value of a terminal node. +*/ +typedef double CUDD_VALUE_TYPE; + +/** + @brief Type of the decision diagram node. +*/ +typedef struct DdNode DdNode; + +/** + @brief Type of a pointer to a decision diagram node. +*/ +typedef DdNode *DdNodePtr; + +/** + @brief CUDD manager. +*/ +typedef struct DdManager DdManager; + +/** + @brief CUDD generator. +*/ +typedef struct DdGen DdGen; + +/** + @brief Type of an arbitrary precision integer "digit." +*/ +typedef uint32_t DdApaDigit; + +/** + @brief Type of an arbitrary precision intger, which is an array of digits. +*/ +typedef DdApaDigit * DdApaNumber; + +/** + @brief Type of a const-qualified arbitrary precision integer. +*/ +typedef DdApaDigit const * DdConstApaNumber; + +/** + @brief Return type for function computing two-literal clauses. +*/ +typedef struct DdTlcInfo DdTlcInfo; + +/** + @brief Type of hook function. +*/ +typedef int (*DD_HFP)(DdManager *, const char *, void *); +/** + @brief Type of priority function +*/ +typedef DdNode * (*DD_PRFP)(DdManager * , int, DdNode **, DdNode **, DdNode **); +/** + @brief Type of apply operator. +*/ +typedef DdNode * (*DD_AOP)(DdManager *, DdNode **, DdNode **); +/** + @brief Type of monadic apply operator. +*/ +typedef DdNode * (*DD_MAOP)(DdManager *, DdNode *); +/** + @brief Type of two-operand cache tag functions. +*/ +typedef DdNode * (*DD_CTFP)(DdManager *, DdNode *, DdNode *); +/** + @brief Type of one-operand cache tag functions. +*/ +typedef DdNode * (*DD_CTFP1)(DdManager *, DdNode *); +/** + @brief Type of memory-out function. +*/ +typedef void (*DD_OOMFP)(size_t); +/** + @brief Type of comparison function for qsort. +*/ +typedef int (*DD_QSFP)(const void *, const void *); +/** + @brief Type of termination handler. +*/ +typedef int (*DD_THFP)(const void *); +/** + @brief Type of timeout handler. +*/ +typedef void (*DD_TOHFP)(DdManager *, void *); + +/*---------------------------------------------------------------------------*/ +/* Variable declarations */ +/*---------------------------------------------------------------------------*/ + + +/*---------------------------------------------------------------------------*/ +/* Macro declarations */ +/*---------------------------------------------------------------------------*/ + + +/** + @brief Complements a %DD. + + @details Complements a %DD by flipping the complement attribute of + the pointer (the least significant bit). + + @sideeffect none + + @see Cudd_NotCond + +*/ +#define Cudd_Not(node) ((DdNode *)((uintptr_t)(node) ^ (uintptr_t) 01)) + + +/** + @brief Complements a %DD if a condition is true. + + @details Complements a %DD if condition c is true; c should be + either 0 or 1, because it is used directly (for efficiency). If in + doubt on the values c may take, use "(c) ? Cudd_Not(node) : node". + + @sideeffect none + + @see Cudd_Not + +*/ +#define Cudd_NotCond(node,c) ((DdNode *)((uintptr_t)(node) ^ (uintptr_t) (c))) + + +/** + @brief Returns the regular version of a pointer. + + @details + + @sideeffect none + + @see Cudd_Complement Cudd_IsComplement + +*/ +#define Cudd_Regular(node) ((DdNode *)((uintptr_t)(node) & ~(uintptr_t) 01)) + + +/** + @brief Returns the complemented version of a pointer. + + @details + + @sideeffect none + + @see Cudd_Regular Cudd_IsComplement + +*/ +#define Cudd_Complement(node) ((DdNode *)((uintptr_t)(node) | (uintptr_t) 01)) + + +/** + @brief Returns 1 if a pointer is complemented. + + @details + + @sideeffect none + + @see Cudd_Regular Cudd_Complement + +*/ +#define Cudd_IsComplement(node) ((int) ((uintptr_t) (node) & (uintptr_t) 01)) + + +/** + @brief Returns the current position in the order of variable + index. + + @details Returns the current position in the order of variable + index. This macro is obsolete and is kept for compatibility. New + applications should use Cudd_ReadPerm instead. + + @sideeffect none + + @see Cudd_ReadPerm + +*/ +#define Cudd_ReadIndex(dd,index) (Cudd_ReadPerm(dd,index)) + + +/** + @brief Iterates over the cubes of a decision diagram. + + @details Iterates over the cubes of a decision diagram f. + <ul> + <li> DdManager *manager; + <li> DdNode *f; + <li> DdGen *gen; + <li> int *cube; + <li> CUDD_VALUE_TYPE value; + </ul> + Cudd_ForeachCube allocates and frees the generator. Therefore the + application should not try to do that. Also, the cube is freed at the + end of Cudd_ForeachCube and hence is not available outside of the loop.<p> + CAUTION: It is assumed that dynamic reordering will not occur while + there are open generators. It is the user's responsibility to make sure + that dynamic reordering does not occur. As long as new nodes are not created + during generation, and dynamic reordering is not called explicitly, + dynamic reordering will not occur. Alternatively, it is sufficient to + disable dynamic reordering. It is a mistake to dispose of a diagram + on which generation is ongoing. + + @sideeffect none + + @see Cudd_ForeachNode Cudd_FirstCube Cudd_NextCube Cudd_GenFree + Cudd_IsGenEmpty Cudd_AutodynDisable + +*/ +#define Cudd_ForeachCube(manager, f, gen, cube, value)\ + for((gen) = Cudd_FirstCube(manager, f, &cube, &value);\ + Cudd_IsGenEmpty(gen) ? Cudd_GenFree(gen) : CUDD_TRUE;\ + (void) Cudd_NextCube(gen, &cube, &value)) + + +/** + @brief Iterates over the primes of a Boolean function. + + @details Iterates over the primes of a Boolean function producing + a prime, but not necessarily irredundant, cover. + <ul> + <li> DdManager *manager; + <li> DdNode *l; + <li> DdNode *u; + <li> DdGen *gen; + <li> int *cube; + </ul> + The Boolean function is described by an upper bound and a lower bound. If + the function is completely specified, the two bounds coincide. + Cudd_ForeachPrime allocates and frees the generator. Therefore the + application should not try to do that. Also, the cube is freed at the + end of Cudd_ForeachPrime and hence is not available outside of the loop.<p> + CAUTION: It is a mistake to change a diagram on which generation is ongoing. + + @sideeffect none + + @see Cudd_ForeachCube Cudd_FirstPrime Cudd_NextPrime Cudd_GenFree + Cudd_IsGenEmpty + +*/ +#define Cudd_ForeachPrime(manager, l, u, gen, cube)\ + for((gen) = Cudd_FirstPrime(manager, l, u, &cube);\ + Cudd_IsGenEmpty(gen) ? Cudd_GenFree(gen) : CUDD_TRUE;\ + (void) Cudd_NextPrime(gen, &cube)) + + +/** + @brief Iterates over the nodes of a decision diagram. + + @details Iterates over the nodes of a decision diagram f. + <ul> + <li> DdManager *manager; + <li> DdNode *f; + <li> DdGen *gen; + <li> DdNode *node; + </ul> + The nodes are returned in a seemingly random order. + Cudd_ForeachNode allocates and frees the generator. Therefore the + application should not try to do that.<p> + CAUTION: It is assumed that dynamic reordering will not occur while + there are open generators. It is the user's responsibility to make sure + that dynamic reordering does not occur. As long as new nodes are not created + during generation, and dynamic reordering is not called explicitly, + dynamic reordering will not occur. Alternatively, it is sufficient to + disable dynamic reordering. It is a mistake to dispose of a diagram + on which generation is ongoing. + + @sideeffect none + + @see Cudd_ForeachCube Cudd_FirstNode Cudd_NextNode Cudd_GenFree + Cudd_IsGenEmpty Cudd_AutodynDisable + +*/ +#define Cudd_ForeachNode(manager, f, gen, node)\ + for((gen) = Cudd_FirstNode(manager, f, &node);\ + Cudd_IsGenEmpty(gen) ? Cudd_GenFree(gen) : CUDD_TRUE;\ + (void) Cudd_NextNode(gen, &node)) + + +/** + @brief Iterates over the paths of a %ZDD. + + @details Iterates over the paths of a %ZDD f. + <ul> + <li> DdManager *manager; + <li> DdNode *f; + <li> DdGen *gen; + <li> int *path; + </ul> + Cudd_zddForeachPath allocates and frees the generator. Therefore the + application should not try to do that. Also, the path is freed at the + end of Cudd_zddForeachPath and hence is not available outside of the loop.<p> + CAUTION: It is assumed that dynamic reordering will not occur while + there are open generators. It is the user's responsibility to make sure + that dynamic reordering does not occur. As long as new nodes are not created + during generation, and dynamic reordering is not called explicitly, + dynamic reordering will not occur. Alternatively, it is sufficient to + disable dynamic reordering. It is a mistake to dispose of a diagram + on which generation is ongoing. + + @sideeffect none + + @see Cudd_zddFirstPath Cudd_zddNextPath Cudd_GenFree + Cudd_IsGenEmpty Cudd_AutodynDisable + +*/ +#define Cudd_zddForeachPath(manager, f, gen, path)\ + for((gen) = Cudd_zddFirstPath(manager, f, &path);\ + Cudd_IsGenEmpty(gen) ? Cudd_GenFree(gen) : CUDD_TRUE;\ + (void) Cudd_zddNextPath(gen, &path)) + + + +/*---------------------------------------------------------------------------*/ +/* Function prototypes */ +/*---------------------------------------------------------------------------*/ + +#ifdef __cplusplus +extern "C" { +#endif + +extern DdNode * Cudd_addNewVar(DdManager *dd); +extern DdNode * Cudd_addNewVarAtLevel(DdManager *dd, int level); +extern DdNode * Cudd_bddNewVar(DdManager *dd); +extern DdNode * Cudd_bddNewVarAtLevel(DdManager *dd, int level); +extern int Cudd_bddIsVar(DdManager * dd, DdNode * f); +extern DdNode * Cudd_addIthVar(DdManager *dd, int i); +extern DdNode * Cudd_bddIthVar(DdManager *dd, int i); +extern DdNode * Cudd_zddIthVar(DdManager *dd, int i); +extern int Cudd_zddVarsFromBddVars(DdManager *dd, int multiplicity); +extern unsigned int Cudd_ReadMaxIndex(void); +extern DdNode * Cudd_addConst(DdManager *dd, CUDD_VALUE_TYPE c); +extern int Cudd_IsConstant(DdNode *node); +extern int Cudd_IsNonConstant(DdNode *f); +extern DdNode * Cudd_T(DdNode *node); +extern DdNode * Cudd_E(DdNode *node); +extern DdNode const * Cudd_T_const(DdNode const * node); +extern DdNode const * Cudd_E_const(DdNode const * node); +extern CUDD_VALUE_TYPE Cudd_V(DdNode const * node); +extern unsigned long Cudd_ReadStartTime(DdManager *unique); +extern unsigned long Cudd_ReadElapsedTime(DdManager *unique); +extern void Cudd_SetStartTime(DdManager *unique, unsigned long st); +extern void Cudd_ResetStartTime(DdManager *unique); +extern unsigned long Cudd_ReadTimeLimit(DdManager *unique); +extern unsigned long Cudd_SetTimeLimit(DdManager *unique, unsigned long tl); +extern void Cudd_UpdateTimeLimit(DdManager * unique); +extern void Cudd_IncreaseTimeLimit(DdManager * unique, unsigned long increase); +extern void Cudd_UnsetTimeLimit(DdManager *unique); +extern int Cudd_TimeLimited(DdManager *unique); +extern void Cudd_RegisterTerminationCallback(DdManager *unique, DD_THFP callback, void * callback_arg); +extern void Cudd_UnregisterTerminationCallback(DdManager *unique); +extern DD_OOMFP Cudd_RegisterOutOfMemoryCallback(DdManager *unique, DD_OOMFP callback); +extern void Cudd_UnregisterOutOfMemoryCallback(DdManager *unique); +extern void Cudd_RegisterTimeoutHandler(DdManager *unique, DD_TOHFP handler, void *arg); +extern DD_TOHFP Cudd_ReadTimeoutHandler(DdManager *unique, void **argp); +extern void Cudd_AutodynEnable(DdManager *unique, Cudd_ReorderingType method); +extern void Cudd_AutodynDisable(DdManager *unique); +extern int Cudd_ReorderingStatus(DdManager *unique, Cudd_ReorderingType *method); +extern void Cudd_AutodynEnableZdd(DdManager *unique, Cudd_ReorderingType method); +extern void Cudd_AutodynDisableZdd(DdManager *unique); +extern int Cudd_ReorderingStatusZdd(DdManager *unique, Cudd_ReorderingType *method); +extern int Cudd_zddRealignmentEnabled(DdManager *unique); +extern void Cudd_zddRealignEnable(DdManager *unique); +extern void Cudd_zddRealignDisable(DdManager *unique); +extern int Cudd_bddRealignmentEnabled(DdManager *unique); +extern void Cudd_bddRealignEnable(DdManager *unique); +extern void Cudd_bddRealignDisable(DdManager *unique); +extern DdNode * Cudd_ReadOne(DdManager *dd); +extern DdNode * Cudd_ReadZddOne(DdManager *dd, int i); +extern DdNode * Cudd_ReadZero(DdManager *dd); +extern DdNode * Cudd_ReadLogicZero(DdManager *dd); +extern DdNode * Cudd_ReadPlusInfinity(DdManager *dd); +extern DdNode * Cudd_ReadMinusInfinity(DdManager *dd); +extern DdNode * Cudd_ReadBackground(DdManager *dd); +extern void Cudd_SetBackground(DdManager *dd, DdNode *bck); +extern unsigned int Cudd_ReadCacheSlots(DdManager *dd); +extern double Cudd_ReadCacheUsedSlots(DdManager * dd); +extern double Cudd_ReadCacheLookUps(DdManager *dd); +extern double Cudd_ReadCacheHits(DdManager *dd); +extern double Cudd_ReadRecursiveCalls(DdManager * dd); +extern unsigned int Cudd_ReadMinHit(DdManager *dd); +extern void Cudd_SetMinHit(DdManager *dd, unsigned int hr); +extern unsigned int Cudd_ReadLooseUpTo(DdManager *dd); +extern void Cudd_SetLooseUpTo(DdManager *dd, unsigned int lut); +extern unsigned int Cudd_ReadMaxCache(DdManager *dd); +extern unsigned int Cudd_ReadMaxCacheHard(DdManager *dd); +extern void Cudd_SetMaxCacheHard(DdManager *dd, unsigned int mc); +extern int Cudd_ReadSize(DdManager *dd); +extern int Cudd_ReadZddSize(DdManager *dd); +extern unsigned int Cudd_ReadSlots(DdManager *dd); +extern double Cudd_ReadUsedSlots(DdManager * dd); +extern double Cudd_ExpectedUsedSlots(DdManager * dd); +extern unsigned int Cudd_ReadKeys(DdManager *dd); +extern unsigned int Cudd_ReadDead(DdManager *dd); +extern unsigned int Cudd_ReadMinDead(DdManager *dd); +extern unsigned int Cudd_ReadReorderings(DdManager *dd); +extern unsigned int Cudd_ReadMaxReorderings(DdManager *dd); +extern void Cudd_SetMaxReorderings(DdManager *dd, unsigned int mr); +extern long Cudd_ReadReorderingTime(DdManager * dd); +extern int Cudd_ReadGarbageCollections(DdManager * dd); +extern long Cudd_ReadGarbageCollectionTime(DdManager * dd); +extern double Cudd_ReadNodesFreed(DdManager * dd); +extern double Cudd_ReadNodesDropped(DdManager * dd); +extern double Cudd_ReadUniqueLookUps(DdManager * dd); +extern double Cudd_ReadUniqueLinks(DdManager * dd); +extern int Cudd_ReadSiftMaxVar(DdManager *dd); +extern void Cudd_SetSiftMaxVar(DdManager *dd, int smv); +extern int Cudd_ReadSiftMaxSwap(DdManager *dd); +extern void Cudd_SetSiftMaxSwap(DdManager *dd, int sms); +extern double Cudd_ReadMaxGrowth(DdManager *dd); +extern void Cudd_SetMaxGrowth(DdManager *dd, double mg); +extern double Cudd_ReadMaxGrowthAlternate(DdManager * dd); +extern void Cudd_SetMaxGrowthAlternate(DdManager * dd, double mg); +extern int Cudd_ReadReorderingCycle(DdManager * dd); +extern void Cudd_SetReorderingCycle(DdManager * dd, int cycle); +extern unsigned int Cudd_NodeReadIndex(DdNode const * node); +extern int Cudd_ReadPerm(DdManager *dd, int i); +extern int Cudd_ReadPermZdd(DdManager *dd, int i); +extern int Cudd_ReadInvPerm(DdManager *dd, int i); +extern int Cudd_ReadInvPermZdd(DdManager *dd, int i); +extern DdNode * Cudd_ReadVars(DdManager *dd, int i); +extern CUDD_VALUE_TYPE Cudd_ReadEpsilon(DdManager *dd); +extern void Cudd_SetEpsilon(DdManager *dd, CUDD_VALUE_TYPE ep); +extern Cudd_AggregationType Cudd_ReadGroupcheck(DdManager *dd); +extern void Cudd_SetGroupcheck(DdManager *dd, Cudd_AggregationType gc); +extern int Cudd_GarbageCollectionEnabled(DdManager *dd); +extern void Cudd_EnableGarbageCollection(DdManager *dd); +extern void Cudd_DisableGarbageCollection(DdManager *dd); +extern int Cudd_DeadAreCounted(DdManager *dd); +extern void Cudd_TurnOnCountDead(DdManager *dd); +extern void Cudd_TurnOffCountDead(DdManager *dd); +extern int Cudd_ReadRecomb(DdManager *dd); +extern void Cudd_SetRecomb(DdManager *dd, int recomb); +extern int Cudd_ReadSymmviolation(DdManager *dd); +extern void Cudd_SetSymmviolation(DdManager *dd, int symmviolation); +extern int Cudd_ReadArcviolation(DdManager *dd); +extern void Cudd_SetArcviolation(DdManager *dd, int arcviolation); +extern int Cudd_ReadPopulationSize(DdManager *dd); +extern void Cudd_SetPopulationSize(DdManager *dd, int populationSize); +extern int Cudd_ReadNumberXovers(DdManager *dd); +extern void Cudd_SetNumberXovers(DdManager *dd, int numberXovers); +extern unsigned int Cudd_ReadOrderRandomization(DdManager * dd); +extern void Cudd_SetOrderRandomization(DdManager * dd, unsigned int factor); +extern size_t Cudd_ReadMemoryInUse(DdManager *dd); +extern int Cudd_PrintInfo(DdManager *dd, FILE *fp); +extern long Cudd_ReadPeakNodeCount(DdManager *dd); +extern int Cudd_ReadPeakLiveNodeCount(DdManager * dd); +extern long Cudd_ReadNodeCount(DdManager *dd); +extern long Cudd_zddReadNodeCount(DdManager *dd); +extern int Cudd_AddHook(DdManager *dd, DD_HFP f, Cudd_HookType where); +extern int Cudd_RemoveHook(DdManager *dd, DD_HFP f, Cudd_HookType where); +extern int Cudd_IsInHook(DdManager * dd, DD_HFP f, Cudd_HookType where); +extern int Cudd_StdPreReordHook(DdManager *dd, const char *str, void *data); +extern int Cudd_StdPostReordHook(DdManager *dd, const char *str, void *data); +extern int Cudd_EnableReorderingReporting(DdManager *dd); +extern int Cudd_DisableReorderingReporting(DdManager *dd); +extern int Cudd_ReorderingReporting(DdManager *dd); +extern int Cudd_PrintGroupedOrder(DdManager * dd, const char *str, void *data); +extern int Cudd_EnableOrderingMonitoring(DdManager *dd); +extern int Cudd_DisableOrderingMonitoring(DdManager *dd); +extern int Cudd_OrderingMonitoring(DdManager *dd); +extern void Cudd_SetApplicationHook(DdManager *dd, void * value); +extern void * Cudd_ReadApplicationHook(DdManager *dd); +extern Cudd_ErrorType Cudd_ReadErrorCode(DdManager *dd); +extern void Cudd_ClearErrorCode(DdManager *dd); +extern DD_OOMFP Cudd_InstallOutOfMemoryHandler(DD_OOMFP newHandler); +extern FILE * Cudd_ReadStdout(DdManager *dd); +extern void Cudd_SetStdout(DdManager *dd, FILE *fp); +extern FILE * Cudd_ReadStderr(DdManager *dd); +extern void Cudd_SetStderr(DdManager *dd, FILE *fp); +extern unsigned int Cudd_ReadNextReordering(DdManager *dd); +extern void Cudd_SetNextReordering(DdManager *dd, unsigned int next); +extern double Cudd_ReadSwapSteps(DdManager *dd); +extern unsigned int Cudd_ReadMaxLive(DdManager *dd); +extern void Cudd_SetMaxLive(DdManager *dd, unsigned int maxLive); +extern size_t Cudd_ReadMaxMemory(DdManager *dd); +extern size_t Cudd_SetMaxMemory(DdManager *dd, size_t maxMemory); +extern int Cudd_bddBindVar(DdManager *dd, int index); +extern int Cudd_bddUnbindVar(DdManager *dd, int index); +extern int Cudd_bddVarIsBound(DdManager *dd, int index); +extern DdNode * Cudd_addExistAbstract(DdManager *manager, DdNode *f, DdNode *cube); +extern DdNode * Cudd_addUnivAbstract(DdManager *manager, DdNode *f, DdNode *cube); +extern DdNode * Cudd_addOrAbstract(DdManager *manager, DdNode *f, DdNode *cube); +extern DdNode * Cudd_addMinAbstract(DdManager * manager, DdNode * f, DdNode * cube); +extern DdNode * Cudd_addMaxAbstract(DdManager * manager, DdNode * f, DdNode * cube); +extern DdNode * Cudd_addApply(DdManager *dd, DD_AOP op, DdNode *f, DdNode *g); +extern DdNode * Cudd_addPlus(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addTimes(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addThreshold(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addSetNZ(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addDivide(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addMinus(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addMinimum(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addMaximum(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addOneZeroMaximum(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addDiff(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addAgreement(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addOr(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addNand(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addNor(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addXor(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addXnor(DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addEquals (DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addNotEquals (DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addGreaterThan (DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addGreaterThanEquals (DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addLessThan (DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addLessThanEquals (DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addPow (DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addMod (DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addLogXY (DdManager *dd, DdNode **f, DdNode **g); +extern DdNode * Cudd_addFloor (DdManager * dd, DdNode * f); +extern DdNode * Cudd_addCeil (DdManager * dd, DdNode * f); +extern DdNode * Cudd_addMonadicApply(DdManager * dd, DD_MAOP op, DdNode * f); +extern DdNode * Cudd_addLog(DdManager * dd, DdNode * f); +extern DdNode * Cudd_addFindMax(DdManager *dd, DdNode *f); +extern DdNode * Cudd_addFindMin(DdManager *dd, DdNode *f); +extern DdNode * Cudd_addIthBit(DdManager *dd, DdNode *f, int bit); +extern DdNode * Cudd_addScalarInverse(DdManager *dd, DdNode *f, DdNode *epsilon); +extern DdNode * Cudd_addIte(DdManager *dd, DdNode *f, DdNode *g, DdNode *h); +extern DdNode * Cudd_addIteConstant(DdManager *dd, DdNode *f, DdNode *g, DdNode *h); +extern DdNode * Cudd_addEvalConst(DdManager *dd, DdNode *f, DdNode *g); +extern int Cudd_addLeq(DdManager * dd, DdNode * f, DdNode * g); +extern DdNode * Cudd_addCmpl(DdManager *dd, DdNode *f); +extern DdNode * Cudd_addNegate(DdManager *dd, DdNode *f); +extern DdNode * Cudd_addRoundOff(DdManager *dd, DdNode *f, int N); +extern DdNode * Cudd_addWalsh(DdManager *dd, DdNode **x, DdNode **y, int n); +extern DdNode * Cudd_addResidue(DdManager *dd, int n, int m, int options, int top); +extern DdNode * Cudd_bddAndAbstract(DdManager *manager, DdNode *f, DdNode *g, DdNode *cube); +extern DdNode * Cudd_bddAndAbstractLimit(DdManager *manager, DdNode *f, DdNode *g, DdNode *cube, unsigned int limit); +extern int Cudd_ApaNumberOfDigits(int binaryDigits); +extern DdApaNumber Cudd_NewApaNumber(int digits); +extern void Cudd_FreeApaNumber(DdApaNumber number); +extern void Cudd_ApaCopy(int digits, DdConstApaNumber source, DdApaNumber dest); +extern DdApaDigit Cudd_ApaAdd(int digits, DdConstApaNumber a, DdConstApaNumber b, DdApaNumber sum); +extern DdApaDigit Cudd_ApaSubtract(int digits, DdConstApaNumber a, DdConstApaNumber b, DdApaNumber diff); +extern DdApaDigit Cudd_ApaShortDivision(int digits, DdConstApaNumber dividend, DdApaDigit divisor, DdApaNumber quotient); +extern unsigned int Cudd_ApaIntDivision(int digits, DdConstApaNumber dividend, unsigned int divisor, DdApaNumber quotient); +extern void Cudd_ApaShiftRight(int digits, DdApaDigit in, DdConstApaNumber a, DdApaNumber b); +extern void Cudd_ApaSetToLiteral(int digits, DdApaNumber number, DdApaDigit literal); +extern void Cudd_ApaPowerOfTwo(int digits, DdApaNumber number, int power); +extern int Cudd_ApaCompare(int digitsFirst, DdConstApaNumber first, int digitsSecond, DdConstApaNumber second); +extern int Cudd_ApaCompareRatios(int digitsFirst, DdConstApaNumber firstNum, unsigned int firstDen, int digitsSecond, DdConstApaNumber secondNum, unsigned int secondDen); +extern int Cudd_ApaPrintHex(FILE *fp, int digits, DdConstApaNumber number); +extern int Cudd_ApaPrintDecimal(FILE *fp, int digits, DdConstApaNumber number); +extern char * Cudd_ApaStringDecimal(int digits, DdConstApaNumber number); +extern int Cudd_ApaPrintExponential(FILE * fp, int digits, DdConstApaNumber number, int precision); +extern DdApaNumber Cudd_ApaCountMinterm(DdManager const *manager, DdNode *node, int nvars, int *digits); +extern int Cudd_ApaPrintMinterm(FILE *fp, DdManager const *dd, DdNode *node, int nvars); +extern int Cudd_ApaPrintMintermExp(FILE * fp, DdManager const * dd, DdNode *node, int nvars, int precision); +extern int Cudd_ApaPrintDensity(FILE * fp, DdManager * dd, DdNode * node, int nvars); +extern DdNode * Cudd_UnderApprox(DdManager *dd, DdNode *f, int numVars, int threshold, int safe, double quality); +extern DdNode * Cudd_OverApprox(DdManager *dd, DdNode *f, int numVars, int threshold, int safe, double quality); +extern DdNode * Cudd_RemapUnderApprox(DdManager *dd, DdNode *f, int numVars, int threshold, double quality); +extern DdNode * Cudd_RemapOverApprox(DdManager *dd, DdNode *f, int numVars, int threshold, double quality); +extern DdNode * Cudd_BiasedUnderApprox(DdManager *dd, DdNode *f, DdNode *b, int numVars, int threshold, double quality1, double quality0); +extern DdNode * Cudd_BiasedOverApprox(DdManager *dd, DdNode *f, DdNode *b, int numVars, int threshold, double quality1, double quality0); +extern DdNode * Cudd_bddExistAbstract(DdManager *manager, DdNode *f, DdNode *cube); +extern DdNode * Cudd_bddExistAbstractLimit(DdManager * manager, DdNode * f, DdNode * cube, unsigned int limit); +extern DdNode * Cudd_bddXorExistAbstract(DdManager *manager, DdNode *f, DdNode *g, DdNode *cube); +extern DdNode * Cudd_bddUnivAbstract(DdManager *manager, DdNode *f, DdNode *cube); +extern DdNode * Cudd_bddBooleanDiff(DdManager *manager, DdNode *f, int x); +extern int Cudd_bddVarIsDependent(DdManager *dd, DdNode *f, DdNode *var); +extern double Cudd_bddCorrelation(DdManager *manager, DdNode *f, DdNode *g); +extern double Cudd_bddCorrelationWeights(DdManager *manager, DdNode *f, DdNode *g, double *prob); +extern DdNode * Cudd_bddIte(DdManager *dd, DdNode *f, DdNode *g, DdNode *h); +extern DdNode * Cudd_bddIteLimit(DdManager *dd, DdNode *f, DdNode *g, DdNode *h, unsigned int limit); +extern DdNode * Cudd_bddIteConstant(DdManager *dd, DdNode *f, DdNode *g, DdNode *h); +extern DdNode * Cudd_bddIntersect(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_bddAnd(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_bddAndLimit(DdManager *dd, DdNode *f, DdNode *g, unsigned int limit); +extern DdNode * Cudd_bddOr(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_bddOrLimit(DdManager *dd, DdNode *f, DdNode *g, unsigned int limit); +extern DdNode * Cudd_bddNand(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_bddNor(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_bddXor(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_bddXnor(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_bddXnorLimit(DdManager *dd, DdNode *f, DdNode *g, unsigned int limit); +extern int Cudd_bddLeq(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_addBddThreshold(DdManager *dd, DdNode *f, CUDD_VALUE_TYPE value); +extern DdNode * Cudd_addBddStrictThreshold(DdManager *dd, DdNode *f, CUDD_VALUE_TYPE value); +extern DdNode * Cudd_addBddInterval(DdManager *dd, DdNode *f, CUDD_VALUE_TYPE lower, CUDD_VALUE_TYPE upper); +extern DdNode * Cudd_addBddIthBit(DdManager *dd, DdNode *f, int bit); +extern DdNode * Cudd_BddToAdd(DdManager *dd, DdNode *B); +extern DdNode * Cudd_addBddPattern(DdManager *dd, DdNode *f); +extern DdNode * Cudd_bddTransfer(DdManager *ddSource, DdManager *ddDestination, DdNode *f); +extern int Cudd_DebugCheck(DdManager *table); +extern int Cudd_CheckKeys(DdManager *table); +extern DdNode * Cudd_bddClippingAnd(DdManager *dd, DdNode *f, DdNode *g, int maxDepth, int direction); +extern DdNode * Cudd_bddClippingAndAbstract(DdManager *dd, DdNode *f, DdNode *g, DdNode *cube, int maxDepth, int direction); +extern DdNode * Cudd_Cofactor(DdManager *dd, DdNode *f, DdNode *g); +extern int Cudd_CheckCube(DdManager *dd, DdNode *g); +extern int Cudd_VarsAreSymmetric(DdManager * dd, DdNode * f, int index1, int index2); +extern DdNode * Cudd_bddCompose(DdManager *dd, DdNode *f, DdNode *g, int v); +extern DdNode * Cudd_addCompose(DdManager *dd, DdNode *f, DdNode *g, int v); +extern DdNode * Cudd_addPermute(DdManager *manager, DdNode *node, int *permut); +extern DdNode * Cudd_addSwapVariables(DdManager *dd, DdNode *f, DdNode **x, DdNode **y, int n); +extern DdNode * Cudd_bddPermute(DdManager *manager, DdNode *node, int *permut); +extern DdNode * Cudd_bddVarMap(DdManager *manager, DdNode *f); +extern int Cudd_SetVarMap(DdManager *manager, DdNode **x, DdNode **y, int n); +extern DdNode * Cudd_bddSwapVariables(DdManager *dd, DdNode *f, DdNode **x, DdNode **y, int n); +extern DdNode * Cudd_bddAdjPermuteX(DdManager *dd, DdNode *B, DdNode **x, int n); +extern DdNode * Cudd_addVectorCompose(DdManager *dd, DdNode *f, DdNode **vector); +extern DdNode * Cudd_addGeneralVectorCompose(DdManager *dd, DdNode *f, DdNode **vectorOn, DdNode **vectorOff); +extern DdNode * Cudd_addNonSimCompose(DdManager *dd, DdNode *f, DdNode **vector); +extern DdNode * Cudd_bddVectorCompose(DdManager *dd, DdNode *f, DdNode **vector); +extern int Cudd_bddApproxConjDecomp(DdManager *dd, DdNode *f, DdNode ***conjuncts); +extern int Cudd_bddApproxDisjDecomp(DdManager *dd, DdNode *f, DdNode ***disjuncts); +extern int Cudd_bddIterConjDecomp(DdManager *dd, DdNode *f, DdNode ***conjuncts); +extern int Cudd_bddIterDisjDecomp(DdManager *dd, DdNode *f, DdNode ***disjuncts); +extern int Cudd_bddGenConjDecomp(DdManager *dd, DdNode *f, DdNode ***conjuncts); +extern int Cudd_bddGenDisjDecomp(DdManager *dd, DdNode *f, DdNode ***disjuncts); +extern int Cudd_bddVarConjDecomp(DdManager *dd, DdNode * f, DdNode ***conjuncts); +extern int Cudd_bddVarDisjDecomp(DdManager *dd, DdNode * f, DdNode ***disjuncts); +extern DdNode * Cudd_FindEssential(DdManager *dd, DdNode *f); +extern int Cudd_bddIsVarEssential(DdManager *manager, DdNode *f, int id, int phase); +extern DdTlcInfo * Cudd_FindTwoLiteralClauses(DdManager * dd, DdNode * f); +extern int Cudd_PrintTwoLiteralClauses(DdManager * dd, DdNode * f, char **names, FILE *fp); +extern int Cudd_ReadIthClause(DdTlcInfo * tlc, int i, unsigned *var1, unsigned *var2, int *phase1, int *phase2); +extern void Cudd_tlcInfoFree(DdTlcInfo * t); +extern int Cudd_DumpBlif(DdManager *dd, int n, DdNode **f, char const * const *inames, char const * const *onames, char *mname, FILE *fp, int mv); +extern int Cudd_DumpBlifBody(DdManager *dd, int n, DdNode **f, char const * const *inames, char const * const *onames, FILE *fp, int mv); +extern int Cudd_DumpDot(DdManager *dd, int n, DdNode **f, char const * const *inames, char const * const *onames, FILE *fp); +extern int Cudd_DumpDaVinci(DdManager *dd, int n, DdNode **f, char const * const *inames, char const * const *onames, FILE *fp); +extern int Cudd_DumpDDcal(DdManager *dd, int n, DdNode **f, char const * const *inames, char const * const *onames, FILE *fp); +extern int Cudd_DumpFactoredForm(DdManager *dd, int n, DdNode **f, char const * const *inames, char const * const *onames, FILE *fp); +extern char * Cudd_FactoredFormString(DdManager *dd, DdNode *f, char const * const * inames); +extern DdNode * Cudd_bddConstrain(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode * Cudd_bddRestrict(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode * Cudd_bddNPAnd(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode * Cudd_addConstrain(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode ** Cudd_bddConstrainDecomp(DdManager *dd, DdNode *f); +extern DdNode * Cudd_addRestrict(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode ** Cudd_bddCharToVect(DdManager *dd, DdNode *f); +extern DdNode * Cudd_bddLICompaction(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode * Cudd_bddSqueeze(DdManager *dd, DdNode *l, DdNode *u); +extern DdNode * Cudd_bddInterpolate(DdManager * dd, DdNode * l, DdNode * u); +extern DdNode * Cudd_bddMinimize(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode * Cudd_SubsetCompress(DdManager *dd, DdNode *f, int nvars, int threshold); +extern DdNode * Cudd_SupersetCompress(DdManager *dd, DdNode *f, int nvars, int threshold); +extern int Cudd_addHarwell(FILE *fp, DdManager *dd, DdNode **E, DdNode ***x, DdNode ***y, DdNode ***xn, DdNode ***yn_, int *nx, int *ny, int *m, int *n, int bx, int sx, int by, int sy, int pr); +extern DdManager * Cudd_Init(unsigned int numVars, unsigned int numVarsZ, unsigned int numSlots, unsigned int cacheSize, size_t maxMemory); +extern void Cudd_Quit(DdManager *unique); +extern int Cudd_PrintLinear(DdManager *table); +extern int Cudd_ReadLinear(DdManager *table, int x, int y); +extern DdNode * Cudd_bddLiteralSetIntersection(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_addMatrixMultiply(DdManager *dd, DdNode *A, DdNode *B, DdNode **z, int nz); +extern DdNode * Cudd_addTimesPlus(DdManager *dd, DdNode *A, DdNode *B, DdNode **z, int nz); +extern DdNode * Cudd_addTriangle(DdManager *dd, DdNode *f, DdNode *g, DdNode **z, int nz); +extern DdNode * Cudd_addOuterSum(DdManager *dd, DdNode *M, DdNode *r, DdNode *c); +extern DdNode * Cudd_PrioritySelect(DdManager *dd, DdNode *R, DdNode **x, DdNode **y, DdNode **z, DdNode *Pi, int n, DD_PRFP PiFunc); +extern DdNode * Cudd_Xgty(DdManager *dd, int N, DdNode **z, DdNode **x, DdNode **y); +extern DdNode * Cudd_Xeqy(DdManager *dd, int N, DdNode **x, DdNode **y); +extern DdNode * Cudd_addXeqy(DdManager *dd, int N, DdNode **x, DdNode **y); +extern DdNode * Cudd_Dxygtdxz(DdManager *dd, int N, DdNode **x, DdNode **y, DdNode **z); +extern DdNode * Cudd_Dxygtdyz(DdManager *dd, int N, DdNode **x, DdNode **y, DdNode **z); +extern DdNode * Cudd_Inequality(DdManager * dd, int N, int c, DdNode ** x, DdNode ** y); +extern DdNode * Cudd_Disequality(DdManager * dd, int N, int c, DdNode ** x, DdNode ** y); +extern DdNode * Cudd_bddInterval(DdManager * dd, int N, DdNode ** x, unsigned int lowerB, unsigned int upperB); +extern DdNode * Cudd_CProjection(DdManager *dd, DdNode *R, DdNode *Y); +extern DdNode * Cudd_addHamming(DdManager *dd, DdNode **xVars, DdNode **yVars, int nVars); +extern int Cudd_MinHammingDist(DdManager *dd, DdNode *f, int *minterm, int upperBound); +extern DdNode * Cudd_bddClosestCube(DdManager *dd, DdNode * f, DdNode *g, int *distance); +extern int Cudd_addRead(FILE *fp, DdManager *dd, DdNode **E, DdNode ***x, DdNode ***y, DdNode ***xn, DdNode ***yn_, int *nx, int *ny, int *m, int *n, int bx, int sx, int by, int sy); +extern int Cudd_bddRead(FILE *fp, DdManager *dd, DdNode **E, DdNode ***x, DdNode ***y, int *nx, int *ny, int *m, int *n, int bx, int sx, int by, int sy); +extern void Cudd_Ref(DdNode *n); +extern void Cudd_RecursiveDeref(DdManager *table, DdNode *n); +extern void Cudd_IterDerefBdd(DdManager *table, DdNode *n); +extern void Cudd_DelayedDerefBdd(DdManager * table, DdNode * n); +extern void Cudd_RecursiveDerefZdd(DdManager *table, DdNode *n); +extern void Cudd_Deref(DdNode *node); +extern int Cudd_CheckZeroRef(DdManager *manager); +extern int Cudd_ReduceHeap(DdManager *table, Cudd_ReorderingType heuristic, int minsize); +extern int Cudd_ShuffleHeap(DdManager *table, int *permutation); +extern DdNode * Cudd_Eval(DdManager *dd, DdNode *f, int *inputs); +extern DdNode * Cudd_ShortestPath(DdManager *manager, DdNode *f, int *weight, int *support, int *length); +extern DdNode * Cudd_LargestCube(DdManager *manager, DdNode *f, int *length); +extern int Cudd_ShortestLength(DdManager *manager, DdNode *f, int *weight); +extern DdNode * Cudd_Decreasing(DdManager *dd, DdNode *f, int i); +extern DdNode * Cudd_Increasing(DdManager *dd, DdNode *f, int i); +extern int Cudd_EquivDC(DdManager *dd, DdNode *F, DdNode *G, DdNode *D); +extern int Cudd_bddLeqUnless(DdManager *dd, DdNode *f, DdNode *g, DdNode *D); +extern int Cudd_EqualSupNorm(DdManager *dd, DdNode *f, DdNode *g, CUDD_VALUE_TYPE tolerance, int pr); +extern int Cudd_EqualSupNormRel (DdManager *dd, DdNode *f, DdNode *g, CUDD_VALUE_TYPE tolerance, int pr); +extern DdNode * Cudd_bddMakePrime(DdManager *dd, DdNode *cube, DdNode *f); +extern DdNode * Cudd_bddMaximallyExpand(DdManager *dd, DdNode *lb, DdNode *ub, DdNode *f); +extern DdNode * Cudd_bddLargestPrimeUnate(DdManager *dd , DdNode *f, DdNode *phaseBdd); +extern double * Cudd_CofMinterm(DdManager *dd, DdNode *node); +extern DdNode * Cudd_SolveEqn(DdManager * bdd, DdNode *F, DdNode *Y, DdNode **G, int **yIndex, int n); +extern DdNode * Cudd_VerifySol(DdManager * bdd, DdNode *F, DdNode **G, int *yIndex, int n); +extern DdNode * Cudd_SplitSet(DdManager *manager, DdNode *S, DdNode **xVars, int n, double m); +extern DdNode * Cudd_SubsetHeavyBranch(DdManager *dd, DdNode *f, int numVars, int threshold); +extern DdNode * Cudd_SupersetHeavyBranch(DdManager *dd, DdNode *f, int numVars, int threshold); +extern DdNode * Cudd_SubsetShortPaths(DdManager *dd, DdNode *f, int numVars, int threshold, int hardlimit); +extern DdNode * Cudd_SupersetShortPaths(DdManager *dd, DdNode *f, int numVars, int threshold, int hardlimit); +extern void Cudd_SymmProfile(DdManager *table, int lower, int upper); +extern unsigned int Cudd_Prime(unsigned int p); +extern int Cudd_Reserve(DdManager *manager, int amount); +extern int Cudd_PrintMinterm(DdManager *manager, DdNode *node); +extern int Cudd_bddPrintCover(DdManager *dd, DdNode *l, DdNode *u); +extern int Cudd_PrintDebug(DdManager *dd, DdNode *f, int n, int pr); +extern int Cudd_PrintSummary(DdManager * dd, DdNode * f, int n, int mode); +extern int Cudd_DagSize(DdNode *node); +extern int Cudd_EstimateCofactor(DdManager *dd, DdNode * node, int i, int phase); +extern int Cudd_EstimateCofactorSimple(DdNode * node, int i); +extern int Cudd_SharingSize(DdNode **nodeArray, int n); +extern double Cudd_CountMinterm(DdManager *manager, DdNode *node, int nvars); +#ifdef EPD_H_ +extern int Cudd_EpdCountMinterm(DdManager const *manager, DdNode *node, int nvars, EpDouble *epd); +#endif +extern long double Cudd_LdblCountMinterm(DdManager const *manager, DdNode *node, int nvars); +extern int Cudd_EpdPrintMinterm(DdManager const * dd, DdNode * node, int nvars); +extern double Cudd_CountPath(DdNode *node); +extern double Cudd_CountPathsToNonZero(DdNode *node); +extern int Cudd_SupportIndices(DdManager * dd, DdNode * f, int **indices); +extern DdNode * Cudd_Support(DdManager *dd, DdNode *f); +extern int * Cudd_SupportIndex(DdManager *dd, DdNode *f); +extern int Cudd_SupportSize(DdManager *dd, DdNode *f); +extern int Cudd_VectorSupportIndices(DdManager * dd, DdNode ** F, int n, int **indices); +extern DdNode * Cudd_VectorSupport(DdManager *dd, DdNode **F, int n); +extern int * Cudd_VectorSupportIndex(DdManager *dd, DdNode **F, int n); +extern int Cudd_VectorSupportSize(DdManager *dd, DdNode **F, int n); +extern int Cudd_ClassifySupport(DdManager *dd, DdNode *f, DdNode *g, DdNode **common, DdNode **onlyF, DdNode **onlyG); +extern int Cudd_CountLeaves(DdNode *node); +extern int Cudd_bddPickOneCube(DdManager *ddm, DdNode *node, char *string); +extern DdNode * Cudd_bddPickOneMinterm(DdManager *dd, DdNode *f, DdNode **vars, int n); +extern DdNode ** Cudd_bddPickArbitraryMinterms(DdManager *dd, DdNode *f, DdNode **vars, int n, int k); +extern DdNode * Cudd_SubsetWithMaskVars(DdManager *dd, DdNode *f, DdNode **vars, int nvars, DdNode **maskVars, int mvars); +extern DdGen * Cudd_FirstCube(DdManager *dd, DdNode *f, int **cube, CUDD_VALUE_TYPE *value); +extern int Cudd_NextCube(DdGen *gen, int **cube, CUDD_VALUE_TYPE *value); +extern DdGen * Cudd_FirstPrime(DdManager *dd, DdNode *l, DdNode *u, int **cube); +extern int Cudd_NextPrime(DdGen *gen, int **cube); +extern DdNode * Cudd_bddComputeCube(DdManager *dd, DdNode **vars, int *phase, int n); +extern DdNode * Cudd_addComputeCube(DdManager *dd, DdNode **vars, int *phase, int n); +extern DdNode * Cudd_CubeArrayToBdd(DdManager *dd, int *array); +extern int Cudd_BddToCubeArray(DdManager *dd, DdNode *cube, int *array); +extern DdGen * Cudd_FirstNode(DdManager *dd, DdNode *f, DdNode **node); +extern int Cudd_NextNode(DdGen *gen, DdNode **node); +extern int Cudd_GenFree(DdGen *gen); +extern int Cudd_IsGenEmpty(DdGen *gen); +extern DdNode * Cudd_IndicesToCube(DdManager *dd, int *array, int n); +extern void Cudd_PrintVersion(FILE *fp); +extern double Cudd_AverageDistance(DdManager *dd); +extern int32_t Cudd_Random(DdManager * dd); +extern void Cudd_Srandom(DdManager * dd, int32_t seed); +extern double Cudd_Density(DdManager *dd, DdNode *f, int nvars); +extern void Cudd_OutOfMem(size_t size); +extern void Cudd_OutOfMemSilent(size_t size); +extern int Cudd_zddCount(DdManager *zdd, DdNode *P); +extern double Cudd_zddCountDouble(DdManager *zdd, DdNode *P); +extern DdNode * Cudd_zddProduct(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_zddUnateProduct(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_zddWeakDiv(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_zddDivide(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_zddWeakDivF(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_zddDivideF(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * Cudd_zddComplement(DdManager *dd, DdNode *node); +extern DdNode * Cudd_zddIsop(DdManager *dd, DdNode *L, DdNode *U, DdNode **zdd_I); +extern DdNode * Cudd_bddIsop(DdManager *dd, DdNode *L, DdNode *U); +extern DdNode * Cudd_MakeBddFromZddCover(DdManager *dd, DdNode *node); +extern int Cudd_zddDagSize(DdNode *p_node); +extern double Cudd_zddCountMinterm(DdManager *zdd, DdNode *node, int path); +extern void Cudd_zddPrintSubtable(DdManager *table); +extern DdNode * Cudd_zddPortFromBdd(DdManager *dd, DdNode *B); +extern DdNode * Cudd_zddPortToBdd(DdManager *dd, DdNode *f); +extern int Cudd_zddReduceHeap(DdManager *table, Cudd_ReorderingType heuristic, int minsize); +extern int Cudd_zddShuffleHeap(DdManager *table, int *permutation); +extern DdNode * Cudd_zddIte(DdManager *dd, DdNode *f, DdNode *g, DdNode *h); +extern DdNode * Cudd_zddUnion(DdManager *dd, DdNode *P, DdNode *Q); +extern DdNode * Cudd_zddIntersect(DdManager *dd, DdNode *P, DdNode *Q); +extern DdNode * Cudd_zddDiff(DdManager *dd, DdNode *P, DdNode *Q); +extern DdNode * Cudd_zddDiffConst(DdManager *zdd, DdNode *P, DdNode *Q); +extern DdNode * Cudd_zddSubset1(DdManager *dd, DdNode *P, int var); +extern DdNode * Cudd_zddSubset0(DdManager *dd, DdNode *P, int var); +extern DdNode * Cudd_zddChange(DdManager *dd, DdNode *P, int var); +extern void Cudd_zddSymmProfile(DdManager *table, int lower, int upper); +extern int Cudd_zddPrintMinterm(DdManager *zdd, DdNode *node); +extern int Cudd_zddPrintCover(DdManager *zdd, DdNode *node); +extern int Cudd_zddPrintDebug(DdManager *zdd, DdNode *f, int n, int pr); +extern DdGen * Cudd_zddFirstPath(DdManager *zdd, DdNode *f, int **path); +extern int Cudd_zddNextPath(DdGen *gen, int **path); +extern char * Cudd_zddCoverPathToString(DdManager *zdd, int *path, char *str); +extern DdNode * Cudd_zddSupport(DdManager * dd, DdNode * f); +extern int Cudd_zddDumpDot(DdManager *dd, int n, DdNode **f, char const * const *inames, char const * const *onames, FILE *fp); +extern int Cudd_bddSetPiVar(DdManager *dd, int index); +extern int Cudd_bddSetPsVar(DdManager *dd, int index); +extern int Cudd_bddSetNsVar(DdManager *dd, int index); +extern int Cudd_bddIsPiVar(DdManager *dd, int index); +extern int Cudd_bddIsPsVar(DdManager *dd, int index); +extern int Cudd_bddIsNsVar(DdManager *dd, int index); +extern int Cudd_bddSetPairIndex(DdManager *dd, int index, int pairIndex); +extern int Cudd_bddReadPairIndex(DdManager *dd, int index); +extern int Cudd_bddSetVarToBeGrouped(DdManager *dd, int index); +extern int Cudd_bddSetVarHardGroup(DdManager *dd, int index); +extern int Cudd_bddResetVarToBeGrouped(DdManager *dd, int index); +extern int Cudd_bddIsVarToBeGrouped(DdManager *dd, int index); +extern int Cudd_bddSetVarToBeUngrouped(DdManager *dd, int index); +extern int Cudd_bddIsVarToBeUngrouped(DdManager *dd, int index); +extern int Cudd_bddIsVarHardGroup(DdManager *dd, int index); +#ifdef MTR_H_ +extern MtrNode * Cudd_ReadTree(DdManager *dd); +extern void Cudd_SetTree(DdManager *dd, MtrNode *tree); +extern void Cudd_FreeTree(DdManager *dd); +extern MtrNode * Cudd_ReadZddTree(DdManager *dd); +extern void Cudd_SetZddTree(DdManager *dd, MtrNode *tree); +extern void Cudd_FreeZddTree(DdManager *dd); +extern MtrNode * Cudd_MakeTreeNode(DdManager *dd, unsigned int low, unsigned int size, unsigned int type); +extern MtrNode * Cudd_MakeZddTreeNode(DdManager *dd, unsigned int low, unsigned int size, unsigned int type); +#endif + +#ifdef __cplusplus +} /* end of extern "C" */ +#endif + +#endif /* CUDD_H_ */ diff --git a/resources/3rdparty/cudd-3.0.0/cudd/cuddAPI.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddAPI.c new file mode 100644 index 000000000..78214567e --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddAPI.c @@ -0,0 +1,4808 @@ +/** + @file + + @ingroup cudd + + @brief Application interface functions. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" +#include "mtrInt.h" +#include "cuddInt.h" + +/*---------------------------------------------------------------------------*/ +/* Constant declarations */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Stucture declarations */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Type declarations */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Variable declarations */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Macro declarations */ +/*---------------------------------------------------------------------------*/ + +/** \cond */ + +/*---------------------------------------------------------------------------*/ +/* Static function prototypes */ +/*---------------------------------------------------------------------------*/ + +static void fixVarTree (MtrNode *treenode, int *perm, int size); +static int addMultiplicityGroups (DdManager *dd, MtrNode *treenode, int multiplicity, char *vmask, char *lmask); + +/** \endcond */ + + + +/*---------------------------------------------------------------------------*/ +/* Definition of exported functions */ +/*---------------------------------------------------------------------------*/ + + +/** + @brief Returns a new %ADD variable. + + @details The new variable has an index equal to the largest previous + index plus 1. An %ADD variable differs from a %BDD variable because + it points to the arithmetic zero, instead of having a complement + pointer to 1. + + @return a pointer to the new variable if successful; NULL otherwise. + + @sideeffect None + + @see Cudd_bddNewVar Cudd_addIthVar Cudd_addConst + Cudd_addNewVarAtLevel + +*/ +DdNode * +Cudd_addNewVar( + DdManager * dd) +{ + DdNode *res; + + if ((unsigned int) dd->size >= CUDD_MAXINDEX - 1) { + dd->errorCode = CUDD_INVALID_ARG; + return(NULL); + } + do { + dd->reordered = 0; + res = cuddUniqueInter(dd,dd->size,DD_ONE(dd),DD_ZERO(dd)); + } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + + return(res); + +} /* end of Cudd_addNewVar */ + + +/** + @brief Returns a new %ADD variable at a specified level. + + @details The new variable has an index equal to the largest previous + index plus 1 and is positioned at the specified level in the order. + + @return a pointer to the new variable if successful; NULL otherwise. + + @sideeffect None + + @see Cudd_addNewVar Cudd_addIthVar Cudd_bddNewVarAtLevel + +*/ +DdNode * +Cudd_addNewVarAtLevel( + DdManager * dd, + int level) +{ + DdNode *res; + + if ((unsigned int) dd->size >= CUDD_MAXINDEX - 1) { + dd->errorCode = CUDD_INVALID_ARG; + return(NULL); + } + if (level >= dd->size) return(Cudd_addIthVar(dd,level)); + if (!cuddInsertSubtables(dd,1,level)) return(NULL); + do { + dd->reordered = 0; + res = cuddUniqueInter(dd,dd->size - 1,DD_ONE(dd),DD_ZERO(dd)); + } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + + return(res); + +} /* end of Cudd_addNewVarAtLevel */ + + +/** + @brief Returns a new %BDD variable. + + @details The new variable has an index equal to the largest previous + index plus 1. + + @return a pointer to the new variable if successful; NULL otherwise. + + @sideeffect None + + @see Cudd_addNewVar Cudd_bddIthVar Cudd_bddNewVarAtLevel + +*/ +DdNode * +Cudd_bddNewVar( + DdManager * dd) +{ + DdNode *res; + + if ((unsigned int) dd->size >= CUDD_MAXINDEX - 1) { + dd->errorCode = CUDD_INVALID_ARG; + return(NULL); + } + res = cuddUniqueInter(dd,dd->size,dd->one,Cudd_Not(dd->one)); + + return(res); + +} /* end of Cudd_bddNewVar */ + + +/** + @brief Returns a new %BDD variable at a specified level. + + @details The new variable has an index equal to the largest previous + index plus 1 and is positioned at the specified level in the order. + + @return a pointer to the new variable if successful; NULL otherwise. + + @sideeffect None + + @see Cudd_bddNewVar Cudd_bddIthVar Cudd_addNewVarAtLevel + +*/ +DdNode * +Cudd_bddNewVarAtLevel( + DdManager * dd, + int level) +{ + DdNode *res; + + if ((unsigned int) dd->size >= CUDD_MAXINDEX - 1) { + dd->errorCode = CUDD_INVALID_ARG; + return(NULL); + } + if (level >= dd->size) return(Cudd_bddIthVar(dd,level)); + if (!cuddInsertSubtables(dd,1,level)) return(NULL); + res = dd->vars[dd->size - 1]; + + return(res); + +} /* end of Cudd_bddNewVarAtLevel */ + + +/** + @brief Returns 1 if the given node is a %BDD variable; 0 otherwise. + + @sideeffect None + +*/ +int +Cudd_bddIsVar( + DdManager * dd, + DdNode * f) +{ + DdNode *one = DD_ONE(dd); + return(f != 0 && cuddT(f) == one && cuddE(f) == Cudd_Not(one)); + +} /* end of Cudd_bddIsVar */ + + +/** + @brief Returns the %ADD variable with index i. + + @details Retrieves the %ADD variable with index i if it already + exists, or creates a new %ADD variable. An %ADD variable differs from + a %BDD variable because it points to the arithmetic zero, instead of + having a complement pointer to 1. + + @return a pointer to the variable if successful; NULL otherwise. + + @sideeffect None + + @see Cudd_addNewVar Cudd_bddIthVar Cudd_addConst + Cudd_addNewVarAtLevel + +*/ +DdNode * +Cudd_addIthVar( + DdManager * dd, + int i) +{ + DdNode *res; + + if ((unsigned int) i >= CUDD_MAXINDEX - 1) { + dd->errorCode = CUDD_INVALID_ARG; + return(NULL); + } + do { + dd->reordered = 0; + res = cuddUniqueInter(dd,i,DD_ONE(dd),DD_ZERO(dd)); + } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + + return(res); + +} /* end of Cudd_addIthVar */ + + +/** + @brief Returns the %BDD variable with index i. + + @details Retrieves the %BDD variable with index i if it already + exists, or creates a new %BDD variable. + + @return a pointer to the variable if successful; NULL otherwise. + + @sideeffect None + + @see Cudd_bddNewVar Cudd_addIthVar Cudd_bddNewVarAtLevel + Cudd_ReadVars + +*/ +DdNode * +Cudd_bddIthVar( + DdManager * dd, + int i) +{ + DdNode *res; + + if ((unsigned int) i >= CUDD_MAXINDEX - 1) { + dd->errorCode = CUDD_INVALID_ARG; + return(NULL); + } + if (i < dd->size) { + res = dd->vars[i]; + } else { + res = cuddUniqueInter(dd,i,dd->one,Cudd_Not(dd->one)); + } + + return(res); + +} /* end of Cudd_bddIthVar */ + + +/** + @brief Returns the %ZDD variable with index i. + + @details Retrieves the %ZDD variable with index i if it already + exists, or creates a new %ZDD variable. + + @return a pointer to the variable if successful; NULL otherwise. + + @sideeffect None + + @see Cudd_bddIthVar Cudd_addIthVar + +*/ +DdNode * +Cudd_zddIthVar( + DdManager * dd, + int i) +{ + DdNode *res; + DdNode *zvar; + DdNode *lower; + int j; + + if ((unsigned int) i >= CUDD_MAXINDEX - 1) { + dd->errorCode = CUDD_INVALID_ARG; + return(NULL); + } + /* The i-th variable function has the following structure: + ** at the level corresponding to index i there is a node whose "then" + ** child points to the universe, and whose "else" child points to zero. + ** Above that level there are nodes with identical children. + */ + + /* First we build the node at the level of index i. */ + lower = (i < dd->sizeZ - 1) ? dd->univ[dd->permZ[i]+1] : DD_ONE(dd); + do { + dd->reordered = 0; + zvar = cuddUniqueInterZdd(dd, i, lower, DD_ZERO(dd)); + } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + + if (zvar == NULL) + return(NULL); + cuddRef(zvar); + + /* Now we add the "filler" nodes above the level of index i. */ + for (j = dd->permZ[i] - 1; j >= 0; j--) { + do { + dd->reordered = 0; + res = cuddUniqueInterZdd(dd, dd->invpermZ[j], zvar, zvar); + } while (dd->reordered == 1); + if (res == NULL) { + Cudd_RecursiveDerefZdd(dd,zvar); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(NULL); + } + cuddRef(res); + Cudd_RecursiveDerefZdd(dd,zvar); + zvar = res; + } + cuddDeref(zvar); + return(zvar); + +} /* end of Cudd_zddIthVar */ + + +/** + @brief Creates one or more %ZDD variables for each %BDD variable. + + @details If some %ZDD variables already exist, only the missing + variables are created. Parameter multiplicity allows the caller to + control how many variables are created for each %BDD variable in + existence. For instance, if ZDDs are used to represent covers, two + %ZDD variables are required for each %BDD variable. The order of the + %BDD variables is transferred to the %ZDD variables. If a variable + group tree exists for the %BDD variables, a corresponding %ZDD + variable group tree is created by expanding the %BDD variable + tree. In any case, the %ZDD variables derived from the same %BDD + variable are merged in a %ZDD variable group. If a %ZDD variable group + tree exists, it is freed. + + @return 1 if successful; 0 otherwise. + + @sideeffect None + + @see Cudd_bddNewVar Cudd_bddIthVar Cudd_bddNewVarAtLevel + +*/ +int +Cudd_zddVarsFromBddVars( + DdManager * dd /**< %DD manager */, + int multiplicity /**< how many %ZDD variables are created for each %BDD variable */) +{ + int res; + int i, j; + int allnew; + int *permutation; + + if (multiplicity < 1) { + dd->errorCode = CUDD_INVALID_ARG; + return(0); + } + allnew = dd->sizeZ == 0; + if (dd->size * multiplicity > dd->sizeZ) { + res = cuddResizeTableZdd(dd,dd->size * multiplicity - 1); + if (res == 0) return(0); + } + /* Impose the order of the BDD variables to the ZDD variables. */ + if (allnew) { + for (i = 0; i < dd->size; i++) { + for (j = 0; j < multiplicity; j++) { + dd->permZ[i * multiplicity + j] = + dd->perm[i] * multiplicity + j; + dd->invpermZ[dd->permZ[i * multiplicity + j]] = + i * multiplicity + j; + } + } + for (i = 0; i < dd->sizeZ; i++) { + dd->univ[i]->index = dd->invpermZ[i]; + } + } else { + permutation = ALLOC(int,dd->sizeZ); + if (permutation == NULL) { + dd->errorCode = CUDD_MEMORY_OUT; + return(0); + } + for (i = 0; i < dd->size; i++) { + for (j = 0; j < multiplicity; j++) { + permutation[i * multiplicity + j] = + dd->invperm[i] * multiplicity + j; + } + } + for (i = dd->size * multiplicity; i < dd->sizeZ; i++) { + permutation[i] = i; + } + res = Cudd_zddShuffleHeap(dd, permutation); + FREE(permutation); + if (res == 0) return(0); + } + /* Copy and expand the variable group tree if it exists. */ + if (dd->treeZ != NULL) { + Cudd_FreeZddTree(dd); + } + if (dd->tree != NULL) { + dd->treeZ = Mtr_CopyTree(dd->tree, multiplicity); + if (dd->treeZ == NULL) return(0); + } else if (multiplicity > 1) { + dd->treeZ = Mtr_InitGroupTree(0, dd->sizeZ); + if (dd->treeZ == NULL) return(0); + dd->treeZ->index = dd->invpermZ[0]; + } + /* Create groups for the ZDD variables derived from the same BDD variable. + */ + if (multiplicity > 1) { + char *vmask, *lmask; + + vmask = ALLOC(char, dd->size); + if (vmask == NULL) { + dd->errorCode = CUDD_MEMORY_OUT; + return(0); + } + lmask = ALLOC(char, dd->size); + if (lmask == NULL) { + dd->errorCode = CUDD_MEMORY_OUT; + return(0); + } + for (i = 0; i < dd->size; i++) { + vmask[i] = lmask[i] = 0; + } + res = addMultiplicityGroups(dd,dd->treeZ,multiplicity,vmask,lmask); + FREE(vmask); + FREE(lmask); + if (res == 0) return(0); + } + return(1); + +} /* end of Cudd_zddVarsFromBddVars */ + + +/** + @brief Returns the maximum possible index for a variable. + + @sideeffect None +*/ +unsigned int +Cudd_ReadMaxIndex(void) +{ + return(CUDD_MAXINDEX); + +} /* end of Cudd_ReadMaxIndex */ + + +/** + @brief Returns the %ADD for constant c. + + @details Retrieves the %ADD for constant c if it already + exists, or creates a new %ADD. + + @return a pointer to the %ADD if successful; NULL otherwise. + + @sideeffect None + + @see Cudd_addNewVar Cudd_addIthVar + +*/ +DdNode * +Cudd_addConst( + DdManager * dd, + CUDD_VALUE_TYPE c) +{ + return(cuddUniqueConst(dd,c)); + +} /* end of Cudd_addConst */ + + +/** + @brief Returns 1 if the node is a constant node. + + @details A constant node is not an internal node. The pointer + passed to Cudd_IsConstant may be either regular or complemented. + + @sideeffect none + +*/ +int Cudd_IsConstant(DdNode *node) +{ + return Cudd_Regular(node)->index == CUDD_CONST_INDEX; + +} /* end of Cudd_IsConstant */ + + +/** + @brief Returns 1 if a %DD node is not constant. + + @details This function is useful to test the results of + Cudd_bddIteConstant, Cudd_addIteConstant, Cudd_addEvalConst. These + results may be a special value signifying non-constant. In the other + cases Cudd_IsConstant can be used. + + @sideeffect None + + @see Cudd_IsConstant Cudd_bddIteConstant Cudd_addIteConstant + Cudd_addEvalConst + +*/ +int +Cudd_IsNonConstant( + DdNode *f) +{ + return(f == DD_NON_CONSTANT || !Cudd_IsConstantInt(f)); + +} /* end of Cudd_IsNonConstant */ + + +/** + @brief Returns the then child of an internal node. + + @details If <code>node</code> is a constant node, the result is + unpredictable. + + @sideeffect none + + @see Cudd_E Cudd_V + +*/ +DdNode const * +Cudd_T_const(DdNode const *node) +{ + return Cudd_Regular(node)->type.kids.T; + +} /* end of Cudd_T */ + + +/** + @brief Returns the else child of an internal node. + + @details If <code>node</code> is a constant node, the result is + unpredictable. + + @sideeffect none + + @see Cudd_T Cudd_V + +*/ +DdNode const * +Cudd_E_const(DdNode const * node) +{ + return Cudd_Regular(node)->type.kids.E; + +} /* end of Cudd_E */ + +/** + @brief Returns the then child of an internal node. + + @details If <code>node</code> is a constant node, the result is + unpredictable. + + @sideeffect none + + @see Cudd_E Cudd_V + + */ +DdNode * +Cudd_T(DdNode * node) +{ + return Cudd_Regular(node)->type.kids.T; + +} /* end of Cudd_T */ + + +/** + @brief Returns the else child of an internal node. + + @details If <code>node</code> is a constant node, the result is + unpredictable. + + @sideeffect none + + @see Cudd_T Cudd_V + + */ +DdNode * +Cudd_E(DdNode * node) +{ + return Cudd_Regular(node)->type.kids.E; + +} /* end of Cudd_E */ + +/** + @brief Returns the value of a constant node. + + @details If <code>node</code> is an internal node, the result is + unpredictable. + + @sideeffect none + + @see Cudd_T Cudd_E + +*/ +CUDD_VALUE_TYPE +Cudd_V(DdNode const *node) +{ + return Cudd_Regular(node)->type.value; + +} /* end of Cudd_V */ + + +/** + @brief Returns the start time of the manager. + + @details This is initially set to the number of milliseconds since + the program started, but may be reset by the application. + + @sideeffect None + + @see Cudd_SetStartTime Cudd_ResetStartTime Cudd_ReadTimeLimit + +*/ +unsigned long +Cudd_ReadStartTime( + DdManager * unique) +{ + return unique->startTime; + +} /* end of Cudd_ReadStartTime */ + + +/** + @brief Returns the time elapsed since the start time of the manager. + + @details The time is expressed in milliseconds. + + @sideeffect None + + @see Cudd_ReadStartTime Cudd_SetStartTime + +*/ +unsigned long +Cudd_ReadElapsedTime( + DdManager * unique) +{ + return util_cpu_time() - unique->startTime; + +} /* end of Cudd_ReadElapsedTime */ + + +/** + @brief Sets the start time of the manager. + + @details The time must be expressed in milliseconds. + + @sideeffect None + + @see Cudd_ReadStartTime Cudd_ResetStartTime Cudd_ReadElapsedTime + Cudd_SetTimeLimit + +*/ +void +Cudd_SetStartTime( + DdManager * unique, + unsigned long st) +{ + unique->startTime = st; + +} /* end of Cudd_SetStartTime */ + + +/** + @brief Resets the start time of the manager. + + @sideeffect None + + @see Cudd_ReadStartTime Cudd_SetStartTime Cudd_SetTimeLimit + +*/ +void +Cudd_ResetStartTime( + DdManager * unique) +{ + unique->startTime = util_cpu_time(); + +} /* end of Cudd_ResetStartTime */ + + +/** + @brief Returns the time limit for the manager. + + @details This is initially set to a very large number, but may be + reset by the application. The time is expressed in milliseconds. + + @sideeffect None + + @see Cudd_SetTimeLimit Cudd_UpdateTimeLimit Cudd_UnsetTimeLimit + Cudd_IncreaseTimeLimit Cudd_TimeLimited Cudd_ReadStartTime + +*/ +unsigned long +Cudd_ReadTimeLimit( + DdManager * unique) +{ + return unique->timeLimit; + +} /* end of Cudd_ReadTimeLimit */ + + +/** + @brief Sets the time limit for the manager. + + @details The time must be expressed in milliseconds. + + @return the old time limit. + + @sideeffect None + + @see Cudd_ReadTimeLimit Cudd_UnsetTimeLimit Cudd_UpdateTimeLimit + Cudd_IncreaseTimeLimit Cudd_TimeLimited Cudd_SetStartTime + +*/ +unsigned long +Cudd_SetTimeLimit( + DdManager * unique, + unsigned long tl) +{ + unsigned long ret = unique->timeLimit; + unique->timeLimit = tl; + return(ret); + +} /* end of Cudd_SetTimeLimit */ + + +/** + @brief Updates the time limit for the manager. + + @details Updates the time limit for the manager by subtracting the + elapsed time from it. + + @sideeffect None + + @see Cudd_ReadTimeLimit Cudd_SetTimeLimit Cudd_UnsetTimeLimit + Cudd_IncreaseTimeLimit Cudd_TimeLimited Cudd_SetStartTime + +*/ +void +Cudd_UpdateTimeLimit( + DdManager * unique) +{ + unsigned long elapsed; + if (unique->timeLimit == ~0UL) + return; + elapsed = util_cpu_time() - unique->startTime; + if (unique->timeLimit >= elapsed) { + unique->timeLimit -= elapsed; + } else { + unique->timeLimit = 0; + } + +} /* end of Cudd_UpdateTimeLimit */ + + +/** + @brief Increases the time limit for the manager. + + @details The time increase must be expressed in milliseconds. + + @sideeffect None + + @see Cudd_ReadTimeLimit Cudd_SetTimeLimit Cudd_UnsetTimeLimit + Cudd_UpdateTimeLimit Cudd_TimeLimited Cudd_SetStartTime + +*/ +void +Cudd_IncreaseTimeLimit( + DdManager * unique, + unsigned long increase) +{ + if (unique->timeLimit == ~0UL) + unique->timeLimit = increase; + else + unique->timeLimit += increase; + +} /* end of Cudd_IncreaseTimeLimit */ + + +/** + @brief Unsets the time limit for the manager. + + @details Actually, sets it to a very large value. + + @sideeffect None + + @see Cudd_ReadTimeLimit Cudd_SetTimeLimit Cudd_UpdateTimeLimit + Cudd_IncreaseTimeLimit Cudd_TimeLimited Cudd_SetStartTime + +*/ +void +Cudd_UnsetTimeLimit( + DdManager * unique) +{ + unique->timeLimit = ~0UL; + +} /* end of Cudd_UnsetTimeLimit */ + + +/** + @brief Returns true if the time limit for the manager is set. + + @sideeffect None + + @see Cudd_ReadTimeLimit Cudd_SetTimeLimit Cudd_UpdateTimeLimit + Cudd_UnsetTimeLimit Cudd_IncreaseTimeLimit + +*/ +int +Cudd_TimeLimited( + DdManager * unique) +{ + return unique->timeLimit != ~0UL; + +} /* end of Cudd_TimeLimited */ + + +/** + @brief Installs a termination callback. + + @details Registers a callback function that is called from time + to time to decide whether computation should be abandoned. + + @sideeffect None + + @see Cudd_UnregisterTerminationCallback + +*/ +void +Cudd_RegisterTerminationCallback( + DdManager *unique, + DD_THFP callback, + void * callback_arg) +{ + unique->terminationCallback = callback; + unique->tcbArg = callback_arg; + +} /* end of Cudd_RegisterTerminationCallback */ + + +/** + @brief Unregisters a termination callback. + + @sideeffect None + + @see Cudd_RegisterTerminationCallback + +*/ +void +Cudd_UnregisterTerminationCallback( + DdManager *unique) +{ + unique->terminationCallback = NULL; + unique->tcbArg = NULL; + +} /* end of Cudd_UnregisterTerminationCallback */ + + +/** + @brief Installs an out-of-memory callback. + + @details Registers a callback function that is called when + a discretionary memory allocation fails. + + @return the old callback function. + + @sideeffect None + + @see Cudd_UnregisterOutOfMemoryCallback Cudd_OutOfMem Cudd_OutOfMemSilent + +*/ +DD_OOMFP +Cudd_RegisterOutOfMemoryCallback( + DdManager *unique, + DD_OOMFP callback) +{ + DD_OOMFP ret = unique->outOfMemCallback; + unique->outOfMemCallback = callback; + return(ret); + +} /* end of Cudd_RegisterOutOfMemoryCallback */ + + +/** + @brief Unregister an out-of-memory callback. + + @sideeffect None + + @see Cudd_RegisterOutOfMemoryCallback Cudd_OutOfMem Cudd_OutOfMemSilent + +*/ +void +Cudd_UnregisterOutOfMemoryCallback( + DdManager *unique) +{ + unique->outOfMemCallback = Cudd_OutOfMemSilent; + +} /* end of Cudd_UnregisterOutOfMemoryCallback */ + + +/** + @brief Register a timeout handler function. + + @details To unregister a handler, register a NULL pointer. + + @sideeffect None + + @see Cudd_ReadTimeoutHandler +*/ +void +Cudd_RegisterTimeoutHandler( + DdManager *unique, + DD_TOHFP handler, + void *arg) +{ + unique->timeoutHandler = handler; + unique->tohArg = arg; + +} /* end of Cudd_RegisterTimeoutHandler */ + + +/** + @brief Read the current timeout handler function. + + @sideeffect If argp is non-null, the second argument to + the handler is written to the location it points to. + + @see Cudd_RegisterTimeoutHandler +*/ +DD_TOHFP +Cudd_ReadTimeoutHandler( + DdManager *unique, + void **argp) +{ + if (argp != NULL) + *argp = unique->tohArg; + return unique->timeoutHandler; + +} /* end of Cudd_ReadTimeoutHandler */ + + +/** + @brief Enables automatic dynamic reordering of BDDs and ADDs. + + @details Parameter method is used to determine the method used for + reordering. If CUDD_REORDER_SAME is passed, the method is unchanged. + + @sideeffect None + + @see Cudd_AutodynDisable Cudd_ReorderingStatus + Cudd_AutodynEnableZdd + +*/ +void +Cudd_AutodynEnable( + DdManager * unique, + Cudd_ReorderingType method) +{ + unique->autoDyn = 1; + if (method != CUDD_REORDER_SAME) { + unique->autoMethod = method; + } +#ifndef DD_NO_DEATH_ROW + /* If reordering is enabled, using the death row causes too many + ** invocations. Hence, we shrink the death row to just one entry. + */ + cuddClearDeathRow(unique); + unique->deathRowDepth = 1; + unique->deadMask = unique->deathRowDepth - 1; + if ((unsigned) unique->nextDead > unique->deadMask) { + unique->nextDead = 0; + } + unique->deathRow = REALLOC(DdNodePtr, unique->deathRow, + unique->deathRowDepth); +#endif + return; + +} /* end of Cudd_AutodynEnable */ + + +/** + @brief Disables automatic dynamic reordering. + + @sideeffect None + + @see Cudd_AutodynEnable Cudd_ReorderingStatus + Cudd_AutodynDisableZdd + +*/ +void +Cudd_AutodynDisable( + DdManager * unique) +{ + unique->autoDyn = 0; + return; + +} /* end of Cudd_AutodynDisable */ + + +/** + @brief Reports the status of automatic dynamic reordering of BDDs + and ADDs. + + @details The location pointed by parameter method is set to + the reordering method currently selected if method is non-null. + + @return 1 if automatic reordering is enabled; 0 otherwise. + + @sideeffect The location pointed by parameter method is set to the + reordering method currently selected if method is non-null. + + @see Cudd_AutodynEnable Cudd_AutodynDisable + Cudd_ReorderingStatusZdd + +*/ +int +Cudd_ReorderingStatus( + DdManager * unique, + Cudd_ReorderingType * method) +{ + if (method) + *method = unique->autoMethod; + return(unique->autoDyn); + +} /* end of Cudd_ReorderingStatus */ + + +/** + @brief Enables automatic dynamic reordering of ZDDs. + + @details Parameter method is used to determine the method used for + reordering ZDDs. If CUDD_REORDER_SAME is passed, the method is + unchanged. + + @sideeffect None + + @see Cudd_AutodynDisableZdd Cudd_ReorderingStatusZdd + Cudd_AutodynEnable + +*/ +void +Cudd_AutodynEnableZdd( + DdManager * unique, + Cudd_ReorderingType method) +{ + unique->autoDynZ = 1; + if (method != CUDD_REORDER_SAME) { + unique->autoMethodZ = method; + } + return; + +} /* end of Cudd_AutodynEnableZdd */ + + +/** + @brief Disables automatic dynamic reordering of ZDDs. + + @sideeffect None + + @see Cudd_AutodynEnableZdd Cudd_ReorderingStatusZdd + Cudd_AutodynDisable + +*/ +void +Cudd_AutodynDisableZdd( + DdManager * unique) +{ + unique->autoDynZ = 0; + return; + +} /* end of Cudd_AutodynDisableZdd */ + + +/** + @brief Reports the status of automatic dynamic reordering of ZDDs. + + @details Parameter method is set to the %ZDD reordering method currently + selected. + + @return 1 if automatic reordering is enabled; 0 otherwise. + + @sideeffect Parameter method is set to the %ZDD reordering method currently + selected. + + @see Cudd_AutodynEnableZdd Cudd_AutodynDisableZdd + Cudd_ReorderingStatus + +*/ +int +Cudd_ReorderingStatusZdd( + DdManager * unique, + Cudd_ReorderingType * method) +{ + *method = unique->autoMethodZ; + return(unique->autoDynZ); + +} /* end of Cudd_ReorderingStatusZdd */ + + +/** + @brief Tells whether the realignment of %ZDD order to %BDD order is + enabled. + + @return 1 if the realignment of %ZDD order to %BDD order is enabled; 0 + otherwise. + + @sideeffect None + + @see Cudd_zddRealignEnable Cudd_zddRealignDisable + Cudd_bddRealignEnable Cudd_bddRealignDisable + +*/ +int +Cudd_zddRealignmentEnabled( + DdManager * unique) +{ + return(unique->realign); + +} /* end of Cudd_zddRealignmentEnabled */ + + +/** + @brief Enables realignment of %ZDD order to %BDD order. + + @details Enables realignment of the %ZDD variable order to the + %BDD variable order after the BDDs and ADDs have been reordered. The + number of %ZDD variables must be a multiple of the number of %BDD + variables for realignment to make sense. If this condition is not met, + Cudd_ReduceHeap will return 0. Let <code>M</code> be the + ratio of the two numbers. For the purpose of realignment, the %ZDD + variables from <code>M*i</code> to <code>(M+1)*i-1</code> are + reagarded as corresponding to %BDD variable <code>i</code>. Realignment + is initially disabled. + + @sideeffect None + + @see Cudd_ReduceHeap Cudd_zddRealignDisable + Cudd_zddRealignmentEnabled Cudd_bddRealignDisable + Cudd_bddRealignmentEnabled + +*/ +void +Cudd_zddRealignEnable( + DdManager * unique) +{ + unique->realign = 1; + return; + +} /* end of Cudd_zddRealignEnable */ + + +/** + @brief Disables realignment of %ZDD order to %BDD order. + + @sideeffect None + + @see Cudd_zddRealignEnable Cudd_zddRealignmentEnabled + Cudd_bddRealignEnable Cudd_bddRealignmentEnabled + +*/ +void +Cudd_zddRealignDisable( + DdManager * unique) +{ + unique->realign = 0; + return; + +} /* end of Cudd_zddRealignDisable */ + + +/** + @brief Tells whether the realignment of %BDD order to %ZDD order is + enabled. + + @return 1 if the realignment of %BDD order to %ZDD order is enabled; 0 + otherwise. + + @sideeffect None + + @see Cudd_bddRealignEnable Cudd_bddRealignDisable + Cudd_zddRealignEnable Cudd_zddRealignDisable + +*/ +int +Cudd_bddRealignmentEnabled( + DdManager * unique) +{ + return(unique->realignZ); + +} /* end of Cudd_bddRealignmentEnabled */ + + +/** + @brief Enables realignment of %BDD order to %ZDD order. + + @details Enables realignment of the %BDD variable order to the + %ZDD variable order after the ZDDs have been reordered. The + number of %ZDD variables must be a multiple of the number of %BDD + variables for realignment to make sense. If this condition is not met, + Cudd_zddReduceHeap will return 0. Let <code>M</code> be the + ratio of the two numbers. For the purpose of realignment, the %ZDD + variables from <code>M*i</code> to <code>(M+1)*i-1</code> are + reagarded as corresponding to %BDD variable <code>i</code>. Realignment + is initially disabled. + + @sideeffect None + + @see Cudd_zddReduceHeap Cudd_bddRealignDisable + Cudd_bddRealignmentEnabled Cudd_zddRealignDisable + Cudd_zddRealignmentEnabled + +*/ +void +Cudd_bddRealignEnable( + DdManager * unique) +{ + unique->realignZ = 1; + return; + +} /* end of Cudd_bddRealignEnable */ + + +/** + @brief Disables realignment of %ZDD order to %BDD order. + + @sideeffect None + + @see Cudd_bddRealignEnable Cudd_bddRealignmentEnabled + Cudd_zddRealignEnable Cudd_zddRealignmentEnabled + +*/ +void +Cudd_bddRealignDisable( + DdManager * unique) +{ + unique->realignZ = 0; + return; + +} /* end of Cudd_bddRealignDisable */ + + +/** + @brief Returns the one constant of the manager. + + @details The one constant is common to ADDs and BDDs. + + @sideeffect None + + @see Cudd_ReadZero Cudd_ReadLogicZero Cudd_ReadZddOne + +*/ +DdNode * +Cudd_ReadOne( + DdManager * dd) +{ + return(dd->one); + +} /* end of Cudd_ReadOne */ + + +/** + @brief Returns the %ZDD for the constant 1 function. + + @details The representation of the constant 1 function as a %ZDD + depends on how many variables it (nominally) depends on. The index + of the topmost variable in the support is given as argument + <code>i</code>. + + @sideeffect None + + @see Cudd_ReadOne + +*/ +DdNode * +Cudd_ReadZddOne( + DdManager * dd, + int i) +{ + if (i < 0) + return(NULL); + return(i < dd->sizeZ ? dd->univ[i] : DD_ONE(dd)); + +} /* end of Cudd_ReadZddOne */ + + + +/** + @brief Returns the zero constant of the manager. + + @details The zero constant is the arithmetic zero, rather than the + logic zero. The latter is the complement of the one constant. + + @sideeffect None + + @see Cudd_ReadOne Cudd_ReadLogicZero + +*/ +DdNode * +Cudd_ReadZero( + DdManager * dd) +{ + return(DD_ZERO(dd)); + +} /* end of Cudd_ReadZero */ + + +/** + @brief Returns the logic zero constant of the manager. + + @details The logic zero constant is the complement of the one + constant, and is distinct from the arithmetic zero. + + @sideeffect None + + @see Cudd_ReadOne Cudd_ReadZero + +*/ +DdNode * +Cudd_ReadLogicZero( + DdManager * dd) +{ + return(Cudd_Not(DD_ONE(dd))); + +} /* end of Cudd_ReadLogicZero */ + + +/** + @brief Reads the plus-infinity constant from the manager. + + @sideeffect None + +*/ +DdNode * +Cudd_ReadPlusInfinity( + DdManager * dd) +{ + return(dd->plusinfinity); + +} /* end of Cudd_ReadPlusInfinity */ + + +/** + @brief Reads the minus-infinity constant from the manager. + + @sideeffect None + +*/ +DdNode * +Cudd_ReadMinusInfinity( + DdManager * dd) +{ + return(dd->minusinfinity); + +} /* end of Cudd_ReadMinusInfinity */ + + +/** + @brief Reads the background constant of the manager. + + @sideeffect None + +*/ +DdNode * +Cudd_ReadBackground( + DdManager * dd) +{ + return(dd->background); + +} /* end of Cudd_ReadBackground */ + + +/** + @brief Sets the background constant of the manager. + + @details It assumes that the DdNode pointer bck is already + referenced. + + @sideeffect None + +*/ +void +Cudd_SetBackground( + DdManager * dd, + DdNode * bck) +{ + dd->background = bck; + +} /* end of Cudd_SetBackground */ + + +/** + @brief Reads the number of slots in the cache. + + @sideeffect None + + @see Cudd_ReadCacheUsedSlots + +*/ +unsigned int +Cudd_ReadCacheSlots( + DdManager * dd) +{ + return(dd->cacheSlots); + +} /* end of Cudd_ReadCacheSlots */ + + +/** + @brief Reads the fraction of used slots in the cache. + + @details The unused slots are those in which no valid data is + stored. Garbage collection, variable reordering, and cache resizing + may cause used slots to become unused. + + @sideeffect None + + @see Cudd_ReadCacheSlots + +*/ +double +Cudd_ReadCacheUsedSlots( + DdManager * dd) +{ + size_t used = 0; + int slots = dd->cacheSlots; + DdCache *cache = dd->cache; + int i; + + for (i = 0; i < slots; i++) { + used += cache[i].h != 0; + } + + return((double)used / (double) dd->cacheSlots); + +} /* end of Cudd_ReadCacheUsedSlots */ + + +/** + @brief Returns the number of cache look-ups. + + @sideeffect None + + @see Cudd_ReadCacheHits + +*/ +double +Cudd_ReadCacheLookUps( + DdManager * dd) +{ + return(dd->cacheHits + dd->cacheMisses + + dd->totCachehits + dd->totCacheMisses); + +} /* end of Cudd_ReadCacheLookUps */ + + +/** + @brief Returns the number of cache hits. + + @sideeffect None + + @see Cudd_ReadCacheLookUps + +*/ +double +Cudd_ReadCacheHits( + DdManager * dd) +{ + return(dd->cacheHits + dd->totCachehits); + +} /* end of Cudd_ReadCacheHits */ + + +/** + @brief Returns the number of recursive calls. + + @details Returns the number of recursive calls if the package is + compiled with DD_COUNT defined. + + @sideeffect None + +*/ +double +Cudd_ReadRecursiveCalls( + DdManager * dd) +{ +#ifdef DD_COUNT + return(dd->recursiveCalls); +#else + (void) dd; /* avoid warning */ + return(-1.0); +#endif + +} /* end of Cudd_ReadRecursiveCalls */ + + + +/** + @brief Reads the hit rate that causes resizinig of the computed + table. + + @sideeffect None + + @see Cudd_SetMinHit + +*/ +unsigned int +Cudd_ReadMinHit( + DdManager * dd) +{ + /* Internally, the package manipulates the ratio of hits to + ** misses instead of the ratio of hits to accesses. */ + return((unsigned int) (0.5 + 100 * dd->minHit / (1 + dd->minHit))); + +} /* end of Cudd_ReadMinHit */ + + +/** + @brief Sets the hit rate that causes resizinig of the computed + table. + + @details Sets the minHit parameter of the manager. This + parameter controls the resizing of the computed table. If the hit + rate is larger than the specified value, and the cache is not + already too large, then its size is doubled. + + @sideeffect None + + @see Cudd_ReadMinHit + +*/ +void +Cudd_SetMinHit( + DdManager * dd, + unsigned int hr) +{ + /* Internally, the package manipulates the ratio of hits to + ** misses instead of the ratio of hits to accesses. */ + dd->minHit = (double) hr / (100.0 - (double) hr); + +} /* end of Cudd_SetMinHit */ + + +/** + @brief Reads the looseUpTo parameter of the manager. + + @sideeffect None + + @see Cudd_SetLooseUpTo Cudd_ReadMinHit Cudd_ReadMinDead + +*/ +unsigned int +Cudd_ReadLooseUpTo( + DdManager * dd) +{ + return(dd->looseUpTo); + +} /* end of Cudd_ReadLooseUpTo */ + + +/** + @brief Sets the looseUpTo parameter of the manager. + + @details This parameter of the manager controls the threshold beyond + which no fast growth of the unique table is allowed. The threshold + is given as a number of slots. If the value passed to this function + is 0, the function determines a suitable value based on the + available memory. + + @sideeffect None + + @see Cudd_ReadLooseUpTo Cudd_SetMinHit + +*/ +void +Cudd_SetLooseUpTo( + DdManager * dd, + unsigned int lut) +{ + if (lut == 0) { + unsigned long datalimit = getSoftDataLimit(); + lut = (unsigned int) (datalimit / (sizeof(DdNode) * + DD_MAX_LOOSE_FRACTION)); + } + dd->looseUpTo = lut; + +} /* end of Cudd_SetLooseUpTo */ + + +/** + @brief Returns the soft limit for the cache size. + + @sideeffect None + + @see Cudd_ReadMaxCacheHard + +*/ +unsigned int +Cudd_ReadMaxCache( + DdManager * dd) +{ + return(2 * dd->cacheSlots + dd->cacheSlack); + +} /* end of Cudd_ReadMaxCache */ + + +/** + @brief Reads the maxCacheHard parameter of the manager. + + @sideeffect None + + @see Cudd_SetMaxCacheHard Cudd_ReadMaxCache + +*/ +unsigned int +Cudd_ReadMaxCacheHard( + DdManager * dd) +{ + return(dd->maxCacheHard); + +} /* end of Cudd_ReadMaxCache */ + + +/** + @brief Sets the maxCacheHard parameter of the manager. + + @details The cache cannot grow larger than maxCacheHard + entries. This parameter allows an application to control the + trade-off of memory versus speed. If the value passed to this + function is 0, the function determines a suitable maximum cache size + based on the available memory. + + @sideeffect None + + @see Cudd_ReadMaxCacheHard Cudd_SetMaxCache + +*/ +void +Cudd_SetMaxCacheHard( + DdManager * dd, + unsigned int mc) +{ + if (mc == 0) { + unsigned long datalimit = getSoftDataLimit(); + mc = (unsigned int) (datalimit / (sizeof(DdCache) * + DD_MAX_CACHE_FRACTION)); + } + dd->maxCacheHard = mc; + +} /* end of Cudd_SetMaxCacheHard */ + + +/** + @brief Returns the number of %BDD variables in existance. + + @sideeffect None + + @see Cudd_ReadZddSize + +*/ +int +Cudd_ReadSize( + DdManager * dd) +{ + return(dd->size); + +} /* end of Cudd_ReadSize */ + + +/** + @brief Returns the number of %ZDD variables in existance. + + @sideeffect None + + @see Cudd_ReadSize + +*/ +int +Cudd_ReadZddSize( + DdManager * dd) +{ + return(dd->sizeZ); + +} /* end of Cudd_ReadZddSize */ + + +/** + @brief Returns the total number of slots of the unique table. + + @details This number is mainly for diagnostic purposes. + + @sideeffect None + +*/ +unsigned int +Cudd_ReadSlots( + DdManager * dd) +{ + return(dd->slots); + +} /* end of Cudd_ReadSlots */ + + +/** + @brief Reads the fraction of used slots in the unique table. + + @details The unused slots are those in which no valid data is + stored. Garbage collection, variable reordering, and subtable + resizing may cause used slots to become unused. + + @sideeffect None + + @see Cudd_ReadSlots + +*/ +double +Cudd_ReadUsedSlots( + DdManager * dd) +{ + size_t used = 0; + int i, j; + int size = dd->size; + DdNodePtr *nodelist; + DdSubtable *subtable; + DdNode *node; + DdNode *sentinel = &(dd->sentinel); + + /* Scan each BDD/ADD subtable. */ + for (i = 0; i < size; i++) { + subtable = &(dd->subtables[i]); + nodelist = subtable->nodelist; + for (j = 0; (unsigned) j < subtable->slots; j++) { + node = nodelist[j]; + if (node != sentinel) { + used++; + } + } + } + + /* Scan the ZDD subtables. */ + size = dd->sizeZ; + + for (i = 0; i < size; i++) { + subtable = &(dd->subtableZ[i]); + nodelist = subtable->nodelist; + for (j = 0; (unsigned) j < subtable->slots; j++) { + node = nodelist[j]; + if (node != NULL) { + used++; + } + } + } + + /* Constant table. */ + subtable = &(dd->constants); + nodelist = subtable->nodelist; + for (j = 0; (unsigned) j < subtable->slots; j++) { + node = nodelist[j]; + if (node != NULL) { + used++; + } + } + + return((double)used / (double) dd->slots); + +} /* end of Cudd_ReadUsedSlots */ + + +/** + @brief Computes the expected fraction of used slots in the unique + table. + + @details This expected value is based on the assumption that the + hash function distributes the keys randomly; it can be compared with + the result of Cudd_ReadUsedSlots to monitor the performance of the + unique table hash function. + + @sideeffect None + + @see Cudd_ReadSlots Cudd_ReadUsedSlots + +*/ +double +Cudd_ExpectedUsedSlots( + DdManager * dd) +{ + int i; + int size = dd->size; + DdSubtable *subtable; + double empty = 0.0; + + /* To each subtable we apply the corollary to Theorem 8.5 (occupancy + ** distribution) from Sedgewick and Flajolet's Analysis of Algorithms. + ** The corollary says that for a table with M buckets and a load ratio + ** of r, the expected number of empty buckets is asymptotically given + ** by M * exp(-r). + */ + + /* Scan each BDD/ADD subtable. */ + for (i = 0; i < size; i++) { + subtable = &(dd->subtables[i]); + empty += (double) subtable->slots * + exp(-(double) subtable->keys / (double) subtable->slots); + } + + /* Scan the ZDD subtables. */ + size = dd->sizeZ; + + for (i = 0; i < size; i++) { + subtable = &(dd->subtableZ[i]); + empty += (double) subtable->slots * + exp(-(double) subtable->keys / (double) subtable->slots); + } + + /* Constant table. */ + subtable = &(dd->constants); + empty += (double) subtable->slots * + exp(-(double) subtable->keys / (double) subtable->slots); + + return(1.0 - empty / (double) dd->slots); + +} /* end of Cudd_ExpectedUsedSlots */ + + +/** + @brief Returns the number of nodes in the unique table. + + @details Returns the total number of nodes currently in the unique + table, including the dead nodes. + + @sideeffect None + + @see Cudd_ReadDead + +*/ +unsigned int +Cudd_ReadKeys( + DdManager * dd) +{ + return(dd->keys); + +} /* end of Cudd_ReadKeys */ + + +/** + @brief Returns the number of dead nodes in the unique table. + + @sideeffect None + + @see Cudd_ReadKeys + +*/ +unsigned int +Cudd_ReadDead( + DdManager * dd) +{ + return(dd->dead); + +} /* end of Cudd_ReadDead */ + + +/** + @brief Reads the minDead parameter of the manager. + + @details The minDead parameter is used by the package to decide + whether to collect garbage or resize a subtable of the unique table + when the subtable becomes too full. The application can indirectly + control the value of minDead by setting the looseUpTo parameter. + + @sideeffect None + + @see Cudd_ReadDead Cudd_ReadLooseUpTo Cudd_SetLooseUpTo + +*/ +unsigned int +Cudd_ReadMinDead( + DdManager * dd) +{ + return(dd->minDead); + +} /* end of Cudd_ReadMinDead */ + + +/** + @brief Returns the number of times reordering has occurred. + + @details The number includes both the calls to Cudd_ReduceHeap from + the application program and those automatically performed by the + package. However, calls that do not even initiate reordering are not + counted. A call may not initiate reordering if there are fewer than + minsize live nodes in the manager, or if CUDD_REORDER_NONE is specified + as reordering method. The calls to Cudd_ShuffleHeap are not counted. + + @sideeffect None + + @see Cudd_ReduceHeap Cudd_ReadReorderingTime + +*/ +unsigned int +Cudd_ReadReorderings( + DdManager * dd) +{ + return(dd->reorderings); + +} /* end of Cudd_ReadReorderings */ + + +/** + @brief Returns the maximum number of times reordering may be invoked. + + @sideeffect None + + @see Cudd_ReadReorderings Cudd_SetMaxReorderings Cudd_ReduceHeap + +*/ +unsigned int +Cudd_ReadMaxReorderings( + DdManager * dd) +{ + return(dd->maxReorderings); + +} /* end of Cudd_ReadMaxReorderings */ + + +/** + @brief Sets the maximum number of times reordering may be invoked. + + @details The default value is (practically) infinite. + + @sideeffect None + + @see Cudd_ReadReorderings Cudd_ReadMaxReorderings Cudd_ReduceHeap + +*/ +void +Cudd_SetMaxReorderings( + DdManager * dd, unsigned int mr) +{ + dd->maxReorderings = mr; + +} /* end of Cudd_SetMaxReorderings */ + + +/** + @brief Returns the time spent in reordering. + + @details Returns the number of milliseconds spent reordering + variables since the manager was initialized. The time spent in collecting + garbage before reordering is included. + + @sideeffect None + + @see Cudd_ReadReorderings + +*/ +long +Cudd_ReadReorderingTime( + DdManager * dd) +{ + return(dd->reordTime); + +} /* end of Cudd_ReadReorderingTime */ + + +/** + @brief Returns the number of times garbage collection has occurred. + + @details The number includes both the calls from reordering + procedures and those caused by requests to create new nodes. + + @sideeffect None + + @see Cudd_ReadGarbageCollectionTime + +*/ +int +Cudd_ReadGarbageCollections( + DdManager * dd) +{ + return(dd->garbageCollections); + +} /* end of Cudd_ReadGarbageCollections */ + + +/** + @brief Returns the time spent in garbage collection. + + @details Returns the number of milliseconds spent doing garbage + collection since the manager was initialized. + + @sideeffect None + + @see Cudd_ReadGarbageCollections + +*/ +long +Cudd_ReadGarbageCollectionTime( + DdManager * dd) +{ + return(dd->GCTime); + +} /* end of Cudd_ReadGarbageCollectionTime */ + + +/** + @brief Returns the number of nodes freed. + + @details Returns the number of nodes returned to the free list if the + keeping of this statistic is enabled; -1 otherwise. This statistic is + enabled only if the package is compiled with DD_STATS defined. + + @sideeffect None + + @see Cudd_ReadNodesDropped + +*/ +double +Cudd_ReadNodesFreed( + DdManager * dd) +{ +#ifdef DD_STATS + return(dd->nodesFreed); +#else + (void) dd; /* avoid warning */ + return(-1.0); +#endif + +} /* end of Cudd_ReadNodesFreed */ + + +/** + @brief Returns the number of nodes dropped. + + @details Returns the number of nodes killed by dereferencing if the + keeping of this statistic is enabled; -1 otherwise. This statistic is + enabled only if the package is compiled with DD_STATS defined. + + @sideeffect None + + @see Cudd_ReadNodesFreed + +*/ +double +Cudd_ReadNodesDropped( + DdManager * dd) +{ +#ifdef DD_STATS + return(dd->nodesDropped); +#else + (void) dd; /* avoid warning */ + return(-1.0); +#endif + +} /* end of Cudd_ReadNodesDropped */ + + +/** + @brief Returns the number of look-ups in the unique table. + + @details Returns the number of look-ups in the unique table if the + keeping of this statistic is enabled; -1 otherwise. This statistic is + enabled only if the package is compiled with DD_UNIQUE_PROFILE defined. + + @sideeffect None + + @see Cudd_ReadUniqueLinks + +*/ +double +Cudd_ReadUniqueLookUps( + DdManager * dd) +{ +#ifdef DD_UNIQUE_PROFILE + return(dd->uniqueLookUps); +#else + (void) dd; /* avoid warning */ + return(-1.0); +#endif + +} /* end of Cudd_ReadUniqueLookUps */ + + +/** + @brief Returns the number of links followed in the unique table. + + @details Returns the number of links followed during look-ups in the + unique table if the keeping of this statistic is enabled; -1 otherwise. + If an item is found in the first position of its collision list, the + number of links followed is taken to be 0. If it is in second position, + the number of links is 1, and so on. This statistic is enabled only if + the package is compiled with DD_UNIQUE_PROFILE defined. + + @sideeffect None + + @see Cudd_ReadUniqueLookUps + +*/ +double +Cudd_ReadUniqueLinks( + DdManager * dd) +{ +#ifdef DD_UNIQUE_PROFILE + return(dd->uniqueLinks); +#else + (void) dd; /* avoid warning */ + return(-1.0); +#endif + +} /* end of Cudd_ReadUniqueLinks */ + + +/** + @brief Reads the siftMaxVar parameter of the manager. + + @details This parameter gives the maximum number of variables that + will be sifted for each invocation of sifting. + + @sideeffect None + + @see Cudd_ReadSiftMaxSwap Cudd_SetSiftMaxVar + +*/ +int +Cudd_ReadSiftMaxVar( + DdManager * dd) +{ + return(dd->siftMaxVar); + +} /* end of Cudd_ReadSiftMaxVar */ + + +/** + @brief Sets the siftMaxVar parameter of the manager. + + @details This parameter gives the maximum number of variables that + will be sifted for each invocation of sifting. + + @sideeffect None + + @see Cudd_SetSiftMaxSwap Cudd_ReadSiftMaxVar + +*/ +void +Cudd_SetSiftMaxVar( + DdManager * dd, + int smv) +{ + dd->siftMaxVar = smv; + +} /* end of Cudd_SetSiftMaxVar */ + + +/** + @brief Reads the siftMaxSwap parameter of the manager. + + @details This parameter gives the maximum number of swaps that will + be attempted for each invocation of sifting. The real number of + swaps may exceed the set limit because the package will always + complete the sifting of the variable that causes the limit to be + reached. + + @sideeffect None + + @see Cudd_ReadSiftMaxVar Cudd_SetSiftMaxSwap + +*/ +int +Cudd_ReadSiftMaxSwap( + DdManager * dd) +{ + return(dd->siftMaxSwap); + +} /* end of Cudd_ReadSiftMaxSwap */ + + +/** + @brief Sets the siftMaxSwap parameter of the manager. + + @details This parameter gives the maximum number of swaps that will + be attempted for each invocation of sifting. The real number of + swaps may exceed the set limit because the package will always + complete the sifting of the variable that causes the limit to be + reached. + + @sideeffect None + + @see Cudd_SetSiftMaxVar Cudd_ReadSiftMaxSwap + +*/ +void +Cudd_SetSiftMaxSwap( + DdManager * dd, + int sms) +{ + dd->siftMaxSwap = sms; + +} /* end of Cudd_SetSiftMaxSwap */ + + +/** + @brief Reads the maxGrowth parameter of the manager. + + @details This parameter determines how much the number of nodes can + grow during sifting of a variable. Overall, sifting never increases + the size of the decision diagrams. This parameter only refers to + intermediate results. A lower value will speed up sifting, possibly + at the expense of quality. + + @sideeffect None + + @see Cudd_SetMaxGrowth Cudd_ReadMaxGrowthAlternate + +*/ +double +Cudd_ReadMaxGrowth( + DdManager * dd) +{ + return(dd->maxGrowth); + +} /* end of Cudd_ReadMaxGrowth */ + + +/** + @brief Sets the maxGrowth parameter of the manager. + + @details This parameter determines how much the number of nodes can + grow during sifting of a variable. Overall, sifting never increases + the size of the decision diagrams. This parameter only refers to + intermediate results. A lower value will speed up sifting, possibly + at the expense of quality. + + @sideeffect None + + @see Cudd_ReadMaxGrowth Cudd_SetMaxGrowthAlternate + +*/ +void +Cudd_SetMaxGrowth( + DdManager * dd, + double mg) +{ + dd->maxGrowth = mg; + +} /* end of Cudd_SetMaxGrowth */ + + +/** + @brief Reads the maxGrowthAlt parameter of the manager. + + @details This parameter is analogous to the maxGrowth paramter, and + is used every given number of reorderings instead of maxGrowth. The + number of reorderings is set with Cudd_SetReorderingCycle. If the + number of reorderings is 0 (default) maxGrowthAlt is never used. + + @sideeffect None + + @see Cudd_ReadMaxGrowth Cudd_SetMaxGrowthAlternate + Cudd_SetReorderingCycle Cudd_ReadReorderingCycle + +*/ +double +Cudd_ReadMaxGrowthAlternate( + DdManager * dd) +{ + return(dd->maxGrowthAlt); + +} /* end of Cudd_ReadMaxGrowthAlternate */ + + +/** + @brief Sets the maxGrowthAlt parameter of the manager. + + @details This parameter is analogous to the maxGrowth paramter, and + is used every given number of reorderings instead of maxGrowth. The + number of reorderings is set with Cudd_SetReorderingCycle. If the + number of reorderings is 0 (default) maxGrowthAlt is never used. + + @sideeffect None + + @see Cudd_ReadMaxGrowthAlternate Cudd_SetMaxGrowth + Cudd_SetReorderingCycle Cudd_ReadReorderingCycle + +*/ +void +Cudd_SetMaxGrowthAlternate( + DdManager * dd, + double mg) +{ + dd->maxGrowthAlt = mg; + +} /* end of Cudd_SetMaxGrowthAlternate */ + + +/** + @brief Reads the reordCycle parameter of the manager. + + @details This parameter determines how often the alternate threshold + on maximum growth is used in reordering. + + @sideeffect None + + @see Cudd_ReadMaxGrowthAlternate Cudd_SetMaxGrowthAlternate + Cudd_SetReorderingCycle + +*/ +int +Cudd_ReadReorderingCycle( + DdManager * dd) +{ + return(dd->reordCycle); + +} /* end of Cudd_ReadReorderingCycle */ + + +/** + @brief Sets the reordCycle parameter of the manager. + + @details This parameter determines how often the alternate threshold + on maximum growth is used in reordering. + + @sideeffect None + + @see Cudd_ReadMaxGrowthAlternate Cudd_SetMaxGrowthAlternate + Cudd_ReadReorderingCycle + +*/ +void +Cudd_SetReorderingCycle( + DdManager * dd, + int cycle) +{ + dd->reordCycle = cycle; + +} /* end of Cudd_SetReorderingCycle */ + + +/** + @brief Returns the variable group tree of the manager. + + @sideeffect None + + @see Cudd_SetTree Cudd_FreeTree Cudd_ReadZddTree + +*/ +MtrNode * +Cudd_ReadTree( + DdManager * dd) +{ + return(dd->tree); + +} /* end of Cudd_ReadTree */ + + +/** + @brief Sets the variable group tree of the manager. + + @sideeffect None + + @see Cudd_FreeTree Cudd_ReadTree Cudd_SetZddTree + +*/ +void +Cudd_SetTree( + DdManager * dd, + MtrNode * tree) +{ + if (dd->tree != NULL) { + Mtr_FreeTree(dd->tree); + } + dd->tree = tree; + if (tree == NULL) return; + + fixVarTree(tree, dd->perm, dd->size); + return; + +} /* end of Cudd_SetTree */ + + +/** + @brief Frees the variable group tree of the manager. + + @sideeffect None + + @see Cudd_SetTree Cudd_ReadTree Cudd_FreeZddTree + +*/ +void +Cudd_FreeTree( + DdManager * dd) +{ + if (dd->tree != NULL) { + Mtr_FreeTree(dd->tree); + dd->tree = NULL; + } + return; + +} /* end of Cudd_FreeTree */ + + +/** + @brief Returns the variable group tree of the manager. + + @sideeffect None + + @see Cudd_SetZddTree Cudd_FreeZddTree Cudd_ReadTree + +*/ +MtrNode * +Cudd_ReadZddTree( + DdManager * dd) +{ + return(dd->treeZ); + +} /* end of Cudd_ReadZddTree */ + + +/** + @brief Sets the %ZDD variable group tree of the manager. + + @sideeffect None + + @see Cudd_FreeZddTree Cudd_ReadZddTree Cudd_SetTree + +*/ +void +Cudd_SetZddTree( + DdManager * dd, + MtrNode * tree) +{ + if (dd->treeZ != NULL) { + Mtr_FreeTree(dd->treeZ); + } + dd->treeZ = tree; + if (tree == NULL) return; + + fixVarTree(tree, dd->permZ, dd->sizeZ); + return; + +} /* end of Cudd_SetZddTree */ + + +/** + @brief Frees the variable group tree of the manager. + + @sideeffect None + + @see Cudd_SetZddTree Cudd_ReadZddTree Cudd_FreeTree + +*/ +void +Cudd_FreeZddTree( + DdManager * dd) +{ + if (dd->treeZ != NULL) { + Mtr_FreeTree(dd->treeZ); + dd->treeZ = NULL; + } + return; + +} /* end of Cudd_FreeZddTree */ + + +/** + @brief Returns the index of the node. + + @details The node pointer can be either regular or complemented. + + @sideeffect None + + @see Cudd_ReadIndex + +*/ +unsigned int +Cudd_NodeReadIndex( + DdNode const * node) +{ + return((unsigned int) Cudd_Regular(node)->index); + +} /* end of Cudd_NodeReadIndex */ + +/** + @brief Returns the current position of the i-th variable in the + order. + + @details If the index is CUDD_CONST_INDEX, returns CUDD_CONST_INDEX; + otherwise, if the index is out of bounds returns -1. + + @sideeffect None + + @see Cudd_ReadInvPerm Cudd_ReadPermZdd + +*/ +int +Cudd_ReadPerm( + DdManager * dd, + int i) +{ + if (i == CUDD_CONST_INDEX) return(CUDD_CONST_INDEX); + if (i < 0 || i >= dd->size) return(-1); + return(dd->perm[i]); + +} /* end of Cudd_ReadPerm */ + + +/** + @brief Returns the current position of the i-th %ZDD variable in the + order. + + @details If the index is CUDD_CONST_INDEX, returns CUDD_CONST_INDEX; + otherwise, if the index is out of bounds returns -1. + + @sideeffect None + + @see Cudd_ReadInvPermZdd Cudd_ReadPerm + +*/ +int +Cudd_ReadPermZdd( + DdManager * dd, + int i) +{ + if (i == CUDD_CONST_INDEX) return(CUDD_CONST_INDEX); + if (i < 0 || i >= dd->sizeZ) return(-1); + return(dd->permZ[i]); + +} /* end of Cudd_ReadPermZdd */ + + +/** + @brief Returns the index of the variable currently in the i-th + position of the order. + + @details If the index is CUDD_CONST_INDEX, returns CUDD_CONST_INDEX; + otherwise, if the index is out of bounds returns -1. + + @sideeffect None + + @see Cudd_ReadPerm Cudd_ReadInvPermZdd + +*/ +int +Cudd_ReadInvPerm( + DdManager * dd, + int i) +{ + if (i == CUDD_CONST_INDEX) return(CUDD_CONST_INDEX); + if (i < 0 || i >= dd->size) return(-1); + return(dd->invperm[i]); + +} /* end of Cudd_ReadInvPerm */ + + +/** + @brief Returns the index of the %ZDD variable currently in the i-th + position of the order. + + @details If the index is CUDD_CONST_INDEX, returns CUDD_CONST_INDEX; + otherwise, if the index is out of bounds returns -1. + + @sideeffect None + + @see Cudd_ReadPerm Cudd_ReadInvPermZdd + +*/ +int +Cudd_ReadInvPermZdd( + DdManager * dd, + int i) +{ + if (i == CUDD_CONST_INDEX) return(CUDD_CONST_INDEX); + if (i < 0 || i >= dd->sizeZ) return(-1); + return(dd->invpermZ[i]); + +} /* end of Cudd_ReadInvPermZdd */ + + +/** + @brief Returns the i-th element of the vars array. + + @details Returns the i-th element of the vars array if it falls + within the array bounds; NULL otherwise. If i is the index of an + existing variable, this function produces the same result as + Cudd_bddIthVar. However, if the i-th var does not exist yet, + Cudd_bddIthVar will create it, whereas Cudd_ReadVars will not. + + @sideeffect None + + @see Cudd_bddIthVar + +*/ +DdNode * +Cudd_ReadVars( + DdManager * dd, + int i) +{ + if (i < 0 || i > dd->size) return(NULL); + return(dd->vars[i]); + +} /* end of Cudd_ReadVars */ + + +/** + @brief Reads the epsilon parameter of the manager. + + @details The epsilon parameter control the comparison between + floating point numbers. + + @sideeffect None + + @see Cudd_SetEpsilon + +*/ +CUDD_VALUE_TYPE +Cudd_ReadEpsilon( + DdManager * dd) +{ + return(dd->epsilon); + +} /* end of Cudd_ReadEpsilon */ + + +/** + @brief Sets the epsilon parameter of the manager to ep. + + @details The epsilon parameter control the comparison between + floating point numbers. + + @sideeffect None + + @see Cudd_ReadEpsilon + +*/ +void +Cudd_SetEpsilon( + DdManager * dd, + CUDD_VALUE_TYPE ep) +{ + dd->epsilon = ep; + +} /* end of Cudd_SetEpsilon */ + + +/** + @brief Reads the groupcheck parameter of the manager. + + @details The groupcheck parameter determines the aggregation + criterion in group sifting. + + @sideeffect None + + @see Cudd_SetGroupcheck + +*/ +Cudd_AggregationType +Cudd_ReadGroupcheck( + DdManager * dd) +{ + return(dd->groupcheck); + +} /* end of Cudd_ReadGroupCheck */ + + +/** + @brief Sets the parameter groupcheck of the manager to gc. + + @details The groupcheck parameter determines the aggregation + criterion in group sifting. + + @sideeffect None + + @see Cudd_ReadGroupCheck + +*/ +void +Cudd_SetGroupcheck( + DdManager * dd, + Cudd_AggregationType gc) +{ + dd->groupcheck = gc; + +} /* end of Cudd_SetGroupcheck */ + + +/** + @brief Tells whether garbage collection is enabled. + + @return 1 if garbage collection is enabled; 0 otherwise. + + @sideeffect None + + @see Cudd_EnableGarbageCollection Cudd_DisableGarbageCollection + +*/ +int +Cudd_GarbageCollectionEnabled( + DdManager * dd) +{ + return(dd->gcEnabled); + +} /* end of Cudd_GarbageCollectionEnabled */ + + +/** + @brief Enables garbage collection. + + @details Garbage collection is initially enabled. Therefore it is + necessary to call this function only if garbage collection has been + explicitly disabled. + + @sideeffect None + + @see Cudd_DisableGarbageCollection Cudd_GarbageCollectionEnabled + +*/ +void +Cudd_EnableGarbageCollection( + DdManager * dd) +{ + dd->gcEnabled = 1; + +} /* end of Cudd_EnableGarbageCollection */ + + +/** + @brief Disables garbage collection. + + @details Garbage collection is initially enabled. This function may + be called to disable it. However, garbage collection will still + occur when a new node must be created and no memory is left, or when + garbage collection is required for correctness. (E.g., before + reordering.) + + @sideeffect None + + @see Cudd_EnableGarbageCollection Cudd_GarbageCollectionEnabled + +*/ +void +Cudd_DisableGarbageCollection( + DdManager * dd) +{ + dd->gcEnabled = 0; + +} /* end of Cudd_DisableGarbageCollection */ + + +/** + @brief Tells whether dead nodes are counted towards triggering + reordering. + + @return 1 if dead nodes are counted; 0 otherwise. + + @sideeffect None + + @see Cudd_TurnOnCountDead Cudd_TurnOffCountDead + +*/ +int +Cudd_DeadAreCounted( + DdManager * dd) +{ + return(dd->countDead == 0 ? 1 : 0); + +} /* end of Cudd_DeadAreCounted */ + + +/** + @brief Causes the dead nodes to be counted towards triggering + reordering. + + @details This causes more frequent reorderings. By default dead + nodes are not counted. + + @sideeffect Changes the manager. + + @see Cudd_TurnOffCountDead Cudd_DeadAreCounted + +*/ +void +Cudd_TurnOnCountDead( + DdManager * dd) +{ + dd->countDead = 0; + +} /* end of Cudd_TurnOnCountDead */ + + +/** + @brief Causes the dead nodes not to be counted towards triggering + reordering. + + @details This causes less frequent reorderings. By default dead + nodes are not counted. Therefore there is no need to call this + function unless Cudd_TurnOnCountDead has been previously called. + + @sideeffect Changes the manager. + + @see Cudd_TurnOnCountDead Cudd_DeadAreCounted + +*/ +void +Cudd_TurnOffCountDead( + DdManager * dd) +{ + dd->countDead = ~0U; + +} /* end of Cudd_TurnOffCountDead */ + + +/** + @brief Returns the current value of the recombination parameter used + in group sifting. + + @details A larger (positive) value makes the aggregation of + variables due to the second difference criterion more likely. A + smaller (negative) value makes aggregation less likely. + + @sideeffect None + + @see Cudd_SetRecomb + +*/ +int +Cudd_ReadRecomb( + DdManager * dd) +{ + return(dd->recomb); + +} /* end of Cudd_ReadRecomb */ + + +/** + @brief Sets the value of the recombination parameter used in group + sifting. + + @details A larger (positive) value makes the aggregation of + variables due to the second difference criterion more likely. A + smaller (negative) value makes aggregation less likely. The default + value is 0. + + @sideeffect Changes the manager. + + @see Cudd_ReadRecomb + +*/ +void +Cudd_SetRecomb( + DdManager * dd, + int recomb) +{ + dd->recomb = recomb; + +} /* end of Cudd_SetRecomb */ + + +/** + @brief Returns the current value of the symmviolation parameter used + in group sifting. + + @details This parameter is used in group sifting to decide how many + violations to the symmetry conditions <code>f10 = f01</code> or + <code>f11 = f00</code> are tolerable when checking for aggregation + due to extended symmetry. The value should be between 0 and 100. A + small value causes fewer variables to be aggregated. The default + value is 0. + + @sideeffect None + + @see Cudd_SetSymmviolation + +*/ +int +Cudd_ReadSymmviolation( + DdManager * dd) +{ + return(dd->symmviolation); + +} /* end of Cudd_ReadSymmviolation */ + + +/** + @brief Sets the value of the symmviolation parameter used + in group sifting. + + @details This parameter is used in group sifting to decide how many + violations to the symmetry conditions <code>f10 = f01</code> or + <code>f11 = f00</code> are tolerable when checking for aggregation + due to extended symmetry. The value should be between 0 and 100. A + small value causes fewer variables to be aggregated. The default + value is 0. + + @sideeffect Changes the manager. + + @see Cudd_ReadSymmviolation + +*/ +void +Cudd_SetSymmviolation( + DdManager * dd, + int symmviolation) +{ + dd->symmviolation = symmviolation; + +} /* end of Cudd_SetSymmviolation */ + + +/** + @brief Returns the current value of the arcviolation parameter used + in group sifting. + + @details This parameter is used to decide how many arcs into + <code>y</code> not coming from <code>x</code> are tolerable when + checking for aggregation due to extended symmetry. The value should + be between 0 and 100. A small value causes fewer variables to be + aggregated. The default value is 0. + + @sideeffect None + + @see Cudd_SetArcviolation + +*/ +int +Cudd_ReadArcviolation( + DdManager * dd) +{ + return(dd->arcviolation); + +} /* end of Cudd_ReadArcviolation */ + + +/** + @brief Sets the value of the arcviolation parameter used + in group sifting. + + @details This parameter is used to decide how many arcs into + <code>y</code> not coming from <code>x</code> are tolerable when + checking for aggregation due to extended symmetry. The value should + be between 0 and 100. A small value causes fewer variables to be + aggregated. The default value is 0. + + @sideeffect None + + @see Cudd_ReadArcviolation + +*/ +void +Cudd_SetArcviolation( + DdManager * dd, + int arcviolation) +{ + dd->arcviolation = arcviolation; + +} /* end of Cudd_SetArcviolation */ + + +/** + @brief Reads the current size of the population used by the + genetic algorithm for variable reordering. + + @details A larger population size will cause the genetic algorithm + to take more time, but will generally produce better results. The + default value is 0, in which case the package uses three times the + number of variables as population size, with a maximum of 120. + + @sideeffect None + + @see Cudd_SetPopulationSize + +*/ +int +Cudd_ReadPopulationSize( + DdManager * dd) +{ + return(dd->populationSize); + +} /* end of Cudd_ReadPopulationSize */ + + +/** + @brief Sets the size of the population used by the + genetic algorithm for variable reordering. + + @details A larger population size will cause the genetic algorithm + to take more time, but will generally produce better results. The + default value is 0, in which case the package uses three times the + number of variables as population size, with a maximum of 120. + + @sideeffect Changes the manager. + + @see Cudd_ReadPopulationSize + +*/ +void +Cudd_SetPopulationSize( + DdManager * dd, + int populationSize) +{ + dd->populationSize = populationSize; + +} /* end of Cudd_SetPopulationSize */ + + +/** + @brief Reads the current number of crossovers used by the + genetic algorithm for variable reordering. + + @details A larger number of crossovers will cause the genetic + algorithm to take more time, but will generally produce better + results. The default value is 0, in which case the package uses + three times the number of variables as number of crossovers, with a + maximum of 60. + + @sideeffect None + + @see Cudd_SetNumberXovers + +*/ +int +Cudd_ReadNumberXovers( + DdManager * dd) +{ + return(dd->numberXovers); + +} /* end of Cudd_ReadNumberXovers */ + + +/** + @brief Sets the number of crossovers used by the + genetic algorithm for variable reordering. + + @details A larger number of crossovers will cause the genetic + algorithm to take more time, but will generally produce better + results. The default value is 0, in which case the package uses + three times the number of variables as number of crossovers, with a + maximum of 60. + + @sideeffect None + + @see Cudd_ReadNumberXovers + +*/ +void +Cudd_SetNumberXovers( + DdManager * dd, + int numberXovers) +{ + dd->numberXovers = numberXovers; + +} /* end of Cudd_SetNumberXovers */ + + +/** + @brief Returns the order randomization factor. + + @details If non-zero this factor is used to determine a perturbation + of the next reordering threshold. Larger factors cause larger + perturbations. + + @sideeffect None + + @see Cudd_SetOrderRandomization + +*/ +unsigned int +Cudd_ReadOrderRandomization( + DdManager * dd) +{ + return(dd->randomizeOrder); + +} /* end of Cudd_ReadOrderRandomization */ + + +/** + @brief Sets the order randomization factor. + + @sideeffect None + + @see Cudd_ReadOrderRandomization + +*/ +void +Cudd_SetOrderRandomization( + DdManager * dd, + unsigned int factor) +{ + dd->randomizeOrder = factor; + +} /* end of Cudd_SetOrderRandomization */ + + +/** + @brief Returns the memory in use by the manager measured in bytes. + + @sideeffect None + +*/ +size_t +Cudd_ReadMemoryInUse( + DdManager * dd) +{ + return(dd->memused); + +} /* end of Cudd_ReadMemoryInUse */ + + +/** + @brief Prints out statistics and settings for a CUDD manager. + + @return 1 if successful; 0 otherwise. + + @sideeffect None + +*/ +int +Cudd_PrintInfo( + DdManager * dd, + FILE * fp) +{ + int retval; + Cudd_ReorderingType autoMethod, autoMethodZ; + + /* Modifiable parameters. */ + retval = fprintf(fp,"**** CUDD modifiable parameters ****\n"); + if (retval == EOF) return(0); + retval = fprintf(fp,"Hard limit for cache size: %u\n", + Cudd_ReadMaxCacheHard(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Cache hit threshold for resizing: %u%%\n", + Cudd_ReadMinHit(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Garbage collection enabled: %s\n", + Cudd_GarbageCollectionEnabled(dd) ? "yes" : "no"); + if (retval == EOF) return(0); + retval = fprintf(fp,"Limit for fast unique table growth: %u\n", + Cudd_ReadLooseUpTo(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp, + "Maximum number of variables sifted per reordering: %d\n", + Cudd_ReadSiftMaxVar(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp, + "Maximum number of variable swaps per reordering: %d\n", + Cudd_ReadSiftMaxSwap(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Maximum growth while sifting a variable: %g\n", + Cudd_ReadMaxGrowth(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Dynamic reordering of BDDs enabled: %s\n", + Cudd_ReorderingStatus(dd,&autoMethod) ? "yes" : "no"); + if (retval == EOF) return(0); + retval = fprintf(fp,"Default BDD reordering method: %d\n", + (int) autoMethod); + if (retval == EOF) return(0); + retval = fprintf(fp,"Dynamic reordering of ZDDs enabled: %s\n", + Cudd_ReorderingStatusZdd(dd,&autoMethodZ) ? "yes" : "no"); + if (retval == EOF) return(0); + retval = fprintf(fp,"Default ZDD reordering method: %d\n", + (int) autoMethodZ); + if (retval == EOF) return(0); + retval = fprintf(fp,"Realignment of ZDDs to BDDs enabled: %s\n", + Cudd_zddRealignmentEnabled(dd) ? "yes" : "no"); + if (retval == EOF) return(0); + retval = fprintf(fp,"Realignment of BDDs to ZDDs enabled: %s\n", + Cudd_bddRealignmentEnabled(dd) ? "yes" : "no"); + if (retval == EOF) return(0); + retval = fprintf(fp,"Dead nodes counted in triggering reordering: %s\n", + Cudd_DeadAreCounted(dd) ? "yes" : "no"); + if (retval == EOF) return(0); + retval = fprintf(fp,"Group checking criterion: %u\n", + (unsigned int) Cudd_ReadGroupcheck(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Recombination threshold: %d\n", Cudd_ReadRecomb(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Symmetry violation threshold: %d\n", + Cudd_ReadSymmviolation(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Arc violation threshold: %d\n", + Cudd_ReadArcviolation(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"GA population size: %d\n", + Cudd_ReadPopulationSize(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of crossovers for GA: %d\n", + Cudd_ReadNumberXovers(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Next reordering threshold: %u\n", + Cudd_ReadNextReordering(dd)); + if (retval == EOF) return(0); + + /* Non-modifiable parameters. */ + retval = fprintf(fp,"**** CUDD non-modifiable parameters ****\n"); + if (retval == EOF) return(0); + retval = fprintf(fp,"Memory in use: %" PRIszt "\n", + Cudd_ReadMemoryInUse(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Peak number of nodes: %ld\n", + Cudd_ReadPeakNodeCount(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Peak number of live nodes: %d\n", + Cudd_ReadPeakLiveNodeCount(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of BDD variables: %d\n", dd->size); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of ZDD variables: %d\n", dd->sizeZ); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of cache entries: %u\n", dd->cacheSlots); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of cache look-ups: %.0f\n", + Cudd_ReadCacheLookUps(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of cache hits: %.0f\n", + Cudd_ReadCacheHits(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of cache insertions: %.0f\n", + dd->cacheinserts); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of cache collisions: %.0f\n", + dd->cachecollisions); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of cache deletions: %.0f\n", + dd->cachedeletions); + if (retval == EOF) return(0); + retval = cuddCacheProfile(dd,fp); + if (retval == 0) return(0); + retval = fprintf(fp,"Soft limit for cache size: %u\n", + Cudd_ReadMaxCache(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of buckets in unique table: %u\n", dd->slots); + if (retval == EOF) return(0); + retval = fprintf(fp,"Used buckets in unique table: %.2f%% (expected %.2f%%)\n", + 100.0 * Cudd_ReadUsedSlots(dd), + 100.0 * Cudd_ExpectedUsedSlots(dd)); + if (retval == EOF) return(0); +#ifdef DD_UNIQUE_PROFILE + retval = fprintf(fp,"Unique lookups: %.0f\n", dd->uniqueLookUps); + if (retval == EOF) return(0); + retval = fprintf(fp,"Unique links: %.0f (%g per lookup)\n", + dd->uniqueLinks, dd->uniqueLinks / dd->uniqueLookUps); + if (retval == EOF) return(0); +#endif + retval = fprintf(fp,"Number of BDD and ADD nodes: %u\n", dd->keys); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of ZDD nodes: %u\n", dd->keysZ); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of dead BDD and ADD nodes: %u\n", dd->dead); + if (retval == EOF) return(0); + retval = fprintf(fp,"Number of dead ZDD nodes: %u\n", dd->deadZ); + if (retval == EOF) return(0); + retval = fprintf(fp,"Total number of nodes allocated: %.0f\n", + dd->allocated); + if (retval == EOF) return(0); + retval = fprintf(fp,"Total number of nodes reclaimed: %.0f\n", + dd->reclaimed); + if (retval == EOF) return(0); +#ifdef DD_STATS + retval = fprintf(fp,"Nodes freed: %.0f\n", dd->nodesFreed); + if (retval == EOF) return(0); + retval = fprintf(fp,"Nodes dropped: %.0f\n", dd->nodesDropped); + if (retval == EOF) return(0); +#endif +#ifdef DD_COUNT + retval = fprintf(fp,"Number of recursive calls: %.0f\n", + Cudd_ReadRecursiveCalls(dd)); + if (retval == EOF) return(0); +#endif + retval = fprintf(fp,"Garbage collections so far: %d\n", + Cudd_ReadGarbageCollections(dd)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Time for garbage collection: %.2f sec\n", + ((double)Cudd_ReadGarbageCollectionTime(dd)/1000.0)); + if (retval == EOF) return(0); + retval = fprintf(fp,"Reorderings so far: %d\n", dd->reorderings); + if (retval == EOF) return(0); + retval = fprintf(fp,"Time for reordering: %.2f sec\n", + ((double)Cudd_ReadReorderingTime(dd)/1000.0)); + if (retval == EOF) return(0); +#ifdef DD_COUNT + retval = fprintf(fp,"Node swaps in reordering: %.0f\n", + Cudd_ReadSwapSteps(dd)); + if (retval == EOF) return(0); +#endif + + return(1); + +} /* end of Cudd_PrintInfo */ + + +/** + @brief Reports the peak number of nodes. + + @details This number includes node on the free list. At the peak, + the number of nodes on the free list is guaranteed to be less than + DD_MEM_CHUNK. + + @sideeffect None + + @see Cudd_ReadNodeCount Cudd_PrintInfo + +*/ +long +Cudd_ReadPeakNodeCount( + DdManager * dd) +{ + long count = 0; + DdNodePtr *scan = dd->memoryList; + + while (scan != NULL) { + count += DD_MEM_CHUNK; + scan = (DdNodePtr *) *scan; + } + return(count); + +} /* end of Cudd_ReadPeakNodeCount */ + + +/** + @brief Reports the peak number of live nodes. + + @sideeffect None + + @see Cudd_ReadNodeCount Cudd_PrintInfo Cudd_ReadPeakNodeCount + +*/ +int +Cudd_ReadPeakLiveNodeCount( + DdManager * dd) +{ + unsigned int live = dd->keys - dd->dead; + + if (live > dd->peakLiveNodes) { + dd->peakLiveNodes = live; + } + return((int)dd->peakLiveNodes); + +} /* end of Cudd_ReadPeakLiveNodeCount */ + + +/** + @brief Reports the number of nodes in BDDs and ADDs. + + @details This number does not include the isolated projection + functions and the unused constants. These nodes that are not counted + are not part of the DDs manipulated by the application. + + @sideeffect None + + @see Cudd_ReadPeakNodeCount Cudd_zddReadNodeCount + +*/ +long +Cudd_ReadNodeCount( + DdManager * dd) +{ + long count; + int i; + +#ifndef DD_NO_DEATH_ROW + cuddClearDeathRow(dd); +#endif + + count = (long) (dd->keys - dd->dead); + + /* Count isolated projection functions. Their number is subtracted + ** from the node count because they are not part of the BDDs. + */ + for (i=0; i < dd->size; i++) { + if (dd->vars[i]->ref == 1) count--; + } + /* Subtract from the count the unused constants. */ + if (DD_ZERO(dd)->ref == 1) count--; + if (DD_PLUS_INFINITY(dd)->ref == 1) count--; + if (DD_MINUS_INFINITY(dd)->ref == 1) count--; + + return(count); + +} /* end of Cudd_ReadNodeCount */ + + + +/** + @brief Reports the number of nodes in ZDDs. + + @details This number always includes the two constants 1 and 0. + + @sideeffect None + + @see Cudd_ReadPeakNodeCount Cudd_ReadNodeCount + +*/ +long +Cudd_zddReadNodeCount( + DdManager * dd) +{ + return((long)(dd->keysZ - dd->deadZ + 2)); + +} /* end of Cudd_zddReadNodeCount */ + + +/** + @brief Adds a function to a hook. + + @details A hook is a list of + application-provided functions called on certain occasions by the + package. + + @return 1 if the function is successfully added; 2 if the function + was already in the list; 0 otherwise. + + @sideeffect None + + @see Cudd_RemoveHook + +*/ +int +Cudd_AddHook( + DdManager * dd, + DD_HFP f, + Cudd_HookType where) +{ + DdHook **hook, *nextHook, *newHook; + + switch (where) { + case CUDD_PRE_GC_HOOK: + hook = &(dd->preGCHook); + break; + case CUDD_POST_GC_HOOK: + hook = &(dd->postGCHook); + break; + case CUDD_PRE_REORDERING_HOOK: + hook = &(dd->preReorderingHook); + break; + case CUDD_POST_REORDERING_HOOK: + hook = &(dd->postReorderingHook); + break; + default: + return(0); + } + /* Scan the list and find whether the function is already there. + ** If so, just return. */ + nextHook = *hook; + while (nextHook != NULL) { + if (nextHook->f == f) { + return(2); + } + hook = &(nextHook->next); + nextHook = nextHook->next; + } + /* The function was not in the list. Create a new item and append it + ** to the end of the list. */ + newHook = ALLOC(DdHook,1); + if (newHook == NULL) { + dd->errorCode = CUDD_MEMORY_OUT; + return(0); + } + newHook->next = NULL; + newHook->f = f; + *hook = newHook; + return(1); + +} /* end of Cudd_AddHook */ + + +/** + @brief Removes a function from a hook. + + @details A hook is a list of application-provided functions called + on certain occasions by the package. + + @return 1 if successful; 0 the function was not in the list. + + @sideeffect None + + @see Cudd_AddHook + +*/ +int +Cudd_RemoveHook( + DdManager * dd, + DD_HFP f, + Cudd_HookType where) +{ + DdHook **hook, *nextHook; + + switch (where) { + case CUDD_PRE_GC_HOOK: + hook = &(dd->preGCHook); + break; + case CUDD_POST_GC_HOOK: + hook = &(dd->postGCHook); + break; + case CUDD_PRE_REORDERING_HOOK: + hook = &(dd->preReorderingHook); + break; + case CUDD_POST_REORDERING_HOOK: + hook = &(dd->postReorderingHook); + break; + default: + return(0); + } + nextHook = *hook; + while (nextHook != NULL) { + if (nextHook->f == f) { + *hook = nextHook->next; + FREE(nextHook); + return(1); + } + hook = &(nextHook->next); + nextHook = nextHook->next; + } + + return(0); + +} /* end of Cudd_RemoveHook */ + + +/** + @brief Checks whether a function is in a hook. + + @details A hook is a list of application-provided functions called + on certain occasions by the package. + + @return 1 if the function is found; 0 otherwise. + + @sideeffect None + + @see Cudd_AddHook Cudd_RemoveHook + +*/ +int +Cudd_IsInHook( + DdManager * dd, + DD_HFP f, + Cudd_HookType where) +{ + DdHook *hook; + + switch (where) { + case CUDD_PRE_GC_HOOK: + hook = dd->preGCHook; + break; + case CUDD_POST_GC_HOOK: + hook = dd->postGCHook; + break; + case CUDD_PRE_REORDERING_HOOK: + hook = dd->preReorderingHook; + break; + case CUDD_POST_REORDERING_HOOK: + hook = dd->postReorderingHook; + break; + default: + return(0); + } + /* Scan the list and find whether the function is already there. */ + while (hook != NULL) { + if (hook->f == f) { + return(1); + } + hook = hook->next; + } + return(0); + +} /* end of Cudd_IsInHook */ + + +/** + @brief Sample hook function to call before reordering. + + @details Prints on the manager's stdout reordering method and initial size. + + @return 1 if successful; 0 otherwise. + + @sideeffect None + + @see Cudd_StdPostReordHook + +*/ +int +Cudd_StdPreReordHook( + DdManager *dd, + const char *str, + void *data) +{ + Cudd_ReorderingType method = (Cudd_ReorderingType) (ptruint) data; + int retval; + + retval = fprintf(dd->out,"%s reordering with ", str); + if (retval == EOF) return(0); + switch (method) { + case CUDD_REORDER_SIFT_CONVERGE: + case CUDD_REORDER_SYMM_SIFT_CONV: + case CUDD_REORDER_GROUP_SIFT_CONV: + case CUDD_REORDER_WINDOW2_CONV: + case CUDD_REORDER_WINDOW3_CONV: + case CUDD_REORDER_WINDOW4_CONV: + case CUDD_REORDER_LINEAR_CONVERGE: + retval = fprintf(dd->out,"converging "); + if (retval == EOF) return(0); + break; + default: + break; + } + switch (method) { + case CUDD_REORDER_RANDOM: + case CUDD_REORDER_RANDOM_PIVOT: + retval = fprintf(dd->out,"random"); + break; + case CUDD_REORDER_SIFT: + case CUDD_REORDER_SIFT_CONVERGE: + retval = fprintf(dd->out,"sifting"); + break; + case CUDD_REORDER_SYMM_SIFT: + case CUDD_REORDER_SYMM_SIFT_CONV: + retval = fprintf(dd->out,"symmetric sifting"); + break; + case CUDD_REORDER_LAZY_SIFT: + retval = fprintf(dd->out,"lazy sifting"); + break; + case CUDD_REORDER_GROUP_SIFT: + case CUDD_REORDER_GROUP_SIFT_CONV: + retval = fprintf(dd->out,"group sifting"); + break; + case CUDD_REORDER_WINDOW2: + case CUDD_REORDER_WINDOW3: + case CUDD_REORDER_WINDOW4: + case CUDD_REORDER_WINDOW2_CONV: + case CUDD_REORDER_WINDOW3_CONV: + case CUDD_REORDER_WINDOW4_CONV: + retval = fprintf(dd->out,"window"); + break; + case CUDD_REORDER_ANNEALING: + retval = fprintf(dd->out,"annealing"); + break; + case CUDD_REORDER_GENETIC: + retval = fprintf(dd->out,"genetic"); + break; + case CUDD_REORDER_LINEAR: + case CUDD_REORDER_LINEAR_CONVERGE: + retval = fprintf(dd->out,"linear sifting"); + break; + case CUDD_REORDER_EXACT: + retval = fprintf(dd->out,"exact"); + break; + default: + return(0); + } + if (retval == EOF) return(0); + + retval = fprintf(dd->out,": from %ld to ... ", strcmp(str, "BDD") == 0 ? + Cudd_ReadNodeCount(dd) : Cudd_zddReadNodeCount(dd)); + if (retval == EOF) return(0); + fflush(dd->out); + return(1); + +} /* end of Cudd_StdPreReordHook */ + + +/** + @brief Sample hook function to call after reordering. + + @details Prints on the manager's stdout final size and reordering time. + + @return 1 if successful; 0 otherwise. + + @sideeffect None + + @see Cudd_StdPreReordHook + +*/ +int +Cudd_StdPostReordHook( + DdManager *dd, + const char *str, + void *data) +{ + unsigned long initialTime = (unsigned long) (ptruint) data; + int retval; + unsigned long finalTime = util_cpu_time(); + double totalTimeSec = (double)(finalTime - initialTime) / 1000.0; + + retval = fprintf(dd->out,"%ld nodes in %g sec\n", strcmp(str, "BDD") == 0 ? + Cudd_ReadNodeCount(dd) : Cudd_zddReadNodeCount(dd), + totalTimeSec); + if (retval == EOF) return(0); + retval = fflush(dd->out); + if (retval == EOF) return(0); + return(1); + +} /* end of Cudd_StdPostReordHook */ + + +/** + @brief Enables reporting of reordering stats. + + @return 1 if successful; 0 otherwise. + + @sideeffect Installs functions in the pre-reordering and post-reordering + hooks. + + @see Cudd_DisableReorderingReporting Cudd_ReorderingReporting + +*/ +int +Cudd_EnableReorderingReporting( + DdManager *dd) +{ + if (!Cudd_AddHook(dd, Cudd_StdPreReordHook, CUDD_PRE_REORDERING_HOOK)) { + return(0); + } + if (!Cudd_AddHook(dd, Cudd_StdPostReordHook, CUDD_POST_REORDERING_HOOK)) { + return(0); + } + return(1); + +} /* end of Cudd_EnableReorderingReporting */ + + +/** + @brief Disables reporting of reordering stats. + + @return 1 if successful; 0 otherwise. + + @sideeffect Removes functions from the pre-reordering and post-reordering + hooks. + + @see Cudd_EnableReorderingReporting Cudd_ReorderingReporting + +*/ +int +Cudd_DisableReorderingReporting( + DdManager *dd) +{ + if (!Cudd_RemoveHook(dd, Cudd_StdPreReordHook, CUDD_PRE_REORDERING_HOOK)) { + return(0); + } + if (!Cudd_RemoveHook(dd, Cudd_StdPostReordHook, CUDD_POST_REORDERING_HOOK)) { + return(0); + } + return(1); + +} /* end of Cudd_DisableReorderingReporting */ + + +/** + @brief Returns 1 if reporting of reordering stats is enabled; 0 + otherwise. + + @sideeffect none + + @see Cudd_EnableReorderingReporting Cudd_DisableReorderingReporting + +*/ +int +Cudd_ReorderingReporting( + DdManager *dd) +{ + return(Cudd_IsInHook(dd, Cudd_StdPreReordHook, CUDD_PRE_REORDERING_HOOK)); + +} /* end of Cudd_ReorderingReporting */ + + +/** + @brief Hook function to print the current variable order. + + @details It may be called before or after reordering. Prints on the + manager's stdout a parenthesized list that describes the variable + groups. + + @return 1 if successful; 0 otherwise. + + @sideeffect None + + @see Cudd_StdPreReordHook + +*/ +int +Cudd_PrintGroupedOrder( + DdManager * dd, + const char *str, + void *data) +{ + (void) data; /* avoid warning */ + int isBdd = strcmp(str, "ZDD"); + MtrNode *tree = isBdd ? dd->tree : dd->treeZ; + int *invperm = isBdd ? dd->invperm : dd->invpermZ; + int size = isBdd ? dd->size : dd->sizeZ; + if (tree == NULL) { + int i, retval; + for (i=0; i < size; i++) { + retval = fprintf(dd->out, "%c%d", i==0 ? '(' : ',', invperm[i]); + if (retval == EOF) return(0); + } + retval = fprintf(dd->out,")\n"); + return (retval != EOF); + } else { + return Mtr_PrintGroupedOrder(tree,invperm,dd->out); + } + +} /* end of Cudd_PrintGroupedOrder */ + + +/** + @brief Enables monitoring of ordering. + + @return 1 if successful; 0 otherwise. + + @sideeffect Installs functions in the pre-reordering and post-reordering + hooks. + + @see Cudd_EnableReorderingReporting + +*/ +int +Cudd_EnableOrderingMonitoring( + DdManager *dd) +{ + if (!Cudd_AddHook(dd, Cudd_PrintGroupedOrder, CUDD_PRE_REORDERING_HOOK)) { + return(0); + } + if (!Cudd_AddHook(dd, Cudd_StdPreReordHook, CUDD_PRE_REORDERING_HOOK)) { + return(0); + } + if (!Cudd_AddHook(dd, Cudd_StdPostReordHook, CUDD_POST_REORDERING_HOOK)) { + return(0); + } + if (!Cudd_AddHook(dd, Cudd_PrintGroupedOrder, CUDD_POST_REORDERING_HOOK)) { + return(0); + } + return(1); + +} /* end of Cudd_EnableOrderingMonitoring */ + + +/** + @brief Disables monitoring of ordering. + + @return 1 if successful; 0 otherwise. + + @sideeffect Removes functions from the pre-reordering and post-reordering + hooks. + + @see Cudd_EnableOrderingMonitoring + +*/ +int +Cudd_DisableOrderingMonitoring( + DdManager *dd) +{ + if (!Cudd_RemoveHook(dd, Cudd_StdPreReordHook, CUDD_PRE_REORDERING_HOOK)) { + return(0); + } + if (!Cudd_RemoveHook(dd, Cudd_PrintGroupedOrder, CUDD_PRE_REORDERING_HOOK)) { + return(0); + } + if (!Cudd_RemoveHook(dd, Cudd_PrintGroupedOrder, CUDD_POST_REORDERING_HOOK)) { + return(0); + } + if (!Cudd_RemoveHook(dd, Cudd_StdPostReordHook, CUDD_POST_REORDERING_HOOK)) { + return(0); + } + return(1); + +} /* end of Cudd_DisableOrderingMonitoring */ + + +/** + @brief Returns 1 if monitoring of ordering is enabled; 0 otherwise. + + @sideeffect none + + @see Cudd_EnableOrderingMonitoring Cudd_DisableOrderingMonitoring + +*/ +int +Cudd_OrderingMonitoring( + DdManager *dd) +{ + return(Cudd_IsInHook(dd, Cudd_PrintGroupedOrder, CUDD_PRE_REORDERING_HOOK)); + +} /* end of Cudd_OrderingMonitoring */ + + +/** + @brief Sets the application hook. + + @sideeffect None + + @see Cudd_ReadApplicationHook + +*/ +void +Cudd_SetApplicationHook( + DdManager *dd, + void * value) +{ + dd->hooks = value; + +} /* end of Cudd_SetApplicationHook */ + + +/** + @brief Reads the application hook. + + @sideeffect None + + @see Cudd_SetApplicationHook + +*/ +void * +Cudd_ReadApplicationHook( + DdManager *dd) +{ + return(dd->hooks); + +} /* end of Cudd_ReadApplicationHook */ + + +/** + @brief Returns the code of the last error. + + @details The error codes are defined in cudd.h. + + @sideeffect None + + @see Cudd_ClearErrorCode + +*/ +Cudd_ErrorType +Cudd_ReadErrorCode( + DdManager *dd) +{ + return(dd->errorCode); + +} /* end of Cudd_ReadErrorCode */ + + +/** + @brief Clear the error code of a manager. + + @sideeffect None + + @see Cudd_ReadErrorCode + +*/ +void +Cudd_ClearErrorCode( + DdManager *dd) +{ + dd->errorCode = CUDD_NO_ERROR; + +} /* end of Cudd_ClearErrorCode */ + + +/** + @brief Installs a handler for failed memory allocations. + + @details Changing the handler only has an effect if the wrappers + in safe_mem.c are in use. + + @return the current handler. +*/ +DD_OOMFP +Cudd_InstallOutOfMemoryHandler( + DD_OOMFP newHandler) +{ + DD_OOMFP oldHandler = MMoutOfMemory; + MMoutOfMemory = newHandler; + return oldHandler; + +} /* end of Cudd_InstallOutOfMemoryHandler */ + + +/** + @brief Reads the stdout of a manager. + + @details This is the file pointer to which messages normally going + to stdout are written. It is initialized to stdout. Cudd_SetStdout + allows the application to redirect it. + + @sideeffect None + + @see Cudd_SetStdout Cudd_ReadStderr + +*/ +FILE * +Cudd_ReadStdout( + DdManager *dd) +{ + return(dd->out); + +} /* end of Cudd_ReadStdout */ + + +/** + @brief Sets the stdout of a manager. + + @sideeffect None + + @see Cudd_ReadStdout Cudd_SetStderr + +*/ +void +Cudd_SetStdout( + DdManager *dd, + FILE *fp) +{ + dd->out = fp; + +} /* end of Cudd_SetStdout */ + + +/** + @brief Reads the stderr of a manager. + + @details This is the file pointer to which messages normally going + to stderr are written. It is initialized to stderr. Cudd_SetStderr + allows the application to redirect it. + + @sideeffect None + + @see Cudd_SetStderr Cudd_ReadStdout + +*/ +FILE * +Cudd_ReadStderr( + DdManager *dd) +{ + return(dd->err); + +} /* end of Cudd_ReadStderr */ + + +/** + @brief Sets the stderr of a manager. + + @sideeffect None + + @see Cudd_ReadStderr Cudd_SetStdout + +*/ +void +Cudd_SetStderr( + DdManager *dd, + FILE *fp) +{ + dd->err = fp; + +} /* end of Cudd_SetStderr */ + + +/** + @brief Returns the threshold for the next dynamic reordering. + + @details The threshold is in terms of number of nodes and is in + effect only if reordering is enabled. The count does not include the + dead nodes, unless the countDead parameter of the manager has been + changed from its default setting. + + @sideeffect None + + @see Cudd_SetNextReordering + +*/ +unsigned int +Cudd_ReadNextReordering( + DdManager *dd) +{ + return(dd->nextDyn); + +} /* end of Cudd_ReadNextReordering */ + + +/** + @brief Sets the threshold for the next dynamic reordering. + + @details The threshold is in terms of number of nodes and is in + effect only if reordering is enabled. The count does not include the + dead nodes, unless the countDead parameter of the manager has been + changed from its default setting. + + @sideeffect None + + @see Cudd_ReadNextReordering + +*/ +void +Cudd_SetNextReordering( + DdManager *dd, + unsigned int next) +{ + dd->nextDyn = next; + +} /* end of Cudd_SetNextReordering */ + + +/** + @brief Reads the number of elementary reordering steps. + + @sideeffect none + +*/ +double +Cudd_ReadSwapSteps( + DdManager *dd) +{ +#ifdef DD_COUNT + return(dd->swapSteps); +#else + (void) dd; /* avoid warning */ + return(-1); +#endif + +} /* end of Cudd_ReadSwapSteps */ + + +/** + @brief Reads the maximum allowed number of live nodes. + + @details When this number is exceeded, the package returns NULL. + + @sideeffect none + + @see Cudd_SetMaxLive + +*/ +unsigned int +Cudd_ReadMaxLive( + DdManager *dd) +{ + return(dd->maxLive); + +} /* end of Cudd_ReadMaxLive */ + + +/** + @brief Sets the maximum allowed number of live nodes. + + @details When this number is exceeded, the package returns NULL. + + @sideeffect none + + @see Cudd_ReadMaxLive + +*/ +void +Cudd_SetMaxLive( + DdManager *dd, + unsigned int maxLive) +{ + dd->maxLive = maxLive; + +} /* end of Cudd_SetMaxLive */ + + +/** + @brief Reads the maximum allowed memory. + + @details When this number is exceeded, the package returns NULL. + + @sideeffect none + + @see Cudd_SetMaxMemory + +*/ +size_t +Cudd_ReadMaxMemory( + DdManager *dd) +{ + return(dd->maxmemhard); + +} /* end of Cudd_ReadMaxMemory */ + + +/** + @brief Sets the maximum allowed memory. + + @details When this number is exceeded, the package returns NULL. + + @return the previous limit. + + @sideeffect none + + @see Cudd_ReadMaxMemory + +*/ +size_t +Cudd_SetMaxMemory( + DdManager *dd, + size_t maxMemory) +{ + size_t oldLimit = dd->maxmemhard; + dd->maxmemhard = maxMemory; + return oldLimit; + +} /* end of Cudd_SetMaxMemory */ + + +/** + @brief Prevents sifting of a variable. + + @details This function sets a flag to prevent sifting of a + variable. + + @return 1 if successful; 0 otherwise (i.e., invalid variable index). + + @sideeffect Changes the "bindVar" flag in DdSubtable. + + @see Cudd_bddUnbindVar + +*/ +int +Cudd_bddBindVar( + DdManager *dd /**< manager */, + int index /**< variable index */) +{ + if (index >= dd->size || index < 0) return(0); + dd->subtables[dd->perm[index]].bindVar = 1; + return(1); + +} /* end of Cudd_bddBindVar */ + + +/** + @brief Allows the sifting of a variable. + + @details This function resets the flag that prevents the sifting + of a variable. In successive variable reorderings, the variable will + NOT be skipped, that is, sifted. Initially all variables can be + sifted. It is necessary to call this function only to re-enable + sifting after a call to Cudd_bddBindVar. + + @return 1 if successful; 0 otherwise (i.e., invalid variable index). + + @sideeffect Changes the "bindVar" flag in DdSubtable. + + @see Cudd_bddBindVar + +*/ +int +Cudd_bddUnbindVar( + DdManager *dd /**< manager */, + int index /**< variable index */) +{ + if (index >= dd->size || index < 0) return(0); + dd->subtables[dd->perm[index]].bindVar = 0; + return(1); + +} /* end of Cudd_bddUnbindVar */ + + +/** + @brief Tells whether a variable can be sifted. + + @details This function returns 1 if a variable is enabled for + sifting. Initially all variables can be sifted. This function + returns 0 if there has been a previous call to Cudd_bddBindVar for + that variable not followed by a call to Cudd_bddUnbindVar. The + function returns 0 also in the case in which the index of the + variable is out of bounds. + + @sideeffect none + + @see Cudd_bddBindVar Cudd_bddUnbindVar + +*/ +int +Cudd_bddVarIsBound( + DdManager *dd /**< manager */, + int index /**< variable index */) +{ + if (index >= dd->size || index < 0) return(0); + return(dd->subtables[dd->perm[index]].bindVar); + +} /* end of Cudd_bddVarIsBound */ + + +/** + @brief Sets a variable type to primary input. + + @details The variable type is used by lazy sifting. + + @return 1 if successful; 0 otherwise. + + @sideeffect modifies the manager + + @see Cudd_bddSetPsVar Cudd_bddSetNsVar Cudd_bddIsPiVar + +*/ +int +Cudd_bddSetPiVar( + DdManager *dd /**< manager */, + int index /**< variable index */) +{ + if (index >= dd->size || index < 0) return (0); + dd->subtables[dd->perm[index]].varType = CUDD_VAR_PRIMARY_INPUT; + return(1); + +} /* end of Cudd_bddSetPiVar */ + + +/** + @brief Sets a variable type to present state. + + @details The variable type is used by lazy sifting. + + @return 1 if successful; 0 otherwise. + + @sideeffect modifies the manager + + @see Cudd_bddSetPiVar Cudd_bddSetNsVar Cudd_bddIsPsVar + +*/ +int +Cudd_bddSetPsVar( + DdManager *dd /**< manager */, + int index /**< variable index */) +{ + if (index >= dd->size || index < 0) return (0); + dd->subtables[dd->perm[index]].varType = CUDD_VAR_PRESENT_STATE; + return(1); + +} /* end of Cudd_bddSetPsVar */ + + +/** + @brief Sets a variable type to next state. + + @details The variable type is used by lazy sifting. + + @return 1 if successful; 0 otherwise. + + @sideeffect modifies the manager + + @see Cudd_bddSetPiVar Cudd_bddSetPsVar Cudd_bddIsNsVar + +*/ +int +Cudd_bddSetNsVar( + DdManager *dd /**< manager */, + int index /**< variable index */) +{ + if (index >= dd->size || index < 0) return (0); + dd->subtables[dd->perm[index]].varType = CUDD_VAR_NEXT_STATE; + return(1); + +} /* end of Cudd_bddSetNsVar */ + + +/** + @brief Checks whether a variable is primary input. + + @return 1 if the variable's type is primary input; 0 if the variable + exists but is not a primary input; -1 if the variable does not + exist. + + @sideeffect none + + @see Cudd_bddSetPiVar Cudd_bddIsPsVar Cudd_bddIsNsVar + +*/ +int +Cudd_bddIsPiVar( + DdManager *dd /**< manager */, + int index /**< variable index */) +{ + if (index >= dd->size || index < 0) return -1; + return (dd->subtables[dd->perm[index]].varType == CUDD_VAR_PRIMARY_INPUT); + +} /* end of Cudd_bddIsPiVar */ + + +/** + @brief Checks whether a variable is present state. + + @return 1 if the variable's type is present state; 0 if the variable + exists but is not a present state; -1 if the variable does not + exist. + + @sideeffect none + + @see Cudd_bddSetPsVar Cudd_bddIsPiVar Cudd_bddIsNsVar + +*/ +int +Cudd_bddIsPsVar( + DdManager *dd, + int index) +{ + if (index >= dd->size || index < 0) return -1; + return (dd->subtables[dd->perm[index]].varType == CUDD_VAR_PRESENT_STATE); + +} /* end of Cudd_bddIsPsVar */ + + +/** + @brief Checks whether a variable is next state. + + @return 1 if the variable's type is present state; 0 if the variable + exists but is not a present state; -1 if the variable does not + exist. + + @sideeffect none + + @see Cudd_bddSetNsVar Cudd_bddIsPiVar Cudd_bddIsPsVar + +*/ +int +Cudd_bddIsNsVar( + DdManager *dd, + int index) +{ + if (index >= dd->size || index < 0) return -1; + return (dd->subtables[dd->perm[index]].varType == CUDD_VAR_NEXT_STATE); + +} /* end of Cudd_bddIsNsVar */ + + +/** + @brief Sets a corresponding pair index for a given index. + + @details These pair indices are present and next state variable. + + @return 1 if successful; 0 otherwise. + + @sideeffect modifies the manager + + @see Cudd_bddReadPairIndex + +*/ +int +Cudd_bddSetPairIndex( + DdManager *dd /**< manager */, + int index /**< variable index */, + int pairIndex /**< corresponding variable index */) +{ + if (index >= dd->size || index < 0) return(0); + dd->subtables[dd->perm[index]].pairIndex = pairIndex; + return(1); + +} /* end of Cudd_bddSetPairIndex */ + + +/** + @brief Reads a corresponding pair index for a given index. + + @details These pair indices are present and next state variable. + + @return the corresponding variable index if the variable exists; -1 + otherwise. + + @sideeffect modifies the manager + + @see Cudd_bddSetPairIndex + +*/ +int +Cudd_bddReadPairIndex( + DdManager *dd, + int index) +{ + if (index >= dd->size || index < 0) return -1; + return dd->subtables[dd->perm[index]].pairIndex; + +} /* end of Cudd_bddReadPairIndex */ + + +/** + @brief Sets a variable to be grouped. + + @details This function is used for lazy sifting. + + @return 1 if successful; 0 otherwise. + + @sideeffect modifies the manager + + @see Cudd_bddSetVarHardGroup Cudd_bddResetVarToBeGrouped + +*/ +int +Cudd_bddSetVarToBeGrouped( + DdManager *dd, + int index) +{ + if (index >= dd->size || index < 0) return(0); + if (dd->subtables[dd->perm[index]].varToBeGrouped <= CUDD_LAZY_SOFT_GROUP) { + dd->subtables[dd->perm[index]].varToBeGrouped = CUDD_LAZY_SOFT_GROUP; + } + return(1); + +} /* end of Cudd_bddSetVarToBeGrouped */ + + +/** + @brief Sets a variable to be a hard group. + + @details This function is used for lazy sifting. + + @return 1 if successful; 0 otherwise. + + @sideeffect modifies the manager + + @see Cudd_bddSetVarToBeGrouped Cudd_bddResetVarToBeGrouped + Cudd_bddIsVarHardGroup + +*/ +int +Cudd_bddSetVarHardGroup( + DdManager *dd, + int index) +{ + if (index >= dd->size || index < 0) return(0); + dd->subtables[dd->perm[index]].varToBeGrouped = CUDD_LAZY_HARD_GROUP; + return(1); + +} /* end of Cudd_bddSetVarHardGrouped */ + + +/** + @brief Resets a variable not to be grouped. + + @details This function is used for lazy sifting. + + @return 1 if successful; 0 otherwise. + + @sideeffect modifies the manager + + @see Cudd_bddSetVarToBeGrouped Cudd_bddSetVarHardGroup + +*/ +int +Cudd_bddResetVarToBeGrouped( + DdManager *dd, + int index) +{ + if (index >= dd->size || index < 0) return(0); + if (dd->subtables[dd->perm[index]].varToBeGrouped <= + CUDD_LAZY_SOFT_GROUP) { + dd->subtables[dd->perm[index]].varToBeGrouped = CUDD_LAZY_NONE; + } + return(1); + +} /* end of Cudd_bddResetVarToBeGrouped */ + + +/** + @brief Checks whether a variable is set to be grouped. + + @details This function is used for lazy sifting. + + @sideeffect none + +*/ +int +Cudd_bddIsVarToBeGrouped( + DdManager *dd, + int index) +{ + if (index >= dd->size || index < 0) return(-1); + if (dd->subtables[dd->perm[index]].varToBeGrouped == CUDD_LAZY_UNGROUP) + return(0); + else + return(dd->subtables[dd->perm[index]].varToBeGrouped); + +} /* end of Cudd_bddIsVarToBeGrouped */ + + +/** + @brief Sets a variable to be ungrouped. + + @details This function is used for lazy sifting. + + @return 1 if successful; 0 otherwise. + + @sideeffect modifies the manager + + @see Cudd_bddIsVarToBeUngrouped + +*/ +int +Cudd_bddSetVarToBeUngrouped( + DdManager *dd, + int index) +{ + if (index >= dd->size || index < 0) return(0); + dd->subtables[dd->perm[index]].varToBeGrouped = CUDD_LAZY_UNGROUP; + return(1); + +} /* end of Cudd_bddSetVarToBeGrouped */ + + +/** + @brief Checks whether a variable is set to be ungrouped. + + @details This function is used for lazy sifting. + + @return 1 if the variable is marked to be ungrouped; 0 if the + variable exists, but it is not marked to be ungrouped; -1 if the + variable does not exist. + + @sideeffect none + + @see Cudd_bddSetVarToBeUngrouped + +*/ +int +Cudd_bddIsVarToBeUngrouped( + DdManager *dd, + int index) +{ + if (index >= dd->size || index < 0) return(-1); + return dd->subtables[dd->perm[index]].varToBeGrouped == CUDD_LAZY_UNGROUP; + +} /* end of Cudd_bddIsVarToBeGrouped */ + + +/** + @brief Checks whether a variable is set to be in a hard group. + + @details This function is used for lazy sifting. + + @return 1 if the variable is marked to be in a hard group; 0 if the + variable exists, but it is not marked to be in a hard group; -1 if + the variable does not exist. + + @sideeffect none + + @see Cudd_bddSetVarHardGroup + +*/ +int +Cudd_bddIsVarHardGroup( + DdManager *dd, + int index) +{ + if (index >= dd->size || index < 0) return(-1); + if (dd->subtables[dd->perm[index]].varToBeGrouped == CUDD_LAZY_HARD_GROUP) + return(1); + return(0); + +} /* end of Cudd_bddIsVarToBeGrouped */ + + +/*---------------------------------------------------------------------------*/ +/* Definition of internal functions */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Definition of static functions */ +/*---------------------------------------------------------------------------*/ + + +/** + @brief Fixes a variable group tree. + + @sideeffect Changes the variable group tree. + +*/ +static void +fixVarTree( + MtrNode * treenode, + int * perm, + int size) +{ + treenode->index = treenode->low; + treenode->low = ((int) treenode->index < size) ? + (MtrHalfWord) perm[treenode->index] : treenode->index; + if (treenode->child != NULL) + fixVarTree(treenode->child, perm, size); + if (treenode->younger != NULL) + fixVarTree(treenode->younger, perm, size); + return; + +} /* end of fixVarTree */ + + +/** + @brief Adds multiplicity groups to a %ZDD variable group tree. + + @details This function creates the groups for set of %ZDD variables + (whose cardinality is given by parameter multiplicity) that are + created for each %BDD variable in Cudd_zddVarsFromBddVars. The crux + of the matter is to determine the index each new group. (The index + of the first variable in the group.) We first build all the groups + for the children of a node, and then deal with the %ZDD variables + that are directly attached to the node. The problem for these is + that the tree itself does not provide information on their position + inside the group. While we deal with the children of the node, + therefore, we keep track of all the positions they occupy. The + remaining positions in the tree can be freely used. Also, we keep + track of all the variables placed in the children. All the remaining + variables are directly attached to the group. We can then place any + pair of variables not yet grouped in any pair of available positions + in the node. + + @return 1 if successful; 0 otherwise. + + @sideeffect Changes the variable group tree. + + @see Cudd_zddVarsFromBddVars + +*/ +static int +addMultiplicityGroups( + DdManager *dd /**< manager */, + MtrNode *treenode /**< current tree node */, + int multiplicity /**< how many %ZDD vars per %BDD var */, + char *vmask /**< variable pairs for which a group has been already built */, + char *lmask /**< levels for which a group has already been built*/) +{ + int startV, stopV, startL; + int i, j; + MtrNode *auxnode = treenode; + + while (auxnode != NULL) { + if (auxnode->child != NULL) { + addMultiplicityGroups(dd,auxnode->child,multiplicity,vmask,lmask); + } + /* Build remaining groups. */ + startV = dd->permZ[auxnode->index] / multiplicity; + startL = auxnode->low / multiplicity; + stopV = startV + auxnode->size / multiplicity; + /* Walk down vmask starting at startV and build missing groups. */ + for (i = startV, j = startL; i < stopV; i++) { + if (vmask[i] == 0) { + MtrNode *node; + while (lmask[j] == 1) j++; + node = Mtr_MakeGroup(auxnode, j * multiplicity, multiplicity, + MTR_FIXED); + if (node == NULL) { + return(0); + } + node->index = dd->invpermZ[i * multiplicity]; + vmask[i] = 1; + lmask[j] = 1; + } + } + auxnode = auxnode->younger; + } + return(1); + +} /* end of addMultiplicityGroups */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddAbs.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddAbs.c similarity index 69% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddAbs.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddAddAbs.c index 7d774586c..db284f7b4 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddAbs.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddAbs.c @@ -1,35 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddAddAbs.c] - - PackageName [cudd] - - Synopsis [Quantification functions for ADDs.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_addExistAbstract() - <li> Cudd_addUnivAbstract() - <li> Cudd_addOrAbstract() - <li> Cudd_addMinAbstract() - <li> Cudd_addMaxAbstract() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAddExistAbstractRecur() - <li> cuddAddUnivAbstractRecur() - <li> cuddAddOrAbstractRecur() - <li> cuddAddMinAbstractRecur() - <li> cuddAddMaxAbstractRecur() - </ul> - Static procedures included in this module: - <ul> - <li> addCheckPositiveCube() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Quantification functions for ADDs. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -59,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -85,18 +65,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddAddAbs.c,v 1.16 2012/02/05 01:07:18 fabio Exp $"; -#endif - -static DdNode *two; /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -104,27 +78,27 @@ static DdNode *two; static int addCheckPositiveCube (DdManager *manager, DdNode *cube); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Existentially Abstracts all the variables in cube from f. - Synopsis [Existentially Abstracts all the variables in cube from f.] + @details Abstracts all the variables in cube from f by summing + over all possible values taken by the variables. - Description [Abstracts all the variables in cube from f by summing - over all possible values taken by the variables. Returns the - abstracted ADD.] + @return the abstracted %ADD. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addUnivAbstract Cudd_bddExistAbstract - Cudd_addOrAbstract] + @see Cudd_addUnivAbstract Cudd_bddExistAbstract + Cudd_addOrAbstract -******************************************************************************/ +*/ DdNode * Cudd_addExistAbstract( DdManager * manager, @@ -133,10 +107,6 @@ Cudd_addExistAbstract( { DdNode *res; - two = cuddUniqueConst(manager,(CUDD_VALUE_TYPE) 2); - if (two == NULL) return(NULL); - cuddRef(two); - if (addCheckPositiveCube(manager, cube) == 0) { (void) fprintf(manager->err,"Error: Can only abstract cubes"); return(NULL); @@ -146,34 +116,29 @@ Cudd_addExistAbstract( manager->reordered = 0; res = cuddAddExistAbstractRecur(manager, f, cube); } while (manager->reordered == 1); - - if (res == NULL) { - Cudd_RecursiveDeref(manager,two); - return(NULL); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); } - cuddRef(res); - Cudd_RecursiveDeref(manager,two); - cuddDeref(res); return(res); } /* end of Cudd_addExistAbstract */ -/**Function******************************************************************** +/** + @brief Universally Abstracts all the variables in cube from f. - Synopsis [Universally Abstracts all the variables in cube from f.] + @details Abstracts all the variables in cube from f by taking + the product over all possible values taken by the variable. - Description [Abstracts all the variables in cube from f by taking - the product over all possible values taken by the variable. Returns - the abstracted ADD if successful; NULL otherwise.] + @return the abstracted %ADD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addExistAbstract Cudd_bddUnivAbstract - Cudd_addOrAbstract] + @see Cudd_addExistAbstract Cudd_bddUnivAbstract + Cudd_addOrAbstract -******************************************************************************/ +*/ DdNode * Cudd_addUnivAbstract( DdManager * manager, @@ -191,27 +156,30 @@ Cudd_addUnivAbstract( manager->reordered = 0; res = cuddAddUnivAbstractRecur(manager, f, cube); } while (manager->reordered == 1); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_addUnivAbstract */ -/**Function******************************************************************** - - Synopsis [Disjunctively abstracts all the variables in cube from the - 0-1 ADD f.] +/** + @brief Disjunctively abstracts all the variables in cube from the + 0-1 %ADD f. - Description [Abstracts all the variables in cube from the 0-1 ADD f + @details Abstracts all the variables in cube from the 0-1 %ADD f by taking the disjunction over all possible values taken by the - variables. Returns the abstracted ADD if successful; NULL - otherwise.] + variables. - SideEffects [None] + @return the abstracted %ADD if successful; NULL otherwise. - SeeAlso [Cudd_addUnivAbstract Cudd_addExistAbstract] + @sideeffect None -******************************************************************************/ + @see Cudd_addUnivAbstract Cudd_addExistAbstract + +*/ DdNode * Cudd_addOrAbstract( DdManager * manager, @@ -229,6 +197,9 @@ Cudd_addOrAbstract( manager->reordered = 0; res = cuddAddOrAbstractRecur(manager, f, cube); } while (manager->reordered == 1); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_addOrAbstract */ @@ -315,19 +286,15 @@ Cudd_addMaxAbstract( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_addExistAbstract.] - - Description [Performs the recursive step of Cudd_addExistAbstract. - Returns the ADD obtained by abstracting the variables of cube from f, - if successful; NULL otherwise.] +/** + @brief Performs the recursive step of Cudd_addExistAbstract. - SideEffects [None] + @details Returns the %ADD obtained by abstracting the variables of + cube from f, if successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * cuddAddExistAbstractRecur( DdManager * manager, @@ -353,7 +320,7 @@ cuddAddExistAbstractRecur( ** dynamic reordering. If dynamic reordering occurs, we ** have to abort the entire abstraction. */ - res = cuddAddApplyRecur(manager,Cudd_addTimes,res1,two); + res = cuddAddApplyRecur(manager,Cudd_addPlus,res1,res1); if (res == NULL) { Cudd_RecursiveDeref(manager,res1); return(NULL); @@ -368,6 +335,8 @@ cuddAddExistAbstractRecur( return(res); } + checkWhetherToGiveUp(manager); + T = cuddT(f); E = cuddE(f); @@ -420,19 +389,15 @@ cuddAddExistAbstractRecur( } /* end of cuddAddExistAbstractRecur */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_addUnivAbstract.] - - Description [Performs the recursive step of Cudd_addUnivAbstract. - Returns the ADD obtained by abstracting the variables of cube from f, - if successful; NULL otherwise.] +/** + @brief Performs the recursive step of Cudd_addUnivAbstract. - SideEffects [None] + @return the %ADD obtained by abstracting the variables of cube from + f, if successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * cuddAddUnivAbstractRecur( DdManager * manager, @@ -476,6 +441,8 @@ cuddAddUnivAbstractRecur( return(res); } + checkWhetherToGiveUp(manager); + T = cuddT(f); E = cuddE(f); @@ -528,19 +495,15 @@ cuddAddUnivAbstractRecur( } /* end of cuddAddUnivAbstractRecur */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_addOrAbstract.] - - Description [Performs the recursive step of Cudd_addOrAbstract. - Returns the ADD obtained by abstracting the variables of cube from f, - if successful; NULL otherwise.] +/** + @brief Performs the recursive step of Cudd_addOrAbstract. - SideEffects [None] + @return the %ADD obtained by abstracting the variables of cube from + f, if successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * cuddAddOrAbstractRecur( DdManager * manager, @@ -567,6 +530,8 @@ cuddAddOrAbstractRecur( return(res); } + checkWhetherToGiveUp(manager); + T = cuddT(f); E = cuddE(f); @@ -637,79 +602,79 @@ cuddAddOrAbstractRecur( ******************************************************************************/ DdNode * cuddAddMinAbstractRecur( - DdManager * manager, - DdNode * f, - DdNode * cube) + DdManager * manager, + DdNode * f, + DdNode * cube) { - DdNode *T, *E, *res, *res1, *res2, *zero; + DdNode *T, *E, *res, *res1, *res2, *zero; - zero = DD_ZERO(manager); + zero = DD_ZERO(manager); - /* Cube is guaranteed to be a cube at this point. */ - if (f == zero || cuddIsConstant(cube)) { - return(f); - } + /* Cube is guaranteed to be a cube at this point. */ + if (f == zero || cuddIsConstant(cube)) { + return(f); + } /* Abstract a variable that does not appear in f. */ - if (cuddI(manager,f->index) > cuddI(manager,cube->index)) { - res = cuddAddMinAbstractRecur(manager, f, cuddT(cube)); + if (cuddI(manager,f->index) > cuddI(manager,cube->index)) { + res = cuddAddMinAbstractRecur(manager, f, cuddT(cube)); return(res); - } + } - if ((res = cuddCacheLookup2(manager, Cudd_addMinAbstract, f, cube)) != NULL) { - return(res); - } + if ((res = cuddCacheLookup2(manager, Cudd_addMinAbstract, f, cube)) != NULL) { + return(res); + } - T = cuddT(f); - E = cuddE(f); + T = cuddT(f); + E = cuddE(f); - /* If the two indices are the same, so are their levels. */ - if (f->index == cube->index) { - res1 = cuddAddMinAbstractRecur(manager, T, cuddT(cube)); - if (res1 == NULL) return(NULL); + /* If the two indices are the same, so are their levels. */ + if (f->index == cube->index) { + res1 = cuddAddMinAbstractRecur(manager, T, cuddT(cube)); + if (res1 == NULL) return(NULL); cuddRef(res1); - res2 = cuddAddMinAbstractRecur(manager, E, cuddT(cube)); - if (res2 == NULL) { + res2 = cuddAddMinAbstractRecur(manager, E, cuddT(cube)); + if (res2 == NULL) { Cudd_RecursiveDeref(manager,res1); return(NULL); - } - cuddRef(res2); - res = cuddAddApplyRecur(manager, Cudd_addMinimum, res1, res2); - if (res == NULL) { + } + cuddRef(res2); + res = cuddAddApplyRecur(manager, Cudd_addMinimum, res1, res2); + if (res == NULL) { Cudd_RecursiveDeref(manager,res1); Cudd_RecursiveDeref(manager,res2); return(NULL); - } - cuddRef(res); - Cudd_RecursiveDeref(manager,res1); - Cudd_RecursiveDeref(manager,res2); - cuddCacheInsert2(manager, Cudd_addMinAbstract, f, cube, res); - cuddDeref(res); + } + cuddRef(res); + Cudd_RecursiveDeref(manager,res1); + Cudd_RecursiveDeref(manager,res2); + cuddCacheInsert2(manager, Cudd_addMinAbstract, f, cube, res); + cuddDeref(res); return(res); } - else { /* if (cuddI(manager,f->index) < cuddI(manager,cube->index)) */ - res1 = cuddAddMinAbstractRecur(manager, T, cube); - if (res1 == NULL) return(NULL); + else { /* if (cuddI(manager,f->index) < cuddI(manager,cube->index)) */ + res1 = cuddAddMinAbstractRecur(manager, T, cube); + if (res1 == NULL) return(NULL); cuddRef(res1); - res2 = cuddAddMinAbstractRecur(manager, E, cube); - if (res2 == NULL) { - Cudd_RecursiveDeref(manager,res1); - return(NULL); - } + res2 = cuddAddMinAbstractRecur(manager, E, cube); + if (res2 == NULL) { + Cudd_RecursiveDeref(manager,res1); + return(NULL); + } cuddRef(res2); - res = (res1 == res2) ? res1 : + res = (res1 == res2) ? res1 : cuddUniqueInter(manager, (int) f->index, res1, res2); - if (res == NULL) { + if (res == NULL) { Cudd_RecursiveDeref(manager,res1); Cudd_RecursiveDeref(manager,res2); return(NULL); - } - cuddDeref(res1); - cuddDeref(res2); - cuddCacheInsert2(manager, Cudd_addMinAbstract, f, cube, res); + } + cuddDeref(res1); + cuddDeref(res2); + cuddCacheInsert2(manager, Cudd_addMinAbstract, f, cube, res); return(res); - } + } } /* end of cuddAddMinAbstractRecur */ @@ -733,75 +698,75 @@ cuddAddMaxAbstractRecur( DdNode * f, DdNode * cube) { - DdNode *T, *E, *res, *res1, *res2, *zero; + DdNode *T, *E, *res, *res1, *res2, *zero; - zero = DD_ZERO(manager); + zero = DD_ZERO(manager); - /* Cube is guaranteed to be a cube at this point. */ - if (f == zero || cuddIsConstant(cube)) { - return(f); - } + /* Cube is guaranteed to be a cube at this point. */ + if (f == zero || cuddIsConstant(cube)) { + return(f); + } /* Abstract a variable that does not appear in f. */ - if (cuddI(manager,f->index) > cuddI(manager,cube->index)) { - res = cuddAddMaxAbstractRecur(manager, f, cuddT(cube)); + if (cuddI(manager,f->index) > cuddI(manager,cube->index)) { + res = cuddAddMaxAbstractRecur(manager, f, cuddT(cube)); return(res); - } + } - if ((res = cuddCacheLookup2(manager, Cudd_addMaxAbstract, f, cube)) != NULL) { - return(res); - } + if ((res = cuddCacheLookup2(manager, Cudd_addMaxAbstract, f, cube)) != NULL) { + return(res); + } - T = cuddT(f); - E = cuddE(f); + T = cuddT(f); + E = cuddE(f); - /* If the two indices are the same, so are their levels. */ - if (f->index == cube->index) { - res1 = cuddAddMaxAbstractRecur(manager, T, cuddT(cube)); - if (res1 == NULL) return(NULL); + /* If the two indices are the same, so are their levels. */ + if (f->index == cube->index) { + res1 = cuddAddMaxAbstractRecur(manager, T, cuddT(cube)); + if (res1 == NULL) return(NULL); cuddRef(res1); - res2 = cuddAddMaxAbstractRecur(manager, E, cuddT(cube)); - if (res2 == NULL) { + res2 = cuddAddMaxAbstractRecur(manager, E, cuddT(cube)); + if (res2 == NULL) { Cudd_RecursiveDeref(manager,res1); return(NULL); - } - cuddRef(res2); - res = cuddAddApplyRecur(manager, Cudd_addMaximum, res1, res2); - if (res == NULL) { + } + cuddRef(res2); + res = cuddAddApplyRecur(manager, Cudd_addMaximum, res1, res2); + if (res == NULL) { Cudd_RecursiveDeref(manager,res1); Cudd_RecursiveDeref(manager,res2); return(NULL); - } - cuddRef(res); - Cudd_RecursiveDeref(manager,res1); - Cudd_RecursiveDeref(manager,res2); - cuddCacheInsert2(manager, Cudd_addMaxAbstract, f, cube, res); - cuddDeref(res); + } + cuddRef(res); + Cudd_RecursiveDeref(manager,res1); + Cudd_RecursiveDeref(manager,res2); + cuddCacheInsert2(manager, Cudd_addMaxAbstract, f, cube, res); + cuddDeref(res); return(res); } - else { /* if (cuddI(manager,f->index) < cuddI(manager,cube->index)) */ - res1 = cuddAddMaxAbstractRecur(manager, T, cube); - if (res1 == NULL) return(NULL); + else { /* if (cuddI(manager,f->index) < cuddI(manager,cube->index)) */ + res1 = cuddAddMaxAbstractRecur(manager, T, cube); + if (res1 == NULL) return(NULL); cuddRef(res1); - res2 = cuddAddMaxAbstractRecur(manager, E, cube); - if (res2 == NULL) { - Cudd_RecursiveDeref(manager,res1); - return(NULL); - } + res2 = cuddAddMaxAbstractRecur(manager, E, cube); + if (res2 == NULL) { + Cudd_RecursiveDeref(manager,res1); + return(NULL); + } cuddRef(res2); - res = (res1 == res2) ? res1 : + res = (res1 == res2) ? res1 : cuddUniqueInter(manager, (int) f->index, res1, res2); - if (res == NULL) { + if (res == NULL) { Cudd_RecursiveDeref(manager,res1); Cudd_RecursiveDeref(manager,res2); return(NULL); - } - cuddDeref(res1); - cuddDeref(res2); - cuddCacheInsert2(manager, Cudd_addMaxAbstract, f, cube, res); + } + cuddDeref(res1); + cuddDeref(res2); + cuddCacheInsert2(manager, Cudd_addMaxAbstract, f, cube, res); return(res); - } + } } /* end of cuddAddMaxAbstractRecur */ @@ -810,19 +775,15 @@ cuddAddMaxAbstractRecur( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Checks whether cube is an ADD representing the product - of positive literals.] +/** + @brief Checks whether cube is an %ADD representing the product + of positive literals. - Description [Checks whether cube is an ADD representing the product of - positive literals. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int addCheckPositiveCube( DdManager * manager, @@ -837,4 +798,3 @@ addCheckPositiveCube( return(0); } /* end of addCheckPositiveCube */ - diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddApply.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddApply.c similarity index 63% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddApply.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddAddApply.c index e789bfc73..d7a3c71cc 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddApply.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddApply.c @@ -1,41 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddAddApply.c] - - PackageName [cudd] - - Synopsis [Apply functions for ADDs and their operators.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_addApply() - <li> Cudd_addMonadicApply() - <li> Cudd_addPlus() - <li> Cudd_addTimes() - <li> Cudd_addThreshold() - <li> Cudd_addSetNZ() - <li> Cudd_addDivide() - <li> Cudd_addMinus() - <li> Cudd_addMinimum() - <li> Cudd_addMaximum() - <li> Cudd_addOneZeroMaximum() - <li> Cudd_addDiff() - <li> Cudd_addAgreement() - <li> Cudd_addOr() - <li> Cudd_addNand() - <li> Cudd_addNor() - <li> Cudd_addXor() - <li> Cudd_addXnor() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAddApplyRecur() - <li> cuddAddMonadicApplyRecur() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Apply functions for ADDs and their operators. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -65,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -91,51 +65,43 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddAddApply.c,v 1.19 2012/02/05 01:07:18 fabio Exp $"; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Applies op to the corresponding discriminants of f and g.] +/** + @brief Applies op to the corresponding discriminants of f and g. - Description [Applies op to the corresponding discriminants of f and g. - Returns a pointer to the result if succssful; NULL otherwise.] + @return a pointer to the result if succssful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addMonadicApply Cudd_addPlus Cudd_addTimes + @see Cudd_addMonadicApply Cudd_addPlus Cudd_addTimes Cudd_addThreshold Cudd_addSetNZ Cudd_addDivide Cudd_addMinus Cudd_addMinimum Cudd_addMaximum Cudd_addOneZeroMaximum Cudd_addDiff Cudd_addAgreement - Cudd_addOr Cudd_addNand Cudd_addNor Cudd_addXor Cudd_addXnor] + Cudd_addOr Cudd_addNand Cudd_addNor Cudd_addXor Cudd_addXnor -******************************************************************************/ +*/ DdNode * Cudd_addApply( - DdManager * dd, - DD_AOP op, - DdNode * f, - DdNode * g) + DdManager * dd /**< manager */, + DD_AOP op /**< operator */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */) { DdNode *res; @@ -143,23 +109,25 @@ Cudd_addApply( dd->reordered = 0; res = cuddAddApplyRecur(dd,op,f,g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(res); } /* end of Cudd_addApply */ -/**Function******************************************************************** - - Synopsis [Integer and floating point addition.] +/** + @brief Integer and floating point addition. - Description [Integer and floating point addition. Returns NULL if not - a terminal case; f+g otherwise.] + @return NULL if not a terminal case; f+g otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addPlus( DdManager * dd, @@ -187,19 +155,19 @@ Cudd_addPlus( } /* end of Cudd_addPlus */ -/**Function******************************************************************** +/** + @brief Integer and floating point multiplication. - Synopsis [Integer and floating point multiplication.] + @details This function can be used also to take the AND of two 0-1 + ADDs. - Description [Integer and floating point multiplication. Returns NULL - if not a terminal case; f * g otherwise. This function can be used also - to take the AND of two 0-1 ADDs.] + @return NULL if not a terminal case; f * g otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addTimes( DdManager * dd, @@ -228,18 +196,18 @@ Cudd_addTimes( } /* end of Cudd_addTimes */ -/**Function******************************************************************** +/** + @brief f if f≥g; 0 if f<g. - Synopsis [f if f>=g; 0 if f<g.] + @details Threshold operator for Apply (f if f ≥g; 0 if f<g). - Description [Threshold operator for Apply (f if f >=g; 0 if f<g). - Returns NULL if not a terminal case; f op g otherwise.] + @return NULL if not a terminal case; f op g otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addThreshold( DdManager * dd, @@ -262,18 +230,16 @@ Cudd_addThreshold( } /* end of Cudd_addThreshold */ -/**Function******************************************************************** - - Synopsis [This operator sets f to the value of g wherever g != 0.] +/** + @brief This operator sets f to the value of g wherever g != 0. - Description [This operator sets f to the value of g wherever g != 0. - Returns NULL if not a terminal case; f op g otherwise.] + @return NULL if not a terminal case; f op g otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addSetNZ( DdManager * dd, @@ -292,18 +258,16 @@ Cudd_addSetNZ( } /* end of Cudd_addSetNZ */ -/**Function******************************************************************** - - Synopsis [Integer and floating point division.] +/** + @brief Integer and floating point division. - Description [Integer and floating point division. Returns NULL if not - a terminal case; f / g otherwise.] + @return NULL if not a terminal case; f / g otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addDivide( DdManager * dd, @@ -329,18 +293,16 @@ Cudd_addDivide( } /* end of Cudd_addDivide */ -/**Function******************************************************************** - - Synopsis [Integer and floating point subtraction.] +/** + @brief Integer and floating point subtraction. - Description [Integer and floating point subtraction. Returns NULL if - not a terminal case; f - g otherwise.] + @return NULL if not a terminal case; f - g otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addMinus( DdManager * dd, @@ -365,18 +327,18 @@ Cudd_addMinus( } /* end of Cudd_addMinus */ -/**Function******************************************************************** - - Synopsis [Integer and floating point min.] +/** + @brief Integer and floating point min. - Description [Integer and floating point min for Cudd_addApply. - Returns NULL if not a terminal case; min(f,g) otherwise.] + @details Integer and floating point min for Cudd_addApply. + + @return NULL if not a terminal case; min(f,g) otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addMinimum( DdManager * dd, @@ -410,18 +372,18 @@ Cudd_addMinimum( } /* end of Cudd_addMinimum */ -/**Function******************************************************************** +/** + @brief Integer and floating point max. - Synopsis [Integer and floating point max.] + @details Integer and floating point max for Cudd_addApply. - Description [Integer and floating point max for Cudd_addApply. - Returns NULL if not a terminal case; max(f,g) otherwise.] + @return NULL if not a terminal case; max(f,g) otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addMaximum( DdManager * dd, @@ -455,19 +417,18 @@ Cudd_addMaximum( } /* end of Cudd_addMaximum */ -/**Function******************************************************************** +/** + @brief Returns 1 if f > g and 0 otherwise. - Synopsis [Returns 1 if f > g and 0 otherwise.] + @details Used in conjunction with Cudd_addApply. - Description [Returns 1 if f > g and 0 otherwise. Used in - conjunction with Cudd_addApply. Returns NULL if not a terminal - case.] + @return NULL if not a terminal case. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addOneZeroMaximum( DdManager * dd, @@ -491,18 +452,17 @@ Cudd_addOneZeroMaximum( } /* end of Cudd_addOneZeroMaximum */ -/**Function******************************************************************** - - Synopsis [Returns plusinfinity if f=g; returns min(f,g) if f!=g.] +/** + @brief Returns plusinfinity if f=g; returns min(f,g) if f!=g. - Description [Returns NULL if not a terminal case; f op g otherwise, - where f op g is plusinfinity if f=g; min(f,g) if f!=g.] + @return NULL if not a terminal case; f op g otherwise, where f op g + is plusinfinity if f=g; min(f,g) if f!=g. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addDiff( DdManager * dd, @@ -531,18 +491,17 @@ Cudd_addDiff( } /* end of Cudd_addDiff */ -/**Function******************************************************************** - - Synopsis [f if f==g; background if f!=g.] +/** + @brief f if f==g; background if f!=g. - Description [Returns NULL if not a terminal case; f op g otherwise, - where f op g is f if f==g; background if f!=g.] + @return NULL if not a terminal case; f op g otherwise, where f op g + is f if f==g; background if f!=g. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addAgreement( DdManager * dd, @@ -561,18 +520,16 @@ Cudd_addAgreement( } /* end of Cudd_addAgreement */ -/**Function******************************************************************** - - Synopsis [Disjunction of two 0-1 ADDs.] +/** + @brief Disjunction of two 0-1 ADDs. - Description [Disjunction of two 0-1 ADDs. Returns NULL - if not a terminal case; f OR g otherwise.] + @return NULL if not a terminal case; f OR g otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addOr( DdManager * dd, @@ -595,18 +552,16 @@ Cudd_addOr( } /* end of Cudd_addOr */ -/**Function******************************************************************** - - Synopsis [NAND of two 0-1 ADDs.] +/** + @brief NAND of two 0-1 ADDs. - Description [NAND of two 0-1 ADDs. Returns NULL - if not a terminal case; f NAND g otherwise.] + @return NULL if not a terminal case; f NAND g otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addNand( DdManager * dd, @@ -627,18 +582,16 @@ Cudd_addNand( } /* end of Cudd_addNand */ -/**Function******************************************************************** - - Synopsis [NOR of two 0-1 ADDs.] +/** + @brief NOR of two 0-1 ADDs. - Description [NOR of two 0-1 ADDs. Returns NULL - if not a terminal case; f NOR g otherwise.] + @return NULL if not a terminal case; f NOR g otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addNor( DdManager * dd, @@ -659,18 +612,16 @@ Cudd_addNor( } /* end of Cudd_addNor */ -/**Function******************************************************************** - - Synopsis [XOR of two 0-1 ADDs.] +/** + @brief XOR of two 0-1 ADDs. - Description [XOR of two 0-1 ADDs. Returns NULL - if not a terminal case; f XOR g otherwise.] + @return NULL if not a terminal case; f XOR g otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addXor( DdManager * dd, @@ -693,18 +644,16 @@ Cudd_addXor( } /* end of Cudd_addXor */ -/**Function******************************************************************** - - Synopsis [XNOR of two 0-1 ADDs.] +/** + @brief XNOR of two 0-1 ADDs. - Description [XNOR of two 0-1 ADDs. Returns NULL - if not a terminal case; f XNOR g otherwise.] + @return NULL if not a terminal case; f XNOR g otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addApply] + @see Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addXnor( DdManager * dd, @@ -727,18 +676,16 @@ Cudd_addXnor( } /* end of Cudd_addXnor */ -/**Function******************************************************************** +/** + @brief Applies op to the discriminants of f. - Synopsis [Applies op to the discriminants of f.] + @return a pointer to the result if succssful; NULL otherwise. - Description [Applies op to the discriminants of f. - Returns a pointer to the result if succssful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_addApply Cudd_addLog - SeeAlso [Cudd_addApply Cudd_addLog] - -******************************************************************************/ +*/ DdNode * Cudd_addMonadicApply( DdManager * dd, @@ -751,24 +698,27 @@ Cudd_addMonadicApply( dd->reordered = 0; res = cuddAddMonadicApplyRecur(dd,op,f); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(res); } /* end of Cudd_addMonadicApply */ -/**Function******************************************************************** +/** + @brief Natural logarithm of an %ADD. - Synopsis [Natural logarithm of an ADD.] + @details The discriminants of f must be positive double's. - Description [Natural logarithm of an ADDs. Returns NULL - if not a terminal case; log(f) otherwise. The discriminants of f must - be positive double's.] + @return NULL if not a terminal case; log(f) otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addMonadicApply] + @see Cudd_addMonadicApply -******************************************************************************/ +*/ DdNode * Cudd_addLog( DdManager * dd, @@ -837,185 +787,185 @@ Cudd_addCeil( } /* end of Cudd_addCeiling */ /**Function******************************************************************** - - Synopsis [1 if f==g; 0 otherwise.] - - Description [Returns NULL if not a terminal case; f op g otherwise, - where f op g is 1 if f==g; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_addApply] - -******************************************************************************/ + + Synopsis [1 if f==g; 0 otherwise.] + + Description [Returns NULL if not a terminal case; f op g otherwise, + where f op g is 1 if f==g; 0 otherwise.] + + SideEffects [None] + + SeeAlso [Cudd_addApply] + + ******************************************************************************/ DdNode * Cudd_addEquals( - DdManager * dd, - DdNode ** f, - DdNode ** g) + DdManager * dd, + DdNode ** f, + DdNode ** g) { DdNode *F, *G; - + F = *f; G = *g; if (F == G) return(DD_ONE(dd)); if (cuddIsConstant(F) && cuddIsConstant(G)) return(DD_ZERO(dd)); if (F > G) { /* swap f and g */ - *f = G; - *g = F; + *f = G; + *g = F; } return(NULL); - + } /* end of Cudd_addEquals */ /**Function******************************************************************** - - Synopsis [1 if f!=g; 0 otherwise.] - - Description [Returns NULL if not a terminal case; f op g otherwise, - where f op g is 1 if f!=g; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_addApply] - -******************************************************************************/ + + Synopsis [1 if f!=g; 0 otherwise.] + + Description [Returns NULL if not a terminal case; f op g otherwise, + where f op g is 1 if f!=g; 0 otherwise.] + + SideEffects [None] + + SeeAlso [Cudd_addApply] + + ******************************************************************************/ DdNode * Cudd_addNotEquals( - DdManager * dd, - DdNode ** f, - DdNode ** g) + DdManager * dd, + DdNode ** f, + DdNode ** g) { DdNode *F, *G; - + F = *f; G = *g; if (F == G) return(DD_ZERO(dd)); if (cuddIsConstant(F) && cuddIsConstant(G)) return(DD_ONE(dd)); if (F > G) { /* swap f and g */ - *f = G; - *g = F; + *f = G; + *g = F; } return(NULL); - + } /* end of Cudd_addNotEquals */ /**Function******************************************************************** - - Synopsis [1 if f>g; 0 otherwise.] - - Description [Returns NULL if not a terminal case; f op g otherwise, - where f op g is 1 if f>g; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_addApply] - -******************************************************************************/ + + Synopsis [1 if f>g; 0 otherwise.] + + Description [Returns NULL if not a terminal case; f op g otherwise, + where f op g is 1 if f>g; 0 otherwise.] + + SideEffects [None] + + SeeAlso [Cudd_addApply] + + ******************************************************************************/ DdNode * Cudd_addGreaterThan( - DdManager * dd, - DdNode ** f, - DdNode ** g) + DdManager * dd, + DdNode ** f, + DdNode ** g) { DdNode *F, *G; - + F = *f; G = *g; if (F == G) return(DD_ZERO(dd)); if (cuddIsConstant(F) && cuddIsConstant(G)) { - if (cuddV(F)>cuddV(G)) return (DD_ONE(dd)); else return (DD_ZERO(dd)); + if (cuddV(F)>cuddV(G)) return (DD_ONE(dd)); else return (DD_ZERO(dd)); } return(NULL); - + } /* end of Cudd_addGreaterThan */ /**Function******************************************************************** - - Synopsis [1 if f>=g; 0 otherwise.] - - Description [Returns NULL if not a terminal case; f op g otherwise, - where f op g is 1 if f>=g; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_addApply] - -******************************************************************************/ + + Synopsis [1 if f>=g; 0 otherwise.] + + Description [Returns NULL if not a terminal case; f op g otherwise, + where f op g is 1 if f>=g; 0 otherwise.] + + SideEffects [None] + + SeeAlso [Cudd_addApply] + + ******************************************************************************/ DdNode * Cudd_addGreaterThanEquals( - DdManager * dd, - DdNode ** f, - DdNode ** g) + DdManager * dd, + DdNode ** f, + DdNode ** g) { DdNode *F, *G; - + F = *f; G = *g; if (F == G) return(DD_ONE(dd)); if (cuddIsConstant(F) && cuddIsConstant(G)) { - if (cuddV(F)>=cuddV(G)) return (DD_ONE(dd)); else return (DD_ZERO(dd)); + if (cuddV(F)>=cuddV(G)) return (DD_ONE(dd)); else return (DD_ZERO(dd)); } return(NULL); - + } /* end of Cudd_addGreaterThanEquals */ /**Function******************************************************************** - - Synopsis [1 if f<g; 0 otherwise.] - - Description [Returns NULL if not a terminal case; f op g otherwise, - where f op g is 1 if f<g; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_addApply] - -******************************************************************************/ + + Synopsis [1 if f<g; 0 otherwise.] + + Description [Returns NULL if not a terminal case; f op g otherwise, + where f op g is 1 if f<g; 0 otherwise.] + + SideEffects [None] + + SeeAlso [Cudd_addApply] + + ******************************************************************************/ DdNode * Cudd_addLessThan( - DdManager * dd, - DdNode ** f, - DdNode ** g) + DdManager * dd, + DdNode ** f, + DdNode ** g) { DdNode *F, *G; - + F = *f; G = *g; if (F == G) return(DD_ZERO(dd)); if (cuddIsConstant(F) && cuddIsConstant(G)) { - if (cuddV(F)<cuddV(G)) return (DD_ONE(dd)); else return (DD_ZERO(dd)); + if (cuddV(F)<cuddV(G)) return (DD_ONE(dd)); else return (DD_ZERO(dd)); } return(NULL); - + } /* end of Cudd_addLessThan */ /**Function******************************************************************** - - Synopsis [1 if f<=g; 0 otherwise.] - - Description [Returns NULL if not a terminal case; f op g otherwise, - where f op g is 1 if f<=g; 0 otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_addApply] - -******************************************************************************/ + + Synopsis [1 if f<=g; 0 otherwise.] + + Description [Returns NULL if not a terminal case; f op g otherwise, + where f op g is 1 if f<=g; 0 otherwise.] + + SideEffects [None] + + SeeAlso [Cudd_addApply] + + ******************************************************************************/ DdNode * Cudd_addLessThanEquals( - DdManager * dd, - DdNode ** f, - DdNode ** g) + DdManager * dd, + DdNode ** f, + DdNode ** g) { DdNode *F, *G; - + F = *f; G = *g; if (F == G) return(DD_ONE(dd)); if (cuddIsConstant(F) && cuddIsConstant(G)) { - if (cuddV(F)<=cuddV(G)) return (DD_ONE(dd)); else return (DD_ZERO(dd)); + if (cuddV(F)<=cuddV(G)) return (DD_ONE(dd)); else return (DD_ZERO(dd)); } return(NULL); - + } /* end of Cudd_addLessThanEquals */ /**Function******************************************************************** @@ -1135,23 +1085,22 @@ Cudd_addLogXY( return(NULL); } /* end of Cudd_addLogXY */ + /*---------------------------------------------------------------------------*/ /* Definition of internal functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_addApply. - Synopsis [Performs the recursive step of Cudd_addApply.] + @return a pointer to the result if successful; NULL otherwise. - Description [Performs the recursive step of Cudd_addApply. Returns a - pointer to the result if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see cuddAddMonadicApplyRecur - SeeAlso [cuddAddMonadicApplyRecur] - -******************************************************************************/ +*/ DdNode * cuddAddApplyRecur( DdManager * dd, @@ -1162,7 +1111,7 @@ cuddAddApplyRecur( DdNode *res, *fv, *fvn, *gv, *gvn, *T, *E; - unsigned int ford, gord; + int ford, gord; unsigned int index; DD_CTFP cacheOp; @@ -1178,6 +1127,8 @@ cuddAddApplyRecur( res = cuddCacheLookup2(dd,cacheOp,f,g); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + /* Recursive step. */ ford = cuddI(dd,f->index); gord = cuddI(dd,g->index); @@ -1224,18 +1175,16 @@ cuddAddApplyRecur( } /* end of cuddAddApplyRecur */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_addMonadicApply. - Synopsis [Performs the recursive step of Cudd_addMonadicApply.] + @return a pointer to the result if successful; NULL otherwise. - Description [Performs the recursive step of Cudd_addMonadicApply. Returns a - pointer to the result if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see cuddAddApplyRecur - SeeAlso [cuddAddApplyRecur] - -******************************************************************************/ +*/ DdNode * cuddAddMonadicApplyRecur( DdManager * dd, @@ -1254,6 +1203,8 @@ cuddAddMonadicApplyRecur( res = cuddCacheLookup1(dd,op,f); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + /* Recursive step. */ index = f->index; ft = cuddT(f); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddFind.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddFind.c similarity index 71% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddFind.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddAddFind.c index 1352a87ff..240d78437 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddFind.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddFind.c @@ -1,26 +1,15 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddAddFind.c] + @ingroup cudd - PackageName [cudd] + @brief Functions to find maximum and minimum in an %ADD and to + extract the i-th bit. - Synopsis [Functions to find maximum and minimum in an ADD and to - extract the i-th bit.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_addFindMax() - <li> Cudd_addFindMin() - <li> Cudd_addIthBit() - </ul> - Static functions included in this module: - <ul> - <li> addDoIthBit() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -50,9 +39,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -76,20 +66,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddAddFind.c,v 1.9 2012/02/05 01:07:18 fabio Exp $"; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -#ifdef __cplusplus -extern "C" { -#endif - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -97,25 +79,20 @@ extern "C" { static DdNode * addDoIthBit (DdManager *dd, DdNode *f, DdNode *index); -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} -#endif +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Finds the maximum discriminant of f.] +/** + @brief Finds the maximum discriminant of f. - Description [Returns a pointer to a constant ADD.] + @return a pointer to a constant %ADD. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ DdNode * Cudd_addFindMax( DdManager * dd, @@ -133,6 +110,8 @@ Cudd_addFindMax( return(res); } + checkWhetherToGiveUp(dd); + t = Cudd_addFindMax(dd,cuddT(f)); if (t == DD_PLUS_INFINITY(dd)) return(t); @@ -147,15 +126,14 @@ Cudd_addFindMax( } /* end of Cudd_addFindMax */ -/**Function******************************************************************** +/** + @brief Finds the minimum discriminant of f. - Synopsis [Finds the minimum discriminant of f.] + @return a pointer to a constant %ADD. - Description [Returns a pointer to a constant ADD.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ DdNode * Cudd_addFindMin( DdManager * dd, @@ -173,6 +151,8 @@ Cudd_addFindMin( return(res); } + checkWhetherToGiveUp(dd); + t = Cudd_addFindMin(dd,cuddT(f)); if (t == DD_MINUS_INFINITY(dd)) return(t); @@ -187,24 +167,25 @@ Cudd_addFindMin( } /* end of Cudd_addFindMin */ -/**Function******************************************************************** +/** + @brief Extracts the i-th bit from an %ADD. - Synopsis [Extracts the i-th bit from an ADD.] - - Description [Produces an ADD from another ADD by replacing all + @details Produces an %ADD from another %ADD by replacing all discriminants whose i-th bit is equal to 1 with 1, and all other discriminants with 0. The i-th bit refers to the integer - representation of the leaf value. If the value is has a fractional + representation of the leaf value. If the value has a fractional part, it is ignored. Repeated calls to this procedure allow one to - transform an integer-valued ADD into an array of ADDs, one for each - bit of the leaf values. Returns a pointer to the resulting ADD if - successful; NULL otherwise.] + transform an integer-valued %ADD into an array of ADDs, one for each + bit of the leaf values. + + @return a pointer to the resulting %ADD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addBddIthBit] + @see Cudd_addBddIthBit -******************************************************************************/ +*/ DdNode * Cudd_addIthBit( DdManager * dd, @@ -228,6 +209,9 @@ Cudd_addIthBit( if (res == NULL) { Cudd_RecursiveDeref(dd, index); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(NULL); } cuddRef(res); @@ -248,18 +232,14 @@ Cudd_addIthBit( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step for Cudd_addIthBit. - Synopsis [Performs the recursive step for Cudd_addIthBit.] + @return a pointer to the %BDD if successful; NULL otherwise. - Description [Performs the recursive step for Cudd_addIthBit. - Returns a pointer to the BDD if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static DdNode * addDoIthBit( DdManager * dd, @@ -268,14 +248,14 @@ addDoIthBit( { DdNode *res, *T, *E; DdNode *fv, *fvn; - int mask, value; - int v; + unsigned int mask, value; + DdHalfWord v; statLine(dd); /* Check terminal case. */ if (cuddIsConstant(f)) { - mask = 1 << ((int) cuddV(index)); - value = (int) cuddV(f); + mask = 1U << ((unsigned int) cuddV(index)); + value = (unsigned) (int) cuddV(f); return((value & mask) == 0 ? DD_ZERO(dd) : DD_ONE(dd)); } @@ -283,6 +263,8 @@ addDoIthBit( res = cuddCacheLookup2(dd,addDoIthBit,f,index); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + /* Recursive step. */ v = f->index; fv = cuddT(f); fvn = cuddE(f); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddInv.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddInv.c similarity index 74% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddInv.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddAddInv.c index 454aa811d..683979c8e 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddInv.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddInv.c @@ -1,23 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddAddInv.c] + @ingroup cudd - PackageName [cudd] + @brief Function to compute the scalar inverse of an %ADD. - Synopsis [Function to compute the scalar inverse of an ADD.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_addScalarInverse() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAddScalarInverseRecur() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -47,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -74,24 +66,18 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddAddInv.c,v 1.10 2012/02/05 01:07:18 fabio Exp $"; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -99,19 +85,19 @@ static char rcsid[] DD_UNUSED = "$Id: cuddAddInv.c,v 1.10 2012/02/05 01:07:18 fa /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Computes the scalar inverse of an ADD.] +/** + @brief Computes the scalar inverse of an %ADD. - Description [Computes an n ADD where the discriminants are the + @details Computes an n %ADD where the discriminants are the multiplicative inverses of the corresponding discriminants of the - argument ADD. Returns a pointer to the resulting ADD in case of - success. Returns NULL if any discriminants smaller than epsilon is - encountered.] + argument %ADD. + + @return a pointer to the resulting %ADD in case of success. Returns + NULL if any discriminants smaller than epsilon is encountered. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ DdNode * Cudd_addScalarInverse( DdManager * dd, @@ -128,6 +114,9 @@ Cudd_addScalarInverse( dd->reordered = 0; res = cuddAddScalarInverseRecur(dd,f,epsilon); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addScalarInverse */ @@ -137,17 +126,15 @@ Cudd_addScalarInverse( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of addScalarInverse. - Synopsis [Performs the recursive step of addScalarInverse.] + @return a pointer to the resulting %ADD in case of success. Returns + NULL if any discriminants smaller than epsilon is encountered. - Description [Returns a pointer to the resulting ADD in case of - success. Returns NULL if any discriminants smaller than epsilon is - encountered.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ DdNode * cuddAddScalarInverseRecur( DdManager * dd, @@ -168,6 +155,8 @@ cuddAddScalarInverseRecur( res = cuddCacheLookup2(dd,Cudd_addScalarInverse,f,epsilon); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + t = cuddAddScalarInverseRecur(dd,cuddT(f),epsilon); if (t == NULL) return(NULL); cuddRef(t); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddIte.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddIte.c similarity index 71% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddIte.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddAddIte.c index a6e84c54c..12413269a 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddIte.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddIte.c @@ -1,32 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddAddIte.c] + @ingroup cudd - PackageName [cudd] + @brief %ADD ITE function and satellites. - Synopsis [ADD ITE function and satellites.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_addIte() - <li> Cudd_addIteConstant() - <li> Cudd_addEvalConst() - <li> Cudd_addCmpl() - <li> Cudd_addLeq() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAddIteRecur() - <li> cuddAddCmplRecur() - </ul> - Static procedures included in this module: - <ul> - <li> addVarToConst() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -56,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -82,17 +65,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddAddIte.c,v 1.16 2012/02/05 01:07:18 fabio Exp $"; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -100,7 +78,7 @@ static char rcsid[] DD_UNUSED = "$Id: cuddAddIte.c,v 1.16 2012/02/05 01:07:18 fa static void addVarToConst (DdNode *f, DdNode **gp, DdNode **hp, DdNode *one, DdNode *zero); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -108,19 +86,19 @@ static void addVarToConst (DdNode *f, DdNode **gp, DdNode **hp, DdNode *one, DdN /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Implements ITE(f,g,h). - Synopsis [Implements ITE(f,g,h).] + @details This procedure assumes that f is a 0-1 %ADD. - Description [Implements ITE(f,g,h). This procedure assumes that f is - a 0-1 ADD. Returns a pointer to the resulting ADD if successful; NULL - otherwise.] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddIte Cudd_addIteConstant Cudd_addApply] + @see Cudd_bddIte Cudd_addIteConstant Cudd_addApply -******************************************************************************/ +*/ DdNode * Cudd_addIte( DdManager * dd, @@ -134,27 +112,30 @@ Cudd_addIte( dd->reordered = 0; res = cuddAddIteRecur(dd,f,g,h); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addIte */ -/**Function******************************************************************** +/** + @brief Implements ITEconstant for %ADDs. - Synopsis [Implements ITEconstant for ADDs.] + @details f must be a 0-1 %ADD. No new nodes are created. This + function can be used, for instance, to check that g has a constant + value (specified by h) whenever f is 1. If the constant value is + unknown, then one should use Cudd_addEvalConst. - Description [Implements ITEconstant for ADDs. f must be a 0-1 ADD. - Returns a pointer to the resulting ADD (which may or may not be - constant) or DD_NON_CONSTANT. No new nodes are created. This function - can be used, for instance, to check that g has a constant value - (specified by h) whenever f is 1. If the constant value is unknown, - then one should use Cudd_addEvalConst.] + @return a pointer to the resulting %ADD (which may or may not be + constant) or DD_NON_CONSTANT. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addIte Cudd_addEvalConst Cudd_bddIteConstant] + @see Cudd_addIte Cudd_addEvalConst Cudd_bddIteConstant -******************************************************************************/ +*/ DdNode * Cudd_addIteConstant( DdManager * dd, @@ -164,7 +145,7 @@ Cudd_addIteConstant( { DdNode *one,*zero; DdNode *Fv,*Fnv,*Gv,*Gnv,*Hv,*Hnv,*r,*t,*e; - unsigned int topf,topg,toph,v; + int topf,topg,toph,v; statLine(dd); /* Trivial cases. */ @@ -237,21 +218,21 @@ Cudd_addIteConstant( } /* end of Cudd_addIteConstant */ -/**Function******************************************************************** +/** + @brief Checks whether %ADD g is constant whenever %ADD f is 1. - Synopsis [Checks whether ADD g is constant whenever ADD f is 1.] + @details f must be a 0-1 %ADD. If f is identically 0, the check is + assumed to be successful, and the background value is returned. No + new nodes are created. - Description [Checks whether ADD g is constant whenever ADD f is 1. f - must be a 0-1 ADD. Returns a pointer to the resulting ADD (which may - or may not be constant) or DD_NON_CONSTANT. If f is identically 0, - the check is assumed to be successful, and the background value is - returned. No new nodes are created.] + @return a pointer to the resulting %ADD (which may or may not be + constant) or DD_NON_CONSTANT. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addIteConstant Cudd_addLeq] + @see Cudd_addIteConstant Cudd_addLeq -******************************************************************************/ +*/ DdNode * Cudd_addEvalConst( DdManager * dd, @@ -260,7 +241,7 @@ Cudd_addEvalConst( { DdNode *zero; DdNode *Fv,*Fnv,*Gv,*Gnv,*r,*t,*e; - unsigned int topf,topg; + int topf,topg; #ifdef DD_DEBUG assert(!Cudd_IsComplement(f)); @@ -326,19 +307,19 @@ Cudd_addEvalConst( } /* end of Cudd_addEvalConst */ -/**Function******************************************************************** +/** + @brief Computes the complement of an %ADD a la C language. - Synopsis [Computes the complement of an ADD a la C language.] + @details The complement of 0 is 1 and the complement of everything + else is 0. - Description [Computes the complement of an ADD a la C language: The - complement of 0 is 1 and the complement of everything else is 0. - Returns a pointer to the resulting ADD if successful; NULL otherwise.] + @return a pointer to the resulting %ADD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addNegate] + @see Cudd_addNegate -******************************************************************************/ +*/ DdNode * Cudd_addCmpl( DdManager * dd, @@ -350,24 +331,27 @@ Cudd_addCmpl( dd->reordered = 0; res = cuddAddCmplRecur(dd,f); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addCmpl */ -/**Function******************************************************************** +/** + @brief Determines whether f is less than or equal to g. - Synopsis [Determines whether f is less than or equal to g.] + @details No new nodes are created. This procedure works for arbitrary ADDs. + For 0-1 ADDs Cudd_addEvalConst is more efficient. - Description [Returns 1 if f is less than or equal to g; 0 otherwise. - No new nodes are created. This procedure works for arbitrary ADDs. - For 0-1 ADDs Cudd_addEvalConst is more efficient.] + @return 1 if f is less than or equal to g; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addIteConstant Cudd_addEvalConst Cudd_bddLeq] + @see Cudd_addIteConstant Cudd_addEvalConst Cudd_bddLeq -******************************************************************************/ +*/ int Cudd_addLeq( DdManager * dd, @@ -375,7 +359,7 @@ Cudd_addLeq( DdNode * g) { DdNode *tmp, *fv, *fvn, *gv, *gvn; - unsigned int topf, topg, res; + int topf, topg, res; /* Terminal cases. */ if (f == g) return(1); @@ -424,19 +408,17 @@ Cudd_addLeq( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Implements the recursive step of Cudd_addIte(f,g,h).] +/** + @brief Implements the recursive step of Cudd_addIte(f,g,h). - Description [Implements the recursive step of Cudd_addIte(f,g,h). - Returns a pointer to the resulting ADD if successful; NULL - otherwise.] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addIte] + @see Cudd_addIte -******************************************************************************/ +*/ DdNode * cuddAddIteRecur( DdManager * dd, @@ -446,8 +428,8 @@ cuddAddIteRecur( { DdNode *one,*zero; DdNode *r,*Fv,*Fnv,*Gv,*Gnv,*Hv,*Hnv,*t,*e; - unsigned int topf,topg,toph,v; - int index; + int topf,topg,toph,v; + unsigned int index; statLine(dd); /* Trivial cases. */ @@ -493,10 +475,12 @@ cuddAddIteRecur( return(r); } + checkWhetherToGiveUp(dd); + /* Compute cofactors. */ + index = f->index; if (topf <= v) { v = ddMin(topf,v); /* v = top_var(F,G,H) */ - index = f->index; Fv = cuddT(f); Fnv = cuddE(f); } else { Fv = Fnv = f; @@ -542,18 +526,17 @@ cuddAddIteRecur( } /* end of cuddAddIteRecur */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_addCmpl. - Synopsis [Performs the recursive step of Cudd_addCmpl.] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. - Description [Performs the recursive step of Cudd_addCmpl. Returns a - pointer to the resulting ADD if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_addCmpl - SeeAlso [Cudd_addCmpl] - -******************************************************************************/ +*/ DdNode * cuddAddCmplRecur( DdManager * dd, @@ -577,6 +560,7 @@ cuddAddCmplRecur( if (r != NULL) { return(r); } + checkWhetherToGiveUp(dd); Fv = cuddT(f); Fnv = cuddE(f); t = cuddAddCmplRecur(dd,Fv); @@ -607,16 +591,13 @@ cuddAddCmplRecur( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Replaces variables with constants if possible (part of - canonical form).] - - Description [] +/** + @brief Replaces variables with constants if possible (part of + canonical form). - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static void addVarToConst( DdNode * f, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddNeg.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddNeg.c similarity index 71% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddNeg.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddAddNeg.c index 92c1cd71f..b9692a30f 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddNeg.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddNeg.c @@ -1,25 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddAddNeg.c] + @ingroup cudd - PackageName [cudd] + @brief Function to compute the negation of an %ADD. - Synopsis [Function to compute the negation of an ADD.] + @author Fabio Somenzi, Balakrishna Kumthekar - Description [External procedures included in this module: - <ul> - <li> Cudd_addNegate() - <li> Cudd_addRoundOff() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAddNegateRecur() - <li> cuddAddRoundOffRecur() - </ul> ] - - Author [Fabio Somenzi, Balakrishna Kumthekar] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -49,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -76,42 +66,34 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddAddNeg.c,v 1.14 2012/02/05 01:07:18 fabio Exp $"; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Computes the additive inverse of an ADD.] +/** + @brief Computes the additive inverse of an %ADD. - Description [Computes the additive inverse of an ADD. Returns a pointer - to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addCmpl] + @see Cudd_addCmpl -******************************************************************************/ +*/ DdNode * Cudd_addNegate( DdManager * dd, @@ -123,24 +105,25 @@ Cudd_addNegate( dd->reordered = 0; res = cuddAddNegateRecur(dd,f); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addNegate */ -/**Function******************************************************************** - - Synopsis [Rounds off the discriminants of an ADD.] +/** + @brief Rounds off the discriminants of an %ADD. - Description [Rounds off the discriminants of an ADD. The discriminants are - rounded off to N digits after the decimal. Returns a pointer to the result - ADD if successful; NULL otherwise.] + @details The discriminants are rounded off to N digits after the + decimal. - SideEffects [None] + @return a pointer to the result %ADD if successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * Cudd_addRoundOff( DdManager * dd, @@ -154,6 +137,9 @@ Cudd_addRoundOff( dd->reordered = 0; res = cuddAddRoundOffRecur(dd,f,trunc); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addRoundOff */ @@ -164,16 +150,14 @@ Cudd_addRoundOff( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Implements the recursive step of Cudd_addNegate. - Synopsis [Implements the recursive step of Cudd_addNegate.] + @return a pointer to the result. - Description [Implements the recursive step of Cudd_addNegate. - Returns a pointer to the result.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ DdNode * cuddAddNegateRecur( DdManager * dd, @@ -194,6 +178,8 @@ cuddAddNegateRecur( res = cuddCacheLookup1(dd,Cudd_addNegate,f); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + /* Recursive Step */ fv = cuddT(f); fvn = cuddE(f); @@ -224,16 +210,14 @@ cuddAddNegateRecur( } /* end of cuddAddNegateRecur */ -/**Function******************************************************************** - - Synopsis [Implements the recursive step of Cudd_addRoundOff.] +/** + @brief Implements the recursive step of Cudd_addRoundOff. - Description [Implements the recursive step of Cudd_addRoundOff. - Returns a pointer to the result.] + @return a pointer to the result. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ DdNode * cuddAddRoundOffRecur( DdManager * dd, @@ -256,6 +240,7 @@ cuddAddRoundOffRecur( if (res != NULL) { return(res); } + checkWhetherToGiveUp(dd); /* Recursive Step */ fv = cuddT(f); fvn = cuddE(f); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddWalsh.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddWalsh.c similarity index 80% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddWalsh.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddAddWalsh.c index 146b1d313..789341dc3 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAddWalsh.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddAddWalsh.c @@ -1,25 +1,15 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddAddWalsh.c] + @ingroup cudd - PackageName [cudd] + @brief Functions that generate Walsh matrices and residue + functions in %ADD form. - Synopsis [Functions that generate Walsh matrices and residue - functions in ADD form.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_addWalsh() - <li> Cudd_addResidue() - </ul> - Static procedures included in this module: - <ul> - <li> addWalshInt() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -49,9 +39,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -76,17 +67,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddAddWalsh.c,v 1.11 2012/02/05 01:07:18 fabio Exp $"; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -94,7 +80,7 @@ static char rcsid[] DD_UNUSED = "$Id: cuddAddWalsh.c,v 1.11 2012/02/05 01:07:18 static DdNode * addWalshInt (DdManager *dd, DdNode **x, DdNode **y, int n); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -102,16 +88,14 @@ static DdNode * addWalshInt (DdManager *dd, DdNode **x, DdNode **y, int n); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Generates a Walsh matrix in %ADD form. - Synopsis [Generates a Walsh matrix in ADD form.] + @return a pointer to the matrixi if successful; NULL otherwise. - Description [Generates a Walsh matrix in ADD form. Returns a pointer - to the matrixi if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ DdNode * Cudd_addWalsh( DdManager * dd, @@ -125,18 +109,19 @@ Cudd_addWalsh( dd->reordered = 0; res = addWalshInt(dd, x, y, n); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addWalsh */ -/**Function******************************************************************** - - Synopsis [Builds an ADD for the residue modulo m of an n-bit - number.] +/** + @brief Builds an %ADD for the residue modulo m of an n-bit + number. - Description [Builds an ADD for the residue modulo m of an n-bit - number. The modulus must be at least 2, and the number of bits at + @details The modulus must be at least 2, and the number of bits at least 1. Parameter options specifies whether the MSB should be on top or the LSB; and whther the number whose residue is computed is in two's complement notation or not. The macro CUDD_RESIDUE_DEFAULT @@ -145,21 +130,20 @@ Cudd_addWalsh( complement residue. To request MSB on top and two's complement residue simultaneously, one can OR the two macros: CUDD_RESIDUE_MSB | CUDD_RESIDUE_TC. - Cudd_addResidue returns a pointer to the resulting ADD if successful; - NULL otherwise.] - SideEffects [None] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * Cudd_addResidue( - DdManager * dd /* manager */, - int n /* number of bits */, - int m /* modulus */, - int options /* options */, - int top /* index of top variable */) + DdManager * dd /**< manager */, + int n /**< number of bits */, + int m /**< modulus */, + int options /**< options */, + int top /**< index of top variable */) { int msbLsb; /* MSB on top (1) or LSB on top (0) */ int tc; /* two's complement (1) or unsigned (0) */ @@ -280,16 +264,16 @@ Cudd_addResidue( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Implements the recursive step of Cudd_addWalsh. - Synopsis [Implements the recursive step of Cudd_addWalsh.] + @return a pointer to the matrixi if successful; NULL otherwise. - Description [Generates a Walsh matrix in ADD form. Returns a pointer - to the matrixi if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_addWalsh -******************************************************************************/ +*/ static DdNode * addWalshInt( DdManager * dd, @@ -298,7 +282,7 @@ addWalshInt( int n) { DdNode *one, *minusone; - DdNode *t, *u, *t1, *u1, *v, *w; + DdNode *t = NULL, *u, *t1, *u1, *v, *w; int i; one = DD_ONE(dd); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAndAbs.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddAndAbs.c similarity index 76% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddAndAbs.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddAndAbs.c index a800830bf..49e06e030 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAndAbs.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddAndAbs.c @@ -1,24 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddAndAbs.c] + @ingroup cudd - PackageName [cudd] + @brief Combined AND and existential abstraction for BDDs - Synopsis [Combined AND and existential abstraction for BDDs] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_bddAndAbstract() - <li> Cudd_bddAndAbstractLimit() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddAndAbstractRecur() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -48,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -75,24 +66,18 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddAndAbs.c,v 1.20 2012/02/05 01:07:18 fabio Exp $"; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -100,22 +85,21 @@ static char rcsid[] DD_UNUSED = "$Id: cuddAndAbs.c,v 1.20 2012/02/05 01:07:18 fa /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Takes the AND of two BDDs and simultaneously abstracts the + variables in cube. - Synopsis [Takes the AND of two BDDs and simultaneously abstracts the - variables in cube.] - - Description [Takes the AND of two BDDs and simultaneously abstracts - the variables in cube. The variables are existentially abstracted. - Returns a pointer to the result is successful; NULL otherwise. + @details The variables are existentially abstracted. Cudd_bddAndAbstract implements the semiring matrix multiplication - algorithm for the boolean semiring.] + algorithm for the boolean semiring. + + @return a pointer to the result is successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addMatrixMultiply Cudd_addTriangle Cudd_bddAnd] + @see Cudd_addMatrixMultiply Cudd_addTriangle Cudd_bddAnd -******************************************************************************/ +*/ DdNode * Cudd_bddAndAbstract( DdManager * manager, @@ -129,27 +113,29 @@ Cudd_bddAndAbstract( manager->reordered = 0; res = cuddBddAndAbstractRecur(manager, f, g, cube); } while (manager->reordered == 1); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_bddAndAbstract */ -/**Function******************************************************************** +/** + @brief Takes the AND of two BDDs and simultaneously abstracts + variables unless too many nodes are needed. - Synopsis [Takes the AND of two BDDs and simultaneously abstracts the - variables in cube. Returns NULL if too many nodes are required.] + @details The variables in cube are existentially abstracted. - Description [Takes the AND of two BDDs and simultaneously abstracts - the variables in cube. The variables are existentially abstracted. - Returns a pointer to the result is successful; NULL otherwise. + @return a pointer to the result is successful; NULL otherwise. In particular, if the number of new nodes created exceeds - <code>limit</code>, this function returns NULL.] + <code>limit</code>, this function returns NULL. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddAndAbstract] + @see Cudd_bddAndAbstract -******************************************************************************/ +*/ DdNode * Cudd_bddAndAbstractLimit( DdManager * manager, @@ -168,6 +154,9 @@ Cudd_bddAndAbstractLimit( res = cuddBddAndAbstractRecur(manager, f, g, cube); } while (manager->reordered == 1); manager->maxLive = saveLimit; + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_bddAndAbstractLimit */ @@ -178,20 +167,19 @@ Cudd_bddAndAbstractLimit( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Takes the AND of two BDDs and simultaneously abstracts the + variables in cube. - Synopsis [Takes the AND of two BDDs and simultaneously abstracts the - variables in cube.] + @details The variables are existentially abstracted. - Description [Takes the AND of two BDDs and simultaneously abstracts - the variables in cube. The variables are existentially abstracted. - Returns a pointer to the result is successful; NULL otherwise.] + @return a pointer to the result is successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddAndAbstract] + @see Cudd_bddAndAbstract -******************************************************************************/ +*/ DdNode * cuddBddAndAbstractRecur( DdManager * manager, @@ -201,7 +189,8 @@ cuddBddAndAbstractRecur( { DdNode *F, *ft, *fe, *G, *gt, *ge; DdNode *one, *zero, *r, *t, *e; - unsigned int topf, topg, topcube, top, index; + int topf, topg, top, topcube; + unsigned int index; statLine(manager); one = DD_ONE(manager); @@ -255,6 +244,8 @@ cuddBddAndAbstractRecur( } } + checkWhetherToGiveUp(manager); + if (topf == top) { index = F->index; ft = cuddT(F); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAnneal.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddAnneal.c similarity index 73% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddAnneal.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddAnneal.c index 622c3d14a..c9996d643 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddAnneal.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddAnneal.c @@ -1,34 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddAnneal.c] + @ingroup cudd - PackageName [cudd] + @brief Reordering of DDs based on simulated annealing - Synopsis [Reordering of DDs based on simulated annealing] + @author Jae-Young Jang, Jorgen Sivesind - Description [Internal procedures included in this file: - <ul> - <li> cuddAnnealing() - </ul> - Static procedures included in this file: - <ul> - <li> stopping_criterion() - <li> random_generator() - <li> ddExchange() - <li> ddJumpingAux() - <li> ddJumpingUp() - <li> ddJumpingDown() - <li> siftBackwardProb() - <li> copyOrder() - <li> restoreOrder() - </ul> - ] - - SeeAlso [] - - Author [Jae-Young Jang, Jorgen Sivesind] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -58,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -81,40 +62,26 @@ /* Stucture declarations */ /*---------------------------------------------------------------------------*/ - /*---------------------------------------------------------------------------*/ /* Type declarations */ /*---------------------------------------------------------------------------*/ - /*---------------------------------------------------------------------------*/ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddAnneal.c,v 1.15 2012/02/05 01:07:18 fabio Exp $"; -#endif - -#ifdef DD_STATS -extern int ddTotalNumberSwapping; -extern int ddTotalNISwaps; -static int tosses; -static int acceptances; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ static int stopping_criterion (int c1, int c2, int c3, int c4, double temp); -static double random_generator (void); +static double random_generator (DdManager *dd); static int ddExchange (DdManager *table, int x, int y, double temp); static int ddJumpingAux (DdManager *table, int x, int x_low, int x_high, double temp); static Move * ddJumpingUp (DdManager *table, int x, int x_low, int initial_size); @@ -123,8 +90,7 @@ static int siftBackwardProb (DdManager *table, Move *moves, int size, double tem static void copyOrder (DdManager *table, int *array, int lower, int upper); static int restoreOrder (DdManager *table, int *array, int lower, int upper); -/**AutomaticEnd***************************************************************/ - +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ @@ -135,21 +101,20 @@ static int restoreOrder (DdManager *table, int *array, int lower, int upper); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Get new variable-order by simulated annealing algorithm.] +/** + @brief Get new variable-order by simulated annealing algorithm. - Description [Get x, y by random selection. Choose either + @details Get x, y by random selection. Choose either exchange or jump randomly. In case of jump, choose between jump_up and jump_down randomly. Do exchange or jump and get optimal case. Loop until there is no improvement or temperature reaches - minimum. Returns 1 in case of success; 0 otherwise.] + minimum. - SideEffects [None] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int cuddAnnealing( DdManager * table, @@ -176,7 +141,7 @@ cuddAnnealing( #endif if (result == 0) return(0); - size = table->keys - table->isolated; + size = (int) (table->keys - table->isolated); /* Keep track of the best order. */ BestCost = size; @@ -200,13 +165,13 @@ cuddAnnealing( #ifdef DD_STATS (void) fprintf(table->out,"temp=%f\tsize=%d\tgen=%d\t", temp,size,maxGen); - tosses = acceptances = 0; + table->tosses = table->acceptances = 0; #endif for (innerloop = 0; innerloop < maxGen; innerloop++) { /* Choose x, y randomly. */ - x = (int) Cudd_Random() % nvars; + x = (int) Cudd_Random(table) % nvars; do { - y = (int) Cudd_Random() % nvars; + y = (int) Cudd_Random(table) % nvars; } while (x == y); x += lower; y += lower; @@ -217,7 +182,7 @@ cuddAnnealing( } /* Choose move with roulette wheel. */ - rand1 = random_generator(); + rand1 = random_generator(table); if (rand1 < EXC_PROB) { result = ddExchange(table,x,y,temp); /* exchange */ ecount++; @@ -249,7 +214,7 @@ cuddAnnealing( return(0); } - size = table->keys - table->isolated; /* keep current size */ + size = (int) (table->keys - table->isolated); /* keep current size */ if (size < BestCost) { /* update best order */ BestCost = size; copyOrder(table,BestOrder,lower,upper); @@ -266,7 +231,7 @@ cuddAnnealing( temp = NewTemp; /* control variable */ #ifdef DD_STATS (void) fprintf(table->out,"uphill = %d\taccepted = %d\n", - tosses,acceptances); + table->tosses,table->acceptances); fflush(table->out); #endif } @@ -288,19 +253,17 @@ cuddAnnealing( /* Definition of static functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Checks termination condition. - Synopsis [Checks termination condition.] + @details If temperature is STOP_TEMP or there is no improvement + then terminates. - Description [If temperature is STOP_TEMP or there is no improvement - then terminates. Returns 1 if the termination criterion is met; 0 - otherwise.] + @return 1 if the termination criterion is met; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int stopping_criterion( int c1, @@ -320,37 +283,31 @@ stopping_criterion( } /* end of stopping_criterion */ -/**Function******************************************************************** - - Synopsis [Random number generator.] +/** + @brief Random number generator. - Description [Returns a double precision value between 0.0 and 1.0.] + @return a double precision value between 0.0 and 1.0. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static double -random_generator(void) +random_generator(DdManager * dd) { - return((double)(Cudd_Random() / 2147483561.0)); + return((double)(Cudd_Random(dd) / 2147483561.0)); } /* end of random_generator */ -/**Function******************************************************************** - - Synopsis [This function is for exchanging two variables, x and y.] +/** + @brief Exchanges two variables, x and y. - Description [This is the same funcion as ddSwapping except for - comparison expression. Use probability function, exp(-size_change/temp).] + @details This is the same funcion as ddSwapping except for the + comparison expression. Use probability function, exp(-size_change/temp). - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int ddExchange( DdManager * table, @@ -371,7 +328,7 @@ ddExchange( x_next = cuddNextHigh(table,x); y_next = cuddNextLow(table,y); moves = NULL; - initial_size = limit_size = table->keys - table->isolated; + initial_size = limit_size = (int) (table->keys - table->isolated); for (;;) { if (x_next == y_next) { @@ -487,19 +444,17 @@ ddExchangeOutOfMem: } /* end of ddExchange */ -/**Function******************************************************************** - - Synopsis [Moves a variable to a specified position.] +/** + @brief Moves a variable to a specified position. - Description [If x==x_low, it executes jumping_down. If x==x_high, it - executes jumping_up. This funcion is similar to ddSiftingAux. Returns - 1 in case of success; 0 otherwise.] + @details If x==x_low, it executes jumping_down. If x==x_high, it + executes jumping_up. This funcion is similar to ddSiftingAux. - SideEffects [None] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int ddJumpingAux( DdManager * table, @@ -513,7 +468,7 @@ ddJumpingAux( int initial_size; int result; - initial_size = table->keys - table->isolated; + initial_size = (int) (table->keys - table->isolated); #ifdef DD_DEBUG assert(table->subtables[x].keys > 0); @@ -558,19 +513,17 @@ ddJumpingAuxOutOfMem: } /* end of ddJumpingAux */ -/**Function******************************************************************** - - Synopsis [This function is for jumping up.] +/** + @brief This function is for jumping up. - Description [This is a simplified version of ddSiftingUp. It does not - use lower bounding. Returns the set of moves in case of success; NULL - if memory is full.] + @details This is a simplified version of ddSiftingUp. It does not + use lower bounding. - SideEffects [None] + @return the set of moves in case of success; NULL if memory is full. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static Move * ddJumpingUp( DdManager * table, @@ -617,19 +570,17 @@ ddJumpingUpOutOfMem: } /* end of ddJumpingUp */ -/**Function******************************************************************** +/** + @brief This function is for jumping down. - Synopsis [This function is for jumping down.] + @details This is a simplified version of ddSiftingDown. It does not + use lower bounding. - Description [This is a simplified version of ddSiftingDown. It does not - use lower bounding. Returns the set of moves in case of success; NULL - if memory is full.] + @return the set of moves in case of success; NULL if memory is full. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static Move * ddJumpingDown( DdManager * table, @@ -676,20 +627,19 @@ ddJumpingDownOutOfMem: } /* end of ddJumpingDown */ -/**Function******************************************************************** - - Synopsis [Returns the DD to the best position encountered during - sifting if there was improvement.] +/** + @brief Returns the %DD to the best position encountered during + sifting if there was improvement. - Description [Otherwise, "tosses a coin" to decide whether to keep - the current configuration or return the DD to the original - one. Returns 1 in case of success; 0 otherwise.] + @details Otherwise, "tosses a coin" to decide whether to keep + the current configuration or return the %DD to the original + one. - SideEffects [None] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int siftBackwardProb( DdManager * table, @@ -714,14 +664,15 @@ siftBackwardProb( ** this change or not. */ if (best_size == size) { - coin = random_generator(); + coin = random_generator(table); #ifdef DD_STATS - tosses++; + table->tosses++; #endif - threshold = exp(-((double)(table->keys - table->isolated - size))/temp); + threshold = exp(-((double)(table->keys - table->isolated - + (unsigned int) size))/temp); if (coin < threshold) { #ifdef DD_STATS - acceptances++; + table->acceptances++; #endif return(1); } @@ -730,7 +681,7 @@ siftBackwardProb( /* Either there was improvement, or we have decided not to ** accept the uphill move. Go to best position. */ - res = table->keys - table->isolated; + res = (int) (table->keys - table->isolated); for (move = moves; move != NULL; move = move->next) { if (res == best_size) return(1); res = cuddSwapInPlace(table,(int)move->x,(int)move->y); @@ -742,18 +693,14 @@ siftBackwardProb( } /* end of sift_backward_prob */ -/**Function******************************************************************** - - Synopsis [Copies the current variable order to array.] +/** + @brief Copies the current variable order to array. - Description [Copies the current variable order to array. - At the same time inverts the permutation.] + @details At the same time inverts the permutation. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static void copyOrder( DdManager * table, @@ -772,18 +719,14 @@ copyOrder( } /* end of copyOrder */ -/**Function******************************************************************** - - Synopsis [Restores the variable order in array by a series of sifts up.] - - Description [Restores the variable order in array by a series of sifts up. - Returns 1 in case of success; 0 otherwise.] +/** + @brief Restores the variable order in array by a series of sifts up. - SideEffects [None] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int restoreOrder( DdManager * table, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddApa.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddApa.c similarity index 50% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddApa.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddApa.c index 7c4ff8ce6..87dca2cc6 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddApa.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddApa.c @@ -1,42 +1,18 @@ -/**CFile*********************************************************************** - - FileName [cuddApa.c] - - PackageName [cudd] - - Synopsis [Arbitrary precision arithmetic functions.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_ApaNumberOfDigits() - <li> Cudd_NewApaNumber() - <li> Cudd_ApaCopy() - <li> Cudd_ApaAdd() - <li> Cudd_ApaSubtract() - <li> Cudd_ApaShortDivision() - <li> Cudd_ApaIntDivision() - <li> Cudd_ApaShiftRight() - <li> Cudd_ApaSetToLiteral() - <li> Cudd_ApaPowerOfTwo() - <li> Cudd_ApaCompare() - <li> Cudd_ApaCompareRatios() - <li> Cudd_ApaPrintHex() - <li> Cudd_ApaPrintDecimal() - <li> Cudd_ApaPrintExponential() - <li> Cudd_ApaCountMinterm() - <li> Cudd_ApaPrintMinterm() - <li> Cudd_ApaPrintMintermExp() - <li> Cudd_ApaPrintDensity() - </ul> - Static procedures included in this module: - <ul> - <li> cuddApaCountMintermAux() - <li> cuddApaStCountfree() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Arbitrary precision arithmetic functions. + + @details This file provides just enough functionality as needed + by CUDD to compute the number of minterms of functions with many + variables. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -66,9 +42,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -77,6 +54,13 @@ /* Constant declarations */ /*---------------------------------------------------------------------------*/ +/* These constants define the digits used in the representation of +** arbitrary precision integers. +*/ +#define DD_APA_BITS ((int) sizeof(DdApaDigit) * 8) +#define DD_APA_BASE ((DdApaDoubleDigit) 1 << DD_APA_BITS) +#define DD_APA_MASK (DD_APA_BASE - 1) + /*---------------------------------------------------------------------------*/ /* Stucture declarations */ /*---------------------------------------------------------------------------*/ @@ -85,38 +69,51 @@ /* Type declarations */ /*---------------------------------------------------------------------------*/ +/** + @brief Type used for intermediate results. +*/ +typedef uint64_t DdApaDoubleDigit; + /*---------------------------------------------------------------------------*/ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddApa.c,v 1.20 2012/02/05 01:07:18 fabio Exp $"; -#endif - -static DdNode *background, *zero; /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -#ifdef __cplusplus -extern "C" { -#endif +/** + @brief Extract the least significant digit of a double digit. + + @sideeffect None + + @see DD_MSDIGIT + +*/ +#define DD_LSDIGIT(x) ((x) & DD_APA_MASK) + + +/** + @brief Extract the most significant digit of a double digit. -/**AutomaticStart*************************************************************/ + @sideeffect None + + @see DD_LSDIGIT + +*/ +#define DD_MSDIGIT(x) ((x) >> DD_APA_BITS) + +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ -static DdApaNumber cuddApaCountMintermAux (DdNode * node, int digits, DdApaNumber max, DdApaNumber min, st_table * table); -static enum st_retval cuddApaStCountfree (char * key, char * value, char * arg); - -/**AutomaticEnd***************************************************************/ +static DdApaNumber cuddApaCountMintermAux (DdManager const * manager, DdNode * node, int digits, DdApaNumber mmax, DdApaNumber mmin, st_table * table); +static enum st_retval cuddApaStCountfree (void * key, void * value, void * arg); -#ifdef __cplusplus -} /* end of extern "C" */ -#endif +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -124,24 +121,20 @@ static enum st_retval cuddApaStCountfree (char * key, char * value, char * arg); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Returns the number of digits for an arbitrary precision + integer. - Synopsis [Finds the number of digits for an arbitrary precision - integer.] - - Description [Finds the number of digits for an arbitrary precision + @details Finds the number of digits for an arbitrary precision integer given the maximum number of binary digits. The number of - binary digits should be positive. Returns the number of digits if - successful; 0 otherwise.] - - SideEffects [None] + binary digits should be positive. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Cudd_ApaNumberOfDigits( - int binaryDigits) + int binaryDigits) { int digits; @@ -153,44 +146,52 @@ Cudd_ApaNumberOfDigits( } /* end of Cudd_ApaNumberOfDigits */ -/**Function******************************************************************** - - Synopsis [Allocates memory for an arbitrary precision integer.] +/** + @brief Allocates memory for an arbitrary precision integer. - Description [Allocates memory for an arbitrary precision - integer. Returns a pointer to the allocated memory if successful; - NULL otherwise.] + @return a pointer to the allocated memory if successful; + NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ + @see Cudd_FreeApaNumber +*/ DdApaNumber Cudd_NewApaNumber( - int digits) + int digits) { return(ALLOC(DdApaDigit, digits)); } /* end of Cudd_NewApaNumber */ -/**Function******************************************************************** +/** + @brief Frees an arbitrary precision integer. + + @sideeffect None + + @see Cudd_NewApaNumber +*/ +void +Cudd_FreeApaNumber( + DdApaNumber number) +{ + FREE(number); - Synopsis [Makes a copy of an arbitrary precision integer.] +} /* end of Cudd_FreeApaNumber */ - Description [Makes a copy of an arbitrary precision integer.] - SideEffects [Changes parameter <code>dest</code>.] +/** + @brief Makes a copy of an arbitrary precision integer. - SeeAlso [] + @sideeffect Changes parameter <code>dest</code>. -******************************************************************************/ +*/ void Cudd_ApaCopy( - int digits, - DdApaNumber source, - DdApaNumber dest) + int digits, + DdConstApaNumber source, + DdApaNumber dest) { int i; @@ -201,30 +202,26 @@ Cudd_ApaCopy( } /* end of Cudd_ApaCopy */ -/**Function******************************************************************** +/** + @brief Adds two arbitrary precision integers. - Synopsis [Adds two arbitrary precision integers.] + @return the carry out of the most significant digit. - Description [Adds two arbitrary precision integers. Returns the - carry out of the most significant digit.] + @sideeffect The result of the sum is stored in parameter <code>sum</code>. - SideEffects [The result of the sum is stored in parameter <code>sum</code>.] - - SeeAlso [] - -******************************************************************************/ +*/ DdApaDigit Cudd_ApaAdd( int digits, - DdApaNumber a, - DdApaNumber b, - DdApaNumber sum) + DdConstApaNumber a, + DdConstApaNumber b, + DdApaNumber sum) { int i; DdApaDoubleDigit partial = 0; for (i = digits - 1; i >= 0; i--) { - partial = a[i] + b[i] + DD_MSDIGIT(partial); + partial = DD_MSDIGIT(partial) + a[i] + b[i]; sum[i] = (DdApaDigit) DD_LSDIGIT(partial); } return((DdApaDigit) DD_MSDIGIT(partial)); @@ -232,31 +229,27 @@ Cudd_ApaAdd( } /* end of Cudd_ApaAdd */ -/**Function******************************************************************** - - Synopsis [Subtracts two arbitrary precision integers.] - - Description [Subtracts two arbitrary precision integers. Returns the - borrow out of the most significant digit.] +/** + @brief Subtracts two arbitrary precision integers. - SideEffects [The result of the subtraction is stored in parameter - <code>diff</code>.] + @return the borrow out of the most significant digit. - SeeAlso [] + @sideeffect The result of the subtraction is stored in parameter + <code>diff</code>. -******************************************************************************/ +*/ DdApaDigit Cudd_ApaSubtract( int digits, - DdApaNumber a, - DdApaNumber b, - DdApaNumber diff) + DdConstApaNumber a, + DdConstApaNumber b, + DdApaNumber diff) { int i; DdApaDoubleDigit partial = DD_APA_BASE; for (i = digits - 1; i >= 0; i--) { - partial = DD_MSDIGIT(partial) + DD_APA_MASK + a[i] - b[i]; + partial = DD_MSDIGIT(partial) + DD_APA_MASK + a[i] - b[i]; diff[i] = (DdApaDigit) DD_LSDIGIT(partial); } return((DdApaDigit) DD_MSDIGIT(partial) - 1); @@ -264,23 +257,20 @@ Cudd_ApaSubtract( } /* end of Cudd_ApaSubtract */ -/**Function******************************************************************** +/** + @brief Divides an arbitrary precision integer by a digit. - Synopsis [Divides an arbitrary precision integer by a digit.] + @return the remainder digit. - Description [Divides an arbitrary precision integer by a digit.] + @sideeffect The quotient is returned in parameter <code>quotient</code>. - SideEffects [The quotient is returned in parameter <code>quotient</code>.] - - SeeAlso [] - -******************************************************************************/ +*/ DdApaDigit Cudd_ApaShortDivision( int digits, - DdApaNumber dividend, - DdApaDigit divisor, - DdApaNumber quotient) + DdConstApaNumber dividend, + DdApaDigit divisor, + DdApaNumber quotient) { int i; DdApaDigit remainder; @@ -298,28 +288,31 @@ Cudd_ApaShortDivision( } /* end of Cudd_ApaShortDivision */ -/**Function******************************************************************** +/** + @brief Divides an arbitrary precision integer by an integer. - Synopsis [Divides an arbitrary precision integer by an integer.] + @details Divides an arbitrary precision integer by a 32-bit unsigned + integer. This procedure relies on the assumption that the number of + bits of a DdApaDigit plus the number of bits of an unsigned int is + less the number of bits of the mantissa of a double. This guarantees + that the product of a DdApaDigit and an unsigned int can be + represented without loss of precision by a double. On machines where + this assumption is not satisfied, this procedure will malfunction. - Description [Divides an arbitrary precision integer by a 32-bit - unsigned integer. Returns the remainder of the division. This - procedure relies on the assumption that the number of bits of a - DdApaDigit plus the number of bits of an unsigned int is less the - number of bits of the mantissa of a double. This guarantees that the - product of a DdApaDigit and an unsigned int can be represented - without loss of precision by a double. On machines where this - assumption is not satisfied, this procedure will malfunction.] + @return the remainder. - SideEffects [The quotient is returned in parameter <code>quotient</code>.] + @sideeffect The quotient is returned in parameter <code>quotient</code>. - SeeAlso [Cudd_ApaShortDivision] + @deprecated The assumption on which the correctness of this function rests + is not satisfied by modern-day 64-bit CPUs. -******************************************************************************/ + @see Cudd_ApaShortDivision + +*/ unsigned int Cudd_ApaIntDivision( int digits, - DdApaNumber dividend, + DdConstApaNumber dividend, unsigned int divisor, DdApaNumber quotient) { @@ -339,26 +332,22 @@ Cudd_ApaIntDivision( } /* end of Cudd_ApaIntDivision */ -/**Function******************************************************************** - - Synopsis [Shifts right an arbitrary precision integer by one binary - place.] - - Description [Shifts right an arbitrary precision integer by one - binary place. The most significant binary digit of the result is - taken from parameter <code>in</code>.] +/** + @brief Shifts right an arbitrary precision integer by one binary + place. - SideEffects [The result is returned in parameter <code>b</code>.] + @details The most significant binary digit of the result is taken + from parameter <code>in</code>. - SeeAlso [] + @sideeffect The result is returned in parameter <code>b</code>. -******************************************************************************/ +*/ void Cudd_ApaShiftRight( - int digits, - DdApaDigit in, - DdApaNumber a, - DdApaNumber b) + int digits, + DdApaDigit in, + DdConstApaNumber a, + DdApaNumber b) { int i; @@ -370,22 +359,17 @@ Cudd_ApaShiftRight( } /* end of Cudd_ApaShiftRight */ -/**Function******************************************************************** - - Synopsis [Sets an arbitrary precision integer to a one-digit literal.] - - Description [Sets an arbitrary precision integer to a one-digit literal.] +/** + @brief Sets an arbitrary precision integer to a one-digit literal. - SideEffects [The result is returned in parameter <code>number</code>.] + @sideeffect The result is returned in parameter <code>number</code>. - SeeAlso [] - -******************************************************************************/ +*/ void Cudd_ApaSetToLiteral( - int digits, - DdApaNumber number, - DdApaDigit literal) + int digits, + DdApaNumber number, + DdApaDigit literal) { int i; @@ -396,24 +380,20 @@ Cudd_ApaSetToLiteral( } /* end of Cudd_ApaSetToLiteral */ -/**Function******************************************************************** - - Synopsis [Sets an arbitrary precision integer to a power of two.] - - Description [Sets an arbitrary precision integer to a power of - two. If the power of two is too large to be represented, the number - is set to 0.] +/** + @brief Sets an arbitrary precision integer to a power of two. - SideEffects [The result is returned in parameter <code>number</code>.] + @details If the power of two is too large to be represented, the number + is set to 0. - SeeAlso [] + @sideeffect The result is returned in parameter <code>number</code>. -******************************************************************************/ +*/ void Cudd_ApaPowerOfTwo( - int digits, - DdApaNumber number, - int power) + int digits, + DdApaNumber number, + int power) { int i; int index; @@ -423,30 +403,26 @@ Cudd_ApaPowerOfTwo( i = digits - 1 - power / DD_APA_BITS; if (i < 0) return; index = power & (DD_APA_BITS - 1); - number[i] = 1 << index; + number[i] = (DdApaDigit) 1 << index; } /* end of Cudd_ApaPowerOfTwo */ -/**Function******************************************************************** - - Synopsis [Compares two arbitrary precision integers.] - - Description [Compares two arbitrary precision integers. Returns 1 if - the first number is larger; 0 if they are equal; -1 if the second - number is larger.] +/** + @brief Compares two arbitrary precision integers. - SideEffects [None] + @return 1 if the first number is larger; 0 if they are equal; -1 if + the second number is larger. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Cudd_ApaCompare( int digitsFirst, - DdApaNumber first, + DdConstApaNumber first, int digitsSecond, - DdApaNumber second) + DdConstApaNumber second) { int i; int firstNZ, secondNZ; @@ -467,27 +443,23 @@ Cudd_ApaCompare( } /* end of Cudd_ApaCompare */ -/**Function******************************************************************** +/** + @brief Compares the ratios of two arbitrary precision integers to two + unsigned ints. - Synopsis [Compares the ratios of two arbitrary precision integers to two - unsigned ints.] + @return 1 if the first number is larger; 0 if they are equal; -1 if + the second number is larger. - Description [Compares the ratios of two arbitrary precision integers - to two unsigned ints. Returns 1 if the first number is larger; 0 if - they are equal; -1 if the second number is larger.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ int Cudd_ApaCompareRatios( int digitsFirst, - DdApaNumber firstNum, + DdConstApaNumber firstNum, unsigned int firstDen, int digitsSecond, - DdApaNumber secondNum, + DdConstApaNumber secondNum, unsigned int secondDen) { int result; @@ -512,28 +484,26 @@ Cudd_ApaCompareRatios( } /* end of Cudd_ApaCompareRatios */ -/**Function******************************************************************** - - Synopsis [Prints an arbitrary precision integer in hexadecimal format.] +/** + @brief Prints an arbitrary precision integer in hexadecimal format. - Description [Prints an arbitrary precision integer in hexadecimal format. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_ApaPrintDecimal Cudd_ApaPrintExponential] + @see Cudd_ApaPrintDecimal Cudd_ApaPrintExponential -******************************************************************************/ +*/ int Cudd_ApaPrintHex( FILE * fp, - int digits, - DdApaNumber number) + int digits, + DdConstApaNumber number) { int i, result; for (i = 0; i < digits; i++) { - result = fprintf(fp,DD_APA_HEXPRINT,number[i]); + result = fprintf(fp, "%0*x", (int) sizeof(DdApaDigit) * 2, number[i]); if (result == EOF) return(0); } @@ -542,23 +512,21 @@ Cudd_ApaPrintHex( } /* end of Cudd_ApaPrintHex */ -/**Function******************************************************************** - - Synopsis [Prints an arbitrary precision integer in decimal format.] +/** + @brief Prints an arbitrary precision integer in decimal format. - Description [Prints an arbitrary precision integer in decimal format. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_ApaPrintHex Cudd_ApaPrintExponential] + @see Cudd_ApaPrintHex Cudd_ApaPrintExponential -******************************************************************************/ +*/ int Cudd_ApaPrintDecimal( FILE * fp, - int digits, - DdApaNumber number) + int digits, + DdConstApaNumber number) { int i, result; DdApaDigit remainder; @@ -599,31 +567,93 @@ Cudd_ApaPrintDecimal( } /* end of Cudd_ApaPrintDecimal */ -/**Function******************************************************************** +/** + @brief converts an arbitrary precision integer to a string in decimal format. - Synopsis [Prints an arbitrary precision integer in exponential format.] + @return the string if successful; NULL otherwise. - Description [Prints an arbitrary precision integer in exponential format. - Returns 1 if successful; 0 otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_ApaPrintDecimal - SeeAlso [Cudd_ApaPrintHex Cudd_ApaPrintDecimal] +*/ +char * +Cudd_ApaStringDecimal( + int digits, + DdConstApaNumber number) +{ + int i, fsd; + DdApaDigit remainder; + DdApaNumber work; + char *decimal, *ret; + int decimalDigits = (int) (digits * log10((double) DD_APA_BASE)) + 1; + + work = Cudd_NewApaNumber(digits); + if (work == NULL) { + return(0); + } + decimal = ALLOC(char, decimalDigits); + if (decimal == NULL) { + FREE(work); + return(0); + } + Cudd_ApaCopy(digits,number,work); + for (i = decimalDigits - 1; i >= 0; i--) { + remainder = Cudd_ApaShortDivision(digits,work,(DdApaDigit) 10,work); + decimal[i] = (char) remainder; + } + FREE(work); + + /* Find first significant digit. */ + for (fsd = 0; fsd < decimalDigits-1; fsd++) { + if (decimal[fsd] != 0) + break; + } + ret = ALLOC(char, decimalDigits - fsd + 1); + if (ret == NULL) { + FREE(decimal); + return(NULL); + } + for (i = fsd; i < decimalDigits; i++) { + ret[i-fsd] = decimal[i] + '0'; + } + ret[decimalDigits-fsd] = '\0'; + FREE(decimal); + return(ret); + +} /* end of Cudd_ApaStringDecimal */ + + +/** + @brief Prints an arbitrary precision integer in exponential format. + + @details Prints as an integer if precision is at least the number of + digits to be printed. If precision does not allow printing of all + digits, rounds to nearest breaking ties so that the last printed + digit is even. -******************************************************************************/ + @return 1 if successful; 0 otherwise. + + @sideeffect None + + @see Cudd_ApaPrintHex Cudd_ApaPrintDecimal + +*/ int Cudd_ApaPrintExponential( FILE * fp, - int digits, - DdApaNumber number, + int digits, + DdConstApaNumber number, int precision) { int i, first, last, result; DdApaDigit remainder; DdApaNumber work; - unsigned char *decimal; - int decimalDigits = (int) (digits * log10((double) DD_APA_BASE)) + 1; + unsigned char *decimal, carry; + /* We add an extra digit to have room for rounding up. */ + int decimalDigits = (int) (digits * log10((double) DD_APA_BASE)) + 2; + /* Convert to decimal. */ work = Cudd_NewApaNumber(digits); if (work == NULL) return(0); @@ -642,6 +672,59 @@ Cudd_ApaPrintExponential( FREE(work); last = ddMin(first + precision, decimalDigits); + /* See if we can print as integer. */ + if (decimalDigits - first <= precision) { + for (i = first; i < last; i++) { + result = fprintf(fp,"%1d", decimal[i]); + if (result == EOF) { + FREE(decimal); + return(0); + } + } + FREE(decimal); + return(1); + } + + /* If we get here we need to print an exponent. Take care of rounding. */ + if (last == decimalDigits) { + carry = 0; + } else if (decimal[last] < 5) { + carry = 0; + } else if (decimal[last] == 5) { + int nonZero = CUDD_FALSE; + for (i = last + 1; i < decimalDigits; i++) { + if (decimal[i] > 0) { + nonZero = CUDD_TRUE; + break; + } + } + if (nonZero) { + carry = 1; + } else if (decimal[last - 1] & 1) { /* odd */ + carry = 1; + } else { + carry = 0; + } + } else { + carry = 1; + } + + /* Add carry. */ + for (i = last - 1; i >= 0; i--) { + unsigned char tmp = decimal[i] + carry; + if (tmp < 10) { + decimal[i] = tmp; + break; + } else { + decimal[i] = tmp - 10; + } + } + + /* Don't print trailing zeros. */ + while (last > first && decimal[last - 1] == 0) + last--; + + /* Print. */ for (i = first; i < last; i++) { result = fprintf(fp,"%s%1d",i == first+1 ? "." : "", decimal[i]); if (result == EOF) { @@ -650,7 +733,7 @@ Cudd_ApaPrintExponential( } } FREE(decimal); - result = fprintf(fp,"e+%d",decimalDigits - first - 1); + result = fprintf(fp,"e+%02d",decimalDigits - first - 1); if (result == EOF) { return(0); } @@ -659,79 +742,75 @@ Cudd_ApaPrintExponential( } /* end of Cudd_ApaPrintExponential */ -/**Function******************************************************************** +/** + @brief Counts the number of minterms of a %DD. - Synopsis [Counts the number of minterms of a DD.] + @details The function is assumed to depend on nvars variables. The + minterm count is represented as an arbitrary precision unsigned + integer, to allow for any number of variables CUDD supports. - Description [Counts the number of minterms of a DD. The function is - assumed to depend on nvars variables. The minterm count is - represented as an arbitrary precision unsigned integer, to allow for - any number of variables CUDD supports. Returns a pointer to the - array representing the number of minterms of the function rooted at - node if successful; NULL otherwise.] + @return a pointer to the array representing the number of minterms + of the function rooted at node if successful; NULL otherwise. - SideEffects [The number of digits of the result is returned in - parameter <code>digits</code>.] + @sideeffect The number of digits of the result is returned in + parameter <code>digits</code>. - SeeAlso [Cudd_CountMinterm] + @see Cudd_CountMinterm -******************************************************************************/ +*/ DdApaNumber Cudd_ApaCountMinterm( - DdManager * manager, + DdManager const * manager, DdNode * node, int nvars, int * digits) { - DdApaNumber max, min; + DdApaNumber mmax, mmin; st_table *table; DdApaNumber i,count; - background = manager->background; - zero = Cudd_Not(manager->one); - *digits = Cudd_ApaNumberOfDigits(nvars+1); - max = Cudd_NewApaNumber(*digits); - if (max == NULL) { + mmax = Cudd_NewApaNumber(*digits); + if (mmax == NULL) { return(NULL); } - Cudd_ApaPowerOfTwo(*digits,max,nvars); - min = Cudd_NewApaNumber(*digits); - if (min == NULL) { - FREE(max); + Cudd_ApaPowerOfTwo(*digits,mmax,nvars); + mmin = Cudd_NewApaNumber(*digits); + if (mmin == NULL) { + FREE(mmax); return(NULL); } - Cudd_ApaSetToLiteral(*digits,min,0); + Cudd_ApaSetToLiteral(*digits,mmin,0); table = st_init_table(st_ptrcmp,st_ptrhash); if (table == NULL) { - FREE(max); - FREE(min); + FREE(mmax); + FREE(mmin); return(NULL); } - i = cuddApaCountMintermAux(Cudd_Regular(node),*digits,max,min,table); + i = cuddApaCountMintermAux(manager, Cudd_Regular(node),*digits,mmax,mmin,table); if (i == NULL) { - FREE(max); - FREE(min); + FREE(mmax); + FREE(mmin); st_foreach(table, cuddApaStCountfree, NULL); st_free_table(table); return(NULL); } count = Cudd_NewApaNumber(*digits); if (count == NULL) { - FREE(max); - FREE(min); + FREE(mmax); + FREE(mmin); st_foreach(table, cuddApaStCountfree, NULL); st_free_table(table); if (Cudd_Regular(node)->ref == 1) FREE(i); return(NULL); } if (Cudd_IsComplement(node)) { - (void) Cudd_ApaSubtract(*digits,max,i,count); + (void) Cudd_ApaSubtract(*digits,mmax,i,count); } else { Cudd_ApaCopy(*digits,i,count); } - FREE(max); - FREE(min); + FREE(mmax); + FREE(mmin); st_foreach(table, cuddApaStCountfree, NULL); st_free_table(table); if (Cudd_Regular(node)->ref == 1) FREE(i); @@ -740,23 +819,21 @@ Cudd_ApaCountMinterm( } /* end of Cudd_ApaCountMinterm */ -/**Function******************************************************************** +/** + @brief Prints the number of minterms of a %BDD or %ADD using arbitrary + precision arithmetic. - Synopsis [Prints the number of minterms of a BDD or ADD using - arbitrary precision arithmetic.] + @return 1 if successful; 0 otherwise. - Description [Prints the number of minterms of a BDD or ADD using - arbitrary precision arithmetic. Returns 1 if successful; 0 otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_ApaPrintMintermExp - SeeAlso [Cudd_ApaPrintMintermExp] - -******************************************************************************/ +*/ int Cudd_ApaPrintMinterm( FILE * fp, - DdManager * dd, + DdManager const * dd, DdNode * node, int nvars) { @@ -777,27 +854,26 @@ Cudd_ApaPrintMinterm( } /* end of Cudd_ApaPrintMinterm */ -/**Function******************************************************************** +/** + @brief Prints the number of minterms of a %BDD or %ADD in + exponential format using arbitrary precision arithmetic. - Synopsis [Prints the number of minterms of a BDD or ADD in exponential - format using arbitrary precision arithmetic.] + @details Parameter precision controls the number of signficant + digits printed. - Description [Prints the number of minterms of a BDD or ADD in - exponential format using arbitrary precision arithmetic. Parameter - precision controls the number of signficant digits printed. Returns - 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_ApaPrintMinterm] + @see Cudd_ApaPrintMinterm -******************************************************************************/ +*/ int Cudd_ApaPrintMintermExp( FILE * fp, - DdManager * dd, + DdManager const * dd, DdNode * node, - int nvars, + int nvars, int precision) { int digits; @@ -817,25 +893,21 @@ Cudd_ApaPrintMintermExp( } /* end of Cudd_ApaPrintMintermExp */ -/**Function******************************************************************** - - Synopsis [Prints the density of a BDD or ADD using - arbitrary precision arithmetic.] +/** + @brief Prints the density of a %BDD or %ADD using arbitrary + precision arithmetic. - Description [Prints the density of a BDD or ADD using - arbitrary precision arithmetic. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int Cudd_ApaPrintDensity( FILE * fp, DdManager * dd, DdNode * node, - int nvars) + int nvars) { int digits; int result; @@ -845,7 +917,7 @@ Cudd_ApaPrintDensity( count = Cudd_ApaCountMinterm(dd,node,nvars,&digits); if (count == NULL) return(0); - size = Cudd_DagSize(node); + size = (unsigned int) Cudd_DagSize(node); density = Cudd_NewApaNumber(digits); remainder = Cudd_ApaIntDivision(digits,count,size,density); result = Cudd_ApaPrintDecimal(fp,digits,density); @@ -870,33 +942,33 @@ Cudd_ApaPrintDensity( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_ApaCountMinterm. + + @details It is based on the following identity. Let <code>|f|</code> be the + number of minterms of <code>f</code>. Then: - Synopsis [Performs the recursive step of Cudd_ApaCountMinterm.] + |f| = (|f0|+|f1|)/2 - Description [Performs the recursive step of Cudd_ApaCountMinterm. - It is based on the following identity. Let |f| be the - number of minterms of f. Then: - <xmp> - |f| = (|f0|+|f1|)/2 - </xmp> where f0 and f1 are the two cofactors of f. - Uses the identity <code>|f'| = max - |f|</code>. + Uses the identity <code>|f'| = mmax - |f|</code>. The procedure expects the argument "node" to be a regular pointer, and guarantees this condition is met in the recursive calls. For efficiency, the result of a call is cached only if the node has a reference count greater than 1. - Returns the number of minterms of the function rooted at node.] - SideEffects [None] + @return the number of minterms of the function rooted at node. -******************************************************************************/ + @sideeffect None + +*/ static DdApaNumber cuddApaCountMintermAux( + DdManager const * manager, DdNode * node, - int digits, - DdApaNumber max, - DdApaNumber min, + int digits, + DdApaNumber mmax, + DdApaNumber mmin, st_table * table) { DdNode *Nt, *Ne; @@ -904,21 +976,40 @@ cuddApaCountMintermAux( DdApaDigit carryout; if (cuddIsConstant(node)) { - if (node == background || node == zero) { - return(min); + int singleRef = Cudd_Regular(node)->ref == 1; + if (node == manager->background || node == Cudd_Not(manager->one)) { + if (singleRef) { + mint = Cudd_NewApaNumber(digits); + if (mint == NULL) { + return(NULL); + } + Cudd_ApaCopy(digits, mmin, mint); + return(mint); + } else { + return(mmin); + } } else { - return(max); + if (singleRef) { + mint = Cudd_NewApaNumber(digits); + if (mint == NULL) { + return(NULL); + } + Cudd_ApaCopy(digits, mmax, mint); + return(mint); + } else { + return(mmax); + } } } - if (node->ref > 1 && st_lookup(table, node, &mint)) { + if (node->ref > 1 && st_lookup(table, node, (void **) &mint)) { return(mint); } Nt = cuddT(node); Ne = cuddE(node); - mint1 = cuddApaCountMintermAux(Nt, digits, max, min, table); + mint1 = cuddApaCountMintermAux(manager, Nt, digits, mmax, mmin, table); if (mint1 == NULL) return(NULL); - mint2 = cuddApaCountMintermAux(Cudd_Regular(Ne), digits, max, min, table); + mint2 = cuddApaCountMintermAux(manager, Cudd_Regular(Ne), digits, mmax, mmin, table); if (mint2 == NULL) { if (Nt->ref == 1) FREE(mint1); return(NULL); @@ -930,7 +1021,7 @@ cuddApaCountMintermAux( return(NULL); } if (Cudd_IsComplement(Ne)) { - (void) Cudd_ApaSubtract(digits,max,mint2,mint); + (void) Cudd_ApaSubtract(digits,mmax,mint2,mint); carryout = Cudd_ApaAdd(digits,mint1,mint,mint); } else { carryout = Cudd_ApaAdd(digits,mint1,mint2,mint); @@ -943,7 +1034,7 @@ cuddApaCountMintermAux( if (Cudd_Regular(Ne)->ref == 1) FREE(mint2); if (node->ref > 1) { - if (st_insert(table, (char *)node, (char *)mint) == ST_OUT_OF_MEM) { + if (st_insert(table, node, mint) == ST_OUT_OF_MEM) { FREE(mint); return(NULL); } @@ -953,25 +1044,25 @@ cuddApaCountMintermAux( } /* end of cuddApaCountMintermAux */ -/**Function******************************************************************** - - Synopsis [Frees the memory used to store the minterm counts recorded - in the visited table.] +/** + @brief Frees the memory used to store the minterm counts recorded + in the visited table. - Description [Frees the memory used to store the minterm counts - recorded in the visited table. Returns ST_CONTINUE.] + @return ST_CONTINUE. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static enum st_retval cuddApaStCountfree( - char * key, - char * value, - char * arg) + void * key, + void * value, + void * arg) { DdApaNumber d; + (void) key; /* avoid warning */ + (void) arg; /* avoid warning */ d = (DdApaNumber) value; FREE(d); return(ST_CONTINUE); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddApprox.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddApprox.c similarity index 69% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddApprox.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddApprox.c index 23f97415f..601f83b1e 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddApprox.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddApprox.c @@ -1,47 +1,16 @@ -/**CFile*********************************************************************** - - FileName [cuddApprox.c] - - PackageName [cudd] - - Synopsis [Procedures to approximate a given BDD.] - - Description [External procedures provided by this module: - <ul> - <li> Cudd_UnderApprox() - <li> Cudd_OverApprox() - <li> Cudd_RemapUnderApprox() - <li> Cudd_RemapOverApprox() - <li> Cudd_BiasedUnderApprox() - <li> Cudd_BiasedOverApprox() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddUnderApprox() - <li> cuddRemapUnderApprox() - <li> cuddBiasedUnderApprox() - </ul> - Static procedures included in this module: - <ul> - <li> updateParity() - <li> gatherInfoAux() - <li> gatherInfo() - <li> computeSavings() - <li> updateRefs() - <li> UAmarkNodes() - <li> UAbuildSubset() - <li> RAmarkNodes() - <li> BAmarkNodes() - <li> RAbuildSubset() - <li> BAapplyBias() - </ul> - ] - - SeeAlso [cuddSubsetHB.c cuddSubsetSP.c cuddGenCof.c] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Procedures to approximate a given %BDD. + + @see cuddSubsetHB.c cuddSubsetSP.c cuddGenCof.c + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -71,9 +40,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #ifdef __STDC__ #include <float.h> @@ -107,38 +77,46 @@ /* Type declarations */ /*---------------------------------------------------------------------------*/ -/* Data structure to store the information on each node. It keeps the -** number of minterms of the function rooted at this node in terms of -** the number of variables specified by the user; the number of -** minterms of the complement; the impact of the number of minterms of -** this function on the number of minterms of the root function; the -** reference count of the node from within the root function; the -** flag that says whether the node intersects the care set; the flag -** that says whether the node should be replaced and how; the results -** of subsetting in both phases. */ +/** + ** @brief Data structure to store the information on each node. + ** + ** @details It keeps the number of minterms of the function rooted at + ** this node in terms of the number of variables specified by the + ** user; the number of minterms of the complement; the impact of the + ** number of minterms of this function on the number of minterms of + ** the root function; the reference count of the node from within the + ** root function; the flag that says whether the node intersects the + ** care set; the flag that says whether the node should be replaced + ** and how; the results of subsetting in both phases. + */ typedef struct NodeData { - double mintermsP; /* minterms for the regular node */ - double mintermsN; /* minterms for the complemented node */ - int functionRef; /* references from within this function */ - char care; /* node intersects care set */ - char replace; /* replacement decision */ - short int parity; /* 1: even; 2: odd; 3: both */ - DdNode *resultP; /* result for even parity */ - DdNode *resultN; /* result for odd parity */ + double mintermsP; /**< minterms for the regular node */ + double mintermsN; /**< minterms for the complemented node */ + int functionRef; /**< references from within this function */ + char care; /**< node intersects care set */ + char replace; /**< replacement decision */ + short int parity; /**< 1: even; 2: odd; 3: both */ + DdNode *resultP; /**< result for even parity */ + DdNode *resultN; /**< result for odd parity */ } NodeData; +/** + ** @brief Main bookkeeping data structure for approximation algorithms. + */ typedef struct ApproxInfo { - DdNode *one; /* one constant */ - DdNode *zero; /* BDD zero constant */ - NodeData *page; /* per-node information */ - DdHashTable *table; /* hash table to access the per-node info */ - int index; /* index of the current node */ - double max; /* max number of minterms */ - int size; /* how many nodes are left */ - double minterms; /* how many minterms are left */ + DdNode *one; /**< one constant */ + DdNode *zero; /**< %BDD zero constant */ + NodeData *page; /**< per-node information */ + DdHashTable *table; /**< hash table to access the per-node info */ + int index; /**< index of the current node */ + double max; /**< max number of minterms */ + int size; /**< how many nodes are left */ + double minterms; /**< how many minterms are left */ } ApproxInfo; -/* Item of the queue used in the levelized traversal of the BDD. */ +/** + ** @brief Item of the queue used in the levelized traversal of the %BDD. + */ typedef struct GlobalQueueItem { struct GlobalQueueItem *next; struct GlobalQueueItem *cnext; @@ -146,7 +124,10 @@ typedef struct GlobalQueueItem { double impactP; double impactN; } GlobalQueueItem; - + +/** + ** @brief Type of the item of the local queue. + */ typedef struct LocalQueueItem { struct LocalQueueItem *next; struct LocalQueueItem *cnext; @@ -159,15 +140,12 @@ typedef struct LocalQueueItem { /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddApprox.c,v 1.31 2012/02/05 04:38:07 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -185,23 +163,20 @@ static int BAmarkNodes (DdManager *dd, DdNode *f, ApproxInfo *info, int threshol static DdNode * RAbuildSubset (DdManager *dd, DdNode *node, ApproxInfo *info); static int BAapplyBias (DdManager *dd, DdNode *f, DdNode *b, ApproxInfo *info, DdHashTable *cache); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Extracts a dense subset from a BDD with Shiple's - underapproximation method.] +/** + @brief Extracts a dense subset from a %BDD with Shiple's + underapproximation method. - Description [Extracts a dense subset from a BDD. This procedure uses - a variant of Tom Shiple's underapproximation method. The main - difference from the original method is that density is used as cost - function. Returns a pointer to the BDD of the subset if - successful. NULL if the procedure runs out of memory. The parameter + @details This procedure uses a variant of Tom Shiple's + underapproximation method. The main difference from the original + method is that density is used as cost function. The parameter numVars is the maximum number of variables to be used in minterm calculation. The optimal number should be as close as possible to the size of the support of f. However, it is safe to pass the value @@ -209,21 +184,24 @@ static int BAapplyBias (DdManager *dd, DdNode *f, DdNode *b, ApproxInfo *info, D is under 1023. If numVars is larger than 1023, it will cause overflow. If a 0 parameter is passed then the procedure will compute a value which will avoid overflow but will cause underflow with 2046 - variables or more.] + variables or more. + + @return a pointer to the %BDD of the subset if successful; NULL if + the procedure runs out of memory. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_SubsetShortPaths Cudd_SubsetHeavyBranch Cudd_ReadSize] + @see Cudd_SubsetShortPaths Cudd_SubsetHeavyBranch Cudd_ReadSize -******************************************************************************/ +*/ DdNode * Cudd_UnderApprox( - DdManager * dd /* manager */, - DdNode * f /* function to be subset */, - int numVars /* number of variables in the support of f */, - int threshold /* when to stop approximation */, - int safe /* enforce safe approximation */, - double quality /* minimum improvement for accepted changes */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be subset */, + int numVars /**< number of variables in the support of f */, + int threshold /**< when to stop approximation */, + int safe /**< enforce safe approximation */, + double quality /**< minimum improvement for accepted changes */) { DdNode *subset; @@ -231,46 +209,48 @@ Cudd_UnderApprox( dd->reordered = 0; subset = cuddUnderApprox(dd, f, numVars, threshold, safe, quality); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(subset); } /* end of Cudd_UnderApprox */ -/**Function******************************************************************** +/** + @brief Extracts a dense superset from a %BDD with Shiple's + underapproximation method. - Synopsis [Extracts a dense superset from a BDD with Shiple's - underapproximation method.] - - Description [Extracts a dense superset from a BDD. The procedure is - identical to the underapproximation procedure except for the fact that it - works on the complement of the given function. Extracting the subset - of the complement function is equivalent to extracting the superset - of the function. - Returns a pointer to the BDD of the superset if successful. NULL if - intermediate result causes the procedure to run out of memory. The + @details The procedure is identical to the underapproximation + procedure except for the fact that it works on the complement of the + given function. Extracting the subset of the complement function is + equivalent to extracting the superset of the function. The parameter numVars is the maximum number of variables to be used in - minterm calculation. The optimal number - should be as close as possible to the size of the support of f. - However, it is safe to pass the value returned by Cudd_ReadSize for - numVars when the number of variables is under 1023. If numVars is - larger than 1023, it will overflow. If a 0 parameter is passed then - the procedure will compute a value which will avoid overflow but - will cause underflow with 2046 variables or more.] + minterm calculation. The optimal number should be as close as + possible to the size of the support of f. However, it is safe to + pass the value returned by Cudd_ReadSize for numVars when the number + of variables is under 1023. If numVars is larger than 1023, it will + overflow. If a 0 parameter is passed then the procedure will compute + a value which will avoid overflow but will cause underflow with 2046 + variables or more. + + @return a pointer to the %BDD of the superset if successful. NULL if + intermediate result causes the procedure to run out of memory. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_SupersetHeavyBranch Cudd_SupersetShortPaths Cudd_ReadSize] + @see Cudd_SupersetHeavyBranch Cudd_SupersetShortPaths Cudd_ReadSize -******************************************************************************/ +*/ DdNode * Cudd_OverApprox( - DdManager * dd /* manager */, - DdNode * f /* function to be superset */, - int numVars /* number of variables in the support of f */, - int threshold /* when to stop approximation */, - int safe /* enforce safe approximation */, - double quality /* minimum improvement for accepted changes */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be superset */, + int numVars /**< number of variables in the support of f */, + int threshold /**< when to stop approximation */, + int safe /**< enforce safe approximation */, + double quality /**< minimum improvement for accepted changes */) { DdNode *subset, *g; @@ -279,42 +259,44 @@ Cudd_OverApprox( dd->reordered = 0; subset = cuddUnderApprox(dd, g, numVars, threshold, safe, quality); } while (dd->reordered == 1); - + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(Cudd_NotCond(subset, (subset != NULL))); } /* end of Cudd_OverApprox */ -/**Function******************************************************************** - - Synopsis [Extracts a dense subset from a BDD with the remapping - underapproximation method.] +/** + @brief Extracts a dense subset from a %BDD with the remapping + underapproximation method. - Description [Extracts a dense subset from a BDD. This procedure uses - a remapping technique and density as the cost function. - Returns a pointer to the BDD of the subset if - successful. NULL if the procedure runs out of memory. The parameter - numVars is the maximum number of variables to be used in minterm - calculation. The optimal number should be as close as possible to - the size of the support of f. However, it is safe to pass the value - returned by Cudd_ReadSize for numVars when the number of variables - is under 1023. If numVars is larger than 1023, it will cause - overflow. If a 0 parameter is passed then the procedure will compute - a value which will avoid overflow but will cause underflow with 2046 - variables or more.] + @details This procedure uses a remapping technique and density as + the cost function. The parameter numVars is the maximum number of + variables to be used in minterm calculation. The optimal number + should be as close as possible to the size of the support of f. + However, it is safe to pass the value returned by Cudd_ReadSize for + numVars when the number of variables is under 1023. If numVars is + larger than 1023, it will cause overflow. If a 0 parameter is passed + then the procedure will compute a value which will avoid overflow + but will cause underflow with 2046 variables or more. - SideEffects [None] + @return a pointer to the %BDD of the subset if successful. NULL if + the procedure runs out of memory. + + @sideeffect None - SeeAlso [Cudd_SubsetShortPaths Cudd_SubsetHeavyBranch Cudd_UnderApprox Cudd_ReadSize] + @see Cudd_SubsetShortPaths Cudd_SubsetHeavyBranch Cudd_UnderApprox Cudd_ReadSize -******************************************************************************/ +*/ DdNode * Cudd_RemapUnderApprox( - DdManager * dd /* manager */, - DdNode * f /* function to be subset */, - int numVars /* number of variables in the support of f */, - int threshold /* when to stop approximation */, - double quality /* minimum improvement for accepted changes */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be subset */, + int numVars /**< number of variables in the support of f */, + int threshold /**< when to stop approximation */, + double quality /**< minimum improvement for accepted changes */) { DdNode *subset; @@ -322,45 +304,47 @@ Cudd_RemapUnderApprox( dd->reordered = 0; subset = cuddRemapUnderApprox(dd, f, numVars, threshold, quality); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(subset); } /* end of Cudd_RemapUnderApprox */ -/**Function******************************************************************** - - Synopsis [Extracts a dense superset from a BDD with the remapping - underapproximation method.] +/** + @brief Extracts a dense superset from a %BDD with the remapping + underapproximation method. - Description [Extracts a dense superset from a BDD. The procedure is - identical to the underapproximation procedure except for the fact that it - works on the complement of the given function. Extracting the subset - of the complement function is equivalent to extracting the superset - of the function. - Returns a pointer to the BDD of the superset if successful. NULL if - intermediate result causes the procedure to run out of memory. The - parameter numVars is the maximum number of variables to be used in - minterm calculation. The optimal number - should be as close as possible to the size of the support of f. - However, it is safe to pass the value returned by Cudd_ReadSize for - numVars when the number of variables is under 1023. If numVars is - larger than 1023, it will overflow. If a 0 parameter is passed then - the procedure will compute a value which will avoid overflow but - will cause underflow with 2046 variables or more.] + @details The procedure is identical to the underapproximation + procedure except for the fact that it works on the complement of the + given function. Extracting the subset of the complement function is + equivalent to extracting the superset of the function. The parameter + numVars is the maximum number of variables to be used in minterm + calculation. The optimal number should be as close as possible to + the size of the support of f. However, it is safe to pass the value + returned by Cudd_ReadSize for numVars when the number of variables + is under 1023. If numVars is larger than 1023, it will overflow. If + a 0 parameter is passed then the procedure will compute a value + which will avoid overflow but will cause underflow with 2046 + variables or more. - SideEffects [None] + @return a pointer to the %BDD of the superset if successful. NULL if + intermediate result causes the procedure to run out of memory. + + @sideeffect None - SeeAlso [Cudd_SupersetHeavyBranch Cudd_SupersetShortPaths Cudd_ReadSize] + @see Cudd_SupersetHeavyBranch Cudd_SupersetShortPaths Cudd_ReadSize -******************************************************************************/ +*/ DdNode * Cudd_RemapOverApprox( - DdManager * dd /* manager */, - DdNode * f /* function to be superset */, - int numVars /* number of variables in the support of f */, - int threshold /* when to stop approximation */, - double quality /* minimum improvement for accepted changes */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be superset */, + int numVars /**< number of variables in the support of f */, + int threshold /**< when to stop approximation */, + double quality /**< minimum improvement for accepted changes */) { DdNode *subset, *g; @@ -369,47 +353,49 @@ Cudd_RemapOverApprox( dd->reordered = 0; subset = cuddRemapUnderApprox(dd, g, numVars, threshold, quality); } while (dd->reordered == 1); - + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(Cudd_NotCond(subset, (subset != NULL))); } /* end of Cudd_RemapOverApprox */ -/**Function******************************************************************** - - Synopsis [Extracts a dense subset from a BDD with the biased - underapproximation method.] +/** + @brief Extracts a dense subset from a %BDD with the biased + underapproximation method. - Description [Extracts a dense subset from a BDD. This procedure uses - a biased remapping technique and density as the cost function. The bias - is a function. This procedure tries to approximate where the bias is 0 - and preserve the given function where the bias is 1. - Returns a pointer to the BDD of the subset if - successful. NULL if the procedure runs out of memory. The parameter - numVars is the maximum number of variables to be used in minterm - calculation. The optimal number should be as close as possible to - the size of the support of f. However, it is safe to pass the value - returned by Cudd_ReadSize for numVars when the number of variables - is under 1023. If numVars is larger than 1023, it will cause - overflow. If a 0 parameter is passed then the procedure will compute - a value which will avoid overflow but will cause underflow with 2046 - variables or more.] + @details This procedure uses a biased remapping technique and + density as the cost function. The bias is a function. This procedure + tries to approximate where the bias is 0 and preserve the given + function where the bias is 1. The parameter numVars is the maximum + number of variables to be used in minterm calculation. The optimal + number should be as close as possible to the size of the support of + f. However, it is safe to pass the value returned by Cudd_ReadSize + for numVars when the number of variables is under 1023. If numVars + is larger than 1023, it will cause overflow. If a 0 parameter is + passed then the procedure will compute a value which will avoid + overflow but will cause underflow with 2046 variables or more. - SideEffects [None] + @return a pointer to the %BDD of the subset if successful. NULL if + the procedure runs out of memory. + + @sideeffect None - SeeAlso [Cudd_SubsetShortPaths Cudd_SubsetHeavyBranch Cudd_UnderApprox - Cudd_RemapUnderApprox Cudd_ReadSize] + @see Cudd_SubsetShortPaths Cudd_SubsetHeavyBranch Cudd_UnderApprox + Cudd_RemapUnderApprox Cudd_ReadSize -******************************************************************************/ +*/ DdNode * Cudd_BiasedUnderApprox( - DdManager *dd /* manager */, - DdNode *f /* function to be subset */, - DdNode *b /* bias function */, - int numVars /* number of variables in the support of f */, - int threshold /* when to stop approximation */, - double quality1 /* minimum improvement for accepted changes when b=1 */, - double quality0 /* minimum improvement for accepted changes when b=0 */) + DdManager *dd /**< manager */, + DdNode *f /**< function to be subset */, + DdNode *b /**< bias function */, + int numVars /**< number of variables in the support of f */, + int threshold /**< when to stop approximation */, + double quality1 /**< minimum improvement for accepted changes when b=1 */, + double quality0 /**< minimum improvement for accepted changes when b=0 */) { DdNode *subset; @@ -418,48 +404,50 @@ Cudd_BiasedUnderApprox( subset = cuddBiasedUnderApprox(dd, f, b, numVars, threshold, quality1, quality0); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(subset); } /* end of Cudd_BiasedUnderApprox */ -/**Function******************************************************************** - - Synopsis [Extracts a dense superset from a BDD with the biased - underapproximation method.] +/** + @brief Extracts a dense superset from a %BDD with the biased + underapproximation method. - Description [Extracts a dense superset from a BDD. The procedure is - identical to the underapproximation procedure except for the fact that it - works on the complement of the given function. Extracting the subset - of the complement function is equivalent to extracting the superset - of the function. - Returns a pointer to the BDD of the superset if successful. NULL if - intermediate result causes the procedure to run out of memory. The + @details The procedure is identical to the underapproximation + procedure except for the fact that it works on the complement of the + given function. Extracting the subset of the complement function is + equivalent to extracting the superset of the function. The parameter numVars is the maximum number of variables to be used in - minterm calculation. The optimal number - should be as close as possible to the size of the support of f. - However, it is safe to pass the value returned by Cudd_ReadSize for - numVars when the number of variables is under 1023. If numVars is - larger than 1023, it will overflow. If a 0 parameter is passed then - the procedure will compute a value which will avoid overflow but - will cause underflow with 2046 variables or more.] + minterm calculation. The optimal number should be as close as + possible to the size of the support of f. However, it is safe to + pass the value returned by Cudd_ReadSize for numVars when the number + of variables is under 1023. If numVars is larger than 1023, it will + overflow. If a 0 parameter is passed then the procedure will compute + a value which will avoid overflow but will cause underflow with 2046 + variables or more. - SideEffects [None] + @return a pointer to the %BDD of the superset if successful. NULL if + intermediate result causes the procedure to run out of memory. + + @sideeffect None - SeeAlso [Cudd_SupersetHeavyBranch Cudd_SupersetShortPaths - Cudd_RemapOverApprox Cudd_BiasedUnderApprox Cudd_ReadSize] + @see Cudd_SupersetHeavyBranch Cudd_SupersetShortPaths + Cudd_RemapOverApprox Cudd_BiasedUnderApprox Cudd_ReadSize -******************************************************************************/ +*/ DdNode * Cudd_BiasedOverApprox( - DdManager *dd /* manager */, - DdNode *f /* function to be superset */, - DdNode *b /* bias function */, - int numVars /* number of variables in the support of f */, - int threshold /* when to stop approximation */, - double quality1 /* minimum improvement for accepted changes when b=1*/, - double quality0 /* minimum improvement for accepted changes when b=0 */) + DdManager *dd /**< manager */, + DdNode *f /**< function to be superset */, + DdNode *b /**< bias function */, + int numVars /**< number of variables in the support of f */, + int threshold /**< when to stop approximation */, + double quality1 /**< minimum improvement for accepted changes when b=1*/, + double quality0 /**< minimum improvement for accepted changes when b=0 */) { DdNode *subset, *g; @@ -469,7 +457,10 @@ Cudd_BiasedOverApprox( subset = cuddBiasedUnderApprox(dd, g, b, numVars, threshold, quality1, quality0); } while (dd->reordered == 1); - + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(Cudd_NotCond(subset, (subset != NULL))); } /* end of Cudd_BiasedOverApprox */ @@ -480,33 +471,32 @@ Cudd_BiasedOverApprox( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Applies Tom Shiple's underappoximation algorithm. - Synopsis [Applies Tom Shiple's underappoximation algorithm.] - - Description [Applies Tom Shiple's underappoximation algorithm. Proceeds - in three phases: + @details Proceeds in three phases: <ul> - <li> collect information on each node in the BDD; this is done via DFS. - <li> traverse the BDD in top-down fashion and compute for each node + <li> collect information on each node in the %BDD; this is done via DFS. + <li> traverse the %BDD in top-down fashion and compute for each node whether its elimination increases density. - <li> traverse the BDD via DFS and actually perform the elimination. + <li> traverse the %BDD via DFS and actually perform the elimination. </ul> - Returns the approximated BDD if successful; NULL otherwise.] - SideEffects [None] + @return the approximated %BDD if successful; NULL otherwise. + + @sideeffect None - SeeAlso [Cudd_UnderApprox] + @see Cudd_UnderApprox -******************************************************************************/ +*/ DdNode * cuddUnderApprox( - DdManager * dd /* DD manager */, - DdNode * f /* current DD */, - int numVars /* maximum number of variables */, - int threshold /* threshold under which approximation stops */, - int safe /* enforce safe approximation */, - double quality /* minimum improvement for accepted changes */) + DdManager * dd /**< %DD manager */, + DdNode * f /**< current %DD */, + int numVars /**< maximum number of variables */, + int threshold /**< threshold under which approximation stops */, + int safe /**< enforce safe approximation */, + double quality /**< minimum improvement for accepted changes */) { ApproxInfo *info; DdNode *subset; @@ -517,7 +507,7 @@ cuddUnderApprox( return(NULL); } - if (Cudd_IsConstant(f)) { + if (Cudd_IsConstantInt(f)) { return(f); } @@ -570,32 +560,31 @@ cuddUnderApprox( } /* end of cuddUnderApprox */ -/**Function******************************************************************** - - Synopsis [Applies the remapping underappoximation algorithm.] +/** + @brief Applies the remapping underappoximation algorithm. - Description [Applies the remapping underappoximation algorithm. - Proceeds in three phases: + @details Proceeds in three phases: <ul> - <li> collect information on each node in the BDD; this is done via DFS. - <li> traverse the BDD in top-down fashion and compute for each node + <li> collect information on each node in the %BDD; this is done via DFS. + <li> traverse the %BDD in top-down fashion and compute for each node whether remapping increases density. - <li> traverse the BDD via DFS and actually perform the elimination. + <li> traverse the %BDD via DFS and actually perform the elimination. </ul> - Returns the approximated BDD if successful; NULL otherwise.] - SideEffects [None] + @return the approximated %BDD if successful; NULL otherwise. - SeeAlso [Cudd_RemapUnderApprox] + @sideeffect None -******************************************************************************/ + @see Cudd_RemapUnderApprox + +*/ DdNode * cuddRemapUnderApprox( - DdManager * dd /* DD manager */, - DdNode * f /* current DD */, - int numVars /* maximum number of variables */, - int threshold /* threshold under which approximation stops */, - double quality /* minimum improvement for accepted changes */) + DdManager * dd /**< %DD manager */, + DdNode * f /**< current %DD */, + int numVars /**< maximum number of variables */, + int threshold /**< threshold under which approximation stops */, + double quality /**< minimum improvement for accepted changes */) { ApproxInfo *info; DdNode *subset; @@ -607,7 +596,7 @@ cuddRemapUnderApprox( return(NULL); } - if (Cudd_IsConstant(f)) { + if (Cudd_IsConstantInt(f)) { return(f); } @@ -660,34 +649,33 @@ cuddRemapUnderApprox( } /* end of cuddRemapUnderApprox */ -/**Function******************************************************************** - - Synopsis [Applies the biased remapping underappoximation algorithm.] +/** + @brief Applies the biased remapping underappoximation algorithm. - Description [Applies the biased remapping underappoximation algorithm. - Proceeds in three phases: + @details Proceeds in three phases: <ul> - <li> collect information on each node in the BDD; this is done via DFS. - <li> traverse the BDD in top-down fashion and compute for each node + <li> collect information on each node in the %BDD; this is done via DFS. + <li> traverse the %BDD in top-down fashion and compute for each node whether remapping increases density. - <li> traverse the BDD via DFS and actually perform the elimination. + <li> traverse the %BDD via DFS and actually perform the elimination. </ul> - Returns the approximated BDD if successful; NULL otherwise.] - SideEffects [None] + @return the approximated %BDD if successful; NULL otherwise. + + @sideeffect None - SeeAlso [Cudd_BiasedUnderApprox] + @see Cudd_BiasedUnderApprox -******************************************************************************/ +*/ DdNode * cuddBiasedUnderApprox( - DdManager *dd /* DD manager */, - DdNode *f /* current DD */, - DdNode *b /* bias function */, - int numVars /* maximum number of variables */, - int threshold /* threshold under which approximation stops */, - double quality1 /* minimum improvement for accepted changes when b=1 */, - double quality0 /* minimum improvement for accepted changes when b=0 */) + DdManager *dd /**< %DD manager */, + DdNode *f /**< current %DD */, + DdNode *b /**< bias function */, + int numVars /**< maximum number of variables */, + int threshold /**< threshold under which approximation stops */, + double quality1 /**< minimum improvement for accepted changes when b=1 */, + double quality0 /**< minimum improvement for accepted changes when b=0 */) { ApproxInfo *info; DdNode *subset; @@ -700,7 +688,7 @@ cuddBiasedUnderApprox( return(NULL); } - if (Cudd_IsConstant(f)) { + if (Cudd_IsConstantInt(f)) { return(f); } @@ -771,23 +759,21 @@ cuddBiasedUnderApprox( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Recursively update the parity of the paths reaching a node. - Synopsis [Recursively update the parity of the paths reaching a node.] + @details Assumes that node is regular and propagates the invariant. - Description [Recursively update the parity of the paths reaching a node. - Assumes that node is regular and propagates the invariant.] + @sideeffect None - SideEffects [None] + @see gatherInfoAux - SeeAlso [gatherInfoAux] - -******************************************************************************/ +*/ static void updateParity( - DdNode * node /* function to analyze */, - ApproxInfo * info /* info on BDD */, - int newparity /* new parity for node */) + DdNode * node /**< function to analyze */, + ApproxInfo * info /**< info on %BDD */, + int newparity /**< new parity for node */) { NodeData *infoN; DdNode *E; @@ -796,7 +782,7 @@ updateParity( return; if ((infoN->parity & newparity) != 0) return; infoN->parity |= (short) newparity; - if (Cudd_IsConstant(node)) return; + if (Cudd_IsConstantInt(node)) return; updateParity(cuddT(node),info,newparity); E = cuddE(node); if (Cudd_IsComplement(E)) { @@ -809,28 +795,25 @@ updateParity( } /* end of updateParity */ -/**Function******************************************************************** - - Synopsis [Recursively counts minterms and computes reference counts - of each node in the BDD.] +/** + @brief Recursively counts minterms and computes reference counts + of each node in the %BDD. - Description [Recursively counts minterms and computes reference - counts of each node in the BDD. Similar to the cuddCountMintermAux - which recursively counts the number of minterms for the dag rooted - at each node in terms of the total number of variables (max). It assumes - that the node pointer passed to it is regular and it maintains the - invariant.] + @details Similar to the cuddCountMintermAux which recursively counts + the number of minterms for the dag rooted at each node in terms of + the total number of variables (max). It assumes that the node + pointer passed to it is regular and it maintains the invariant. - SideEffects [None] + @sideeffect None - SeeAlso [gatherInfo] + @see gatherInfo -******************************************************************************/ +*/ static NodeData * gatherInfoAux( - DdNode * node /* function to analyze */, - ApproxInfo * info /* info on BDD */, - int parity /* gather parity information */) + DdNode * node /**< function to analyze */, + ApproxInfo * info /**< info on %BDD */, + int parity /**< gather parity information */) { DdNode *N, *Nt, *Ne; NodeData *infoN, *infoT, *infoE; @@ -881,21 +864,22 @@ gatherInfoAux( } /* end of gatherInfoAux */ -/**Function******************************************************************** +/** + @brief Gathers information about each node. - Synopsis [Gathers information about each node.] - - Description [Counts minterms and computes reference counts of each - node in the BDD. The minterm count is separately computed for the + @details Counts minterms and computes reference counts of each + node in the %BDD. The minterm count is separately computed for the node and its complement. This is to avoid cancellation - errors. Returns a pointer to the data structure holding the - information gathered if successful; NULL otherwise.] + errors. + + @return a pointer to the data structure holding the information + gathered if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddUnderApprox gatherInfoAux] + @see cuddUnderApprox gatherInfoAux -******************************************************************************/ +*/ static ApproxInfo * gatherInfo( DdManager * dd /* manager */, @@ -948,8 +932,8 @@ gatherInfo( /* Info for the constant node: Initialize only fields different from 0. */ if (cuddHashTableGenericInsert(info->table, info->one, info->page) == 0) { FREE(info->page); - FREE(info); cuddHashTableGenericQuit(info->table); + FREE(info); return(NULL); } info->page[0].mintermsP = info->max; @@ -974,22 +958,22 @@ gatherInfo( } /* end of gatherInfo */ -/**Function******************************************************************** +/** + @brief Counts the nodes that would be eliminated if a given node + were replaced by zero. - Synopsis [Counts the nodes that would be eliminated if a given node - were replaced by zero.] + @details This procedure uses a queue passed by the caller for + efficiency: since the queue is left empty at the endof the search, + it can be reused as is by the next search. - Description [Counts the nodes that would be eliminated if a given - node were replaced by zero. This procedure uses a queue passed by - the caller for efficiency: since the queue is left empty at the - endof the search, it can be reused as is by the next search. Returns - the count (always striclty positive) if successful; 0 otherwise.] + @return the count (always striclty positive) if successful; 0 + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [UAmarkNodes RAmarkNodes BAmarkNodes] + @see UAmarkNodes RAmarkNodes BAmarkNodes -******************************************************************************/ +*/ static int computeSavings( DdManager * dd, @@ -1004,6 +988,7 @@ computeSavings( int savings = 0; node = Cudd_Regular(f); + if (node == NULL) return(0); skip = Cudd_Regular(skip); /* Insert the given node in the level queue. Its local reference ** count is set equal to the function reference count so that the @@ -1052,18 +1037,16 @@ computeSavings( } /* end of computeSavings */ -/**Function******************************************************************** - - Synopsis [Update function reference counts.] +/** + @brief Update function reference counts to account for replacement. - Description [Update function reference counts to account for replacement. - Returns the number of nodes saved if successful; 0 otherwise.] + @return the number of nodes saved if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [UAmarkNodes RAmarkNodes BAmarkNodes] + @see UAmarkNodes RAmarkNodes BAmarkNodes -******************************************************************************/ +*/ static int updateRefs( DdManager * dd, @@ -1132,26 +1115,24 @@ updateRefs( } /* end of updateRefs */ -/**Function******************************************************************** +/** + @brief Marks nodes for replacement by zero. - Synopsis [Marks nodes for replacement by zero.] + @return 1 if successful; 0 otherwise. - Description [Marks nodes for replacement by zero. Returns 1 if successful; - 0 otherwise.] + @sideeffect None - SideEffects [None] + @see cuddUnderApprox - SeeAlso [cuddUnderApprox] - -******************************************************************************/ +*/ static int UAmarkNodes( - DdManager * dd /* manager */, - DdNode * f /* function to be analyzed */, - ApproxInfo * info /* info on BDD */, - int threshold /* when to stop approximating */, - int safe /* enforce safe approximation */, - double quality /* minimum improvement for accepted changes */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be analyzed */, + ApproxInfo * info /**< info on %BDD */, + int threshold /**< when to stop approximating */, + int safe /**< enforce safe approximation */, + double quality /**< minimum improvement for accepted changes */) { DdLevelQueue *queue; DdLevelQueue *localQueue; @@ -1166,12 +1147,12 @@ UAmarkNodes( (void) printf("initial size = %d initial minterms = %g\n", info->size, info->minterms); #endif - queue = cuddLevelQueueInit(dd->size,sizeof(GlobalQueueItem),info->size); + queue = cuddLevelQueueInit(dd->size,sizeof(GlobalQueueItem),info->size,dd); if (queue == NULL) { return(0); } localQueue = cuddLevelQueueInit(dd->size,sizeof(LocalQueueItem), - dd->initSlots); + dd->initSlots,dd); if (localQueue == NULL) { cuddLevelQueueQuit(queue); return(0); @@ -1235,7 +1216,7 @@ UAmarkNodes( item->impactP += impactP/2.0; item->impactN += impactN/2.0; } - if (!Cudd_IsConstant(cuddE(node))) { + if (!Cudd_IsConstantInt(cuddE(node))) { item = (GlobalQueueItem *) cuddLevelQueueEnqueue(queue,Cudd_Regular(cuddE(node)), cuddI(dd,Cudd_Regular(cuddE(node))->index)); if (Cudd_IsComplement(cuddE(node))) { @@ -1255,30 +1236,29 @@ UAmarkNodes( } /* end of UAmarkNodes */ -/**Function******************************************************************** +/** + @brief Builds the subset %BDD. - Synopsis [Builds the subset BDD.] + @details Based on the info table, replaces selected nodes by zero. - Description [Builds the subset BDD. Based on the info table, - replaces selected nodes by zero. Returns a pointer to the result if - successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddUnderApprox] + @see cuddUnderApprox -******************************************************************************/ +*/ static DdNode * UAbuildSubset( - DdManager * dd /* DD manager */, - DdNode * node /* current node */, - ApproxInfo * info /* node info */) + DdManager * dd /**< %DD manager */, + DdNode * node /**< current node */, + ApproxInfo * info /**< node info */) { DdNode *Nt, *Ne, *N, *t, *e, *r; NodeData *infoN; - if (Cudd_IsConstant(node)) + if (Cudd_IsConstantInt(node)) return(node); N = Cudd_Regular(node); @@ -1351,25 +1331,23 @@ UAbuildSubset( } /* end of UAbuildSubset */ -/**Function******************************************************************** +/** + @brief Marks nodes for remapping. - Synopsis [Marks nodes for remapping.] + @return 1 if successful; 0 otherwise. - Description [Marks nodes for remapping. Returns 1 if successful; 0 - otherwise.] + @sideeffect None - SideEffects [None] + @see cuddRemapUnderApprox - SeeAlso [cuddRemapUnderApprox] - -******************************************************************************/ +*/ static int RAmarkNodes( - DdManager * dd /* manager */, - DdNode * f /* function to be analyzed */, - ApproxInfo * info /* info on BDD */, - int threshold /* when to stop approximating */, - double quality /* minimum improvement for accepted changes */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be analyzed */, + ApproxInfo * info /**< info on %BDD */, + int threshold /**< when to stop approximating */, + double quality /**< minimum improvement for accepted changes */) { DdLevelQueue *queue; DdLevelQueue *localQueue; @@ -1387,12 +1365,12 @@ RAmarkNodes( (void) fprintf(dd->out,"initial size = %d initial minterms = %g\n", info->size, info->minterms); #endif - queue = cuddLevelQueueInit(dd->size,sizeof(GlobalQueueItem),info->size); + queue = cuddLevelQueueInit(dd->size,sizeof(GlobalQueueItem),info->size,dd); if (queue == NULL) { return(0); } localQueue = cuddLevelQueueInit(dd->size,sizeof(LocalQueueItem), - dd->initSlots); + dd->initSlots,dd); if (localQueue == NULL) { cuddLevelQueueQuit(queue); return(0); @@ -1426,7 +1404,7 @@ RAmarkNodes( assert(item->impactP >= 0 && item->impactP <= 1.0); assert(item->impactN >= 0 && item->impactN <= 1.0); assert(!Cudd_IsComplement(node)); - assert(!Cudd_IsConstant(node)); + assert(!Cudd_IsConstantInt(node)); #endif if ((infoN = (NodeData *) cuddHashTableGenericLookup(info->table, node)) == NULL) { cuddLevelQueueQuit(queue); @@ -1610,7 +1588,7 @@ RAmarkNodes( } } if ((replace == REPLACE_T || replace == NOTHING) && - !Cudd_IsConstant(cuddE(node))) { + !Cudd_IsConstantInt(cuddE(node))) { item = (GlobalQueueItem *) cuddLevelQueueEnqueue(queue,Cudd_Regular(cuddE(node)), cuddI(dd,Cudd_Regular(cuddE(node))->index)); if (Cudd_IsComplement(cuddE(node))) { @@ -1632,7 +1610,7 @@ RAmarkNodes( } } if ((replace == REPLACE_TT || replace == REPLACE_TE) && - !Cudd_IsConstant(shared)) { + !Cudd_IsConstantInt(shared)) { item = (GlobalQueueItem *) cuddLevelQueueEnqueue(queue,Cudd_Regular(shared), cuddI(dd,Cudd_Regular(shared)->index)); if (Cudd_IsComplement(shared)) { @@ -1652,26 +1630,24 @@ RAmarkNodes( } /* end of RAmarkNodes */ -/**Function******************************************************************** - - Synopsis [Marks nodes for remapping.] +/** + @brief Marks nodes for remapping. - Description [Marks nodes for remapping. Returns 1 if successful; 0 - otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddBiasedUnderApprox] + @see cuddBiasedUnderApprox -******************************************************************************/ +*/ static int BAmarkNodes( - DdManager *dd /* manager */, - DdNode *f /* function to be analyzed */, - ApproxInfo *info /* info on BDD */, - int threshold /* when to stop approximating */, - double quality1 /* minimum improvement for accepted changes when b=1 */, - double quality0 /* minimum improvement for accepted changes when b=0 */) + DdManager *dd /**< manager */, + DdNode *f /**< function to be analyzed */, + ApproxInfo *info /**< info on %BDD */, + int threshold /**< when to stop approximating */, + double quality1 /**< minimum improvement for accepted changes when b=1 */, + double quality0 /**< minimum improvement for accepted changes when b=0 */) { DdLevelQueue *queue; DdLevelQueue *localQueue; @@ -1690,12 +1666,12 @@ BAmarkNodes( (void) fprintf(dd->out,"initial size = %d initial minterms = %g\n", info->size, info->minterms); #endif - queue = cuddLevelQueueInit(dd->size,sizeof(GlobalQueueItem),info->size); + queue = cuddLevelQueueInit(dd->size,sizeof(GlobalQueueItem),info->size,dd); if (queue == NULL) { return(0); } localQueue = cuddLevelQueueInit(dd->size,sizeof(LocalQueueItem), - dd->initSlots); + dd->initSlots,dd); if (localQueue == NULL) { cuddLevelQueueQuit(queue); return(0); @@ -1730,7 +1706,7 @@ BAmarkNodes( assert(item->impactP >= 0 && item->impactP <= 1.0); assert(item->impactN >= 0 && item->impactN <= 1.0); assert(!Cudd_IsComplement(node)); - assert(!Cudd_IsConstant(node)); + assert(!Cudd_IsConstantInt(node)); #endif if ((infoN = (NodeData *) cuddHashTableGenericLookup(info->table, node)) == NULL) { cuddLevelQueueQuit(queue); @@ -1764,7 +1740,7 @@ BAmarkNodes( if (infoN->parity == 1) { impact = impactP; minterms = infoE->mintermsP/2.0 - infoT->mintermsP/2.0; - if (infoE->functionRef == 1 && !Cudd_IsConstant(E)) { + if (infoE->functionRef == 1 && !Cudd_IsConstantInt(E)) { savings = 1 + computeSavings(dd,E,NULL,info,localQueue); if (savings == 1) { cuddLevelQueueQuit(queue); @@ -1781,7 +1757,7 @@ BAmarkNodes( #endif impact = impactN; minterms = infoT->mintermsN/2.0 - infoE->mintermsN/2.0; - if (infoT->functionRef == 1 && !Cudd_IsConstant(T)) { + if (infoT->functionRef == 1 && !Cudd_IsConstantInt(T)) { savings = 1 + computeSavings(dd,T,NULL,info,localQueue); if (savings == 1) { cuddLevelQueueQuit(queue); @@ -1803,7 +1779,7 @@ BAmarkNodes( impact = impactP; minterms = infoT->mintermsP/2.0 - ((E == Ereg) ? infoE->mintermsP : infoE->mintermsN)/2.0; - if (infoT->functionRef == 1 && !Cudd_IsConstant(T)) { + if (infoT->functionRef == 1 && !Cudd_IsConstantInt(T)) { savings = 1 + computeSavings(dd,T,NULL,info,localQueue); if (savings == 1) { cuddLevelQueueQuit(queue); @@ -1821,7 +1797,7 @@ BAmarkNodes( impact = impactN; minterms = ((E == Ereg) ? infoE->mintermsN : infoE->mintermsP)/2.0 - infoT->mintermsN/2.0; - if (infoE->functionRef == 1 && !Cudd_IsConstant(E)) { + if (infoE->functionRef == 1 && !Cudd_IsConstantInt(E)) { savings = 1 + computeSavings(dd,E,NULL,info,localQueue); if (savings == 1) { cuddLevelQueueQuit(queue); @@ -1915,7 +1891,7 @@ BAmarkNodes( } } if ((replace == REPLACE_T || replace == NOTHING) && - !Cudd_IsConstant(cuddE(node))) { + !Cudd_IsConstantInt(cuddE(node))) { item = (GlobalQueueItem *) cuddLevelQueueEnqueue(queue,Cudd_Regular(cuddE(node)), cuddI(dd,Cudd_Regular(cuddE(node))->index)); if (Cudd_IsComplement(cuddE(node))) { @@ -1937,7 +1913,7 @@ BAmarkNodes( } } if ((replace == REPLACE_TT || replace == REPLACE_TE) && - !Cudd_IsConstant(shared)) { + !Cudd_IsConstantInt(shared)) { item = (GlobalQueueItem *) cuddLevelQueueEnqueue(queue,Cudd_Regular(shared), cuddI(dd,Cudd_Regular(shared)->index)); if (Cudd_IsComplement(shared)) { @@ -1967,30 +1943,29 @@ BAmarkNodes( } /* end of BAmarkNodes */ -/**Function******************************************************************** +/** + @brief Builds the subset %BDD for cuddRemapUnderApprox. - Synopsis [Builds the subset BDD for cuddRemapUnderApprox.] + @details Based on the info table, performs remapping or replacement + at selected nodes. - Description [Builds the subset BDDfor cuddRemapUnderApprox. Based - on the info table, performs remapping or replacement at selected - nodes. Returns a pointer to the result if successful; NULL - otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddRemapUnderApprox] + @see cuddRemapUnderApprox -******************************************************************************/ +*/ static DdNode * RAbuildSubset( - DdManager * dd /* DD manager */, - DdNode * node /* current node */, - ApproxInfo * info /* node info */) + DdManager * dd /**< %DD manager */, + DdNode * node /**< current node */, + ApproxInfo * info /**< node info */) { DdNode *Nt, *Ne, *N, *t, *e, *r; NodeData *infoN; - if (Cudd_IsConstant(node)) + if (Cudd_IsConstantInt(node)) return(node); N = Cudd_Regular(node); @@ -2047,7 +2022,7 @@ RAbuildSubset( } else if (infoN->replace == REPLACE_TE) { DdNode *Nte = Cudd_NotCond(cuddE(cuddT(N)), Cudd_IsComplement(node)); - int index = cuddT(N)->index; + unsigned int index = cuddT(N)->index; t = info->one; e = RAbuildSubset(dd, Nte, info); if (e == NULL) { @@ -2116,19 +2091,17 @@ RAbuildSubset( } /* end of RAbuildSubset */ -/**Function******************************************************************** - - Synopsis [Finds don't care nodes.] +/** + @brief Finds don't care nodes by traversing f and b in parallel. - Description [Finds don't care nodes by traversing f and b in parallel. - Returns the care status of the visited f node if successful; CARE_ERROR - otherwise.] + @return the care status of the visited f node if successful; + CARE_ERROR otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddBiasedUnderApprox] + @see cuddBiasedUnderApprox -******************************************************************************/ +*/ static int BAapplyBias( DdManager *dd, @@ -2139,7 +2112,7 @@ BAapplyBias( { DdNode *one, *zero, *res; DdNode *Ft, *Fe, *B, *Bt, *Be; - unsigned int topf, topb; + int topf, topb; NodeData *infoF; int careT, careE; diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddBddAbs.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddBddAbs.c similarity index 72% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddBddAbs.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddBddAbs.c index a806078c5..62170e3b2 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddBddAbs.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddBddAbs.c @@ -1,35 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddBddAbs.c] - - PackageName [cudd] - - Synopsis [Quantification functions for BDDs.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_bddExistAbstract() - <li> Cudd_bddExistAbstractLimit() - <li> Cudd_bddXorExistAbstract() - <li> Cudd_bddUnivAbstract() - <li> Cudd_bddBooleanDiff() - <li> Cudd_bddVarIsDependent() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddExistAbstractRecur() - <li> cuddBddXorExistAbstractRecur() - <li> cuddBddBooleanDiffRecur() - </ul> - Static procedures included in this module: - <ul> - <li> bddCheckPositiveCube() - </ul> - ] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Quantification functions for BDDs. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -59,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -86,16 +66,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddBddAbs.c,v 1.28 2012/02/05 01:07:18 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -103,7 +79,7 @@ static char rcsid[] DD_UNUSED = "$Id: cuddBddAbs.c,v 1.28 2012/02/05 01:07:18 fa static int bddCheckPositiveCube (DdManager *manager, DdNode *cube); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -111,18 +87,16 @@ static int bddCheckPositiveCube (DdManager *manager, DdNode *cube); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Existentially abstracts all the variables in cube from f.] +/** + @brief Existentially abstracts all the variables in cube from f. - Description [Existentially abstracts all the variables in cube from f. - Returns the abstracted BDD if successful; NULL otherwise.] + @return the abstracted %BDD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddUnivAbstract Cudd_addExistAbstract] + @see Cudd_bddUnivAbstract Cudd_addExistAbstract -******************************************************************************/ +*/ DdNode * Cudd_bddExistAbstract( DdManager * manager, @@ -142,26 +116,27 @@ Cudd_bddExistAbstract( manager->reordered = 0; res = cuddBddExistAbstractRecur(manager, f, cube); } while (manager->reordered == 1); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_bddExistAbstract */ -/**Function******************************************************************** - - Synopsis [Existentially abstracts all the variables in cube from f.] +/** + @brief Existentially abstracts all the variables in cube from f. - Description [Existentially abstracts all the variables in cube from f. - Returns the abstracted BDD if successful; NULL if the intermediate + @return the abstracted %BDD if successful; NULL if the intermediate result blows up or more new nodes than <code>limit</code> are - required.] + required. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddExistAbstract] + @see Cudd_bddExistAbstract -******************************************************************************/ +*/ DdNode * Cudd_bddExistAbstractLimit( DdManager * manager, @@ -186,26 +161,28 @@ Cudd_bddExistAbstractLimit( res = cuddBddExistAbstractRecur(manager, f, cube); } while (manager->reordered == 1); manager->maxLive = saveLimit; + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_bddExistAbstractLimit */ -/**Function******************************************************************** +/** + @brief Takes the exclusive OR of two BDDs and simultaneously abstracts the + variables in cube. - Synopsis [Takes the exclusive OR of two BDDs and simultaneously abstracts the - variables in cube.] + @details The variables are existentially abstracted. - Description [Takes the exclusive OR of two BDDs and simultaneously abstracts - the variables in cube. The variables are existentially abstracted. Returns a - pointer to the result is successful; NULL otherwise.] + @return a pointer to the result is successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddUnivAbstract Cudd_bddExistAbstract Cudd_bddAndAbstract] + @see Cudd_bddUnivAbstract Cudd_bddExistAbstract Cudd_bddAndAbstract -******************************************************************************/ +*/ DdNode * Cudd_bddXorExistAbstract( DdManager * manager, @@ -226,24 +203,25 @@ Cudd_bddXorExistAbstract( manager->reordered = 0; res = cuddBddXorExistAbstractRecur(manager, f, g, cube); } while (manager->reordered == 1); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_bddXorExistAbstract */ -/**Function******************************************************************** - - Synopsis [Universally abstracts all the variables in cube from f.] +/** + @brief Universally abstracts all the variables in cube from f. - Description [Universally abstracts all the variables in cube from f. - Returns the abstracted BDD if successful; NULL otherwise.] + @return the abstracted %BDD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddExistAbstract Cudd_addUnivAbstract] + @see Cudd_bddExistAbstract Cudd_addUnivAbstract -******************************************************************************/ +*/ DdNode * Cudd_bddUnivAbstract( DdManager * manager, @@ -264,25 +242,27 @@ Cudd_bddUnivAbstract( res = cuddBddExistAbstractRecur(manager, Cudd_Not(f), cube); } while (manager->reordered == 1); if (res != NULL) res = Cudd_Not(res); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_bddUnivAbstract */ -/**Function******************************************************************** - - Synopsis [Computes the boolean difference of f with respect to x.] +/** + @brief Computes the boolean difference of f with respect to x. - Description [Computes the boolean difference of f with respect to the - variable with index x. Returns the BDD of the boolean difference if - successful; NULL otherwise.] + @details Computes the boolean difference of f with respect to the + variable with index x. - SideEffects [None] + @return the %BDD of the boolean difference if successful; NULL + otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * Cudd_bddBooleanDiff( DdManager * manager, @@ -301,31 +281,31 @@ Cudd_bddBooleanDiff( manager->reordered = 0; res = cuddBddBooleanDiffRecur(manager, Cudd_Regular(f), var); } while (manager->reordered == 1); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_bddBooleanDiff */ -/**Function******************************************************************** +/** + @brief Checks whether a variable is dependent on others in a + function. - Synopsis [Checks whether a variable is dependent on others in a - function.] + @details No new nodes are created. - Description [Checks whether a variable is dependent on others in a - function. Returns 1 if the variable is dependent; 0 otherwise. No - new nodes are created.] + @return 1 if the variable is dependent; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int Cudd_bddVarIsDependent( - DdManager *dd, /* manager */ - DdNode *f, /* function */ - DdNode *var /* variable */) + DdManager *dd, /**< manager */ + DdNode *f, /**< function */ + DdNode *var /**< variable */) { DdNode *F, *res, *zero, *ft, *fe; unsigned topf, level; @@ -333,10 +313,10 @@ Cudd_bddVarIsDependent( int retval; zero = Cudd_Not(DD_ONE(dd)); - if (Cudd_IsConstant(f)) return(f == zero); + F = Cudd_Regular(f); + if (cuddIsConstant(F)) return(f == zero); /* From now on f is not constant. */ - F = Cudd_Regular(f); topf = (unsigned) dd->perm[F->index]; level = (unsigned) dd->perm[var->index]; @@ -375,20 +355,19 @@ Cudd_bddVarIsDependent( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive steps of Cudd_bddExistAbstract. - Synopsis [Performs the recursive steps of Cudd_bddExistAbstract.] + @details It is also used by Cudd_bddUnivAbstract. - Description [Performs the recursive steps of Cudd_bddExistAbstract. - Returns the BDD obtained by abstracting the variables - of cube from f if successful; NULL otherwise. It is also used by - Cudd_bddUnivAbstract.] + @return the %BDD obtained by abstracting the variables of cube from f + if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddExistAbstract Cudd_bddUnivAbstract] + @see Cudd_bddExistAbstract Cudd_bddUnivAbstract -******************************************************************************/ +*/ DdNode * cuddBddExistAbstractRecur( DdManager * manager, @@ -418,6 +397,8 @@ cuddBddExistAbstractRecur( return(res); } + checkWhetherToGiveUp(manager); + /* Compute the cofactors of f. */ T = cuddT(F); E = cuddE(F); if (f != F) { @@ -485,20 +466,19 @@ cuddBddExistAbstractRecur( } /* end of cuddBddExistAbstractRecur */ -/**Function******************************************************************** +/** + @brief Takes the exclusive OR of two BDDs and simultaneously abstracts the + variables in cube. - Synopsis [Takes the exclusive OR of two BDDs and simultaneously abstracts the - variables in cube.] + @details The variables are existentially abstracted. - Description [Takes the exclusive OR of two BDDs and simultaneously abstracts - the variables in cube. The variables are existentially abstracted. Returns a - pointer to the result is successful; NULL otherwise.] + @return a pointer to the result is successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddAndAbstract] + @see Cudd_bddAndAbstract -******************************************************************************/ +*/ DdNode * cuddBddXorExistAbstractRecur( DdManager * manager, @@ -508,7 +488,8 @@ cuddBddXorExistAbstractRecur( { DdNode *F, *fv, *fnv, *G, *gv, *gnv; DdNode *one, *zero, *r, *t, *e, *Cube; - unsigned int topf, topg, topcube, top, index; + int topf, topg, topcube, top; + unsigned int index; statLine(manager); one = DD_ONE(manager); @@ -551,6 +532,8 @@ cuddBddXorExistAbstractRecur( return(r); } + checkWhetherToGiveUp(manager); + /* Here we can skip the use of cuddI, because the operands are known ** to be non-constant. */ @@ -657,20 +640,17 @@ cuddBddXorExistAbstractRecur( } /* end of cuddBddXorExistAbstractRecur */ -/**Function******************************************************************** +/** + @brief Performs the recursive steps of Cudd_bddBoleanDiff. - Synopsis [Performs the recursive steps of Cudd_bddBoleanDiff.] + @details Exploits the fact that dF/dx = dF'/dx. - Description [Performs the recursive steps of Cudd_bddBoleanDiff. - Returns the BDD obtained by XORing the cofactors of f with respect to - var if successful; NULL otherwise. Exploits the fact that dF/dx = - dF'/dx.] + @return the %BDD obtained by XORing the cofactors of f with respect + to var if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ DdNode * cuddBddBooleanDiffRecur( DdManager * manager, @@ -733,16 +713,15 @@ cuddBddBooleanDiffRecur( /* Definition of static functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Checks whether cube is an BDD representing the product of - positive literals.] +/** + @brief Checks whether cube is a %BDD representing the product of + positive literals. - Description [Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int bddCheckPositiveCube( DdManager * manager, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddBddCorr.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddBddCorr.c similarity index 64% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddBddCorr.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddBddCorr.c index e92d24ad6..efce7dd74 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddBddCorr.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddBddCorr.c @@ -1,29 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddBddCorr.c] + @ingroup cudd - PackageName [cudd] + @brief Correlation between BDDs. - Synopsis [Correlation between BDDs.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_bddCorrelation() - <li> Cudd_bddCorrelationWeights() - </ul> - Static procedures included in this module: - <ul> - <li> bddCorrelationAux() - <li> bddCorrelationWeightsAux() - <li> CorrelCompare() - <li> CorrelHash() - <li> CorrelCleanUp() - </ul> - ] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -53,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -75,6 +61,7 @@ /* Type declarations */ /*---------------------------------------------------------------------------*/ +/** Type of hash-table key. */ typedef struct hashEntry { DdNode *f; DdNode *g; @@ -85,10 +72,6 @@ typedef struct hashEntry { /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddBddCorr.c,v 1.15 2012/02/05 01:07:18 fabio Exp $"; -#endif - #ifdef CORREL_STATS static int num_calls; #endif @@ -97,11 +80,7 @@ static int num_calls; /* Macro declarations */ /*---------------------------------------------------------------------------*/ -#ifdef __cplusplus -extern "C" { -#endif - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -109,43 +88,37 @@ extern "C" { static double bddCorrelationAux (DdManager *dd, DdNode *f, DdNode *g, st_table *table); static double bddCorrelationWeightsAux (DdManager *dd, DdNode *f, DdNode *g, double *prob, st_table *table); -static int CorrelCompare (const char *key1, const char *key2); -static int CorrelHash (char *key, int modulus); -static enum st_retval CorrelCleanUp (char *key, char *value, char *arg); - -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} -#endif +static int CorrelCompare (const void *key1, const void *key2); +static int CorrelHash (void const *key, int modulus); +static enum st_retval CorrelCleanUp (void *key, void *value, void *arg); +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Computes the correlation of f and g. - Synopsis [Computes the correlation of f and g.] + @details If f == g, their correlation is 1. If f == g', their + correlation is 0. - Description [Computes the correlation of f and g. If f == g, their - correlation is 1. If f == g', their correlation is 0. Returns the - fraction of minterms in the ON-set of the EXNOR of f and g. If it - runs out of memory, returns (double)CUDD_OUT_OF_MEM.] + @return the fraction of minterms in the ON-set of the EXNOR of f and + g. If it runs out of memory, returns (double)CUDD_OUT_OF_MEM. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddCorrelationWeights] + @see Cudd_bddCorrelationWeights -******************************************************************************/ +*/ double Cudd_bddCorrelation( DdManager * manager, DdNode * f, DdNode * g) { - st_table *table; double correlation; @@ -156,31 +129,30 @@ Cudd_bddCorrelation( table = st_init_table(CorrelCompare,CorrelHash); if (table == NULL) return((double)CUDD_OUT_OF_MEM); correlation = bddCorrelationAux(manager,f,g,table); - st_foreach(table, CorrelCleanUp, NIL(char)); + st_foreach(table, CorrelCleanUp, NIL(void)); st_free_table(table); return(correlation); } /* end of Cudd_bddCorrelation */ -/**Function******************************************************************** +/** + @brief Computes the correlation of f and g for given input + probabilities. - Synopsis [Computes the correlation of f and g for given input - probabilities.] + @details On input, prob\[i\] is supposed to contain the probability + of the i-th input variable to be 1. If f == g, their correlation is + 1. If f == g', their correlation is 0. The correlation of f and the + constant one gives the probability of f. - Description [Computes the correlation of f and g for given input - probabilities. On input, prob\[i\] is supposed to contain the - probability of the i-th input variable to be 1. - If f == g, their correlation is 1. If f == g', their - correlation is 0. Returns the probability that f and g have the same - value. If it runs out of memory, returns (double)CUDD_OUT_OF_MEM. The - correlation of f and the constant one gives the probability of f.] + @return the probability that f and g have the same value. If it runs + out of memory, returns (double)CUDD_OUT_OF_MEM. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddCorrelation] + @see Cudd_bddCorrelation -******************************************************************************/ +*/ double Cudd_bddCorrelationWeights( DdManager * manager, @@ -188,7 +160,6 @@ Cudd_bddCorrelationWeights( DdNode * g, double * prob) { - st_table *table; double correlation; @@ -199,7 +170,7 @@ Cudd_bddCorrelationWeights( table = st_init_table(CorrelCompare,CorrelHash); if (table == NULL) return((double)CUDD_OUT_OF_MEM); correlation = bddCorrelationWeightsAux(manager,f,g,prob,table); - st_foreach(table, CorrelCleanUp, NIL(char)); + st_foreach(table, CorrelCleanUp, NIL(void)); st_free_table(table); return(correlation); @@ -216,19 +187,17 @@ Cudd_bddCorrelationWeights( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_bddCorrelation.] +/** + @brief Performs the recursive step of Cudd_bddCorrelation. - Description [Performs the recursive step of Cudd_bddCorrelation. - Returns the fraction of minterms in the ON-set of the EXNOR of f and - g.] + @return the fraction of minterms in the ON-set of the EXNOR of f and + g. - SideEffects [None] + @sideeffect None - SeeAlso [bddCorrelationWeightsAux] + @see bddCorrelationWeightsAux -******************************************************************************/ +*/ static double bddCorrelationAux( DdManager * dd, @@ -237,9 +206,10 @@ bddCorrelationAux( st_table * table) { DdNode *Fv, *Fnv, *G, *Gv, *Gnv; - double min, *pmin, min1, min2, *dummy; + double min, *pmin, min1, min2; + void *dummy; HashEntry *entry; - unsigned int topF, topG; + int topF, topG; statLine(dd); #ifdef CORREL_STATS @@ -276,7 +246,7 @@ bddCorrelationAux( ** to minimize the risk of cancellation. */ if (st_lookup(table, entry, &dummy)) { - min = *dummy; + min = *(double *) dummy; FREE(entry); return(min); } @@ -310,7 +280,7 @@ bddCorrelationAux( } *pmin = min; - if (st_insert(table,(char *)entry, (char *)pmin) == ST_OUT_OF_MEM) { + if (st_insert(table, entry, pmin) == ST_OUT_OF_MEM) { FREE(entry); FREE(pmin); return((double)CUDD_OUT_OF_MEM); @@ -320,17 +290,14 @@ bddCorrelationAux( } /* end of bddCorrelationAux */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_bddCorrelationWeigths.] +/** + @brief Performs the recursive step of Cudd_bddCorrelationWeigths. - Description [] + @sideeffect None - SideEffects [None] + @see bddCorrelationAux - SeeAlso [bddCorrelationAux] - -******************************************************************************/ +*/ static double bddCorrelationWeightsAux( DdManager * dd, @@ -340,9 +307,11 @@ bddCorrelationWeightsAux( st_table * table) { DdNode *Fv, *Fnv, *G, *Gv, *Gnv; - double min, *pmin, min1, min2, *dummy; + double min, *pmin, min1, min2; + void *dummy; HashEntry *entry; - int topF, topG, index; + int topF, topG; + unsigned index; statLine(dd); #ifdef CORREL_STATS @@ -379,7 +348,7 @@ bddCorrelationWeightsAux( ** to minimize the risk of cancellation. */ if (st_lookup(table, entry, &dummy)) { - min = *dummy; + min = *(double *) dummy; FREE(entry); return(min); } @@ -419,7 +388,7 @@ bddCorrelationWeightsAux( } *pmin = min; - if (st_insert(table,(char *)entry, (char *)pmin) == ST_OUT_OF_MEM) { + if (st_insert(table, entry, pmin) == ST_OUT_OF_MEM) { FREE(entry); FREE(pmin); return((double)CUDD_OUT_OF_MEM); @@ -429,26 +398,21 @@ bddCorrelationWeightsAux( } /* end of bddCorrelationWeightsAux */ -/**Function******************************************************************** - - Synopsis [Compares two hash table entries.] +/** + @brief Compares two hash table entries. - Description [Compares two hash table entries. Returns 0 if they are - identical; 1 otherwise.] + @return 0 if they are identical; 1 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int CorrelCompare( - const char * key1, - const char * key2) + void const * key1, + void const * key2) { - HashEntry *entry1; - HashEntry *entry2; - - entry1 = (HashEntry *) key1; - entry2 = (HashEntry *) key2; + HashEntry const *entry1 = (HashEntry const *) key1; + HashEntry const *entry2 = (HashEntry const *) key2; if (entry1->f != entry2->f || entry1->g != entry2->g) return(1); return(0); @@ -456,60 +420,51 @@ CorrelCompare( } /* end of CorrelCompare */ -/**Function******************************************************************** +/** + @brief Hashes a hash table entry. - Synopsis [Hashes a hash table entry.] + @details It is patterned after st_strhash. - Description [Hashes a hash table entry. It is patterned after - st_strhash. Returns a value between 0 and modulus.] + @return a value between 0 and modulus. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int CorrelHash( - char * key, + void const * key, int modulus) { - HashEntry *entry; + HashEntry const *entry = (HashEntry const *) key; int val = 0; - entry = (HashEntry *) key; -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 - val = ((int) ((long)entry->f))*997 + ((int) ((long)entry->g)); -#else - val = ((int) entry->f)*997 + ((int) entry->g); -#endif + val = (int) (((ptrint)entry->f)*997 + ((ptrint)entry->g)); return ((val < 0) ? -val : val) % modulus; } /* end of CorrelHash */ -/**Function******************************************************************** +/** + @brief Frees memory associated with hash table. - Synopsis [Frees memory associated with hash table.] + @return ST_CONTINUE. - Description [Frees memory associated with hash table. Returns - ST_CONTINUE.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static enum st_retval CorrelCleanUp( - char * key, - char * value, - char * arg) + void * key, + void * value, + void * arg) { - double *d; - HashEntry *entry; + double *d = (double *) value; + HashEntry *entry = (HashEntry *) key; - entry = (HashEntry *) key; + (void) arg; /* avoid warning */ FREE(entry); - d = (double *)value; FREE(d); return ST_CONTINUE; } /* end of CorrelCleanUp */ - diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddBddIte.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddBddIte.c similarity index 64% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddBddIte.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddBddIte.c index 750a51c74..668dea521 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddBddIte.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddBddIte.c @@ -1,47 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddBddIte.c] - - PackageName [cudd] - - Synopsis [BDD ITE function and satellites.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_bddIte() - <li> Cudd_bddIteLimit() - <li> Cudd_bddIteConstant() - <li> Cudd_bddIntersect() - <li> Cudd_bddAnd() - <li> Cudd_bddAndLimit() - <li> Cudd_bddOr() - <li> Cudd_bddOrLimit() - <li> Cudd_bddNand() - <li> Cudd_bddNor() - <li> Cudd_bddXor() - <li> Cudd_bddXnor() - <li> Cudd_bddXnorLimit() - <li> Cudd_bddLeq() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddIteRecur() - <li> cuddBddIntersectRecur() - <li> cuddBddAndRecur() - <li> cuddBddXorRecur() - </ul> - Static procedures included in this module: - <ul> - <li> bddVarToConst() - <li> bddVarToCanonical() - <li> bddVarToCanonicalSimple() - </ul>] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief %BDD ITE function and satellites. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -71,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -98,26 +66,22 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddBddIte.c,v 1.26 2012/02/05 01:07:18 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ static void bddVarToConst (DdNode *f, DdNode **gp, DdNode **hp, DdNode *one); -static int bddVarToCanonical (DdManager *dd, DdNode **fp, DdNode **gp, DdNode **hp, unsigned int *topfp, unsigned int *topgp, unsigned int *tophp); -static int bddVarToCanonicalSimple (DdManager *dd, DdNode **fp, DdNode **gp, DdNode **hp, unsigned int *topfp, unsigned int *topgp, unsigned int *tophp); +static int bddVarToCanonical (DdManager *dd, DdNode **fp, DdNode **gp, DdNode **hp, int *topfp, int *topgp, int *tophp); +static int bddVarToCanonicalSimple (DdManager *dd, DdNode **fp, DdNode **gp, DdNode **hp, int *topfp, int *topgp, int *tophp); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -125,25 +89,23 @@ static int bddVarToCanonicalSimple (DdManager *dd, DdNode **fp, DdNode **gp, DdN /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Implements ITE(f,g,h).] +/** + @brief Implements ITE(f,g,h). - Description [Implements ITE(f,g,h). Returns a pointer to the - resulting BDD if successful; NULL if the intermediate result blows - up.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addIte Cudd_bddIteConstant Cudd_bddIntersect] + @see Cudd_addIte Cudd_bddIteConstant Cudd_bddIntersect -******************************************************************************/ +*/ DdNode * Cudd_bddIte( - DdManager * dd, - DdNode * f, - DdNode * g, - DdNode * h) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */, + DdNode * h /**< third operand */) { DdNode *res; @@ -151,33 +113,33 @@ Cudd_bddIte( dd->reordered = 0; res = cuddBddIteRecur(dd,f,g,h); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddIte */ -/**Function******************************************************************** +/** + @brief Implements ITE(f,g,h) unless too many nodes are required. - Synopsis [Implements ITE(f,g,h). Returns - NULL if too many nodes are required.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up or more new nodes than `limit` are + required. - Description [Implements ITE(f,g,h). Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up or more new nodes than <code>limit</code> are - required.] + @sideeffect None - SideEffects [None] + @see Cudd_bddIte - SeeAlso [Cudd_bddIte] - -******************************************************************************/ +*/ DdNode * Cudd_bddIteLimit( - DdManager * dd, - DdNode * f, - DdNode * g, - DdNode * h, - unsigned int limit) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */, + DdNode * h /**< third operand */, + unsigned int limit /**< maximum number of new nodes */) { DdNode *res; unsigned int saveLimit = dd->maxLive; @@ -188,36 +150,39 @@ Cudd_bddIteLimit( res = cuddBddIteRecur(dd,f,g,h); } while (dd->reordered == 1); dd->maxLive = saveLimit; + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddIteLimit */ -/**Function******************************************************************** +/** + @brief Implements ITEconstant(f,g,h). - Synopsis [Implements ITEconstant(f,g,h).] + @return a pointer to the resulting %BDD (which may or may not be + constant) or DD_NON_CONSTANT. - Description [Implements ITEconstant(f,g,h). Returns a pointer to the - resulting BDD (which may or may not be constant) or DD_NON_CONSTANT. - No new nodes are created.] + @details No new nodes are created. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddIte Cudd_bddIntersect Cudd_bddLeq Cudd_addIteConstant] + @see Cudd_bddIte Cudd_bddIntersect Cudd_bddLeq Cudd_addIteConstant -******************************************************************************/ +*/ DdNode * Cudd_bddIteConstant( - DdManager * dd, - DdNode * f, - DdNode * g, - DdNode * h) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */, + DdNode * h /**< thord operand */) { DdNode *r, *Fv, *Fnv, *Gv, *Gnv, *H, *Hv, *Hnv, *t, *e; DdNode *one = DD_ONE(dd); DdNode *zero = Cudd_Not(one); int comple; - unsigned int topf, topg, toph, v; + int topf, topg, toph, v; statLine(dd); /* Trivial cases. */ @@ -234,7 +199,7 @@ Cudd_bddIteConstant( if (g == h) /* ITE(F,G,G) => G */ return(g); - if (Cudd_IsConstant(g) && Cudd_IsConstant(h)) + if (Cudd_IsConstantInt(g) && Cudd_IsConstantInt(h)) return(DD_NON_CONSTANT); /* ITE(F,1,0) or ITE(F,0,1) */ /* => DD_NON_CONSTANT */ @@ -284,12 +249,12 @@ Cudd_bddIteConstant( /* Recursion. */ t = Cudd_bddIteConstant(dd, Fv, Gv, Hv); - if (t == DD_NON_CONSTANT || !Cudd_IsConstant(t)) { + if (t == DD_NON_CONSTANT || !Cudd_IsConstantInt(t)) { cuddCacheInsert(dd, DD_BDD_ITE_CONSTANT_TAG, f, g, h, DD_NON_CONSTANT); return(DD_NON_CONSTANT); } e = Cudd_bddIteConstant(dd, Fnv, Gnv, Hnv); - if (e == DD_NON_CONSTANT || !Cudd_IsConstant(e) || t != e) { + if (e == DD_NON_CONSTANT || !Cudd_IsConstantInt(e) || t != e) { cuddCacheInsert(dd, DD_BDD_ITE_CONSTANT_TAG, f, g, h, DD_NON_CONSTANT); return(DD_NON_CONSTANT); } @@ -299,26 +264,24 @@ Cudd_bddIteConstant( } /* end of Cudd_bddIteConstant */ -/**Function******************************************************************** +/** + @brief Returns a function included in the intersection of f and g. - Synopsis [Returns a function included in the intersection of f and g.] + @details The function computed (if not zero) is a witness that the + intersection is not empty. Cudd_bddIntersect tries to build as few + new nodes as possible. If the only result of interest is whether f + and g intersect, Cudd_bddLeq should be used instead. - Description [Computes a function included in the intersection of f and - g. (That is, a witness that the intersection is not empty.) - Cudd_bddIntersect tries to build as few new nodes as possible. If the - only result of interest is whether f and g intersect, - Cudd_bddLeq should be used instead.] + @sideeffect None - SideEffects [None] + @see Cudd_bddLeq Cudd_bddIteConstant - SeeAlso [Cudd_bddLeq Cudd_bddIteConstant] - -******************************************************************************/ +*/ DdNode * Cudd_bddIntersect( - DdManager * dd /* manager */, - DdNode * f /* first operand */, - DdNode * g /* second operand */) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */) { DdNode *res; @@ -326,31 +289,32 @@ Cudd_bddIntersect( dd->reordered = 0; res = cuddBddIntersectRecur(dd,f,g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddIntersect */ -/**Function******************************************************************** +/** + @brief Computes the conjunction of two BDDs f and g. - Synopsis [Computes the conjunction of two BDDs f and g.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up. - Description [Computes the conjunction of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up.] + @sideeffect None - SideEffects [None] + @see Cudd_bddIte Cudd_addApply Cudd_bddAndAbstract Cudd_bddIntersect + Cudd_bddOr Cudd_bddNand Cudd_bddNor Cudd_bddXor Cudd_bddXnor - SeeAlso [Cudd_bddIte Cudd_addApply Cudd_bddAndAbstract Cudd_bddIntersect - Cudd_bddOr Cudd_bddNand Cudd_bddNor Cudd_bddXor Cudd_bddXnor] - -******************************************************************************/ +*/ DdNode * Cudd_bddAnd( - DdManager * dd, - DdNode * f, - DdNode * g) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */) { DdNode *res; @@ -358,32 +322,33 @@ Cudd_bddAnd( dd->reordered = 0; res = cuddBddAndRecur(dd,f,g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddAnd */ -/**Function******************************************************************** - - Synopsis [Computes the conjunction of two BDDs f and g. Returns - NULL if too many nodes are required.] +/** + @brief Computes the conjunction of two BDDs f and g unless too many + nodes are required. - Description [Computes the conjunction of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up or more new nodes than <code>limit</code> are - required.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up or more new nodes than `limit` are + required. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddAnd] + @see Cudd_bddAnd -******************************************************************************/ +*/ DdNode * Cudd_bddAndLimit( - DdManager * dd, - DdNode * f, - DdNode * g, - unsigned int limit) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */, + unsigned int limit /**< maximum number of new nodes */) { DdNode *res; unsigned int saveLimit = dd->maxLive; @@ -394,30 +359,31 @@ Cudd_bddAndLimit( res = cuddBddAndRecur(dd,f,g); } while (dd->reordered == 1); dd->maxLive = saveLimit; + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddAndLimit */ -/**Function******************************************************************** - - Synopsis [Computes the disjunction of two BDDs f and g.] +/** + @brief Computes the disjunction of two BDDs f and g. - Description [Computes the disjunction of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddIte Cudd_addApply Cudd_bddAnd Cudd_bddNand Cudd_bddNor - Cudd_bddXor Cudd_bddXnor] + @see Cudd_bddIte Cudd_addApply Cudd_bddAnd Cudd_bddNand Cudd_bddNor + Cudd_bddXor Cudd_bddXnor -******************************************************************************/ +*/ DdNode * Cudd_bddOr( - DdManager * dd, - DdNode * f, - DdNode * g) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */) { DdNode *res; @@ -425,33 +391,34 @@ Cudd_bddOr( dd->reordered = 0; res = cuddBddAndRecur(dd,Cudd_Not(f),Cudd_Not(g)); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } res = Cudd_NotCond(res,res != NULL); return(res); } /* end of Cudd_bddOr */ -/**Function******************************************************************** - - Synopsis [Computes the disjunction of two BDDs f and g. Returns - NULL if too many nodes are required.] +/** + @brief Computes the disjunction of two BDDs f and g unless too many + nodes are required. - Description [Computes the disjunction of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up or more new nodes than <code>limit</code> are - required.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up or more new nodes than `limit` are + required. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddOr] + @see Cudd_bddOr -******************************************************************************/ +*/ DdNode * Cudd_bddOrLimit( - DdManager * dd, - DdNode * f, - DdNode * g, - unsigned int limit) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */, + unsigned int limit /**< maximum number of new nodes */) { DdNode *res; unsigned int saveLimit = dd->maxLive; @@ -462,31 +429,32 @@ Cudd_bddOrLimit( res = cuddBddAndRecur(dd,Cudd_Not(f),Cudd_Not(g)); } while (dd->reordered == 1); dd->maxLive = saveLimit; + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } res = Cudd_NotCond(res,res != NULL); return(res); } /* end of Cudd_bddOrLimit */ -/**Function******************************************************************** - - Synopsis [Computes the NAND of two BDDs f and g.] +/** + @brief Computes the NAND of two BDDs f and g. - Description [Computes the NAND of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddIte Cudd_addApply Cudd_bddAnd Cudd_bddOr Cudd_bddNor - Cudd_bddXor Cudd_bddXnor] + @see Cudd_bddIte Cudd_addApply Cudd_bddAnd Cudd_bddOr Cudd_bddNor + Cudd_bddXor Cudd_bddXnor -******************************************************************************/ +*/ DdNode * Cudd_bddNand( - DdManager * dd, - DdNode * f, - DdNode * g) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /** second operand */) { DdNode *res; @@ -494,31 +462,32 @@ Cudd_bddNand( dd->reordered = 0; res = cuddBddAndRecur(dd,f,g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } res = Cudd_NotCond(res,res != NULL); return(res); } /* end of Cudd_bddNand */ -/**Function******************************************************************** - - Synopsis [Computes the NOR of two BDDs f and g.] +/** + @brief Computes the NOR of two BDDs f and g. - Description [Computes the NOR of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddIte Cudd_addApply Cudd_bddAnd Cudd_bddOr Cudd_bddNand - Cudd_bddXor Cudd_bddXnor] + @see Cudd_bddIte Cudd_addApply Cudd_bddAnd Cudd_bddOr Cudd_bddNand + Cudd_bddXor Cudd_bddXnor -******************************************************************************/ +*/ DdNode * Cudd_bddNor( - DdManager * dd, - DdNode * f, - DdNode * g) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */) { DdNode *res; @@ -526,30 +495,31 @@ Cudd_bddNor( dd->reordered = 0; res = cuddBddAndRecur(dd,Cudd_Not(f),Cudd_Not(g)); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddNor */ -/**Function******************************************************************** +/** + @brief Computes the exclusive OR of two BDDs f and g. - Synopsis [Computes the exclusive OR of two BDDs f and g.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up. - Description [Computes the exclusive OR of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up.] + @sideeffect None - SideEffects [None] + @see Cudd_bddIte Cudd_addApply Cudd_bddAnd Cudd_bddOr + Cudd_bddNand Cudd_bddNor Cudd_bddXnor - SeeAlso [Cudd_bddIte Cudd_addApply Cudd_bddAnd Cudd_bddOr - Cudd_bddNand Cudd_bddNor Cudd_bddXnor] - -******************************************************************************/ +*/ DdNode * Cudd_bddXor( - DdManager * dd, - DdNode * f, - DdNode * g) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */) { DdNode *res; @@ -557,30 +527,31 @@ Cudd_bddXor( dd->reordered = 0; res = cuddBddXorRecur(dd,f,g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddXor */ -/**Function******************************************************************** +/** + @brief Computes the exclusive NOR of two BDDs f and g. - Synopsis [Computes the exclusive NOR of two BDDs f and g.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up. - Description [Computes the exclusive NOR of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up.] + @sideeffect None - SideEffects [None] + @see Cudd_bddIte Cudd_addApply Cudd_bddAnd Cudd_bddOr + Cudd_bddNand Cudd_bddNor Cudd_bddXor - SeeAlso [Cudd_bddIte Cudd_addApply Cudd_bddAnd Cudd_bddOr - Cudd_bddNand Cudd_bddNor Cudd_bddXor] - -******************************************************************************/ +*/ DdNode * Cudd_bddXnor( - DdManager * dd, - DdNode * f, - DdNode * g) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */) { DdNode *res; @@ -588,32 +559,33 @@ Cudd_bddXnor( dd->reordered = 0; res = cuddBddXorRecur(dd,f,Cudd_Not(g)); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddXnor */ -/**Function******************************************************************** +/** + @brief Computes the exclusive NOR of two BDDs f and g unless too + many nodes are required. - Synopsis [Computes the exclusive NOR of two BDDs f and g. Returns - NULL if too many nodes are required.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up or more new nodes than `limit` are + required. - Description [Computes the exclusive NOR of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up or more new nodes than <code>limit</code> are - required.] + @sideeffect None - SideEffects [None] + @see Cudd_bddXnor - SeeAlso [Cudd_bddXnor] - -******************************************************************************/ +*/ DdNode * Cudd_bddXnorLimit( - DdManager * dd, - DdNode * f, - DdNode * g, - unsigned int limit) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */, + unsigned int limit /**< maximum number of new nodes */) { DdNode *res; unsigned int saveLimit = dd->maxLive; @@ -624,31 +596,34 @@ Cudd_bddXnorLimit( res = cuddBddXorRecur(dd,f,Cudd_Not(g)); } while (dd->reordered == 1); dd->maxLive = saveLimit; + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddXnorLimit */ -/**Function******************************************************************** +/** + @brief Checks whether f is less than or equal to g. - Synopsis [Determines whether f is less than or equal to g.] + @return 1 if f is less than or equal to g; 0 otherwise. - Description [Returns 1 if f is less than or equal to g; 0 otherwise. - No new nodes are created.] + @details No new nodes are created. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddIteConstant Cudd_addEvalConst] + @see Cudd_bddIteConstant Cudd_addEvalConst -******************************************************************************/ +*/ int Cudd_bddLeq( - DdManager * dd, - DdNode * f, - DdNode * g) + DdManager * dd /**< manager */, + DdNode * f /**< first operand */, + DdNode * g /**< second operand */) { DdNode *one, *zero, *tmp, *F, *fv, *fvn, *gv, *gvn; - unsigned int topf, topg, res; + int topf, topg, res; statLine(dd); /* Terminal cases and normalization. */ @@ -671,7 +646,7 @@ Cudd_bddLeq( f = Cudd_Not(tmp); } - /* Now g is regular and, if f is not regular, f < g. */ + /* Now g is regular. */ one = DD_ONE(dd); if (g == one) return(1); /* no need to test against zero */ if (f == one) return(0); /* since at this point g != one */ @@ -682,13 +657,15 @@ Cudd_bddLeq( /* Here neither f nor g is constant. */ /* Check cache. */ - tmp = cuddCacheLookup2(dd,(DD_CTFP)Cudd_bddLeq,f,g); - if (tmp != NULL) { - return(tmp == one); + F = Cudd_Regular(f); + if (F->ref != 1 || g->ref != 1) { + tmp = cuddCacheLookup2(dd,(DD_CTFP)Cudd_bddLeq,f,g); + if (tmp != NULL) { + return(tmp == one); + } } /* Compute cofactors. */ - F = Cudd_Regular(f); topf = dd->perm[F->index]; topg = dd->perm[g->index]; if (topf <= topg) { @@ -714,7 +691,8 @@ Cudd_bddLeq( res = Cudd_bddLeq(dd,fvn,gvn) && Cudd_bddLeq(dd,fv,gv); /* Store result in cache and return. */ - cuddCacheInsert2(dd,(DD_CTFP)Cudd_bddLeq,f,g,(res ? one : zero)); + if (F->ref !=1 || g->ref != 1) + cuddCacheInsert2(dd,(DD_CTFP)Cudd_bddLeq,f,g,(res ? one : zero)); return(res); } /* end of Cudd_bddLeq */ @@ -725,19 +703,15 @@ Cudd_bddLeq( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Implements the recursive step of Cudd_bddIte.] +/** + @brief Implements the recursive step of Cudd_bddIte. - Description [Implements the recursive step of Cudd_bddIte. Returns a - pointer to the resulting BDD. NULL if the intermediate result blows - up or if reordering occurs.] + @return a pointer to the resulting %BDD. NULL if the intermediate + result blows up or if reordering occurs. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ DdNode * cuddBddIteRecur( DdManager * dd, @@ -747,8 +721,8 @@ cuddBddIteRecur( { DdNode *one, *zero, *res; DdNode *r, *Fv, *Fnv, *Gv, *Gnv, *H, *Hv, *Hnv, *t, *e; - unsigned int topf, topg, toph, v; - int index; + int topf, topg, toph, v; + unsigned int index; int comple; statLine(dd); @@ -812,10 +786,12 @@ cuddBddIteRecur( return(Cudd_NotCond(r,comple)); } + checkWhetherToGiveUp(dd); + /* Compute cofactors. */ + index = f->index; if (topf <= v) { v = ddMin(topf, v); /* v = top_var(F,G,H) */ - index = f->index; Fv = cuddT(f); Fnv = cuddE(f); } else { Fv = Fnv = f; @@ -865,17 +841,14 @@ cuddBddIteRecur( } /* end of cuddBddIteRecur */ -/**Function******************************************************************** - - Synopsis [Implements the recursive step of Cudd_bddIntersect.] - - Description [] +/** + @brief Implements the recursive step of Cudd_bddIntersect. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddIntersect] + @see Cudd_bddIntersect -******************************************************************************/ +*/ DdNode * cuddBddIntersectRecur( DdManager * dd, @@ -886,7 +859,8 @@ cuddBddIntersectRecur( DdNode *F, *G, *t, *e; DdNode *fv, *fnv, *gv, *gnv; DdNode *one, *zero; - unsigned int index, topf, topg; + unsigned int index; + int topf, topg; statLine(dd); one = DD_ONE(dd); @@ -902,6 +876,8 @@ cuddBddIntersectRecur( res = cuddCacheLookup2(dd,Cudd_bddIntersect,f,g); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + /* Find splitting variable. Here we can skip the use of cuddI, ** because the operands are known to be non-constant. */ @@ -978,19 +954,18 @@ cuddBddIntersectRecur( } /* end of cuddBddIntersectRecur */ -/**Function******************************************************************** +/** + @brief Implements the recursive step of Cudd_bddAnd. - Synopsis [Implements the recursive step of Cudd_bddAnd.] + @details Takes the conjunction of two BDDs. - Description [Implements the recursive step of Cudd_bddAnd by taking - the conjunction of two BDDs. Returns a pointer to the result is - successful; NULL otherwise.] + @return a pointer to the result is successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddAnd] + @see Cudd_bddAnd -******************************************************************************/ +*/ DdNode * cuddBddAndRecur( DdManager * manager, @@ -999,7 +974,8 @@ cuddBddAndRecur( { DdNode *F, *fv, *fnv, *G, *gv, *gnv; DdNode *one, *r, *t, *e; - unsigned int topf, topg, index; + int topf, topg; + unsigned int index; statLine(manager); one = DD_ONE(manager); @@ -1035,6 +1011,8 @@ cuddBddAndRecur( if (r != NULL) return(r); } + checkWhetherToGiveUp(manager); + /* Here we can skip the use of cuddI, because the operands are known ** to be non-constant. */ @@ -1106,19 +1084,18 @@ cuddBddAndRecur( } /* end of cuddBddAndRecur */ -/**Function******************************************************************** +/** + @brief Implements the recursive step of Cudd_bddXor. - Synopsis [Implements the recursive step of Cudd_bddXor.] + @details Takes the exclusive OR of two BDDs. - Description [Implements the recursive step of Cudd_bddXor by taking - the exclusive OR of two BDDs. Returns a pointer to the result is - successful; NULL otherwise.] + @return a pointer to the result is successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddXor] + @see Cudd_bddXor -******************************************************************************/ +*/ DdNode * cuddBddXorRecur( DdManager * manager, @@ -1127,7 +1104,8 @@ cuddBddXorRecur( { DdNode *fv, *fnv, *G, *gv, *gnv; DdNode *one, *zero, *r, *t, *e; - unsigned int topf, topg, index; + int topf, topg; + unsigned int index; statLine(manager); one = DD_ONE(manager); @@ -1156,6 +1134,8 @@ cuddBddXorRecur( r = cuddCacheLookup2(manager, Cudd_bddXor, f, g); if (r != NULL) return(r); + checkWhetherToGiveUp(manager); + /* Here we can skip the use of cuddI, because the operands are known ** to be non-constant. */ @@ -1228,18 +1208,17 @@ cuddBddXorRecur( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Replaces variables with constants if possible.] +/** + @brief Replaces variables with constants if possible. - Description [This function performs part of the transformation to - standard form by replacing variables with constants if possible.] + @details This function performs part of the transformation to + standard form by replacing variables with constants if possible. - SideEffects [None] + @sideeffect None - SeeAlso [bddVarToCanonical bddVarToCanonicalSimple] + @see bddVarToCanonical bddVarToCanonicalSimple -******************************************************************************/ +*/ static void bddVarToConst( DdNode * f, @@ -1264,31 +1243,30 @@ bddVarToConst( } /* end of bddVarToConst */ -/**Function******************************************************************** - - Synopsis [Picks unique member from equiv expressions.] +/** + @brief Picks unique member from equiv expressions. - Description [Reduces 2 variable expressions to canonical form.] + @details Reduces 2 variable expressions to canonical form. - SideEffects [None] + @sideeffect None - SeeAlso [bddVarToConst bddVarToCanonicalSimple] + @see bddVarToConst bddVarToCanonicalSimple -******************************************************************************/ +*/ static int bddVarToCanonical( DdManager * dd, DdNode ** fp, DdNode ** gp, DdNode ** hp, - unsigned int * topfp, - unsigned int * topgp, - unsigned int * tophp) + int * topfp, + int * topgp, + int * tophp) { - register DdNode *F, *G, *H, *r, *f, *g, *h; - register unsigned int topf, topg, toph; - DdNode *one = dd->one; - int comple, change; + DdNode *F, *G, *H, *r, *f, *g, *h; + DdNode *one = dd->one; + int topf, topg, toph; + int comple, change; f = *fp; g = *gp; @@ -1362,33 +1340,32 @@ bddVarToCanonical( } /* end of bddVarToCanonical */ -/**Function******************************************************************** +/** + @brief Picks unique member from equiv expressions. - Synopsis [Picks unique member from equiv expressions.] - - Description [Makes sure the first two pointers are regular. This + @details Makes sure the first two pointers are regular. This mat require the complementation of the result, which is signaled by returning 1 instead of 0. This function is simpler than the general case because it assumes that no two arguments are the same or - complementary, and no argument is constant.] + complementary, and no argument is constant. - SideEffects [None] + @sideeffect None - SeeAlso [bddVarToConst bddVarToCanonical] + @see bddVarToConst bddVarToCanonical -******************************************************************************/ +*/ static int bddVarToCanonicalSimple( DdManager * dd, DdNode ** fp, DdNode ** gp, DdNode ** hp, - unsigned int * topfp, - unsigned int * topgp, - unsigned int * tophp) + int * topfp, + int * topgp, + int * tophp) { - register DdNode *r, *f, *g, *h; - int comple, change; + DdNode *r, *f, *g, *h; + int comple, change; f = *fp; g = *gp; @@ -1427,4 +1404,3 @@ bddVarToCanonicalSimple( return(comple); } /* end of bddVarToCanonicalSimple */ - diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddBridge.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddBridge.c similarity index 66% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddBridge.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddBridge.c index a6207b7f6..4d4374f83 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddBridge.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddBridge.c @@ -1,43 +1,15 @@ -/**CFile*********************************************************************** - - FileName [cuddBridge.c] - - PackageName [cudd] - - Synopsis [Translation from BDD to ADD and vice versa and transfer between - different managers.] - - Description [External procedures included in this file: - <ul> - <li> Cudd_addBddThreshold() - <li> Cudd_addBddStrictThreshold() - <li> Cudd_addBddInterval() - <li> Cudd_addBddIthBit() - <li> Cudd_BddToAdd() - <li> Cudd_addBddPattern() - <li> Cudd_bddTransfer() - </ul> - Internal procedures included in this file: - <ul> - <li> cuddBddTransfer() - <li> cuddAddBddDoPattern() - </ul> - Static procedures included in this file: - <ul> - <li> addBddDoThreshold() - <li> addBddDoStrictThreshold() - <li> addBddDoInterval() - <li> addBddDoIthBit() - <li> ddBddToAddRecur() - <li> cuddBddTransferRecur() - </ul> - ] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Translation from %BDD to %ADD and vice versa and transfer + between different managers. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -67,9 +39,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -93,20 +66,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddBridge.c,v 1.20 2012/02/05 01:07:18 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -#ifdef __cplusplus -extern "C" { -#endif - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -119,33 +84,28 @@ static DdNode * addBddDoIthBit (DdManager *dd, DdNode *f, DdNode *index); static DdNode * ddBddToAddRecur (DdManager *dd, DdNode *B); static DdNode * cuddBddTransferRecur (DdManager *ddS, DdManager *ddD, DdNode *f, st_table *table); -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} -#endif - +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Converts an %ADD to a %BDD. - Synopsis [Converts an ADD to a BDD.] + @details Replaces all discriminants greater than or equal to value + with 1, and all other discriminants with 0. - Description [Converts an ADD to a BDD by replacing all - discriminants greater than or equal to value with 1, and all other - discriminants with 0. Returns a pointer to the resulting BDD if - successful; NULL otherwise.] + @return a pointer to the resulting %BDD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addBddInterval Cudd_addBddPattern Cudd_BddToAdd - Cudd_addBddStrictThreshold] + @see Cudd_addBddInterval Cudd_addBddPattern Cudd_BddToAdd + Cudd_addBddStrictThreshold -******************************************************************************/ +*/ DdNode * Cudd_addBddThreshold( DdManager * dd, @@ -166,6 +126,9 @@ Cudd_addBddThreshold( if (res == NULL) { Cudd_RecursiveDeref(dd, val); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(NULL); } cuddRef(res); @@ -176,21 +139,21 @@ Cudd_addBddThreshold( } /* end of Cudd_addBddThreshold */ -/**Function******************************************************************** +/** + @brief Converts an %ADD to a %BDD. - Synopsis [Converts an ADD to a BDD.] + @details Replaces all discriminants STRICTLY greater than value with + 1, and all other discriminants with 0. - Description [Converts an ADD to a BDD by replacing all - discriminants STRICTLY greater than value with 1, and all other - discriminants with 0. Returns a pointer to the resulting BDD if - successful; NULL otherwise.] + @return a pointer to the resulting %BDD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addBddInterval Cudd_addBddPattern Cudd_BddToAdd - Cudd_addBddThreshold] + @see Cudd_addBddInterval Cudd_addBddPattern Cudd_BddToAdd + Cudd_addBddThreshold -******************************************************************************/ +*/ DdNode * Cudd_addBddStrictThreshold( DdManager * dd, @@ -211,6 +174,9 @@ Cudd_addBddStrictThreshold( if (res == NULL) { Cudd_RecursiveDeref(dd, val); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(NULL); } cuddRef(res); @@ -221,21 +187,22 @@ Cudd_addBddStrictThreshold( } /* end of Cudd_addBddStrictThreshold */ -/**Function******************************************************************** +/** + @brief Converts an %ADD to a %BDD. - Synopsis [Converts an ADD to a BDD.] + @details Replaces all discriminants greater than or equal to lower + and less than or equal to upper with 1, and all other discriminants + with 0. - Description [Converts an ADD to a BDD by replacing all - discriminants greater than or equal to lower and less than or equal to - upper with 1, and all other discriminants with 0. Returns a pointer to - the resulting BDD if successful; NULL otherwise.] + @return a pointer to the resulting %BDD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addBddThreshold Cudd_addBddStrictThreshold - Cudd_addBddPattern Cudd_BddToAdd] + @see Cudd_addBddThreshold Cudd_addBddStrictThreshold + Cudd_addBddPattern Cudd_BddToAdd -******************************************************************************/ +*/ DdNode * Cudd_addBddInterval( DdManager * dd, @@ -268,6 +235,9 @@ Cudd_addBddInterval( if (res == NULL) { Cudd_RecursiveDeref(dd, l); Cudd_RecursiveDeref(dd, u); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(NULL); } cuddRef(res); @@ -279,25 +249,26 @@ Cudd_addBddInterval( } /* end of Cudd_addBddInterval */ -/**Function******************************************************************** +/** + @brief Converts an %ADD to a %BDD by extracting the i-th bit from + the leaves. - Synopsis [Converts an ADD to a BDD by extracting the i-th bit from - the leaves.] - - Description [Converts an ADD to a BDD by replacing all + @details Converts an %ADD to a %BDD by replacing all discriminants whose i-th bit is equal to 1 with 1, and all other - discriminants with 0. The i-th bit refers to the integer - representation of the leaf value. If the value is has a fractional - part, it is ignored. Repeated calls to this procedure allow one to - transform an integer-valued ADD into an array of BDDs, one for each - bit of the leaf values. Returns a pointer to the resulting BDD if - successful; NULL otherwise.] + discriminants with 0. The i-th bit refers to the integer + representation of the leaf value. If the value has a fractional + part, it is ignored. Repeated calls to this procedure allow one to + transform an integer-valued %ADD into an array of BDDs, one for each + bit of the leaf values. + + @return a pointer to the resulting %BDD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addBddInterval Cudd_addBddPattern Cudd_BddToAdd] + @see Cudd_addBddInterval Cudd_addBddPattern Cudd_BddToAdd -******************************************************************************/ +*/ DdNode * Cudd_addBddIthBit( DdManager * dd, @@ -318,6 +289,9 @@ Cudd_addBddIthBit( if (res == NULL) { Cudd_RecursiveDeref(dd, index); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(NULL); } cuddRef(res); @@ -328,19 +302,18 @@ Cudd_addBddIthBit( } /* end of Cudd_addBddIthBit */ -/**Function******************************************************************** +/** + @brief Converts a %BDD to a 0-1 %ADD. - Synopsis [Converts a BDD to a 0-1 ADD.] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. - Description [Converts a BDD to a 0-1 ADD. Returns a pointer to the - resulting ADD if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_addBddPattern Cudd_addBddThreshold Cudd_addBddInterval + Cudd_addBddStrictThreshold - SeeAlso [Cudd_addBddPattern Cudd_addBddThreshold Cudd_addBddInterval - Cudd_addBddStrictThreshold] - -******************************************************************************/ +*/ DdNode * Cudd_BddToAdd( DdManager * dd, @@ -357,20 +330,20 @@ Cudd_BddToAdd( } /* end of Cudd_BddToAdd */ -/**Function******************************************************************** +/** + @brief Converts an %ADD to a %BDD. - Synopsis [Converts an ADD to a BDD.] + @details Replaces all discriminants different from 0 with 1. - Description [Converts an ADD to a BDD by replacing all - discriminants different from 0 with 1. Returns a pointer to the - resulting BDD if successful; NULL otherwise.] + @return a pointer to the resulting %BDD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_BddToAdd Cudd_addBddThreshold Cudd_addBddInterval - Cudd_addBddStrictThreshold] + @see Cudd_BddToAdd Cudd_addBddThreshold Cudd_addBddInterval + Cudd_addBddStrictThreshold -******************************************************************************/ +*/ DdNode * Cudd_addBddPattern( DdManager * dd, @@ -382,25 +355,26 @@ Cudd_addBddPattern( dd->reordered = 0; res = cuddAddBddDoPattern(dd, f); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addBddPattern */ -/**Function******************************************************************** +/** + @brief Convert a %BDD from a manager to another one. - Synopsis [Convert a BDD from a manager to another one.] + @details The orders of the variables in the two managers may be + different. - Description [Convert a BDD from a manager to another one. The orders of the - variables in the two managers may be different. Returns a - pointer to the BDD in the destination manager if successful; NULL - otherwise.] + @return a pointer to the %BDD in the destination manager if + successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ DdNode * Cudd_bddTransfer( DdManager * ddSource, @@ -412,6 +386,10 @@ Cudd_bddTransfer( ddDestination->reordered = 0; res = cuddBddTransfer(ddSource, ddDestination, f); } while (ddDestination->reordered == 1); + if (ddDestination->errorCode == CUDD_TIMEOUT_EXPIRED && + ddDestination->timeoutHandler) { + ddDestination->timeoutHandler(ddDestination, ddDestination->tohArg); + } return(res); } /* end of Cudd_bddTransfer */ @@ -422,19 +400,17 @@ Cudd_bddTransfer( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Convert a %BDD from a manager to another one. - Synopsis [Convert a BDD from a manager to another one.] + @return a pointer to the %BDD in the destination manager if + successful; NULL otherwise. - Description [Convert a BDD from a manager to another one. Returns a - pointer to the BDD in the destination manager if successful; NULL - otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_bddTransfer - SeeAlso [Cudd_bddTransfer] - -******************************************************************************/ +*/ DdNode * cuddBddTransfer( DdManager * ddS, @@ -456,7 +432,7 @@ cuddBddTransfer( ** reordering. */ gen = st_init_gen(table); if (gen == NULL) goto failure; - while (st_gen(gen, &key, &value)) { + while (st_gen(gen, (void **) &key, (void **) &value)) { Cudd_RecursiveDeref(ddD, value); } st_free_gen(gen); gen = NULL; @@ -473,18 +449,15 @@ failure: } /* end of cuddBddTransfer */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step for Cudd_addBddPattern.] +/** + @brief Performs the recursive step for Cudd_addBddPattern. - Description [Performs the recursive step for Cudd_addBddPattern. Returns a - pointer to the resulting BDD if successful; NULL otherwise.] + @return a pointer to the resulting %BDD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ DdNode * cuddAddBddDoPattern( DdManager * dd, @@ -492,7 +465,7 @@ cuddAddBddDoPattern( { DdNode *res, *T, *E; DdNode *fv, *fvn; - int v; + unsigned int v; statLine(dd); /* Check terminal case. */ @@ -504,6 +477,8 @@ cuddAddBddDoPattern( res = cuddCacheLookup1(dd,Cudd_addBddPattern,f); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + /* Recursive step. */ v = f->index; fv = cuddT(f); fvn = cuddE(f); @@ -550,18 +525,16 @@ cuddAddBddDoPattern( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step for Cudd_addBddThreshold. - Synopsis [Performs the recursive step for Cudd_addBddThreshold.] + @return a pointer to the %BDD if successful; NULL otherwise. - Description [Performs the recursive step for Cudd_addBddThreshold. - Returns a pointer to the BDD if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see addBddDoStrictThreshold - SeeAlso [addBddDoStrictThreshold] - -******************************************************************************/ +*/ static DdNode * addBddDoThreshold( DdManager * dd, @@ -570,7 +543,7 @@ addBddDoThreshold( { DdNode *res, *T, *E; DdNode *fv, *fvn; - int v; + unsigned int v; statLine(dd); /* Check terminal case. */ @@ -582,6 +555,8 @@ addBddDoThreshold( res = cuddCacheLookup2(dd,addBddDoThreshold,f,val); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + /* Recursive step. */ v = f->index; fv = cuddT(f); fvn = cuddE(f); @@ -623,18 +598,16 @@ addBddDoThreshold( } /* end of addBddDoThreshold */ -/**Function******************************************************************** +/** + @brief Performs the recursive step for Cudd_addBddStrictThreshold. - Synopsis [Performs the recursive step for Cudd_addBddStrictThreshold.] + @return a pointer to the %BDD if successful; NULL otherwise. - Description [Performs the recursive step for Cudd_addBddStrictThreshold. - Returns a pointer to the BDD if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see addBddDoThreshold - SeeAlso [addBddDoThreshold] - -******************************************************************************/ +*/ static DdNode * addBddDoStrictThreshold( DdManager * dd, @@ -643,7 +616,7 @@ addBddDoStrictThreshold( { DdNode *res, *T, *E; DdNode *fv, *fvn; - int v; + unsigned int v; statLine(dd); /* Check terminal case. */ @@ -655,6 +628,8 @@ addBddDoStrictThreshold( res = cuddCacheLookup2(dd,addBddDoStrictThreshold,f,val); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + /* Recursive step. */ v = f->index; fv = cuddT(f); fvn = cuddE(f); @@ -696,18 +671,16 @@ addBddDoStrictThreshold( } /* end of addBddDoStrictThreshold */ -/**Function******************************************************************** +/** + @brief Performs the recursive step for Cudd_addBddInterval. - Synopsis [Performs the recursive step for Cudd_addBddInterval.] + @return a pointer to the %BDD if successful; NULL otherwise. - Description [Performs the recursive step for Cudd_addBddInterval. - Returns a pointer to the BDD if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see addBddDoThreshold addBddDoStrictThreshold - SeeAlso [addBddDoThreshold addBddDoStrictThreshold] - -******************************************************************************/ +*/ static DdNode * addBddDoInterval( DdManager * dd, @@ -717,7 +690,7 @@ addBddDoInterval( { DdNode *res, *T, *E; DdNode *fv, *fvn; - int v; + unsigned int v; statLine(dd); /* Check terminal case. */ @@ -729,6 +702,8 @@ addBddDoInterval( res = cuddCacheLookup(dd,DD_ADD_BDD_DO_INTERVAL_TAG,f,l,u); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + /* Recursive step. */ v = f->index; fv = cuddT(f); fvn = cuddE(f); @@ -770,18 +745,14 @@ addBddDoInterval( } /* end of addBddDoInterval */ -/**Function******************************************************************** +/** + @brief Performs the recursive step for Cudd_addBddIthBit. - Synopsis [Performs the recursive step for Cudd_addBddIthBit.] + @return a pointer to the %BDD if successful; NULL otherwise. - Description [Performs the recursive step for Cudd_addBddIthBit. - Returns a pointer to the BDD if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static DdNode * addBddDoIthBit( DdManager * dd, @@ -791,7 +762,7 @@ addBddDoIthBit( DdNode *res, *T, *E; DdNode *fv, *fvn; int mask, value; - int v; + unsigned int v; statLine(dd); /* Check terminal case. */ @@ -805,6 +776,8 @@ addBddDoIthBit( res = cuddCacheLookup2(dd,addBddDoIthBit,f,index); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + /* Recursive step. */ v = f->index; fv = cuddT(f); fvn = cuddE(f); @@ -846,18 +819,15 @@ addBddDoIthBit( } /* end of addBddDoIthBit */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step for Cudd_BddToAdd.] +/** + @brief Performs the recursive step for Cudd_BddToAdd. - Description [Performs the recursive step for Cudd_BddToAdd. Returns a - pointer to the resulting ADD if successful; NULL otherwise.] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static DdNode * ddBddToAddRecur( DdManager * dd, @@ -870,7 +840,7 @@ ddBddToAddRecur( statLine(dd); one = DD_ONE(dd); - if (Cudd_IsConstant(B)) { + if (Cudd_IsConstantInt(B)) { if (B == one) { res = one; } else { @@ -882,6 +852,8 @@ ddBddToAddRecur( res = cuddCacheLookup1(dd,ddBddToAddRecur,B); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + if (Cudd_IsComplement(B)) { complement = 1; Bt = cuddT(Cudd_Regular(B)); @@ -933,18 +905,16 @@ ddBddToAddRecur( } /* end of ddBddToAddRecur */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_bddTransfer.] +/** + @brief Performs the recursive step of Cudd_bddTransfer. - Description [Performs the recursive step of Cudd_bddTransfer. - Returns a pointer to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddBddTransfer] + @see cuddBddTransfer -******************************************************************************/ +*/ static DdNode * cuddBddTransferRecur( DdManager * ddS, @@ -954,22 +924,22 @@ cuddBddTransferRecur( { DdNode *ft, *fe, *t, *e, *var, *res; DdNode *one, *zero; - int index; - int comple = 0; + unsigned int index; + int comple = 0; statLine(ddD); one = DD_ONE(ddD); comple = Cudd_IsComplement(f); /* Trivial cases. */ - if (Cudd_IsConstant(f)) return(Cudd_NotCond(one, comple)); + if (Cudd_IsConstantInt(f)) return(Cudd_NotCond(one, comple)); /* Make canonical to increase the utilization of the cache. */ f = Cudd_NotCond(f,comple); /* Now f is a regular pointer to a non-constant node. */ /* Check the cache. */ - if (st_lookup(table, f, &res)) + if (st_lookup(table, f, (void **) &res)) return(Cudd_NotCond(res,comple)); /* Recursive step. */ @@ -1006,7 +976,7 @@ cuddBddTransferRecur( Cudd_RecursiveDeref(ddD, t); Cudd_RecursiveDeref(ddD, e); - if (st_add_direct(table, (char *) f, (char *) res) == ST_OUT_OF_MEM) { + if (st_add_direct(table, f, res) == ST_OUT_OF_MEM) { Cudd_RecursiveDeref(ddD, res); return(NULL); } diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddCache.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddCache.c similarity index 74% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddCache.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddCache.c index bf98c69e4..010e486f7 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddCache.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddCache.c @@ -1,35 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddCache.c] + @ingroup cudd - PackageName [cudd] + @brief Functions for cache insertion and lookup. - Synopsis [Functions for cache insertion and lookup.] + @author Fabio Somenzi - Description [Internal procedures included in this module: - <ul> - <li> cuddInitCache() - <li> cuddCacheInsert() - <li> cuddCacheInsert2() - <li> cuddCacheLookup() - <li> cuddCacheLookupZdd() - <li> cuddCacheLookup2() - <li> cuddCacheLookup2Zdd() - <li> cuddConstantLookup() - <li> cuddCacheProfile() - <li> cuddCacheResize() - <li> cuddCacheFlush() - <li> cuddComputeFloorLog2() - </ul> - Static procedures included in this module: - <ul> - </ul> ] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -59,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -88,23 +68,18 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddCache.c,v 1.36 2012/02/05 01:07:18 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -116,23 +91,23 @@ static char rcsid[] DD_UNUSED = "$Id: cuddCache.c,v 1.36 2012/02/05 01:07:18 fab /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Initializes the computed table. - Synopsis [Initializes the computed table.] + @details It is called by Cudd_Init. - Description [Initializes the computed table. It is called by - Cudd_Init. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Init] + @see Cudd_Init -******************************************************************************/ +*/ int cuddInitCache( - DdManager * unique /* unique table */, - unsigned int cacheSize /* initial size of the cache */, - unsigned int maxCacheSize /* cache size beyond which no resizing occurs */) + DdManager * unique /**< unique table */, + unsigned int cacheSize /**< initial size of the cache */, + unsigned int maxCacheSize /**< cache size beyond which no resizing occurs */) { int i; unsigned int logSize; @@ -144,7 +119,7 @@ cuddInitCache( /* Round cacheSize to largest power of 2 not greater than the requested ** initial cache size. */ logSize = cuddComputeFloorLog2(ddMax(cacheSize,unique->slots/2)); - cacheSize = 1 << logSize; + cacheSize = 1U << logSize; unique->acache = ALLOC(DdCache,cacheSize+1); if (unique->acache == NULL) { unique->errorCode = CUDD_MEMORY_OUT; @@ -199,20 +174,18 @@ cuddInitCache( } /* end of cuddInitCache */ -/**Function******************************************************************** +/** + @brief Inserts a result in the cache for a function with three + operands. - Synopsis [Inserts a result in the cache for a function with three - operands.] + @details The operator tag (see cuddInt.h for details) is split and + stored into unused bits of the first two pointers. - Description [Inserts a result in the cache for a function with three - operands. The operator tag (see cuddInt.h for details) is split and stored - into unused bits of the first two pointers.] + @sideeffect None - SideEffects [None] + @see cuddCacheInsert2 cuddCacheInsert1 - SeeAlso [cuddCacheInsert2 cuddCacheInsert1] - -******************************************************************************/ +*/ void cuddCacheInsert( DdManager * table, @@ -223,7 +196,7 @@ cuddCacheInsert( DdNode * data) { int posn; - register DdCache *entry; + DdCache *entry; ptruint uf, ug, uh; uf = (ptruint) f | (op & 0xe); @@ -247,18 +220,15 @@ cuddCacheInsert( } /* end of cuddCacheInsert */ -/**Function******************************************************************** - - Synopsis [Inserts a result in the cache for a function with two - operands.] +/** + @brief Inserts a result in the cache for a function with two + operands. - Description [] + @sideeffect None - SideEffects [None] + @see cuddCacheInsert cuddCacheInsert1 - SeeAlso [cuddCacheInsert cuddCacheInsert1] - -******************************************************************************/ +*/ void cuddCacheInsert2( DdManager * table, @@ -268,7 +238,7 @@ cuddCacheInsert2( DdNode * data) { int posn; - register DdCache *entry; + DdCache *entry; posn = ddCHash2(op,f,g,table->cacheShift); entry = &table->cache[posn]; @@ -289,18 +259,15 @@ cuddCacheInsert2( } /* end of cuddCacheInsert2 */ -/**Function******************************************************************** - - Synopsis [Inserts a result in the cache for a function with two - operands.] +/** + @brief Inserts a result in the cache for a function with two + operands. - Description [] + @sideeffect None - SideEffects [None] + @see cuddCacheInsert cuddCacheInsert2 - SeeAlso [cuddCacheInsert cuddCacheInsert2] - -******************************************************************************/ +*/ void cuddCacheInsert1( DdManager * table, @@ -309,7 +276,7 @@ cuddCacheInsert1( DdNode * data) { int posn; - register DdCache *entry; + DdCache *entry; posn = ddCHash2(op,f,f,table->cacheShift); entry = &table->cache[posn]; @@ -330,19 +297,17 @@ cuddCacheInsert1( } /* end of cuddCacheInsert1 */ -/**Function******************************************************************** - - Synopsis [Looks up in the cache for the result of op applied to f, - g, and h.] +/** + @brief Looks up in the cache for the result of op applied to f, + g, and h. - Description [Returns the result if found; it returns NULL if no - result is found.] + @return the result if found; it returns NULL if no result is found. - SideEffects [None] + @sideeffect None - SeeAlso [cuddCacheLookup2 cuddCacheLookup1] + @see cuddCacheLookup2 cuddCacheLookup1 -******************************************************************************/ +*/ DdNode * cuddCacheLookup( DdManager * table, @@ -392,19 +357,17 @@ cuddCacheLookup( } /* end of cuddCacheLookup */ -/**Function******************************************************************** +/** + @brief Looks up in the cache for the result of op applied to f, + g, and h. - Synopsis [Looks up in the cache for the result of op applied to f, - g, and h.] + @return the result if found; it returns NULL if no result is found. - Description [Returns the result if found; it returns NULL if no - result is found.] + @sideeffect None - SideEffects [None] + @see cuddCacheLookup2Zdd cuddCacheLookup1Zdd - SeeAlso [cuddCacheLookup2Zdd cuddCacheLookup1Zdd] - -******************************************************************************/ +*/ DdNode * cuddCacheLookupZdd( DdManager * table, @@ -454,19 +417,17 @@ cuddCacheLookupZdd( } /* end of cuddCacheLookupZdd */ -/**Function******************************************************************** - - Synopsis [Looks up in the cache for the result of op applied to f - and g.] +/** + @brief Looks up in the cache for the result of op applied to f + and g. - Description [Returns the result if found; it returns NULL if no - result is found.] + @return the result if found; it returns NULL if no result is found. - SideEffects [None] + @sideeffect None - SeeAlso [cuddCacheLookup cuddCacheLookup1] + @see cuddCacheLookup cuddCacheLookup1 -******************************************************************************/ +*/ DdNode * cuddCacheLookup2( DdManager * table, @@ -509,18 +470,16 @@ cuddCacheLookup2( } /* end of cuddCacheLookup2 */ -/**Function******************************************************************** - - Synopsis [Looks up in the cache for the result of op applied to f.] +/** + @brief Looks up in the cache for the result of op applied to f. - Description [Returns the result if found; it returns NULL if no - result is found.] + @return the result if found; it returns NULL if no result is found. - SideEffects [None] + @sideeffect None - SeeAlso [cuddCacheLookup cuddCacheLookup2] + @see cuddCacheLookup cuddCacheLookup2 -******************************************************************************/ +*/ DdNode * cuddCacheLookup1( DdManager * table, @@ -562,19 +521,17 @@ cuddCacheLookup1( } /* end of cuddCacheLookup1 */ -/**Function******************************************************************** +/** + @brief Looks up in the cache for the result of op applied to f + and g. - Synopsis [Looks up in the cache for the result of op applied to f - and g.] + @return the result if found; it returns NULL if no result is found. - Description [Returns the result if found; it returns NULL if no - result is found.] + @sideeffect None - SideEffects [None] + @see cuddCacheLookupZdd cuddCacheLookup1Zdd - SeeAlso [cuddCacheLookupZdd cuddCacheLookup1Zdd] - -******************************************************************************/ +*/ DdNode * cuddCacheLookup2Zdd( DdManager * table, @@ -617,18 +574,16 @@ cuddCacheLookup2Zdd( } /* end of cuddCacheLookup2Zdd */ -/**Function******************************************************************** - - Synopsis [Looks up in the cache for the result of op applied to f.] +/** + @brief Looks up in the cache for the result of op applied to f. - Description [Returns the result if found; it returns NULL if no - result is found.] + @return the result if found; it returns NULL if no result is found. - SideEffects [None] + @sideeffect None - SeeAlso [cuddCacheLookupZdd cuddCacheLookup2Zdd] + @see cuddCacheLookupZdd cuddCacheLookup2Zdd -******************************************************************************/ +*/ DdNode * cuddCacheLookup1Zdd( DdManager * table, @@ -670,22 +625,22 @@ cuddCacheLookup1Zdd( } /* end of cuddCacheLookup1Zdd */ -/**Function******************************************************************** +/** + @brief Looks up in the cache for the result of op applied to f, + g, and h. - Synopsis [Looks up in the cache for the result of op applied to f, - g, and h.] - - Description [Looks up in the cache for the result of op applied to f, - g, and h. Assumes that the calling procedure (e.g., + @details Assumes that the calling procedure (e.g., Cudd_bddIteConstant) is only interested in whether the result is - constant or not. Returns the result if found (possibly - DD_NON_CONSTANT); otherwise it returns NULL.] + constant or not. + + @return the result if found (possibly DD_NON_CONSTANT); otherwise it + returns NULL. - SideEffects [None] + @sideeffect None - SeeAlso [cuddCacheLookup] + @see cuddCacheLookup -******************************************************************************/ +*/ DdNode * cuddConstantLookup( DdManager * table, @@ -733,18 +688,14 @@ cuddConstantLookup( } /* end of cuddConstantLookup */ -/**Function******************************************************************** +/** + @brief Computes and prints a profile of the cache usage. - Synopsis [Computes and prints a profile of the cache usage.] + @return 1 if successful; 0 otherwise. - Description [Computes and prints a profile of the cache usage. - Returns 1 if successful; 0 otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ int cuddCacheProfile( DdManager * table, @@ -874,17 +825,12 @@ cuddCacheProfile( } /* end of cuddCacheProfile */ -/**Function******************************************************************** - - Synopsis [Resizes the cache.] +/** + @brief Resizes the cache. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ void cuddCacheResize( DdManager * table) @@ -917,7 +863,7 @@ cuddCacheResize( #endif saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = table->outOfMemCallback; table->acache = cache = ALLOC(DdCache,slots+1); MMoutOfMemory = saveHandler; /* If we fail to allocate the new table we just give up. */ @@ -989,17 +935,12 @@ cuddCacheResize( } /* end of cuddCacheResize */ -/**Function******************************************************************** - - Synopsis [Flushes the cache.] - - Description [] +/** + @brief Flushes the cache. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ void cuddCacheFlush( DdManager * table) @@ -1020,18 +961,14 @@ cuddCacheFlush( } /* end of cuddCacheFlush */ -/**Function******************************************************************** - - Synopsis [Returns the floor of the logarithm to the base 2.] - - Description [Returns the floor of the logarithm to the base 2. - The input value is assumed to be greater than 0.] +/** + @brief Returns the floor of the logarithm to the base 2. - SideEffects [None] + @details The input value is assumed to be greater than 0. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int cuddComputeFloorLog2( unsigned int value) diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddCheck.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddCheck.c similarity index 76% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddCheck.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddCheck.c index 424aaba39..2026f1246 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddCheck.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddCheck.c @@ -1,33 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddCheck.c] + @ingroup cudd - PackageName [cudd] + @brief Functions to check consistency of data structures. - Synopsis [Functions to check consistency of data structures.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_DebugCheck() - <li> Cudd_CheckKeys() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddHeapProfile() - <li> cuddPrintNode() - <li> cuddPrintVarGroups() - </ul> - Static procedures included in this module: - <ul> - <li> debugFindParent() - </ul> - ] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -57,11 +38,13 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" +#include "mtrInt.h" #include "cuddInt.h" /*---------------------------------------------------------------------------*/ @@ -83,16 +66,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddCheck.c,v 1.37 2012/02/05 01:07:18 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -103,7 +82,7 @@ static void debugFindParent (DdManager *table, DdNode *node); static void debugCheckParent (DdManager *table, DdNode *node); #endif -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -111,29 +90,29 @@ static void debugCheckParent (DdManager *table, DdNode *node); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Checks for inconsistencies in the DD heap.] +/** + @brief Checks for inconsistencies in the %DD heap. - Description [Checks for inconsistencies in the DD heap: + @details The following inconsistencies are checked: <ul> <li> node has illegal index <li> live node has dead children <li> node has illegal Then or Else pointers - <li> BDD/ADD node has identical children - <li> ZDD node has zero then child + <li> %BDD/%ADD node has identical children + <li> %ZDD node has zero then child <li> wrong number of total nodes <li> wrong number of dead nodes <li> ref count error at node </ul> - Returns 0 if no inconsistencies are found; DD_OUT_OF_MEM if there is - not enough memory; 1 otherwise.] + + @return 0 if no inconsistencies are found; DD_OUT_OF_MEM if there is + not enough memory; 1 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_CheckKeys] + @see Cudd_CheckKeys -******************************************************************************/ +*/ int Cudd_DebugCheck( DdManager * table) @@ -206,7 +185,7 @@ Cudd_DebugCheck( cuddPrintNode(f,table->err); flag =1; } - if (ddHash(cuddT(f),cuddE(f),shift) != j) { + if (ddHash(cuddT(f),cuddE(f),shift) != (unsigned) j) { (void) fprintf(table->err, "Error: misplaced node\n"); cuddPrintNode(f,table->err); flag =1; @@ -214,13 +193,13 @@ Cudd_DebugCheck( /* Increment the internal reference count for the ** then child of the current node. */ - if (st_lookup_int(edgeTable,(char *)cuddT(f),&count)) { + if (st_lookup_int(edgeTable,cuddT(f),&count)) { count++; } else { count = 1; } - if (st_insert(edgeTable,(char *)cuddT(f), - (char *)(long)count) == ST_OUT_OF_MEM) { + if (st_insert(edgeTable,cuddT(f), + (void *)(ptruint)count) == ST_OUT_OF_MEM) { st_free_table(edgeTable); return(CUDD_OUT_OF_MEM); } @@ -228,14 +207,14 @@ Cudd_DebugCheck( /* Increment the internal reference count for the ** else child of the current node. */ - if (st_lookup_int(edgeTable,(char *)Cudd_Regular(cuddE(f)), + if (st_lookup_int(edgeTable,Cudd_Regular(cuddE(f)), &count)) { count++; } else { count = 1; } - if (st_insert(edgeTable,(char *)Cudd_Regular(cuddE(f)), - (char *)(long)count) == ST_OUT_OF_MEM) { + if (st_insert(edgeTable,Cudd_Regular(cuddE(f)), + (void *)(ptruint)count) == ST_OUT_OF_MEM) { st_free_table(edgeTable); return(CUDD_OUT_OF_MEM); } @@ -320,13 +299,13 @@ Cudd_DebugCheck( /* Increment the internal reference count for the ** then child of the current node. */ - if (st_lookup_int(edgeTable,(char *)cuddT(f),&count)) { + if (st_lookup_int(edgeTable,cuddT(f),&count)) { count++; } else { count = 1; } - if (st_insert(edgeTable,(char *)cuddT(f), - (char *)(long)count) == ST_OUT_OF_MEM) { + if (st_insert(edgeTable,cuddT(f), + (void *)(ptruint)count) == ST_OUT_OF_MEM) { st_free_table(edgeTable); return(CUDD_OUT_OF_MEM); } @@ -334,13 +313,13 @@ Cudd_DebugCheck( /* Increment the internal reference count for the ** else child of the current node. */ - if (st_lookup_int(edgeTable,(char *)cuddE(f),&count)) { + if (st_lookup_int(edgeTable,cuddE(f),&count)) { count++; } else { count = 1; } - if (st_insert(edgeTable,(char *)cuddE(f), - (char *)(long)count) == ST_OUT_OF_MEM) { + if (st_insert(edgeTable,cuddE(f), + (void *)(ptruint)count) == ST_OUT_OF_MEM) { st_free_table(edgeTable); table->errorCode = CUDD_MEMORY_OUT; return(CUDD_OUT_OF_MEM); @@ -386,15 +365,9 @@ Cudd_DebugCheck( if (f->ref != 0) { if (f->index != CUDD_CONST_INDEX) { fprintf(table->err,"Error: node has illegal index\n"); -#if SIZEOF_VOID_P == 8 - fprintf(table->err, - " node 0x%lx, id = %u, ref = %u, value = %g\n", - (ptruint)f,f->index,f->ref,cuddV(f)); -#else fprintf(table->err, - " node 0x%x, id = %hu, ref = %hu, value = %g\n", + " node 0x%" PRIxPTR ", id = %u, ref = %u, value = %g\n", (ptruint)f,f->index,f->ref,cuddV(f)); -#endif flag = 1; } } else { @@ -414,13 +387,10 @@ Cudd_DebugCheck( flag = 1; } gen = st_init_gen(edgeTable); - while (st_gen(gen, &f, &count)) { + while (st_gen_int(gen, (void **) &f, &count)) { if (count > (int)(f->ref) && f->ref != DD_MAXREF) { -#if SIZEOF_VOID_P == 8 - fprintf(table->err,"ref count error at node 0x%lx, count = %d, id = %u, ref = %u, then = 0x%lx, else = 0x%lx\n",(ptruint)f,count,f->index,f->ref,(ptruint)cuddT(f),(ptruint)cuddE(f)); -#else - fprintf(table->err,"ref count error at node 0x%x, count = %d, id = %hu, ref = %hu, then = 0x%x, else = 0x%x\n",(ptruint)f,count,f->index,f->ref,(ptruint)cuddT(f),(ptruint)cuddE(f)); -#endif + fprintf(table->err,"ref count error at node 0x%" PRIxPTR ", count = %d, id = %u, ref = %u, then = 0x%" PRIxPTR ", else = 0x%" PRIxPTR "\n", + (ptruint)f,count,f->index,f->ref,(ptruint)cuddT(f),(ptruint)cuddE(f)); debugFindParent(table,f); flag = 1; } @@ -433,11 +403,10 @@ Cudd_DebugCheck( } /* end of Cudd_DebugCheck */ -/**Function******************************************************************** - - Synopsis [Checks for several conditions that should not occur.] +/** + @brief Checks for several conditions that should not occur. - Description [Checks for the following conditions: + @details Checks for the following conditions: <ul> <li>Wrong sizes of subtables. <li>Wrong number of keys found in unique subtable. @@ -448,14 +417,16 @@ Cudd_DebugCheck( <li>Wrong number of maximum keys found <li>Wrong number of total dead found </ul> - Reports the average length of non-empty lists. Returns the number of - subtables for which the number of keys is wrong.] + Reports the average length of non-empty lists. - SideEffects [None] + @return the number of subtables for which the number of keys is + wrong. - SeeAlso [Cudd_DebugCheck] + @sideeffect None -******************************************************************************/ + @see Cudd_DebugCheck + +*/ int Cudd_CheckKeys( DdManager * table) @@ -615,12 +586,11 @@ in the constant table (difference=%d)\n", dead); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Prints information about the heap.] +/** + @brief Prints information about the heap. - Description [Prints to the manager's stdout the number of live nodes for each - level of the DD heap that contains at least one live node. It also + @details Prints to the manager's stdout the number of live nodes for each + level of the %DD heap that contains at least one live node. It also prints a summary containing: <ul> <li> total number of tables; @@ -629,14 +599,13 @@ in the constant table (difference=%d)\n", dead); <li> number of nodes in that table. </ul> If more than one table contains the maximum number of live nodes, - only the one of lowest index is reported. Returns 1 in case of success - and 0 otherwise.] + only the one of lowest index is reported. - SideEffects [None] + @return 1 in case of success and 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int cuddHeapProfile( DdManager * dd) @@ -651,13 +620,8 @@ cuddHeapProfile( nonempty = 0; /* number of tables with live nodes */ /* Print header. */ -#if SIZEOF_VOID_P == 8 - retval = fprintf(dd->out,"*** DD heap profile for 0x%lx ***\n", - (ptruint) dd); -#else - retval = fprintf(dd->out,"*** DD heap profile for 0x%x ***\n", + retval = fprintf(dd->out,"*** DD heap profile for 0x%" PRIxPTR " ***\n", (ptruint) dd); -#endif if (retval == EOF) return 0; /* Print number of live nodes for each nonempty table. */ @@ -697,40 +661,29 @@ cuddHeapProfile( } /* end of cuddHeapProfile */ -/**Function******************************************************************** - - Synopsis [Prints out information on a node.] - - Description [Prints out information on a node.] - - SideEffects [None] +/** + @brief Prints out information on a node. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ void cuddPrintNode( DdNode * f, FILE *fp) { f = Cudd_Regular(f); -#if SIZEOF_VOID_P == 8 - (void) fprintf(fp," node 0x%lx, id = %u, ref = %u, then = 0x%lx, else = 0x%lx\n",(ptruint)f,f->index,f->ref,(ptruint)cuddT(f),(ptruint)cuddE(f)); -#else - (void) fprintf(fp," node 0x%x, id = %hu, ref = %hu, then = 0x%x, else = 0x%x\n",(ptruint)f,f->index,f->ref,(ptruint)cuddT(f),(ptruint)cuddE(f)); -#endif + (void) fprintf(fp," node 0x%" PRIxPTR ", id = %u, ref = %u, then = 0x%" PRIxPTR ", else = 0x%" PRIxPTR "\n", + (ptruint)f,f->index,f->ref,(ptruint)cuddT(f),(ptruint)cuddE(f)); } /* end of cuddPrintNode */ +/** + @brief Prints the variable groups as a parenthesized list. -/**Function******************************************************************** - - Synopsis [Prints the variable groups as a parenthesized list.] - - Description [Prints the variable groups as a parenthesized list. - For each group the level range that it represents is printed. After - each group, the group's flags are printed, preceded by a `|'. For + @details For each group the level range that it represents is printed. + After each group, the group's flags are printed, preceded by a `|'. For each flag (except MTR_TERMINAL) a character is printed. <ul> <li>F: MTR_FIXED @@ -738,19 +691,17 @@ cuddPrintNode( <li>S: MTR_SOFT </ul> The second argument, silent, if different from 0, causes - Cudd_PrintVarGroups to only check the syntax of the group tree.] + Cudd_PrintVarGroups to only check the syntax of the group tree. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ void cuddPrintVarGroups( - DdManager * dd /* manager */, - MtrNode * root /* root of the group tree */, - int zdd /* 0: BDD; 1: ZDD */, - int silent /* flag to check tree syntax only */) + DdManager * dd /**< manager */, + MtrNode * root /**< root of the group tree */, + int zdd /**< 0: %BDD; 1: %ZDD */, + int silent /**< flag to check tree syntax only */) { MtrNode *node; int level; @@ -797,17 +748,12 @@ cuddPrintVarGroups( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Searches the subtables above node for its parents.] - - Description [] - - SideEffects [None] +/** + @brief Searches the subtables above node for its parents. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static void debugFindParent( DdManager * table, @@ -826,13 +772,8 @@ debugFindParent( f = nodelist[j]; while (f != NULL) { if (cuddT(f) == node || Cudd_Regular(cuddE(f)) == node) { -#if SIZEOF_VOID_P == 8 - (void) fprintf(table->out,"parent is at 0x%lx, id = %u, ref = %u, then = 0x%lx, else = 0x%lx\n", + (void) fprintf(table->out,"parent is at 0x%" PRIxPTR ", id = %u, ref = %u, then = 0x%" PRIxPTR ", else = 0x%" PRIxPTR "\n", (ptruint)f,f->index,f->ref,(ptruint)cuddT(f),(ptruint)cuddE(f)); -#else - (void) fprintf(table->out,"parent is at 0x%x, id = %hu, ref = %hu, then = 0x%x, else = 0x%x\n", - (ptruint)f,f->index,f->ref,(ptruint)cuddT(f),(ptruint)cuddE(f)); -#endif } f = f->next; } @@ -843,18 +784,17 @@ debugFindParent( #if 0 -/**Function******************************************************************** - - Synopsis [Reports an error if a (dead) node has a non-dead parent.] +/** + @brief Reports an error if a (dead) node has a non-dead parent. - Description [Searches all the subtables above node. Very expensive. - The same check is now implemented more efficiently in ddDebugCheck.] + @details Searches all the subtables above node. Very expensive. + The same check is now implemented more efficiently in ddDebugCheck. - SideEffects [None] + @sideeffect None - SeeAlso [debugFindParent] + @see debugFindParent -******************************************************************************/ +*/ static void debugCheckParent( DdManager * table, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddClip.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddClip.c similarity index 68% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddClip.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddClip.c index 2993254ff..e9fa7989a 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddClip.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddClip.c @@ -1,32 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddClip.c] + @ingroup cudd - PackageName [cudd] + @brief Clipping functions. - Synopsis [Clipping functions.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_bddClippingAnd() - <li> Cudd_bddClippingAndAbstract() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddClippingAnd() - <li> cuddBddClippingAndAbstract() - </ul> - Static procedures included in this module: - <ul> - <li> cuddBddClippingAndRecur() - <li> cuddBddClipAndAbsRecur() - </ul> - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -56,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -82,16 +65,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddClip.c,v 1.9 2012/02/05 01:07:18 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -100,7 +79,7 @@ static char rcsid[] DD_UNUSED = "$Id: cuddClip.c,v 1.9 2012/02/05 01:07:18 fabio static DdNode * cuddBddClippingAndRecur (DdManager *manager, DdNode *f, DdNode *g, int distance, int direction); static DdNode * cuddBddClipAndAbsRecur (DdManager *manager, DdNode *f, DdNode *g, DdNode *cube, int distance, int direction); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -108,26 +87,24 @@ static DdNode * cuddBddClipAndAbsRecur (DdManager *manager, DdNode *f, DdNode *g /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Approximates the conjunction of two BDDs f and g.] +/** + @brief Approximates the conjunction of two BDDs f and g. - Description [Approximates the conjunction of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddAnd] + @see Cudd_bddAnd -******************************************************************************/ +*/ DdNode * Cudd_bddClippingAnd( - DdManager * dd /* manager */, - DdNode * f /* first conjunct */, - DdNode * g /* second conjunct */, - int maxDepth /* maximum recursion depth */, - int direction /* under (0) or over (1) approximation */) + DdManager * dd /**< manager */, + DdNode * f /**< first conjunct */, + DdNode * g /**< second conjunct */, + int maxDepth /**< maximum recursion depth */, + int direction /**< under (0) or over (1) approximation */) { DdNode *res; @@ -135,34 +112,36 @@ Cudd_bddClippingAnd( dd->reordered = 0; res = cuddBddClippingAnd(dd,f,g,maxDepth,direction); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddClippingAnd */ -/**Function******************************************************************** +/** + @brief Approximates the conjunction of two BDDs f and g and + simultaneously abstracts the variables in cube. - Synopsis [Approximates the conjunction of two BDDs f and g and - simultaneously abstracts the variables in cube.] + @details The variables are existentially abstracted. - Description [Approximates the conjunction of two BDDs f and g and - simultaneously abstracts the variables in cube. The variables are - existentially abstracted. Returns a pointer to the resulting BDD if - successful; NULL if the intermediate result blows up.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddAndAbstract Cudd_bddClippingAnd] + @see Cudd_bddAndAbstract Cudd_bddClippingAnd -******************************************************************************/ +*/ DdNode * Cudd_bddClippingAndAbstract( - DdManager * dd /* manager */, - DdNode * f /* first conjunct */, - DdNode * g /* second conjunct */, - DdNode * cube /* cube of variables to be abstracted */, - int maxDepth /* maximum recursion depth */, - int direction /* under (0) or over (1) approximation */) + DdManager * dd /**< manager */, + DdNode * f /**< first conjunct */, + DdNode * g /**< second conjunct */, + DdNode * cube /**< cube of variables to be abstracted */, + int maxDepth /**< maximum recursion depth */, + int direction /**< under (0) or over (1) approximation */) { DdNode *res; @@ -170,6 +149,9 @@ Cudd_bddClippingAndAbstract( dd->reordered = 0; res = cuddBddClippingAndAbstract(dd,f,g,cube,maxDepth,direction); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddClippingAndAbstract */ @@ -180,26 +162,24 @@ Cudd_bddClippingAndAbstract( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Approximates the conjunction of two BDDs f and g.] +/** + @brief Approximates the conjunction of two BDDs f and g. - Description [Approximates the conjunction of two BDDs f and g. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddClippingAnd] + @see Cudd_bddClippingAnd -******************************************************************************/ +*/ DdNode * cuddBddClippingAnd( - DdManager * dd /* manager */, - DdNode * f /* first conjunct */, - DdNode * g /* second conjunct */, - int maxDepth /* maximum recursion depth */, - int direction /* under (0) or over (1) approximation */) + DdManager * dd /**< manager */, + DdNode * f /**< first conjunct */, + DdNode * g /**< second conjunct */, + int maxDepth /**< maximum recursion depth */, + int direction /**< under (0) or over (1) approximation */) { DdNode *res; @@ -210,29 +190,26 @@ cuddBddClippingAnd( } /* end of cuddBddClippingAnd */ -/**Function******************************************************************** - - Synopsis [Approximates the conjunction of two BDDs f and g and - simultaneously abstracts the variables in cube.] +/** + @brief Approximates the conjunction of two BDDs f and g and + simultaneously abstracts the variables in cube. - Description [Approximates the conjunction of two BDDs f and g and - simultaneously abstracts the variables in cube. Returns a - pointer to the resulting BDD if successful; NULL if the intermediate - result blows up.] + @return a pointer to the resulting %BDD if successful; NULL if the + intermediate result blows up. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddClippingAndAbstract] + @see Cudd_bddClippingAndAbstract -******************************************************************************/ +*/ DdNode * cuddBddClippingAndAbstract( - DdManager * dd /* manager */, - DdNode * f /* first conjunct */, - DdNode * g /* second conjunct */, - DdNode * cube /* cube of variables to be abstracted */, - int maxDepth /* maximum recursion depth */, - int direction /* under (0) or over (1) approximation */) + DdManager * dd /**< manager */, + DdNode * f /**< first conjunct */, + DdNode * g /**< second conjunct */, + DdNode * cube /**< cube of variables to be abstracted */, + int maxDepth /**< maximum recursion depth */, + int direction /**< under (0) or over (1) approximation */) { DdNode *res; @@ -248,19 +225,18 @@ cuddBddClippingAndAbstract( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Implements the recursive step of Cudd_bddClippingAnd. - Synopsis [Implements the recursive step of Cudd_bddClippingAnd.] + @details Takes the conjunction of two BDDs. - Description [Implements the recursive step of Cudd_bddClippingAnd by taking - the conjunction of two BDDs. Returns a pointer to the result is - successful; NULL otherwise.] + @return a pointer to the result is successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddBddClippingAnd] + @see cuddBddClippingAnd -******************************************************************************/ +*/ static DdNode * cuddBddClippingAndRecur( DdManager * manager, @@ -271,7 +247,8 @@ cuddBddClippingAndRecur( { DdNode *F, *ft, *fe, *G, *gt, *ge; DdNode *one, *zero, *r, *t, *e; - unsigned int topf, topg, index; + int topf, topg; + unsigned int index; DD_CTFP cacheOp; statLine(manager); @@ -312,6 +289,8 @@ cuddBddClippingAndRecur( if (r != NULL) return(r); } + checkWhetherToGiveUp(manager); + /* Here we can skip the use of cuddI, because the operands are known ** to be non-constant. */ @@ -382,21 +361,19 @@ cuddBddClippingAndRecur( } /* end of cuddBddClippingAndRecur */ -/**Function******************************************************************** +/** + @brief Approximates the AND of two BDDs and simultaneously abstracts the + variables in cube. - Synopsis [Approximates the AND of two BDDs and simultaneously abstracts the - variables in cube.] + @details The variables are existentially abstracted. - Description [Approximates the AND of two BDDs and simultaneously - abstracts the variables in cube. The variables are existentially - abstracted. Returns a pointer to the result is successful; NULL - otherwise.] + @return a pointer to the result is successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddClippingAndAbstract] + @see Cudd_bddClippingAndAbstract -******************************************************************************/ +*/ static DdNode * cuddBddClipAndAbsRecur( DdManager * manager, @@ -408,7 +385,8 @@ cuddBddClipAndAbsRecur( { DdNode *F, *ft, *fe, *G, *gt, *ge; DdNode *one, *zero, *r, *t, *e, *Cube; - unsigned int topf, topg, topcube, top, index; + int topf, topg, topcube, top; + unsigned int index; ptruint cacheTag; statLine(manager); @@ -449,6 +427,8 @@ cuddBddClipAndAbsRecur( } } + checkWhetherToGiveUp(manager); + /* Here we can skip the use of cuddI, because the operands are known ** to be non-constant. */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddCof.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddCof.c similarity index 51% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddCof.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddCof.c index cff47b20a..90603a5cf 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddCof.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddCof.c @@ -1,28 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddCof.c] + @ingroup cudd - PackageName [cudd] + @brief Cofactoring functions. - Synopsis [Cofactoring functions.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_Cofactor() - <li> Cudd_CheckCube() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddGetBranches() - <li> cuddCofactorRecur() - </ul> - ] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -52,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -78,23 +65,21 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddCof.c,v 1.11 2012/02/05 01:07:18 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ +static int ddVarsAreSymmetricBefore(DdManager * dd, DdNode * f, DdNode * var1, DdNode * var2); +static int ddVarsAreSymmetricBetween(DdManager * dd, DdNode * f1, DdNode * f0, DdNode * var2); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -102,19 +87,18 @@ static char rcsid[] DD_UNUSED = "$Id: cuddCof.c,v 1.11 2012/02/05 01:07:18 fabio /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Computes the cofactor of f with respect to g. - Synopsis [Computes the cofactor of f with respect to g.] + @details g must be the %BDD or the %ADD of a cube. - Description [Computes the cofactor of f with respect to g; g must be - the BDD or the ADD of a cube. Returns a pointer to the cofactor if - successful; NULL otherwise.] + @return a pointer to the cofactor if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddConstrain Cudd_bddRestrict] + @see Cudd_bddConstrain Cudd_bddRestrict -******************************************************************************/ +*/ DdNode * Cudd_Cofactor( DdManager * dd, @@ -133,24 +117,25 @@ Cudd_Cofactor( dd->reordered = 0; res = cuddCofactorRecur(dd,f,g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_Cofactor */ -/**Function******************************************************************** - - Synopsis [Checks whether g is the BDD of a cube.] +/** + @brief Checks whether g is the %BDD of a cube. - Description [Checks whether g is the BDD of a cube. Returns 1 in case - of success; 0 otherwise. The constant 1 is a valid cube, but all other - constant functions cause cuddCheckCube to return 0.] + @details The constant 1 is a valid cube, but all other constant + functions cause cuddCheckCube to return 0. - SideEffects [None] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Cudd_CheckCube( DdManager * dd, @@ -160,7 +145,7 @@ Cudd_CheckCube( one = DD_ONE(dd); if (g == one) return(1); - if (Cudd_IsConstant(g)) return(0); + if (Cudd_Not(g) == one) return(0); zero = Cudd_Not(one); cuddGetBranches(g,&g1,&g0); @@ -176,22 +161,66 @@ Cudd_CheckCube( } /* end of Cudd_CheckCube */ -/*---------------------------------------------------------------------------*/ -/* Definition of internal functions */ -/*---------------------------------------------------------------------------*/ +/** + @brief Checks whether two variables are symmetric in a BDD. + + @return 1 if the variables are symmetric; 0 if they are not. + + @details No nodes are built during the check. + + @sideeffect None +*/ +int +Cudd_VarsAreSymmetric( + DdManager * dd /**< manager */, + DdNode * f /**< BDD whose variables are tested */, + int index1 /**< index of first variable */, + int index2 /**< index of second variable */) +{ + DdNode *var1, *var2; + + if (index1 == index2) /* trivial case: symmetry is reflexive */ + return(1); + + if (index1 >= dd->size) { + if (index2 >= dd->size) { + return(1); /* f depends on neither variable */ + } else { + /* f does not depend on var1; check whether it depends on var2 */ + var2 = dd->vars[index2]; + return ddVarsAreSymmetricBetween(dd, f, f, var2); + } + } else if (index2 >= dd->size) { + /* f does not depend on var2; check whether it depends on var1 */ + var1 = dd->vars[index1]; + return ddVarsAreSymmetricBetween(dd, f, f, var1); + } + /* Make sure index1 denotes the variable currently closer to the root. */ + if (dd->perm[index1] < dd->perm[index2]) { + var1 = dd->vars[index1]; + var2 = dd->vars[index2]; + } else { + var1 = dd->vars[index2]; + var2 = dd->vars[index1]; + } + + return ddVarsAreSymmetricBefore(dd, f, var1, var2); + +} /* end of Cudd_VarsAreSymmetric */ -/**Function******************************************************************** - Synopsis [Computes the children of g.] +/*---------------------------------------------------------------------------*/ +/* Definition of internal functions */ +/*---------------------------------------------------------------------------*/ - Description [] - SideEffects [None] +/** + @brief Computes the children of g. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ void cuddGetBranches( DdNode * g, @@ -210,18 +239,16 @@ cuddGetBranches( } /* end of cuddGetBranches */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_Cofactor.] +/** + @brief Performs the recursive step of Cudd_Cofactor. - Description [Performs the recursive step of Cudd_Cofactor. Returns a - pointer to the cofactor if successful; NULL otherwise.] + @return a pointer to the cofactor if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Cofactor] + @see Cudd_Cofactor -******************************************************************************/ +*/ DdNode * cuddCofactorRecur( DdManager * dd, @@ -229,7 +256,7 @@ cuddCofactorRecur( DdNode * g) { DdNode *one,*zero,*F,*G,*g1,*g0,*f1,*f0,*t,*e,*r; - unsigned int topf,topg; + int topf,topg; int comple; statLine(dd); @@ -251,6 +278,8 @@ cuddCofactorRecur( return(Cudd_NotCond(r,comple)); } + checkWhetherToGiveUp(dd); + topf = dd->perm[F->index]; G = Cudd_Regular(g); topg = dd->perm[G->index]; @@ -279,7 +308,7 @@ cuddCofactorRecur( } else if (g1 == zero || g1 == DD_ZERO(dd)) { r = cuddCofactorRecur(dd, f0, g0); } else { - (void) fprintf(dd->out, + (void) fprintf(dd->err, "Cudd_Cofactor: Invalid restriction 2\n"); dd->errorCode = CUDD_INVALID_ARG; return(NULL); @@ -325,3 +354,144 @@ cuddCofactorRecur( /* Definition of static functions */ /*---------------------------------------------------------------------------*/ +/** + @brief Implements the upper recursive step of Cudd_VarsAreSymmetric(). + + @details The assumption is made that the level of index1 is less + than the level of index2. + + @return 1 if the variables are symmetric for the given function; + 0 if they are not. + + @see Cudd_VarsAreSymmetric ddVarsAreSymmetricBetween + +*/ +static int +ddVarsAreSymmetricBefore( + DdManager * dd, + DdNode * f, + DdNode * var1, + DdNode * var2) +{ + DdNode *F, *ft, *fe, *r; + int top, res, level1; + + statLine(dd); + F = Cudd_Regular(f); + if (cuddIsConstant(F)) /* f depends on neither variable */ + return(1); + top = dd->perm[F->index]; + if (top > dd->perm[var2->index]) + return(1); /* f depends on neither variable */ + /* Cache lookup. We take advantage of the observation that + * var1 and var2 are symmetric in f iff they are symmetric in + * the complement of f. */ + r = cuddCacheLookup(dd, DD_VARS_SYMM_BEFORE_TAG, F, var1, var2); + if (r != NULL) { + return(r == DD_ONE(dd) ? 1 : 0); + } + level1 = dd->perm[var1->index]; + if (top > level1) + /* Check whether f1 depends on the variable currently at level2. */ + return ddVarsAreSymmetricBetween(dd, f, f, var2); + ft = cuddT(F); + fe = cuddE(F); + if (F != f) { + ft = Cudd_Not(ft); + fe = Cudd_Not(fe); + } + if (top < level1) { + res = ddVarsAreSymmetricBefore(dd, ft, var1, var2); + if (res) + res = ddVarsAreSymmetricBefore(dd, fe, var1, var2); + } else { + res = ddVarsAreSymmetricBetween(dd, ft, fe, var2); + } + /* Cache insertion. */ + cuddCacheInsert(dd, DD_VARS_SYMM_BEFORE_TAG, F, var1, var2, + res ? DD_ONE(dd) : Cudd_Not(DD_ONE(dd))); + return(res); + +} /* end of ddVarsAreSymmetricBefore */ + + +/** + @brief Implements the lower recursive step of Cudd_VarsAreSymmetric(). + + @return 1 if the negative cofactor of the first argument w.r.t. the variable + currently at level2 is the same as the positive cofactor of the second + argument; 0 if the two cofactors are not the same. + + @see Cudd_VarsAreSymmetric ddVarsAreSymmetricBefore + +*/ +static int +ddVarsAreSymmetricBetween( + DdManager * dd, + DdNode * f1, + DdNode * f0, + DdNode * var2) +{ + DdNode *F1, *F0, *f1t, *f1e, *f0t, *f0e, *r; + int topf1, topf0, top, res; + int level2 = dd->perm[var2->index]; + + statLine(dd); + F1 = Cudd_Regular(f1); + F0 = Cudd_Regular(f0); + if (cuddIsConstant(F1) && cuddIsConstant(F0)) + return f1 == f0; + /* Here we know that one of f1 and f0 is not constant. Hence the + * least index is that of a variable. */ + if (cuddIsConstant(F1)) + topf1 = CUDD_CONST_INDEX; + else + topf1 = dd->perm[F1->index]; + if (cuddIsConstant(F0)) + topf0 = CUDD_CONST_INDEX; + else + topf0 = dd->perm[F0->index]; + if (topf0 > level2 && topf1 > level2) + return(f1 == f0); + /* Cache lookup. */ + r = cuddCacheLookup(dd, DD_VARS_SYMM_BETWEEN_TAG, f1, f0, var2); + if (r != NULL) { + return(r == DD_ONE(dd) ? 1 : 0); + } + /* Compute cofactors and find top level. */ + if (topf1 <= topf0) { + top = topf1; + f1t = cuddT(F1); + f1e = cuddE(F1); + if (F1 != f1) { + f1t = Cudd_Not(f1t); + f1e = Cudd_Not(f1e); + } + } else { + top = topf0; + f1t = f1e = f1; + } + if (topf0 <= topf1) { + f0t = cuddT(F0); + f0e = cuddE(F0); + if (F0 != f0) { + f0t = Cudd_Not(f0t); + f0e = Cudd_Not(f0e); + } + } else { + f0t = f0e = f0; + } + if (top < level2) { + res = ddVarsAreSymmetricBetween(dd, f1t, f0t, var2); + if (res) + res = ddVarsAreSymmetricBetween(dd, f1e, f0e, var2); + } else { + assert(top == level2); + res = f1e == f0t; + } + /* Cache insertion. */ + cuddCacheInsert(dd, DD_VARS_SYMM_BETWEEN_TAG, f1, f0, var2, + res ? DD_ONE(dd) : Cudd_Not(DD_ONE(dd))); + return(res); + +} /* end of ddVarsAreSymmetricBetween */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddCompose.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddCompose.c similarity index 69% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddCompose.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddCompose.c index eea044f59..cdcb5a6c8 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddCompose.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddCompose.c @@ -1,54 +1,21 @@ -/**CFile*********************************************************************** - - FileName [cuddCompose.c] - - PackageName [cudd] - - Synopsis [Functional composition and variable permutation of DDs.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_bddCompose() - <li> Cudd_addCompose() - <li> Cudd_addPermute() - <li> Cudd_addSwapVariables() - <li> Cudd_bddPermute() - <li> Cudd_bddVarMap() - <li> Cudd_SetVarMap() - <li> Cudd_bddSwapVariables() - <li> Cudd_bddAdjPermuteX() - <li> Cudd_addVectorCompose() - <li> Cudd_addGeneralVectorCompose() - <li> Cudd_addNonSimCompose() - <li> Cudd_bddVectorCompose() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddComposeRecur() - <li> cuddAddComposeRecur() - </ul> - Static procedures included in this module: - <ul> - <li> cuddAddPermuteRecur() - <li> cuddBddPermuteRecur() - <li> cuddBddVarMapRecur() - <li> cuddAddVectorComposeRecur() - <li> cuddAddGeneralVectorComposeRecur() - <li> cuddAddNonSimComposeRecur() - <li> cuddBddVectorComposeRecur() - <li> ddIsIthAddVar() - <li> ddIsIthAddVarPair() - </ul> - The permutation functions use a local cache because the results to - be remembered depend on the permutation being applied. Since the - permutation is just an array, it cannot be stored in the global - cache. There are different procedured for BDDs and ADDs. This is - because bddPermuteRecur uses cuddBddIteRecur. If this were changed, - the procedures could be merged.] - - Author [Fabio Somenzi and Kavita Ravi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Functional composition and variable permutation of DDs. + + @details The permutation functions use a local cache because the + results to be remembered depend on the permutation being applied. + Since the permutation is just an array, it cannot be stored in the + global cache. There are different procedured for BDDs and ADDs. This + is because bddPermuteRecur uses cuddBddIteRecur. If this were + changed, the procedures could be merged. + + @author Fabio Somenzi and Kavita Ravi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -78,14 +45,14 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" - /*---------------------------------------------------------------------------*/ /* Constant declarations */ /*---------------------------------------------------------------------------*/ @@ -102,25 +69,11 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddCompose.c,v 1.46 2012/02/05 01:07:18 fabio Exp $"; -#endif - -#ifdef DD_DEBUG -static int addPermuteRecurHits; -static int bddPermuteRecurHits; -static int bddVectorComposeHits; -static int addVectorComposeHits; - -static int addGeneralVectorComposeHits; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -132,12 +85,12 @@ static DdNode * cuddBddVarMapRecur (DdManager *manager, DdNode *f); static DdNode * cuddAddVectorComposeRecur (DdManager *dd, DdHashTable *table, DdNode *f, DdNode **vector, int deepest); static DdNode * cuddAddNonSimComposeRecur (DdManager *dd, DdNode *f, DdNode **vector, DdNode *key, DdNode *cube, int lastsub); static DdNode * cuddBddVectorComposeRecur (DdManager *dd, DdHashTable *table, DdNode *f, DdNode **vector, int deepest); -DD_INLINE static int ddIsIthAddVar (DdManager *dd, DdNode *f, unsigned int i); +static int ddIsIthAddVar (DdManager *dd, DdNode *f, unsigned int i); static DdNode * cuddAddGeneralVectorComposeRecur (DdManager *dd, DdHashTable *table, DdNode *f, DdNode **vectorOn, DdNode **vectorOff, int deepest); -DD_INLINE static int ddIsIthAddVarPair (DdManager *dd, DdNode *f, DdNode *g, unsigned int i); +static int ddIsIthAddVarPair (DdManager *dd, DdNode *f, DdNode *g, unsigned int i); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -145,20 +98,20 @@ DD_INLINE static int ddIsIthAddVarPair (DdManager *dd, DdNode *f, DdNode *g, uns /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Substitutes g for x_v in the %BDD for f. - Synopsis [Substitutes g for x_v in the BDD for f.] + @details v is the index of the variable to be substituted. + Cudd_bddCompose passes the corresponding projection function to the + recursive procedure, so that the cache may be used. - Description [Substitutes g for x_v in the BDD for f. v is the index of the - variable to be substituted. Cudd_bddCompose passes the corresponding - projection function to the recursive procedure, so that the cache may - be used. Returns the composed BDD if successful; NULL otherwise.] + @return the composed %BDD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addCompose] + @see Cudd_addCompose -******************************************************************************/ +*/ DdNode * Cudd_bddCompose( DdManager * dd, @@ -176,26 +129,28 @@ Cudd_bddCompose( dd->reordered = 0; res = cuddBddComposeRecur(dd,f,g,proj); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddCompose */ -/**Function******************************************************************** +/** + @brief Substitutes g for x_v in the %ADD for f. - Synopsis [Substitutes g for x_v in the ADD for f.] + @details v is the index of the variable to be substituted. g must be + a 0-1 %ADD. Cudd_bddCompose passes the corresponding projection + function to the recursive procedure, so that the cache may be used. - Description [Substitutes g for x_v in the ADD for f. v is the index of the - variable to be substituted. g must be a 0-1 ADD. Cudd_bddCompose passes - the corresponding projection function to the recursive procedure, so - that the cache may be used. Returns the composed ADD if successful; - NULL otherwise.] + @return the composed %ADD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddCompose] + @see Cudd_bddCompose -******************************************************************************/ +*/ DdNode * Cudd_addCompose( DdManager * dd, @@ -213,27 +168,31 @@ Cudd_addCompose( dd->reordered = 0; res = cuddAddComposeRecur(dd,f,g,proj); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addCompose */ -/**Function******************************************************************** - - Synopsis [Permutes the variables of an ADD.] +/** + @brief Permutes the variables of an %ADD. - Description [Given a permutation in array permut, creates a new ADD + @details Given a permutation in array permut, creates a new %ADD with permuted variables. There should be an entry in array permut for each variable in the manager. The i-th entry of permut holds the index of the variable that is to substitute the i-th - variable. Returns a pointer to the resulting ADD if successful; NULL - otherwise.] + variable. - SideEffects [None] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. - SeeAlso [Cudd_bddPermute Cudd_addSwapVariables] + @sideeffect None -******************************************************************************/ + @see Cudd_bddPermute Cudd_addSwapVariables + +*/ DdNode * Cudd_addPermute( DdManager * manager, @@ -255,26 +214,29 @@ Cudd_addPermute( } while (manager->reordered == 1); if (res != NULL) cuddDeref(res); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_addPermute */ -/**Function******************************************************************** +/** + @brief Swaps two sets of variables of the same size (x and y) in + the %ADD f. - Synopsis [Swaps two sets of variables of the same size (x and y) in - the ADD f.] + @details The size is given by n. The two sets of variables are + assumed to be disjoint. - Description [Swaps two sets of variables of the same size (x and y) in - the ADD f. The size is given by n. The two sets of variables are - assumed to be disjoint. Returns a pointer to the resulting ADD if - successful; NULL otherwise.] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addPermute Cudd_bddSwapVariables] + @see Cudd_addPermute Cudd_bddSwapVariables -******************************************************************************/ +*/ DdNode * Cudd_addSwapVariables( DdManager * dd, @@ -308,22 +270,22 @@ Cudd_addSwapVariables( } /* end of Cudd_addSwapVariables */ -/**Function******************************************************************** +/** + @brief Permutes the variables of a %BDD. - Synopsis [Permutes the variables of a BDD.] - - Description [Given a permutation in array permut, creates a new BDD + @details Given a permutation in array permut, creates a new %BDD with permuted variables. There should be an entry in array permut for each variable in the manager. The i-th entry of permut holds the index of the variable that is to substitute the i-th variable. - Returns a pointer to the resulting BDD if successful; NULL - otherwise.] - SideEffects [None] + @return a pointer to the resulting %BDD if successful; NULL + otherwise. + + @sideeffect None - SeeAlso [Cudd_addPermute Cudd_bddSwapVariables] + @see Cudd_addPermute Cudd_bddSwapVariables -******************************************************************************/ +*/ DdNode * Cudd_bddPermute( DdManager * manager, @@ -345,30 +307,32 @@ Cudd_bddPermute( } while (manager->reordered == 1); if (res != NULL) cuddDeref(res); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_bddPermute */ -/**Function******************************************************************** - - Synopsis [Remaps the variables of a BDD using the default variable map.] +/** + @brief Remaps the variables of a %BDD using the default variable map. - Description [Remaps the variables of a BDD using the default - variable map. A typical use of this function is to swap two sets of + @details A typical use of this function is to swap two sets of variables. The variable map must be registered with Cudd_SetVarMap. - Returns a pointer to the resulting BDD if successful; NULL - otherwise.] - SideEffects [None] + @return a pointer to the resulting %BDD if successful; NULL + otherwise. - SeeAlso [Cudd_bddPermute Cudd_bddSwapVariables Cudd_SetVarMap] + @sideeffect None -******************************************************************************/ + @see Cudd_bddPermute Cudd_bddSwapVariables Cudd_SetVarMap + +*/ DdNode * Cudd_bddVarMap( - DdManager * manager /* DD manager */, - DdNode * f /* function in which to remap variables */) + DdManager * manager /**< %DD manager */, + DdNode * f /**< function in which to remap variables */) { DdNode *res; @@ -377,17 +341,19 @@ Cudd_bddVarMap( manager->reordered = 0; res = cuddBddVarMapRecur(manager, f); } while (manager->reordered == 1); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(res); } /* end of Cudd_bddVarMap */ -/**Function******************************************************************** +/** + @brief Registers a variable mapping with the manager. - Synopsis [Registers a variable mapping with the manager.] - - Description [Registers with the manager a variable mapping described + @details Registers with the manager a variable mapping described by two sets of variables. This variable mapping is then used by functions like Cudd_bddVarMap. This function is convenient for those applications that perform the same mapping several times. @@ -400,20 +366,22 @@ Cudd_bddVarMap( not imposeded by the function. When new variables are created, the map is automatically extended (each new variable maps to itself). The typical use, however, is to wait until all variables - are created, and then create the map. Returns 1 if the mapping is - successfully registered with the manager; 0 otherwise.] + are created, and then create the map. + + @return 1 if the mapping is successfully registered with the + manager; 0 otherwise. - SideEffects [Modifies the manager. May clear the cache.] + @sideeffect Modifies the manager. May clear the cache. - SeeAlso [Cudd_bddVarMap Cudd_bddPermute Cudd_bddSwapVariables] + @see Cudd_bddVarMap Cudd_bddPermute Cudd_bddSwapVariables -******************************************************************************/ +*/ int Cudd_SetVarMap ( - DdManager *manager /* DD manager */, - DdNode **x /* first array of variables */, - DdNode **y /* second array of variables */, - int n /* length of both arrays */) + DdManager *manager /**< %DD manager */, + DdNode **x /**< first array of variables */, + DdNode **y /**< second array of variables */, + int n /**< length of both arrays */) { int i; @@ -441,21 +409,21 @@ Cudd_SetVarMap ( } /* end of Cudd_SetVarMap */ -/**Function******************************************************************** +/** + @brief Swaps two sets of variables of the same size (x and y) in + the %BDD f. - Synopsis [Swaps two sets of variables of the same size (x and y) in - the BDD f.] + @details The size is given by n. The two sets of variables are + assumed to be disjoint. - Description [Swaps two sets of variables of the same size (x and y) - in the BDD f. The size is given by n. The two sets of variables are - assumed to be disjoint. Returns a pointer to the resulting BDD if - successful; NULL otherwise.] + @return a pointer to the resulting %BDD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddPermute Cudd_addSwapVariables] + @see Cudd_bddPermute Cudd_addSwapVariables -******************************************************************************/ +*/ DdNode * Cudd_bddSwapVariables( DdManager * dd, @@ -489,21 +457,20 @@ Cudd_bddSwapVariables( } /* end of Cudd_bddSwapVariables */ -/**Function******************************************************************** +/** + @brief Rearranges a set of variables in the %BDD B. - Synopsis [Rearranges a set of variables in the BDD B.] + @details The size of the set is given by n. This procedure is + intended for the `randomization' of the priority functions. - Description [Rearranges a set of variables in the BDD B. The size of - the set is given by n. This procedure is intended for the - `randomization' of the priority functions. Returns a pointer to the - BDD if successful; NULL otherwise.] + @return a pointer to the %BDD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddPermute Cudd_bddSwapVariables - Cudd_Dxygtdxz Cudd_Dxygtdyz Cudd_PrioritySelect] + @see Cudd_bddPermute Cudd_bddSwapVariables + Cudd_Dxygtdxz Cudd_Dxygtdyz Cudd_PrioritySelect -******************************************************************************/ +*/ DdNode * Cudd_bddAdjPermuteX( DdManager * dd, @@ -536,25 +503,25 @@ Cudd_bddAdjPermuteX( } /* end of Cudd_bddAdjPermuteX */ -/**Function******************************************************************** +/** + @brief Composes an %ADD with a vector of 0-1 ADDs. - Synopsis [Composes an ADD with a vector of 0-1 ADDs.] - - Description [Given a vector of 0-1 ADDs, creates a new ADD by - substituting the 0-1 ADDs for the variables of the ADD f. There + @details Given a vector of 0-1 ADDs, creates a new %ADD by + substituting the 0-1 ADDs for the variables of the %ADD f. There should be an entry in vector for each variable in the manager. If no substitution is sought for a given variable, the corresponding projection function should be specified in the vector. This function implements simultaneous composition. - Returns a pointer to the resulting ADD if successful; NULL - otherwise.] - SideEffects [None] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. + + @sideeffect None - SeeAlso [Cudd_addNonSimCompose Cudd_addPermute Cudd_addCompose - Cudd_bddVectorCompose] + @see Cudd_addNonSimCompose Cudd_addPermute Cudd_addCompose + Cudd_bddVectorCompose -******************************************************************************/ +*/ DdNode * Cudd_addVectorCompose( DdManager * dd, @@ -589,30 +556,34 @@ Cudd_addVectorCompose( } while (dd->reordered == 1); if (res != NULL) cuddDeref(res); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addVectorCompose */ -/**Function******************************************************************** - - Synopsis [Composes an ADD with a vector of ADDs.] +/** + @brief Composes an %ADD with a vector of ADDs. - Description [Given a vector of ADDs, creates a new ADD by substituting the - ADDs for the variables of the ADD f. vectorOn contains ADDs to be substituted + @details Given a vector of ADDs, creates a new %ADD by substituting the + ADDs for the variables of the %ADD f. vectorOn contains ADDs to be substituted for the x_v and vectorOff the ADDs to be substituted for x_v'. There should be an entry in vector for each variable in the manager. If no substitution is sought for a given variable, the corresponding projection function should be specified in the vector. This function implements simultaneous - composition. Returns a pointer to the resulting ADD if successful; NULL - otherwise.] + composition. - SideEffects [None] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. - SeeAlso [Cudd_addVectorCompose Cudd_addNonSimCompose Cudd_addPermute - Cudd_addCompose Cudd_bddVectorCompose] + @sideeffect None -******************************************************************************/ + @see Cudd_addVectorCompose Cudd_addNonSimCompose Cudd_addPermute + Cudd_addCompose Cudd_bddVectorCompose + +*/ DdNode * Cudd_addGeneralVectorCompose( DdManager * dd, @@ -649,31 +620,34 @@ Cudd_addGeneralVectorCompose( } while (dd->reordered == 1); if (res != NULL) cuddDeref(res); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addGeneralVectorCompose */ -/**Function******************************************************************** +/** + @brief Composes an %ADD with a vector of 0-1 ADDs. - Synopsis [Composes an ADD with a vector of 0-1 ADDs.] - - Description [Given a vector of 0-1 ADDs, creates a new ADD by - substituting the 0-1 ADDs for the variables of the ADD f. There + @details Given a vector of 0-1 ADDs, creates a new %ADD by + substituting the 0-1 ADDs for the variables of the %ADD f. There should be an entry in vector for each variable in the manager. This function implements non-simultaneous composition. If any of the functions being composed depends on any of the variables being substituted, then the result depends on the order of composition, which in turn depends on the variable order: The variables farther from the roots in the order are substituted first. - Returns a pointer to the resulting ADD if successful; NULL - otherwise.] - SideEffects [None] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. + + @sideeffect None - SeeAlso [Cudd_addVectorCompose Cudd_addPermute Cudd_addCompose] + @see Cudd_addVectorCompose Cudd_addPermute Cudd_addCompose -******************************************************************************/ +*/ DdNode * Cudd_addNonSimCompose( DdManager * dd, @@ -760,29 +734,32 @@ Cudd_addNonSimCompose( Cudd_RecursiveDeref(dd,key); Cudd_RecursiveDeref(dd,cube); if (res != NULL) cuddDeref(res); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addNonSimCompose */ -/**Function******************************************************************** - - Synopsis [Composes a BDD with a vector of BDDs.] +/** + @brief Composes a %BDD with a vector of BDDs. - Description [Given a vector of BDDs, creates a new BDD by - substituting the BDDs for the variables of the BDD f. There + @details Given a vector of BDDs, creates a new %BDD by + substituting the BDDs for the variables of the %BDD f. There should be an entry in vector for each variable in the manager. If no substitution is sought for a given variable, the corresponding projection function should be specified in the vector. This function implements simultaneous composition. - Returns a pointer to the resulting BDD if successful; NULL - otherwise.] - SideEffects [None] + @return a pointer to the resulting %BDD if successful; NULL + otherwise. - SeeAlso [Cudd_bddPermute Cudd_bddCompose Cudd_addVectorCompose] + @sideeffect None -******************************************************************************/ + @see Cudd_bddPermute Cudd_bddCompose Cudd_addVectorCompose + +*/ DdNode * Cudd_bddVectorCompose( DdManager * dd, @@ -817,6 +794,9 @@ Cudd_bddVectorCompose( } while (dd->reordered == 1); if (res != NULL) cuddDeref(res); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddVectorCompose */ @@ -827,21 +807,20 @@ Cudd_bddVectorCompose( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_bddCompose. - Synopsis [Performs the recursive step of Cudd_bddCompose.] - - Description [Performs the recursive step of Cudd_bddCompose. - Exploits the fact that the composition of f' with g + @details Exploits the fact that the composition of f' with g produces the complement of the composition of f with g to better - utilize the cache. Returns the composed BDD if successful; NULL - otherwise.] + utilize the cache. + + @return the composed %BDD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddCompose] + @see Cudd_bddCompose -******************************************************************************/ +*/ DdNode * cuddBddComposeRecur( DdManager * dd, @@ -849,9 +828,10 @@ cuddBddComposeRecur( DdNode * g, DdNode * proj) { - DdNode *F, *G, *f1, *f0, *g1, *g0, *r, *t, *e; - unsigned int v, topf, topg, topindex; - int comple; + DdNode *F, *G, *f1, *f0, *g1, *g0, *r, *t, *e; + unsigned int topindex; + int topf, topg, v; + int comple; statLine(dd); v = dd->perm[proj->index]; @@ -872,6 +852,8 @@ cuddBddComposeRecur( return(Cudd_NotCond(r,comple)); } + checkWhetherToGiveUp(dd); + if (topf == v) { /* Compose. */ f1 = cuddT(F); @@ -932,18 +914,16 @@ cuddBddComposeRecur( } /* end of cuddBddComposeRecur */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_addCompose.] +/** + @brief Performs the recursive step of Cudd_addCompose. - Description [Performs the recursive step of Cudd_addCompose. - Returns the composed BDD if successful; NULL otherwise.] + @return the composed %BDD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addCompose] + @see Cudd_addCompose -******************************************************************************/ +*/ DdNode * cuddAddComposeRecur( DdManager * dd, @@ -952,7 +932,9 @@ cuddAddComposeRecur( DdNode * proj) { DdNode *f1, *f0, *g1, *g0, *r, *t, *e; - unsigned int v, topf, topg, topindex; + int v; + int topf, topg; + unsigned int topindex; statLine(dd); v = dd->perm[proj->index]; @@ -967,6 +949,8 @@ cuddAddComposeRecur( return(r); } + checkWhetherToGiveUp(dd); + if (topf == v) { /* Compose. */ f1 = cuddT(f); @@ -1029,32 +1013,31 @@ cuddAddComposeRecur( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Implements the recursive step of Cudd_addPermute.] +/** + @brief Implements the recursive step of Cudd_addPermute. - Description [ Recursively puts the ADD in the order given in the + @details Recursively puts the %ADD in the order given in the array permut. Checks for trivial cases to terminate recursion, then splits on the children of this node. Once the solutions for the children are obtained, it puts into the current position the node - from the rest of the ADD that should be here. Then returns this ADD. + from the rest of the %ADD that should be here. Then returns this %ADD. The key here is that the node being visited is NOT put in its proper place by this instance, but rather is switched when its proper position is reached in the recursion tree.<p> - The DdNode * that is returned is the same ADD as passed in as node, - but in the new order.] + The DdNode * that is returned is the same %ADD as passed in as node, + but in the new order. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addPermute cuddBddPermuteRecur] + @see Cudd_addPermute cuddBddPermuteRecur -******************************************************************************/ +*/ static DdNode * cuddAddPermuteRecur( - DdManager * manager /* DD manager */, - DdHashTable * table /* computed table */, - DdNode * node /* ADD to be reordered */, - int * permut /* permutation array */) + DdManager * manager /**< %DD manager */, + DdHashTable * table /**< computed table */, + DdNode * node /**< %ADD to be reordered */, + int * permut /**< permutation array */) { DdNode *T,*E; DdNode *res,*var; @@ -1069,7 +1052,7 @@ cuddAddPermuteRecur( /* If problem already solved, look up answer and return. */ if (node->ref != 1 && (res = cuddHashTableLookup1(table,node)) != NULL) { #ifdef DD_DEBUG - addPermuteRecurHits++; + manager->addPermuteRecurHits++; #endif return(res); } @@ -1122,32 +1105,31 @@ cuddAddPermuteRecur( } /* end of cuddAddPermuteRecur */ -/**Function******************************************************************** +/** + @brief Implements the recursive step of Cudd_bddPermute. - Synopsis [Implements the recursive step of Cudd_bddPermute.] - - Description [ Recursively puts the BDD in the order given in the array permut. + @details Recursively puts the %BDD in the order given in the array permut. Checks for trivial cases to terminate recursion, then splits on the children of this node. Once the solutions for the children are obtained, it puts into the current position the node from the rest of - the BDD that should be here. Then returns this BDD. + the %BDD that should be here. Then returns this %BDD. The key here is that the node being visited is NOT put in its proper place by this instance, but rather is switched when its proper position is reached in the recursion tree.<p> - The DdNode * that is returned is the same BDD as passed in as node, - but in the new order.] + The DdNode * that is returned is the same %BDD as passed in as node, + but in the new order. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddPermute cuddAddPermuteRecur] + @see Cudd_bddPermute cuddAddPermuteRecur -******************************************************************************/ +*/ static DdNode * cuddBddPermuteRecur( - DdManager * manager /* DD manager */, - DdHashTable * table /* computed table */, - DdNode * node /* BDD to be reordered */, - int * permut /* permutation array */) + DdManager * manager /**< %DD manager */, + DdHashTable * table /**< computed table */, + DdNode * node /**< %BDD to be reordered */, + int * permut /**< permutation array */) { DdNode *N,*T,*E; DdNode *res; @@ -1164,7 +1146,7 @@ cuddBddPermuteRecur( /* If problem already solved, look up answer and return. */ if (N->ref != 1 && (res = cuddHashTableLookup1(table,N)) != NULL) { #ifdef DD_DEBUG - bddPermuteRecurHits++; + manager->bddPermuteRecurHits++; #endif return(Cudd_NotCond(res,N != node)); } @@ -1212,22 +1194,20 @@ cuddBddPermuteRecur( } /* end of cuddBddPermuteRecur */ -/**Function******************************************************************** - - Synopsis [Implements the recursive step of Cudd_bddVarMap.] +/** + @brief Implements the recursive step of Cudd_bddVarMap. - Description [Implements the recursive step of Cudd_bddVarMap. - Returns a pointer to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddVarMap] + @see Cudd_bddVarMap -******************************************************************************/ +*/ static DdNode * cuddBddVarMapRecur( - DdManager *manager /* DD manager */, - DdNode *f /* BDD to be remapped */) + DdManager *manager /**< %DD manager */, + DdNode *f /**< %BDD to be remapped */) { DdNode *F, *T, *E; DdNode *res; @@ -1247,6 +1227,8 @@ cuddBddVarMapRecur( return(Cudd_NotCond(res,F != f)); } + checkWhetherToGiveUp(manager); + /* Split and recur on children of this node. */ T = cuddBddVarMapRecur(manager,cuddT(F)); if (T == NULL) return(NULL); @@ -1285,24 +1267,19 @@ cuddBddVarMapRecur( } /* end of cuddBddVarMapRecur */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_addVectorCompose.] +/** + @brief Performs the recursive step of Cudd_addVectorCompose. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static DdNode * cuddAddVectorComposeRecur( - DdManager * dd /* DD manager */, - DdHashTable * table /* computed table */, - DdNode * f /* ADD in which to compose */, - DdNode ** vector /* functions to substitute */, - int deepest /* depth of deepest substitution */) + DdManager * dd /**< %DD manager */, + DdHashTable * table /**< computed table */, + DdNode * f /**< %ADD in which to compose */, + DdNode ** vector /**< functions to substitute */, + int deepest /**< depth of deepest substitution */) { DdNode *T,*E; DdNode *res; @@ -1315,7 +1292,7 @@ cuddAddVectorComposeRecur( if ((res = cuddHashTableLookup1(table,f)) != NULL) { #ifdef DD_DEBUG - addVectorComposeHits++; + dd->addVectorComposeHits++; #endif return(res); } @@ -1361,25 +1338,20 @@ cuddAddVectorComposeRecur( } /* end of cuddAddVectorComposeRecur */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_addGeneralVectorCompose.] - - Description [] +/** + @brief Performs the recursive step of Cudd_addGeneralVectorCompose. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static DdNode * cuddAddGeneralVectorComposeRecur( - DdManager * dd /* DD manager */, - DdHashTable * table /* computed table */, - DdNode * f /* ADD in which to compose */, - DdNode ** vectorOn /* functions to substitute for x_i */, - DdNode ** vectorOff /* functions to substitute for x_i' */, - int deepest /* depth of deepest substitution */) + DdManager * dd /**< %DD manager */, + DdHashTable * table /**< computed table */, + DdNode * f /**< %ADD in which to compose */, + DdNode ** vectorOn /**< functions to substitute for x_i */, + DdNode ** vectorOff /**< functions to substitute for x_i' */, + int deepest /**< depth of deepest substitution */) { DdNode *T,*E,*t,*e; DdNode *res; @@ -1391,7 +1363,7 @@ cuddAddGeneralVectorComposeRecur( if ((res = cuddHashTableLookup1(table,f)) != NULL) { #ifdef DD_DEBUG - addGeneralVectorComposeHits++; + dd->addGeneralVectorComposeHits++; #endif return(res); } @@ -1458,17 +1430,12 @@ cuddAddGeneralVectorComposeRecur( } /* end of cuddAddGeneralVectorComposeRecur */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_addNonSimCompose.] - - Description [] - - SideEffects [None] +/** + @brief Performs the recursive step of Cudd_addNonSimCompose. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static DdNode * cuddAddNonSimComposeRecur( DdManager * dd, @@ -1481,7 +1448,7 @@ cuddAddNonSimComposeRecur( DdNode *f1, *f0, *key1, *key0, *cube1, *var; DdNode *T,*E; DdNode *r; - unsigned int top, topf, topk, topc; + int top, topf, topk, topc; unsigned int index; int i; DdNode **vect1; @@ -1499,6 +1466,8 @@ cuddAddNonSimComposeRecur( return(r); } + checkWhetherToGiveUp(dd); + /* Find top variable. we just need to look at f, key, and cube, ** because all the varibles in the gi are in key. */ @@ -1618,24 +1587,19 @@ cuddAddNonSimComposeRecur( } /* end of cuddAddNonSimComposeRecur */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_bddVectorCompose.] - - Description [] - - SideEffects [None] +/** + @brief Performs the recursive step of Cudd_bddVectorCompose. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static DdNode * cuddBddVectorComposeRecur( - DdManager * dd /* DD manager */, - DdHashTable * table /* computed table */, - DdNode * f /* BDD in which to compose */, - DdNode ** vector /* functions to be composed */, - int deepest /* depth of the deepest substitution */) + DdManager * dd /**< %DD manager */, + DdHashTable * table /**< computed table */, + DdNode * f /**< %BDD in which to compose */, + DdNode ** vector /**< functions to be composed */, + int deepest /**< depth of the deepest substitution */) { DdNode *F,*T,*E; DdNode *res; @@ -1651,7 +1615,7 @@ cuddBddVectorComposeRecur( /* If problem already solved, look up answer and return. */ if ((res = cuddHashTableLookup1(table,F)) != NULL) { #ifdef DD_DEBUG - bddVectorComposeHits++; + dd->bddVectorComposeHits++; #endif return(Cudd_NotCond(res,F != f)); } @@ -1697,19 +1661,14 @@ cuddBddVectorComposeRecur( } /* end of cuddBddVectorComposeRecur */ -/**Function******************************************************************** +/** + @brief Comparison of a function to the i-th %ADD variable. - Synopsis [Comparison of a function to the i-th ADD variable.] + @return 1 if the function is the i-th %ADD variable; 0 otherwise. - Description [Comparison of a function to the i-th ADD variable. Returns 1 if - the function is the i-th ADD variable; 0 otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ -DD_INLINE +*/ static int ddIsIthAddVar( DdManager * dd, @@ -1721,20 +1680,15 @@ ddIsIthAddVar( } /* end of ddIsIthAddVar */ -/**Function******************************************************************** - - Synopsis [Comparison of a pair of functions to the i-th ADD variable.] - - Description [Comparison of a pair of functions to the i-th ADD - variable. Returns 1 if the functions are the i-th ADD variable and its - complement; 0 otherwise.] +/** + @brief Comparison of a pair of functions to the i-th %ADD variable. - SideEffects [None] + @return 1 if the functions are the i-th %ADD variable and its + complement; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ -DD_INLINE +*/ static int ddIsIthAddVarPair( DdManager * dd, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddDecomp.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddDecomp.c similarity index 67% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddDecomp.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddDecomp.c index 066027d95..b77214208 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddDecomp.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddDecomp.c @@ -1,33 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddDecomp.c] + @ingroup cudd - PackageName [cudd] + @brief Functions for %BDD decomposition. - Synopsis [Functions for BDD decomposition.] + @author Kavita Ravi, Fabio Somenzi - Description [External procedures included in this file: - <ul> - <li> Cudd_bddApproxConjDecomp() - <li> Cudd_bddApproxDisjDecomp() - <li> Cudd_bddIterConjDecomp() - <li> Cudd_bddIterDisjDecomp() - <li> Cudd_bddGenConjDecomp() - <li> Cudd_bddGenDisjDecomp() - <li> Cudd_bddVarConjDecomp() - <li> Cudd_bddVarDisjDecomp() - </ul> - Static procedures included in this module: - <ul> - <li> cuddConjunctsAux() - <li> CreateBotDist() - <li> BuildConjuncts() - <li> ConjunctsFree() - </ul>] - - Author [Kavita Ravi, Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -57,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -86,11 +68,17 @@ /*---------------------------------------------------------------------------*/ /* Type declarations */ /*---------------------------------------------------------------------------*/ +/** + * @brief Type of a pair of conjoined BDDs. + */ typedef struct Conjuncts { DdNode *g; DdNode *h; } Conjuncts; +/** + @brief Stats for one node. +*/ typedef struct NodeStat { int distance; int localRef; @@ -101,42 +89,36 @@ typedef struct NodeStat { /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddDecomp.c,v 1.45 2012/02/05 01:07:18 fabio Exp $"; -#endif - -static DdNode *one, *zero; -long lastTimeG; /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -#define FactorsNotStored(factors) ((int)((long)(factors) & 01)) +#define FactorsNotStored(factors) ((int)((ptrint)(factors) & 01)) -#define FactorsComplement(factors) ((Conjuncts *)((long)(factors) | 01)) +#define FactorsComplement(factors) ((Conjuncts *)((ptrint)(factors) | 01)) -#define FactorsUncomplement(factors) ((Conjuncts *)((long)(factors) ^ 01)) +#define FactorsUncomplement(factors) ((Conjuncts *)((ptrint)(factors) ^ 01)) -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ static NodeStat * CreateBotDist (DdNode * node, st_table * distanceTable); -static double CountMinterms (DdNode * node, double max, st_table * mintermTable, FILE *fp); +static double CountMinterms (DdManager * dd, DdNode * node, double max, st_table * mintermTable, FILE *fp); static void ConjunctsFree (DdManager * dd, Conjuncts * factors); static int PairInTables (DdNode * g, DdNode * h, st_table * ghTable); -static Conjuncts * CheckTablesCacheAndReturn (DdNode * node, DdNode * g, DdNode * h, st_table * ghTable, st_table * cacheTable); -static Conjuncts * PickOnePair (DdNode * node, DdNode * g1, DdNode * h1, DdNode * g2, DdNode * h2, st_table * ghTable, st_table * cacheTable); -static Conjuncts * CheckInTables (DdNode * node, DdNode * g1, DdNode * h1, DdNode * g2, DdNode * h2, st_table * ghTable, st_table * cacheTable, int * outOfMem); +static Conjuncts * CheckTablesCacheAndReturn (DdManager *manager, DdNode * node, DdNode * g, DdNode * h, st_table * ghTable, st_table * cacheTable); +static Conjuncts * PickOnePair (DdManager * manager, DdNode * node, DdNode * g1, DdNode * h1, DdNode * g2, DdNode * h2, st_table * ghTable, st_table * cacheTable); +static Conjuncts * CheckInTables (DdManager * manager, DdNode * node, DdNode * g1, DdNode * h1, DdNode * g2, DdNode * h2, st_table * ghTable, st_table * cacheTable, int * outOfMem); static Conjuncts * ZeroCase (DdManager * dd, DdNode * node, Conjuncts * factorsNv, st_table * ghTable, st_table * cacheTable, int switched); -static Conjuncts * BuildConjuncts (DdManager * dd, DdNode * node, st_table * distanceTable, st_table * cacheTable, int approxDistance, int maxLocalRef, st_table * ghTable, st_table * mintermTable); +static Conjuncts * BuildConjuncts (DdManager * dd, DdNode * node, st_table * distanceTable, st_table * cacheTable, int approxDistance, int maxLocalRef, st_table * ghTable, st_table * mintermTable, int32_t *lastTimeG); static int cuddConjunctsAux (DdManager * dd, DdNode * f, DdNode ** c1, DdNode ** c2); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -144,34 +126,33 @@ static int cuddConjunctsAux (DdManager * dd, DdNode * f, DdNode ** c1, DdNode ** /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs two-way conjunctive decomposition of a %BDD. - Synopsis [Performs two-way conjunctive decomposition of a BDD.] + @details This procedure owes its name to the use of supersetting to + obtain an initial factor of the given function. The conjuncts + produced by this procedure tend to be imbalanced. - Description [Performs two-way conjunctive decomposition of a - BDD. This procedure owes its name to the use of supersetting to - obtain an initial factor of the given function. Returns the number - of conjuncts produced, that is, 2 if successful; 1 if no meaningful - decomposition was found; 0 otherwise. The conjuncts produced by this - procedure tend to be imbalanced.] + @return the number of conjuncts produced, that is, 2 if successful; + 1 if no meaningful decomposition was found; 0 otherwise. - SideEffects [The factors are returned in an array as side effects. + @sideeffect The factors are returned in an array as side effects. The array is allocated by this function. It is the caller's responsibility to free it. On successful completion, the conjuncts are already referenced. If the function returns 0, the array for the conjuncts is not allocated. If the function returns 1, the only factor equals the - function to be decomposed.] + function to be decomposed. - SeeAlso [Cudd_bddApproxDisjDecomp Cudd_bddIterConjDecomp + @see Cudd_bddApproxDisjDecomp Cudd_bddIterConjDecomp Cudd_bddGenConjDecomp Cudd_bddVarConjDecomp Cudd_RemapOverApprox - Cudd_bddSqueeze Cudd_bddLICompaction] + Cudd_bddSqueeze Cudd_bddLICompaction -******************************************************************************/ +*/ int Cudd_bddApproxConjDecomp( - DdManager * dd /* manager */, - DdNode * f /* function to be decomposed */, - DdNode *** conjuncts /* address of the first factor */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be decomposed */, + DdNode *** conjuncts /**< address of the first factor */) { DdNode *superset1, *superset2, *glocal, *hlocal; int nvars = Cudd_SupportSize(dd,f); @@ -245,31 +226,31 @@ Cudd_bddApproxConjDecomp( } /* end of Cudd_bddApproxConjDecomp */ -/**Function******************************************************************** +/** + @brief Performs two-way disjunctive decomposition of a %BDD. - Synopsis [Performs two-way disjunctive decomposition of a BDD.] + @details The disjuncts produced by this procedure tend to be + imbalanced. - Description [Performs two-way disjunctive decomposition of a BDD. - Returns the number of disjuncts produced, that is, 2 if successful; - 1 if no meaningful decomposition was found; 0 otherwise. The - disjuncts produced by this procedure tend to be imbalanced.] + @return the number of disjuncts produced, that is, 2 if successful; + 1 if no meaningful decomposition was found; 0 otherwise. - SideEffects [The two disjuncts are returned in an array as side effects. + @sideeffect The two disjuncts are returned in an array as side effects. The array is allocated by this function. It is the caller's responsibility to free it. On successful completion, the disjuncts are already referenced. If the function returns 0, the array for the disjuncts is not allocated. If the function returns 1, the only factor equals the - function to be decomposed.] + function to be decomposed. - SeeAlso [Cudd_bddApproxConjDecomp Cudd_bddIterDisjDecomp - Cudd_bddGenDisjDecomp Cudd_bddVarDisjDecomp] + @see Cudd_bddApproxConjDecomp Cudd_bddIterDisjDecomp + Cudd_bddGenDisjDecomp Cudd_bddVarDisjDecomp -******************************************************************************/ +*/ int Cudd_bddApproxDisjDecomp( - DdManager * dd /* manager */, - DdNode * f /* function to be decomposed */, - DdNode *** disjuncts /* address of the array of the disjuncts */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be decomposed */, + DdNode *** disjuncts /**< address of the array of the disjuncts */) { int result, i; @@ -282,34 +263,33 @@ Cudd_bddApproxDisjDecomp( } /* end of Cudd_bddApproxDisjDecomp */ -/**Function******************************************************************** +/** + @brief Performs two-way conjunctive decomposition of a %BDD. - Synopsis [Performs two-way conjunctive decomposition of a BDD.] + @details This procedure owes its name to the iterated use of + supersetting to obtain a factor of the given function. The + conjuncts produced by this procedure tend to be imbalanced. - Description [Performs two-way conjunctive decomposition of a - BDD. This procedure owes its name to the iterated use of - supersetting to obtain a factor of the given function. Returns the - number of conjuncts produced, that is, 2 if successful; 1 if no - meaningful decomposition was found; 0 otherwise. The conjuncts - produced by this procedure tend to be imbalanced.] + @return the number of conjuncts produced, that is, 2 if successful; + 1 if no meaningful decomposition was found; 0 otherwise. - SideEffects [The factors are returned in an array as side effects. + @sideeffect The factors are returned in an array as side effects. The array is allocated by this function. It is the caller's responsibility to free it. On successful completion, the conjuncts are already referenced. If the function returns 0, the array for the conjuncts is not allocated. If the function returns 1, the only factor equals the - function to be decomposed.] + function to be decomposed. - SeeAlso [Cudd_bddIterDisjDecomp Cudd_bddApproxConjDecomp + @see Cudd_bddIterDisjDecomp Cudd_bddApproxConjDecomp Cudd_bddGenConjDecomp Cudd_bddVarConjDecomp Cudd_RemapOverApprox - Cudd_bddSqueeze Cudd_bddLICompaction] + Cudd_bddSqueeze Cudd_bddLICompaction -******************************************************************************/ +*/ int Cudd_bddIterConjDecomp( - DdManager * dd /* manager */, - DdNode * f /* function to be decomposed */, - DdNode *** conjuncts /* address of the array of conjuncts */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be decomposed */, + DdNode *** conjuncts /**< address of the array of conjuncts */) { DdNode *superset1, *superset2, *old[2], *res[2]; int sizeOld, sizeNew; @@ -428,31 +408,31 @@ Cudd_bddIterConjDecomp( } /* end of Cudd_bddIterConjDecomp */ -/**Function******************************************************************** +/** + @brief Performs two-way disjunctive decomposition of a %BDD. - Synopsis [Performs two-way disjunctive decomposition of a BDD.] + @details The disjuncts produced by this procedure tend to be + imbalanced. - Description [Performs two-way disjunctive decomposition of a BDD. - Returns the number of disjuncts produced, that is, 2 if successful; - 1 if no meaningful decomposition was found; 0 otherwise. The - disjuncts produced by this procedure tend to be imbalanced.] + @return the number of disjuncts produced, that is, 2 if successful; + 1 if no meaningful decomposition was found; 0 otherwise. - SideEffects [The two disjuncts are returned in an array as side effects. + @sideeffect The two disjuncts are returned in an array as side effects. The array is allocated by this function. It is the caller's responsibility to free it. On successful completion, the disjuncts are already referenced. If the function returns 0, the array for the disjuncts is not allocated. If the function returns 1, the only factor equals the - function to be decomposed.] + function to be decomposed. - SeeAlso [Cudd_bddIterConjDecomp Cudd_bddApproxDisjDecomp - Cudd_bddGenDisjDecomp Cudd_bddVarDisjDecomp] + @see Cudd_bddIterConjDecomp Cudd_bddApproxDisjDecomp + Cudd_bddGenDisjDecomp Cudd_bddVarDisjDecomp -******************************************************************************/ +*/ int Cudd_bddIterDisjDecomp( - DdManager * dd /* manager */, - DdNode * f /* function to be decomposed */, - DdNode *** disjuncts /* address of the array of the disjuncts */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be decomposed */, + DdNode *** disjuncts /**< address of the array of the disjuncts */) { int result, i; @@ -465,52 +445,51 @@ Cudd_bddIterDisjDecomp( } /* end of Cudd_bddIterDisjDecomp */ -/**Function******************************************************************** +/** + @brief Performs two-way conjunctive decomposition of a %BDD. - Synopsis [Performs two-way conjunctive decomposition of a BDD.] + @details This procedure owes its name to the fact tht it generalizes + the decomposition based on the cofactors with respect to one + variable. The conjuncts produced by this procedure tend to be + balanced. - Description [Performs two-way conjunctive decomposition of a - BDD. This procedure owes its name to the fact tht it generalizes the - decomposition based on the cofactors with respect to one - variable. Returns the number of conjuncts produced, that is, 2 if - successful; 1 if no meaningful decomposition was found; 0 - otherwise. The conjuncts produced by this procedure tend to be - balanced.] + @return the number of conjuncts produced, that is, 2 if successful; + 1 if no meaningful decomposition was found; 0 otherwise. - SideEffects [The two factors are returned in an array as side effects. + @sideeffect The two factors are returned in an array as side effects. The array is allocated by this function. It is the caller's responsibility to free it. On successful completion, the conjuncts are already referenced. If the function returns 0, the array for the conjuncts is not allocated. If the function returns 1, the only factor equals the - function to be decomposed.] + function to be decomposed. - SeeAlso [Cudd_bddGenDisjDecomp Cudd_bddApproxConjDecomp - Cudd_bddIterConjDecomp Cudd_bddVarConjDecomp] + @see Cudd_bddGenDisjDecomp Cudd_bddApproxConjDecomp + Cudd_bddIterConjDecomp Cudd_bddVarConjDecomp -******************************************************************************/ +*/ int Cudd_bddGenConjDecomp( - DdManager * dd /* manager */, - DdNode * f /* function to be decomposed */, - DdNode *** conjuncts /* address of the array of conjuncts */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be decomposed */, + DdNode *** conjuncts /**< address of the array of conjuncts */) { int result; DdNode *glocal, *hlocal; - one = DD_ONE(dd); - zero = Cudd_Not(one); - do { dd->reordered = 0; result = cuddConjunctsAux(dd, f, &glocal, &hlocal); } while (dd->reordered == 1); if (result == 0) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(0); } - if (glocal != one) { - if (hlocal != one) { + if (glocal != DD_ONE(dd)) { + if (hlocal != DD_ONE(dd)) { *conjuncts = ALLOC(DdNode *,2); if (*conjuncts == NULL) { Cudd_RecursiveDeref(dd,glocal); @@ -547,31 +526,31 @@ Cudd_bddGenConjDecomp( } /* end of Cudd_bddGenConjDecomp */ -/**Function******************************************************************** +/** + @brief Performs two-way disjunctive decomposition of a %BDD. - Synopsis [Performs two-way disjunctive decomposition of a BDD.] + @details The disjuncts produced by this procedure tend to be + balanced. - Description [Performs two-way disjunctive decomposition of a BDD. - Returns the number of disjuncts produced, that is, 2 if successful; - 1 if no meaningful decomposition was found; 0 otherwise. The - disjuncts produced by this procedure tend to be balanced.] + @return the number of disjuncts produced, that is, 2 if successful; + 1 if no meaningful decomposition was found; 0 otherwise. - SideEffects [The two disjuncts are returned in an array as side effects. + @sideeffect The two disjuncts are returned in an array as side effects. The array is allocated by this function. It is the caller's responsibility to free it. On successful completion, the disjuncts are already referenced. If the function returns 0, the array for the disjuncts is not allocated. If the function returns 1, the only factor equals the - function to be decomposed.] + function to be decomposed. - SeeAlso [Cudd_bddGenConjDecomp Cudd_bddApproxDisjDecomp - Cudd_bddIterDisjDecomp Cudd_bddVarDisjDecomp] + @see Cudd_bddGenConjDecomp Cudd_bddApproxDisjDecomp + Cudd_bddIterDisjDecomp Cudd_bddVarDisjDecomp -******************************************************************************/ +*/ int Cudd_bddGenDisjDecomp( - DdManager * dd /* manager */, - DdNode * f /* function to be decomposed */, - DdNode *** disjuncts /* address of the array of the disjuncts */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be decomposed */, + DdNode *** disjuncts /**< address of the array of the disjuncts */) { int result, i; @@ -584,34 +563,34 @@ Cudd_bddGenDisjDecomp( } /* end of Cudd_bddGenDisjDecomp */ -/**Function******************************************************************** - - Synopsis [Performs two-way conjunctive decomposition of a BDD.] +/** + @brief Performs two-way conjunctive decomposition of a %BDD. - Description [Conjunctively decomposes one BDD according to a - variable. If <code>f</code> is the function of the BDD and + @details Conjunctively decomposes one %BDD according to a + variable. If <code>f</code> is the function of the %BDD and <code>x</code> is the variable, the decomposition is <code>(f+x)(f+x')</code>. The variable is chosen so as to balance - the sizes of the two conjuncts and to keep them small. Returns the - number of conjuncts produced, that is, 2 if successful; 1 if no - meaningful decomposition was found; 0 otherwise.] + the sizes of the two conjuncts and to keep them small. - SideEffects [The two factors are returned in an array as side effects. + @return the number of conjuncts produced, that is, 2 if successful; + 1 if no meaningful decomposition was found; 0 otherwise. + + @sideeffect The two factors are returned in an array as side effects. The array is allocated by this function. It is the caller's responsibility to free it. On successful completion, the conjuncts are already referenced. If the function returns 0, the array for the conjuncts is not allocated. If the function returns 1, the only factor equals the - function to be decomposed.] + function to be decomposed. - SeeAlso [Cudd_bddVarDisjDecomp Cudd_bddGenConjDecomp - Cudd_bddApproxConjDecomp Cudd_bddIterConjDecomp] + @see Cudd_bddVarDisjDecomp Cudd_bddGenConjDecomp + Cudd_bddApproxConjDecomp Cudd_bddIterConjDecomp -*****************************************************************************/ +*/ int Cudd_bddVarConjDecomp( - DdManager * dd /* manager */, - DdNode * f /* function to be decomposed */, - DdNode *** conjuncts /* address of the array of conjuncts */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be decomposed */, + DdNode *** conjuncts /**< address of the array of conjuncts */) { int best; int min; @@ -620,7 +599,7 @@ Cudd_bddVarConjDecomp( /* Find best cofactoring variable. */ support = Cudd_Support(dd,f); if (support == NULL) return(0); - if (Cudd_IsConstant(support)) { + if (Cudd_IsConstantInt(support)) { *conjuncts = ALLOC(DdNode *,1); if (*conjuncts == NULL) { dd->errorCode = CUDD_MEMORY_OUT; @@ -634,12 +613,15 @@ Cudd_bddVarConjDecomp( min = 1000000000; best = -1; scan = support; - while (!Cudd_IsConstant(scan)) { - int i = scan->index; - int est1 = Cudd_EstimateCofactor(dd,f,i,1); - int est0 = Cudd_EstimateCofactor(dd,f,i,0); + while (!Cudd_IsConstantInt(scan)) { + int i, est1, est0, est; + i = scan->index; + est1 = Cudd_EstimateCofactor(dd,f,i,1); + if (est1 == CUDD_OUT_OF_MEM) return(0); + est0 = Cudd_EstimateCofactor(dd,f,i,0); + if (est0 == CUDD_OUT_OF_MEM) return(0); /* Minimize the size of the larger of the two cofactors. */ - int est = (est1 > est0) ? est1 : est0; + est = (est1 > est0) ? est1 : est0; if (est < min) { min = est; best = i; @@ -702,34 +684,34 @@ Cudd_bddVarConjDecomp( } /* end of Cudd_bddVarConjDecomp */ -/**Function******************************************************************** - - Synopsis [Performs two-way disjunctive decomposition of a BDD.] +/** + @brief Performs two-way disjunctive decomposition of a %BDD. - Description [Performs two-way disjunctive decomposition of a BDD + @details Performs two-way disjunctive decomposition of a %BDD according to a variable. If <code>f</code> is the function of the - BDD and <code>x</code> is the variable, the decomposition is + %BDD and <code>x</code> is the variable, the decomposition is <code>f*x + f*x'</code>. The variable is chosen so as to balance - the sizes of the two disjuncts and to keep them small. Returns the - number of disjuncts produced, that is, 2 if successful; 1 if no - meaningful decomposition was found; 0 otherwise.] + the sizes of the two disjuncts and to keep them small. - SideEffects [The two disjuncts are returned in an array as side effects. + @return the number of disjuncts produced, that is, 2 if successful; + 1 if no meaningful decomposition was found; 0 otherwise. + + @sideeffect The two disjuncts are returned in an array as side effects. The array is allocated by this function. It is the caller's responsibility to free it. On successful completion, the disjuncts are already referenced. If the function returns 0, the array for the disjuncts is not allocated. If the function returns 1, the only factor equals the - function to be decomposed.] + function to be decomposed. - SeeAlso [Cudd_bddVarConjDecomp Cudd_bddApproxDisjDecomp - Cudd_bddIterDisjDecomp Cudd_bddGenDisjDecomp] + @see Cudd_bddVarConjDecomp Cudd_bddApproxDisjDecomp + Cudd_bddIterDisjDecomp Cudd_bddGenDisjDecomp -******************************************************************************/ +*/ int Cudd_bddVarDisjDecomp( - DdManager * dd /* manager */, - DdNode * f /* function to be decomposed */, - DdNode *** disjuncts /* address of the array of the disjuncts */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be decomposed */, + DdNode *** disjuncts /**< address of the array of the disjuncts */) { int result, i; @@ -751,19 +733,15 @@ Cudd_bddVarDisjDecomp( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Get longest distance of node from constant.] +/** + @brief Get longest distance of node from constant. - Description [Get longest distance of node from constant. Returns the - distance of the root from the constant if successful; CUDD_OUT_OF_MEM - otherwise.] + @return the distance of the root from the constant if successful; + CUDD_OUT_OF_MEM otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static NodeStat * CreateBotDist( DdNode * node, @@ -774,14 +752,14 @@ CreateBotDist( NodeStat *nodeStat, *nodeStatNv, *nodeStatNnv; #if 0 - if (Cudd_IsConstant(node)) { + if (Cudd_IsConstantInt(node)) { return(0); } #endif /* Return the entry in the table if found. */ N = Cudd_Regular(node); - if (st_lookup(distanceTable, N, &nodeStat)) { + if (st_lookup(distanceTable, N, (void **) &nodeStat)) { nodeStat->localRef++; return(nodeStat); } @@ -811,7 +789,7 @@ CreateBotDist( nodeStat->distance = distance; nodeStat->localRef = 1; - if (st_insert(distanceTable, (char *)N, (char *)nodeStat) == + if (st_insert(distanceTable, N, nodeStat) == ST_OUT_OF_MEM) { return(0); @@ -821,20 +799,16 @@ CreateBotDist( } /* end of CreateBotDist */ -/**Function******************************************************************** - - Synopsis [Count the number of minterms of each node ina a BDD and - store it in a hash table.] - - Description [] +/** + @brief Count the number of minterms of each node ina a %BDD and + store it in a hash table. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static double CountMinterms( + DdManager * dd, DdNode * node, double max, st_table * mintermTable, @@ -847,7 +821,7 @@ CountMinterms( N = Cudd_Regular(node); if (cuddIsConstant(N)) { - if (node == zero) { + if (node == Cudd_Not(DD_ONE(dd))) { return(0); } else { return(max); @@ -855,8 +829,8 @@ CountMinterms( } /* Return the entry in the table if found. */ - if (st_lookup(mintermTable, node, &dummy)) { - min = *dummy; + if (st_lookup(mintermTable, node, (void **) &dummy)) { + min = *dummy; return(min); } @@ -866,9 +840,9 @@ CountMinterms( Nnv = Cudd_NotCond(Nnv, Cudd_IsComplement(node)); /* Recur on the children. */ - minNv = CountMinterms(Nv, max, mintermTable, fp); + minNv = CountMinterms(dd, Nv, max, mintermTable, fp); if (minNv == -1.0) return(-1.0); - minNnv = CountMinterms(Nnv, max, mintermTable, fp); + minNnv = CountMinterms(dd, Nnv, max, mintermTable, fp); if (minNnv == -1.0) return(-1.0); min = minNv / 2.0 + minNnv / 2.0; /* store @@ -877,7 +851,7 @@ CountMinterms( dummy = ALLOC(double, 1); if (dummy == NULL) return(-1.0); *dummy = min; - if (st_insert(mintermTable, (char *)node, (char *)dummy) == ST_OUT_OF_MEM) { + if (st_insert(mintermTable, node, dummy) == ST_OUT_OF_MEM) { (void) fprintf(fp, "st table insert failed\n"); } return(min); @@ -885,17 +859,12 @@ CountMinterms( } /* end of CountMinterms */ -/**Function******************************************************************** - - Synopsis [Free factors structure] - - Description [] +/** + @brief Free factors structure - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static void ConjunctsFree( DdManager * dd, @@ -909,12 +878,10 @@ ConjunctsFree( } /* end of ConjunctsFree */ -/**Function******************************************************************** - - Synopsis [Check whether the given pair is in the tables.] +/** + @brief Check whether the given pair is in the tables. - Description [.Check whether the given pair is in the tables. gTable - and hTable are combined. + @details gTable and hTable are combined. absence in both is indicated by 0, presence in gTable is indicated by 1, presence in hTable by 2 and @@ -929,13 +896,11 @@ ConjunctsFree( H_CR implies h in gTable and g not in any table BOTH_G implies both in gTable BOTH_H implies both in hTable - NONE implies none in table; ] - - SideEffects [] + NONE implies none in table; - SeeAlso [CheckTablesCacheAndReturn CheckInTables] + @see CheckTablesCacheAndReturn CheckInTables -******************************************************************************/ +*/ static int PairInTables( DdNode * g, @@ -946,8 +911,8 @@ PairInTables( valueG = valueH = gPresent = hPresent = 0; - gPresent = st_lookup_int(ghTable, (char *)Cudd_Regular(g), &valueG); - hPresent = st_lookup_int(ghTable, (char *)Cudd_Regular(h), &valueH); + gPresent = st_lookup_int(ghTable, Cudd_Regular(g), &valueG); + hPresent = st_lookup_int(ghTable, Cudd_Regular(h), &valueH); if (!gPresent && !hPresent) return(NONE); @@ -972,22 +937,21 @@ PairInTables( } /* end of PairInTables */ -/**Function******************************************************************** +/** + @brief Check the tables for the existence of pair and return one + combination, cache the result. - Synopsis [Check the tables for the existence of pair and return one - combination, cache the result.] + @details The assumption is that one of the conjuncts is already in + the tables. - Description [Check the tables for the existence of pair and return - one combination, cache the result. The assumption is that one of the - conjuncts is already in the tables.] + @sideeffect g and h referenced for the cache - SideEffects [g and h referenced for the cache] + @see ZeroCase - SeeAlso [ZeroCase] - -******************************************************************************/ +*/ static Conjuncts * CheckTablesCacheAndReturn( + DdManager * manager, DdNode * node, DdNode * g, DdNode * h, @@ -1008,50 +972,50 @@ CheckTablesCacheAndReturn( factors = ALLOC(Conjuncts, 1); if (factors == NULL) return(NULL); if ((pairValue == BOTH_H) || (pairValue == H_ST)) { - if (g != one) { + if (g != DD_ONE(manager)) { value = 0; - if (st_lookup_int(ghTable, (char *)Cudd_Regular(g), &value)) { + if (st_lookup_int(ghTable, Cudd_Regular(g), &value)) { value |= 1; } else { value = 1; } - if (st_insert(ghTable, (char *)Cudd_Regular(g), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(g), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { return(NULL); } } factors->g = g; factors->h = h; } else if ((pairValue == BOTH_G) || (pairValue == G_ST)) { - if (h != one) { + if (h != DD_ONE(manager)) { value = 0; - if (st_lookup_int(ghTable, (char *)Cudd_Regular(h), &value)) { + if (st_lookup_int(ghTable, Cudd_Regular(h), &value)) { value |= 2; } else { value = 2; } - if (st_insert(ghTable, (char *)Cudd_Regular(h), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(h), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { return(NULL); } } factors->g = g; factors->h = h; } else if (pairValue == H_CR) { - if (g != one) { + if (g != DD_ONE(manager)) { value = 2; - if (st_insert(ghTable, (char *)Cudd_Regular(g), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(g), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { return(NULL); } } factors->g = h; factors->h = g; } else if (pairValue == G_CR) { - if (h != one) { + if (h != DD_ONE(manager)) { value = 1; - if (st_insert(ghTable, (char *)Cudd_Regular(h), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(h), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { return(NULL); } } @@ -1067,7 +1031,7 @@ CheckTablesCacheAndReturn( } /* cache the result for this node */ - if (st_insert(cacheTable, (char *)node, (char *)factors) == ST_OUT_OF_MEM) { + if (st_insert(cacheTable, node, factors) == ST_OUT_OF_MEM) { FREE(factors); return(NULL); } @@ -1076,23 +1040,20 @@ CheckTablesCacheAndReturn( } /* end of CheckTablesCacheAndReturn */ -/**Function******************************************************************** - - Synopsis [Check the tables for the existence of pair and return one - combination, store in cache.] +/** + @brief Check the tables for the existence of pair and return one + combination, store in cache. - Description [Check the tables for the existence of pair and return - one combination, store in cache. The pair that has more pointers to - it is picked. An approximation of the number of local pointers is - made by taking the reference count of the pairs sent. ] + @details The pair that has more pointers to it is picked. An + approximation of the number of local pointers is made by taking the + reference count of the pairs sent. - SideEffects [] + @see ZeroCase BuildConjuncts - SeeAlso [ZeroCase BuildConjuncts] - -******************************************************************************/ +*/ static Conjuncts * PickOnePair( + DdManager * manager, DdNode * node, DdNode * g1, DdNode * h1, @@ -1109,18 +1070,18 @@ PickOnePair( if (factors == NULL) return(NULL); /* count the number of pointers to pair 2 */ - if (h2 == one) { + if (h2 == DD_ONE(manager)) { twoRef = (Cudd_Regular(g2))->ref; - } else if (g2 == one) { + } else if (g2 == DD_ONE(manager)) { twoRef = (Cudd_Regular(h2))->ref; } else { twoRef = ((Cudd_Regular(g2))->ref + (Cudd_Regular(h2))->ref)/2; } /* count the number of pointers to pair 1 */ - if (h1 == one) { + if (h1 == DD_ONE(manager)) { oneRef = (Cudd_Regular(g1))->ref; - } else if (g1 == one) { + } else if (g1 == DD_ONE(manager)) { oneRef = (Cudd_Regular(h1))->ref; } else { oneRef = ((Cudd_Regular(g1))->ref + (Cudd_Regular(h1))->ref)/2; @@ -1139,44 +1100,44 @@ PickOnePair( * Store computed factors in respective tables to encourage * recombination. */ - if (factors->g != one) { + if (factors->g != DD_ONE(manager)) { /* insert g in htable */ value = 0; - if (st_lookup_int(ghTable, (char *)Cudd_Regular(factors->g), &value)) { + if (st_lookup_int(ghTable, Cudd_Regular(factors->g), &value)) { if (value == 2) { value |= 1; - if (st_insert(ghTable, (char *)Cudd_Regular(factors->g), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(factors->g), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { FREE(factors); return(NULL); } } } else { value = 1; - if (st_insert(ghTable, (char *)Cudd_Regular(factors->g), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(factors->g), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { FREE(factors); return(NULL); } } } - if (factors->h != one) { + if (factors->h != DD_ONE(manager)) { /* insert h in htable */ value = 0; - if (st_lookup_int(ghTable, (char *)Cudd_Regular(factors->h), &value)) { + if (st_lookup_int(ghTable, Cudd_Regular(factors->h), &value)) { if (value == 1) { value |= 2; - if (st_insert(ghTable, (char *)Cudd_Regular(factors->h), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(factors->h), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { FREE(factors); return(NULL); } } } else { value = 2; - if (st_insert(ghTable, (char *)Cudd_Regular(factors->h), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(factors->h), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { FREE(factors); return(NULL); } @@ -1184,7 +1145,7 @@ PickOnePair( } /* Store factors in cache table for later use. */ - if (st_insert(cacheTable, (char *)node, (char *)factors) == + if (st_insert(cacheTable, node, factors) == ST_OUT_OF_MEM) { FREE(factors); return(NULL); @@ -1195,22 +1156,18 @@ PickOnePair( } /* end of PickOnePair */ -/**Function******************************************************************** - - Synopsis [Check if the two pairs exist in the table, If any of the - conjuncts do exist, store in the cache and return the corresponding pair.] +/** + @brief Check if the two pairs exist in the table. - Description [Check if the two pairs exist in the table. If any of - the conjuncts do exist, store in the cache and return the - corresponding pair.] + @details If any of the conjuncts do exist, store in the cache and + return the corresponding pair. - SideEffects [] + @see ZeroCase BuildConjuncts - SeeAlso [ZeroCase BuildConjuncts] - -******************************************************************************/ +*/ static Conjuncts * CheckInTables( + DdManager * manager, DdNode * node, DdNode * g1, DdNode * h1, @@ -1258,10 +1215,10 @@ CheckInTables( /* g exists in the table, h is not found in either table */ factors->g = g1; factors->h = h1; - if (h1 != one) { + if (h1 != DD_ONE(manager)) { value = 2; - if (st_insert(ghTable, (char *)Cudd_Regular(h1), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(h1), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1271,10 +1228,10 @@ CheckInTables( /* g and h are found in the g table */ factors->g = g1; factors->h = h1; - if (h1 != one) { + if (h1 != DD_ONE(manager)) { value = 3; - if (st_insert(ghTable, (char *)Cudd_Regular(h1), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(h1), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1284,10 +1241,10 @@ CheckInTables( /* h exists in the table, g is not found in either table */ factors->g = g1; factors->h = h1; - if (g1 != one) { + if (g1 != DD_ONE(manager)) { value = 1; - if (st_insert(ghTable, (char *)Cudd_Regular(g1), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(g1), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1297,10 +1254,10 @@ CheckInTables( /* g and h are found in the h table */ factors->g = g1; factors->h = h1; - if (g1 != one) { + if (g1 != DD_ONE(manager)) { value = 3; - if (st_insert(ghTable, (char *)Cudd_Regular(g1), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(g1), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1310,10 +1267,10 @@ CheckInTables( /* g exists in the table, h is not found in either table */ factors->g = g2; factors->h = h2; - if (h2 != one) { + if (h2 != DD_ONE(manager)) { value = 2; - if (st_insert(ghTable, (char *)Cudd_Regular(h2), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(h2), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1323,10 +1280,10 @@ CheckInTables( /* g and h are found in the g table */ factors->g = g2; factors->h = h2; - if (h2 != one) { + if (h2 != DD_ONE(manager)) { value = 3; - if (st_insert(ghTable, (char *)Cudd_Regular(h2), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(h2), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1336,10 +1293,10 @@ CheckInTables( /* h exists in the table, g is not found in either table */ factors->g = g2; factors->h = h2; - if (g2 != one) { + if (g2 != DD_ONE(manager)) { value = 1; - if (st_insert(ghTable, (char *)Cudd_Regular(g2), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(g2), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1349,10 +1306,10 @@ CheckInTables( /* g and h are found in the h table */ factors->g = g2; factors->h = h2; - if (g2 != one) { + if (g2 != DD_ONE(manager)) { value = 3; - if (st_insert(ghTable, (char *)Cudd_Regular(g2), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(g2), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1362,10 +1319,10 @@ CheckInTables( /* g found in h table and h in none */ factors->g = h1; factors->h = g1; - if (h1 != one) { + if (h1 != DD_ONE(manager)) { value = 1; - if (st_insert(ghTable, (char *)Cudd_Regular(h1), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(h1), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1375,10 +1332,10 @@ CheckInTables( /* h found in g table and g in none */ factors->g = h1; factors->h = g1; - if (g1 != one) { + if (g1 != DD_ONE(manager)) { value = 2; - if (st_insert(ghTable, (char *)Cudd_Regular(g1), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(g1), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1388,10 +1345,10 @@ CheckInTables( /* g found in h table and h in none */ factors->g = h2; factors->h = g2; - if (h2 != one) { + if (h2 != DD_ONE(manager)) { value = 1; - if (st_insert(ghTable, (char *)Cudd_Regular(h2), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(h2), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1401,10 +1358,10 @@ CheckInTables( /* h found in g table and g in none */ factors->g = h2; factors->h = g2; - if (g2 != one) { + if (g2 != DD_ONE(manager)) { value = 2; - if (st_insert(ghTable, (char *)Cudd_Regular(g2), - (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(g2), + (void *)(ptruint)value) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); return(NULL); @@ -1413,7 +1370,7 @@ CheckInTables( } /* Store factors in cache table for later use. */ - if (st_insert(cacheTable, (char *)node, (char *)factors) == + if (st_insert(cacheTable, node, factors) == ST_OUT_OF_MEM) { *outOfMem = 1; FREE(factors); @@ -1424,21 +1381,19 @@ CheckInTables( -/**Function******************************************************************** - - Synopsis [If one child is zero, do explicitly what Restrict does or better] +/** + @brief If one child is zero, do explicitly what Restrict does or better - Description [If one child is zero, do explicitly what Restrict does or better. - First separate a variable and its child in the base case. In case of a cube - times a function, separate the cube and function. As a last resort, look in - tables.] + @details First separate a variable and its child in the base + case. In case of a cube times a function, separate the cube and + function. As a last resort, look in tables. - SideEffects [Frees the BDDs in factorsNv. factorsNv itself is not freed - because it is freed above.] + @sideeffect Frees the BDDs in factorsNv. factorsNv itself is not freed + because it is freed above. - SeeAlso [BuildConjuncts] + @see BuildConjuncts -******************************************************************************/ +*/ static Conjuncts * ZeroCase( DdManager * dd, @@ -1463,7 +1418,7 @@ ZeroCase( cuddRef(x); /* Seprate variable and child */ - if (factorsNv->g == one) { + if (factorsNv->g == DD_ONE(dd)) { Cudd_RecursiveDeref(dd, factorsNv->g); factors = ALLOC(Conjuncts, 1); if (factors == NULL) { @@ -1475,7 +1430,7 @@ ZeroCase( factors->g = x; factors->h = factorsNv->h; /* cache the result*/ - if (st_insert(cacheTable, (char *)node, (char *)factors) == ST_OUT_OF_MEM) { + if (st_insert(cacheTable, node, factors) == ST_OUT_OF_MEM) { dd->errorCode = CUDD_MEMORY_OUT; Cudd_RecursiveDeref(dd, factorsNv->h); Cudd_RecursiveDeref(dd, x); @@ -1484,12 +1439,12 @@ ZeroCase( } /* store x in g table, the other node is already in the table */ - if (st_lookup_int(ghTable, (char *)Cudd_Regular(x), &value)) { + if (st_lookup_int(ghTable, Cudd_Regular(x), &value)) { value |= 1; } else { value = 1; } - if (st_insert(ghTable, (char *)Cudd_Regular(x), (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(x), (void *)(ptruint)value) == ST_OUT_OF_MEM) { dd->errorCode = CUDD_MEMORY_OUT; return NULL; } @@ -1497,7 +1452,7 @@ ZeroCase( } /* Seprate variable and child */ - if (factorsNv->h == one) { + if (factorsNv->h == DD_ONE(dd)) { Cudd_RecursiveDeref(dd, factorsNv->h); factors = ALLOC(Conjuncts, 1); if (factors == NULL) { @@ -1509,7 +1464,7 @@ ZeroCase( factors->g = factorsNv->g; factors->h = x; /* cache the result. */ - if (st_insert(cacheTable, (char *)node, (char *)factors) == ST_OUT_OF_MEM) { + if (st_insert(cacheTable, node, factors) == ST_OUT_OF_MEM) { dd->errorCode = CUDD_MEMORY_OUT; Cudd_RecursiveDeref(dd, factorsNv->g); Cudd_RecursiveDeref(dd, x); @@ -1517,12 +1472,12 @@ ZeroCase( return(NULL); } /* store x in h table, the other node is already in the table */ - if (st_lookup_int(ghTable, (char *)Cudd_Regular(x), &value)) { + if (st_lookup_int(ghTable, Cudd_Regular(x), &value)) { value |= 2; } else { value = 2; } - if (st_insert(ghTable, (char *)Cudd_Regular(x), (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(x), (void *)(ptruint)value) == ST_OUT_OF_MEM) { dd->errorCode = CUDD_MEMORY_OUT; return NULL; } @@ -1535,7 +1490,7 @@ ZeroCase( Gv = Cudd_NotCond(Gv, Cudd_IsComplement(node)); Gnv = Cudd_NotCond(Gnv, Cudd_IsComplement(node)); /* if the child below is a variable */ - if ((Gv == zero) || (Gnv == zero)) { + if ((Gv == Cudd_Not(DD_ONE(dd))) || (Gnv == Cudd_Not(DD_ONE(dd)))) { h = factorsNv->h; g = cuddBddAndRecur(dd, x, factorsNv->g); if (g != NULL) cuddRef(g); @@ -1548,7 +1503,8 @@ ZeroCase( /* CheckTablesCacheAndReturn responsible for allocating * factors structure., g,h referenced for cache store the */ - factors = CheckTablesCacheAndReturn(node, + factors = CheckTablesCacheAndReturn(dd, + node, g, h, ghTable, @@ -1567,7 +1523,7 @@ ZeroCase( Hv = Cudd_NotCond(Hv, Cudd_IsComplement(node)); Hnv = Cudd_NotCond(Hnv, Cudd_IsComplement(node)); /* if the child below is a variable */ - if ((Hv == zero) || (Hnv == zero)) { + if ((Hv == Cudd_Not(DD_ONE(dd))) || (Hnv == Cudd_Not(DD_ONE(dd)))) { g = factorsNv->g; h = cuddBddAndRecur(dd, x, factorsNv->h); if (h!= NULL) cuddRef(h); @@ -1580,7 +1536,8 @@ ZeroCase( /* CheckTablesCacheAndReturn responsible for allocating * factors structure.g,h referenced for table store */ - factors = CheckTablesCacheAndReturn(node, + factors = CheckTablesCacheAndReturn(dd, + node, g, h, ghTable, @@ -1615,7 +1572,7 @@ ZeroCase( } /* check whether any pair is in tables */ - factors = CheckInTables(node, g1, h1, g2, h2, ghTable, cacheTable, &outOfMem); + factors = CheckInTables(dd, node, g1, h1, g2, h2, ghTable, cacheTable, &outOfMem); if (outOfMem) { dd->errorCode = CUDD_MEMORY_OUT; Cudd_RecursiveDeref(dd, g1); @@ -1636,7 +1593,7 @@ ZeroCase( } /* check for each pair in tables and choose one */ - factors = PickOnePair(node,g1, h1, g2, h2, ghTable, cacheTable); + factors = PickOnePair(dd, node,g1, h1, g2, h2, ghTable, cacheTable); if (factors == NULL) { dd->errorCode = CUDD_MEMORY_OUT; Cudd_RecursiveDeref(dd, g1); @@ -1658,25 +1615,21 @@ ZeroCase( } /* end of ZeroCase */ -/**Function******************************************************************** - - Synopsis [Builds the conjuncts recursively, bottom up.] +/** + @brief Builds the conjuncts recursively, bottom up. - Description [Builds the conjuncts recursively, bottom up. Constants - are returned as (f, f). The cache is checked for previously computed - result. The decomposition points are determined by the local - reference count of this node and the longest distance from the - constant. At the decomposition point, the factors returned are (f, - 1). Recur on the two children. The order is determined by the - heavier branch. Combine the factors of the two children and pick the - one that already occurs in the gh table. Occurence in g is indicated - by value 1, occurence in h by 2, occurence in both 3.] + @details Constants are returned as (f, f). The cache is checked for + previously computed result. The decomposition points are determined + by the local reference count of this node and the longest distance + from the constant. At the decomposition point, the factors returned + are (f, 1). Recur on the two children. The order is determined by + the heavier branch. Combine the factors of the two children and pick + the one that already occurs in the gh table. Occurence in g is + indicated by value 1, occurence in h by 2, occurence in both by 3. - SideEffects [] + @see cuddConjunctsAux - SeeAlso [cuddConjunctsAux] - -******************************************************************************/ +*/ static Conjuncts * BuildConjuncts( DdManager * dd, @@ -1686,11 +1639,12 @@ BuildConjuncts( int approxDistance, int maxLocalRef, st_table * ghTable, - st_table * mintermTable) + st_table * mintermTable, + int32_t *lastTimeG) { int topid, distance; - Conjuncts *factorsNv, *factorsNnv, *factors; - Conjuncts *dummy; + Conjuncts *factorsNv = NULL, *factorsNnv = NULL, *factors; + void *dummy; DdNode *N, *Nv, *Nnv, *temp, *g1, *g2, *h1, *h2, *topv; double minNv = 0.0, minNnv = 0.0; double *doubleDummy; @@ -1699,9 +1653,11 @@ BuildConjuncts( int freeNv = 0, freeNnv = 0, freeTemp; NodeStat *nodeStat; int value; + DdNode * const one = DD_ONE(dd); + DdNode * const zero = Cudd_Not(one); /* if f is constant, return (f,f) */ - if (Cudd_IsConstant(node)) { + if (Cudd_IsConstantInt(node)) { factors = ALLOC(Conjuncts, 1); if (factors == NULL) { dd->errorCode = CUDD_MEMORY_OUT; @@ -1714,13 +1670,13 @@ BuildConjuncts( /* If result (a pair of conjuncts) in cache, return the factors. */ if (st_lookup(cacheTable, node, &dummy)) { - factors = dummy; + factors = (Conjuncts *) dummy; return(factors); } - + /* check distance and local reference count of this node */ N = Cudd_Regular(node); - if (!st_lookup(distanceTable, N, &nodeStat)) { + if (!st_lookup(distanceTable, N, (void **) &nodeStat)) { (void) fprintf(dd->err, "Not in table, Something wrong\n"); dd->errorCode = CUDD_INTERNAL_ERROR; return(NULL); @@ -1738,16 +1694,16 @@ BuildConjuncts( } /* alternate assigning (f,1) */ value = 0; - if (st_lookup_int(ghTable, (char *)Cudd_Regular(node), &value)) { + if (st_lookup_int(ghTable, Cudd_Regular(node), &value)) { if (value == 3) { - if (!lastTimeG) { + if (!*lastTimeG) { factors->g = node; factors->h = one; - lastTimeG = 1; + *lastTimeG = 1; } else { factors->g = one; factors->h = node; - lastTimeG = 0; + *lastTimeG = 0; } } else if (value == 1) { factors->g = node; @@ -1756,12 +1712,12 @@ BuildConjuncts( factors->g = one; factors->h = node; } - } else if (!lastTimeG) { + } else if (!*lastTimeG) { factors->g = node; factors->h = one; - lastTimeG = 1; + *lastTimeG = 1; value = 1; - if (st_insert(ghTable, (char *)Cudd_Regular(node), (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(node), (void *)(ptruint)value) == ST_OUT_OF_MEM) { dd->errorCode = CUDD_MEMORY_OUT; FREE(factors); return NULL; @@ -1769,9 +1725,9 @@ BuildConjuncts( } else { factors->g = one; factors->h = node; - lastTimeG = 0; + *lastTimeG = 0; value = 2; - if (st_insert(ghTable, (char *)Cudd_Regular(node), (char *)(long)value) == ST_OUT_OF_MEM) { + if (st_insert(ghTable, Cudd_Regular(node), (void *)(ptruint)value) == ST_OUT_OF_MEM) { dd->errorCode = CUDD_MEMORY_OUT; FREE(factors); return NULL; @@ -1779,7 +1735,7 @@ BuildConjuncts( } return(FactorsComplement(factors)); } - + /* get the children and recur */ Nv = cuddT(N); Nnv = cuddE(N); @@ -1789,24 +1745,24 @@ BuildConjuncts( /* Choose which subproblem to solve first based on the number of * minterms. We go first where there are more minterms. */ - if (!Cudd_IsConstant(Nv)) { - if (!st_lookup(mintermTable, Nv, &doubleDummy)) { + if (!Cudd_IsConstantInt(Nv)) { + if (!st_lookup(mintermTable, Nv, (void **) &doubleDummy)) { (void) fprintf(dd->err, "Not in table: Something wrong\n"); dd->errorCode = CUDD_INTERNAL_ERROR; return(NULL); } minNv = *doubleDummy; } - - if (!Cudd_IsConstant(Nnv)) { - if (!st_lookup(mintermTable, Nnv, &doubleDummy)) { + + if (!Cudd_IsConstantInt(Nnv)) { + if (!st_lookup(mintermTable, Nnv, (void **) &doubleDummy)) { (void) fprintf(dd->err, "Not in table: Something wrong\n"); dd->errorCode = CUDD_INTERNAL_ERROR; return(NULL); } minNnv = *doubleDummy; } - + if (minNv < minNnv) { temp = Nv; Nv = Nnv; @@ -1818,13 +1774,13 @@ BuildConjuncts( if (Nv != zero) { factorsNv = BuildConjuncts(dd, Nv, distanceTable, cacheTable, approxDistance, maxLocalRef, - ghTable, mintermTable); + ghTable, mintermTable, lastTimeG); if (factorsNv == NULL) return(NULL); freeNv = FactorsNotStored(factorsNv); factorsNv = (freeNv) ? FactorsUncomplement(factorsNv) : factorsNv; cuddRef(factorsNv->g); cuddRef(factorsNv->h); - + /* Deal with the zero case */ if (Nnv == zero) { /* is responsible for freeing factorsNv */ @@ -1839,11 +1795,13 @@ BuildConjuncts( if (Nnv != zero) { factorsNnv = BuildConjuncts(dd, Nnv, distanceTable, cacheTable, approxDistance, maxLocalRef, - ghTable, mintermTable); + ghTable, mintermTable, lastTimeG); if (factorsNnv == NULL) { - Cudd_RecursiveDeref(dd, factorsNv->g); - Cudd_RecursiveDeref(dd, factorsNv->h); - if (freeNv) FREE(factorsNv); + if (factorsNv != NULL) { + Cudd_RecursiveDeref(dd, factorsNv->g); + Cudd_RecursiveDeref(dd, factorsNv->h); + if (freeNv) FREE(factorsNv); + } return(NULL); } freeNnv = FactorsNotStored(factorsNnv); @@ -1876,7 +1834,7 @@ BuildConjuncts( /* Build the factors for this node. */ topid = N->index; topv = dd->vars[topid]; - + g1 = cuddBddIteRecur(dd, topv, factorsNv->g, factorsNnv->g); if (g1 == NULL) { Cudd_RecursiveDeref(dd, factorsNv->g); @@ -1940,7 +1898,7 @@ BuildConjuncts( if (freeNnv) FREE(factorsNnv); /* check for each pair in tables and choose one */ - factors = CheckInTables(node, g1, h1, g2, h2, ghTable, cacheTable, &outOfMem); + factors = CheckInTables(dd, node, g1, h1, g2, h2, ghTable, cacheTable, &outOfMem); if (outOfMem) { dd->errorCode = CUDD_MEMORY_OUT; Cudd_RecursiveDeref(dd, g1); @@ -1961,7 +1919,7 @@ BuildConjuncts( } /* if not in tables, pick one pair */ - factors = PickOnePair(node,g1, h1, g2, h2, ghTable, cacheTable); + factors = PickOnePair(dd, node, g1, h1, g2, h2, ghTable, cacheTable); if (factors == NULL) { dd->errorCode = CUDD_MEMORY_OUT; Cudd_RecursiveDeref(dd, g1); @@ -1978,25 +1936,19 @@ BuildConjuncts( Cudd_RecursiveDeref(dd, h1); } } - - return(factors); - -} /* end of BuildConjuncts */ + return(factors); -/**Function******************************************************************** - - Synopsis [Procedure to compute two conjunctive factors of f and place in *c1 and *c2.] +} /* end of BuildConjuncts */ - Description [Procedure to compute two conjunctive factors of f and - place in *c1 and *c2. Sets up the required data - table of distances - from the constant and local reference count. Also minterm table. ] - SideEffects [] +/** + @brief Computes two conjunctive factors of f and places them in *c1 and *c2. - SeeAlso [] + @details Sets up the required data - table of distances from the + constant and local reference count. Also minterm table. -******************************************************************************/ +*/ static int cuddConjunctsAux( DdManager * dd, @@ -2016,7 +1968,8 @@ cuddConjunctsAux( int freeFactors; NodeStat *nodeStat; int maxLocalRef; - + int32_t lastTimeG; + /* initialize */ *c1 = NULL; *c2 = NULL; @@ -2030,7 +1983,7 @@ cuddConjunctsAux( if (nodeStat == NULL) goto outOfMem; nodeStat->distance = 0; nodeStat->localRef = 1; - if (st_insert(distanceTable, (char *)one, (char *)nodeStat) == ST_OUT_OF_MEM) { + if (st_insert(distanceTable, DD_ONE(dd), nodeStat) == ST_OUT_OF_MEM) { goto outOfMem; } @@ -2049,7 +2002,7 @@ cuddConjunctsAux( cuddRef(*c1); cuddRef(*c2); stGen = st_init_gen(distanceTable); if (stGen == NULL) goto outOfMem; - while(st_gen(stGen, (char **)&key, (char **)&value)) { + while(st_gen(stGen, (void **)&key, (void **)&value)) { FREE(value); } st_free_gen(stGen); stGen = NULL; @@ -2061,22 +2014,22 @@ cuddConjunctsAux( maxLocalRef = 0; stGen = st_init_gen(distanceTable); if (stGen == NULL) goto outOfMem; - while(st_gen(stGen, (char **)&key, (char **)&value)) { + while(st_gen(stGen, (void **)&key, (void **)&value)) { nodeStat = (NodeStat *)value; maxLocalRef = (nodeStat->localRef > maxLocalRef) ? nodeStat->localRef : maxLocalRef; } st_free_gen(stGen); stGen = NULL; - + /* Count minterms for each node. */ max = pow(2.0, (double)Cudd_SupportSize(dd,f)); /* potential overflow */ mintermTable = st_init_table(st_ptrcmp,st_ptrhash); if (mintermTable == NULL) goto outOfMem; - minterms = CountMinterms(f, max, mintermTable, dd->err); + minterms = CountMinterms(dd, f, max, mintermTable, dd->err); if (minterms == -1.0) goto outOfMem; - lastTimeG = Cudd_Random() & 1; + lastTimeG = Cudd_Random(dd) & 1; cacheTable = st_init_table(st_ptrcmp, st_ptrhash); if (cacheTable == NULL) goto outOfMem; ghTable = st_init_table(st_ptrcmp, st_ptrhash); @@ -2084,13 +2037,14 @@ cuddConjunctsAux( /* Build conjuncts. */ factors = BuildConjuncts(dd, f, distanceTable, cacheTable, - approxDistance, maxLocalRef, ghTable, mintermTable); + approxDistance, maxLocalRef, ghTable, + mintermTable, &lastTimeG); if (factors == NULL) goto outOfMem; /* free up tables */ stGen = st_init_gen(distanceTable); if (stGen == NULL) goto outOfMem; - while(st_gen(stGen, (char **)&key, (char **)&value)) { + while(st_gen(stGen, (void **)&key, (void **)&value)) { FREE(value); } st_free_gen(stGen); stGen = NULL; @@ -2099,7 +2053,7 @@ cuddConjunctsAux( stGen = st_init_gen(mintermTable); if (stGen == NULL) goto outOfMem; - while(st_gen(stGen, (char **)&key, (char **)&value)) { + while(st_gen(stGen, (void **)&key, (void **)&value)) { FREE(value); } st_free_gen(stGen); stGen = NULL; @@ -2115,17 +2069,17 @@ cuddConjunctsAux( if (freeFactors) FREE(factors); #if 0 - if ((*c1 == f) && (!Cudd_IsConstant(f))) { - assert(*c2 == one); + if ((*c1 == f) && (!Cudd_IsConstantInt(f))) { + assert(*c2 == DD_ONE(manager)); } - if ((*c2 == f) && (!Cudd_IsConstant(f))) { - assert(*c1 == one); + if ((*c2 == f) && (!Cudd_IsConstantInt(f))) { + assert(*c1 == DD_ONE(manager)); } - if ((*c1 != one) && (!Cudd_IsConstant(f))) { + if ((*c1 != DD_ONE(manager)) && (!Cudd_IsConstantInt(f))) { assert(!Cudd_bddLeq(dd, *c2, *c1)); } - if ((*c2 != one) && (!Cudd_IsConstant(f))) { + if ((*c2 != DD_ONE(manager)) && (!Cudd_IsConstantInt(f))) { assert(!Cudd_bddLeq(dd, *c1, *c2)); } #endif @@ -2133,7 +2087,7 @@ cuddConjunctsAux( stGen = st_init_gen(cacheTable); if (stGen == NULL) goto outOfMem; - while(st_gen(stGen, (char **)&key, (char **)&value)) { + while(st_gen(stGen, (void **)&key, (void **)&value)) { ConjunctsFree(dd, (Conjuncts *)value); } st_free_gen(stGen); stGen = NULL; @@ -2146,7 +2100,7 @@ outOfMem: if (distanceTable != NULL) { stGen = st_init_gen(distanceTable); if (stGen == NULL) goto outOfMem; - while(st_gen(stGen, (char **)&key, (char **)&value)) { + while(st_gen(stGen, (void **)&key, (void **)&value)) { FREE(value); } st_free_gen(stGen); stGen = NULL; @@ -2155,7 +2109,7 @@ outOfMem: if (mintermTable != NULL) { stGen = st_init_gen(mintermTable); if (stGen == NULL) goto outOfMem; - while(st_gen(stGen, (char **)&key, (char **)&value)) { + while(st_gen(stGen, (void **)&key, (void **)&value)) { FREE(value); } st_free_gen(stGen); stGen = NULL; @@ -2165,7 +2119,7 @@ outOfMem: if (cacheTable != NULL) { stGen = st_init_gen(cacheTable); if (stGen == NULL) goto outOfMem; - while(st_gen(stGen, (char **)&key, (char **)&value)) { + while(st_gen(stGen, (void **)&key, (void **)&value)) { ConjunctsFree(dd, (Conjuncts *)value); } st_free_gen(stGen); stGen = NULL; diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddEssent.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddEssent.c similarity index 69% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddEssent.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddEssent.c index 7af6df651..64d900049 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddEssent.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddEssent.c @@ -1,43 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddEssent.c] - - PackageName [cudd] - - Synopsis [Functions for the detection of essential variables.] - - Description [External procedures included in this file: - <ul> - <li> Cudd_FindEssential() - <li> Cudd_bddIsVarEssential() - <li> Cudd_FindTwoLiteralClauses() - <li> Cudd_ReadIthClause() - <li> Cudd_PrintTwoLiteralClauses() - <li> Cudd_tlcInfoFree() - </ul> - Static procedures included in this module: - <ul> - <li> ddFindEssentialRecur() - <li> ddFindTwoLiteralClausesRecur() - <li> computeClauses() - <li> computeClausesWithUniverse() - <li> emptyClauseSet() - <li> sentinelp() - <li> equalp() - <li> beforep() - <li> oneliteralp() - <li> impliedp() - <li> bitVectorAlloc() - <li> bitVectorClear() - <li> bitVectorFree() - <li> bitVectorRead() - <li> bitVectorSet() - <li> tlcInfoAlloc() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Functions for the detection of essential variables. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -67,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -79,7 +51,7 @@ /*---------------------------------------------------------------------------*/ /* These definitions are for the bit vectors. */ -#if SIZEOF_LONG == 8 +#if SIZEOF_VOID_P == 8 #define BPL 64 #define LOGBPL 6 #else @@ -91,8 +63,10 @@ /* Stucture declarations */ /*---------------------------------------------------------------------------*/ -/* This structure holds the set of clauses for a node. Each clause consists -** of two literals. For one-literal clauses, the second lietral is FALSE. +/** +** @brief This structure holds the set of clauses for a node. +** @details Each clause consists of two literals. +** For one-literal clauses, the second literal is FALSE. ** Each literal is composed of a variable and a phase. A variable is a node ** index, and requires sizeof(DdHalfWord) bytes. The constant literals use ** CUDD_MAXINDEX as variable indicator. Each phase is a bit: 0 for positive @@ -105,26 +79,30 @@ ** is the one of least index. So, the clause with literals +2 and -4 is stored ** as (+2,-4). A one-literal clause with literal +3 is stored as ** (+3,-CUDD_MAXINDEX). Clauses are sorted in decreasing order as follows: -** (+5,-7) -** (+5,+6) -** (-5,+7) -** (-4,FALSE) -** (-4,+8) -** ... +** <ul> +** <li> (+5,-7) +** <li> (+5,+6) +** <li> (-5,+7) +** <li> (-4,FALSE) +** <li> (-4,+8) +** <li> ... +** </ul> ** That is, one first looks at the variable of the first literal, then at the -** phase of the first litral, then at the variable of the second literal, +** phase of the first literal, then at the variable of the second literal, ** and finally at the phase of the second literal. */ struct DdTlcInfo { DdHalfWord *vars; - long *phases; + ptruint *phases; DdHalfWord cnt; }; -/* This structure is for temporary representation of sets of clauses. It is -** meant to be used in link lists, when the number of clauses is not yet -** known. The encoding of a clause is the same as in DdTlcInfo, though -** the phase information is not stored in a bit array. */ +/** +** @brief This structure is for temporary representation of sets of clauses. +** @details It is meant to be used in linked lists, when the number of clauses +** is not yet known. The encoding of a clause is the same as in DdTlcInfo, +** though the phase information is not stored in a bit array. +*/ struct TlClause { DdHalfWord v1, v2; short p1, p2; @@ -135,35 +113,26 @@ struct TlClause { /* Type declarations */ /*---------------------------------------------------------------------------*/ -typedef long BitVector; +typedef ptruint BitVector; typedef struct TlClause TlClause; /*---------------------------------------------------------------------------*/ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddEssent.c,v 1.25 2012/02/05 01:07:18 fabio Exp $"; -#endif - -static BitVector *Tolv; -static BitVector *Tolp; -static BitVector *Eolv; -static BitVector *Eolp; - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ static DdNode * ddFindEssentialRecur (DdManager *dd, DdNode *f); -static DdTlcInfo * ddFindTwoLiteralClausesRecur (DdManager * dd, DdNode * f, st_table *table); -static DdTlcInfo * computeClauses (DdTlcInfo *Tres, DdTlcInfo *Eres, DdHalfWord label, int size); +static DdTlcInfo * ddFindTwoLiteralClausesRecur (DdManager * dd, DdNode * f, st_table *table, BitVector *Tolv, BitVector *Tolp, BitVector *Eolv, BitVector *Eolp); +static DdTlcInfo * computeClauses (DdTlcInfo *Tres, DdTlcInfo *Eres, DdHalfWord label, int size, BitVector *Tolv, BitVector *Tolp, BitVector *Eolv, BitVector *Eolp); static DdTlcInfo * computeClausesWithUniverse (DdTlcInfo *Cres, DdHalfWord label, short phase); static DdTlcInfo * emptyClauseSet (void); static int sentinelp (DdHalfWord var1, DdHalfWord var2); @@ -172,13 +141,13 @@ static int beforep (DdHalfWord var1a, short phase1a, DdHalfWord var1b, short pha static int oneliteralp (DdHalfWord var); static int impliedp (DdHalfWord var1, short phase1, DdHalfWord var2, short phase2, BitVector *olv, BitVector *olp); static BitVector * bitVectorAlloc (int size); -DD_INLINE static void bitVectorClear (BitVector *vector, int size); +static void bitVectorClear (BitVector *vector, int size); static void bitVectorFree (BitVector *vector); -DD_INLINE static short bitVectorRead (BitVector *vector, int i); -DD_INLINE static void bitVectorSet (BitVector * vector, int i, short val); +static short bitVectorRead (BitVector *vector, int i); +static void bitVectorSet (BitVector * vector, int i, short val); static DdTlcInfo * tlcInfoAlloc (void); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -186,21 +155,21 @@ static DdTlcInfo * tlcInfoAlloc (void); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Finds the essential variables of a DD.] +/** + @brief Finds the essential variables of a %DD. - Description [Returns the cube of the essential variables. A positive + @details Returns the cube of the essential variables. A positive literal means that the variable must be set to 1 for the function to be 1. A negative literal means that the variable must be set to 0 for the - function to be 1. Returns a pointer to the cube BDD if successful; - NULL otherwise.] + function to be 1. - SideEffects [None] + @return a pointer to the cube %BDD if successful; NULL otherwise. - SeeAlso [Cudd_bddIsVarEssential] + @sideeffect None -******************************************************************************/ + @see Cudd_bddIsVarEssential + +*/ DdNode * Cudd_FindEssential( DdManager * dd, @@ -212,25 +181,26 @@ Cudd_FindEssential( dd->reordered = 0; res = ddFindEssentialRecur(dd,f); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_FindEssential */ -/**Function******************************************************************** - - Synopsis [Determines whether a given variable is essential with a - given phase in a BDD.] +/** + @brief Determines whether a given variable is essential with a + given phase in a %BDD. - Description [Determines whether a given variable is essential with a - given phase in a BDD. Uses Cudd_bddIteConstant. Returns 1 if phase == 1 - and f-->x_id, or if phase == 0 and f-->x_id'.] + @details Uses Cudd_bddIteConstant. Returns 1 if phase == 1 and + f-->x_id, or if phase == 0 and f-->x_id'. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_FindEssential] + @see Cudd_FindEssential -******************************************************************************/ +*/ int Cudd_bddIsVarEssential( DdManager * manager, @@ -252,23 +222,24 @@ Cudd_bddIsVarEssential( } /* end of Cudd_bddIsVarEssential */ -/**Function******************************************************************** +/** + @brief Finds the two literal clauses of a %DD. - Synopsis [Finds the two literal clauses of a DD.] + @details Returns the one- and two-literal clauses of a %DD. For a + constant %DD, the empty set of clauses is returned. This is + obviously correct for a non-zero constant. For the constant zero, + it is based on the assumption that only those clauses containing + variables in the support of the function are considered. Since the + support of a constant function is empty, no clauses are returned. - Description [Returns the one- and two-literal clauses of a DD. - Returns a pointer to the structure holding the clauses if - successful; NULL otherwise. For a constant DD, the empty set of clauses - is returned. This is obviously correct for a non-zero constant. For the - constant zero, it is based on the assumption that only those clauses - containing variables in the support of the function are considered. Since - the support of a constant function is empty, no clauses are returned.] + @return a pointer to the structure holding the clauses if + successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_FindEssential] + @see Cudd_FindEssential -******************************************************************************/ +*/ DdTlcInfo * Cudd_FindTwoLiteralClauses( DdManager * dd, @@ -280,8 +251,9 @@ Cudd_FindTwoLiteralClauses( DdTlcInfo *tlc; DdNode *node; int size = dd->size; + BitVector *Tolv, *Tolp, *Eolv, *Eolp; - if (Cudd_IsConstant(f)) { + if (Cudd_IsConstantInt(f)) { res = emptyClauseSet(); return(res); } @@ -314,9 +286,9 @@ Cudd_FindTwoLiteralClauses( return(NULL); } - res = ddFindTwoLiteralClausesRecur(dd,f,table); + res = ddFindTwoLiteralClausesRecur(dd,f,table,Tolv,Tolp,Eolv,Eolp); /* Dispose of table contents and free table. */ - st_foreach_item(table, gen, &node, &tlc) { + st_foreach_item(table, gen, (void **) &node, (void **) &tlc) { if (node != f) { Cudd_tlcInfoFree(tlc); } @@ -338,33 +310,34 @@ Cudd_FindTwoLiteralClauses( } /* end of Cudd_FindTwoLiteralClauses */ -/**Function******************************************************************** +/** + @brief Accesses the i-th clause of a %DD. - Synopsis [Accesses the i-th clause of a DD.] + @details Accesses the i-th clause of a %DD given the clause set which + must be already computed. - Description [Accesses the i-th clause of a DD given the clause set which - must be already computed. Returns 1 if successful; 0 if i is out of range, - or in case of error.] + @return 1 if successful; 0 if i is out of range, or in case of + error. - SideEffects [the four components of a clause are returned as side effects.] + @sideeffect the four components of a clause are returned as side effects. - SeeAlso [Cudd_FindTwoLiteralClauses] + @see Cudd_FindTwoLiteralClauses -******************************************************************************/ +*/ int Cudd_ReadIthClause( DdTlcInfo * tlc, int i, - DdHalfWord *var1, - DdHalfWord *var2, + unsigned *var1, + unsigned *var2, int *phase1, int *phase2) { if (tlc == NULL) return(0); if (tlc->vars == NULL || tlc->phases == NULL) return(0); if (i < 0 || (unsigned) i >= tlc->cnt) return(0); - *var1 = tlc->vars[2*i]; - *var2 = tlc->vars[2*i+1]; + *var1 = (unsigned) tlc->vars[2*i]; + *var2 = (unsigned) tlc->vars[2*i+1]; *phase1 = (int) bitVectorRead(tlc->phases, 2*i); *phase2 = (int) bitVectorRead(tlc->phases, 2*i+1); return(1); @@ -372,19 +345,19 @@ Cudd_ReadIthClause( } /* end of Cudd_ReadIthClause */ -/**Function******************************************************************** +/** + @brief Prints the one- and two-literal clauses of a %DD. - Synopsis [Prints the two literal clauses of a DD.] + @details The argument "names" can be NULL, in which case the + variable indices are printed. - Description [Prints the one- and two-literal clauses. Returns 1 if - successful; 0 otherwise. The argument "names" can be NULL, in which case - the variable indices are printed.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_FindTwoLiteralClauses] + @see Cudd_FindTwoLiteralClauses -******************************************************************************/ +*/ int Cudd_PrintTwoLiteralClauses( DdManager * dd, @@ -435,18 +408,14 @@ Cudd_PrintTwoLiteralClauses( } /* end of Cudd_PrintTwoLiteralClauses */ -/**Function******************************************************************** - - Synopsis [Frees a DdTlcInfo Structure.] +/** + @brief Frees a DdTlcInfo Structure. - Description [Frees a DdTlcInfo Structure as well as the memory pointed - by it.] + @details Also frees the memory pointed by it. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ void Cudd_tlcInfoFree( DdTlcInfo * t) @@ -468,16 +437,14 @@ Cudd_tlcInfoFree( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Implements the recursive step of Cudd_FindEssential. - Synopsis [Implements the recursive step of Cudd_FindEssential.] + @return a pointer to the cube %BDD if successful; NULL otherwise. - Description [Implements the recursive step of Cudd_FindEssential. - Returns a pointer to the cube BDD if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static DdNode * ddFindEssentialRecur( DdManager * dd, @@ -485,7 +452,7 @@ ddFindEssentialRecur( { DdNode *T, *E, *F; DdNode *essT, *essE, *res; - int index; + unsigned index; DdNode *one, *lzero, *azero; one = DD_ONE(dd); @@ -498,6 +465,8 @@ ddFindEssentialRecur( return(res); } + checkWhetherToGiveUp(dd); + lzero = Cudd_Not(one); azero = DD_ZERO(dd); /* Find cofactors: here f is non-constant. */ @@ -508,7 +477,7 @@ ddFindEssentialRecur( } index = F->index; - if (Cudd_IsConstant(T) && T != lzero && T != azero) { + if (Cudd_IsConstantInt(T) && T != lzero && T != azero) { /* if E is zero, index is essential, otherwise there are no ** essentials, because index is not essential and no other variable ** can be, since setting index = 1 makes the function constant and @@ -520,7 +489,7 @@ ddFindEssentialRecur( res = one; } } else if (T == lzero || T == azero) { - if (Cudd_IsConstant(E)) { /* E cannot be zero here */ + if (Cudd_IsConstantInt(E)) { /* E cannot be zero here */ res = Cudd_Not(dd->vars[index]); } else { /* E == non-constant */ /* find essentials in the else branch */ @@ -556,7 +525,7 @@ ddFindEssentialRecur( return(NULL); } cuddDeref(essT); - } else if (!Cudd_IsConstant(E)) { + } else if (!Cudd_IsConstantInt(E)) { /* if E is a non-zero constant there are no essentials ** because T is non-constant. */ @@ -598,25 +567,27 @@ ddFindEssentialRecur( } /* end of ddFindEssentialRecur */ -/**Function******************************************************************** +/** + @brief Implements the recursive step of Cudd_FindTwoLiteralClauses. - Synopsis [Implements the recursive step of Cudd_FindTwoLiteralClauses.] + @details The %DD node is assumed to be not constant. - Description [Implements the recursive step of - Cudd_FindTwoLiteralClauses. The DD node is assumed to be not - constant. Returns a pointer to a set of clauses if successful; NULL - otherwise.] + @return a pointer to a set of clauses if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_FindTwoLiteralClauses] + @see Cudd_FindTwoLiteralClauses -******************************************************************************/ +*/ static DdTlcInfo * ddFindTwoLiteralClausesRecur( DdManager * dd, DdNode * f, - st_table *table) + st_table *table, + BitVector *Tolv, + BitVector *Tolp, + BitVector *Eolv, + BitVector *Eolp) { DdNode *T, *E, *F; DdNode *one, *lzero, *azero; @@ -629,7 +600,7 @@ ddFindTwoLiteralClausesRecur( /* Check computed table. Separate entries are necessary for ** a node and its complement. We should update the counter here. */ - if (st_lookup(table, f, &res)) { + if (st_lookup(table, f, (void **) &res)) { return(res); } @@ -645,7 +616,7 @@ ddFindTwoLiteralClausesRecur( } index = F->index; - if (Cudd_IsConstant(T) && T != lzero && T != azero) { + if (Cudd_IsConstantInt(T) && T != lzero && T != azero) { /* T is a non-zero constant. If E is zero, then this node's index ** is a one-literal clause. Otherwise, if E is a non-zero ** constant, there are no clauses for this node. Finally, @@ -672,19 +643,21 @@ ddFindTwoLiteralClausesRecur( res->vars[3] = 0; bitVectorSet(res->phases, 0, 0); /* positive phase */ bitVectorSet(res->phases, 1, 1); /* negative phase */ - } else if (Cudd_IsConstant(E)) { + } else if (Cudd_IsConstantInt(E)) { /* If E is a non-zero constant, no clauses. */ res = emptyClauseSet(); } else { /* E is non-constant */ Tres = emptyClauseSet(); if (Tres == NULL) return(NULL); - Eres = ddFindTwoLiteralClausesRecur(dd, E, table); + Eres = ddFindTwoLiteralClausesRecur(dd, E, table, + Tolv, Tolp, Eolv, Eolp); if (Eres == NULL) { Cudd_tlcInfoFree(Tres); return(NULL); } - res = computeClauses(Tres, Eres, index, dd->size); + res = computeClauses(Tres, Eres, index, dd->size, + Tolv, Tolp, Eolv, Eolp); Cudd_tlcInfoFree(Tres); } } else if (T == lzero || T == azero) { @@ -692,7 +665,7 @@ ddFindTwoLiteralClausesRecur( ** complement of this node's index is a one-literal clause. ** Otherwise, if E is not constant, we recursively compute its ** clauses, and then merge using the universal set for T. */ - if (Cudd_IsConstant(E)) { /* E cannot be zero here */ + if (Cudd_IsConstantInt(E)) { /* E cannot be zero here */ /* Create the clause (!index + 0). */ res = tlcInfoAlloc(); if (res == NULL) return(NULL); @@ -714,31 +687,36 @@ ddFindTwoLiteralClausesRecur( bitVectorSet(res->phases, 0, 1); /* negative phase */ bitVectorSet(res->phases, 1, 1); /* negative phase */ } else { /* E == non-constant */ - Eres = ddFindTwoLiteralClausesRecur(dd, E, table); + Eres = ddFindTwoLiteralClausesRecur(dd, E, table, + Tolv, Tolp, Eolv, Eolp); if (Eres == NULL) return(NULL); res = computeClausesWithUniverse(Eres, index, 1); } } else { /* T == non-const */ - Tres = ddFindTwoLiteralClausesRecur(dd, T, table); + Tres = ddFindTwoLiteralClausesRecur(dd, T, table, + Tolv, Tolp, Eolv, Eolp); if (Tres == NULL) return(NULL); - if (Cudd_IsConstant(E)) { + if (Cudd_IsConstantInt(E)) { if (E == lzero || E == azero) { res = computeClausesWithUniverse(Tres, index, 0); } else { Eres = emptyClauseSet(); if (Eres == NULL) return(NULL); - res = computeClauses(Tres, Eres, index, dd->size); + res = computeClauses(Tres, Eres, index, dd->size, + Tolv, Tolp, Eolv, Eolp); Cudd_tlcInfoFree(Eres); } } else { - Eres = ddFindTwoLiteralClausesRecur(dd, E, table); + Eres = ddFindTwoLiteralClausesRecur(dd, E, table, + Tolv, Tolp, Eolv, Eolp); if (Eres == NULL) return(NULL); - res = computeClauses(Tres, Eres, index, dd->size); + res = computeClauses(Tres, Eres, index, dd->size, + Tolv, Tolp, Eolv, Eolp); } } /* Cache results. */ - if (st_add_direct(table, (char *)f, (char *)res) == ST_OUT_OF_MEM) { + if (st_add_direct(table, f, res) == ST_OUT_OF_MEM) { FREE(res); return(NULL); } @@ -747,25 +725,30 @@ ddFindTwoLiteralClausesRecur( } /* end of ddFindTwoLiteralClausesRecur */ -/**Function******************************************************************** +/** + @brief Computes the two-literal clauses for a node. - Synopsis [Computes the two-literal clauses for a node.] + @details Computes the two-literal clauses for a node given the + clauses for its children and the label of the node. - Description [Computes the two-literal clauses for a node given the - clauses for its children and the label of the node. Returns a - pointer to a TclInfo structure if successful; NULL otherwise.] + @return a pointer to a TclInfo structure if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [computeClausesWithUniverse] + @see computeClausesWithUniverse -******************************************************************************/ +*/ static DdTlcInfo * computeClauses( - DdTlcInfo *Tres /* list of clauses for T child */, - DdTlcInfo *Eres /* list of clauses for E child */, - DdHalfWord label /* variable labeling the current node */, - int size /* number of variables in the manager */) + DdTlcInfo *Tres /**< list of clauses for T child */, + DdTlcInfo *Eres /**< list of clauses for E child */, + DdHalfWord label /**< variable labeling the current node */, + int size /**< number of variables in the manager */, + BitVector *Tolv /**< variable bit vector for T child */, + BitVector *Tolp /**< phase bit vector for T child */, + BitVector *Eolv /**< variable bit vector for E child */, + BitVector *Eolp /**< phase bit vector for E child */) { DdHalfWord *Tcv = Tres->vars; /* variables of clauses for the T child */ BitVector *Tcp = Tres->phases; /* phases of clauses for the T child */ @@ -1046,20 +1029,21 @@ computeClauses( } /* end of computeClauses */ -/**Function******************************************************************** +/** + @brief Computes the two-literal clauses for a node. - Synopsis [Computes the two-literal clauses for a node.] - - Description [Computes the two-literal clauses for a node with a zero + @details Computes the two-literal clauses for a node with a zero child, given the clauses for its other child and the label of the - node. Returns a pointer to a TclInfo structure if successful; NULL - otherwise.] + node. + + @return a pointer to a TclInfo structure if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [computeClauses] + @see computeClauses -******************************************************************************/ +*/ static DdTlcInfo * computeClausesWithUniverse( DdTlcInfo *Cres /* list of clauses for child */, @@ -1119,19 +1103,17 @@ computeClausesWithUniverse( } /* end of computeClausesWithUniverse */ -/**Function******************************************************************** +/** + @brief Returns an enpty set of clauses. - Synopsis [Returns an enpty set of clauses.] + @details No bit vector for the phases is allocated. - Description [Returns a pointer to an empty set of clauses if - successful; NULL otherwise. No bit vector for the phases is - allocated.] + @return a pointer to an empty set of clauses if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static DdTlcInfo * emptyClauseSet(void) { @@ -1154,18 +1136,14 @@ emptyClauseSet(void) } /* end of emptyClauseSet */ -/**Function******************************************************************** - - Synopsis [Returns true iff the argument is the sentinel clause.] - - Description [Returns true iff the argument is the sentinel clause. - A sentinel clause has both variables equal to 0.] +/** + @brief Returns true iff the argument is the sentinel clause. - SideEffects [None] + @details A sentinel clause has both variables equal to 0. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int sentinelp( DdHalfWord var1, @@ -1176,19 +1154,17 @@ sentinelp( } /* end of sentinelp */ -/**Function******************************************************************** - - Synopsis [Returns true iff the two arguments are identical clauses.] +/** + @brief Returns true iff the two arguments are identical clauses. - Description [Returns true iff the two arguments are identical - clauses. Since literals are sorted, we only need to compare - literals in the same position.] + @details Since literals are sorted, we only need to compare literals + in the same position. - SideEffects [None] + @sideeffect None - SeeAlso [beforep] + @see beforep -******************************************************************************/ +*/ static int equalp( DdHalfWord var1a, @@ -1206,25 +1182,23 @@ equalp( } /* end of equalp */ -/**Function******************************************************************** - - Synopsis [Returns true iff the first argument precedes the second in - the clause order.] +/** + @brief Returns true iff the first argument precedes the second in + the clause order. - Description [Returns true iff the first argument precedes the second - in the clause order. A clause precedes another if its first lieral + @details A clause precedes another if its first lieral precedes the first literal of the other, or if the first literals are the same, and its second literal precedes the second literal of the other clause. A literal precedes another if it has a higher index, of if it has the same index, but it has lower phase. Phase 0 is the positive phase, and it is lower than Phase 1 (negative - phase).] + phase). - SideEffects [None] + @sideeffect None - SeeAlso [equalp] + @see equalp -******************************************************************************/ +*/ static int beforep( DdHalfWord var1a, @@ -1243,20 +1217,16 @@ beforep( } /* end of beforep */ -/**Function******************************************************************** - - Synopsis [Returns true iff the argument is a one-literal clause.] +/** + @brief Returns true iff the argument is a one-literal clause. - Description [Returns true iff the argument is a one-literal clause. - A one-litaral clause has the constant FALSE as second literal. - Since the constant TRUE is never used, it is sufficient to test for - a constant.] + @details A one-litaral clause has the constant FALSE as second + literal. Since the constant TRUE is never used, it is sufficient to + test for a constant. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int oneliteralp( DdHalfWord var) @@ -1266,20 +1236,16 @@ oneliteralp( } /* end of oneliteralp */ -/**Function******************************************************************** +/** + @brief Returns true iff either literal of a clause is in a set of + literals. - Synopsis [Returns true iff either literal of a clause is in a set of - literals.] + @details The first four arguments specify the clause. The remaining + two arguments specify the literal set. - Description [Returns true iff either literal of a clause is in a set - of literals. The first four arguments specify the clause. The - remaining two arguments specify the literal set.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static int impliedp( DdHalfWord var1, @@ -1297,20 +1263,21 @@ impliedp( } /* end of impliedp */ -/**Function******************************************************************** +/** + @brief Allocates a bit vector. - Synopsis [Allocates a bit vector.] + @details The parameter size gives the number of bits. This + procedure allocates enough words to hold the specified number of + bits. - Description [Allocates a bit vector. The parameter size gives the - number of bits. This procedure allocates enough long's to hold the - specified number of bits. Returns a pointer to the allocated vector - if successful; NULL otherwise.] + @return a pointer to the allocated vector if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [bitVectorClear bitVectorFree] + @see bitVectorClear bitVectorFree -******************************************************************************/ +*/ static BitVector * bitVectorAlloc( int size) @@ -1318,8 +1285,8 @@ bitVectorAlloc( int allocSize; BitVector *vector; - /* Find out how many long's we need. - ** There are sizeof(long) * 8 bits in a long. + /* Find out how many words we need. + ** There are sizeof(ptruint) * 8 bits in a ptruint. ** The ceiling of the ratio of two integers m and n is given ** by ((n-1)/m)+1. Putting all this together, we get... */ allocSize = ((size - 1) / (sizeof(BitVector) * 8)) + 1; @@ -1332,19 +1299,16 @@ bitVectorAlloc( } /* end of bitVectorAlloc */ -/**Function******************************************************************** - - Synopsis [Clears a bit vector.] +/** + @brief Clears a bit vector. - Description [Clears a bit vector. The parameter size gives the - number of bits.] + @details The parameter size gives the number of bits. - SideEffects [None] + @sideeffect None - SeeAlso [bitVectorAlloc] + @see bitVectorAlloc -******************************************************************************/ -DD_INLINE +*/ static void bitVectorClear( BitVector *vector, @@ -1352,8 +1316,8 @@ bitVectorClear( { int allocSize; - /* Find out how many long's we need. - ** There are sizeof(long) * 8 bits in a long. + /* Find out how many words we need. + ** There are sizeof(ptruint) * 8 bits in a ptruint. ** The ceiling of the ratio of two integers m and n is given ** by ((n-1)/m)+1. Putting all this together, we get... */ allocSize = ((size - 1) / (sizeof(BitVector) * 8)) + 1; @@ -1364,17 +1328,14 @@ bitVectorClear( } /* end of bitVectorClear */ -/**Function******************************************************************** - - Synopsis [Frees a bit vector.] +/** + @brief Frees a bit vector. - Description [Frees a bit vector.] + @sideeffect None - SideEffects [None] + @see bitVectorAlloc - SeeAlso [bitVectorAlloc] - -******************************************************************************/ +*/ static void bitVectorFree( BitVector *vector) @@ -1384,18 +1345,14 @@ bitVectorFree( } /* end of bitVectorFree */ -/**Function******************************************************************** - - Synopsis [Returns the i-th entry of a bit vector.] +/** + @brief Returns the i-th entry of a bit vector. - Description [Returns the i-th entry of a bit vector.] + @sideeffect None - SideEffects [None] + @see bitVectorSet - SeeAlso [bitVectorSet] - -******************************************************************************/ -DD_INLINE +*/ static short bitVectorRead( BitVector *vector, @@ -1408,24 +1365,20 @@ bitVectorRead( word = i >> LOGBPL; bit = i & (BPL - 1); - result = (short) ((vector[word] >> bit) & 1L); + result = (short) ((vector[word] >> bit) & (ptruint) 1); return(result); } /* end of bitVectorRead */ -/**Function******************************************************************** - - Synopsis [Sets the i-th entry of a bit vector to a value.] - - Description [Sets the i-th entry of a bit vector to a value.] +/** + @brief Sets the i-th entry of a bit vector to a value. - SideEffects [None] + @sideeffect None - SeeAlso [bitVectorRead] + @see bitVectorRead -******************************************************************************/ -DD_INLINE +*/ static void bitVectorSet( BitVector * vector, @@ -1436,24 +1389,23 @@ bitVectorSet( word = i >> LOGBPL; bit = i & (BPL - 1); - vector[word] &= ~(1L << bit); - vector[word] |= (((long) val) << bit); + vector[word] &= ~((ptruint) 1 << bit); + vector[word] |= (((ptruint) val) << bit); } /* end of bitVectorSet */ -/**Function******************************************************************** - - Synopsis [Allocates a DdTlcInfo Structure.] +/** + @brief Allocates a DdTlcInfo Structure. - Description [Returns a pointer to a DdTlcInfo Structure if successful; - NULL otherwise.] + @return a pointer to a DdTlcInfo Structure if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_tlcInfoFree] + @see Cudd_tlcInfoFree -******************************************************************************/ +*/ static DdTlcInfo * tlcInfoAlloc(void) { diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddExact.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddExact.c similarity index 67% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddExact.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddExact.c index caffbba88..0e07eb226 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddExact.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddExact.c @@ -1,39 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddExact.c] - - PackageName [cudd] - - Synopsis [Functions for exact variable reordering.] - - Description [External procedures included in this file: - <ul> - </ul> - Internal procedures included in this module: - <ul> - <li> cuddExact() - </ul> - Static procedures included in this module: - <ul> - <li> getMaxBinomial() - <li> gcd() - <li> getMatrix() - <li> freeMatrix() - <li> getLevelKeys() - <li> ddShuffle() - <li> ddSiftUp() - <li> updateUB() - <li> ddCountRoots() - <li> ddClearGlobal() - <li> computeLB() - <li> updateEntry() - <li> pushDown() - <li> initSymmInfo() - </ul>] - - Author [Cheng Hua, Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Functions for exact variable reordering. + + @author Cheng Hua, Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -63,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -74,7 +50,6 @@ /* Constant declarations */ /*---------------------------------------------------------------------------*/ - /*---------------------------------------------------------------------------*/ /* Stucture declarations */ /*---------------------------------------------------------------------------*/ @@ -87,19 +62,11 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddExact.c,v 1.30 2012/02/05 01:07:18 fabio Exp $"; -#endif - -#ifdef DD_STATS -static int ddTotalShuffles; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -120,7 +87,7 @@ static void pushDown (DdHalfWord *order, int j, int level); static DdHalfWord * initSymmInfo (DdManager *table, int lower, int upper); static int checkSymmInfo (DdManager *table, DdHalfWord *symmInfo, int index, int level); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -132,19 +99,17 @@ static int checkSymmInfo (DdManager *table, DdHalfWord *symmInfo, int index, int /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Exact variable ordering algorithm. - Synopsis [Exact variable ordering algorithm.] + @details Finds an optimum order for the variables between lower and + upper. - Description [Exact variable ordering algorithm. Finds an optimum - order for the variables between lower and upper. Returns 1 if - successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int cuddExact( DdManager * table, @@ -191,7 +156,7 @@ cuddExact( #ifdef DD_STATS (void) fprintf(table->out,"\n"); - ddTotalShuffles = 0; + table->totalShuffles = 0; ddTotalSubsets = 0; #endif @@ -243,12 +208,12 @@ cuddExact( for (i = 0; i < size; i++) { oldOrder[0][i] = bestOrder[i] = (DdHalfWord) table->invperm[i+lower]; } - subsetCost = table->constants.keys; + subsetCost = (int) table->constants.keys; for (i = upper + 1; i < nvars; i++) subsetCost += getLevelKeys(table,i); oldCost[0] = subsetCost; /* The upper bound is initialized to the current size of the BDDs. */ - upperBound = table->keys - table->isolated; + upperBound = (int) (table->keys - table->isolated); /* Now consider subsets of increasing size. */ for (k = 1; k <= size; k++) { @@ -282,7 +247,7 @@ cuddExact( lower, upper); if (j == 0) break; - if (checkSymmInfo(table, symmInfo, order[j-1], level) == 0) + if (checkSymmInfo(table, symmInfo, (int) order[j-1], level) == 0) continue; pushDown(order,j-1,level); /* Impose new order. */ @@ -310,7 +275,7 @@ cuddExact( (void) fprintf(table->out,"#:S_EXACT %8d: total subsets\n", ddTotalSubsets); (void) fprintf(table->out,"#:H_EXACT %8d: total shuffles", - ddTotalShuffles); + table->totalShuffles); #endif freeMatrix(newOrder); @@ -337,24 +302,21 @@ cuddExactOutOfMem: } /* end of cuddExact */ -/**Function******************************************************************** - - Synopsis [Returns the maximum value of (n choose k) for a given n.] +/** + @brief Returns the maximum value of `(n choose k)` for a given `n`. - Description [Computes the maximum value of (n choose k) for a given - n. The maximum value occurs for k = n/2 when n is even, or k = - (n-1)/2 when n is odd. The algorithm used in this procedure avoids + @details Computes the maximum value of `(n choose k)` for a given + `n`. The maximum value occurs for `k = n/2` when `n` is even, or `k = + (n-1)/2` when `n` is odd. The algorithm used in this procedure avoids intermediate overflow problems. It is based on the identity - <pre> - binomial(n,k) = n/k * binomial(n-1,k-1). - </pre> - Returns the computed value if successful; -1 if out of range.] - SideEffects [None] + binomial(n,k) = n/k * binomial(n-1,k-1). + + @return the computed value if successful; -1 if out of range. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int getMaxBinomial( int n) @@ -375,18 +337,15 @@ getMaxBinomial( #if 0 -/**Function******************************************************************** - - Synopsis [Returns the gcd of two integers.] - - Description [Returns the gcd of two integers. Uses the binary GCD - algorithm described in Cormen, Leiserson, and Rivest.] +/** + @brief Returns the gcd of two integers. - SideEffects [None] + @details Uses the binary GCD algorithm described in Cormen, + Leiserson, and Rivest. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int gcd( int x, @@ -431,18 +390,16 @@ gcd( #endif -/**Function******************************************************************** +/** + @brief Allocates a two-dimensional matrix of ints. - Synopsis [Allocates a two-dimensional matrix of ints.] + @return the pointer to the matrix if successful; NULL otherwise. - Description [Allocates a two-dimensional matrix of ints. - Returns the pointer to the matrix if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see freeMatrix - SeeAlso [freeMatrix] - -******************************************************************************/ +*/ static DdHalfWord ** getMatrix( int rows /* number of rows */, @@ -467,17 +424,14 @@ getMatrix( } /* end of getMatrix */ -/**Function******************************************************************** - - Synopsis [Frees a two-dimensional matrix allocated by getMatrix.] - - Description [] +/** + @brief Frees a two-dimensional matrix allocated by getMatrix. - SideEffects [None] + @sideeffect None - SeeAlso [getMatrix] + @see getMatrix -******************************************************************************/ +*/ static void freeMatrix( DdHalfWord ** matrix) @@ -489,18 +443,14 @@ freeMatrix( } /* end of freeMatrix */ -/**Function******************************************************************** - - Synopsis [Returns the number of nodes at one level of a unique table.] - - Description [Returns the number of nodes at one level of a unique table. - The projection function, if isolated, is not counted.] +/** + @brief Returns the number of nodes at one level of a unique table. - SideEffects [None] + @details The projection function, if isolated, is not counted. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int getLevelKeys( DdManager * table, @@ -512,27 +462,25 @@ getLevelKeys( x = table->invperm[l]; isolated = table->vars[x]->ref == 1; - return(table->subtables[l].keys - isolated); + return((int) table->subtables[l].keys - isolated); } /* end of getLevelKeys */ -/**Function******************************************************************** +/** + @brief Reorders variables according to a given permutation. - Synopsis [Reorders variables according to a given permutation.] + @details The i-th permutation array contains the index of the + variable that should be brought to the i-th level. ddShuffle assumes + that no dead nodes are present and that the interaction matrix is + properly initialized. The reordering is achieved by a series of + upward sifts. - Description [Reorders variables according to a given permutation. - The i-th permutation array contains the index of the variable that - should be brought to the i-th level. ddShuffle assumes that no - dead nodes are present and that the interaction matrix is properly - initialized. The reordering is achieved by a series of upward sifts. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int ddShuffle( DdManager * table, @@ -547,24 +495,19 @@ ddShuffle( int numvars; #endif int result; -#ifdef DD_STATS - unsigned long localTime; +#if defined(DD_STATS) && defined(DD_VERBOSE) int initialSize; -#ifdef DD_VERBOSE int finalSize; #endif - int previousSize; -#endif -#ifdef DD_STATS - localTime = util_cpu_time(); - initialSize = table->keys - table->isolated; +#if defined(DD_STATS) && defined(DD_VERBOSE) + initialSize = (int) (table->keys - table->isolated); #endif #if 0 numvars = table->size; - (void) fprintf(table->out,"%d:", ddTotalShuffles); + (void) fprintf(table->out,"%d:", table->totalShuffles); for (level = 0; level < numvars; level++) { (void) fprintf(table->out," %d", table->invperm[level]); } @@ -574,17 +517,14 @@ ddShuffle( for (level = 0; level <= upper - lower; level++) { index = permutation[level]; position = table->perm[index]; -#ifdef DD_STATS - previousSize = table->keys - table->isolated; -#endif result = ddSiftUp(table,position,level+lower); if (!result) return(0); } #ifdef DD_STATS - ddTotalShuffles++; + table->totalShuffles++; #ifdef DD_VERBOSE - finalSize = table->keys - table->isolated; + finalSize = (int) (table->keys - table->isolated); if (finalSize < initialSize) { (void) fprintf(table->out,"-"); } else if (finalSize > initialSize) { @@ -592,7 +532,7 @@ ddShuffle( } else { (void) fprintf(table->out,"="); } - if ((ddTotalShuffles & 63) == 0) (void) fprintf(table->out,"\n"); + if ((table->totalShuffles & 63) == 0) (void) fprintf(table->out,"\n"); fflush(table->out); #endif #endif @@ -602,19 +542,17 @@ ddShuffle( } /* end of ddShuffle */ -/**Function******************************************************************** - - Synopsis [Moves one variable up.] +/** + @brief Moves one variable up. - Description [Takes a variable from position x and sifts it up to + @details Takes a variable from position x and sifts it up to position xLow; xLow should be less than or equal to x. - Returns 1 if successful; 0 otherwise] - SideEffects [None] + @return 1 if successful; 0 otherwise - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int ddSiftUp( DdManager * table, @@ -638,18 +576,14 @@ ddSiftUp( } /* end of ddSiftUp */ -/**Function******************************************************************** - - Synopsis [Updates the upper bound and saves the best order seen so far.] - - Description [Updates the upper bound and saves the best order seen so far. - Returns the current value of the upper bound.] +/** + @brief Updates the upper bound and saves the best order seen so far. - SideEffects [None] + @return the current value of the upper bound. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int updateUB( DdManager * table, @@ -659,7 +593,7 @@ updateUB( int upper) { int i; - int newBound = table->keys - table->isolated; + int newBound = (int) (table->keys - table->isolated); if (newBound < oldBound) { #ifdef DD_STATS @@ -676,22 +610,23 @@ updateUB( } /* end of updateUB */ -/**Function******************************************************************** +/** + @brief Counts the number of roots. - Synopsis [Counts the number of roots.] + @details Counts the number of roots at the levels between lower and + upper. The computation is based on breadth-first search. A node is + a root if it is not reachable from any previously visited node. + (All the nodes at level lower are therefore considered roots.) The + roots that are constant nodes are always ignored. The visited flag + uses the LSB of the next pointer. - Description [Counts the number of roots at the levels between lower and - upper. The computation is based on breadth-first search. - A node is a root if it is not reachable from any previously visited node. - (All the nodes at level lower are therefore considered roots.) - The visited flag uses the LSB of the next pointer. Returns the root - count. The roots that are constant nodes are always ignored.] + @return the root count. - SideEffects [None] + @sideeffect None - SeeAlso [ddClearGlobal] + @see ddClearGlobal -******************************************************************************/ +*/ static int ddCountRoots( DdManager * table, @@ -708,7 +643,7 @@ ddCountRoots( for (i = lower; i <= upper; i++) { nodelist = table->subtables[i].nodelist; - slots = table->subtables[i].slots; + slots = (int) table->subtables[i].slots; for (j = 0; j < slots; j++) { f = nodelist[j]; while (f != sentinel) { @@ -723,12 +658,12 @@ ddCountRoots( roots++; } } - if (!Cudd_IsConstant(cuddT(f))) { + if (!cuddIsConstant(cuddT(f))) { cuddT(f)->next = Cudd_Complement(cuddT(f)->next); if (table->perm[cuddT(f)->index] > maxlevel) maxlevel = table->perm[cuddT(f)->index]; } - if (!Cudd_IsConstant(cuddE(f))) { + if (!Cudd_IsConstantInt(cuddE(f))) { Cudd_Regular(cuddE(f))->next = Cudd_Complement(Cudd_Regular(cuddE(f))->next); if (table->perm[Cudd_Regular(cuddE(f))->index] > maxlevel) @@ -745,20 +680,18 @@ ddCountRoots( } /* end of ddCountRoots */ -/**Function******************************************************************** +/** + @brief Scans the %DD and clears the LSB of the next pointers. - Synopsis [Scans the DD and clears the LSB of the next pointers.] + @details The LSB of the next pointers are used as markers to tell + whether a node was reached. Once the roots are counted, these flags + are reset. - Description [Scans the DD and clears the LSB of the next pointers. - The LSB of the next pointers are used as markers to tell whether a - node was reached. Once the roots are counted, these flags are - reset.] + @sideeffect None - SideEffects [None] + @see ddCountRoots - SeeAlso [ddCountRoots] - -******************************************************************************/ +*/ static void ddClearGlobal( DdManager * table, @@ -773,7 +706,7 @@ ddClearGlobal( for (i = lower; i <= maxlevel; i++) { nodelist = table->subtables[i].nodelist; - slots = table->subtables[i].slots; + slots = (int) table->subtables[i].slots; for (j = 0; j < slots; j++) { f = nodelist[j]; while (f != sentinel) { @@ -786,34 +719,30 @@ ddClearGlobal( } /* end of ddClearGlobal */ -/**Function******************************************************************** - - Synopsis [Computes a lower bound on the size of a BDD.] +/** + @brief Computes a lower bound on the size of a %BDD. - Description [Computes a lower bound on the size of a BDD from the - following factors: + @details The lower bound depends on the following factors: <ul> <li> size of the lower part of it; <li> size of the part of the upper part not subjected to reordering; - <li> number of roots in the part of the BDD subjected to reordering; + <li> number of roots in the part of the %BDD subjected to reordering; <li> variable in the support of the roots in the upper part of the - BDD subjected to reordering. - <ul/>] - - SideEffects [None] + %BDD subjected to reordering. + </ul> - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int computeLB( - DdManager * table /* manager */, - DdHalfWord * order /* optimal order for the subset */, - int roots /* roots between lower and upper */, - int cost /* minimum cost for the subset */, - int lower /* lower level to be reordered */, - int upper /* upper level to be reordered */, - int level /* offset for the current top bottom var */ + DdManager * table /**< manager */, + DdHalfWord * order /**< optimal order for the subset */, + int roots /**< roots between lower and upper */, + int cost /**< minimum cost for the subset */, + int lower /**< lower level to be reordered */, + int upper /**< upper level to be reordered */, + int level /**< offset for the current top bottom var */ ) { int i; @@ -845,8 +774,8 @@ computeLB( ref = table->vars[order[level+1]]->ref; else ref = table->vars[table->invperm[upper+1]]->ref; - lb2 = table->subtables[lower+level+1].keys - - (ref > (DdHalfWord) 1) - roots; + lb2 = (int) table->subtables[lower+level+1].keys - + (ref > (DdHalfWord) 1) - roots; } else { lb2 = 0; } @@ -858,20 +787,18 @@ computeLB( } /* end of computeLB */ -/**Function******************************************************************** +/** + @brief Updates entry for a subset. - Synopsis [Updates entry for a subset.] + @details Finds the subset, if it exists. If the new order for the + subset has lower cost, or if the subset did not exist, it stores the + new order and cost. - Description [Updates entry for a subset. Finds the subset, if it exists. - If the new order for the subset has lower cost, or if the subset did not - exist, it stores the new order and cost. Returns the number of subsets - currently in the table.] + @return the number of subsets currently in the table. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int updateEntry( DdManager * table, @@ -915,17 +842,12 @@ updateEntry( } /* end of updateEntry */ -/**Function******************************************************************** - - Synopsis [Pushes a variable in the order down to position "level."] +/** + @brief Pushes a variable in the order down to position "level." - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static void pushDown( DdHalfWord * order, @@ -945,11 +867,10 @@ pushDown( } /* end of pushDown */ -/**Function******************************************************************** +/** + @brief Gathers symmetry information. - Synopsis [Gathers symmetry information.] - - Description [Translates the symmetry information stored in the next + @details Translates the symmetry information stored in the next field of each subtable from level to indices. This procedure is called immediately after symmetric sifting, so that the next fields are correct. By translating this informaton in terms of indices, we make it independent @@ -957,13 +878,13 @@ pushDown( a circular list where each variable points to the next variable in the same symmetry group. Only the entries between lower and upper are considered. The procedure returns a pointer to an array - holding the symmetry information if successful; NULL otherwise.] + holding the symmetry information if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [checkSymmInfo] + @see checkSymmInfo -******************************************************************************/ +*/ static DdHalfWord * initSymmInfo( DdManager * table, @@ -978,28 +899,27 @@ initSymmInfo( for (level = lower; level <= upper; level++) { index = table->invperm[level]; - next = table->subtables[level].next; + next = (int) table->subtables[level].next; nextindex = table->invperm[next]; - symmInfo[index] = nextindex; + symmInfo[index] = (DdHalfWord) nextindex; } return(symmInfo); } /* end of initSymmInfo */ -/**Function******************************************************************** - - Synopsis [Check symmetry condition.] +/** + @brief Check symmetry condition. - Description [Returns 1 if a variable is the one with the highest index + @details Returns 1 if a variable is the one with the highest index among those belonging to a symmetry group that are in the top part of - the BDD. The top part is given by level.] + the %BDD. The top part is given by level. - SideEffects [None] + @sideeffect None - SeeAlso [initSymmInfo] + @see initSymmInfo -******************************************************************************/ +*/ static int checkSymmInfo( DdManager * table, @@ -1009,11 +929,11 @@ checkSymmInfo( { int i; - i = symmInfo[index]; + i = (int) symmInfo[index]; while (i != index) { if (index < i && table->perm[i] <= level) return(0); - i = symmInfo[i]; + i = (int) symmInfo[i]; } return(1); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddExport.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddExport.c similarity index 61% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddExport.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddExport.c index affbfd53b..4107b2d8b 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddExport.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddExport.c @@ -1,34 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddExport.c] - - PackageName [cudd] - - Synopsis [Export functions.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_DumpBlif() - <li> Cudd_DumpBlifBody() - <li> Cudd_DumpDot() - <li> Cudd_DumpDaVinci() - <li> Cudd_DumpDDcal() - <li> Cudd_DumpFactoredForm() - </ul> - Internal procedures included in this module: - <ul> - </ul> - Static procedures included in this module: - <ul> - <li> ddDoDumpBlif() - <li> ddDoDumpDaVinci() - <li> ddDoDumpDDcal() - <li> ddDoDumpFactoredForm() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Export functions. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -58,11 +38,13 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" +#include "cstringstream.h" #include "cuddInt.h" /*---------------------------------------------------------------------------*/ @@ -81,26 +63,23 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddExport.c,v 1.23 2012/02/05 01:07:18 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ -static int ddDoDumpBlif (DdManager *dd, DdNode *f, FILE *fp, st_table *visited, char **names, int mv); -static int ddDoDumpDaVinci (DdManager *dd, DdNode *f, FILE *fp, st_table *visited, char **names, ptruint mask); -static int ddDoDumpDDcal (DdManager *dd, DdNode *f, FILE *fp, st_table *visited, char **names, ptruint mask); -static int ddDoDumpFactoredForm (DdManager *dd, DdNode *f, FILE *fp, char **names); - -/**AutomaticEnd***************************************************************/ +static int ddDoDumpBlif (DdManager *dd, DdNode *f, FILE *fp, st_table *visited, char const * const *names, int mv); +static int ddDoDumpDaVinci (DdManager *dd, DdNode *f, FILE *fp, st_table *visited, char const * const *names, ptruint mask); +static int ddDoDumpDDcal (DdManager *dd, DdNode *f, FILE *fp, st_table *visited, char const * const *names, ptruint mask); +static int ddDoDumpFactoredForm (DdManager *dd, DdNode *f, FILE *fp, char const * const *names); +static int ddDoFactoredFormString(DdManager * dd, DdNode *f, cstringstream stream, char const * const * names); +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -108,36 +87,35 @@ static int ddDoDumpFactoredForm (DdManager *dd, DdNode *f, FILE *fp, char **name /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Writes a blif file representing the argument BDDs.] +/** + @brief Writes a blif file representing the argument BDDs. - Description [Writes a blif file representing the argument BDDs as a - network of multiplexers. One multiplexer is written for each BDD - node. It returns 1 in case of success; 0 otherwise (e.g., - out-of-memory, file system full, or an ADD with constants different - from 0 and 1). Cudd_DumpBlif does not close the file: This is the - caller responsibility. Cudd_DumpBlif uses a minimal unique subset of - the hexadecimal address of a node as name for it. If the argument + @details Each %BDD is written as a network of multiplexers. + Cudd_DumpBlif does not close the file: This is the caller + responsibility. Cudd_DumpBlif uses a minimal unique subset of the + hexadecimal address of a node as name for it. If the argument inames is non-null, it is assumed to hold the pointers to the names - of the inputs. Similarly for onames.] + of the inputs. Similarly for onames. - SideEffects [None] + @return 1 in case of success; 0 otherwise (e.g., out-of-memory, file + system full, or an %ADD with constants different from 0 and 1). - SeeAlso [Cudd_DumpBlifBody Cudd_DumpDot Cudd_PrintDebug Cudd_DumpDDcal - Cudd_DumpDaVinci Cudd_DumpFactoredForm] + @sideeffect None -******************************************************************************/ + @see Cudd_DumpBlifBody Cudd_DumpDot Cudd_PrintDebug Cudd_DumpDDcal + Cudd_DumpDaVinci Cudd_DumpFactoredForm + +*/ int Cudd_DumpBlif( - DdManager * dd /* manager */, - int n /* number of output nodes to be dumped */, - DdNode ** f /* array of output nodes to be dumped */, - char ** inames /* array of input names (or NULL) */, - char ** onames /* array of output names (or NULL) */, - char * mname /* model name (or NULL) */, - FILE * fp /* pointer to the dump file */, - int mv /* 0: blif, 1: blif-MV */) + DdManager * dd /**< manager */, + int n /**< number of output nodes to be dumped */, + DdNode ** f /**< array of output nodes to be dumped */, + char const * const * inames /**< array of input names (or NULL) */, + char const * const * onames /**< array of output names (or NULL) */, + char * mname /**< model name (or NULL) */, + FILE * fp /**< pointer to the dump file */, + int mv /**< 0: blif, 1: blif-MV */) { DdNode *support = NULL; DdNode *scan; @@ -214,7 +192,7 @@ Cudd_DumpBlif( return(1); -failure: + failure: if (sorted != NULL) FREE(sorted); if (support != NULL) Cudd_RecursiveDeref(dd,support); return(0); @@ -222,37 +200,37 @@ failure: } /* end of Cudd_DumpBlif */ -/**Function******************************************************************** +/** + @brief Writes a blif body representing the argument BDDs. - Synopsis [Writes a blif body representing the argument BDDs.] - - Description [Writes a blif body representing the argument BDDs as a - network of multiplexers. No header (.model, .inputs, and .outputs) and - footer (.end) are produced by this function. One multiplexer is written - for each BDD node. It returns 1 in case of success; 0 otherwise (e.g., - out-of-memory, file system full, or an ADD with constants different - from 0 and 1). Cudd_DumpBlifBody does not close the file: This is the - caller responsibility. Cudd_DumpBlifBody uses a minimal unique subset of + @details Each %BDD is written as a network of multiplexers. No + header (.model, .inputs, and .outputs) and footer (.end) are + produced by this function. One multiplexer is written for each %BDD + node. Cudd_DumpBlifBody does not close the file: This is the caller + responsibility. Cudd_DumpBlifBody uses a minimal unique subset of the hexadecimal address of a node as name for it. If the argument inames is non-null, it is assumed to hold the pointers to the names of the inputs. Similarly for onames. This function prints out only - .names part.] + .names part. + + @return 1 in case of success; 0 otherwise (e.g., out-of-memory, file + system full, or an %ADD with constants different from 0 and 1). - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_DumpBlif Cudd_DumpDot Cudd_PrintDebug Cudd_DumpDDcal - Cudd_DumpDaVinci Cudd_DumpFactoredForm] + @see Cudd_DumpBlif Cudd_DumpDot Cudd_PrintDebug Cudd_DumpDDcal + Cudd_DumpDaVinci Cudd_DumpFactoredForm -******************************************************************************/ +*/ int Cudd_DumpBlifBody( - DdManager * dd /* manager */, - int n /* number of output nodes to be dumped */, - DdNode ** f /* array of output nodes to be dumped */, - char ** inames /* array of input names (or NULL) */, - char ** onames /* array of output names (or NULL) */, - FILE * fp /* pointer to the dump file */, - int mv /* 0: blif, 1: blif-MV */) + DdManager * dd /**< manager */, + int n /**< number of output nodes to be dumped */, + DdNode ** f /**< array of output nodes to be dumped */, + char const * const * inames /**< array of input names (or NULL) */, + char const * const * onames /**< array of output names (or NULL) */, + FILE * fp /**< pointer to the dump file */, + int mv /**< 0: blif, 1: blif-MV */) { st_table *visited = NULL; int retval; @@ -274,19 +252,11 @@ Cudd_DumpBlifBody( */ for (i = 0; i < n; i++) { if (onames == NULL) { - retval = fprintf(fp, -#if SIZEOF_VOID_P == 8 - ".names %lx f%d\n", (ptruint) f[i] / (ptruint) sizeof(DdNode), i); -#else - ".names %x f%d\n", (ptruint) f[i] / (ptruint) sizeof(DdNode), i); -#endif + retval = fprintf(fp, ".names %" PRIxPTR " f%d\n", + (ptruint) f[i] / (ptruint) sizeof(DdNode), i); } else { - retval = fprintf(fp, -#if SIZEOF_VOID_P == 8 - ".names %lx %s\n", (ptruint) f[i] / (ptruint) sizeof(DdNode), onames[i]); -#else - ".names %x %s\n", (ptruint) f[i] / (ptruint) sizeof(DdNode), onames[i]); -#endif + retval = fprintf(fp, ".names %" PRIxPTR " %s\n", + (ptruint) f[i] / (ptruint) sizeof(DdNode), onames[i]); } if (retval == EOF) goto failure; if (Cudd_IsComplement(f[i])) { @@ -300,21 +270,18 @@ Cudd_DumpBlifBody( st_free_table(visited); return(1); -failure: + failure: if (visited != NULL) st_free_table(visited); return(0); } /* end of Cudd_DumpBlifBody */ -/**Function******************************************************************** - - Synopsis [Writes a dot file representing the argument DDs.] +/** + @brief Writes a dot file representing the argument DDs. - Description [Writes a file representing the argument DDs in a format + @details Writes a file representing the argument DDs in a format suitable for the graph drawing program dot. - It returns 1 in case of success; 0 otherwise (e.g., out-of-memory, - file system full). Cudd_DumpDot does not close the file: This is the caller responsibility. Cudd_DumpDot uses a minimal unique subset of the hexadecimal address of a node as name for it. @@ -328,22 +295,24 @@ failure: </ul> The dot options are chosen so that the drawing fits on a letter-size sheet. - ] - SideEffects [None] + @return 1 in case of success; 0 otherwise (e.g., out-of-memory, file + system full). - SeeAlso [Cudd_DumpBlif Cudd_PrintDebug Cudd_DumpDDcal - Cudd_DumpDaVinci Cudd_DumpFactoredForm] + @sideeffect None -******************************************************************************/ + @see Cudd_DumpBlif Cudd_PrintDebug Cudd_DumpDDcal + Cudd_DumpDaVinci Cudd_DumpFactoredForm + +*/ int Cudd_DumpDot( - DdManager * dd /* manager */, - int n /* number of output nodes to be dumped */, - DdNode ** f /* array of output nodes to be dumped */, - char ** inames /* array of input names (or NULL) */, - char ** onames /* array of output names (or NULL) */, - FILE * fp /* pointer to the dump file */) + DdManager * dd /**< manager */, + int n /**< number of output nodes to be dumped */, + DdNode ** f /**< array of output nodes to be dumped */, + char const * const * inames /**< array of input names (or NULL) */, + char const * const * onames /**< array of output names (or NULL) */, + FILE * fp /**< pointer to the dump file */) { DdNode *support = NULL; DdNode *scan; @@ -355,7 +324,7 @@ Cudd_DumpDot( int i, j; int slots; DdNodePtr *nodelist; - long refAddr, diff, mask; + ptruint refAddr, diff, mask = 0; /* Build a bit array with the support of f. */ sorted = ALLOC(int,nvars); @@ -399,18 +368,18 @@ Cudd_DumpDot( */ /* Find the bits that are different. */ - refAddr = (long) Cudd_Regular(f[0]); + refAddr = (ptruint) Cudd_Regular(f[0]); diff = 0; gen = st_init_gen(visited); if (gen == NULL) goto failure; - while (st_gen(gen, &scan, NULL)) { - diff |= refAddr ^ (long) scan; + while (st_gen(gen, (void **) &scan, NULL)) { + diff |= refAddr ^ (ptruint) scan; } st_free_gen(gen); gen = NULL; /* Choose the mask. */ - for (i = 0; (unsigned) i < 8 * sizeof(long); i += 4) { - mask = (1 << i) - 1; + for (i = 0; (unsigned) i < 8 * sizeof(ptruint); i += 4) { + mask = ((ptruint) 1 << i) - 1; if (diff <= mask) break; } @@ -478,10 +447,9 @@ Cudd_DumpDot( for (j = 0; j < slots; j++) { scan = nodelist[j]; while (scan != NULL) { - if (st_is_member(visited,(char *) scan)) { - retval = fprintf(fp,"\"%p\";\n", - (void *) ((mask & (ptrint) scan) / - sizeof(DdNode))); + if (st_is_member(visited,scan)) { + retval = fprintf(fp,"\"%#" PRIxPTR "\";\n", + ((mask & (ptruint) scan) / sizeof(DdNode))); if (retval == EOF) goto failure; } scan = scan->next; @@ -501,12 +469,10 @@ Cudd_DumpDot( for (j = 0; j < slots; j++) { scan = nodelist[j]; while (scan != NULL) { - if (st_is_member(visited,(char *) scan)) { - if (scan != Cudd_ReadZero(dd)) { - retval = fprintf(fp,"\"%p\";\n", - (void *) ((mask & (ptrint) scan) / sizeof(DdNode))); - if (retval == EOF) goto failure; - } + if (st_is_member(visited,scan)) { + retval = fprintf(fp,"\"%#" PRIxPTR "\";\n", + ((mask & (ptruint) scan) / sizeof(DdNode))); + if (retval == EOF) goto failure; } scan = scan->next; } @@ -525,11 +491,11 @@ Cudd_DumpDot( if (retval == EOF) goto failure; /* Account for the possible complement on the root. */ if (Cudd_IsComplement(f[i])) { - retval = fprintf(fp," -> \"%p\" [style = dotted];\n", - (void *) ((mask & (ptrint) f[i]) / sizeof(DdNode))); + retval = fprintf(fp," -> \"%#" PRIxPTR "\" [style = dotted];\n", + ((mask & (ptruint) f[i]) / sizeof(DdNode))); } else { - retval = fprintf(fp," -> \"%p\" [style = solid];\n", - (void *) ((mask & (ptrint) f[i]) / sizeof(DdNode))); + retval = fprintf(fp," -> \"%#" PRIxPTR "\" [style = solid];\n", + ((mask & (ptruint) f[i]) / sizeof(DdNode))); } if (retval == EOF) goto failure; } @@ -542,47 +508,29 @@ Cudd_DumpDot( for (j = 0; j < slots; j++) { scan = nodelist[j]; while (scan != NULL) { - if (st_is_member(visited,(char *) scan)) { - if (inames != NULL) { - retval = fprintf(fp, - "\"%p\" [label = \"%s\"];\n", - (void *) ((mask & (ptrint) scan) / - sizeof(DdNode)), inames[dd->invperm[i]]); - } else { - retval = fprintf(fp, - "\"%p\" [label = \"%i\"];\n", - (void *) ((mask & (ptrint) scan) / - sizeof(DdNode)), i); - } - if (retval == EOF) goto failure; - if (cuddT(scan) != Cudd_ReadZero(dd)) { + if (st_is_member(visited,scan)) { retval = fprintf(fp, - "\"%p\" -> \"%p\";\n", - (void *) ((mask & (ptrint) scan) / - sizeof(DdNode)), - (void *) ((mask & (ptrint) cuddT(scan)) / - sizeof(DdNode))); + "\"%#" PRIxPTR "\" -> \"%#" PRIxPTR "\";\n", + ((mask & (ptruint) scan) / sizeof(DdNode)), + ((mask & (ptruint) cuddT(scan)) / sizeof(DdNode))); if (retval == EOF) goto failure; - } - if (cuddE(scan) != Cudd_ReadZero(dd)) { if (Cudd_IsComplement(cuddE(scan))) { retval = fprintf(fp, - "\"%p\" -> \"%p\" [style = dotted];\n", - (void *) ((mask & (ptrint) scan) / - sizeof(DdNode)), - (void *) ((mask & (ptrint) cuddE(scan)) / + "\"%#" PRIxPTR "\" -> \"%#" PRIxPTR + "\" [style = dotted];\n", + ((mask & (ptruint) scan) / sizeof(DdNode)), + ((mask & (ptruint) cuddE(scan)) / sizeof(DdNode))); } else { retval = fprintf(fp, - "\"%p\" -> \"%p\" [style = dashed];\n", - (void *) ((mask & (ptrint) scan) / - sizeof(DdNode)), - (void *) ((mask & (ptrint) cuddE(scan)) / + "\"%#" PRIxPTR "\" -> \"%#" PRIxPTR + "\" [style = dashed];\n", + ((mask & (ptruint) scan) / sizeof(DdNode)), + ((mask & (ptruint) cuddE(scan)) / sizeof(DdNode))); } if (retval == EOF) goto failure; } - } scan = scan->next; } } @@ -595,14 +543,11 @@ Cudd_DumpDot( for (j = 0; j < slots; j++) { scan = nodelist[j]; while (scan != NULL) { - if (st_is_member(visited,(char *) scan)) { - if (scan != Cudd_ReadZero(dd)) { - retval = fprintf(fp,"\"%p\" [label = \"%g\"];\n", - (void *) ((mask & (ptrint) scan) / sizeof(DdNode)), - cuddV(scan)); + if (st_is_member(visited,scan)) { + retval = fprintf(fp,"\"%#" PRIxPTR "\" [label = \"%g\"];\n", + ((mask & (ptruint) scan) / sizeof(DdNode)), cuddV(scan)); if (retval == EOF) goto failure; } - } scan = scan->next; } } @@ -615,7 +560,7 @@ Cudd_DumpDot( FREE(sorted); return(1); -failure: + failure: if (sorted != NULL) FREE(sorted); if (support != NULL) Cudd_RecursiveDeref(dd,support); if (visited != NULL) st_free_table(visited); @@ -624,32 +569,33 @@ failure: } /* end of Cudd_DumpDot */ -/**Function******************************************************************** +/** + @brief Writes a daVinci file representing the argument BDDs. - Synopsis [Writes a daVinci file representing the argument BDDs.] + @details Writes a daVinci file representing the argument BDDs. + Cudd_DumpDaVinci does not close the file: This is the caller + responsibility. Cudd_DumpDaVinci uses a minimal unique subset of the + hexadecimal address of a node as name for it. If the argument + inames is non-null, it is assumed to hold the pointers to the names + of the inputs. Similarly for onames. - Description [Writes a daVinci file representing the argument BDDs. - It returns 1 in case of success; 0 otherwise (e.g., out-of-memory or - file system full). Cudd_DumpDaVinci does not close the file: This - is the caller responsibility. Cudd_DumpDaVinci uses a minimal unique - subset of the hexadecimal address of a node as name for it. If the - argument inames is non-null, it is assumed to hold the pointers to - the names of the inputs. Similarly for onames.] + @return 1 in case of success; 0 otherwise (e.g., out-of-memory or + file system full). - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_DumpDot Cudd_PrintDebug Cudd_DumpBlif Cudd_DumpDDcal - Cudd_DumpFactoredForm] + @see Cudd_DumpDot Cudd_PrintDebug Cudd_DumpBlif Cudd_DumpDDcal + Cudd_DumpFactoredForm -******************************************************************************/ +*/ int Cudd_DumpDaVinci( - DdManager * dd /* manager */, - int n /* number of output nodes to be dumped */, - DdNode ** f /* array of output nodes to be dumped */, - char ** inames /* array of input names (or NULL) */, - char ** onames /* array of output names (or NULL) */, - FILE * fp /* pointer to the dump file */) + DdManager * dd /**< manager */, + int n /**< number of output nodes to be dumped */, + DdNode ** f /**< array of output nodes to be dumped */, + char const * const * inames /**< array of input names (or NULL) */, + char const * const * onames /**< array of output names (or NULL) */, + FILE * fp /**< pointer to the dump file */) { DdNode *support = NULL; DdNode *scan; @@ -657,7 +603,7 @@ Cudd_DumpDaVinci( int retval; int i; st_generator *gen; - ptruint refAddr, diff, mask; + ptruint refAddr, diff, mask = 0; /* Initialize symbol table for visited nodes. */ visited = st_init_table(st_ptrcmp, st_ptrhash); @@ -684,14 +630,14 @@ Cudd_DumpDaVinci( refAddr = (ptruint) Cudd_Regular(f[0]); diff = 0; gen = st_init_gen(visited); - while (st_gen(gen, &scan, NULL)) { + while (st_gen(gen, (void **) &scan, NULL)) { diff |= refAddr ^ (ptruint) scan; } st_free_gen(gen); /* Choose the mask. */ for (i = 0; (unsigned) i < 8 * sizeof(ptruint); i += 4) { - mask = (1 << i) - 1; + mask = ((ptruint) 1 << i) - 1; if (diff <= mask) break; } st_free_table(visited); @@ -738,32 +684,33 @@ failure: } /* end of Cudd_DumpDaVinci */ -/**Function******************************************************************** +/** + @brief Writes a DDcal file representing the argument BDDs. - Synopsis [Writes a DDcal file representing the argument BDDs.] + @details Writes a DDcal file representing the argument BDDs. + Cudd_DumpDDcal does not close the file: This is the caller + responsibility. Cudd_DumpDDcal uses a minimal unique subset of the + hexadecimal address of a node as name for it. If the argument + inames is non-null, it is assumed to hold the pointers to the names + of the inputs. Similarly for onames. - Description [Writes a DDcal file representing the argument BDDs. - It returns 1 in case of success; 0 otherwise (e.g., out-of-memory or - file system full). Cudd_DumpDDcal does not close the file: This - is the caller responsibility. Cudd_DumpDDcal uses a minimal unique - subset of the hexadecimal address of a node as name for it. If the - argument inames is non-null, it is assumed to hold the pointers to - the names of the inputs. Similarly for onames.] + @return 1 in case of success; 0 otherwise (e.g., out-of-memory or + file system full). - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_DumpDot Cudd_PrintDebug Cudd_DumpBlif Cudd_DumpDaVinci - Cudd_DumpFactoredForm] + @see Cudd_DumpDot Cudd_PrintDebug Cudd_DumpBlif Cudd_DumpDaVinci + Cudd_DumpFactoredForm -******************************************************************************/ +*/ int Cudd_DumpDDcal( - DdManager * dd /* manager */, - int n /* number of output nodes to be dumped */, - DdNode ** f /* array of output nodes to be dumped */, - char ** inames /* array of input names (or NULL) */, - char ** onames /* array of output names (or NULL) */, - FILE * fp /* pointer to the dump file */) + DdManager * dd /**< manager */, + int n /**< number of output nodes to be dumped */, + DdNode ** f /**< array of output nodes to be dumped */, + char const * const * inames /**< array of input names (or NULL) */, + char const * const * onames /**< array of output names (or NULL) */, + FILE * fp /**< pointer to the dump file */) { DdNode *support = NULL; DdNode *scan; @@ -773,7 +720,7 @@ Cudd_DumpDDcal( int retval; int i; st_generator *gen; - ptruint refAddr, diff, mask; + ptruint refAddr, diff, mask = 0; /* Initialize symbol table for visited nodes. */ visited = st_init_table(st_ptrcmp, st_ptrhash); @@ -800,14 +747,14 @@ Cudd_DumpDDcal( refAddr = (ptruint) Cudd_Regular(f[0]); diff = 0; gen = st_init_gen(visited); - while (st_gen(gen, &scan, NULL)) { + while (st_gen(gen, (void **) &scan, NULL)) { diff |= refAddr ^ (ptruint) scan; } st_free_gen(gen); /* Choose the mask. */ for (i = 0; (unsigned) i < 8 * sizeof(ptruint); i += 4) { - mask = (1 << i) - 1; + mask = ((ptruint) 1 << i) - 1; if (diff <= mask) break; } st_free_table(visited); @@ -860,9 +807,8 @@ Cudd_DumpDDcal( retval = fprintf(fp, "%s = ", onames[i]); } if (retval == EOF) goto failure; - retval = fprintf(fp, "n%p%s\n", - (void *) (((ptruint) f[i] & mask) / - (ptruint) sizeof(DdNode)), + retval = fprintf(fp, "n%#" PRIxPTR "%s\n", + (((ptruint) f[i] & mask) / sizeof(DdNode)), Cudd_IsComplement(f[i]) ? "'" : ""); if (retval == EOF) goto failure; } @@ -876,6 +822,7 @@ Cudd_DumpDDcal( } else { retval = fprintf(fp, "%s", onames[i]); } + if (retval == EOF) goto failure; retval = fprintf(fp, "%s", i == n-1 ? "" : " "); if (retval == EOF) goto failure; } @@ -894,45 +841,52 @@ failure: } /* end of Cudd_DumpDDcal */ -/**Function******************************************************************** +/** + @brief Writes factored forms representing the argument BDDs. - Synopsis [Writes factored forms representing the argument BDDs.] + @details Writes factored forms representing the argument BDDs. The + format of the factored form is the one used in the genlib files for + technology mapping in sis. Cudd_DumpFactoredForm does not close the + file: This is the caller responsibility. Caution must be exercised + because a factored form may be exponentially larger than the + argument %BDD. If the argument inames is non-null, it is assumed to + hold the pointers to the names of the inputs. Similarly for onames. + If the number of output nodes is 0, it is interpreted as 1, but no + output name followed by equal sign is printed before the factored + form. - Description [Writes factored forms representing the argument BDDs. - The format of the factored form is the one used in the genlib files - for technology mapping in sis. It returns 1 in case of success; 0 - otherwise (e.g., file system full). Cudd_DumpFactoredForm does not - close the file: This is the caller responsibility. Caution must be - exercised because a factored form may be exponentially larger than - the argument BDD. If the argument inames is non-null, it is assumed - to hold the pointers to the names of the inputs. Similarly for - onames.] + @return 1 in case of success; 0 otherwise (e.g., file system full). - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_DumpDot Cudd_PrintDebug Cudd_DumpBlif Cudd_DumpDaVinci - Cudd_DumpDDcal] + @see Cudd_DumpDot Cudd_PrintDebug Cudd_DumpBlif Cudd_DumpDaVinci + Cudd_DumpDDcal -******************************************************************************/ +*/ int Cudd_DumpFactoredForm( - DdManager * dd /* manager */, - int n /* number of output nodes to be dumped */, - DdNode ** f /* array of output nodes to be dumped */, - char ** inames /* array of input names (or NULL) */, - char ** onames /* array of output names (or NULL) */, - FILE * fp /* pointer to the dump file */) + DdManager * dd /**< manager */, + int n /**< number of output nodes to be dumped */, + DdNode ** f /**< array of output nodes to be dumped */, + char const * const * inames /**< array of input names (or NULL) */, + char const * const * onames /**< array of output names (or NULL) */, + FILE * fp /**< pointer to the dump file */) { - int retval; + int retval = 0; int i; + int printName = n != 0; + + if (!printName) n = 1; /* Call the function that really gets the job done. */ for (i = 0; i < n; i++) { - if (onames == NULL) { - retval = fprintf(fp, "f%d = ", i); - } else { - retval = fprintf(fp, "%s = ", onames[i]); - } + if (printName) { + if (onames == NULL) { + retval = fprintf(fp, "f%d = ", i); + } else { + retval = fprintf(fp, "%s = ", onames[i]); + } + } if (retval == EOF) return(0); if (f[i] == DD_ONE(dd)) { retval = fprintf(fp, "CONST1"); @@ -941,11 +895,11 @@ Cudd_DumpFactoredForm( retval = fprintf(fp, "CONST0"); if (retval == EOF) return(0); } else { - retval = fprintf(fp, "%s", Cudd_IsComplement(f[i]) ? "!(" : ""); + retval = fprintf(fp, "%s", Cudd_IsComplement(f[i]) ? (Cudd_bddIsVar(dd, Cudd_Regular(f[i])) ? "!" : "!(") : ""); if (retval == EOF) return(0); retval = ddDoDumpFactoredForm(dd,Cudd_Regular(f[i]),fp,inames); if (retval == 0) return(0); - retval = fprintf(fp, "%s", Cudd_IsComplement(f[i]) ? ")" : ""); + retval = fprintf(fp, "%s", Cudd_IsComplement(f[i]) && !Cudd_bddIsVar(dd, Cudd_Regular(f[i])) ? ")" : ""); if (retval == EOF) return(0); } retval = fprintf(fp, "%s", i == n-1 ? "" : "\n"); @@ -957,6 +911,77 @@ Cudd_DumpFactoredForm( } /* end of Cudd_DumpFactoredForm */ +/** + @brief Returns a string with the factored form of the argument BDDs + + @details The factored form uses & for conjunction, | for disjunction + and ! for negation. Caution must be exercised because a factored + form may be exponentially larger than the argument %BDD. If the + argument inames is non-null, it is assumed to hold the pointers to + the names of the inputs. + + @return a string in case of success; NULL otherwise. + + @sideeffect None + + @see Cudd_DumpDot Cudd_PrintDebug Cudd_DumpBlif Cudd_DumpDaVinci + Cudd_DumpDDcal Cudd_DumpFactoredForm + +*/ +char * +Cudd_FactoredFormString( + DdManager *dd, + DdNode *f, + char const * const * inames) +{ + cstringstream stream = newStringStream(); + int err, retval; + char * str; + + if (!stream) { + return(0); + } + /* Call the function that really gets the job done. */ + if (f == DD_ONE(dd)) { + err = appendStringStringStream(stream, "true"); + if (err) { + deleteStringStream(stream); + return(0); + } + } else if (f == Cudd_Not(DD_ONE(dd)) || f == DD_ZERO(dd)) { + err = appendStringStringStream(stream, "false"); + if (err) { + deleteStringStream(stream); + return(0); + } + } else { + err = appendStringStringStream( + stream, Cudd_IsComplement(f) ? + (Cudd_bddIsVar(dd, Cudd_Regular(f)) ? "!" : "!(") : ""); + if (err) { + deleteStringStream(stream); + return(0); + } + retval = ddDoFactoredFormString(dd,Cudd_Regular(f),stream,inames); + if (retval == 0) { + deleteStringStream(stream); + return(0); + } + err = appendStringStringStream( + stream, Cudd_IsComplement(f) && + !Cudd_bddIsVar(dd, Cudd_Regular(f)) ? ")" : ""); + if (err) { + deleteStringStream(stream); + return(0); + } + } + str = stringFromStringStream(stream); + deleteStringStream(stream); + return(str); + +} /* end of Cudd_FactoredFormString */ + + /*---------------------------------------------------------------------------*/ /* Definition of internal functions */ /*---------------------------------------------------------------------------*/ @@ -967,27 +992,24 @@ Cudd_DumpFactoredForm( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_DumpBlif. - Synopsis [Performs the recursive step of Cudd_DumpBlif.] + @details Traverses the %BDD f and writes a multiplexer-network + description to the file pointed by fp in blif format. f is assumed + to be a regular pointer and ddDoDumpBlif guarantees this assumption + in the recursive calls. - Description [Performs the recursive step of Cudd_DumpBlif. Traverses - the BDD f and writes a multiplexer-network description to the file - pointed by fp in blif format. f is assumed to be a regular pointer - and ddDoDumpBlif guarantees this assumption in the recursive calls.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static int ddDoDumpBlif( DdManager * dd, DdNode * f, FILE * fp, st_table * visited, - char ** names, + char const * const * names, int mv) { DdNode *T, *E; @@ -998,7 +1020,7 @@ ddDoDumpBlif( #endif /* If already visited, nothing to do. */ - if (st_is_member(visited, (char *) f) == 1) + if (st_is_member(visited, f) == 1) return(1); /* Check for abnormal condition that should never happen. */ @@ -1006,16 +1028,12 @@ ddDoDumpBlif( return(0); /* Mark node as visited. */ - if (st_insert(visited, (char *) f, NULL) == ST_OUT_OF_MEM) + if (st_insert(visited, f, NULL) == ST_OUT_OF_MEM) return(0); /* Check for special case: If constant node, generate constant 1. */ if (f == DD_ONE(dd)) { -#if SIZEOF_VOID_P == 8 - retval = fprintf(fp, ".names %lx\n1\n",(ptruint) f / (ptruint) sizeof(DdNode)); -#else - retval = fprintf(fp, ".names %x\n1\n",(ptruint) f / (ptruint) sizeof(DdNode)); -#endif + retval = fprintf(fp, ".names %" PRIxPTR "\n1\n",(ptruint) f / (ptruint) sizeof(DdNode)); if (retval == EOF) { return(0); } else { @@ -1027,15 +1045,9 @@ ddDoDumpBlif( ** with the general case. */ if (f == DD_ZERO(dd)) { -#if SIZEOF_VOID_P == 8 - retval = fprintf(fp, ".names %lx\n%s", - (ptruint) f / (ptruint) sizeof(DdNode), - mv ? "0\n" : ""); -#else - retval = fprintf(fp, ".names %x\n%s", + retval = fprintf(fp, ".names %" PRIxPTR "\n%s", (ptruint) f / (ptruint) sizeof(DdNode), mv ? "0\n" : ""); -#endif if (retval == EOF) { return(0); } else { @@ -1066,59 +1078,31 @@ ddDoDumpBlif( if (retval == EOF) return(0); -#if SIZEOF_VOID_P == 8 if (mv) { if (Cudd_IsComplement(cuddE(f))) { - retval = fprintf(fp," %lx %lx %lx\n.def 0\n1 1 - 1\n0 - 0 1\n", + retval = fprintf(fp," %" PRIxPTR " %" PRIxPTR " %" PRIxPTR "\n.def 0\n1 1 - 1\n0 - 0 1\n", (ptruint) T / (ptruint) sizeof(DdNode), (ptruint) E / (ptruint) sizeof(DdNode), (ptruint) f / (ptruint) sizeof(DdNode)); } else { - retval = fprintf(fp," %lx %lx %lx\n.def 0\n1 1 - 1\n0 - 1 1\n", + retval = fprintf(fp," %" PRIxPTR " %" PRIxPTR " %" PRIxPTR "\n.def 0\n1 1 - 1\n0 - 1 1\n", (ptruint) T / (ptruint) sizeof(DdNode), (ptruint) E / (ptruint) sizeof(DdNode), (ptruint) f / (ptruint) sizeof(DdNode)); } } else { if (Cudd_IsComplement(cuddE(f))) { - retval = fprintf(fp," %lx %lx %lx\n11- 1\n0-0 1\n", + retval = fprintf(fp," %" PRIxPTR " %" PRIxPTR " %" PRIxPTR "\n11- 1\n0-0 1\n", (ptruint) T / (ptruint) sizeof(DdNode), (ptruint) E / (ptruint) sizeof(DdNode), (ptruint) f / (ptruint) sizeof(DdNode)); } else { - retval = fprintf(fp," %lx %lx %lx\n11- 1\n0-1 1\n", + retval = fprintf(fp," %" PRIxPTR " %" PRIxPTR " %" PRIxPTR "\n11- 1\n0-1 1\n", (ptruint) T / (ptruint) sizeof(DdNode), (ptruint) E / (ptruint) sizeof(DdNode), (ptruint) f / (ptruint) sizeof(DdNode)); } } -#else - if (mv) { - if (Cudd_IsComplement(cuddE(f))) { - retval = fprintf(fp," %x %x %x\n.def 0\n1 1 - 1\n0 - 0 1\n", - (ptruint) T / (ptruint) sizeof(DdNode), - (ptruint) E / (ptruint) sizeof(DdNode), - (ptruint) f / (ptruint) sizeof(DdNode)); - } else { - retval = fprintf(fp," %x %x %x\n.def 0\n1 1 - 1\n0 - 1 1\n", - (ptruint) T / (ptruint) sizeof(DdNode), - (ptruint) E / (ptruint) sizeof(DdNode), - (ptruint) f / (ptruint) sizeof(DdNode)); - } - } else { - if (Cudd_IsComplement(cuddE(f))) { - retval = fprintf(fp," %x %x %x\n11- 1\n0-0 1\n", - (ptruint) T / (ptruint) sizeof(DdNode), - (ptruint) E / (ptruint) sizeof(DdNode), - (ptruint) f / (ptruint) sizeof(DdNode)); - } else { - retval = fprintf(fp," %x %x %x\n11- 1\n0-1 1\n", - (ptruint) T / (ptruint) sizeof(DdNode), - (ptruint) E / (ptruint) sizeof(DdNode), - (ptruint) f / (ptruint) sizeof(DdNode)); - } - } -#endif if (retval == EOF) { return(0); } else { @@ -1128,27 +1112,24 @@ ddDoDumpBlif( } /* end of ddDoDumpBlif */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_DumpDaVinci. - Synopsis [Performs the recursive step of Cudd_DumpDaVinci.] + @details Traverses the %BDD f and writes a term expression to the + file pointed by fp in daVinci format. f is assumed to be a regular + pointer and ddDoDumpDaVinci guarantees this assumption in the + recursive calls. - Description [Performs the recursive step of Cudd_DumpDaVinci. Traverses - the BDD f and writes a term expression to the file - pointed by fp in daVinci format. f is assumed to be a regular pointer - and ddDoDumpDaVinci guarantees this assumption in the recursive calls.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static int ddDoDumpDaVinci( DdManager * dd, DdNode * f, FILE * fp, st_table * visited, - char ** names, + char const * const * names, ptruint mask) { DdNode *T, *E; @@ -1162,8 +1143,8 @@ ddDoDumpDaVinci( id = ((ptruint) f & mask) / sizeof(DdNode); /* If already visited, insert a reference. */ - if (st_is_member(visited, (char *) f) == 1) { - retval = fprintf(fp,"r(\"%p\")", (void *) id); + if (st_is_member(visited, f) == 1) { + retval = fprintf(fp,"r(\"%#" PRIxPTR "\")", id); if (retval == EOF) { return(0); } else { @@ -1176,14 +1157,15 @@ ddDoDumpDaVinci( return(0); /* Mark node as visited. */ - if (st_insert(visited, (char *) f, NULL) == ST_OUT_OF_MEM) + if (st_insert(visited, f, NULL) == ST_OUT_OF_MEM) return(0); /* Check for special case: If constant node, generate constant 1. */ - if (Cudd_IsConstant(f)) { + if (Cudd_IsConstantInt(f)) { retval = fprintf(fp, - "l(\"%p\",n(\"constant\",[a(\"OBJECT\",\"%g\")],[]))", - (void *) id, cuddV(f)); + "l(\"%#" PRIxPTR + "\",n(\"constant\",[a(\"OBJECT\",\"%g\")],[]))", + id, cuddV(f)); if (retval == EOF) { return(0); } else { @@ -1193,18 +1175,21 @@ ddDoDumpDaVinci( /* Recursive calls. */ if (names != NULL) { - retval = fprintf(fp, - "l(\"%p\",n(\"internal\",[a(\"OBJECT\",\"%s\"),", - (void *) id, names[f->index]); + retval = fprintf(fp, "l(\"%#" PRIxPTR + "\",n(\"internal\",[a(\"OBJECT\",\"%s\"),", + id, names[f->index]); } else { - retval = fprintf(fp, #if SIZEOF_VOID_P == 8 - "l(\"%p\",n(\"internal\",[a(\"OBJECT\",\"%u\"),", + retval = fprintf(fp, "l(\"%#" PRIxPTR + "\",n(\"internal\",[a(\"OBJECT\",\"%u\"),", + id, f->index); #else - "l(\"%p\",n(\"internal\",[a(\"OBJECT\",\"%hu\"),", + retval = fprintf(fp, "l(\"%#"PRIxPTR + "\",n(\"internal\",[a(\"OBJECT\",\"%hu\"),", + id, f->index); #endif - (void *) id, f->index); } + if (retval == EOF) return(0); retval = fprintf(fp, "a(\"_GO\",\"ellipse\")],[e(\"then\",[a(\"EDGECOLOR\",\"blue\"),a(\"_DIR\",\"none\")],"); if (retval == EOF) return(0); T = cuddT(f); @@ -1227,27 +1212,24 @@ ddDoDumpDaVinci( } /* end of ddDoDumpDaVinci */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_DumpDDcal. - Synopsis [Performs the recursive step of Cudd_DumpDDcal.] + @details Traverses the %BDD f and writes a line for each node to the + file pointed by fp in DDcal format. f is assumed to be a regular + pointer and ddDoDumpDDcal guarantees this assumption in the + recursive calls. - Description [Performs the recursive step of Cudd_DumpDDcal. Traverses - the BDD f and writes a line for each node to the file - pointed by fp in DDcal format. f is assumed to be a regular pointer - and ddDoDumpDDcal guarantees this assumption in the recursive calls.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static int ddDoDumpDDcal( DdManager * dd, DdNode * f, FILE * fp, st_table * visited, - char ** names, + char const * const * names, ptruint mask) { DdNode *T, *E; @@ -1261,7 +1243,7 @@ ddDoDumpDDcal( id = ((ptruint) f & mask) / sizeof(DdNode); /* If already visited, do nothing. */ - if (st_is_member(visited, (char *) f) == 1) { + if (st_is_member(visited, f) == 1) { return(1); } @@ -1270,14 +1252,14 @@ ddDoDumpDDcal( return(0); /* Mark node as visited. */ - if (st_insert(visited, (char *) f, NULL) == ST_OUT_OF_MEM) + if (st_insert(visited, f, NULL) == ST_OUT_OF_MEM) return(0); /* Check for special case: If constant node, assign constant. */ - if (Cudd_IsConstant(f)) { + if (Cudd_IsConstantInt(f)) { if (f != DD_ONE(dd) && f != DD_ZERO(dd)) return(0); - retval = fprintf(fp, "n%p = %g\n", (void *) id, cuddV(f)); + retval = fprintf(fp, "n%#" PRIxPTR" = %g\n", id, cuddV(f)); if (retval == EOF) { return(0); } else { @@ -1295,19 +1277,22 @@ ddDoDumpDDcal( idT = ((ptruint) T & mask) / sizeof(DdNode); idE = ((ptruint) E & mask) / sizeof(DdNode); if (names != NULL) { - retval = fprintf(fp, "n%p = %s * n%p + %s' * n%p%s\n", - (void *) id, names[f->index], - (void *) idT, names[f->index], - (void *) idE, Cudd_IsComplement(cuddE(f)) ? "'" : ""); + retval = fprintf(fp, "n%#" PRIxPTR " = %s * n%#" PRIxPTR + " + %s' * n%#" PRIxPTR "%s\n", + id, names[f->index], idT, names[f->index], + idE, Cudd_IsComplement(cuddE(f)) ? "'" : ""); } else { #if SIZEOF_VOID_P == 8 - retval = fprintf(fp, "n%p = v%u * n%p + v%u' * n%p%s\n", + retval = fprintf(fp, "n%#" PRIxPTR " = v%u * n%#" PRIxPTR + " + v%u' * n%#" PRIxPTR "%s\n", + id, f->index, idT, f->index, + idE, Cudd_IsComplement(cuddE(f)) ? "'" : ""); #else - retval = fprintf(fp, "n%p = v%hu * n%p + v%hu' * n%p%s\n", + retval = fprintf(fp, "n%#"PRIxPTR" = v%hu * n%#"PRIxPTR + " + v%hu' * n%#"PRIxPTR"%s\n", + id, f->index, idT, f->index, + idE, Cudd_IsComplement(cuddE(f)) ? "'" : ""); #endif - (void *) id, f->index, - (void *) idT, f->index, - (void *) idE, Cudd_IsComplement(cuddE(f)) ? "'" : ""); } if (retval == EOF) { return(0); @@ -1318,36 +1303,33 @@ ddDoDumpDDcal( } /* end of ddDoDumpDDcal */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_DumpFactoredForm.] +/** + @brief Performs the recursive step of Cudd_DumpFactoredForm. - Description [Performs the recursive step of - Cudd_DumpFactoredForm. Traverses the BDD f and writes a factored - form for each node to the file pointed by fp in terms of the - factored forms of the children. Constants are propagated, and - absorption is applied. f is assumed to be a regular pointer and - ddDoDumpFActoredForm guarantees this assumption in the recursive - calls.] + @details Traverses the %BDD f and writes a factored form for each + node to the file pointed by fp in terms of the factored forms of the + children. Constants are propagated, and absorption is applied. f is + assumed to be a regular pointer and ddDoDumpFActoredForm guarantees + this assumption in the recursive calls. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_DumpFactoredForm] + @see Cudd_DumpFactoredForm -******************************************************************************/ +*/ static int ddDoDumpFactoredForm( DdManager * dd, DdNode * f, FILE * fp, - char ** names) + char const * const * names) { DdNode *T, *E; int retval; #ifdef DD_DEBUG assert(!Cudd_IsComplement(f)); - assert(!Cudd_IsConstant(f)); + assert(!cuddIsConstant(f)); #endif /* Check for abnormal condition that should never happen. */ @@ -1371,11 +1353,12 @@ ddDoDumpFactoredForm( if (retval == EOF) return(0); } if (T != DD_ONE(dd)) { - retval = fprintf(fp, "%s(", E != DD_ONE(dd) ? " * " : ""); + // retval = fprintf(fp, "%s(", E != DD_ONE(dd) ? " * " : ""); + retval = fprintf(fp, "%s%s", E != DD_ONE(dd) ? " * " : "", Cudd_bddIsVar(dd, T) ? "" : "("); if (retval == EOF) return(0); retval = ddDoDumpFactoredForm(dd,T,fp,names); if (retval != 1) return(retval); - retval = fprintf(fp, ")"); + retval = fprintf(fp, "%s", Cudd_bddIsVar(dd, T) ? "" : ")"); if (retval == EOF) return(0); } if (E == Cudd_Not(DD_ONE(dd)) || E == DD_ZERO(dd)) return(1); @@ -1396,14 +1379,105 @@ ddDoDumpFactoredForm( if (retval == EOF) return(0); } if (E != DD_ONE(dd)) { - retval = fprintf(fp, "%s%s(", T != DD_ONE(dd) ? " * " : "", - E != cuddE(f) ? "!" : ""); + retval = fprintf(fp, "%s%s%s", T != DD_ONE(dd) ? " * " : "", + E != cuddE(f) ? "!" : "", Cudd_bddIsVar(dd, E) ? "" : "("); if (retval == EOF) return(0); retval = ddDoDumpFactoredForm(dd,E,fp,names); if (retval != 1) return(retval); - retval = fprintf(fp, ")"); + retval = fprintf(fp, "%s", Cudd_bddIsVar(dd, E) ? "" : "("); if (retval == EOF) return(0); } return(1); } /* end of ddDoDumpFactoredForm */ + + +/** + @brief Performs the recursive step of Cudd_DumpFactoredForm. + + @details Traverses the %BDD f and writes a factored form for each + node to the file pointed by fp in terms of the factored forms of the + children. Constants are propagated, and absorption is applied. f is + assumed to be a regular pointer and ddDoDumpFActoredForm guarantees + this assumption in the recursive calls. + + @sideeffect None + + @see Cudd_DumpFactoredForm + +*/ +static int +ddDoFactoredFormString( + DdManager * dd, + DdNode * f, + cstringstream stream, + char const * const * names) +{ + DdNode *T, *E; + int retval, err; + +#ifdef DD_DEBUG + assert(!Cudd_IsComplement(f)); + assert(!cuddIsConstant(f)); +#endif + + /* Check for abnormal condition that should never happen. */ + if (f == NULL) + return(0); + + /* Recursive calls. */ + T = cuddT(f); + E = cuddE(f); + if (T != DD_ZERO(dd)) { + if (E != DD_ONE(dd)) { + if (names != NULL) { + err = appendStringStringStream(stream, names[f->index]); + } else { + err = appendCharStringStream(stream, 'x'); + if (err) return(0); + err = appendUnsignedStringStream(stream, (unsigned) f->index); + } + if (err) return(0); + } + if (T != DD_ONE(dd)) { + err = appendStringStringStream(stream, E != DD_ONE(dd) ? " & " : ""); + if (err) return(0); + err = appendStringStringStream(stream, Cudd_bddIsVar(dd, T) ? "" : "("); + if (err) return(0); + retval = ddDoFactoredFormString(dd,T,stream,names); + if (retval != 1) return(retval); + err = appendStringStringStream(stream, Cudd_bddIsVar(dd, T) ? "" : ")"); + if (err) return(0); + } + if (E == Cudd_Not(DD_ONE(dd)) || E == DD_ZERO(dd)) return(1); + err = appendStringStringStream(stream, " | "); + if (err) return(0); + } + E = Cudd_Regular(E); + if (T != DD_ONE(dd)) { + err = appendCharStringStream(stream, '!'); + if (err) return(0); + if (names != NULL) { + err = appendStringStringStream(stream, names[f->index]); + } else { + err = appendCharStringStream(stream, 'x'); + if (err) return(0); + err = appendUnsignedStringStream(stream, (unsigned) f->index); + } + if (err) return(0); + } + if (E != DD_ONE(dd)) { + err = appendStringStringStream(stream, T != DD_ONE(dd) ? " & " : ""); + if (err) return(0); + err = appendStringStringStream(stream, E != cuddE(f) ? "!" : ""); + if (err) return(0); + err = appendStringStringStream(stream, Cudd_bddIsVar(dd, E) ? "" : "("); + if (err) return(0); + retval = ddDoFactoredFormString(dd,E,stream,names); + if (retval != 1) return(retval); + err = appendStringStringStream(stream, Cudd_bddIsVar(dd, E) ? "" : ")"); + if (err) return(0); + } + return(1); + +} /* end of ddDoFactoredFormString */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddGenCof.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddGenCof.c similarity index 67% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddGenCof.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddGenCof.c index e129aca44..f99906771 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddGenCof.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddGenCof.c @@ -1,51 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddGenCof.c] - - PackageName [cudd] - - Synopsis [Generalized cofactors for BDDs and ADDs.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_bddConstrain() - <li> Cudd_bddRestrict() - <li> Cudd_bddNPAnd() - <li> Cudd_addConstrain() - <li> Cudd_bddConstrainDecomp() - <li> Cudd_addRestrict() - <li> Cudd_bddCharToVect() - <li> Cudd_bddLICompaction() - <li> Cudd_bddSqueeze() - <li> Cudd_bddMinimize() - <li> Cudd_SubsetCompress() - <li> Cudd_SupersetCompress() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddConstrainRecur() - <li> cuddBddRestrictRecur() - <li> cuddBddNPAndRecur() - <li> cuddAddConstrainRecur() - <li> cuddAddRestrictRecur() - <li> cuddBddLICompaction() - </ul> - Static procedures included in this module: - <ul> - <li> cuddBddConstrainDecomp() - <li> cuddBddCharToVect() - <li> cuddBddLICMarkEdges() - <li> cuddBddLICBuildResult() - <li> MarkCacheHash() - <li> MarkCacheCompare() - <li> MarkCacheCleanUp() - <li> cuddBddSqueeze() - </ul> - ] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Generalized cofactors for BDDs and ADDs. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -75,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -104,7 +68,7 @@ /* Type declarations */ /*---------------------------------------------------------------------------*/ -/* Key for the cache used in the edge marking phase. */ +/** Key for the cache used in the edge marking phase. */ typedef struct MarkCacheKey { DdNode *f; DdNode *c; @@ -114,19 +78,12 @@ typedef struct MarkCacheKey { /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddGenCof.c,v 1.40 2012/02/05 01:07:18 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -#ifdef __cplusplus -extern "C" { -#endif - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -136,27 +93,23 @@ static int cuddBddConstrainDecomp (DdManager *dd, DdNode *f, DdNode **decomp); static DdNode * cuddBddCharToVect (DdManager *dd, DdNode *f, DdNode *x); static int cuddBddLICMarkEdges (DdManager *dd, DdNode *f, DdNode *c, st_table *table, st_table *cache); static DdNode * cuddBddLICBuildResult (DdManager *dd, DdNode *f, st_table *cache, st_table *table); -static int MarkCacheHash (char *ptr, int modulus); -static int MarkCacheCompare (const char *ptr1, const char *ptr2); -static enum st_retval MarkCacheCleanUp (char *key, char *value, char *arg); +static int MarkCacheHash (void const *ptr, int modulus); +static int MarkCacheCompare (const void *ptr1, const void *ptr2); +static enum st_retval MarkCacheCleanUp (void *key, void *value, void *arg); static DdNode * cuddBddSqueeze (DdManager *dd, DdNode *l, DdNode *u); +static DdNode * cuddBddInterpolate (DdManager * dd, DdNode * l, DdNode * u); -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} -#endif +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Computes f constrain c.] +/** + @brief Computes f constrain c. - Description [Computes f constrain c (f @ c). + @details Computes f constrain c (f @ c). Uses a canonical form: (f' @ c) = (f @ c)'. (Note: this is not true for c.) List of special cases: <ul> @@ -167,15 +120,16 @@ static DdNode * cuddBddSqueeze (DdManager *dd, DdNode *l, DdNode *u); <li> f @ f = 1 <li> f @ f'= 0 </ul> - Returns a pointer to the result if successful; NULL otherwise. Note that if - F=(f1,...,fn) and reordering takes place while computing F @ c, then the - image restriction property (Img(F,c) = Img(F @ c)) is lost.] + Note that if F=(f1,...,fn) and reordering takes place while computing F @ c, + then the image restriction property (Img(F,c) = Img(F @ c)) is lost. + + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddRestrict Cudd_addConstrain] + @see Cudd_bddRestrict Cudd_addConstrain -******************************************************************************/ +*/ DdNode * Cudd_bddConstrain( DdManager * dd, @@ -188,26 +142,28 @@ Cudd_bddConstrain( dd->reordered = 0; res = cuddBddConstrainRecur(dd,f,c); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddConstrain */ -/**Function******************************************************************** +/** + @brief %BDD restrict according to Coudert and Madre's algorithm + (ICCAD90). - Synopsis [BDD restrict according to Coudert and Madre's algorithm - (ICCAD90).] + @details If application of restrict results in a %BDD larger than the + input %BDD, the input %BDD is returned. - Description [BDD restrict according to Coudert and Madre's algorithm - (ICCAD90). Returns the restricted BDD if successful; otherwise NULL. - If application of restrict results in a BDD larger than the input - BDD, the input BDD is returned.] + @return the restricted %BDD if successful; otherwise NULL. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddConstrain Cudd_addRestrict] + @see Cudd_bddConstrain Cudd_addRestrict -******************************************************************************/ +*/ DdNode * Cudd_bddRestrict( DdManager * dd, @@ -223,7 +179,7 @@ Cudd_bddRestrict( ** This also allows us notto check later for the case c == 0, in which ** there is no common support. */ if (c == Cudd_Not(DD_ONE(dd))) return(Cudd_Not(DD_ONE(dd))); - if (Cudd_IsConstant(f)) return(f); + if (Cudd_IsConstantInt(f)) return(f); if (f == c) return(DD_ONE(dd)); if (f == Cudd_Not(c)) return(Cudd_Not(DD_ONE(dd))); @@ -257,6 +213,9 @@ Cudd_bddRestrict( } while (dd->reordered == 1); if (res == NULL) { Cudd_IterDerefBdd(dd,cplus); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(NULL); } cuddRef(res); @@ -276,25 +235,24 @@ Cudd_bddRestrict( } /* end of Cudd_bddRestrict */ -/**Function******************************************************************** +/** + @brief Computes f non-polluting-and g. - Synopsis [Computes f non-polluting-and g.] + @details The non-polluting AND of f and g is a hybrid of AND and + Restrict. From Restrict, this operation takes the idea of + existentially quantifying the top variable of the second operand if + it does not appear in the first. Therefore, the variables that + appear in the result also appear in f. For the rest, the function + behaves like AND. Since the two operands play different roles, + non-polluting AND is not commutative. - Description [Computes f non-polluting-and g. The non-polluting AND - of f and g is a hybrid of AND and Restrict. From Restrict, this - operation takes the idea of existentially quantifying the top - variable of the second operand if it does not appear in the first. - Therefore, the variables that appear in the result also appear in f. - For the rest, the function behaves like AND. Since the two operands - play different roles, non-polluting AND is not commutative. + @return a pointer to the result if successful; NULL otherwise. - Returns a pointer to the result if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_bddConstrain Cudd_bddRestrict - SeeAlso [Cudd_bddConstrain Cudd_bddRestrict] - -******************************************************************************/ +*/ DdNode * Cudd_bddNPAnd( DdManager * dd, @@ -307,31 +265,34 @@ Cudd_bddNPAnd( dd->reordered = 0; res = cuddBddNPAndRecur(dd,f,g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddNPAnd */ -/**Function******************************************************************** +/** + @brief Computes f constrain c for ADDs. - Synopsis [Computes f constrain c for ADDs.] + @details Computes f constrain c (f @ c), for f an %ADD and c a 0-1 + %ADD. List of special cases: + <ul> + <li> F @ 0 = 0 + <li> F @ 1 = F + <li> 0 @ c = 0 + <li> 1 @ c = 1 + <li> F @ F = 1 + </ul> - Description [Computes f constrain c (f @ c), for f an ADD and c a 0-1 - ADD. List of special cases: - <ul> - <li> F @ 0 = 0 - <li> F @ 1 = F - <li> 0 @ c = 0 - <li> 1 @ c = 1 - <li> F @ F = 1 - </ul> - Returns a pointer to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddConstrain] + @see Cudd_bddConstrain -******************************************************************************/ +*/ DdNode * Cudd_addConstrain( DdManager * dd, @@ -344,29 +305,31 @@ Cudd_addConstrain( dd->reordered = 0; res = cuddAddConstrainRecur(dd,f,c); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addConstrain */ -/**Function******************************************************************** - - Synopsis [BDD conjunctive decomposition as in McMillan's CAV96 paper.] +/** + @brief %BDD conjunctive decomposition as in McMillan's CAV96 paper. - Description [BDD conjunctive decomposition as in McMillan's CAV96 - paper. The decomposition is canonical only for a given variable + @details The decomposition is canonical only for a given variable order. If canonicity is required, variable ordering must be disabled - after the decomposition has been computed. Returns an array with one - entry for each BDD variable in the manager if successful; otherwise - NULL. The components of the solution have their reference counts - already incremented (unlike the results of most other functions in - the package).] + after the decomposition has been computed. The components of the + solution have their reference counts already incremented (unlike the + results of most other functions in the package). + + @return an array with one entry for each %BDD variable in the manager + if successful; otherwise NULL. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddConstrain Cudd_bddExistAbstract] + @see Cudd_bddConstrain Cudd_bddExistAbstract -******************************************************************************/ +*/ DdNode ** Cudd_bddConstrainDecomp( DdManager * dd, @@ -398,6 +361,9 @@ Cudd_bddConstrainDecomp( } while (dd->reordered == 1); if (res == 0) { FREE(decomp); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(NULL); } /* Missing components are constant ones. */ @@ -412,21 +378,20 @@ Cudd_bddConstrainDecomp( } /* end of Cudd_bddConstrainDecomp */ -/**Function******************************************************************** +/** + @brief %ADD restrict according to Coudert and Madre's algorithm + (ICCAD90). - Synopsis [ADD restrict according to Coudert and Madre's algorithm - (ICCAD90).] + @details If application of restrict results in an %ADD larger than + the input %ADD, the input %ADD is returned. - Description [ADD restrict according to Coudert and Madre's algorithm - (ICCAD90). Returns the restricted ADD if successful; otherwise NULL. - If application of restrict results in an ADD larger than the input - ADD, the input ADD is returned.] + @return the restricted %ADD if successful; otherwise NULL. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addConstrain Cudd_bddRestrict] + @see Cudd_addConstrain Cudd_bddRestrict -******************************************************************************/ +*/ DdNode * Cudd_addRestrict( DdManager * dd, @@ -467,6 +432,12 @@ Cudd_addRestrict( dd->reordered = 0; res = cuddAddRestrictRecur(dd, f, c); } while (dd->reordered == 1); + if (res == 0) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(f); + } sizeF = Cudd_DagSize(f); sizeRes = Cudd_DagSize(res); if (sizeF <= sizeRes) { @@ -483,29 +454,28 @@ Cudd_addRestrict( } /* end of Cudd_addRestrict */ -/**Function******************************************************************** - - Synopsis [Computes a vector whose image equals a non-zero function.] +/** + @brief Computes a vector of BDDs whose image equals a non-zero function. - Description [Computes a vector of BDDs whose image equals a non-zero - function. + @details The result depends on the variable order. The i-th component of the vector - depends only on the first i variables in the order. Each BDD in the vector - is not larger than the BDD of the given characteristic function. This + depends only on the first i variables in the order. Each %BDD in the vector + is not larger than the %BDD of the given characteristic function. This function is based on the description of char-to-vect in "Verification of Sequential Machines Using Boolean Functional Vectors" by O. Coudert, C. Berthet and J. C. Madre. - Returns a pointer to an array containing the result if successful; NULL - otherwise. The size of the array equals the number of variables in the - manager. The components of the solution have their reference counts - already incremented (unlike the results of most other functions in - the package).] - SideEffects [None] + @return a pointer to an array containing the result if successful; + NULL otherwise. The size of the array equals the number of + variables in the manager. The components of the solution have their + reference counts already incremented (unlike the results of most + other functions in the package). - SeeAlso [Cudd_bddConstrain] + @sideeffect None -******************************************************************************/ + @see Cudd_bddConstrain + +*/ DdNode ** Cudd_bddCharToVect( DdManager * dd, @@ -540,6 +510,9 @@ Cudd_bddCharToVect( } while (dd->reordered == 1); if (res == NULL) { FREE(vect); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(NULL); } return(vect); @@ -547,30 +520,28 @@ Cudd_bddCharToVect( } /* end of Cudd_bddCharToVect */ -/**Function******************************************************************** +/** + @brief Performs safe minimization of a %BDD. - Synopsis [Performs safe minimization of a BDD.] + @details Given the %BDD `f` of a function to be minimized and a %BDD + `c` representing the care set, Cudd_bddLICompaction produces the + %BDD of a function that agrees with `f` wherever `c` is 1. Safe + minimization means that the size of the result is guaranteed not to + exceed the size of `f`. This function is based on the DAC97 paper by + Hong et al.. - Description [Performs safe minimization of a BDD. Given the BDD - <code>f</code> of a function to be minimized and a BDD - <code>c</code> representing the care set, Cudd_bddLICompaction - produces the BDD of a function that agrees with <code>f</code> - wherever <code>c</code> is 1. Safe minimization means that the size - of the result is guaranteed not to exceed the size of - <code>f</code>. This function is based on the DAC97 paper by Hong et - al.. Returns a pointer to the result if successful; NULL - otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddRestrict] + @see Cudd_bddRestrict -******************************************************************************/ +*/ DdNode * Cudd_bddLICompaction( - DdManager * dd /* manager */, - DdNode * f /* function to be minimized */, - DdNode * c /* constraint (care set) */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be minimized */, + DdNode * c /**< constraint (care set) */) { DdNode *res; @@ -578,31 +549,33 @@ Cudd_bddLICompaction( dd->reordered = 0; res = cuddBddLICompaction(dd,f,c); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddLICompaction */ -/**Function******************************************************************** +/** + @brief Finds a small %BDD in a function interval. - Synopsis [Finds a small BDD in a function interval.] + @details Given BDDs `l` and `u`, representing the lower bound and + upper bound of a function interval, Cudd_bddSqueeze produces the + %BDD of a function within the interval with a small %BDD. - Description [Finds a small BDD in a function interval. Given BDDs - <code>l</code> and <code>u</code>, representing the lower bound and - upper bound of a function interval, Cudd_bddSqueeze produces the BDD - of a function within the interval with a small BDD. Returns a - pointer to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddRestrict Cudd_bddLICompaction] + @see Cudd_bddRestrict Cudd_bddLICompaction -******************************************************************************/ +*/ DdNode * Cudd_bddSqueeze( - DdManager * dd /* manager */, - DdNode * l /* lower bound */, - DdNode * u /* upper bound */) + DdManager * dd /**< manager */, + DdNode * l /**< lower bound */, + DdNode * u /**< upper bound */) { DdNode *res; int sizeRes, sizeL, sizeU; @@ -611,7 +584,12 @@ Cudd_bddSqueeze( dd->reordered = 0; res = cuddBddSqueeze(dd,l,u); } while (dd->reordered == 1); - if (res == NULL) return(NULL); + if (res == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(NULL); + } /* We now compare the result with the bounds and return the smallest. ** We first compare to u, so that in case l == 0 and u == 1, we return ** 0 as in other minimization algorithms. */ @@ -628,27 +606,61 @@ Cudd_bddSqueeze( cuddRef(res); Cudd_IterDerefBdd(dd,res); res = l; - sizeRes = sizeL; } return(res); } /* end of Cudd_bddSqueeze */ -/**Function******************************************************************** +/** + @brief Finds an interpolant of two functions. + + @details Given BDDs `l` and `u`, representing the lower bound and + upper bound of a function interval, Cudd_bddInterpolate produces the + %BDD of a function within the interval that only depends on the + variables common to `l` and `u`. - Synopsis [Finds a small BDD that agrees with <code>f</code> over - <code>c</code>.] + The approach is based on quantification as in Cudd_bddRestrict(). + The function assumes that `l` implies `u`, but does not check whether + that's true. - Description [Finds a small BDD that agrees with <code>f</code> over - <code>c</code>. Returns a pointer to the result if successful; NULL - otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddRestrict Cudd_bddLICompaction Cudd_bddSqueeze] + @see Cudd_bddRestrict Cudd_bddSqueeze -******************************************************************************/ +*/ +DdNode * +Cudd_bddInterpolate( + DdManager * dd /**< manager */, + DdNode * l /**< lower bound */, + DdNode * u /**< upper bound */) +{ + DdNode *res; + + do { + dd->reordered = 0; + res = cuddBddInterpolate(dd,l,u); + } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(res); + +} /* end of Cudd_bddInterpolate */ + + +/** + @brief Finds a small %BDD that agrees with `f` over `c`. + + @return a pointer to the result if successful; NULL otherwise. + + @sideeffect None + + @see Cudd_bddRestrict Cudd_bddLICompaction Cudd_bddSqueeze + +*/ DdNode * Cudd_bddMinimize( DdManager * dd, @@ -658,7 +670,7 @@ Cudd_bddMinimize( DdNode *cplus, *res; if (c == Cudd_Not(DD_ONE(dd))) return(c); - if (Cudd_IsConstant(f)) return(f); + if (Cudd_IsConstantInt(f)) return(f); if (f == c) return(DD_ONE(dd)); if (f == Cudd_Not(c)) return(Cudd_Not(DD_ONE(dd))); @@ -678,30 +690,29 @@ Cudd_bddMinimize( } /* end of Cudd_bddMinimize */ -/**Function******************************************************************** - - Synopsis [Find a dense subset of BDD <code>f</code>.] +/** + @brief Find a dense subset of %BDD `f`. - Description [Finds a dense subset of BDD <code>f</code>. Density is - the ratio of number of minterms to number of nodes. Uses several - techniques in series. It is more expensive than other subsetting - procedures, but often produces better results. See + @details Density is the ratio of number of minterms to number of + nodes. Uses several techniques in series. It is more expensive than + other subsetting procedures, but often produces better results. See Cudd_SubsetShortPaths for a description of the threshold and nvars - parameters. Returns a pointer to the result if successful; NULL - otherwise.] + parameters. - SideEffects [None] + @return a pointer to the result if successful; NULL otherwise. - SeeAlso [Cudd_RemapUnderApprox Cudd_SubsetShortPaths - Cudd_SubsetHeavyBranch Cudd_bddSqueeze] + @sideeffect None -******************************************************************************/ + @see Cudd_RemapUnderApprox Cudd_SubsetShortPaths + Cudd_SubsetHeavyBranch Cudd_bddSqueeze + +*/ DdNode * Cudd_SubsetCompress( - DdManager * dd /* manager */, - DdNode * f /* BDD whose subset is sought */, - int nvars /* number of variables in the support of f */, - int threshold /* maximum number of nodes in the subset */) + DdManager * dd /**< manager */, + DdNode * f /**< %BDD whose subset is sought */, + int nvars /**< number of variables in the support of f */, + int threshold /**< maximum number of nodes in the subset */) { DdNode *res, *tmp1, *tmp2; @@ -728,30 +739,29 @@ Cudd_SubsetCompress( } /* end of Cudd_SubsetCompress */ -/**Function******************************************************************** +/** + @brief Find a dense superset of %BDD `f`. - Synopsis [Find a dense superset of BDD <code>f</code>.] + @details Density is the ratio of number of minterms to number of + nodes. Uses several techniques in series. It is more expensive than + other supersetting procedures, but often produces better + results. See Cudd_SupersetShortPaths for a description of the + threshold and nvars parameters. - Description [Finds a dense superset of BDD <code>f</code>. Density is - the ratio of number of minterms to number of nodes. Uses several - techniques in series. It is more expensive than other supersetting - procedures, but often produces better results. See - Cudd_SupersetShortPaths for a description of the threshold and nvars - parameters. Returns a pointer to the result if successful; NULL - otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_SubsetCompress Cudd_SupersetRemap Cudd_SupersetShortPaths - Cudd_SupersetHeavyBranch Cudd_bddSqueeze] + @see Cudd_SubsetCompress Cudd_SupersetRemap Cudd_SupersetShortPaths + Cudd_SupersetHeavyBranch Cudd_bddSqueeze -******************************************************************************/ +*/ DdNode * Cudd_SupersetCompress( - DdManager * dd /* manager */, - DdNode * f /* BDD whose superset is sought */, - int nvars /* number of variables in the support of f */, - int threshold /* maximum number of nodes in the superset */) + DdManager * dd /**< manager */, + DdNode * f /**< %BDD whose superset is sought */, + int nvars /**< number of variables in the support of f */, + int threshold /**< maximum number of nodes in the superset */) { DdNode *subset; @@ -767,18 +777,16 @@ Cudd_SupersetCompress( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_bddConstrain. - Synopsis [Performs the recursive step of Cudd_bddConstrain.] + @return a pointer to the result if successful; NULL otherwise. - Description [Performs the recursive step of Cudd_bddConstrain. - Returns a pointer to the result if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_bddConstrain - SeeAlso [Cudd_bddConstrain] - -******************************************************************************/ +*/ DdNode * cuddBddConstrainRecur( DdManager * dd, @@ -787,8 +795,8 @@ cuddBddConstrainRecur( { DdNode *Fv, *Fnv, *Cv, *Cnv, *t, *e, *r; DdNode *one, *zero; - unsigned int topf, topc; - int index; + int topf, topc; + unsigned int index; int comple = 0; statLine(dd); @@ -798,7 +806,7 @@ cuddBddConstrainRecur( /* Trivial cases. */ if (c == one) return(f); if (c == zero) return(zero); - if (Cudd_IsConstant(f)) return(f); + if (Cudd_IsConstantInt(f)) return(f); if (f == c) return(one); if (f == Cudd_Not(c)) return(zero); @@ -816,6 +824,8 @@ cuddBddConstrainRecur( if (r != NULL) { return(Cudd_NotCond(r,comple)); } + + checkWhetherToGiveUp(dd); /* Recursive step. */ topf = dd->perm[f->index]; @@ -837,7 +847,7 @@ cuddBddConstrainRecur( Cv = Cnv = c; } - if (!Cudd_IsConstant(Cv)) { + if (!Cudd_IsConstantInt(Cv)) { t = cuddBddConstrainRecur(dd, Fv, Cv); if (t == NULL) return(NULL); @@ -855,7 +865,7 @@ cuddBddConstrainRecur( } cuddRef(t); - if (!Cudd_IsConstant(Cnv)) { + if (!Cudd_IsConstantInt(Cnv)) { e = cuddBddConstrainRecur(dd, Fnv, Cnv); if (e == NULL) { Cudd_IterDerefBdd(dd, t); @@ -896,18 +906,16 @@ cuddBddConstrainRecur( } /* end of cuddBddConstrainRecur */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_bddRestrict. - Synopsis [Performs the recursive step of Cudd_bddRestrict.] + @return the restricted %BDD if successful; otherwise NULL. - Description [Performs the recursive step of Cudd_bddRestrict. - Returns the restricted BDD if successful; otherwise NULL.] + @sideeffect None - SideEffects [None] + @see Cudd_bddRestrict - SeeAlso [Cudd_bddRestrict] - -******************************************************************************/ +*/ DdNode * cuddBddRestrictRecur( DdManager * dd, @@ -915,8 +923,8 @@ cuddBddRestrictRecur( DdNode * c) { DdNode *Fv, *Fnv, *Cv, *Cnv, *t, *e, *r, *one, *zero; - unsigned int topf, topc; - int index; + int topf, topc; + unsigned int index; int comple = 0; statLine(dd); @@ -926,7 +934,7 @@ cuddBddRestrictRecur( /* Trivial cases */ if (c == one) return(f); if (c == zero) return(zero); - if (Cudd_IsConstant(f)) return(f); + if (Cudd_IsConstantInt(f)) return(f); if (f == c) return(one); if (f == Cudd_Not(c)) return(zero); @@ -945,6 +953,8 @@ cuddBddRestrictRecur( return(Cudd_NotCond(r,comple)); } + checkWhetherToGiveUp(dd); + topf = dd->perm[f->index]; topc = dd->perm[Cudd_Regular(c)->index]; @@ -989,7 +999,7 @@ cuddBddRestrictRecur( Cv = Cnv = c; } - if (!Cudd_IsConstant(Cv)) { + if (!Cudd_IsConstantInt(Cv)) { t = cuddBddRestrictRecur(dd, Fv, Cv); if (t == NULL) return(NULL); } else if (Cv == one) { @@ -1005,7 +1015,7 @@ cuddBddRestrictRecur( } cuddRef(t); - if (!Cudd_IsConstant(Cnv)) { + if (!Cudd_IsConstantInt(Cnv)) { e = cuddBddRestrictRecur(dd, Fnv, Cnv); if (e == NULL) { Cudd_IterDerefBdd(dd, t); @@ -1046,18 +1056,16 @@ cuddBddRestrictRecur( } /* end of cuddBddRestrictRecur */ -/**Function******************************************************************** +/** + @brief Implements the recursive step of Cudd_bddAnd. - Synopsis [Implements the recursive step of Cudd_bddAnd.] + @return a pointer to the result is successful; NULL otherwise. - Description [Implements the recursive step of Cudd_bddNPAnd. - Returns a pointer to the result is successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_bddNPAnd - SeeAlso [Cudd_bddNPAnd] - -******************************************************************************/ +*/ DdNode * cuddBddNPAndRecur( DdManager * manager, @@ -1066,7 +1074,8 @@ cuddBddNPAndRecur( { DdNode *F, *ft, *fe, *G, *gt, *ge; DdNode *one, *r, *t, *e; - unsigned int topf, topg, index; + int topf, topg; + unsigned int index; statLine(manager); one = DD_ONE(manager); @@ -1093,6 +1102,8 @@ cuddBddNPAndRecur( if (r != NULL) return(r); } + checkWhetherToGiveUp(manager); + /* Here we can skip the use of cuddI, because the operands are known ** to be non-constant. */ @@ -1187,18 +1198,16 @@ cuddBddNPAndRecur( } /* end of cuddBddNPAndRecur */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_addConstrain.] +/** + @brief Performs the recursive step of Cudd_addConstrain. - Description [Performs the recursive step of Cudd_addConstrain. - Returns a pointer to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addConstrain] + @see Cudd_addConstrain -******************************************************************************/ +*/ DdNode * cuddAddConstrainRecur( DdManager * dd, @@ -1207,8 +1216,8 @@ cuddAddConstrainRecur( { DdNode *Fv, *Fnv, *Cv, *Cnv, *t, *e, *r; DdNode *one, *zero; - unsigned int topf, topc; - int index; + int topf, topc; + unsigned int index; statLine(dd); one = DD_ONE(dd); @@ -1217,7 +1226,7 @@ cuddAddConstrainRecur( /* Trivial cases. */ if (c == one) return(f); if (c == zero) return(zero); - if (Cudd_IsConstant(f)) return(f); + if (cuddIsConstant(f)) return(f); if (f == c) return(one); /* Now f and c are non-constant. */ @@ -1227,7 +1236,9 @@ cuddAddConstrainRecur( if (r != NULL) { return(r); } - + + checkWhetherToGiveUp(dd); + /* Recursive step. */ topf = dd->perm[f->index]; topc = dd->perm[c->index]; @@ -1244,7 +1255,7 @@ cuddAddConstrainRecur( Cv = Cnv = c; } - if (!Cudd_IsConstant(Cv)) { + if (!cuddIsConstant(Cv)) { t = cuddAddConstrainRecur(dd, Fv, Cv); if (t == NULL) return(NULL); @@ -1262,7 +1273,7 @@ cuddAddConstrainRecur( } cuddRef(t); - if (!Cudd_IsConstant(Cnv)) { + if (!cuddIsConstant(Cnv)) { e = cuddAddConstrainRecur(dd, Fnv, Cnv); if (e == NULL) { Cudd_RecursiveDeref(dd, t); @@ -1291,18 +1302,16 @@ cuddAddConstrainRecur( } /* end of cuddAddConstrainRecur */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_addRestrict. - Synopsis [Performs the recursive step of Cudd_addRestrict.] + @return the restricted %ADD if successful; otherwise NULL. - Description [Performs the recursive step of Cudd_addRestrict. - Returns the restricted ADD if successful; otherwise NULL.] + @sideeffect None - SideEffects [None] + @see Cudd_addRestrict - SeeAlso [Cudd_addRestrict] - -******************************************************************************/ +*/ DdNode * cuddAddRestrictRecur( DdManager * dd, @@ -1310,8 +1319,8 @@ cuddAddRestrictRecur( DdNode * c) { DdNode *Fv, *Fnv, *Cv, *Cnv, *t, *e, *r, *one, *zero; - unsigned int topf, topc; - int index; + int topf, topc; + unsigned int index; statLine(dd); one = DD_ONE(dd); @@ -1320,7 +1329,7 @@ cuddAddRestrictRecur( /* Trivial cases */ if (c == one) return(f); if (c == zero) return(zero); - if (Cudd_IsConstant(f)) return(f); + if (cuddIsConstant(f)) return(f); if (f == c) return(one); /* Now f and c are non-constant. */ @@ -1331,6 +1340,8 @@ cuddAddRestrictRecur( return(r); } + checkWhetherToGiveUp(dd); + topf = dd->perm[f->index]; topc = dd->perm[c->index]; @@ -1365,7 +1376,7 @@ cuddAddRestrictRecur( Cv = Cnv = c; } - if (!Cudd_IsConstant(Cv)) { + if (!Cudd_IsConstantInt(Cv)) { t = cuddAddRestrictRecur(dd, Fv, Cv); if (t == NULL) return(NULL); } else if (Cv == one) { @@ -1381,7 +1392,7 @@ cuddAddRestrictRecur( } cuddRef(t); - if (!Cudd_IsConstant(Cnv)) { + if (!cuddIsConstant(Cnv)) { e = cuddAddRestrictRecur(dd, Fnv, Cnv); if (e == NULL) { Cudd_RecursiveDeref(dd, t); @@ -1411,30 +1422,28 @@ cuddAddRestrictRecur( -/**Function******************************************************************** +/** + @brief Performs safe minimization of a %BDD. - Synopsis [Performs safe minimization of a BDD.] + @details Given the %BDD `f` of a function to be minimized and a %BDD + `c` representing the care set, Cudd_bddLICompaction produces the + %BDD of a function that agrees with `f` wherever `c` is 1. Safe + minimization means that the size of the result is guaranteed not to + exceed the size of `f`. This function is based on the DAC97 paper by + Hong et al.. - Description [Performs safe minimization of a BDD. Given the BDD - <code>f</code> of a function to be minimized and a BDD - <code>c</code> representing the care set, Cudd_bddLICompaction - produces the BDD of a function that agrees with <code>f</code> - wherever <code>c</code> is 1. Safe minimization means that the size - of the result is guaranteed not to exceed the size of - <code>f</code>. This function is based on the DAC97 paper by Hong et - al.. Returns a pointer to the result if successful; NULL - otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddLICompaction] + @see Cudd_bddLICompaction -******************************************************************************/ +*/ DdNode * cuddBddLICompaction( - DdManager * dd /* manager */, - DdNode * f /* function to be minimized */, - DdNode * c /* constraint (care set) */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be minimized */, + DdNode * c /**< constraint (care set) */) { st_table *marktable, *markcache, *buildcache; DdNode *res, *zero; @@ -1488,18 +1497,16 @@ cuddBddLICompaction( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_bddConstrainDecomp.] +/** + @brief Performs the recursive step of Cudd_bddConstrainDecomp. - Description [Performs the recursive step of Cudd_bddConstrainDecomp. - Returns f super (i) if successful; otherwise NULL.] + @return f super (i) if successful; otherwise NULL. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddConstrainDecomp] + @see Cudd_bddConstrainDecomp -******************************************************************************/ +*/ static int cuddBddConstrainDecomp( DdManager * dd, @@ -1511,7 +1518,7 @@ cuddBddConstrainDecomp( DdNode *result; int ok; - if (Cudd_IsConstant(f)) return(1); + if (Cudd_IsConstantInt(f)) return(1); /* Compute complements of cofactors. */ F = Cudd_Regular(f); fv = cuddT(F); @@ -1549,27 +1556,26 @@ cuddBddConstrainDecomp( } /* end of cuddBddConstrainDecomp */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_bddCharToVect. - Synopsis [Performs the recursive step of Cudd_bddCharToVect.] + @details This function maintains the invariant that f is non-zero. - Description [Performs the recursive step of Cudd_bddCharToVect. - This function maintains the invariant that f is non-zero. - Returns the i-th component of the vector if successful; otherwise NULL.] + @return the i-th component of the vector if successful; otherwise NULL. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddCharToVect] + @see Cudd_bddCharToVect -******************************************************************************/ +*/ static DdNode * cuddBddCharToVect( DdManager * dd, DdNode * f, DdNode * x) { - unsigned int topf; - unsigned int level; + int topf; + int level; int comple; DdNode *one, *zero, *res, *F, *fT, *fE, *T, *E; @@ -1581,6 +1587,8 @@ cuddBddCharToVect( return(res); } + checkWhetherToGiveUp(dd); + F = Cudd_Regular(f); topf = cuddI(dd,F->index); @@ -1630,19 +1638,17 @@ cuddBddCharToVect( } /* end of cuddBddCharToVect */ -/**Function******************************************************************** +/** + @brief Performs the edge marking step of Cudd_bddLICompaction. - Synopsis [Performs the edge marking step of Cudd_bddLICompaction.] + @return the LUB of the markings of the two outgoing edges of + <code>f</code> if successful; otherwise CUDD_OUT_OF_MEM. - Description [Performs the edge marking step of Cudd_bddLICompaction. - Returns the LUB of the markings of the two outgoing edges of <code>f</code> - if successful; otherwise CUDD_OUT_OF_MEM.] + @sideeffect None - SideEffects [None] + @see Cudd_bddLICompaction cuddBddLICBuildResult - SeeAlso [Cudd_bddLICompaction cuddBddLICBuildResult] - -******************************************************************************/ +*/ static int cuddBddLICMarkEdges( DdManager * dd, @@ -1653,10 +1659,10 @@ cuddBddLICMarkEdges( { DdNode *Fv, *Fnv, *Cv, *Cnv; DdNode *one, *zero; - unsigned int topf, topc; + int topf, topc; int comple; int resT, resE, res, retval; - char **slot; + void **slot; MarkCacheKey *key; one = DD_ONE(dd); @@ -1681,7 +1687,7 @@ cuddBddLICMarkEdges( return(CUDD_OUT_OF_MEM); } key->f = f; key->c = c; - if (st_lookup_int(cache, (char *)key, &res)) { + if (st_lookup_int(cache, key, &res)) { FREE(key); if (comple) { if (res == DD_LIC_0) res = DD_LIC_1; @@ -1722,11 +1728,11 @@ cuddBddLICMarkEdges( /* Update edge markings. */ if (topf <= topc) { - retval = st_find_or_add(table, (char *)f, (char ***)&slot); + retval = st_find_or_add(table, f, &slot); if (retval == 0) { - *slot = (char *) (ptrint)((resT << 2) | resE); + *slot = (void **) (ptrint)((resT << 2) | resE); } else if (retval == 1) { - *slot = (char *) (ptrint)((int)((ptrint) *slot) | (resT << 2) | resE); + *slot = (void **) (ptrint)((int)((ptrint) *slot) | (resT << 2) | resE); } else { FREE(key); return(CUDD_OUT_OF_MEM); @@ -1735,7 +1741,7 @@ cuddBddLICMarkEdges( /* Cache result. */ res = resT | resE; - if (st_insert(cache, (char *)key, (char *)(ptrint)res) == ST_OUT_OF_MEM) { + if (st_insert(cache, key, (void *)(ptrint)res) == ST_OUT_OF_MEM) { FREE(key); return(CUDD_OUT_OF_MEM); } @@ -1750,18 +1756,16 @@ cuddBddLICMarkEdges( } /* end of cuddBddLICMarkEdges */ -/**Function******************************************************************** - - Synopsis [Builds the result of Cudd_bddLICompaction.] +/** + @brief Builds the result of Cudd_bddLICompaction. - Description [Builds the results of Cudd_bddLICompaction. - Returns a pointer to the minimized BDD if successful; otherwise NULL.] + @return a pointer to the minimized %BDD if successful; otherwise NULL. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddLICompaction cuddBddLICMarkEdges] + @see Cudd_bddLICompaction cuddBddLICMarkEdges -******************************************************************************/ +*/ static DdNode * cuddBddLICBuildResult( DdManager * dd, @@ -1771,25 +1775,25 @@ cuddBddLICBuildResult( { DdNode *Fv, *Fnv, *r, *t, *e; DdNode *one, *zero; - int index; + unsigned int index; int comple; int markT, markE, markings; one = DD_ONE(dd); zero = Cudd_Not(one); - if (Cudd_IsConstant(f)) return(f); + if (Cudd_IsConstantInt(f)) return(f); /* Make canonical to increase the utilization of the cache. */ comple = Cudd_IsComplement(f); f = Cudd_Regular(f); /* Check the cache. */ - if (st_lookup(cache, f, &r)) { + if (st_lookup(cache, f, (void **) &r)) { return(Cudd_NotCond(r,comple)); } /* Retrieve the edge markings. */ - if (st_lookup_int(table, (char *)f, &markings) == 0) + if (st_lookup_int(table, f, &markings) == 0) return(NULL); markT = markings >> 2; markE = markings & 3; @@ -1848,7 +1852,7 @@ cuddBddLICBuildResult( cuddDeref(t); cuddDeref(e); - if (st_insert(cache, (char *)f, (char *)r) == ST_OUT_OF_MEM) { + if (st_insert(cache, f, r) == ST_OUT_OF_MEM) { cuddRef(r); Cudd_IterDerefBdd(dd,r); return(NULL); @@ -1859,27 +1863,23 @@ cuddBddLICBuildResult( } /* end of cuddBddLICBuildResult */ -/**Function******************************************************************** - - Synopsis [Hash function for the computed table of cuddBddLICMarkEdges.] +/** + @brief Hash function for the computed table of cuddBddLICMarkEdges. - Description [Hash function for the computed table of - cuddBddLICMarkEdges. Returns the bucket number.] + @return the bucket number. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddLICompaction] + @see Cudd_bddLICompaction -******************************************************************************/ +*/ static int MarkCacheHash( - char * ptr, + void const * ptr, int modulus) { int val = 0; - MarkCacheKey *entry; - - entry = (MarkCacheKey *) ptr; + MarkCacheKey const *entry = (MarkCacheKey const *) ptr; val = (int) (ptrint) entry->f; val = val * 997 + (int) (ptrint) entry->c; @@ -1889,79 +1889,72 @@ MarkCacheHash( } /* end of MarkCacheHash */ -/**Function******************************************************************** - - Synopsis [Comparison function for the computed table of - cuddBddLICMarkEdges.] +/** + @brief Comparison function for the computed table of + cuddBddLICMarkEdges. - Description [Comparison function for the computed table of - cuddBddLICMarkEdges. Returns 0 if the two nodes of the key are equal; 1 - otherwise.] + @return 0 if the two nodes of the key are equal; 1 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddLICompaction] + @see Cudd_bddLICompaction -******************************************************************************/ +*/ static int MarkCacheCompare( - const char * ptr1, - const char * ptr2) + const void * ptr1, + const void * ptr2) { - MarkCacheKey *entry1, *entry2; - - entry1 = (MarkCacheKey *) ptr1; - entry2 = (MarkCacheKey *) ptr2; + MarkCacheKey const *entry1 = (MarkCacheKey const *) ptr1; + MarkCacheKey const *entry2 = (MarkCacheKey const *) ptr2; return((entry1->f != entry2->f) || (entry1->c != entry2->c)); } /* end of MarkCacheCompare */ -/**Function******************************************************************** - - Synopsis [Frees memory associated with computed table of - cuddBddLICMarkEdges.] +/** + @brief Frees memory associated with computed table of + cuddBddLICMarkEdges. - Description [Frees memory associated with computed table of - cuddBddLICMarkEdges. Returns ST_CONTINUE.] + @return ST_CONTINUE. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddLICompaction] + @see Cudd_bddLICompaction -******************************************************************************/ +*/ static enum st_retval MarkCacheCleanUp( - char * key, - char * value, - char * arg) + void * key, + void * value, + void * arg) { - MarkCacheKey *entry; + MarkCacheKey *entry = (MarkCacheKey *) key; - entry = (MarkCacheKey *) key; + (void) value; /* avoid warning */ + (void) arg; /* avoid warning */ FREE(entry); return ST_CONTINUE; } /* end of MarkCacheCleanUp */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_bddSqueeze. - Synopsis [Performs the recursive step of Cudd_bddSqueeze.] + @details This procedure exploits the fact that if we complement and + swap the bounds of the interval we obtain a valid solution by taking + the complement of the solution to the original problem. Therefore, + we can enforce the condition that the upper bound is always regular. - Description [Performs the recursive step of Cudd_bddSqueeze. This - procedure exploits the fact that if we complement and swap the - bounds of the interval we obtain a valid solution by taking the - complement of the solution to the original problem. Therefore, we - can enforce the condition that the upper bound is always regular. - Returns a pointer to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddSqueeze] + @see Cudd_bddSqueeze -******************************************************************************/ +*/ static DdNode * cuddBddSqueeze( DdManager * dd, @@ -1973,8 +1966,8 @@ cuddBddSqueeze( DdNode *ar; #endif int comple = 0; - unsigned int topu, topl; - int index; + int topu, topl; + unsigned int index; statLine(dd); if (l == u) { @@ -2009,6 +2002,8 @@ cuddBddSqueeze( return(Cudd_NotCond(r,comple)); } + checkWhetherToGiveUp(dd); + /* Recursive step. */ topu = dd->perm[u->index]; topl = dd->perm[Cudd_Regular(l)->index]; @@ -2176,3 +2171,156 @@ cuddBddSqueeze( return(Cudd_NotCond(r,comple)); } /* end of cuddBddSqueeze */ + + +/** + @brief Performs the recursive step of Cudd_bddInterpolate. + + @details This procedure exploits the fact that if we complement and + swap the bounds of the interval we obtain a valid solution by taking + the complement of the solution to the original problem. Therefore, + we can enforce the condition that the upper bound is always regular. + + @return a pointer to the result if successful; NULL otherwise. + + @sideeffect None + + @see Cudd_bddInterpolate + +*/ +static DdNode * +cuddBddInterpolate( + DdManager * dd, + DdNode * l, + DdNode * u) +{ + DdNode *one, *zero, *r, *lt, *le, *ut, *ue, *t, *e; +#if 0 + DdNode *ar; +#endif + int comple = 0; + int topu, topl; + unsigned int index; + + statLine(dd); + if (l == u) { + return(l); + } + one = DD_ONE(dd); + zero = Cudd_Not(one); + if (l == zero) return(l); + if (u == one) return(u); + + /* Make canonical to increase the utilization of the cache. */ + if (Cudd_IsComplement(u)) { + DdNode *temp; + temp = Cudd_Not(l); + l = Cudd_Not(u); + u = temp; + comple = 1; + } + /* At this point u is regular and non-constant; l is non-constant, but + ** may be complemented. */ + + /* Check the cache. */ + r = cuddCacheLookup2(dd, Cudd_bddInterpolate, l, u); + if (r != NULL) { + return(Cudd_NotCond(r,comple)); + } + + checkWhetherToGiveUp(dd); + + /* Recursive step. */ + topu = dd->perm[u->index]; + topl = dd->perm[Cudd_Regular(l)->index]; + if (topu < topl) { + /* Universally quantify top variable from upper bound. */ + DdNode *qu; + ut = cuddT(u); ue = cuddE(u); + qu = cuddBddAndRecur(dd, ut, ue); + if (qu == NULL) return(NULL); + cuddRef(qu); + r = cuddBddInterpolate(dd, l, qu); + if (r == NULL) { + Cudd_IterDerefBdd(dd, qu); + return(NULL); + } + cuddRef(r); + Cudd_IterDerefBdd(dd, qu); + cuddCacheInsert2(dd, Cudd_bddInterpolate, l, u, r); + cuddDeref(r); + return(Cudd_NotCond(r, comple)); + } else if (topl < topu) { + /* Existentially quantify top variable from lower bound. */ + DdNode *ql; + /* Find complements of cofactors of c. */ + if (Cudd_IsComplement(l)) { + lt = cuddT(Cudd_Regular(l)); + le = cuddE(Cudd_Regular(l)); + } else { + lt = Cudd_Not(cuddT(l)); + le = Cudd_Not(cuddE(l)); + } + /* Disjoin cofactors by applying DeMorgan. */ + ql = cuddBddAndRecur(dd, lt, le); + if (ql == NULL) return (NULL); + cuddRef(ql); + ql = Cudd_Not(ql); + r = cuddBddInterpolate(dd, ql, u); + if (r == NULL) { + Cudd_IterDerefBdd(dd, ql); + return(NULL); + } + cuddRef(r); + Cudd_IterDerefBdd(dd, ql); + cuddCacheInsert2(dd, Cudd_bddInterpolate, l, u, r); + cuddDeref(r); + return(Cudd_NotCond(r, comple)); + } + + /* Both bounds depend on the top variable: split and recur. */ + index = u->index; + ut = cuddT(u); ue = cuddE(u); + lt = cuddT(Cudd_Regular(l)); le = cuddE(Cudd_Regular(l)); + if (Cudd_IsComplement(l)) { + lt = Cudd_Not(lt); + le = Cudd_Not(le); + } + + t = cuddBddInterpolate(dd, lt, ut); + if (t == NULL) { + return(NULL); + } + cuddRef(t); + e = cuddBddInterpolate(dd, le, ue); + if (e == NULL) { + Cudd_IterDerefBdd(dd,t); + return(NULL); + } + cuddRef(e); + + if (Cudd_IsComplement(t)) { + t = Cudd_Not(t); + e = Cudd_Not(e); + r = (t == e) ? t : cuddUniqueInter(dd, index, t, e); + if (r == NULL) { + Cudd_IterDerefBdd(dd, e); + Cudd_IterDerefBdd(dd, t); + return(NULL); + } + r = Cudd_Not(r); + } else { + r = (t == e) ? t : cuddUniqueInter(dd, index, t, e); + if (r == NULL) { + Cudd_IterDerefBdd(dd, e); + Cudd_IterDerefBdd(dd, t); + return(NULL); + } + } + cuddDeref(t); + cuddDeref(e); + + cuddCacheInsert2(dd, Cudd_bddInterpolate, l, u, r); + return(Cudd_NotCond(r,comple)); + +} /* end of cuddBddInterpolate */ diff --git a/resources/3rdparty/cudd-3.0.0/cudd/cuddGenetic.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddGenetic.c new file mode 100644 index 000000000..a8182256e --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddGenetic.c @@ -0,0 +1,904 @@ +/** + @file + + @ingroup cudd + + @brief Genetic algorithm for variable reordering. + + @details The genetic algorithm implemented here is as follows. We + start with the current %DD order. We sift this order and use this as + the reference %DD. We only keep 1 %DD around for the entire process + and simply rearrange the order of this %DD, storing the various + orders and their corresponding %DD sizes. We generate more random + orders to build an initial population. This initial population is 3 + times the number of variables, with a maximum of 120. Each random + order is built (from the reference %DD) and its size stored. Each + random order is also sifted to keep the %DD sizes fairly small. Then + a crossover is performed between two orders (picked randomly) and + the two resulting DDs are built and sifted. For each new order, if + its size is smaller than any %DD in the population, it is inserted + into the population and the %DD with the largest number of nodes is + thrown out. The crossover process happens up to 50 times, and at + this point the %DD in the population with the smallest size is chosen + as the result. This %DD must then be built from the reference %DD. + + @author Curt Musfeldt, Alan Shuler, Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" +#include "cuddInt.h" + +/*---------------------------------------------------------------------------*/ +/* Constant declarations */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Type declarations */ +/*---------------------------------------------------------------------------*/ + +typedef struct GeneticInfo GeneticInfo_t; + +/*---------------------------------------------------------------------------*/ +/* Stucture declarations */ +/*---------------------------------------------------------------------------*/ + +/** + * @brief Miscellaneous information. + */ +struct GeneticInfo { + int popsize; /**< the size of the population */ + int numvars; /**< the number of variables to be ordered. */ +/** + ** @brief storedd stores the population orders and sizes. + ** + ** @details This table has two extra rows and one extras column. The + ** two extra rows are used for the offspring produced by a + ** crossover. Each row stores one order and its size. The order is + ** stored by storing the indices of variables in the order in which + ** they appear in the order. The table is in reality a + ** one-dimensional array which is accessed via a macro to give the + ** illusion it is a two-dimensional structure. + */ + int *storedd; + st_table *computed; /**< hash table to identify existing orders */ + int *repeat; /**< how many times an order is present */ + int large; /**< stores the index of the population with + ** the largest number of nodes in the %DD */ + int result; /**< result */ + int cross; /**< the number of crossovers to perform */ +}; + +/*---------------------------------------------------------------------------*/ +/* Variable declarations */ +/*---------------------------------------------------------------------------*/ + + +/*---------------------------------------------------------------------------*/ +/* Macro declarations */ +/*---------------------------------------------------------------------------*/ + +/** + ** @brief Used to access the population table as if it were a + ** two-dimensional structure. + */ +#define STOREDD(info,i,j) (info)->storedd[(i)*((info)->numvars+1)+(j)] + +/** \cond */ + +/*---------------------------------------------------------------------------*/ +/* Static function prototypes */ +/*---------------------------------------------------------------------------*/ + +static int make_random (DdManager *table, int lower, GeneticInfo_t * info); +static int sift_up (DdManager *table, int x, int x_low); +static int build_dd (DdManager *table, int num, int lower, int upper, GeneticInfo_t * info); +static int largest (GeneticInfo_t * info); +static int rand_int (DdManager * dd, int a); +static int array_hash (void const *array, int modulus, void const * arg); +static int array_compare (const void *array1, const void *array2, void const * arg); +static int find_best (GeneticInfo_t * info); +#ifdef DD_STATS +static double find_average_fitness (GeneticInfo_t * info); +#endif +static int PMX (DdManager * dd, int maxvar, GeneticInfo_t * info); +static int roulette (DdManager *dd, int *p1, int *p2, GeneticInfo_t * info); + +/** \endcond */ + +/*---------------------------------------------------------------------------*/ +/* Definition of exported functions */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Definition of internal functions */ +/*---------------------------------------------------------------------------*/ + + +/** + @brief Genetic algorithm for %DD reordering. + + @details The two children of a crossover will be stored in + storedd[popsize] and storedd[popsize+1] --- the last two slots in the + storedd array. (This will make comparisons and replacement easy.) + + @return 1 in case of success; 0 otherwise. + + @sideeffect None + +*/ +int +cuddGa( + DdManager * table /**< manager */, + int lower /**< lowest level to be reordered */, + int upper /**< highest level to be reorderded */) +{ + int i,n,m; /* dummy/loop vars */ + int index; +#ifdef DD_STATS + double average_fitness; +#endif + int small; /* index of smallest DD in population */ + GeneticInfo_t info; + + /* Do an initial sifting to produce at least one reasonable individual. */ + if (!cuddSifting(table,lower,upper)) return(0); + + /* Get the initial values. */ + info.numvars = upper - lower + 1; /* number of variables to be reordered */ + if (table->populationSize == 0) { + info.popsize = 3 * info.numvars; /* population size is 3 times # of vars */ + if (info.popsize > 120) { + info.popsize = 120; /* Maximum population size is 120 */ + } + } else { + info.popsize = table->populationSize; /* user specified value */ + } + if (info.popsize < 4) info.popsize = 4; /* enforce minimum population size */ + + /* Allocate population table. */ + info.storedd = ALLOC(int,(info.popsize+2)*(info.numvars+1)); + if (info.storedd == NULL) { + table->errorCode = CUDD_MEMORY_OUT; + return(0); + } + + /* Initialize the computed table. This table is made up of two data + ** structures: A hash table with the key given by the order, which says + ** if a given order is present in the population; and the repeat + ** vector, which says how many copies of a given order are stored in + ** the population table. If there are multiple copies of an order, only + ** one has a repeat count greater than 1. This copy is the one pointed + ** by the computed table. + */ + info.repeat = ALLOC(int,info.popsize); + if (info.repeat == NULL) { + table->errorCode = CUDD_MEMORY_OUT; + FREE(info.storedd); + return(0); + } + for (i = 0; i < info.popsize; i++) { + info.repeat[i] = 0; + } + info.computed = st_init_table_with_arg(array_compare,array_hash, + (void *)(ptrint) info.numvars); + if (info.computed == NULL) { + table->errorCode = CUDD_MEMORY_OUT; + FREE(info.storedd); + FREE(info.repeat); + return(0); + } + + /* Copy the current DD and its size to the population table. */ + for (i = 0; i < info.numvars; i++) { + STOREDD(&info,0,i) = table->invperm[i+lower]; /* order of initial DD */ + } + STOREDD(&info,0,info.numvars) = + (int) (table->keys - table->isolated); /* size of initial DD */ + + /* Store the initial order in the computed table. */ + if (st_insert(info.computed,info.storedd,(void *) 0) == ST_OUT_OF_MEM) { + FREE(info.storedd); + FREE(info.repeat); + st_free_table(info.computed); + return(0); + } + info.repeat[0]++; + + /* Insert the reverse order as second element of the population. */ + for (i = 0; i < info.numvars; i++) { + STOREDD(&info,1,info.numvars-1-i) = table->invperm[i+lower]; /* reverse order */ + } + + /* Now create the random orders. make_random fills the population + ** table with random permutations. The successive loop builds and sifts + ** the DDs for the reverse order and each random permutation, and stores + ** the results in the computed table. + */ + if (!make_random(table,lower,&info)) { + table->errorCode = CUDD_MEMORY_OUT; + FREE(info.storedd); + FREE(info.repeat); + st_free_table(info.computed); + return(0); + } + for (i = 1; i < info.popsize; i++) { + info.result = build_dd(table,i,lower,upper,&info); /* build and sift order */ + if (!info.result) { + FREE(info.storedd); + FREE(info.repeat); + st_free_table(info.computed); + return(0); + } + if (st_lookup_int(info.computed,&STOREDD(&info,i,0),&index)) { + info.repeat[index]++; + } else { + if (st_insert(info.computed,&STOREDD(&info,i,0),(void *)(ptruint)i) == + ST_OUT_OF_MEM) { + FREE(info.storedd); + FREE(info.repeat); + st_free_table(info.computed); + return(0); + } + info.repeat[i]++; + } + } + +#if 0 +#ifdef DD_STATS + /* Print the initial population. */ + (void) fprintf(table->out,"Initial population after sifting\n"); + for (m = 0; m < info.popsize; m++) { + for (i = 0; i < info.numvars; i++) { + (void) fprintf(table->out," %2d",STOREDD(&info,m,i)); + } + (void) fprintf(table->out," : %3d (%d)\n", + STOREDD(&info,m,numvars),info.repeat[m]); + } +#endif +#endif + +#ifdef DD_STATS + small = find_best(&info); + average_fitness = find_average_fitness(&info); + (void) fprintf(table->out,"\nInitial population: best fitness = %d, average fitness %8.3f",STOREDD(&info,small,info.numvars),average_fitness); +#endif + + /* Decide how many crossovers should be tried. */ + if (table->numberXovers == 0) { + info.cross = 3*info.numvars; + if (info.cross > 60) { /* do a maximum of 50 crossovers */ + info.cross = 60; + } + } else { + info.cross = table->numberXovers; /* use user specified value */ + } + if (info.cross >= info.popsize) { + info.cross = info.popsize; + } + + /* Perform the crossovers to get the best order. */ + for (m = 0; m < info.cross; m++) { + if (!PMX(table, table->size, &info)) { /* perform one crossover */ + table->errorCode = CUDD_MEMORY_OUT; + FREE(info.storedd); + FREE(info.repeat); + st_free_table(info.computed); + return(0); + } + /* The offsprings are left in the last two entries of the + ** population table. These are now considered in turn. + */ + for (i = info.popsize; i <= info.popsize+1; i++) { + info.result = build_dd(table,i,lower,upper,&info); /* build and sift child */ + if (!info.result) { + FREE(info.storedd); + FREE(info.repeat); + st_free_table(info.computed); + return(0); + } + info.large = largest(&info); /* find the largest DD in population */ + + /* If the new child is smaller than the largest DD in the current + ** population, enter it into the population in place of the + ** largest DD. + */ + if (STOREDD(&info,i,info.numvars) < + STOREDD(&info,info.large,info.numvars)) { + /* Look up the largest DD in the computed table. + ** Decrease its repetition count. If the repetition count + ** goes to 0, remove the largest DD from the computed table. + */ + info.result = st_lookup_int(info.computed,&STOREDD(&info,info.large,0),&index); + if (!info.result) { + FREE(info.storedd); + FREE(info.repeat); + st_free_table(info.computed); + return(0); + } + info.repeat[index]--; + if (info.repeat[index] == 0) { + int *pointer = &STOREDD(&info,index,0); + info.result = st_delete(info.computed, (void **) &pointer, NULL); + if (!info.result) { + FREE(info.storedd); + FREE(info.repeat); + st_free_table(info.computed); + return(0); + } + } + /* Copy the new individual to the entry of the + ** population table just made available and update the + ** computed table. + */ + for (n = 0; n <= info.numvars; n++) { + STOREDD(&info,info.large,n) = STOREDD(&info,i,n); + } + if (st_lookup_int(info.computed,&STOREDD(&info,info.large,0),&index)) { + info.repeat[index]++; + } else { + if (st_insert(info.computed,&STOREDD(&info,info.large,0), + (void *)(ptruint)info.large) == ST_OUT_OF_MEM) { + FREE(info.storedd); + FREE(info.repeat); + st_free_table(info.computed); + return(0); + } + info.repeat[info.large]++; + } + } + } + } + + /* Find the smallest DD in the population and build it; + ** that will be the result. + */ + small = find_best(&info); + + /* Print stats on the final population. */ +#ifdef DD_STATS + average_fitness = find_average_fitness(&info); + (void) fprintf(table->out,"\nFinal population: best fitness = %d, average fitness %8.3f",STOREDD(&info,small,info.numvars),average_fitness); +#endif + + /* Clean up, build the result DD, and return. */ + st_free_table(info.computed); + info.computed = NULL; + info.result = build_dd(table,small,lower,upper,&info); + FREE(info.storedd); + FREE(info.repeat); + return(info.result); + +} /* end of cuddGa */ + + +/*---------------------------------------------------------------------------*/ +/* Definition of static functions */ +/*---------------------------------------------------------------------------*/ + +/** + @brief Generates the random sequences for the initial population. + + @details The sequences are permutations of the indices between lower + and upper in the current order. + + @sideeffect None + +*/ +static int +make_random( + DdManager * table, + int lower, + GeneticInfo_t * info) +{ + int i,j; /* loop variables */ + int *used; /* is a number already in a permutation */ + int next; /* next random number without repetitions */ + + used = ALLOC(int,info->numvars); + if (used == NULL) { + table->errorCode = CUDD_MEMORY_OUT; + return(0); + } +#if 0 +#ifdef DD_STATS + (void) fprintf(table->out,"Initial population before sifting\n"); + for (i = 0; i < 2; i++) { + for (j = 0; j < numvars; j++) { + (void) fprintf(table->out," %2d",STOREDD(i,j)); + } + (void) fprintf(table->out,"\n"); + } +#endif +#endif + for (i = 2; i < info->popsize; i++) { + for (j = 0; j < info->numvars; j++) { + used[j] = 0; + } + /* Generate a permutation of {0...numvars-1} and use it to + ** permute the variables in the layesr from lower to upper. + */ + for (j = 0; j < info->numvars; j++) { + do { + next = rand_int(table,info->numvars-1); + } while (used[next] != 0); + used[next] = 1; + STOREDD(info,i,j) = table->invperm[next+lower]; + } +#if 0 +#ifdef DD_STATS + /* Print the order just generated. */ + for (j = 0; j < numvars; j++) { + (void) fprintf(table->out," %2d",STOREDD(i,j)); + } + (void) fprintf(table->out,"\n"); +#endif +#endif + } + FREE(used); + return(1); + +} /* end of make_random */ + + +/** + @brief Moves one variable up. + + @details Takes a variable from position x and sifts it up to + position x_low; x_low should be less than x. + + @return 1 if successful; 0 otherwise + + @sideeffect None + +*/ +static int +sift_up( + DdManager * table, + int x, + int x_low) +{ + int y; + int size; + + y = cuddNextLow(table,x); + while (y >= x_low) { + size = cuddSwapInPlace(table,y,x); + if (size == 0) { + return(0); + } + x = y; + y = cuddNextLow(table,x); + } + return(1); + +} /* end of sift_up */ + + +/** + @brief Builds a %DD from a given order. + + @details This procedure also sifts the final order and inserts into + the array the size in nodes of the result. + + @return 1 if successful; 0 otherwise. + + @sideeffect None + +*/ +static int +build_dd( + DdManager * table, + int num /* the index of the individual to be built */, + int lower, + int upper, + GeneticInfo_t * info) +{ + int i,j; /* loop vars */ + int position; + int index; + int limit; /* how large the DD for this order can grow */ + int size; + + /* Check the computed table. If the order already exists, it + ** suffices to copy the size from the existing entry. + */ + if (info->computed && + st_lookup_int(info->computed,&STOREDD(info,num,0),&index)) { + STOREDD(info,num,info->numvars) = STOREDD(info,index,info->numvars); +#ifdef DD_STATS + (void) fprintf(table->out,"\nCache hit for index %d", index); +#endif + return(1); + } + + /* Stop if the DD grows 20 times larges than the reference size. */ + limit = 20 * STOREDD(info,0,info->numvars); + + /* Sift up the variables so as to build the desired permutation. + ** First the variable that has to be on top is sifted to the top. + ** Then the variable that has to occupy the secon position is sifted + ** up to the second position, and so on. + */ + for (j = 0; j < info->numvars; j++) { + i = STOREDD(info,num,j); + position = table->perm[i]; + info->result = sift_up(table,position,j+lower); + if (!info->result) return(0); + size = (int) (table->keys - table->isolated); + if (size > limit) break; + } + + /* Sift the DD just built. */ +#ifdef DD_STATS + (void) fprintf(table->out,"\n"); +#endif + info->result = cuddSifting(table,lower,upper); + if (!info->result) return(0); + + /* Copy order and size to table. */ + for (j = 0; j < info->numvars; j++) { + STOREDD(info,num,j) = table->invperm[lower+j]; + } + STOREDD(info,num,info->numvars) = (int) (table->keys - table->isolated); /* size of new DD */ + return(1); + +} /* end of build_dd */ + + +/** + @brief Finds the largest %DD in the population. + + @details If an order is repeated, it avoids choosing the copy that + is in the computed table (it has repeat[i > 1).] + + @sideeffect None + +*/ +static int +largest(GeneticInfo_t * info) +{ + int i; /* loop var */ + int big; /* temporary holder to return result */ + + big = 0; + while (info->repeat[big] > 1) big++; + for (i = big + 1; i < info->popsize; i++) { + if (STOREDD(info,i,info->numvars) >= + STOREDD(info,big,info->numvars) && info->repeat[i] <= 1) { + big = i; + } + } + return(big); + +} /* end of largest */ + + +/** + @brief Generates a random number between 0 and the integer a. + + @sideeffect None + +*/ +static int +rand_int( + DdManager *dd, + int a) +{ + return(Cudd_Random(dd) % (a+1)); + +} /* end of rand_int */ + + +/** + @brief Hash function for the computed table. + + @return the bucket number. + + @sideeffect None + +*/ +static int +array_hash( + void const * array, + int modulus, + void const * arg) +{ + int val = 0; + int i; + int const *intarray = (int const *) array; + int const numvars = (int const)(ptrint const) arg; + + for (i = 0; i < numvars; i++) { + val = val * 997 + intarray[i]; + } + + return(((val < 0) ? -val : val) % modulus); + +} /* end of array_hash */ + + +/** + @brief Comparison function for the computed table. + + @return 0 if the two arrays are equal; 1 otherwise. + + @sideeffect None + +*/ +static int +array_compare( + void const * array1, + void const * array2, + void const * arg) +{ + int i; + int const *intarray1 = (int const *) array1; + int const *intarray2 = (int const *) array2; + int const numvars = (int const)(ptrint const) arg; + + for (i = 0; i < numvars; i++) { + if (intarray1[i] != intarray2[i]) return(1); + } + return(0); + +} /* end of array_compare */ + + +/** + @brief Returns the index of the fittest individual. + + @sideeffect None + +*/ +static int +find_best(GeneticInfo_t * info) +{ + int i,small; + + small = 0; + for (i = 1; i < info->popsize; i++) { + if (STOREDD(info,i,info->numvars) < STOREDD(info,small,info->numvars)) { + small = i; + } + } + return(small); + +} /* end of find_best */ + + +/** + @brief Returns the average fitness of the population. + + @sideeffect None + +*/ +#ifdef DD_STATS +static double +find_average_fitness(GeneticInfo_t * info) +{ + int i; + int total_fitness = 0; + double average_fitness; + + for (i = 0; i < info->popsize; i++) { + total_fitness += STOREDD(info,i,info->numvars); + } + average_fitness = (double) total_fitness / (double) info->popsize; + return(average_fitness); + +} /* end of find_average_fitness */ +#endif + + +/** + @brief Performs the crossover between two parents. + + @details Performs the crossover between two randomly chosen + parents, and creates two children, x1 and x2. Uses the Partially + Matched Crossover operator. + + @sideeffect None + +*/ +static int +PMX( + DdManager * dd, + int maxvar, + GeneticInfo_t * info) +{ + int cut1,cut2; /* the two cut positions (random) */ + int mom,dad; /* the two randomly chosen parents */ + int *inv1; /* inverse permutations for repair algo */ + int *inv2; + int i; /* loop vars */ + int u,v; /* aux vars */ + + inv1 = ALLOC(int,maxvar); + if (inv1 == NULL) { + return(0); + } + inv2 = ALLOC(int,maxvar); + if (inv2 == NULL) { + FREE(inv1); + return(0); + } + + /* Choose two orders from the population using roulette wheel. */ + if (!roulette(dd,&mom,&dad,info)) { + FREE(inv1); + FREE(inv2); + return(0); + } + + /* Choose two random cut positions. A cut in position i means that + ** the cut immediately precedes position i. If cut1 < cut2, we + ** exchange the middle of the two orderings; otherwise, we + ** exchange the beginnings and the ends. + */ + cut1 = rand_int(dd,info->numvars-1); + do { + cut2 = rand_int(dd,info->numvars-1); + } while (cut1 == cut2); + +#if 0 + /* Print out the parents. */ + (void) fprintf(dd->out, + "Crossover of %d (mom) and %d (dad) between %d and %d\n", + mom,dad,cut1,cut2); + for (i = 0; i < info->numvars; i++) { + if (i == cut1 || i == cut2) (void) fprintf(dd->out,"|"); + (void) fprintf(dd->out,"%2d ",STOREDD(info,mom,i)); + } + (void) fprintf(dd->out,"\n"); + for (i = 0; i < info->numvars; i++) { + if (i == cut1 || i == cut2) (void) fprintf(dd->out,"|"); + (void) fprintf(dd->out,"%2d ",STOREDD(info,dad,i)); + } + (void) fprintf(dd->out,"\n"); +#endif + + /* Initialize the inverse permutations: -1 means yet undetermined. */ + for (i = 0; i < maxvar; i++) { + inv1[i] = -1; + inv2[i] = -1; + } + + /* Copy the portions whithin the cuts. */ + for (i = cut1; i != cut2; i = (i == info->numvars-1) ? 0 : i+1) { + STOREDD(info,info->popsize,i) = STOREDD(info,dad,i); + inv1[STOREDD(info,info->popsize,i)] = i; + STOREDD(info,info->popsize+1,i) = STOREDD(info,mom,i); + inv2[STOREDD(info,info->popsize+1,i)] = i; + } + + /* Now apply the repair algorithm outside the cuts. */ + for (i = cut2; i != cut1; i = (i == info->numvars-1 ) ? 0 : i+1) { + v = i; + do { + u = STOREDD(info,mom,v); + v = inv1[u]; + } while (v != -1); + STOREDD(info,info->popsize,i) = u; + inv1[u] = i; + v = i; + do { + u = STOREDD(info,dad,v); + v = inv2[u]; + } while (v != -1); + STOREDD(info,info->popsize+1,i) = u; + inv2[u] = i; + } + +#if 0 + /* Print the results of crossover. */ + for (i = 0; i < info->numvars; i++) { + if (i == cut1 || i == cut2) (void) fprintf(table->out,"|"); + (void) fprintf(table->out,"%2d ",STOREDD(info,info->popsize,i)); + } + (void) fprintf(table->out,"\n"); + for (i = 0; i < info->numvars; i++) { + if (i == cut1 || i == cut2) (void) fprintf(table->out,"|"); + (void) fprintf(table->out,"%2d ",STOREDD(info,info->popsize+1,i)); + } + (void) fprintf(table->out,"\n"); +#endif + + FREE(inv1); + FREE(inv2); + return(1); + +} /* end of PMX */ + + +/** + @brief Selects two distinct parents with the roulette wheel method. + + @sideeffect The indices of the selected parents are returned as side + effects. + +*/ +static int +roulette( + DdManager * dd, + int * p1, + int * p2, + GeneticInfo_t * info) +{ + double *wheel; + double spin; + int i; + + wheel = ALLOC(double,info->popsize); + if (wheel == NULL) { + return(0); + } + + /* The fitness of an individual is the reciprocal of its size. */ + wheel[0] = 1.0 / (double) STOREDD(info,0,info->numvars); + + for (i = 1; i < info->popsize; i++) { + wheel[i] = wheel[i-1] + 1.0 / (double) STOREDD(info,i,info->numvars); + } + + /* Get a random number between 0 and wheel[popsize-1] (that is, + ** the sum of all fitness values. 2147483561 is the largest number + ** returned by Cudd_Random. + */ + spin = wheel[info->numvars-1] * (double) Cudd_Random(dd) / 2147483561.0; + + /* Find the lucky element by scanning the wheel. */ + for (i = 0; i < info->popsize; i++) { + if (spin <= wheel[i]) break; + } + *p1 = i; + + /* Repeat the process for the second parent, making sure it is + ** distinct from the first. + */ + do { + spin = wheel[info->popsize-1] * (double) Cudd_Random(dd) / 2147483561.0; + for (i = 0; i < info->popsize; i++) { + if (spin <= wheel[i]) break; + } + } while (i == *p1); + *p2 = i; + + FREE(wheel); + return(1); + +} /* end of roulette */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddGroup.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddGroup.c similarity index 74% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddGroup.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddGroup.c index ce3e8b0f1..a0be0490f 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddGroup.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddGroup.c @@ -1,49 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddGroup.c] - - PackageName [cudd] - - Synopsis [Functions for group sifting.] - - Description [External procedures included in this file: - <ul> - <li> Cudd_MakeTreeNode() - </ul> - Internal procedures included in this file: - <ul> - <li> cuddTreeSifting() - </ul> - Static procedures included in this module: - <ul> - <li> ddTreeSiftingAux() - <li> ddCountInternalMtrNodes() - <li> ddReorderChildren() - <li> ddFindNodeHiLo() - <li> ddUniqueCompareGroup() - <li> ddGroupSifting() - <li> ddCreateGroup() - <li> ddGroupSiftingAux() - <li> ddGroupSiftingUp() - <li> ddGroupSiftingDown() - <li> ddGroupMove() - <li> ddGroupMoveBackward() - <li> ddGroupSiftingBackward() - <li> ddMergeGroups() - <li> ddDissolveGroup() - <li> ddNoCheck() - <li> ddSecDiffCheck() - <li> ddExtSymmCheck() - <li> ddVarGroupCheck() - <li> ddSetVarHandled() - <li> ddResetVarHandled() - <li> ddIsVarHandled() - <li> ddFixTree() - </ul>] - - Author [Shipra Panda, Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Functions for group sifting. + + @author Shipra Panda, Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -73,13 +38,14 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" +#include "mtrInt.h" #include "cuddInt.h" -#include "ucbqsort.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ @@ -101,47 +67,17 @@ /* Type declarations */ /*---------------------------------------------------------------------------*/ -#ifdef __cplusplus -extern "C" { -#endif - typedef int (*DD_CHKFP)(DdManager *, int, int); -#ifdef __cplusplus -} -#endif +typedef int (*DD_CHKFP)(DdManager *, int, int); /*---------------------------------------------------------------------------*/ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddGroup.c,v 1.49 2012/02/05 01:07:18 fabio Exp $"; -#endif - -static int *entry; -extern int ddTotalNumberSwapping; -#ifdef DD_STATS -extern int ddTotalNISwaps; -static int extsymmcalls; -static int extsymm; -static int secdiffcalls; -static int secdiff; -static int secdiffmisfire; -#endif -#ifdef DD_DEBUG -static int pr = 0; /* flag to enable printing while debugging */ - /* by depositing a 1 into it */ -#endif -static unsigned int originalSize; - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -#ifdef __cplusplus -extern "C" { -#endif - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -153,7 +89,7 @@ static int ddCountInternalMtrNodes (DdManager *table, MtrNode *treenode); #endif static int ddReorderChildren (DdManager *table, MtrNode *treenode, Cudd_ReorderingType method); static void ddFindNodeHiLo (DdManager *table, MtrNode *treenode, int *lower, int *upper); -static int ddUniqueCompareGroup (int *ptrX, int *ptrY); +static int ddUniqueCompareGroup (void const *ptrX, void const *ptrY); static int ddGroupSifting (DdManager *table, int lower, int upper, DD_CHKFP checkFunction, int lazyFlag); static void ddCreateGroup (DdManager *table, int x, int y); static int ddGroupSiftingAux (DdManager *table, int x, int xLow, int xHigh, DD_CHKFP checkFunction, int lazyFlag); @@ -172,40 +108,36 @@ static int ddSetVarHandled (DdManager *dd, int index); static int ddResetVarHandled (DdManager *dd, int index); static int ddIsVarHandled (DdManager *dd, int index); -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} -#endif +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Creates a new variable group. - Synopsis [Creates a new variable group.] + @details The group starts at variable low and contains size + variables. The parameter low is the index of the first variable. If + the variable already exists, its current position in the order is + known to the manager. If the variable does not exist yet, the + position is assumed to be the same as the index. The group tree is + created if it does not exist yet. - Description [Creates a new variable group. The group starts at - variable low and contains size variables. The parameter low is the index - of the first variable. If the variable already exists, its current - position in the order is known to the manager. If the variable does - not exist yet, the position is assumed to be the same as the index. - The group tree is created if it does not exist yet. - Returns a pointer to the group if successful; NULL otherwise.] + @return a pointer to the group if successful; NULL otherwise. - SideEffects [The variable tree is changed.] + @sideeffect The variable tree is changed. - SeeAlso [Cudd_MakeZddTreeNode] + @see Cudd_MakeZddTreeNode -******************************************************************************/ +*/ MtrNode * Cudd_MakeTreeNode( - DdManager * dd /* manager */, - unsigned int low /* index of the first group variable */, - unsigned int size /* number of variables in the group */, - unsigned int type /* MTR_DEFAULT or MTR_FIXED */) + DdManager * dd /**< manager */, + unsigned int low /**< index of the first group variable */, + unsigned int size /**< number of variables in the group */, + unsigned int type /**< MTR_DEFAULT or MTR_FIXED */) { MtrNode *group; MtrNode *tree; @@ -216,7 +148,7 @@ Cudd_MakeTreeNode( ** Cudd_bddNewVarAtLevel or Cudd_addNewVarAtLevel to create new ** variables have to create the variables before they group them. */ - level = (low < (unsigned int) dd->size) ? dd->perm[low] : low; + level = (low < (unsigned int) dd->size) ? (unsigned int) dd->perm[low] : low; if (level + size - 1> (int) MTR_MAXHIGH) return(NULL); @@ -256,22 +188,23 @@ Cudd_MakeTreeNode( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Tree sifting algorithm. - Synopsis [Tree sifting algorithm.] + @details Assumes that a tree representing a group hierarchy is + passed as a parameter. It then reorders each group in postorder + fashion by calling ddTreeSiftingAux. Assumes that no dead nodes are + present. - Description [Tree sifting algorithm. Assumes that a tree representing - a group hierarchy is passed as a parameter. It then reorders each - group in postorder fashion by calling ddTreeSiftingAux. Assumes that - no dead nodes are present. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ int cuddTreeSifting( - DdManager * table /* DD table */, - Cudd_ReorderingType method /* reordering method for the groups of leaves */) + DdManager * table /**< %DD table */, + Cudd_ReorderingType method /**< reordering method for the groups of leaves */) { int i; int nvars; @@ -290,16 +223,17 @@ cuddTreeSifting( nvars = table->size; #ifdef DD_DEBUG - if (pr > 0 && !tempTree) (void) fprintf(table->out,"cuddTreeSifting:"); - Mtr_PrintGroups(table->tree,pr <= 0); + if (table->enableExtraDebug > 0 && !tempTree) + (void) fprintf(table->out,"cuddTreeSifting:"); + Mtr_PrintGroups(table->tree,table->enableExtraDebug <= 0); #endif #ifdef DD_STATS - extsymmcalls = 0; - extsymm = 0; - secdiffcalls = 0; - secdiff = 0; - secdiffmisfire = 0; + table->extsymmcalls = 0; + table->extsymm = 0; + table->secdiffcalls = 0; + table->secdiff = 0; + table->secdiffmisfire = 0; (void) fprintf(table->out,"\n"); if (!tempTree) @@ -322,14 +256,14 @@ cuddTreeSifting( if (!tempTree && method == CUDD_REORDER_GROUP_SIFT && (table->groupcheck == CUDD_GROUP_CHECK7 || table->groupcheck == CUDD_GROUP_CHECK5)) { - (void) fprintf(table->out,"\nextsymmcalls = %d\n",extsymmcalls); - (void) fprintf(table->out,"extsymm = %d",extsymm); + (void) fprintf(table->out,"\nextsymmcalls = %d\n",table->extsymmcalls); + (void) fprintf(table->out,"extsymm = %d",table->extsymm); } if (!tempTree && method == CUDD_REORDER_GROUP_SIFT && table->groupcheck == CUDD_GROUP_CHECK7) { - (void) fprintf(table->out,"\nsecdiffcalls = %d\n",secdiffcalls); - (void) fprintf(table->out,"secdiff = %d\n",secdiff); - (void) fprintf(table->out,"secdiffmisfire = %d",secdiffmisfire); + (void) fprintf(table->out,"\nsecdiffcalls = %d\n",table->secdiffcalls); + (void) fprintf(table->out,"secdiff = %d\n",table->secdiff); + (void) fprintf(table->out,"secdiffmisfire = %d",table->secdiffmisfire); } #endif @@ -348,16 +282,17 @@ cuddTreeSifting( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Visits the group tree and reorders each group. - Synopsis [Visits the group tree and reorders each group.] + @details Recursively visits the group tree and reorders each + group in postorder fashion. - Description [Recursively visits the group tree and reorders each - group in postorder fashion. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddTreeSiftingAux( DdManager * table, @@ -400,16 +335,14 @@ ddTreeSiftingAux( #ifdef DD_STATS -/**Function******************************************************************** +/** + @brief Counts the number of internal nodes of the group tree. - Synopsis [Counts the number of internal nodes of the group tree.] + @return the count. - Description [Counts the number of internal nodes of the group tree. - Returns the count.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static int ddCountInternalMtrNodes( DdManager * table, @@ -436,20 +369,20 @@ ddCountInternalMtrNodes( #endif -/**Function******************************************************************** - - Synopsis [Reorders the children of a group tree node according to - the options.] +/** + @brief Reorders the children of a group tree node according to + the options. - Description [Reorders the children of a group tree node according to - the options. After reordering puts all the variables in the group - and/or its descendents in a single group. This allows hierarchical + @details After reordering puts all the variables in the group and/or + its descendents in a single group. This allows hierarchical reordering. If the variables in the group do not exist yet, simply - does nothing. Returns 1 if successful; 0 otherwise.] + does nothing. + + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddReorderChildren( DdManager * table, @@ -457,7 +390,7 @@ ddReorderChildren( Cudd_ReorderingType method) { int lower; - int upper; + int upper = 0; int result; unsigned int initialSize; @@ -518,18 +451,17 @@ ddReorderChildren( do { initialSize = table->keys - table->isolated; if (table->groupcheck == CUDD_NO_CHECK) { - result = ddGroupSifting(table,lower,upper,ddNoCheck, - DD_NORMAL_SIFT); + (void) ddGroupSifting(table,lower,upper,ddNoCheck, + DD_NORMAL_SIFT); } else if (table->groupcheck == CUDD_GROUP_CHECK5) { - result = ddGroupSifting(table,lower,upper,ddExtSymmCheck, - DD_NORMAL_SIFT); + (void) ddGroupSifting(table,lower,upper,ddExtSymmCheck, + DD_NORMAL_SIFT); } else if (table->groupcheck == CUDD_GROUP_CHECK7) { - result = ddGroupSifting(table,lower,upper,ddExtSymmCheck, - DD_NORMAL_SIFT); + (void) ddGroupSifting(table,lower,upper,ddExtSymmCheck, + DD_NORMAL_SIFT); } else { (void) fprintf(table->err, "Unknown group ckecking method\n"); - result = 0; } #ifdef DD_STATS (void) fprintf(table->out,"\n"); @@ -592,7 +524,8 @@ ddReorderChildren( ddMergeGroups(table,treenode,lower,upper); #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"ddReorderChildren:"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out,"ddReorderChildren:"); #endif return(result); @@ -600,20 +533,16 @@ ddReorderChildren( } /* end of ddReorderChildren */ -/**Function******************************************************************** - - Synopsis [Finds the lower and upper bounds of the group represented - by treenode.] - - Description [Finds the lower and upper bounds of the group - represented by treenode. From the index and size fields we need to - derive the current positions, and find maximum and minimum.] +/** + @brief Finds the lower and upper bounds of the group represented + by treenode. - SideEffects [The bounds are returned as side effects.] + @details From the index and size fields we need to derive the + current positions, and find maximum and minimum. - SeeAlso [] + @sideeffect The bounds are returned as side effects. -******************************************************************************/ +*/ static void ddFindNodeHiLo( DdManager * table, @@ -669,7 +598,7 @@ ddFindNodeHiLo( #ifdef DD_DEBUG /* Make sure that all variables in group are contiguous. */ - assert(treenode->size >= *upper - *lower + 1); + assert(treenode->size >= (MtrHalfWord) (*upper - *lower + 1)); #endif return; @@ -677,46 +606,48 @@ ddFindNodeHiLo( } /* end of ddFindNodeHiLo */ -/**Function******************************************************************** +/** + @brief Comparison function used by qsort. - Synopsis [Comparison function used by qsort.] + @details Comparison function used by qsort to order the variables + according to the number of keys in the subtables. - Description [Comparison function used by qsort to order the variables - according to the number of keys in the subtables. Returns the - difference in number of keys between the two variables being - compared.] + @return the difference in number of keys between the two variables + being compared. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddUniqueCompareGroup( - int * ptrX, - int * ptrY) + void const * ptrX, + void const * ptrY) { + IndexKey const * pX = (IndexKey const *) ptrX; + IndexKey const * pY = (IndexKey const *) ptrY; #if 0 - if (entry[*ptrY] == entry[*ptrX]) { - return((*ptrX) - (*ptrY)); + if (pY->keys == pX->keys) { + return(pX->index - pY->index); } #endif - return(entry[*ptrY] - entry[*ptrX]); + return(pY->keys - pX->keys); } /* end of ddUniqueCompareGroup */ -/**Function******************************************************************** +/** + @brief Sifts from treenode->low to treenode->high. - Synopsis [Sifts from treenode->low to treenode->high.] + @details If croupcheck == CUDD_GROUP_CHECK7, it checks for group + creation at the end of the initial sifting. If a group is created, + it is then sifted again. After sifting one variable, the group that + contains it is dissolved. - Description [Sifts from treenode->low to treenode->high. If - croupcheck == CUDD_GROUP_CHECK7, it checks for group creation at the - end of the initial sifting. If a group is created, it is then sifted - again. After sifting one variable, the group that contains it is - dissolved. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddGroupSifting( DdManager * table, @@ -725,7 +656,7 @@ ddGroupSifting( DD_CHKFP checkFunction, int lazyFlag) { - int *var; + IndexKey *var; int i,j,x,xInit; int nvars; int classes; @@ -741,18 +672,12 @@ ddGroupSifting( nvars = table->size; /* Order variables to sift. */ - entry = NULL; sifted = NULL; - var = ALLOC(int,nvars); + var = ALLOC(IndexKey,nvars); if (var == NULL) { table->errorCode = CUDD_MEMORY_OUT; goto ddGroupSiftingOutOfMem; } - entry = ALLOC(int,nvars); - if (entry == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - goto ddGroupSiftingOutOfMem; - } sifted = ALLOC(int,nvars); if (sifted == NULL) { table->errorCode = CUDD_MEMORY_OUT; @@ -764,14 +689,13 @@ ddGroupSifting( sifted[i] = 0; x = table->perm[i]; if ((unsigned) x >= table->subtables[x].next) { - entry[i] = table->subtables[x].keys; - var[classes] = i; + var[classes].index = i; + var[classes].keys = table->subtables[x].keys; classes++; } } - cudd__qsort((void *)var,classes,sizeof(int), - (DD_QSFP) ddUniqueCompareGroup); + util_qsort(var, classes, sizeof(IndexKey), ddUniqueCompareGroup); if (lazyFlag) { for (i = 0; i < nvars; i ++) { @@ -781,14 +705,19 @@ ddGroupSifting( /* Now sift. */ for (i = 0; i < ddMin(table->siftMaxVar,classes); i++) { - if (ddTotalNumberSwapping >= table->siftMaxSwap) + if (table->ddTotalNumberSwapping >= table->siftMaxSwap) break; if (util_cpu_time() - table->startTime + table->reordTime > table->timeLimit) { table->autoDyn = 0; /* prevent further reordering */ break; } - xindex = var[i]; + if (table->terminationCallback != NULL && + table->terminationCallback(table->tcbArg)) { + table->autoDyn = 0; /* prevent further reordering */ + break; + } + xindex = var[i].index; if (sifted[xindex] == 1) /* variable already sifted as part of group */ continue; x = table->perm[xindex]; /* find current level of this variable */ @@ -883,20 +812,19 @@ ddGroupSifting( } #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"ddGroupSifting:"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out,"ddGroupSifting:"); #endif - if (lazyFlag) ddSetVarHandled(table, xindex); + if (lazyFlag) ddSetVarHandled(table, xindex); } /* for */ FREE(sifted); FREE(var); - FREE(entry); return(1); ddGroupSiftingOutOfMem: - if (entry != NULL) FREE(entry); if (var != NULL) FREE(var); if (sifted != NULL) FREE(sifted); @@ -905,18 +833,15 @@ ddGroupSiftingOutOfMem: } /* end of ddGroupSifting */ -/**Function******************************************************************** +/** + @brief Creates a group encompassing variables from x to y in the + %DD table. - Synopsis [Creates a group encompassing variables from x to y in the - DD table.] + @details In the current implementation it must be y == x+1. - Description [Creates a group encompassing variables from x to y in the - DD table. In the current implementation it must be y == x+1. - Returns 1 in case of success; 0 otherwise.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static void ddCreateGroup( DdManager * table, @@ -943,21 +868,20 @@ ddCreateGroup( } /* ddCreateGroup */ -/**Function******************************************************************** +/** + @brief Sifts one variable up and down until it has taken all + positions. Checks for aggregation. - Synopsis [Sifts one variable up and down until it has taken all - positions. Checks for aggregation.] + @details There may be at most two sweeps, even if the group grows. + Assumes that x is either an isolated variable, or it is the bottom + of a group. All groups may not have been found. The variable being + moved is returned to the best position seen during sifting. - Description [Sifts one variable up and down until it has taken all - positions. Checks for aggregation. There may be at most two sweeps, - even if the group grows. Assumes that x is either an isolated - variable, or it is the bottom of a group. All groups may not have - been found. The variable being moved is returned to the best position - seen during sifting. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddGroupSiftingAux( DdManager * table, @@ -975,16 +899,16 @@ ddGroupSiftingAux( int topbot; #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out, - "ddGroupSiftingAux from %d to %d\n",xLow,xHigh); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out, + "ddGroupSiftingAux from %d to %d\n",xLow,xHigh); assert((unsigned) x >= table->subtables[x].next); /* x is bottom of group */ #endif - initialSize = table->keys - table->isolated; + table->originalSize = (table->keys - table->isolated); + initialSize = (int) table->originalSize; moves = NULL; - originalSize = initialSize; /* for lazy sifting */ - /* If we have a singleton, we check for aggregation in both ** directions before we sift. */ @@ -1141,21 +1065,20 @@ ddGroupSiftingAuxOutOfMem: } /* end of ddGroupSiftingAux */ -/**Function******************************************************************** +/** + @brief Sifts up a variable until either it reaches position xLow + or the size of the %DD heap increases too much. - Synopsis [Sifts up a variable until either it reaches position xLow - or the size of the DD heap increases too much.] + @details Assumes that y is the top of a group (or a singleton). + Checks y for aggregation to the adjacent variables. Records all the + moves that are appended to the list of moves received as input and + returned as a side effect. - Description [Sifts up a variable until either it reaches position - xLow or the size of the DD heap increases too much. Assumes that y is - the top of a group (or a singleton). Checks y for aggregation to the - adjacent variables. Records all the moves that are appended to the - list of moves received as input and returned as a side effect. - Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddGroupSiftingUp( DdManager * table, @@ -1173,7 +1096,7 @@ ddGroupSiftingUp( int xindex, yindex; int zindex; int z; - int isolated; + unsigned int isolated; int L; /* lower bound on DD size */ #ifdef DD_DEBUG int checkL; @@ -1190,7 +1113,7 @@ ddGroupSiftingUp( ** What we use here is not really a lower bound, because we ignore ** the interactions with all variables except y. */ - limitSize = L = table->keys - table->isolated; + limitSize = L = (int) (table->keys - table->isolated); gybot = y; while ((unsigned) gybot < table->subtables[gybot].next) gybot = table->subtables[gybot].next; @@ -1216,7 +1139,7 @@ ddGroupSiftingUp( checkL -= table->subtables[z].keys - isolated; } } - if (pr > 0 && L != checkL) { + if (table->enableExtraDebug > 0 && L != checkL) { (void) fprintf(table->out, "Inaccurate lower bound: L = %d checkL = %d\n", L, checkL); @@ -1235,7 +1158,7 @@ ddGroupSiftingUp( move->x = x; move->y = y; move->flags = MTR_NEWNODE; - move->size = table->keys - table->isolated; + move->size = (int) (table->keys - table->isolated); move->next = *moves; *moves = move; } else if (table->subtables[x].next == (unsigned) x && @@ -1263,8 +1186,9 @@ ddGroupSiftingUp( *moves = move; #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out, - "ddGroupSiftingUp (2 single groups):\n"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out, + "ddGroupSiftingUp (2 single groups):\n"); #endif if ((double) size > (double) limitSize * table->maxGrowth) return(1); @@ -1303,17 +1227,17 @@ ddGroupSiftingUpOutOfMem: } /* end of ddGroupSiftingUp */ -/**Function******************************************************************** +/** + @brief Sifts down a variable until it reaches position xHigh. - Synopsis [Sifts down a variable until it reaches position xHigh.] + @details Assumes that x is the bottom of a group (or a singleton). + Records all the moves. - Description [Sifts down a variable until it reaches position xHigh. - Assumes that x is the bottom of a group (or a singleton). Records - all the moves. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddGroupSiftingDown( DdManager * table, @@ -1329,7 +1253,8 @@ ddGroupSiftingDown( int gxtop,gybot; int R; /* upper bound on node decrease */ int xindex, yindex; - int isolated, allVars; + unsigned isolated; + int allVars; int z; int zindex; #ifdef DD_DEBUG @@ -1356,7 +1281,7 @@ ddGroupSiftingDown( /* Initialize R. */ xindex = table->invperm[x]; gxtop = table->subtables[x].next; - limitSize = size = table->keys - table->isolated; + limitSize = size = (int) (table->keys - table->isolated); R = 0; for (z = xHigh; z > gxtop; z--) { zindex = table->invperm[z]; @@ -1395,7 +1320,7 @@ ddGroupSiftingDown( move->x = x; move->y = y; move->flags = MTR_NEWNODE; - move->size = table->keys - table->isolated; + move->size = (int) (table->keys - table->isolated); move->next = *moves; *moves = move; } else if (table->subtables[x].next == (unsigned) x && @@ -1425,15 +1350,14 @@ ddGroupSiftingDown( *moves = move; #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out, - "ddGroupSiftingDown (2 single groups):\n"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out, + "ddGroupSiftingDown (2 single groups):\n"); #endif if ((double) size > (double) limitSize * table->maxGrowth) return(1); if (size < limitSize) limitSize = size; - x = y; - y = cuddNextHigh(table,x); } else { /* Group move */ /* Update upper bound on node decrease: first phase. */ gxtop = table->subtables[x].next; @@ -1480,16 +1404,15 @@ ddGroupSiftingDownOutOfMem: } /* end of ddGroupSiftingDown */ -/**Function******************************************************************** - - Synopsis [Swaps two groups and records the move.] +/** + @brief Swaps two groups and records the move. - Description [Swaps two groups and records the move. Returns the - number of keys in the DD table in case of success; 0 otherwise.] + @return the number of keys in the %DD table in case of success; 0 + otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddGroupMove( DdManager * table, @@ -1500,7 +1423,7 @@ ddGroupMove( Move *move; int size; int i,j,xtop,xbot,xsize,ytop,ybot,ysize,newxtop; - int swapx,swapy; + int swapx = 0, swapy = 0; #if defined(DD_DEBUG) && defined(DD_VERBOSE) int initialSize,bestSize; #endif @@ -1560,7 +1483,8 @@ ddGroupMove( table->subtables[x].next = newxtop; /* x is bottom of its group, join */ /* it to top of its group */ #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"ddGroupMove:\n"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out,"ddGroupMove:\n"); #endif /* Store group move */ @@ -1569,11 +1493,11 @@ ddGroupMove( move->x = swapx; move->y = swapy; move->flags = MTR_DEFAULT; - move->size = table->keys - table->isolated; + move->size = (int) (table->keys - table->isolated); move->next = *moves; *moves = move; - return(table->keys - table->isolated); + return((int)(table->keys - table->isolated)); ddGroupMoveOutOfMem: while (*moves != NULL) { @@ -1586,16 +1510,14 @@ ddGroupMoveOutOfMem: } /* end of ddGroupMove */ -/**Function******************************************************************** +/** + @brief Undoes the swap two groups. - Synopsis [Undoes the swap two groups.] + @return 1 in case of success; 0 otherwise. - Description [Undoes the swap two groups. Returns 1 in case of - success; 0 otherwise.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static int ddGroupMoveBackward( DdManager * table, @@ -1651,7 +1573,8 @@ ddGroupMoveBackward( table->subtables[x].next = newxtop; /* x is bottom of its group, join */ /* to its top */ #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"ddGroupMoveBackward:\n"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out,"ddGroupMoveBackward:\n"); #endif return(1); @@ -1659,17 +1582,15 @@ ddGroupMoveBackward( } /* end of ddGroupMoveBackward */ -/**Function******************************************************************** - - Synopsis [Determines the best position for a variables and returns - it there.] +/** + @brief Determines the best position for a variables and returns + it there. - Description [Determines the best position for a variables and returns - it there. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddGroupSiftingBackward( DdManager * table, @@ -1680,7 +1601,7 @@ ddGroupSiftingBackward( { Move *move; int res; - Move *end_move; + Move *end_move = NULL; int diff, tmp_diff; int index; unsigned int pairlev; @@ -1747,7 +1668,8 @@ ddGroupSiftingBackward( res = cuddSwapInPlace(table,(int)move->x,(int)move->y); if (!res) return(0); #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"ddGroupSiftingBackward:\n"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out,"ddGroupSiftingBackward:\n"); assert(table->subtables[move->x].next == move->x); assert(table->subtables[move->y].next == move->y); #endif @@ -1767,16 +1689,15 @@ ddGroupSiftingBackward( } /* end of ddGroupSiftingBackward */ -/**Function******************************************************************** +/** + @brief Merges groups in the %DD table. - Synopsis [Merges groups in the DD table.] + @details Creates a single group from low to high and adjusts the + index field of the tree node. - Description [Creates a single group from low to high and adjusts the - index field of the tree node.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static void ddMergeGroups( DdManager * table, @@ -1815,16 +1736,15 @@ ddMergeGroups( } /* end of ddMergeGroups */ -/**Function******************************************************************** - - Synopsis [Dissolves a group in the DD table.] +/** + @brief Dissolves a group in the %DD table. - Description [x and y are variables in a group to be cut in two. The cut - is to pass between x and y.] + @details x and y are variables in a group to be cut in two. The cut + is to pass between x and y. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static void ddDissolveGroup( DdManager * table, @@ -1849,40 +1769,41 @@ ddDissolveGroup( } /* end of ddDissolveGroup */ -/**Function******************************************************************** - - Synopsis [Pretends to check two variables for aggregation.] +/** + @brief Pretends to check two variables for aggregation. - Description [Pretends to check two variables for aggregation. Always - returns 0.] + @return always 0. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddNoCheck( DdManager * table, int x, int y) { + (void) table; /* avoid warning */ + (void) x; /* avoid warning */ + (void) y; /* avoid warning */ return(0); } /* end of ddNoCheck */ -/**Function******************************************************************** +/** + @brief Checks two variables for aggregation. - Synopsis [Checks two variables for aggregation.] + @details The check is based on the second difference of the number + of nodes as a function of the layer. If the second difference is + lower than a given threshold (typically negative) then the two + variables should be aggregated. - Description [Checks two variables for aggregation. The check is based - on the second difference of the number of nodes as a function of the - layer. If the second difference is lower than a given threshold - (typically negative) then the two variables should be aggregated. - Returns 1 if the two variables pass the test; 0 otherwise.] + @return 1 if the two variables pass the test; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddSecDiffCheck( DdManager * table, @@ -1897,7 +1818,7 @@ ddSecDiffCheck( if (x==0) return(0); #ifdef DD_STATS - secdiffcalls++; + table->secdiffcalls++; #endif Nx = (double) table->subtables[x].keys; Nx_1 = (double) table->subtables[x-1].keys; @@ -1914,12 +1835,12 @@ ddSecDiffCheck( table->invperm[x],Sx,x); #endif #ifdef DD_STATS - secdiff++; + table->secdiff++; #endif return(1); } else { #ifdef DD_STATS - secdiffmisfire++; + table->secdiffmisfire++; #endif return(0); } @@ -1930,16 +1851,14 @@ ddSecDiffCheck( } /* end of ddSecDiffCheck */ -/**Function******************************************************************** +/** + @brief Checks for extended symmetry of x and y. - Synopsis [Checks for extended symmetry of x and y.] + @return 1 in case of extended symmetry; 0 otherwise. - Description [Checks for extended symmetry of x and y. Returns 1 in - case of extended symmetry; 0 otherwise.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static int ddExtSymmCheck( DdManager * table, @@ -1948,7 +1867,7 @@ ddExtSymmCheck( { DdNode *f,*f0,*f1,*f01,*f00,*f11,*f10; DdNode *one; - unsigned comple; /* f0 is complemented */ + int comple; /* f0 is complemented */ int notproj; /* f is not a projection function */ int arccount; /* number of arcs from layer x to layer y */ int TotalRefCount; /* total reference count of layer y minus 1 */ @@ -1986,7 +1905,7 @@ ddExtSymmCheck( #endif #ifdef DD_STATS - extsymmcalls++; + table->extsymmcalls++; #endif arccount = 0; @@ -2073,23 +1992,23 @@ ddExtSymmCheck( #ifdef DD_STATS if (res) - extsymm++; + table->extsymm++; #endif return(res); } /* end ddExtSymmCheck */ -/**Function******************************************************************** +/** + @brief Checks for grouping of x and y. - Synopsis [Checks for grouping of x and y.] + @details This function is used for lazy sifting. - Description [Checks for grouping of x and y. Returns 1 in - case of grouping; 0 otherwise. This function is used for lazy sifting.] + @return 1 in case of grouping; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddVarGroupCheck( DdManager * table, @@ -2106,7 +2025,7 @@ ddVarGroupCheck( ddIsVarHandled(table, yindex)) { if (Cudd_bddIsVarToBeGrouped(table, xindex) || Cudd_bddIsVarToBeGrouped(table, yindex) ) { - if (table->keys - table->isolated <= originalSize) { + if (table->keys - table->isolated <= table->originalSize) { return(1); } } @@ -2118,18 +2037,14 @@ ddVarGroupCheck( } /* end of ddVarGroupCheck */ -/**Function******************************************************************** - - Synopsis [Sets a variable to already handled.] +/** + @brief Sets a variable to already handled. - Description [Sets a variable to already handled. This function is used - for lazy sifting.] + @details This function is used for lazy sifting. - SideEffects [none] + @sideeffect none - SeeAlso [] - -******************************************************************************/ +*/ static int ddSetVarHandled( DdManager *dd, @@ -2142,18 +2057,14 @@ ddSetVarHandled( } /* end of ddSetVarHandled */ -/**Function******************************************************************** - - Synopsis [Resets a variable to be processed.] - - Description [Resets a variable to be processed. This function is used - for lazy sifting.] +/** + @brief Resets a variable to be processed. - SideEffects [none] + @details This function is used for lazy sifting. - SeeAlso [] + @sideeffect none -******************************************************************************/ +*/ static int ddResetVarHandled( DdManager *dd, @@ -2166,18 +2077,14 @@ ddResetVarHandled( } /* end of ddResetVarHandled */ -/**Function******************************************************************** - - Synopsis [Checks whether a variables is already handled.] - - Description [Checks whether a variables is already handled. This - function is used for lazy sifting.] +/** + @brief Checks whether a variables is already handled. - SideEffects [none] + @details This function is used for lazy sifting. - SeeAlso [] + @sideeffect none -******************************************************************************/ +*/ static int ddIsVarHandled( DdManager *dd, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddHarwell.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddHarwell.c similarity index 84% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddHarwell.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddHarwell.c index 323db91d3..e44a1db2e 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddHarwell.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddHarwell.c @@ -1,20 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddHarwell.c] + @ingroup cudd - PackageName [cudd] + @brief Function to read a matrix in Harwell format. - Synopsis [Function to read a matrix in Harwell format.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_addHarwell() - </ul> - ] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -44,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -70,77 +65,72 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddHarwell.c,v 1.10 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Reads in a matrix in the format of the Harwell-Boeing - benchmark suite.] +/** + @brief Reads in a matrix in the format of the Harwell-Boeing + benchmark suite. - Description [Reads in a matrix in the format of the Harwell-Boeing - benchmark suite. The variables are ordered as follows: + @details The variables are ordered as follows: <blockquote> x\[0\] y\[0\] x\[1\] y\[1\] ... </blockquote> 0 is the most significant bit. On input, nx and ny hold the numbers - of row and column variables already in existence. On output, they - hold the numbers of row and column variables actually used by the - matrix. m and n are set to the numbers of rows and columns of the - matrix. Their values on input are immaterial. Returns 1 on - success; 0 otherwise. The ADD for the sparse matrix is returned in - E, and its reference count is > 0.] + of row and column variables already in existence. + + @return 1 on success; 0 otherwise. - SideEffects [None] + @sideeffect On output, nx and ny hold the numbers of row and column + variables actually used by the matrix. m and n are set to the + numbers of rows and columns of the matrix. Their values on input + are immaterial. The %ADD for the sparse matrix is returned in E, and + its reference count is > 0. - SeeAlso [Cudd_addRead Cudd_bddRead] + @see Cudd_addRead Cudd_bddRead -******************************************************************************/ +*/ int Cudd_addHarwell( - FILE * fp /* pointer to the input file */, - DdManager * dd /* DD manager */, - DdNode ** E /* characteristic function of the graph */, - DdNode *** x /* array of row variables */, - DdNode *** y /* array of column variables */, - DdNode *** xn /* array of complemented row variables */, - DdNode *** yn_ /* array of complemented column variables */, - int * nx /* number or row variables */, - int * ny /* number or column variables */, - int * m /* number of rows */, - int * n /* number of columns */, - int bx /* first index of row variables */, - int sx /* step of row variables */, - int by /* first index of column variables */, - int sy /* step of column variables */, - int pr /* verbosity level */) + FILE * fp /**< pointer to the input file */, + DdManager * dd /**< %DD manager */, + DdNode ** E /**< characteristic function of the graph */, + DdNode *** x /**< array of row variables */, + DdNode *** y /**< array of column variables */, + DdNode *** xn /**< array of complemented row variables */, + DdNode *** yn_ /**< array of complemented column variables */, + int * nx /**< number or row variables */, + int * ny /**< number or column variables */, + int * m /**< number of rows */, + int * n /**< number of columns */, + int bx /**< first index of row variables */, + int sx /**< step of row variables */, + int by /**< first index of column variables */, + int sy /**< step of column variables */, + int pr /**< verbosity level */) { DdNode *one, *zero; DdNode *w; DdNode *cubex, *cubey, *minterm1; int u, v, err, i, j, nv; double val; - DdNode **lx, **ly, **lxn, **lyn; /* local copies of x, y, xn, yn_ */ + /* local copies of x, y, xn, yn_ */ + DdNode **lx = NULL, **ly = NULL, **lxn = NULL, **lyn = NULL; int lnx, lny; /* local copies of nx and ny */ char title[73], key[9], mxtype[4], rhstyp[4]; int totcrd, ptrcrd, indcrd, valcrd, rhscrd, @@ -315,13 +305,23 @@ Cudd_addHarwell( dd->reordered = 0; lx[i] = cuddUniqueInter(dd, nv, one, zero); } while (dd->reordered == 1); - if (lx[i] == NULL) return(0); + if (lx[i] == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(0); + } cuddRef(lx[i]); do { dd->reordered = 0; lxn[i] = cuddUniqueInter(dd, nv, zero, one); } while (dd->reordered == 1); - if (lxn[i] == NULL) return(0); + if (lxn[i] == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(0); + } cuddRef(lxn[i]); } for (i= *ny,nv=by+(*ny)*sy; i < lny; i++,nv+=sy) { @@ -329,13 +329,23 @@ Cudd_addHarwell( dd->reordered = 0; ly[i] = cuddUniqueInter(dd, nv, one, zero); } while (dd->reordered == 1); - if (ly[i] == NULL) return(0); + if (ly[i] == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(0); + } cuddRef(ly[i]); do { dd->reordered = 0; lyn[i] = cuddUniqueInter(dd, nv, zero, one); } while (dd->reordered == 1); - if (lyn[i] == NULL) return(0); + if (lyn[i] == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(0); + } cuddRef(lyn[i]); } diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddInit.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddInit.c similarity index 68% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddInit.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddInit.c index 12830bdeb..18f918fab 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddInit.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddInit.c @@ -1,28 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddInit.c] + @ingroup cudd - PackageName [cudd] + @brief Functions to initialize and shut down the %DD manager. - Synopsis [Functions to initialize and shut down the DD manager.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_Init() - <li> Cudd_Quit() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddInitUniv() - <li> cuddZddFreeUniv() - </ul> - ] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -52,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -78,52 +65,46 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddInit.c,v 1.34 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Creates a new DD manager. - Synopsis [Creates a new DD manager.] + @details Initializes the table, the basic constants and the + projection functions. If maxMemory is 0, Cudd_Init decides suitable + values for the maximum size of the cache and for the limit for fast + unique table growth based on the available memory. - Description [Creates a new DD manager, initializes the table, the - basic constants and the projection functions. If maxMemory is 0, - Cudd_Init decides suitable values for the maximum size of the cache - and for the limit for fast unique table growth based on the available - memory. Returns a pointer to the manager if successful; NULL - otherwise.] + @return a pointer to the manager if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Quit] + @see Cudd_Quit -******************************************************************************/ +*/ DdManager * Cudd_Init( - unsigned int numVars /* initial number of BDD variables (i.e., subtables) */, - unsigned int numVarsZ /* initial number of ZDD variables (i.e., subtables) */, - unsigned int numSlots /* initial size of the unique tables */, - unsigned int cacheSize /* initial size of the cache */, - unsigned long maxMemory /* target maximum memory occupation */) + unsigned int numVars /**< initial number of %BDD variables (i.e., subtables) */, + unsigned int numVarsZ /**< initial number of %ZDD variables (i.e., subtables) */, + unsigned int numSlots /**< initial size of the unique tables */, + unsigned int cacheSize /**< initial size of the cache */, + size_t maxMemory /**< target maximum memory occupation */) { DdManager *unique; int i,result; @@ -140,14 +121,14 @@ Cudd_Init( DD_MAX_LOOSE_FRACTION); unique = cuddInitTable(numVars,numVarsZ,numSlots,looseUpTo); if (unique == NULL) return(NULL); - unique->maxmem = (unsigned long) maxMemory / 10 * 9; + unique->maxmem = (size_t) maxMemory / 10 * 9; maxCacheSize = (unsigned int) ((maxMemory / sizeof(DdCache)) / DD_MAX_CACHE_FRACTION); result = cuddInitCache(unique,cacheSize,maxCacheSize); if (result == 0) return(NULL); saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = unique->outOfMemCallback; unique->stash = ALLOC(char,(maxMemory / DD_STASH_FRACTION) + 4); MMoutOfMemory = saveHandler; if (unique->stash == NULL) { @@ -201,25 +182,22 @@ Cudd_Init( } /* end of Cudd_Init */ -/**Function******************************************************************** - - Synopsis [Deletes resources associated with a DD manager.] +/** + @brief Deletes resources associated with a %DD manager. - Description [Deletes resources associated with a DD manager and - resets the global statistical counters. (Otherwise, another manaqger - subsequently created would inherit the stats of this one.)] + @details Calling Cudd_Quit with a null pointer has no effect. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Init] + @see Cudd_Init -******************************************************************************/ +*/ void Cudd_Quit( - DdManager * unique) + DdManager * unique /**< pointer to manager */) { - if (unique->stash != NULL) FREE(unique->stash); - cuddFreeTable(unique); + if (unique) + cuddFreeTable(unique); } /* end of Cudd_Quit */ @@ -229,18 +207,16 @@ Cudd_Quit( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Initializes the ZDD universe.] +/** + @brief Initializes the %ZDD universe. - Description [Initializes the ZDD universe. Returns 1 if successful; 0 - otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddZddFreeUniv] + @see cuddZddFreeUniv -******************************************************************************/ +*/ int cuddZddInitUniv( DdManager * zdd) @@ -279,17 +255,14 @@ cuddZddInitUniv( } /* end of cuddZddInitUniv */ -/**Function******************************************************************** - - Synopsis [Frees the ZDD universe.] - - Description [Frees the ZDD universe.] +/** + @brief Frees the %ZDD universe. - SideEffects [None] + @sideeffect None - SeeAlso [cuddZddInitUniv] + @see cuddZddInitUniv -******************************************************************************/ +*/ void cuddZddFreeUniv( DdManager * zdd) diff --git a/resources/3rdparty/cudd-3.0.0/cudd/cuddInt.h b/resources/3rdparty/cudd-3.0.0/cudd/cuddInt.h new file mode 100644 index 000000000..ccb2a8f16 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddInt.h @@ -0,0 +1,1251 @@ +/** + @file + + @ingroup cudd + + @brief Internal data structures of the CUDD package. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#ifndef CUDD_INT_H_ +#define CUDD_INT_H_ + + +/*---------------------------------------------------------------------------*/ +/* Nested includes */ +/*---------------------------------------------------------------------------*/ + +#include <math.h> +#include "config.h" +#include "st.h" +#include "mtr.h" +#include "epd.h" +#include "cudd.h" + +/*---------------------------------------------------------------------------*/ +/* Constant declarations */ +/*---------------------------------------------------------------------------*/ + +#define CUDD_VERSION PACKAGE_VERSION + +#define DD_MAXREF ((DdHalfWord) ~0) + +#define DD_DEFAULT_RESIZE 10 /* how many extra variables */ + /* should be added when resizing */ +#define DD_MEM_CHUNK 1022 + +/* These definitions work for CUDD_VALUE_TYPE == double */ +#define DD_ONE_VAL (1.0) +#define DD_ZERO_VAL (0.0) +#define DD_EPSILON (1.0e-12) + +/* The definitions of +/- infinity in terms of HUGE_VAL work on +** the DECstations and on many other combinations of OS/compiler. +*/ +#ifdef HAVE_IEEE_754 +# define DD_PLUS_INF_VAL (HUGE_VAL) +#else +# define DD_PLUS_INF_VAL (10e301) +# define DD_CRI_HI_MARK (10e150) +# define DD_CRI_LO_MARK (-(DD_CRI_HI_MARK)) +#endif +#define DD_MINUS_INF_VAL (-(DD_PLUS_INF_VAL)) + +#define DD_NON_CONSTANT ((DdNode *) 1) /* for Cudd_bddIteConstant */ + +/* Unique table and cache management constants. */ +#define DD_MAX_SUBTABLE_DENSITY 4 /* tells when to resize a subtable */ +/* gc when this percent are dead (measured w.r.t. slots, not keys) +** The first limit (LO) applies normally. The second limit applies when +** the package believes more space for the unique table (i.e., more dead +** nodes) would improve performance, and the unique table is not already +** too large. The third limit applies when memory is low. +*/ +#define DD_GC_FRAC_LO DD_MAX_SUBTABLE_DENSITY * 0.25 +#define DD_GC_FRAC_HI DD_MAX_SUBTABLE_DENSITY * 1.0 +#define DD_GC_FRAC_MIN 0.2 +#define DD_MIN_HIT 30 /* resize cache when hit ratio + above this percentage (default) */ +#define DD_MAX_LOOSE_FRACTION 5 /* 1 / (max fraction of memory used for + unique table in fast growth mode) */ +#define DD_MAX_CACHE_FRACTION 3 /* 1 / (max fraction of memory used for + computed table if resizing enabled) */ +#define DD_STASH_FRACTION 64 /* 1 / (fraction of memory set + aside for emergencies) */ +#define DD_MAX_CACHE_TO_SLOTS_RATIO 4 /* used to limit the cache size */ + +/* Variable ordering default parameter values. */ +#define DD_SIFT_MAX_VAR 1000 +#define DD_SIFT_MAX_SWAPS 2000000 +#define DD_DEFAULT_RECOMB 0 +#define DD_MAX_REORDER_GROWTH 1.2 +#define DD_FIRST_REORDER 4004 /* 4 for the constants */ +#define DD_DYN_RATIO 2 /* when to dynamically reorder */ + +/* Primes for cache hash functions. */ +#define DD_P1 12582917 +#define DD_P2 4256249 +#define DD_P3 741457 +#define DD_P4 1618033999 + +/* Cache tags for 3-operand operators. These tags are stored in the +** least significant bits of the cache operand pointers according to +** the following scheme. The tag consists of two hex digits. Both digits +** must be even, so that they do not interfere with complementation bits. +** The least significant one is stored in Bits 3:1 of the f operand in the +** cache entry. Bit 1 is always 1, so that we can differentiate +** three-operand operations from one- and two-operand operations. +** Therefore, the least significant digit is one of {2,6,a,e}. The most +** significant digit occupies Bits 3:1 of the g operand in the cache +** entry. It can by any even digit between 0 and e. This gives a total +** of 5 bits for the tag proper, which means a maximum of 32 three-operand +** operations. */ +#define DD_ADD_ITE_TAG 0x02 +#define DD_BDD_AND_ABSTRACT_TAG 0x06 +#define DD_BDD_XOR_EXIST_ABSTRACT_TAG 0x0a +#define DD_BDD_ITE_TAG 0x0e +#define DD_ADD_BDD_DO_INTERVAL_TAG 0x22 +#define DD_BDD_CLIPPING_AND_ABSTRACT_UP_TAG 0x26 +#define DD_BDD_CLIPPING_AND_ABSTRACT_DOWN_TAG 0x2a +#define DD_BDD_COMPOSE_RECUR_TAG 0x2e +#define DD_ADD_COMPOSE_RECUR_TAG 0x42 +#define DD_ADD_NON_SIM_COMPOSE_TAG 0x46 +#define DD_EQUIV_DC_TAG 0x4a +#define DD_ZDD_ITE_TAG 0x4e +#define DD_ADD_ITE_CONSTANT_TAG 0x62 +#define DD_ADD_EVAL_CONST_TAG 0x66 +#define DD_BDD_ITE_CONSTANT_TAG 0x6a +#define DD_ADD_OUT_SUM_TAG 0x6e +#define DD_BDD_LEQ_UNLESS_TAG 0x82 +#define DD_ADD_TRIANGLE_TAG 0x86 +#define DD_BDD_MAX_EXP_TAG 0x8a +#define DD_VARS_SYMM_BEFORE_TAG 0x8e +#define DD_VARS_SYMM_BETWEEN_TAG 0xa2 + +/* Generator constants. */ +#define CUDD_GEN_CUBES 0 +#define CUDD_GEN_PRIMES 1 +#define CUDD_GEN_NODES 2 +#define CUDD_GEN_ZDD_PATHS 3 +#define CUDD_GEN_EMPTY 0 +#define CUDD_GEN_NONEMPTY 1 + +/** + ** @brief Maximum variable index. + ** + ** @details CUDD_MAXINDEX is defined in such a way that on 32-bit and + ** 64-bit machines one can cast an index to (int) without generating + ** a negative number. + */ +#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 +#define CUDD_MAXINDEX (((DdHalfWord) ~0) >> 1) +#else +#define CUDD_MAXINDEX ((DdHalfWord) ~0) +#endif + +/** + ** @brief The index of constant nodes. + ** + ** @details This is a synonim for CUDD_MAXINDEX. + */ +#define CUDD_CONST_INDEX CUDD_MAXINDEX + +/** + ** @brief Size of the random number generator shuffle table. + */ +#define STAB_SIZE 64 + +/** + ** @brief Mask for periodic check of termination and timeout. + ** + ** @see checkWhetherToGiveUp + */ +#define CUDD_CHECK_MASK 0x7ff + +/*---------------------------------------------------------------------------*/ +/* Type declarations */ +/*---------------------------------------------------------------------------*/ + +/** + @brief Type that is half the size of a pointer. +*/ +#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 +typedef uint32_t DdHalfWord; +#else +typedef uint16_t DdHalfWord; +#endif + +/** + * @brief Signed integer that is the size of a pointer. + * + * @details The only platforms on which CUDD has been tested define + * intptr_t and uintptr_t in inttypes.h and satisfy the condition + * + * sizeof(intptr_t) == sizeof(uintptr_t) == sizeof(void *) + * + * Neither of these is guaranteed by the C standard. + */ +typedef intptr_t ptrint; + +/** + * @brief Unsigned integer that is the size of a pointer. + * + * @see ptrint + */ +typedef uintptr_t ptruint; + +typedef struct DdChildren DdChildren; +typedef struct DdHook DdHook; +typedef struct DdSubtable DdSubtable; +typedef struct DdCache DdCache; +typedef struct DdLocalCacheItem DdLocalCacheItem; +typedef struct DdLocalCache DdLocalCache; +typedef struct DdHashItem DdHashItem; +typedef struct DdHashTable DdHashTable; +typedef struct Move Move; +typedef struct IndexKey IndexKey; +typedef struct DdQueueItem DdQueueItem; +typedef struct DdLevelQueue DdLevelQueue; + +/*---------------------------------------------------------------------------*/ +/* Stucture declarations */ +/*---------------------------------------------------------------------------*/ + +/** + * @brief The two children of a non-terminal node. + */ +struct DdChildren { + struct DdNode *T; /**< then (true) child */ + struct DdNode *E; /**< else (false) child */ +}; + +/** + * @brief Decision diagram node. + */ +struct DdNode { + DdHalfWord index; /**< variable index */ + DdHalfWord ref; /**< reference count */ + DdNode *next; /**< next pointer for unique table */ + union { + CUDD_VALUE_TYPE value; /**< for constant (terminal) nodes */ + DdChildren kids; /**< for internal nodes */ + } type; /**< terminal or internal */ +}; + +/** + * @brief CUDD generator. + */ +struct DdGen { + DdManager *manager; + int type; + int status; + union { + struct { + int *cube; + CUDD_VALUE_TYPE value; + } cubes; + struct { + int *cube; + DdNode *ub; + } primes; + struct { + int size; + } nodes; + } gen; + struct { + int sp; + DdNode **stack; + } stack; + DdNode *node; +}; + +/** + ** @brief CUDD hook + ** + ** Hooks in CUDD are functions that the application registers with the + ** manager so that they are called at appropriate times. The functions + ** are passed the manager as argument; they should return 1 if + ** successful and 0 otherwise. + */ +struct DdHook { + DD_HFP f; /**< function to be called */ + struct DdHook *next; /**< next element in the list */ +}; + +/** + * @brief Generic local cache item. + */ +struct DdLocalCacheItem { + DdNode *value; +#ifdef DD_CACHE_PROFILE + ptrint count; +#endif + DdNode *key[1]; +}; + +/** + * @brief Local cache. + */ +struct DdLocalCache { + DdLocalCacheItem *item; + unsigned int itemsize; + unsigned int keysize; + unsigned int slots; + int shift; + double lookUps; + double minHit; + double hits; + unsigned int maxslots; + DdManager *manager; + struct DdLocalCache *next; +}; + +/** + * @brief Local hash table item. + */ +struct DdHashItem { + struct DdHashItem *next; /**< collision list link */ + ptrint count; /**< reference count of item */ + DdNode *value; /**< value %DD */ + DdNode *key[1]; /**< key pointers */ +}; + +/** + * @brief Local hash table. + */ +struct DdHashTable { + unsigned int keysize; /**< number of pointers in the key */ + unsigned int itemsize; /**< size of hash table item in bytes */ + DdHashItem **bucket; /**< array of buckets */ + DdHashItem *nextFree; /**< item free list */ + DdHashItem **memoryList; /**< list of memory blocks for items */ + unsigned int numBuckets; /**< number of buckets in array */ + int shift; /**< shift used in hash function */ + unsigned int size; /**< number of items stored in table */ + unsigned int maxsize; /**< threshold for table resizing */ + DdManager *manager; /**< %DD manager */ +}; + +/** + * @brief Computed table. + */ +struct DdCache { + DdNode *f,*g; /**< DDs */ + ptruint h; /**< either operator or %DD */ + DdNode *data; /**< already constructed %DD */ +#ifdef DD_CACHE_PROFILE + ptrint count; /**< statistical counter */ +#endif +}; + +/** + * @brief Subtable for one index. + */ +struct DdSubtable { + DdNode **nodelist; /**< hash table */ + int shift; /**< shift for hash function */ + unsigned int slots; /**< size of the hash table */ + unsigned int keys; /**< number of nodes stored in this table */ + unsigned int maxKeys; /**< slots * DD_MAX_SUBTABLE_DENSITY */ + unsigned int dead; /**< number of dead nodes in this table */ + unsigned int next; /**< index of next variable in group */ + int bindVar; /**< flag to bind this variable to its level */ + /* Fields for lazy sifting. */ + Cudd_VariableType varType; /**< variable type (ps, ns, pi) */ + int pairIndex; /**< corresponding variable index (ps <-> ns) */ + int varHandled; /**< flag: 1 means variable is already handled */ + Cudd_LazyGroupType varToBeGrouped; /**< tells what grouping to apply */ +}; + +/** + * @brief Specialized %DD symbol table. + */ +struct DdManager { + /* Constants */ + DdNode sentinel; /**< for collision lists */ + DdNode *one; /**< constant 1 */ + DdNode *zero; /**< constant 0 */ + DdNode *plusinfinity; /**< plus infinity */ + DdNode *minusinfinity; /**< minus infinity */ + DdNode *background; /**< background value */ + /* Computed Table */ + DdCache *acache; /**< address of allocated memory for cache */ + DdCache *cache; /**< the cache-based computed table */ + unsigned int cacheSlots; /**< total number of cache entries */ + int cacheShift; /**< shift value for cache hash function */ + double cacheMisses; /**< number of cache misses (since resizing) */ + double cacheHits; /**< number of cache hits (since resizing) */ + double minHit; /**< hit percentage above which to resize */ + int cacheSlack; /**< slots still available for resizing */ + unsigned int maxCacheHard; /**< hard limit for cache size */ + /* Unique Table */ + int size; /**< number of unique subtables */ + int sizeZ; /**< for %ZDD */ + int maxSize; /**< max number of subtables before resizing */ + int maxSizeZ; /**< for %ZDD */ + DdSubtable *subtables; /**< array of unique subtables */ + DdSubtable *subtableZ; /**< for %ZDD */ + DdSubtable constants; /**< unique subtable for the constants */ + unsigned int slots; /**< total number of hash buckets */ + unsigned int keys; /**< total number of %BDD and %ADD nodes */ + unsigned int keysZ; /**< total number of %ZDD nodes */ + unsigned int dead; /**< total number of dead %BDD and %ADD nodes */ + unsigned int deadZ; /**< total number of dead %ZDD nodes */ + unsigned int maxLive; /**< maximum number of live nodes */ + unsigned int minDead; /**< do not GC if fewer than these dead */ + int gcEnabled; /**< gc is enabled */ + double gcFrac; /**< gc when this fraction is dead */ + unsigned int looseUpTo; /**< slow growth beyond this limit */ + /**< (measured w.r.t. slots, not keys) */ + unsigned int initSlots; /**< initial size of a subtable */ + DdNode **stack; /**< stack for iterative procedures */ + double allocated; /**< number of nodes allocated */ + /**< (not during reordering) */ + double reclaimed; /**< number of nodes brought back from the dead */ + int *perm; /**< current variable perm. (index to level) */ + int *permZ; /**< for %ZDD */ + int *invperm; /**< current inv. var. perm. (level to index) */ + int *invpermZ; /**< for %ZDD */ + DdNode **vars; /**< projection functions */ + int *map; /**< variable map for fast swap */ + DdNode **univ; /**< %ZDD 1 for each variable */ + unsigned int isolated; /**< isolated projection functions */ + unsigned int originalSize; /**< used by lazy sifting */ + int linearSize; /**< number of rows and columns of linear */ + ptruint *interact; /**< interacting variable matrix */ + ptruint *linear; /**< linear transform matrix */ + /* Memory Management */ + DdNode **memoryList; /**< memory manager for symbol table */ + DdNode *nextFree; /**< list of free nodes */ + char *stash; /**< memory reserve */ +#ifndef DD_NO_DEATH_ROW + DdNode **deathRow; /**< queue for dereferencing */ + int deathRowDepth; /**< number of slots in the queue */ + int nextDead; /**< index in the queue */ + unsigned deadMask; /**< mask for circular index update */ +#endif + /* General Parameters */ + CUDD_VALUE_TYPE epsilon; /**< tolerance on comparisons */ + /* Dynamic Reordering Parameters */ + int reordered; /**< flag set at the end of reordering */ + unsigned int reorderings; /**< number of calls to Cudd_ReduceHeap */ + unsigned int maxReorderings;/**< maximum number of calls to Cudd_ReduceHeap */ + int siftMaxVar; /**< maximum number of vars sifted */ + int siftMaxSwap; /**< maximum number of swaps per sifting */ + int ddTotalNumberSwapping; /**< number of %BDD/%ADD swaps completed */ + int zddTotalNumberSwapping; /**< number of %ZDD swaps completed */ + int reordCycle; /**< how often to apply alternate threshold */ + double maxGrowth; /**< maximum growth during reordering */ + double maxGrowthAlt; /**< alternate maximum growth for reordering */ + int autoDyn; /**< automatic dynamic reordering flag (BDD) */ + int autoDynZ; /**< automatic dynamic reordering flag (ZDD) */ + Cudd_ReorderingType autoMethod; /**< default reordering method */ + Cudd_ReorderingType autoMethodZ; /**< default reordering method (ZDD) */ + int realign; /**< realign %ZDD order after %BDD reordering */ + int realignZ; /**< realign %BDD order after %ZDD reordering */ + unsigned int nextDyn; /**< reorder if this size is reached */ + unsigned int countDead; /**< if 0, count deads to trigger reordering */ + MtrNode *tree; /**< variable group tree (BDD) */ + MtrNode *treeZ; /**< variable group tree (ZDD) */ + Cudd_AggregationType groupcheck; /**< used during group sifting */ + int recomb; /**< used during group sifting */ + int symmviolation; /**< used during group sifting */ + int arcviolation; /**< used during group sifting */ + int populationSize; /**< population size for GA */ + int numberXovers; /**< number of crossovers for GA */ + unsigned int randomizeOrder; /**< perturb the next reordering threshold */ + DdLocalCache *localCaches; /**< local caches currently in existence */ + void *hooks; /**< application-specific field (used by vis) */ + DdHook *preGCHook; /**< hooks to be called before GC */ + DdHook *postGCHook; /**< hooks to be called after GC */ + DdHook *preReorderingHook; /**< hooks to be called before reordering */ + DdHook *postReorderingHook; /**< hooks to be called after reordering */ + FILE *out; /**< stdout for this manager */ + FILE *err; /**< stderr for this manager */ + Cudd_ErrorType errorCode; /**< info on last error */ + unsigned long startTime; /**< start time in milliseconds */ + unsigned long timeLimit; /**< CPU time limit */ + DD_THFP terminationCallback; /**< termination callback */ + void * tcbArg; /**< second argument passed to termination handler */ + DD_OOMFP outOfMemCallback; /**< out-of-memory callback */ + DD_TOHFP timeoutHandler; /**< timeout handler */ + void * tohArg; /**< second argument passed to timeout handler */ + /* Statistical counters. */ + size_t memused; /**< total memory allocated for the manager */ + size_t maxmem; /**< target maximum memory */ + size_t maxmemhard; /**< hard limit for maximum memory */ + int garbageCollections; /**< number of garbage collections */ + unsigned long GCTime; /**< total time spent in garbage collection */ + unsigned long reordTime; /**< total time spent in reordering */ + double totCachehits; /**< total number of cache hits */ + double totCacheMisses; /**< total number of cache misses */ + double cachecollisions; /**< number of cache collisions */ + double cacheinserts; /**< number of cache insertions */ + double cacheLastInserts; /**< insertions at the last cache resizing */ + double cachedeletions; /**< number of deletions during garbage coll. */ + unsigned int peakLiveNodes; /**< maximum number of live nodes */ + /* Random number generator. */ + int32_t cuddRand; /**< state of the random number generator */ + int32_t cuddRand2; /**< state of the random number generator */ + int32_t shuffleSelect; /**< state of the random number generator */ + int32_t shuffleTable[STAB_SIZE]; /**< state of the random number generator */ +#ifdef DD_STATS + double nodesFreed; /**< number of nodes returned to the free list */ + double nodesDropped; /**< number of nodes killed by dereferencing */ + int totalNISwaps; /**< number of non-interacting (cheap) swaps */ + int extsymmcalls; /**< number of calls to symmetry check fn */ + int extsymm; /**< number of successful symmetry checks */ + int secdiffcalls; /**< number of calls to second difference fn */ + int secdiff; /**< number of successful second diff. checks */ + int secdiffmisfire; /**< number of misfired second diff. checks */ + int tosses; /**< number of coin tosses in annealing */ + int acceptances; /**< number of acceptances in annealing */ + int totalShuffles; /**< number of shuffles in exact reordering */ + int totalNumberLinearTr; /**< number of linear transformations */ + int num_calls; /**< should equal 2n-1 (n is the # of nodes) */ +#endif +#ifdef DD_UNIQUE_PROFILE + double uniqueLookUps; /**< number of unique table lookups */ + double uniqueLinks; /**< total distance traveled in coll. chains */ +#endif +#ifdef DD_COUNT + double recursiveCalls; /**< number of recursive calls */ +#ifdef DD_STATS + double nextSample; /**< when to write next line of stats */ +#endif + double swapSteps; /**< number of elementary reordering steps */ +#endif +#ifdef DD_DEBUG + int addPermuteRecurHits; /**< debug variable for variable permutation */ + int bddPermuteRecurHits; /**< debug variable for variable permutation */ + int bddVectorComposeHits; /**< debug variable for vector composition */ + int addVectorComposeHits; /**< debug variable for vector composition */ + int addGeneralVectorComposeHits; /**< debug var. for vector composition */ + int enableExtraDebug; /**< deposit a 1 here to enable more debugging */ +#endif +}; + +/** + * @brief Reordering move record. + */ +struct Move { + DdHalfWord x; + DdHalfWord y; + unsigned int flags; + int size; + struct Move *next; +}; + +/** + * @brief Used to sort variables for reordering. + */ +struct IndexKey { + int index; + int keys; +}; + +/** + * @brief Generic level queue item. + */ +struct DdQueueItem { + struct DdQueueItem *next; + struct DdQueueItem *cnext; + void *key; +}; + +/** + * @brief Level queue. + */ +struct DdLevelQueue { + void *first; + DdQueueItem **last; + DdQueueItem *freelist; + DdQueueItem **buckets; + int levels; + int itemsize; + int size; + int maxsize; + int numBuckets; + int shift; + DdManager *manager; +}; + +/*---------------------------------------------------------------------------*/ +/* Variable declarations */ +/*---------------------------------------------------------------------------*/ + + +/*---------------------------------------------------------------------------*/ +/* Macro declarations */ +/*---------------------------------------------------------------------------*/ + +/** + @brief Adds node to the head of the free list. + + @details Does not deallocate memory chunks that become free. This + function is also used by the dynamic reordering functions. + + @sideeffect None + + @see cuddAllocNode cuddDynamicAllocNode cuddDeallocMove + +*/ +#define cuddDeallocNode(unique,node) \ + (node)->next = (unique)->nextFree; \ + (unique)->nextFree = node; + +/** + @brief Adds node to the head of the free list. + + @details Does not deallocate memory chunks that become free. This + function is also used by the dynamic reordering functions. + + @sideeffect None + + @see cuddDeallocNode cuddDynamicAllocNode + +*/ +#define cuddDeallocMove(unique,node) \ + ((DdNode *)(node))->ref = 0; \ + ((DdNode *)(node))->next = (unique)->nextFree; \ + (unique)->nextFree = (DdNode *)(node); + + +/** + @brief Increases the reference count of a node, if it is not + saturated. + + @details This being a macro, it is faster than Cudd_Ref, but it + cannot be used in constructs like cuddRef(a = b()). + + @sideeffect none + + @see Cudd_Ref + +*/ +#define cuddRef(n) cuddSatInc(Cudd_Regular(n)->ref) + + +/** + @brief Decreases the reference count of a node, if it is not + saturated. + + @details It is primarily used in recursive procedures to decrease + the ref count of a result node before returning it. This + accomplishes the goal of removing the protection applied by a + previous cuddRef. This being a macro, it is faster than Cudd_Deref, + but it cannot be used in constructs like cuddDeref(a = b()). + + @sideeffect none + + @see Cudd_Deref + +*/ +#define cuddDeref(n) cuddSatDec(Cudd_Regular(n)->ref) + + +/** + @brief Returns 1 if the node is a constant node. + + @details Returns 1 if the node is a constant node (rather than an + internal node). All constant nodes have the same index + (CUDD_CONST_INDEX). The pointer passed to Cudd_IsConstantInt may be either + regular or complemented. + + @sideeffect none + + @see cuddIsConstant Cudd_IsConstant + +*/ +#define Cudd_IsConstantInt(node) ((Cudd_Regular(node))->index == CUDD_CONST_INDEX) + + +/** + @brief Returns 1 if the node is a constant node. + + @details Returns 1 if the node is a constant node (rather than an + internal node). All constant nodes have the same index + (CUDD_CONST_INDEX). The pointer passed to cuddIsConstant must be regular. + + @sideeffect none + + @see Cudd_IsConstant Cudd_IsConstantInt + +*/ +#define cuddIsConstant(node) ((node)->index == CUDD_CONST_INDEX) + + +/** + @brief Returns the then child of an internal node. + + @details If <code>node</code> is a constant node, the result is + unpredictable. The pointer passed to cuddT must be regular. + + @sideeffect none + + @see Cudd_T + +*/ +#define cuddT(node) ((node)->type.kids.T) + + +/** + @brief Returns the else child of an internal node. + + @details If <code>node</code> is a constant node, the result is + unpredictable. The pointer passed to cuddE must be regular. + + @sideeffect none + + @see Cudd_E + +*/ +#define cuddE(node) ((node)->type.kids.E) + + +/** + @brief Returns the value of a constant node. + + @details If <code>node</code> is an internal node, the result is + unpredictable. The pointer passed to cuddV must be regular. + + @sideeffect none + + @see Cudd_V + +*/ +#define cuddV(node) ((node)->type.value) + + +/** + @brief Finds the current position of variable index in the + order. + + @details This macro duplicates the functionality of Cudd_ReadPerm, + but it does not check for out-of-bounds indices and it is more + efficient. + + @sideeffect none + + @see Cudd_ReadPerm + +*/ +#define cuddI(dd,index) (((index)==CUDD_CONST_INDEX)?(int)(index):(dd)->perm[(index)]) + + +/** + @brief Finds the current position of %ZDD variable index in the + order. + + @details This macro duplicates the functionality of + Cudd_ReadPermZdd, but it does not check for out-of-bounds indices + and it is more efficient. + + @sideeffect none + + @see Cudd_ReadPermZdd + +*/ +#define cuddIZ(dd,index) (((index)==CUDD_CONST_INDEX)?(int)(index):(dd)->permZ[(index)]) + + +/** + @brief Hash function for the unique table. + + @details + + @sideeffect none + + @see ddCHash ddCHash2 + +*/ +#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 +#define ddHash(f,g,s) \ +((((unsigned)(ptruint)(f) * DD_P1 + \ + (unsigned)(ptruint)(g)) * DD_P2) >> (s)) +#else +#define ddHash(f,g,s) \ +((((unsigned)(f) * DD_P1 + (unsigned)(g)) * DD_P2) >> (s)) +#endif + + +/** + @brief Hash function for the cache. + + @sideeffect none + + @see ddHash ddCHash2 + +*/ +#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 +#define ddCHash(o,f,g,h,s) \ +((((((unsigned)(ptruint)(f) + (unsigned)(ptruint)(o)) * DD_P1 + \ + (unsigned)(ptruint)(g)) * DD_P2 + \ + (unsigned)(ptruint)(h)) * DD_P3) >> (s)) +#else +#define ddCHash(o,f,g,h,s) \ +((((((unsigned)(f) + (unsigned)(o)) * DD_P1 + (unsigned)(g)) * DD_P2 + \ + (unsigned)(h)) * DD_P3) >> (s)) +#endif + + +/** + @brief Hash function for the cache for functions with two operands. + + @sideeffect none + + @see ddHash ddCHash + +*/ +#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 +#define ddCHash2(o,f,g,s) \ +(((((unsigned)(ptruint)(f) + (unsigned)(ptruint)(o)) * DD_P1 + \ + (unsigned)(ptruint)(g)) * DD_P2) >> (s)) +#else +#define ddCHash2(o,f,g,s) \ +(((((unsigned)(f) + (unsigned)(o)) * DD_P1 + (unsigned)(g)) * DD_P2) >> (s)) +#endif + + +/** + @brief Clears the 4 least significant bits of a pointer. + + @sideeffect none + +*/ +#define cuddClean(p) ((DdNode *)((ptruint)(p) & ~ (ptruint) 0xf)) + + +/** + @brief Computes the minimum of two numbers. + + @sideeffect none + + @see ddMax + +*/ +#define ddMin(x,y) (((y) < (x)) ? (y) : (x)) + + +/** + @brief Computes the maximum of two numbers. + + @sideeffect none + + @see ddMin + +*/ +#define ddMax(x,y) (((y) > (x)) ? (y) : (x)) + + +/** + @brief Computes the absolute value of a number. + + @sideeffect none + +*/ +#define ddAbs(x) (((x)<0) ? -(x) : (x)) + + +/** + @brief Returns 1 if the absolute value of the difference of the two + arguments x and y is less than e. + + @sideeffect none + +*/ +#define ddEqualVal(x,y,e) (ddAbs((x)-(y))<(e)) + + +/** + @brief Saturating increment operator. + + @details Saturation is only necessary on 32-bit machines, where the + reference count is only 16-bit wide. + + @sideeffect none + + @see cuddSatDec + +*/ +#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 +#define cuddSatInc(x) ((x)++) +#else +#define cuddSatInc(x) ((x) += (x) != (DdHalfWord)DD_MAXREF) +#endif + + +/** + @brief Saturating decrement operator. + + @details Saturation is only necessary on 32-bit machines, where the + reference count is only 16-bit wide. + + @sideeffect none + + @see cuddSatInc + +*/ +#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 +#define cuddSatDec(x) ((x)--) +#else +#define cuddSatDec(x) ((x) -= (x) != (DdHalfWord)DD_MAXREF) +#endif + + +/** + @brief Returns the constant 1 node. + + @sideeffect none + + @see DD_ZERO DD_PLUS_INFINITY DD_MINUS_INFINITY + +*/ +#define DD_ONE(dd) ((dd)->one) + + +/** + @brief Returns the arithmetic 0 constant node. + + @details This is different from the logical zero. The latter is + obtained by Cudd_Not(DD_ONE(dd)). + + @sideeffect none + + @see DD_ONE Cudd_Not DD_PLUS_INFINITY DD_MINUS_INFINITY + +*/ +#define DD_ZERO(dd) ((dd)->zero) + + +/** + @brief Returns the plus infinity constant node. + + @sideeffect none + + @see DD_ONE DD_ZERO DD_MINUS_INFINITY + +*/ +#define DD_PLUS_INFINITY(dd) ((dd)->plusinfinity) + + +/** + @brief Returns the minus infinity constant node. + + @sideeffect none + + @see DD_ONE DD_ZERO DD_PLUS_INFINITY + +*/ +#define DD_MINUS_INFINITY(dd) ((dd)->minusinfinity) + + +/** + @brief Enforces DD_MINUS_INF_VAL <= x <= DD_PLUS_INF_VAL. + + @details Furthermore, if x <= DD_MINUS_INF_VAL/2, x is set to + DD_MINUS_INF_VAL. Similarly, if DD_PLUS_INF_VAL/2 <= x, x is set to + DD_PLUS_INF_VAL. Normally this macro is a NOOP. However, if + HAVE_IEEE_754 is not defined, it makes sure that a value does not + get larger than infinity in absolute value, and once it gets to + infinity, stays there. If the value overflows before this macro is + applied, no recovery is possible. + + @sideeffect none + +*/ +#ifdef HAVE_IEEE_754 +#define cuddAdjust(x) +#else +#define cuddAdjust(x) ((x) = ((x) >= DD_CRI_HI_MARK) ? DD_PLUS_INF_VAL : (((x) <= DD_CRI_LO_MARK) ? DD_MINUS_INF_VAL : (x))) +#endif + + +/** + @brief Outputs a line of stats. + + @details Outputs a line of stats if DD_COUNT and DD_STATS are + defined. Increments the number of recursive calls if DD_COUNT is + defined. + + @sideeffect None + +*/ +#ifdef DD_COUNT +#ifdef DD_STATS +#define statLine(dd) \ + do { \ + (dd)->recursiveCalls++; \ + if ((dd)->recursiveCalls == (dd)->nextSample) { \ + (void) fprintf((dd)->err, \ + "@%.0f: %u nodes %u live %.0f dropped" \ + " %.0f reclaimed\n", \ + (dd)->recursiveCalls, (dd)->keys, \ + (dd)->keys - (dd)->dead, \ + (dd)->nodesDropped, (dd)->reclaimed); \ + (dd)->nextSample += 250000;} \ + } while (0) +#else +#define statLine(dd) (dd)->recursiveCalls++ +#endif +#else +#define statLine(dd) +#endif + + +/** + @brief Checks for termination or timeout. +*/ +#define checkWhetherToGiveUp(dd) \ + do { \ + if (((int64_t) CUDD_CHECK_MASK & (int64_t) (dd)->cacheMisses) == 0) { \ + if ((dd)->terminationCallback != NULL && \ + (dd)->terminationCallback((dd)->tcbArg)) { \ + (dd)->errorCode = CUDD_TERMINATION; \ + return(NULL); \ + } \ + if (util_cpu_time() - (dd)->startTime > (dd)->timeLimit) { \ + (dd)->errorCode = CUDD_TIMEOUT_EXPIRED; \ + return(NULL); \ + } \ + } \ + } while (0) + + +/** \cond */ + +/*---------------------------------------------------------------------------*/ +/* Function prototypes */ +/*---------------------------------------------------------------------------*/ + +#ifdef __cplusplus +extern "C" { +#endif + +extern DdNode * cuddAddExistAbstractRecur(DdManager *manager, DdNode *f, DdNode *cube); +extern DdNode * cuddAddUnivAbstractRecur(DdManager *manager, DdNode *f, DdNode *cube); +extern DdNode * cuddAddOrAbstractRecur(DdManager *manager, DdNode *f, DdNode *cube); +extern DdNode * cuddAddMinAbstractRecur (DdManager *manager, DdNode *f, DdNode *cube); +extern DdNode * cuddAddMaxAbstractRecur (DdManager *manager, DdNode *f, DdNode *cube); +extern DdNode * cuddAddApplyRecur(DdManager *dd, DdNode * (*)(DdManager *, DdNode **, DdNode **), DdNode *f, DdNode *g); +extern DdNode * cuddAddMonadicApplyRecur(DdManager * dd, DdNode * (*op)(DdManager *, DdNode *), DdNode * f); +extern DdNode * cuddAddScalarInverseRecur(DdManager *dd, DdNode *f, DdNode *epsilon); +extern DdNode * cuddAddIteRecur(DdManager *dd, DdNode *f, DdNode *g, DdNode *h); +extern DdNode * cuddAddCmplRecur(DdManager *dd, DdNode *f); +extern DdNode * cuddAddNegateRecur(DdManager *dd, DdNode *f); +extern DdNode * cuddAddRoundOffRecur(DdManager *dd, DdNode *f, double trunc); +extern DdNode * cuddUnderApprox(DdManager *dd, DdNode *f, int numVars, int threshold, int safe, double quality); +extern DdNode * cuddRemapUnderApprox(DdManager *dd, DdNode *f, int numVars, int threshold, double quality); +extern DdNode * cuddBiasedUnderApprox(DdManager *dd, DdNode *f, DdNode *b, int numVars, int threshold, double quality1, double quality0); +extern DdNode * cuddBddAndAbstractRecur(DdManager *manager, DdNode *f, DdNode *g, DdNode *cube); +extern int cuddAnnealing(DdManager *table, int lower, int upper); +extern DdNode * cuddBddExistAbstractRecur(DdManager *manager, DdNode *f, DdNode *cube); +extern DdNode * cuddBddXorExistAbstractRecur(DdManager *manager, DdNode *f, DdNode *g, DdNode *cube); +extern DdNode * cuddBddBooleanDiffRecur(DdManager *manager, DdNode *f, DdNode *var); +extern DdNode * cuddBddIteRecur(DdManager *dd, DdNode *f, DdNode *g, DdNode *h); +extern DdNode * cuddBddIntersectRecur(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * cuddBddAndRecur(DdManager *manager, DdNode *f, DdNode *g); +extern DdNode * cuddBddXorRecur(DdManager *manager, DdNode *f, DdNode *g); +extern DdNode * cuddBddTransfer(DdManager *ddS, DdManager *ddD, DdNode *f); +extern DdNode * cuddAddBddDoPattern(DdManager *dd, DdNode *f); +extern int cuddInitCache(DdManager *unique, unsigned int cacheSize, unsigned int maxCacheSize); +extern void cuddCacheInsert(DdManager *table, ptruint op, DdNode *f, DdNode *g, DdNode *h, DdNode *data); +extern void cuddCacheInsert2(DdManager *table, DdNode * (*)(DdManager *, DdNode *, DdNode *), DdNode *f, DdNode *g, DdNode *data); +extern void cuddCacheInsert1(DdManager *table, DdNode * (*)(DdManager *, DdNode *), DdNode *f, DdNode *data); +extern DdNode * cuddCacheLookup(DdManager *table, ptruint op, DdNode *f, DdNode *g, DdNode *h); +extern DdNode * cuddCacheLookupZdd(DdManager *table, ptruint op, DdNode *f, DdNode *g, DdNode *h); +extern DdNode * cuddCacheLookup2(DdManager *table, DdNode * (*)(DdManager *, DdNode *, DdNode *), DdNode *f, DdNode *g); +extern DdNode * cuddCacheLookup1(DdManager *table, DdNode * (*)(DdManager *, DdNode *), DdNode *f); +extern DdNode * cuddCacheLookup2Zdd(DdManager *table, DdNode * (*)(DdManager *, DdNode *, DdNode *), DdNode *f, DdNode *g); +extern DdNode * cuddCacheLookup1Zdd(DdManager *table, DdNode * (*)(DdManager *, DdNode *), DdNode *f); +extern DdNode * cuddConstantLookup(DdManager *table, ptruint op, DdNode *f, DdNode *g, DdNode *h); +extern int cuddCacheProfile(DdManager *table, FILE *fp); +extern void cuddCacheResize(DdManager *table); +extern void cuddCacheFlush(DdManager *table); +extern int cuddComputeFloorLog2(unsigned int value); +extern int cuddHeapProfile(DdManager *dd); +extern void cuddPrintNode(DdNode *f, FILE *fp); +extern void cuddPrintVarGroups(DdManager * dd, MtrNode * root, int zdd, int silent); +extern DdNode * cuddBddClippingAnd(DdManager *dd, DdNode *f, DdNode *g, int maxDepth, int direction); +extern DdNode * cuddBddClippingAndAbstract(DdManager *dd, DdNode *f, DdNode *g, DdNode *cube, int maxDepth, int direction); +extern void cuddGetBranches(DdNode *g, DdNode **g1, DdNode **g0); +extern DdNode * cuddCofactorRecur(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * cuddBddComposeRecur(DdManager *dd, DdNode *f, DdNode *g, DdNode *proj); +extern DdNode * cuddAddComposeRecur(DdManager *dd, DdNode *f, DdNode *g, DdNode *proj); +extern int cuddExact(DdManager *table, int lower, int upper); +extern DdNode * cuddBddConstrainRecur(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode * cuddBddRestrictRecur(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode * cuddBddNPAndRecur(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode * cuddAddConstrainRecur(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode * cuddAddRestrictRecur(DdManager *dd, DdNode *f, DdNode *c); +extern DdNode * cuddBddLICompaction(DdManager *dd, DdNode *f, DdNode *c); +extern int cuddGa(DdManager *table, int lower, int upper); +extern int cuddTreeSifting(DdManager *table, Cudd_ReorderingType method); +extern int cuddZddInitUniv(DdManager *zdd); +extern void cuddZddFreeUniv(DdManager *zdd); +extern void cuddSetInteract(DdManager *table, int x, int y); +extern int cuddTestInteract(DdManager *table, int x, int y); +extern int cuddInitInteract(DdManager *table); +extern DdLocalCache * cuddLocalCacheInit(DdManager *manager, unsigned int keySize, unsigned int cacheSize, unsigned int maxCacheSize); +extern void cuddLocalCacheQuit(DdLocalCache *cache); +extern void cuddLocalCacheInsert(DdLocalCache *cache, DdNodePtr *key, DdNode *value); +extern DdNode * cuddLocalCacheLookup(DdLocalCache *cache, DdNodePtr *key); +extern void cuddLocalCacheClearDead(DdManager *manager); +extern int cuddIsInDeathRow(DdManager *dd, DdNode *f); +extern int cuddTimesInDeathRow(DdManager *dd, DdNode *f); +extern void cuddLocalCacheClearAll(DdManager *manager); +#ifdef DD_CACHE_PROFILE +extern int cuddLocalCacheProfile(DdLocalCache *cache); +#endif +extern DdHashTable * cuddHashTableInit(DdManager *manager, unsigned int keySize, unsigned int initSize); +extern void cuddHashTableQuit(DdHashTable *hash); +extern void cuddHashTableGenericQuit(DdHashTable *hash); +extern int cuddHashTableInsert(DdHashTable *hash, DdNodePtr *key, DdNode *value, ptrint count); +extern DdNode * cuddHashTableLookup(DdHashTable *hash, DdNodePtr *key); +extern int cuddHashTableInsert1(DdHashTable *hash, DdNode *f, DdNode *value, ptrint count); +extern DdNode * cuddHashTableLookup1(DdHashTable *hash, DdNode *f); +extern int cuddHashTableInsert2(DdHashTable *hash, DdNode *f, DdNode *g, DdNode *value, ptrint count); +extern DdNode * cuddHashTableLookup2(DdHashTable *hash, DdNode *f, DdNode *g); +extern int cuddHashTableInsert3(DdHashTable *hash, DdNode *f, DdNode *g, DdNode *h, DdNode *value, ptrint count); +extern DdNode * cuddHashTableLookup3(DdHashTable *hash, DdNode *f, DdNode *g, DdNode *h); +extern int cuddHashTableGenericInsert(DdHashTable * hash, DdNode * f, void * value); +extern void * cuddHashTableGenericLookup(DdHashTable * hash, DdNode * f); +extern DdLevelQueue * cuddLevelQueueInit(int levels, int itemSize, int numBuckets, DdManager * manager); +extern void cuddLevelQueueQuit(DdLevelQueue *queue); +extern void * cuddLevelQueueFirst(DdLevelQueue * queue, void * key, int level); +extern void * cuddLevelQueueEnqueue(DdLevelQueue *queue, void *key, int level); +extern void cuddLevelQueueDequeue(DdLevelQueue *queue, int level); +extern int cuddLinearAndSifting(DdManager *table, int lower, int upper); +extern int cuddLinearInPlace(DdManager * table, int x, int y); +extern void cuddUpdateInteractionMatrix(DdManager * table, int xindex, int yindex); +extern int cuddInitLinear(DdManager *table); +extern int cuddResizeLinear(DdManager *table); +extern DdNode * cuddBddLiteralSetIntersectionRecur(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * cuddCProjectionRecur(DdManager *dd, DdNode *R, DdNode *Y, DdNode *Ysupp); +extern DdNode * cuddBddClosestCube(DdManager *dd, DdNode *f, DdNode *g, CUDD_VALUE_TYPE bound); +extern void cuddReclaim(DdManager *table, DdNode *n); +extern void cuddReclaimZdd(DdManager *table, DdNode *n); +extern void cuddClearDeathRow(DdManager *table); +extern void cuddShrinkDeathRow(DdManager *table); +extern DdNode * cuddDynamicAllocNode(DdManager *table); +extern int cuddSifting(DdManager *table, int lower, int upper); +extern int cuddSwapping(DdManager *table, int lower, int upper, Cudd_ReorderingType heuristic); +extern int cuddNextHigh(DdManager *table, int x); +extern int cuddNextLow(DdManager *table, int x); +extern int cuddSwapInPlace(DdManager *table, int x, int y); +extern int cuddBddAlignToZdd(DdManager *table); +extern DdNode * cuddBddMakePrime(DdManager *dd, DdNode *cube, DdNode *f); +extern DdNode * cuddSolveEqnRecur(DdManager *bdd, DdNode *F, DdNode *Y, DdNode **G, int n, int *yIndex, int i); +extern DdNode * cuddVerifySol(DdManager *bdd, DdNode *F, DdNode **G, int *yIndex, int n); +#ifdef ST_H_ +extern DdNode* cuddSplitSetRecur(DdManager *manager, st_table *mtable, int *varSeen, DdNode *p, double n, double max, int index); +#endif +extern DdNode * cuddSubsetHeavyBranch(DdManager *dd, DdNode *f, int numVars, int threshold); +extern DdNode * cuddSubsetShortPaths(DdManager *dd, DdNode *f, int numVars, int threshold, int hardlimit); +extern int cuddSymmCheck(DdManager *table, int x, int y); +extern int cuddSymmSifting(DdManager *table, int lower, int upper); +extern int cuddSymmSiftingConv(DdManager *table, int lower, int upper); +extern DdNode * cuddAllocNode(DdManager *unique); +extern DdManager * cuddInitTable(unsigned int numVars, unsigned int numVarsZ, unsigned int numSlots, unsigned int looseUpTo); +extern void cuddFreeTable(DdManager *unique); +extern int cuddGarbageCollect(DdManager *unique, int clearCache); +extern DdNode * cuddZddGetNode(DdManager *zdd, int id, DdNode *T, DdNode *E); +extern DdNode * cuddZddGetNodeIVO(DdManager *dd, int index, DdNode *g, DdNode *h); +extern DdNode * cuddUniqueInter(DdManager *unique, int index, DdNode *T, DdNode *E); +extern DdNode * cuddUniqueInterIVO(DdManager *unique, int index, DdNode *T, DdNode *E); +extern DdNode * cuddUniqueInterZdd(DdManager *unique, int index, DdNode *T, DdNode *E); +extern DdNode * cuddUniqueConst(DdManager *unique, CUDD_VALUE_TYPE value); +extern void cuddRehash(DdManager *unique, int i); +extern void cuddShrinkSubtable(DdManager *unique, int i); +extern int cuddInsertSubtables(DdManager *unique, int n, int level); +extern int cuddDestroySubtables(DdManager *unique, int n); +extern int cuddResizeTableZdd(DdManager *unique, int index); +extern void cuddSlowTableGrowth(DdManager *unique); +extern int cuddP(DdManager *dd, DdNode *f); +#ifdef ST_H_ +extern enum st_retval cuddStCountfree(void *key, void *value, void *arg); +extern int cuddCollectNodes(DdNode *f, st_table *visited); +#endif +extern DdNodePtr * cuddNodeArray(DdNode *f, int *n); +extern int cuddWindowReorder(DdManager *table, int low, int high, Cudd_ReorderingType submethod); +extern DdNode * cuddZddProduct(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * cuddZddUnateProduct(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * cuddZddWeakDiv(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * cuddZddWeakDivF(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * cuddZddDivide(DdManager *dd, DdNode *f, DdNode *g); +extern DdNode * cuddZddDivideF(DdManager *dd, DdNode *f, DdNode *g); +extern int cuddZddGetCofactors3(DdManager *dd, DdNode *f, int v, DdNode **f1, DdNode **f0, DdNode **fd); +extern int cuddZddGetCofactors2(DdManager *dd, DdNode *f, int v, DdNode **f1, DdNode **f0); +extern DdNode * cuddZddComplement(DdManager *dd, DdNode *node); +extern int cuddZddGetPosVarIndex(DdManager * dd, int index); +extern int cuddZddGetNegVarIndex(DdManager * dd, int index); +extern int cuddZddGetPosVarLevel(DdManager * dd, int index); +extern int cuddZddGetNegVarLevel(DdManager * dd, int index); +extern int cuddZddTreeSifting(DdManager *table, Cudd_ReorderingType method); +extern DdNode * cuddZddIsop(DdManager *dd, DdNode *L, DdNode *U, DdNode **zdd_I); +extern DdNode * cuddBddIsop(DdManager *dd, DdNode *L, DdNode *U); +extern DdNode * cuddMakeBddFromZddCover(DdManager *dd, DdNode *node); +extern int cuddZddLinearSifting(DdManager *table, int lower, int upper); +extern int cuddZddAlignToBdd(DdManager *table); +extern int cuddZddNextHigh(DdManager *table, int x); +extern int cuddZddNextLow(DdManager *table, int x); +extern int cuddZddUniqueCompare(void const *ptr_x, void const *ptr_y); +extern int cuddZddSwapInPlace(DdManager *table, int x, int y); +extern int cuddZddSwapping(DdManager *table, int lower, int upper, Cudd_ReorderingType heuristic); +extern int cuddZddSifting(DdManager *table, int lower, int upper); +extern DdNode * cuddZddIte(DdManager *dd, DdNode *f, DdNode *g, DdNode *h); +extern DdNode * cuddZddUnion(DdManager *zdd, DdNode *P, DdNode *Q); +extern DdNode * cuddZddIntersect(DdManager *zdd, DdNode *P, DdNode *Q); +extern DdNode * cuddZddDiff(DdManager *zdd, DdNode *P, DdNode *Q); +extern DdNode * cuddZddChangeAux(DdManager *zdd, DdNode *P, DdNode *zvar); +extern DdNode * cuddZddSubset1(DdManager *dd, DdNode *P, int var); +extern DdNode * cuddZddSubset0(DdManager *dd, DdNode *P, int var); +extern DdNode * cuddZddChange(DdManager *dd, DdNode *P, int var); +extern int cuddZddSymmCheck(DdManager *table, int x, int y); +extern int cuddZddSymmSifting(DdManager *table, int lower, int upper); +extern int cuddZddSymmSiftingConv(DdManager *table, int lower, int upper); +extern int cuddZddP(DdManager *zdd, DdNode *f); + +#ifdef __cplusplus +} /* end of extern "C" */ +#endif + +/** \endcond */ + +#endif /* CUDD_INT_H_ */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddInteract.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddInteract.c similarity index 59% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddInteract.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddInteract.c index fe32bb19e..0106fa467 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddInteract.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddInteract.c @@ -1,47 +1,33 @@ -/**CFile*********************************************************************** - - FileName [cuddInteract.c] - - PackageName [cudd] - - Synopsis [Functions to manipulate the variable interaction matrix.] - - Description [Internal procedures included in this file: - <ul> - <li> cuddSetInteract() - <li> cuddTestInteract() - <li> cuddInitInteract() - </ul> - Static procedures included in this file: - <ul> - <li> ddSuppInteract() - <li> ddClearLocal() - <li> ddUpdateInteract() - <li> ddClearGlobal() - </ul> - The interaction matrix tells whether two variables are - both in the support of some function of the DD. The main use of the +/** + @file + + @ingroup cudd + + @brief Functions to manipulate the variable interaction matrix. + + @details The interaction matrix tells whether two variables are both + in the support of some function of the %DD. The main use of the interaction matrix is in the in-place swapping. Indeed, if two - variables do not interact, there is no arc connecting the two layers; - therefore, the swap can be performed in constant time, without - scanning the subtables. Another use of the interaction matrix is in - the computation of the lower bounds for sifting. Finally, the - interaction matrix can be used to speed up aggregation checks in - symmetric and group sifting.<p> + variables do not interact, there is no arc connecting the two + layers; therefore, the swap can be performed in constant time, + without scanning the subtables. Another use of the interaction + matrix is in the computation of the lower bounds for + sifting. Finally, the interaction matrix can be used to speed up + aggregation checks in symmetric and group sifting.<p> The computation of the interaction matrix is done with a series of depth-first searches. The searches start from those nodes that have - only external references. The matrix is stored as a packed array of bits; - since it is symmetric, only the upper triangle is kept in memory. - As a final remark, we note that there may be variables that do - interact, but that for a given variable order have no arc connecting - their layers when they are adjacent. For instance, in ite(a,b,c) with - the order a<b<c, b and c interact, but are not connected.] + only external references. The matrix is stored as a packed array of + bits; since it is symmetric, only the upper triangle is kept in + memory. As a final remark, we note that there may be variables that + do interact, but that for a given variable order have no arc + connecting their layers when they are adjacent. For instance, in + ite(a,b,c) with the order a<b<c, b and c interact, but are not + connected. - SeeAlso [] + @author Fabio Somenzi - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -71,9 +57,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -82,7 +69,7 @@ /* Constant declarations */ /*---------------------------------------------------------------------------*/ -#if SIZEOF_LONG == 8 +#if SIZEOF_VOID_P == 8 #define BPL 64 #define LOGBPL 6 #else @@ -104,16 +91,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddInteract.c,v 1.14 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -124,7 +107,7 @@ static void ddClearLocal (DdNode *f); static void ddUpdateInteract (DdManager *table, char *support); static void ddClearGlobal (DdManager *table); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -137,25 +120,22 @@ static void ddClearGlobal (DdManager *table); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Set interaction matrix entries. - Synopsis [Set interaction matrix entries.] + @details Given a pair of variables 0 <= x < y < table->size, + sets the corresponding bit of the interaction matrix to 1. - Description [Given a pair of variables 0 <= x < y < table->size, - sets the corresponding bit of the interaction matrix to 1.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ void cuddSetInteract( DdManager * table, int x, int y) { - int posn, word, bit; + ptruint posn, word, bit; #ifdef DD_DEBUG assert(x < y); @@ -163,34 +143,32 @@ cuddSetInteract( assert(x >= 0); #endif - posn = ((((table->size << 1) - x - 3) * x) >> 1) + y - 1; + posn = (((((ptruint)table->size << 1) - x - 3) * x) >> 1) + y - 1; word = posn >> LOGBPL; bit = posn & (BPL-1); - table->interact[word] |= 1L << bit; + table->interact[word] |= ((ptruint) 1) << bit; } /* end of cuddSetInteract */ -/**Function******************************************************************** - - Synopsis [Test interaction matrix entries.] +/** + @brief Test interaction matrix entries. - Description [Given a pair of variables 0 <= x < y < table->size, + @details Given a pair of variables 0 <= x < y < table->size, tests whether the corresponding bit of the interaction matrix is 1. - Returns the value of the bit.] + Returns the value of the bit. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int cuddTestInteract( DdManager * table, int x, int y) { - int posn, word, bit, result; + ptruint posn, word, bit; + int result; if (x > y) { int tmp = x; @@ -203,57 +181,54 @@ cuddTestInteract( assert(x >= 0); #endif - posn = ((((table->size << 1) - x - 3) * x) >> 1) + y - 1; + posn = (((((ptruint)table->size << 1) - x - 3) * x) >> 1) + y - 1; word = posn >> LOGBPL; bit = posn & (BPL-1); - result = (table->interact[word] >> bit) & 1L; + result = (table->interact[word] >> bit) & (ptruint) 1; return(result); } /* end of cuddTestInteract */ -/**Function******************************************************************** - - Synopsis [Initializes the interaction matrix.] +/** + @brief Initializes the interaction matrix. - Description [Initializes the interaction matrix. The interaction - matrix is implemented as a bit vector storing the upper triangle of - the symmetric interaction matrix. The bit vector is kept in an array - of long integers. The computation is based on a series of depth-first - searches, one for each root of the DAG. Two flags are needed: The - local visited flag uses the LSB of the then pointer. The global - visited flag uses the LSB of the next pointer. - Returns 1 if successful; 0 otherwise.] + @details The interaction matrix is implemented as a bit vector + storing the upper triangle of the symmetric interaction matrix. The + bit vector is kept in an array of ptruints. The computation is based + on a series of depth-first searches, one for each root of the + DAG. Two flags are needed: The local visited flag uses the LSB of + the then pointer. The global visited flag uses the LSB of the next + pointer. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int cuddInitInteract( DdManager * table) { + unsigned int i; int j; - unsigned long i; - unsigned long words; - long *interact; + ptruint words; + ptruint *interact; char *support; DdNode *f; DdNode *sentinel = &(table->sentinel); DdNodePtr *nodelist; int slots; - unsigned long n; - n = (unsigned long) table->size; + ptruint n = (ptruint) table->size; words = ((n * (n-1)) >> (1 + LOGBPL)) + 1; - table->interact = interact = ALLOC(long,words); + table->interact = interact = ALLOC(ptruint,words); if (interact == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - return(0); + table->errorCode = CUDD_MEMORY_OUT; + return(0); } for (i = 0; i < words; i++) { - interact[i] = 0; + interact[i] = 0; } support = ALLOC(char,n); @@ -300,18 +275,15 @@ cuddInitInteract( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Find the support of f.] +/** + @brief Find the support of f. - Description [Performs a DFS from f. Uses the LSB of the then pointer - as visited flag.] + @details Performs a DFS from f. Uses the LSB of the then pointer + as visited flag. - SideEffects [Accumulates in support the variables on which f depends.] + @sideeffect Accumulates in support the variables on which f depends. - SeeAlso [] - -******************************************************************************/ +*/ static void ddSuppInteract( DdNode * f, @@ -332,17 +304,12 @@ ddSuppInteract( } /* end of ddSuppInteract */ -/**Function******************************************************************** - - Synopsis [Performs a DFS from f, clearing the LSB of the then pointers.] - - Description [] +/** + @brief Performs a DFS from f, clearing the LSB of the then pointers. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static void ddClearLocal( DdNode * f) @@ -359,19 +326,16 @@ ddClearLocal( } /* end of ddClearLocal */ -/**Function******************************************************************** - - Synopsis [Marks as interacting all pairs of variables that appear in - support.] +/** + @brief Marks as interacting all pairs of variables that appear in + support. - Description [If support[i] == support[j] == 1, sets the (i,j) entry + @details If support[i == support[j] == 1, sets the (i,j) entry of the interaction matrix to 1.] - SideEffects [Clears support.] - - SeeAlso [] + @sideeffect Clears support. -******************************************************************************/ +*/ static void ddUpdateInteract( DdManager * table, @@ -395,19 +359,16 @@ ddUpdateInteract( } /* end of ddUpdateInteract */ -/**Function******************************************************************** +/** + @brief Scans the %DD and clears the LSB of the next pointers. - Synopsis [Scans the DD and clears the LSB of the next pointers.] - - Description [The LSB of the next pointers are used as markers to tell + @details The LSB of the next pointers are used as markers to tell whether a node was reached by at least one DFS. Once the interaction - matrix is built, these flags are reset.] - - SideEffects [None] + matrix is built, these flags are reset. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static void ddClearGlobal( DdManager * table) diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddLCache.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddLCache.c similarity index 64% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddLCache.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddLCache.c index 63186e105..b439187bf 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddLCache.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddLCache.c @@ -1,47 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddLCache.c] - - PackageName [cudd] - - Synopsis [Functions for local caches.] - - Description [Internal procedures included in this module: - <ul> - <li> cuddLocalCacheInit() - <li> cuddLocalCacheQuit() - <li> cuddLocalCacheInsert() - <li> cuddLocalCacheLookup() - <li> cuddLocalCacheClearDead() - <li> cuddLocalCacheClearAll() - <li> cuddLocalCacheProfile() - <li> cuddHashTableInit() - <li> cuddHashTableQuit() - <li> cuddHashTableGenericQuit() - <li> cuddHashTableInsert() - <li> cuddHashTableLookup() - <li> cuddHashTableGenericInsert() - <li> cuddHashTableGenericLookup() - <li> cuddHashTableInsert2() - <li> cuddHashTableLookup2() - <li> cuddHashTableInsert3() - <li> cuddHashTableLookup3() - </ul> - Static procedures included in this module: - <ul> - <li> cuddLocalCacheResize() - <li> ddLCHash() - <li> cuddLocalCacheAddToList() - <li> cuddLocalCacheRemoveFromList() - <li> cuddHashTableResize() - <li> cuddHashTableAlloc() - </ul> ] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Functions for local caches. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -71,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -98,25 +66,19 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddLCache.c,v 1.27 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**Macro*********************************************************************** - - Synopsis [Computes hash function for keys of one operand.] +/** + @brief Computes hash function for keys of one operand. - Description [] + @sideeffect None - SideEffects [None] + @see ddLCHash3 ddLCHash - SeeAlso [ddLCHash3 ddLCHash] - -******************************************************************************/ +*/ #if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 #define ddLCHash1(f,shift) \ (((unsigned)(ptruint)(f) * DD_P1) >> (shift)) @@ -126,17 +88,14 @@ static char rcsid[] DD_UNUSED = "$Id: cuddLCache.c,v 1.27 2012/02/05 01:07:19 fa #endif -/**Macro*********************************************************************** - - Synopsis [Computes hash function for keys of two operands.] - - Description [] +/** + @brief Computes hash function for keys of two operands. - SideEffects [None] + @sideeffect None - SeeAlso [ddLCHash3 ddLCHash] + @see ddLCHash3 ddLCHash -******************************************************************************/ +*/ #if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 #define ddLCHash2(f,g,shift) \ ((((unsigned)(ptruint)(f) * DD_P1 + \ @@ -147,34 +106,31 @@ static char rcsid[] DD_UNUSED = "$Id: cuddLCache.c,v 1.27 2012/02/05 01:07:19 fa #endif -/**Macro*********************************************************************** - - Synopsis [Computes hash function for keys of three operands.] - - Description [] +/** + @brief Computes hash function for keys of three operands. - SideEffects [None] + @sideeffect None - SeeAlso [ddLCHash2 ddLCHash] + @see ddLCHash2 ddLCHash -******************************************************************************/ +*/ #define ddLCHash3(f,g,h,shift) ddCHash2(f,g,h,shift) -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ static void cuddLocalCacheResize (DdLocalCache *cache); -DD_INLINE static unsigned int ddLCHash (DdNodePtr *key, unsigned int keysize, int shift); +static unsigned int ddLCHash (DdNodePtr *key, unsigned int keysize, int shift); static void cuddLocalCacheAddToList (DdLocalCache *cache); static void cuddLocalCacheRemoveFromList (DdLocalCache *cache); static int cuddHashTableResize (DdHashTable *hash); -DD_INLINE static DdHashItem * cuddHashTableAlloc (DdHashTable *hash); +static DdHashItem * cuddHashTableAlloc (DdHashTable *hash); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -186,24 +142,23 @@ DD_INLINE static DdHashItem * cuddHashTableAlloc (DdHashTable *hash); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Initializes a local computed table. - Synopsis [Initializes a local computed table.] + @return a pointer the the new local cache in case of success; NULL + otherwise. - Description [Initializes a computed table. Returns a pointer the - the new local cache in case of success; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see cuddInitCache - SeeAlso [cuddInitCache] - -******************************************************************************/ +*/ DdLocalCache * cuddLocalCacheInit( - DdManager * manager /* manager */, - unsigned int keySize /* size of the key (number of operands) */, - unsigned int cacheSize /* Initial size of the cache */, - unsigned int maxCacheSize /* Size of the cache beyond which no resizing occurs */) + DdManager * manager /**< manager */, + unsigned int keySize /**< size of the key (number of operands) */, + unsigned int cacheSize /**< Initial size of the cache */, + unsigned int maxCacheSize /**< Size of the cache beyond which no resizing occurs */) { DdLocalCache *cache; int logSize; @@ -220,7 +175,7 @@ cuddLocalCacheInit( cache->itemsize += sizeof(ptrint); #endif logSize = cuddComputeFloorLog2(ddMax(cacheSize,manager->slots/2)); - cacheSize = 1 << logSize; + cacheSize = 1U << logSize; cache->item = (DdLocalCacheItem *) ALLOC(char, cacheSize * cache->itemsize); if (cache->item == NULL) { @@ -248,22 +203,17 @@ cuddLocalCacheInit( } /* end of cuddLocalCacheInit */ -/**Function******************************************************************** - - Synopsis [Shuts down a local computed table.] - - Description [Initializes the computed table. It is called by - Cudd_Init. Returns a pointer the the new local cache in case of - success; NULL otherwise.] +/** + @brief Shuts down a local computed table. - SideEffects [None] + @sideeffect None - SeeAlso [cuddLocalCacheInit] + @see cuddLocalCacheInit -******************************************************************************/ +*/ void cuddLocalCacheQuit( - DdLocalCache * cache /* cache to be shut down */) + DdLocalCache * cache /**< cache to be shut down */) { cache->manager->memused -= cache->slots * cache->itemsize + sizeof(DdLocalCache); @@ -276,17 +226,12 @@ cuddLocalCacheQuit( } /* end of cuddLocalCacheQuit */ -/**Function******************************************************************** - - Synopsis [Inserts a result in a local cache.] - - Description [] +/** + @brief Inserts a result in a local cache. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ void cuddLocalCacheInsert( DdLocalCache * cache, @@ -308,18 +253,14 @@ cuddLocalCacheInsert( } /* end of cuddLocalCacheInsert */ -/**Function******************************************************************** - - Synopsis [Looks up in a local cache.] - - Description [Looks up in a local cache. Returns the result if found; - it returns NULL if no result is found.] +/** + @brief Looks up in a local cache. - SideEffects [None] + @return the result if found; it returns NULL if no result is found. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * cuddLocalCacheLookup( DdLocalCache * cache, @@ -355,18 +296,14 @@ cuddLocalCacheLookup( } /* end of cuddLocalCacheLookup */ -/**Function******************************************************************** - - Synopsis [Clears the dead entries of the local caches of a manager.] - - Description [Clears the dead entries of the local caches of a manager. - Used during garbage collection.] +/** + @brief Clears the dead entries of the local caches of a manager. - SideEffects [None] + @details Used during garbage collection. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ void cuddLocalCacheClearDead( DdManager * manager) @@ -407,18 +344,14 @@ cuddLocalCacheClearDead( } /* end of cuddLocalCacheClearDead */ -/**Function******************************************************************** +/** + @brief Clears the local caches of a manager. - Synopsis [Clears the local caches of a manager.] + @details Used before reordering. - Description [Clears the local caches of a manager. - Used before reordering.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ void cuddLocalCacheClearAll( DdManager * manager) @@ -438,18 +371,14 @@ cuddLocalCacheClearAll( #define DD_HYSTO_BINS 8 -/**Function******************************************************************** - - Synopsis [Computes and prints a profile of a local cache usage.] +/** + @brief Computes and prints a profile of a local cache usage. - Description [Computes and prints a profile of a local cache usage. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int cuddLocalCacheProfile( DdLocalCache * cache) @@ -541,23 +470,26 @@ cuddLocalCacheProfile( #endif -/**Function******************************************************************** +/** + @brief Initializes a hash table. - Synopsis [Initializes a hash table.] + @details The table associates tuples of DdNode pointers to one DdNode pointer. + This type of table is used for functions that cannot (or prefer not to) use + the main computed table. The package also provides functions that allow the + caller to store arbitrary pointers in the table. - Description [Initializes a hash table. Returns a pointer to the new - table if successful; NULL otherwise.] + @return a pointer to the new table if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableQuit] + @see cuddHashTableQuit cuddHashTableGenericQuit -******************************************************************************/ +*/ DdHashTable * cuddHashTableInit( - DdManager * manager, - unsigned int keySize, - unsigned int initSize) + DdManager * manager /**< %DD manager */, + unsigned int keySize /**< number of pointers in the key */, + unsigned int initSize /**< initial size of the table */) { DdHashTable *hash; int logSize; @@ -576,7 +508,7 @@ cuddHashTableInit( /* We have to guarantee that the shift be < 32. */ if (initSize < 2) initSize = 2; logSize = cuddComputeFloorLog2(initSize); - hash->numBuckets = 1 << logSize; + hash->numBuckets = 1U << logSize; hash->shift = sizeof(int) * 8 - logSize; hash->bucket = ALLOC(DdHashItem *, hash->numBuckets); if (hash->bucket == NULL) { @@ -592,17 +524,16 @@ cuddHashTableInit( } /* end of cuddHashTableInit */ -/**Function******************************************************************** - - Synopsis [Shuts down a hash table.] +/** + @brief Shuts down a hash table. - Description [Shuts down a hash table, dereferencing all the values.] + @details Dereferences all the values. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableInit] + @see cuddHashTableInit -******************************************************************************/ +*/ void cuddHashTableQuit( DdHashTable * hash) @@ -636,26 +567,21 @@ cuddHashTableQuit( } /* end of cuddHashTableQuit */ -/**Function******************************************************************** +/** + @brief Shuts down a hash table. - Synopsis [Shuts down a hash table.] + @details Shuts down a hash table, when the values are not DdNode + pointers. - Description [Shuts down a hash table, when the values are not DdNode - pointers.] + @sideeffect None - SideEffects [None] + @see cuddHashTableInit - SeeAlso [cuddHashTableInit] - -******************************************************************************/ +*/ void cuddHashTableGenericQuit( DdHashTable * hash) { -#ifdef __osf__ -#pragma pointer_size save -#pragma pointer_size short -#endif DdHashItem **memlist, **nextmem; memlist = hash->memoryList; @@ -667,28 +593,26 @@ cuddHashTableGenericQuit( FREE(hash->bucket); FREE(hash); -#ifdef __osf__ -#pragma pointer_size restore -#endif return; } /* end of cuddHashTableGenericQuit */ -/**Function******************************************************************** +/** + @brief Inserts an item in a hash table. - Synopsis [Inserts an item in a hash table.] + @details Inserts an item in a hash table when the key has more than + three pointers. - Description [Inserts an item in a hash table when the key has more than - three pointers. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [[cuddHashTableInsert1 cuddHashTableInsert2 cuddHashTableInsert3 - cuddHashTableLookup] + @see [cuddHashTableInsert1 cuddHashTableInsert2 cuddHashTableInsert3 + cuddHashTableLookup -******************************************************************************/ +*/ int cuddHashTableInsert( DdHashTable * hash, @@ -727,23 +651,24 @@ cuddHashTableInsert( } /* end of cuddHashTableInsert */ -/**Function******************************************************************** +/** + @brief Looks up a key in a hash table. - Synopsis [Looks up a key in a hash table.] + @details Looks up a key consisting of more than three pointers in a + hash table. If the entry is present, its reference counter is + decremented if not saturated. If the counter reaches 0, the value of + the entry is dereferenced, and the entry is returned to the free + list. - Description [Looks up a key consisting of more than three pointers - in a hash table. Returns the value associated to the key if there - is an entry for the given key in the table; NULL otherwise. If the - entry is present, its reference counter is decremented if not - saturated. If the counter reaches 0, the value of the entry is - dereferenced, and the entry is returned to the free list.] + @return the value associated to the key if there is an entry for the + given key in the table; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableLookup1 cuddHashTableLookup2 cuddHashTableLookup3 - cuddHashTableInsert] + @see cuddHashTableLookup1 cuddHashTableLookup2 cuddHashTableLookup3 + cuddHashTableInsert -******************************************************************************/ +*/ DdNode * cuddHashTableLookup( DdHashTable * hash, @@ -795,19 +720,19 @@ cuddHashTableLookup( } /* end of cuddHashTableLookup */ -/**Function******************************************************************** +/** + @brief Inserts an item in a hash table. - Synopsis [Inserts an item in a hash table.] + @details Inserts an item in a hash table when the key is one pointer. - Description [Inserts an item in a hash table when the key is one pointer. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableInsert cuddHashTableInsert2 cuddHashTableInsert3 - cuddHashTableLookup1] + @see cuddHashTableInsert cuddHashTableInsert2 cuddHashTableInsert3 + cuddHashTableLookup1 -******************************************************************************/ +*/ int cuddHashTableInsert1( DdHashTable * hash, @@ -843,23 +768,23 @@ cuddHashTableInsert1( } /* end of cuddHashTableInsert1 */ -/**Function******************************************************************** +/** + @brief Looks up a key consisting of one pointer in a hash table. - Synopsis [Looks up a key consisting of one pointer in a hash table.] + @details If the entry is present, its reference count is + decremented if not saturated. If the counter reaches 0, the value of + the entry is dereferenced, and the entry is returned to the free + list. - Description [Looks up a key consisting of one pointer in a hash table. - Returns the value associated to the key if there is an entry for the given - key in the table; NULL otherwise. If the entry is present, its reference - counter is decremented if not saturated. If the counter reaches 0, the - value of the entry is dereferenced, and the entry is returned to the free - list.] + @return the value associated to the key if there is an entry for the + given key in the table; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableLookup cuddHashTableLookup2 cuddHashTableLookup3 - cuddHashTableInsert1] + @see cuddHashTableLookup cuddHashTableLookup2 cuddHashTableLookup3 + cuddHashTableInsert1 -******************************************************************************/ +*/ DdNode * cuddHashTableLookup1( DdHashTable * hash, @@ -902,19 +827,21 @@ cuddHashTableLookup1( } /* end of cuddHashTableLookup1 */ -/**Function******************************************************************** +/** + @brief Inserts a generic item in a hash table. - Synopsis [Inserts an item in a hash table.] + @details Inserts an item in a hash table when the key is one + pointer and the value is not a DdNode pointer. The main difference w.r.t. + cuddHashTableInsert1 is that the reference count of the value is not + incremented. - Description [Inserts an item in a hash table when the key is one - pointer and the value is not a DdNode pointer. Returns 1 if - successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableInsert1 cuddHashTableGenericLookup] + @see cuddHashTableInsert1 cuddHashTableGenericLookup -******************************************************************************/ +*/ int cuddHashTableGenericInsert( DdHashTable * hash, @@ -948,20 +875,20 @@ cuddHashTableGenericInsert( } /* end of cuddHashTableGenericInsert */ -/**Function******************************************************************** +/** + @brief Looks up a key consisting of one pointer in a hash table. - Synopsis [Looks up a key consisting of one pointer in a hash table.] + @details Looks up a key consisting of one pointer in a hash + table when the value is not a DdNode pointer. - Description [Looks up a key consisting of one pointer in a hash - table when the value is not a DdNode pointer. Returns the value - associated to the key if there is an entry for the given key in the - table; NULL otherwise.] + @return the value associated to the key if there is an entry for the + given key in the table; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableLookup1 cuddHashTableGenericInsert] + @see cuddHashTableLookup1 cuddHashTableGenericInsert -******************************************************************************/ +*/ void * cuddHashTableGenericLookup( DdHashTable * hash, @@ -988,19 +915,20 @@ cuddHashTableGenericLookup( } /* end of cuddHashTableGenericLookup */ -/**Function******************************************************************** +/** + @brief Inserts an item in a hash table. - Synopsis [Inserts an item in a hash table.] + @details Inserts an item in a hash table when the key is + composed of two pointers. - Description [Inserts an item in a hash table when the key is - composed of two pointers. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableInsert cuddHashTableInsert1 cuddHashTableInsert3 - cuddHashTableLookup2] + @see cuddHashTableInsert cuddHashTableInsert1 cuddHashTableInsert3 + cuddHashTableLookup2 -******************************************************************************/ +*/ int cuddHashTableInsert2( DdHashTable * hash, @@ -1038,23 +966,23 @@ cuddHashTableInsert2( } /* end of cuddHashTableInsert2 */ -/**Function******************************************************************** +/** + @brief Looks up a key consisting of two pointers in a hash table. - Synopsis [Looks up a key consisting of two pointers in a hash table.] + @details If the entry is present, its reference counter is + decremented if not saturated. If the counter reaches 0, the value of + the entry is dereferenced, and the entry is returned to the free + list. - Description [Looks up a key consisting of two pointer in a hash table. - Returns the value associated to the key if there is an entry for the given - key in the table; NULL otherwise. If the entry is present, its reference - counter is decremented if not saturated. If the counter reaches 0, the - value of the entry is dereferenced, and the entry is returned to the free - list.] + @return the value associated to the key if there is an entry for the + given key in the table; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableLookup cuddHashTableLookup1 cuddHashTableLookup3 - cuddHashTableInsert2] + @see cuddHashTableLookup cuddHashTableLookup1 cuddHashTableLookup3 + cuddHashTableInsert2 -******************************************************************************/ +*/ DdNode * cuddHashTableLookup2( DdHashTable * hash, @@ -1098,19 +1026,20 @@ cuddHashTableLookup2( } /* end of cuddHashTableLookup2 */ -/**Function******************************************************************** +/** + @brief Inserts an item in a hash table. - Synopsis [Inserts an item in a hash table.] + @details Inserts an item in a hash table when the key is + composed of three pointers. - Description [Inserts an item in a hash table when the key is - composed of three pointers. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableInsert cuddHashTableInsert1 cuddHashTableInsert2 - cuddHashTableLookup3] + @see cuddHashTableInsert cuddHashTableInsert1 cuddHashTableInsert2 + cuddHashTableLookup3 -******************************************************************************/ +*/ int cuddHashTableInsert3( DdHashTable * hash, @@ -1150,23 +1079,23 @@ cuddHashTableInsert3( } /* end of cuddHashTableInsert3 */ -/**Function******************************************************************** +/** + @brief Looks up a key consisting of three pointers in a hash table. - Synopsis [Looks up a key consisting of three pointers in a hash table.] + @details If the entry is present, its reference counter is + decremented if not saturated. If the counter reaches 0, the value of + the entry is dereferenced, and the entry is returned to the free + list. - Description [Looks up a key consisting of three pointers in a hash table. - Returns the value associated to the key if there is an entry for the given - key in the table; NULL otherwise. If the entry is present, its reference - counter is decremented if not saturated. If the counter reaches 0, the - value of the entry is dereferenced, and the entry is returned to the free - list.] + @return the value associated to the key if there is an entry for the + given key in the table; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableLookup cuddHashTableLookup1 cuddHashTableLookup2 - cuddHashTableInsert3] + @see cuddHashTableLookup cuddHashTableLookup1 cuddHashTableLookup2 + cuddHashTableInsert3 -******************************************************************************/ +*/ DdNode * cuddHashTableLookup3( DdHashTable * hash, @@ -1216,17 +1145,12 @@ cuddHashTableLookup3( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Resizes a local cache.] - - Description [] +/** + @brief Resizes a local cache. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static void cuddLocalCacheResize( DdLocalCache * cache) @@ -1252,7 +1176,7 @@ cuddLocalCacheResize( #endif saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = cache->manager->outOfMemCallback; cache->item = item = (DdLocalCacheItem *) ALLOC(char, slots * cache->itemsize); MMoutOfMemory = saveHandler; @@ -1296,19 +1220,14 @@ cuddLocalCacheResize( } /* end of cuddLocalCacheResize */ -/**Function******************************************************************** - - Synopsis [Computes the hash value for a local cache.] - - Description [Computes the hash value for a local cache. Returns the - bucket index.] +/** + @brief Computes the hash value for a local cache. - SideEffects [None] + @return the bucket index. - SeeAlso [] + @sideeffect None -******************************************************************************/ -DD_INLINE +*/ static unsigned int ddLCHash( DdNodePtr * key, @@ -1327,17 +1246,12 @@ ddLCHash( } /* end of ddLCHash */ -/**Function******************************************************************** - - Synopsis [Inserts a local cache in the manager list.] - - Description [] +/** + @brief Inserts a local cache in the manager list. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static void cuddLocalCacheAddToList( DdLocalCache * cache) @@ -1351,17 +1265,12 @@ cuddLocalCacheAddToList( } /* end of cuddLocalCacheAddToList */ -/**Function******************************************************************** - - Synopsis [Removes a local cache from the manager list.] - - Description [] +/** + @brief Removes a local cache from the manager list. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static void cuddLocalCacheRemoveFromList( DdLocalCache * cache) @@ -1385,18 +1294,16 @@ cuddLocalCacheRemoveFromList( } /* end of cuddLocalCacheRemoveFromList */ -/**Function******************************************************************** - - Synopsis [Resizes a hash table.] +/** + @brief Resizes a hash table. - Description [Resizes a hash table. Returns 1 if successful; 0 - otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddHashTableInsert] + @see cuddHashTableInsert -******************************************************************************/ +*/ static int cuddHashTableResize( DdHashTable * hash) @@ -1417,7 +1324,7 @@ cuddHashTableResize( /* Compute the new size of the table. */ numBuckets = oldNumBuckets << 1; saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = hash->manager->outOfMemCallback; buckets = ALLOC(DdHashItem *, numBuckets); MMoutOfMemory = saveHandler; if (buckets == NULL) { @@ -1484,21 +1391,19 @@ cuddHashTableResize( } /* end of cuddHashTableResize */ -/**Function******************************************************************** +/** + @brief Fast storage allocation for items in a hash table. - Synopsis [Fast storage allocation for items in a hash table.] + @details The first sizeof(void *) bytes of a chunk contain a pointer to the + next block; the rest contains DD_MEM_CHUNK spaces for hash items. - Description [Fast storage allocation for items in a hash table. The - first 4 bytes of a chunk contain a pointer to the next block; the - rest contains DD_MEM_CHUNK spaces for hash items. Returns a pointer to - a new item if successful; NULL is memory is full.] + @return a pointer to a new item if successful; NULL is memory is full. - SideEffects [None] + @sideeffect None - SeeAlso [cuddAllocNode cuddDynamicAllocNode] + @see cuddAllocNode cuddDynamicAllocNode -******************************************************************************/ -DD_INLINE +*/ static DdHashItem * cuddHashTableAlloc( DdHashTable * hash) @@ -1511,7 +1416,7 @@ cuddHashTableAlloc( if (hash->nextFree == NULL) { saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = hash->manager->outOfMemCallback; mem = (DdHashItem **) ALLOC(char,(DD_MEM_CHUNK+1) * itemsize); MMoutOfMemory = saveHandler; if (mem == NULL) { @@ -1530,7 +1435,7 @@ cuddHashTableAlloc( mem = (DdHashItem **) ALLOC(char,(DD_MEM_CHUNK+1) * itemsize); } if (mem == NULL) { - (*MMoutOfMemory)((long)((DD_MEM_CHUNK + 1) * itemsize)); + (*MMoutOfMemory)((size_t)((DD_MEM_CHUNK + 1) * itemsize)); hash->manager->errorCode = CUDD_MEMORY_OUT; return(NULL); } diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddLevelQ.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddLevelQ.c similarity index 66% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddLevelQ.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddLevelQ.c index 34f32c5b8..de40c8271 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddLevelQ.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddLevelQ.c @@ -1,13 +1,12 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddLevelQ.c] + @ingroup cudd - PackageName [cudd] + @brief Procedure to manage level queues. - Synopsis [Procedure to manage level queues.] - - Description [The functions in this file allow an application to - easily manipulate a queue where nodes are prioritized by level. The + @details The functions in this file allow an application to easily + manipulate a queue where nodes are prioritized by level. The emphasis is on efficiency. Therefore, the queue items can have variable size. If the application does not need to attach information to the nodes, it can declare the queue items to be of @@ -22,28 +21,11 @@ appears at most once in the queue. They do so by keeping a hash table where the node is used as key. Queue items are recycled via a free list for efficiency. - - Internal procedures provided by this module: - <ul> - <li> cuddLevelQueueInit() - <li> cuddLevelQueueQuit() - <li> cuddLevelQueueEnqueue() - <li> cuddLevelQueueDequeue() - </ul> - Static procedures included in this module: - <ul> - <li> hashLookup() - <li> hashInsert() - <li> hashDelete() - <li> hashResize() - </ul> - ] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -73,9 +55,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -99,26 +82,20 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddLevelQ.c,v 1.16 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**Macro*********************************************************************** +/** + @brief Hash function for the table of a level queue. - Synopsis [Hash function for the table of a level queue.] + @sideeffect None - Description [Hash function for the table of a level queue.] + @see hashInsert hashLookup hashDelete - SideEffects [None] - - SeeAlso [hashInsert hashLookup hashDelete] - -******************************************************************************/ +*/ #if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 #define lqHash(key,shift) \ (((unsigned)(ptruint)(key) * DD_P1) >> (shift)) @@ -128,7 +105,7 @@ static char rcsid[] DD_UNUSED = "$Id: cuddLevelQ.c,v 1.16 2012/02/05 01:07:19 fa #endif -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -139,7 +116,7 @@ static int hashInsert(DdLevelQueue *queue, DdQueueItem *item); static void hashDelete(DdLevelQueue *queue, DdQueueItem *item); static int hashResize(DdLevelQueue *queue); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -147,27 +124,27 @@ static int hashResize(DdLevelQueue *queue); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Initializes a level queue. - Synopsis [Initializes a level queue.] + @details A level queue is a queue where inserts are based on the + levels of the nodes. Within each level the policy is FIFO. Level + queues are useful in traversing a %BDD top-down. Queue items are kept + in a free list when dequeued for efficiency. - Description [Initializes a level queue. A level queue is a queue - where inserts are based on the levels of the nodes. Within each - level the policy is FIFO. Level queues are useful in traversing a - BDD top-down. Queue items are kept in a free list when dequeued for - efficiency. Returns a pointer to the new queue if successful; NULL - otherwise.] + @return a pointer to the new queue if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddLevelQueueQuit cuddLevelQueueEnqueue cuddLevelQueueDequeue] + @see cuddLevelQueueQuit cuddLevelQueueEnqueue cuddLevelQueueDequeue -******************************************************************************/ +*/ DdLevelQueue * cuddLevelQueueInit( - int levels /* number of levels */, - int itemSize /* size of the item */, - int numBuckets /* initial number of hash buckets */) + int levels /**< number of levels */, + int itemSize /**< size of the item */, + int numBuckets /**< initial number of hash buckets */, + DdManager * manager /*<< DD manager */) { DdLevelQueue *queue; int logSize; @@ -184,7 +161,7 @@ cuddLevelQueueInit( /* Use a hash table to test for uniqueness. */ if (numBuckets < 2) numBuckets = 2; logSize = cuddComputeFloorLog2(numBuckets); - queue->numBuckets = 1 << logSize; + queue->numBuckets = 1U << logSize; queue->shift = sizeof(int) * 8 - logSize; queue->buckets = ALLOC(DdQueueItem *, queue->numBuckets); if (queue->buckets == NULL) { @@ -200,23 +177,22 @@ cuddLevelQueueInit( queue->itemsize = itemSize; queue->size = 0; queue->maxsize = queue->numBuckets * DD_MAX_SUBTABLE_DENSITY; + queue->manager = manager; return(queue); } /* end of cuddLevelQueueInit */ -/**Function******************************************************************** - - Synopsis [Shuts down a level queue.] +/** + @brief Shuts down a level queue. - Description [Shuts down a level queue and releases all the - associated memory.] + @details Releases all the associated memory. - SideEffects [None] + @sideeffect None - SeeAlso [cuddLevelQueueInit] + @see cuddLevelQueueInit -******************************************************************************/ +*/ void cuddLevelQueueQuit( DdLevelQueue * queue) @@ -241,25 +217,24 @@ cuddLevelQueueQuit( } /* end of cuddLevelQueueQuit */ -/**Function******************************************************************** +/** + @brief Inserts a new key in a level queue. - Synopsis [Inserts a new key in a level queue.] + @details A new entry is created in the queue only if the node is not + already enqueued. - Description [Inserts a new key in a level queue. A new entry is - created in the queue only if the node is not already - enqueued. Returns a pointer to the queue item if successful; NULL - otherwise.] + @return a pointer to the queue item if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddLevelQueueInit cuddLevelQueueDequeue] + @see cuddLevelQueueInit cuddLevelQueueDequeue -******************************************************************************/ +*/ void * cuddLevelQueueEnqueue( - DdLevelQueue * queue /* level queue */, - void * key /* key to be enqueued */, - int level /* level at which to insert */) + DdLevelQueue * queue /**< level queue */, + void * key /**< key to be enqueued */, + int level /**< level at which to insert */) { DdQueueItem *item; @@ -315,23 +290,21 @@ cuddLevelQueueEnqueue( } /* end of cuddLevelQueueEnqueue */ -/**Function******************************************************************** +/** + @brief Inserts the first key in a level queue. - Synopsis [Inserts the first key in a level queue.] + @return a pointer to the queue item if successful; NULL otherwise. - Description [Inserts the first key in a level queue. Returns a - pointer to the queue item if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see cuddLevelQueueEnqueue - SeeAlso [cuddLevelQueueEnqueue] - -******************************************************************************/ +*/ void * cuddLevelQueueFirst( - DdLevelQueue * queue /* level queue */, - void * key /* key to be enqueued */, - int level /* level at which to insert */) + DdLevelQueue * queue /**< level queue */, + void * key /**< key to be enqueued */, + int level /**< level at which to insert */) { DdQueueItem *item; @@ -370,17 +343,14 @@ cuddLevelQueueFirst( } /* end of cuddLevelQueueFirst */ -/**Function******************************************************************** - - Synopsis [Remove an item from the front of a level queue.] - - Description [Remove an item from the front of a level queue.] +/** + @brief Remove an item from the front of a level queue. - SideEffects [None] + @sideeffect None - SeeAlso [cuddLevelQueueEnqueue] + @see cuddLevelQueueEnqueue -******************************************************************************/ +*/ void cuddLevelQueueDequeue( DdLevelQueue * queue, @@ -413,19 +383,17 @@ cuddLevelQueueDequeue( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Looks up a key in the hash table of a level queue. - Synopsis [Looks up a key in the hash table of a level queue.] + @return a pointer to the item with the given key if the key is + found; NULL otherwise. - Description [Looks up a key in the hash table of a level queue. Returns - a pointer to the item with the given key if the key is found; NULL - otherwise.] + @sideeffect None - SideEffects [None] + @see cuddLevelQueueEnqueue hashInsert - SeeAlso [cuddLevelQueueEnqueue hashInsert] - -******************************************************************************/ +*/ static DdQueueItem * hashLookup( DdLevelQueue * queue, @@ -448,19 +416,19 @@ hashLookup( } /* end of hashLookup */ -/**Function******************************************************************** +/** + @brief Inserts an item in the hash table of a level queue. - Synopsis [Inserts an item in the hash table of a level queue.] + @details No check is performed to see if an item with the same key + is already in the hash table. - Description [Inserts an item in the hash table of a level queue. Returns - 1 if successful; 0 otherwise. No check is performed to see if an item with - the same key is already in the hash table.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddLevelQueueEnqueue] + @see cuddLevelQueueEnqueue -******************************************************************************/ +*/ static int hashInsert( DdLevelQueue * queue, @@ -483,18 +451,16 @@ hashInsert( } /* end of hashInsert */ -/**Function******************************************************************** - - Synopsis [Removes an item from the hash table of a level queue.] +/** + @brief Removes an item from the hash table of a level queue. - Description [Removes an item from the hash table of a level queue. - Nothing is done if the item is not in the table.] + @details Nothing is done if the item is not in the table. - SideEffects [None] + @sideeffect None - SeeAlso [cuddLevelQueueDequeue hashInsert] + @see cuddLevelQueueDequeue hashInsert -******************************************************************************/ +*/ static void hashDelete( DdLevelQueue * queue, @@ -524,18 +490,16 @@ hashDelete( } /* end of hashDelete */ -/**Function******************************************************************** - - Synopsis [Resizes the hash table of a level queue.] +/** + @brief Resizes the hash table of a level queue. - Description [Resizes the hash table of a level queue. Returns 1 if - successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [hashInsert] + @see hashInsert -******************************************************************************/ +*/ static int hashResize( DdLevelQueue * queue) @@ -555,7 +519,7 @@ hashResize( /* Compute the new size of the subtable. */ numBuckets = oldNumBuckets << 1; saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = queue->manager->outOfMemCallback; buckets = queue->buckets = ALLOC(DdQueueItem *, numBuckets); MMoutOfMemory = saveHandler; if (buckets == NULL) { diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddLinear.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddLinear.c similarity index 75% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddLinear.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddLinear.c index 437830ecd..adbb1e343 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddLinear.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddLinear.c @@ -1,33 +1,15 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddLinear.c] + @ingroup cudd - PackageName [cudd] + @brief Functions for %BDD and %ADD reduction by linear + transformations. - Synopsis [Functions for DD reduction by linear transformations.] + @author Fabio Somenzi - Description [ Internal procedures included in this module: - <ul> - <li> cuddLinearAndSifting() - <li> cuddLinearInPlace() - <li> cuddUpdateInteractionMatrix() - <li> cuddInitLinear() - <li> cuddResizeLinear() - </ul> - Static procedures included in this module: - <ul> - <li> ddLinearUniqueCompare() - <li> ddLinearAndSiftingAux() - <li> ddLinearAndSiftingUp() - <li> ddLinearAndSiftingDown() - <li> ddLinearAndSiftingBackward() - <li> ddUndoMoves() - <li> cuddXorLinear() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -57,13 +39,13 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" -#include "ucbqsort.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ @@ -72,7 +54,7 @@ #define CUDD_SWAP_MOVE 0 #define CUDD_LINEAR_TRANSFORM_MOVE 1 #define CUDD_INVERSE_TRANSFORM_MOVE 2 -#if SIZEOF_LONG == 8 +#if SIZEOF_VOID_P == 8 #define BPL 64 #define LOGBPL 6 #else @@ -92,33 +74,17 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddLinear.c,v 1.29 2012/02/05 01:07:19 fabio Exp $"; -#endif - -static int *entry; - -#ifdef DD_STATS -extern int ddTotalNumberSwapping; -extern int ddTotalNISwaps; -static int ddTotalNumberLinearTr; -#endif - -#ifdef DD_DEBUG -static int zero = 0; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ -static int ddLinearUniqueCompare (int *ptrX, int *ptrY); +static int ddLinearUniqueCompare (void const *ptrX, void const *ptrY); static int ddLinearAndSiftingAux (DdManager *table, int x, int xLow, int xHigh); static Move * ddLinearAndSiftingUp (DdManager *table, int y, int xLow, Move *prevMoves); static Move * ddLinearAndSiftingDown (DdManager *table, int x, int xHigh, Move *prevMoves); @@ -126,7 +92,7 @@ static int ddLinearAndSiftingBackward (DdManager *table, int size, Move *moves); static Move* ddUndoMoves (DdManager *table, Move *moves); static void cuddXorLinear (DdManager *table, int x, int y); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -134,18 +100,14 @@ static void cuddXorLinear (DdManager *table, int x, int y); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Prints the linear transform matrix.] +/** + @brief Prints the linear transform matrix. - Description [Prints the linear transform matrix. Returns 1 in case of - success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [none] + @sideeffect none - SeeAlso [] - -******************************************************************************/ +*/ int Cudd_PrintLinear( DdManager * table) @@ -154,13 +116,13 @@ Cudd_PrintLinear( int retval; int nvars = table->linearSize; int wordsPerRow = ((nvars - 1) >> LOGBPL) + 1; - long word; + ptruint word; for (i = 0; i < nvars; i++) { for (j = 0; j < wordsPerRow; j++) { word = table->linear[i*wordsPerRow + j]; for (k = 0; k < BPL; k++) { - retval = fprintf(table->out,"%ld",word & 1); + retval = fprintf(table->out,"%" PRIuPTR,word & (ptruint) 1); if (retval == 0) return(0); word >>= 1; } @@ -173,34 +135,29 @@ Cudd_PrintLinear( } /* end of Cudd_PrintLinear */ -/**Function******************************************************************** - - Synopsis [Reads an entry of the linear transform matrix.] +/** + @brief Reads an entry of the linear transform matrix. - Description [Reads an entry of the linear transform matrix.] + @sideeffect none - SideEffects [none] - - SeeAlso [] - -******************************************************************************/ +*/ int Cudd_ReadLinear( - DdManager * table /* CUDD manager */, - int x /* row index */, - int y /* column index */) + DdManager * table /**< CUDD manager */, + int x /**< row index */, + int y /**< column index */) { int nvars = table->size; - int wordsPerRow = ((nvars - 1) >> LOGBPL) + 1; - long word; + ptruint wordsPerRow = ((ptruint)(nvars - 1) >> LOGBPL) + 1; + ptruint word; int bit; int result; assert(table->size == table->linearSize); - word = wordsPerRow * x + (y >> LOGBPL); + word = wordsPerRow * (ptruint) x + ((ptruint) y >> LOGBPL); bit = y & (BPL-1); - result = (int) ((table->linear[word] >> bit) & 1); + result = (int) ((table->linear[word] >> bit) & (ptruint) 1); return(result); } /* end of Cudd_ReadLinear */ @@ -211,28 +168,27 @@ Cudd_ReadLinear( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [BDD reduction based on combination of sifting and linear - transformations.] +/** + @brief %BDD reduction based on combination of sifting and linear + transformations. - Description [BDD reduction based on combination of sifting and linear - transformations. Assumes that no dead nodes are present. + @details Assumes that no dead nodes are present. <ol> <li> Order all the variables according to the number of entries in each unique table. <li> Sift the variable up and down, remembering each time the - total size of the DD heap. At each position, linear transformation + total size of the %DD heap. At each position, linear transformation of the two adjacent variables is tried and is accepted if it reduces - the size of the DD. + the size of the %DD. <li> Select the best permutation. <li> Repeat 3 and 4 for all variables. </ol> - Returns 1 if successful; 0 otherwise.] - SideEffects [None] + @return 1 if successful; 0 otherwise. -******************************************************************************/ + @sideeffect None + +*/ int cuddLinearAndSifting( DdManager * table, @@ -240,7 +196,7 @@ cuddLinearAndSifting( int upper) { int i; - int *var; + IndexKey *var; int size; int x; int result; @@ -249,13 +205,12 @@ cuddLinearAndSifting( #endif #ifdef DD_STATS - ddTotalNumberLinearTr = 0; + table->totalNumberLinearTr = 0; #endif size = table->size; var = NULL; - entry = NULL; if (table->linear == NULL) { result = cuddInitLinear(table); if (result == 0) goto cuddLinearAndSiftingOutOfMem; @@ -275,12 +230,7 @@ cuddLinearAndSifting( } /* Find order in which to sift variables. */ - entry = ALLOC(int,size); - if (entry == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - goto cuddLinearAndSiftingOutOfMem; - } - var = ALLOC(int,size); + var = ALLOC(IndexKey,size); if (var == NULL) { table->errorCode = CUDD_MEMORY_OUT; goto cuddLinearAndSiftingOutOfMem; @@ -288,18 +238,18 @@ cuddLinearAndSifting( for (i = 0; i < size; i++) { x = table->perm[i]; - entry[i] = table->subtables[x].keys; - var[i] = i; + var[i].index = i; + var[i].keys = table->subtables[x].keys; } - cudd__qsort((void *)var,size,sizeof(int),(DD_QSFP)ddLinearUniqueCompare); + util_qsort(var,size,sizeof(IndexKey),ddLinearUniqueCompare); /* Now sift. */ for (i = 0; i < ddMin(table->siftMaxVar,size); i++) { - x = table->perm[var[i]]; + x = table->perm[var[i].index]; if (x < lower || x > upper) continue; #ifdef DD_STATS - previousSize = table->keys - table->isolated; + previousSize = (int) (table->keys - table->isolated); #endif result = ddLinearAndSiftingAux(table,x,lower,upper); if (!result) goto cuddLinearAndSiftingOutOfMem; @@ -308,7 +258,7 @@ cuddLinearAndSifting( (void) fprintf(table->out,"-"); } else if (table->keys > (unsigned) previousSize + table->isolated) { (void) fprintf(table->out,"+"); /* should never happen */ - (void) fprintf(table->out,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keys - table->isolated, var[i]); + (void) fprintf(table->out,"\nSize increased from %d to %u while sifting variable %d\n", previousSize, table->keys - table->isolated, var[i].index); } else { (void) fprintf(table->out,"="); } @@ -320,18 +270,16 @@ cuddLinearAndSifting( } FREE(var); - FREE(entry); #ifdef DD_STATS (void) fprintf(table->out,"\n#:L_LINSIFT %8d: linear trans.", - ddTotalNumberLinearTr); + table->totalNumberLinearTr); #endif return(1); cuddLinearAndSiftingOutOfMem: - if (entry != NULL) FREE(entry); if (var != NULL) FREE(var); return(0); @@ -339,24 +287,23 @@ cuddLinearAndSiftingOutOfMem: } /* end of cuddLinearAndSifting */ -/**Function******************************************************************** +/** + @brief Linearly combines two adjacent variables. - Synopsis [Linearly combines two adjacent variables.] + @details Specifically, replaces the top variable with the exclusive + nor of the two variables. It assumes that no dead nodes are present + on entry to this procedure. The procedure then guarantees that no + dead nodes will be present when it terminates. cuddLinearInPlace + assumes that x < y. - Description [Linearly combines two adjacent variables. Specifically, - replaces the top variable with the exclusive nor of the two variables. - It assumes that no dead nodes are present on entry to this - procedure. The procedure then guarantees that no dead nodes will be - present when it terminates. cuddLinearInPlace assumes that x < - y. Returns the number of keys in the table if successful; 0 - otherwise.] + @return the number of keys in the table if successful; 0 otherwise. - SideEffects [The two subtables corrresponding to variables x and y are - modified. The global counters of the unique table are also affected.] + @sideeffect The two subtables corrresponding to variables x and y are + modified. The global counters of the unique table are also affected. - SeeAlso [cuddSwapInPlace] + @see cuddSwapInPlace -******************************************************************************/ +*/ int cuddLinearInPlace( DdManager * table, @@ -367,14 +314,17 @@ cuddLinearInPlace( int xindex, yindex; int xslots, yslots; int xshift, yshift; - int oldxkeys, oldykeys; +#if defined(DD_COUNT) || defined(DD_DEBUG) + int oldxkeys; +#endif + int oldykeys; int newxkeys, newykeys; int comple, newcomplement; int i; int posn; int isolated; DdNode *f,*f0,*f1,*f01,*f00,*f11,*f10,*newf1,*newf0; - DdNode *g,*next,*last; + DdNode *g,*next,*last=NULL; DdNodePtr *previousP; DdNode *tmp; DdNode *sentinel = &(table->sentinel); @@ -396,11 +346,13 @@ cuddLinearInPlace( if (cuddTestInteract(table,xindex,yindex)) { #ifdef DD_STATS - ddTotalNumberLinearTr++; + table->totalNumberLinearTr++; #endif /* Get parameters of x subtable. */ xlist = table->subtables[x].nodelist; +#if defined(DD_COUNT) || defined(DD_DEBUG) oldxkeys = table->subtables[x].keys; +#endif xslots = table->subtables[x].slots; xshift = table->subtables[x].shift; @@ -669,7 +621,7 @@ cuddLinearInPlace( isolated += (table->vars[xindex]->ref == 1) + (table->vars[yindex]->ref == 1); - table->isolated += isolated; + table->isolated += (unsigned int) isolated; /* Set the appropriate fields in table. */ table->subtables[y].keys = newykeys; @@ -685,12 +637,12 @@ cuddLinearInPlace( } #ifdef DD_DEBUG - if (zero) { + if (table->enableExtraDebug) { (void) Cudd_DebugCheck(table); } #endif - return(table->keys - table->isolated); + return((int) (table->keys - table->isolated)); cuddLinearOutOfMem: (void) fprintf(table->err,"Error: cuddLinearInPlace out of memory\n"); @@ -700,17 +652,12 @@ cuddLinearOutOfMem: } /* end of cuddLinearInPlace */ -/**Function******************************************************************** - - Synopsis [Updates the interaction matrix.] - - Description [] - - SideEffects [none] +/** + @brief Updates the interaction matrix. - SeeAlso [] + @sideeffect none -******************************************************************************/ +*/ void cuddUpdateInteractionMatrix( DdManager * table, @@ -740,18 +687,14 @@ cuddUpdateInteractionMatrix( } /* end of cuddUpdateInteractionMatrix */ -/**Function******************************************************************** +/** + @brief Initializes the linear transform matrix. - Synopsis [Initializes the linear transform matrix.] + @return 1 if successful; 0 otherwise. - Description [Initializes the linear transform matrix. Returns 1 if - successful; 0 otherwise.] + @sideeffect none - SideEffects [none] - - SeeAlso [] - -******************************************************************************/ +*/ int cuddInitLinear( DdManager * table) @@ -762,41 +705,37 @@ cuddInitLinear( int word; int bit; int i; - long *linear; + ptruint *linear; nvars = table->size; wordsPerRow = ((nvars - 1) >> LOGBPL) + 1; words = wordsPerRow * nvars; - table->linear = linear = ALLOC(long,words); + table->linear = linear = ALLOC(ptruint,words); if (linear == NULL) { table->errorCode = CUDD_MEMORY_OUT; return(0); } - table->memused += words * sizeof(long); + table->memused += words * sizeof(ptruint); table->linearSize = nvars; for (i = 0; i < words; i++) linear[i] = 0; for (i = 0; i < nvars; i++) { word = wordsPerRow * i + (i >> LOGBPL); bit = i & (BPL-1); - linear[word] = 1 << bit; + linear[word] = (ptruint) 1 << bit; } return(1); } /* end of cuddInitLinear */ -/**Function******************************************************************** - - Synopsis [Resizes the linear transform matrix.] +/** + @brief Resizes the linear transform matrix. - Description [Resizes the linear transform matrix. Returns 1 if - successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [none] + @sideeffect none - SeeAlso [] - -******************************************************************************/ +*/ int cuddResizeLinear( DdManager * table) @@ -807,7 +746,7 @@ cuddResizeLinear( int word,oldWord; int bit; int i,j; - long *linear,*oldLinear; + ptruint *linear,*oldLinear; oldNvars = table->linearSize; oldWordsPerRow = ((oldNvars - 1) >> LOGBPL) + 1; @@ -817,12 +756,12 @@ cuddResizeLinear( nvars = table->size; wordsPerRow = ((nvars - 1) >> LOGBPL) + 1; words = wordsPerRow * nvars; - table->linear = linear = ALLOC(long,words); + table->linear = linear = ALLOC(ptruint,words); if (linear == NULL) { table->errorCode = CUDD_MEMORY_OUT; return(0); } - table->memused += (words - oldWords) * sizeof(long); + table->memused += (words - oldWords) * sizeof(ptruint); for (i = 0; i < words; i++) linear[i] = 0; /* Copy old matrix. */ @@ -839,7 +778,7 @@ cuddResizeLinear( for (i = oldNvars; i < nvars; i++) { word = wordsPerRow * i + (i >> LOGBPL); bit = i & (BPL-1); - linear[word] = 1 << bit; + linear[word] = (ptruint) 1 << bit; } table->linearSize = nvars; @@ -853,46 +792,48 @@ cuddResizeLinear( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Comparison function used by qsort.] +/** + @brief Comparison function used by qsort. - Description [Comparison function used by qsort to order the + @details Comparison function used by qsort to order the variables according to the number of keys in the subtables. - Returns the difference in number of keys between the two - variables being compared.] - SideEffects [None] + @return the difference in number of keys between the two variables + being compared. -******************************************************************************/ + @sideeffect None + +*/ static int ddLinearUniqueCompare( - int * ptrX, - int * ptrY) + void const * ptrX, + void const * ptrY) { + IndexKey const * pX = (IndexKey const *) ptrX; + IndexKey const * pY = (IndexKey const *) ptrY; #if 0 - if (entry[*ptrY] == entry[*ptrX]) { - return((*ptrX) - (*ptrY)); + if (pY->keys == pX->keys) { + return(pX->index - pY->index); } #endif - return(entry[*ptrY] - entry[*ptrX]); + return(pY->keys - pX->keys); } /* end of ddLinearUniqueCompare */ -/**Function******************************************************************** +/** + @brief Given xLow <= x <= xHigh moves x up and down between the + boundaries. - Synopsis [Given xLow <= x <= xHigh moves x up and down between the - boundaries.] + @details At each step a linear transformation is tried, and, if it + decreases the size of the %DD, it is accepted. Finds the best position + and does the required changes. - Description [Given xLow <= x <= xHigh moves x up and down between the - boundaries. At each step a linear transformation is tried, and, if it - decreases the size of the DD, it is accepted. Finds the best position - and does the required changes. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddLinearAndSiftingAux( DdManager * table, @@ -907,7 +848,7 @@ ddLinearAndSiftingAux( int initialSize; int result; - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveDown = NULL; moveUp = NULL; @@ -934,7 +875,7 @@ ddLinearAndSiftingAux( if (moveDown == (Move *) CUDD_OUT_OF_MEM) goto ddLinearAndSiftingAuxOutOfMem; moveUp = ddUndoMoves(table,moveDown); #ifdef DD_DEBUG - assert(moveUp == NULL || moveUp->x == x); + assert(moveUp == NULL || moveUp->x == (DdHalfWord) x); #endif moveUp = ddLinearAndSiftingUp(table,x,xLow,moveUp); if (moveUp == (Move *) CUDD_OUT_OF_MEM) goto ddLinearAndSiftingAuxOutOfMem; @@ -948,7 +889,7 @@ ddLinearAndSiftingAux( if (moveUp == (Move *) CUDD_OUT_OF_MEM) goto ddLinearAndSiftingAuxOutOfMem; moveDown = ddUndoMoves(table,moveUp); #ifdef DD_DEBUG - assert(moveDown == NULL || moveDown->y == x); + assert(moveDown == NULL || moveDown->y == (DdHalfWord) x); #endif moveDown = ddLinearAndSiftingDown(table,x,xHigh,moveDown); if (moveDown == (Move *) CUDD_OUT_OF_MEM) goto ddLinearAndSiftingAuxOutOfMem; @@ -987,18 +928,17 @@ ddLinearAndSiftingAuxOutOfMem: } /* end of ddLinearAndSiftingAux */ -/**Function******************************************************************** +/** + @brief Sifts a variable up and applies linear transformations. - Synopsis [Sifts a variable up and applies linear transformations.] + @details Moves y up until either it reaches the bound (xLow) or the + size of the %DD heap increases too much. - Description [Sifts a variable up and applies linear transformations. - Moves y up until either it reaches the bound (xLow) or the size of - the DD heap increases too much. Returns the set of moves in case of - success; NULL if memory is full.] + @return the set of moves in case of success; NULL if memory is full. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static Move * ddLinearAndSiftingUp( DdManager * table, @@ -1029,16 +969,16 @@ ddLinearAndSiftingUp( ** change. The rest may vanish in the best case, except for ** the nodes at level xLow, which will not vanish, regardless. */ - limitSize = L = table->keys - table->isolated; + limitSize = L = (int) (table->keys - table->isolated); for (x = xLow + 1; x < y; x++) { xindex = table->invperm[x]; if (cuddTestInteract(table,xindex,yindex)) { isolated = table->vars[xindex]->ref == 1; - L -= table->subtables[x].keys - isolated; + L -= (int) table->subtables[x].keys - isolated; } } isolated = table->vars[yindex]->ref == 1; - L -= table->subtables[y].keys - isolated; + L -= (int) table->subtables[y].keys - isolated; x = cuddNextLow(table,y); while (x >= xLow && L <= limitSize) { @@ -1090,7 +1030,7 @@ ddLinearAndSiftingUp( /* Update the lower bound. */ if (cuddTestInteract(table,xindex,yindex)) { isolated = table->vars[xindex]->ref == 1; - L += table->subtables[y].keys - isolated; + L += (int) table->subtables[y].keys - isolated; } if ((double) size > (double) limitSize * table->maxGrowth) break; if (size < limitSize) limitSize = size; @@ -1110,18 +1050,17 @@ ddLinearAndSiftingUpOutOfMem: } /* end of ddLinearAndSiftingUp */ -/**Function******************************************************************** +/** + @brief Sifts a variable down and applies linear transformations. - Synopsis [Sifts a variable down and applies linear transformations.] + @details Moves x down until either it reaches the bound (xHigh) or + the size of the %DD heap increases too much. - Description [Sifts a variable down and applies linear - transformations. Moves x down until either it reaches the bound - (xHigh) or the size of the DD heap increases too much. Returns the - set of moves in case of success; NULL if memory is full.] + @return the set of moves in case of success; NULL if memory is full. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static Move * ddLinearAndSiftingDown( DdManager * table, @@ -1164,7 +1103,7 @@ ddLinearAndSiftingDown( zindex = table->invperm[z]; if (cuddTestInteract(table,xindex,zindex)) { isolated = table->vars[zindex]->ref == 1; - checkR += table->subtables[z].keys - isolated; + checkR += (int) table->subtables[z].keys - isolated; } } if (R != checkR) { @@ -1175,7 +1114,7 @@ ddLinearAndSiftingDown( yindex = table->invperm[y]; if (cuddTestInteract(table,xindex,yindex)) { isolated = table->vars[yindex]->ref == 1; - R -= table->subtables[y].keys - isolated; + R -= (int) table->subtables[y].keys - isolated; } size = cuddSwapInPlace(table,x,y); if (size == 0) goto ddLinearAndSiftingDownOutOfMem; @@ -1222,19 +1161,18 @@ ddLinearAndSiftingDownOutOfMem: } /* end of ddLinearAndSiftingDown */ -/**Function******************************************************************** +/** + @brief Given a set of moves, returns the %DD heap to the order + giving the minimum size. - Synopsis [Given a set of moves, returns the DD heap to the order - giving the minimum size.] + @details In case of ties, returns to the closest position giving the + minimum size. - Description [Given a set of moves, returns the DD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddLinearAndSiftingBackward( DdManager * table, @@ -1269,18 +1207,15 @@ ddLinearAndSiftingBackward( } /* end of ddLinearAndSiftingBackward */ -/**Function******************************************************************** - - Synopsis [Given a set of moves, returns the DD heap to the order - in effect before the moves.] +/** + @brief Given a set of moves, returns the %DD heap to the order + in effect before the moves. - Description [Given a set of moves, returns the DD heap to the - order in effect before the moves. Returns 1 in case of success; - 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static Move* ddUndoMoves( DdManager * table, @@ -1334,18 +1269,14 @@ ddUndoMovesOutOfMem: } /* end of ddUndoMoves */ -/**Function******************************************************************** - - Synopsis [XORs two rows of the linear transform matrix.] - - Description [XORs two rows of the linear transform matrix and replaces - the first row with the result.] +/** + @brief XORs two rows of the linear transform matrix. - SideEffects [none] + @details Replaces the first row with the result. - SeeAlso [] + @sideeffect none -******************************************************************************/ +*/ static void cuddXorLinear( DdManager * table, @@ -1357,7 +1288,7 @@ cuddXorLinear( int wordsPerRow = ((nvars - 1) >> LOGBPL) + 1; int xstart = wordsPerRow * x; int ystart = wordsPerRow * y; - long *linear = table->linear; + ptruint *linear = table->linear; for (i = 0; i < wordsPerRow; i++) { linear[xstart+i] ^= linear[ystart+i]; diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddLiteral.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddLiteral.c similarity index 75% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddLiteral.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddLiteral.c index b81697028..aa61ad168 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddLiteral.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddLiteral.c @@ -1,24 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddLiteral.c] + @ingroup cudd - PackageName [cudd] + @brief Functions for manipulation of literal sets represented by BDDs. - Synopsis [Functions for manipulation of literal sets represented by - BDDs.] + @author Fabio Somenzi - Description [External procedures included in this file: - <ul> - <li> Cudd_bddLiteralSetIntersection() - </ul> - Internal procedures included in this file: - <ul> - <li> cuddBddLiteralSetIntersectionRecur() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -48,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -72,22 +63,18 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddLiteral.c,v 1.9 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -95,21 +82,20 @@ static char rcsid[] DD_UNUSED = "$Id: cuddLiteral.c,v 1.9 2012/02/05 01:07:19 fa /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Computes the intesection of two sets of literals + represented as BDDs. - Synopsis [Computes the intesection of two sets of literals - represented as BDDs.] + @details Each set is represented as a cube of the literals in the + set. The empty set is represented by the constant 1. No variable + can be simultaneously present in both phases in a set. - Description [Computes the intesection of two sets of literals - represented as BDDs. Each set is represented as a cube of the - literals in the set. The empty set is represented by the constant 1. - No variable can be simultaneously present in both phases in a set. - Returns a pointer to the BDD representing the intersected sets, if - successful; NULL otherwise.] + @return a pointer to the %BDD representing the intersected sets, if + successful; NULL otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ DdNode * Cudd_bddLiteralSetIntersection( DdManager * dd, @@ -122,6 +108,9 @@ Cudd_bddLiteralSetIntersection( dd->reordered = 0; res = cuddBddLiteralSetIntersectionRecur(dd,f,g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddLiteralSetIntersection */ @@ -132,19 +121,19 @@ Cudd_bddLiteralSetIntersection( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of + Cudd_bddLiteralSetIntersection. - Synopsis [Performs the recursive step of - Cudd_bddLiteralSetIntersection.] + @details Scans the cubes for common variables, and checks whether + they agree in phase. - Description [Performs the recursive step of - Cudd_bddLiteralSetIntersection. Scans the cubes for common variables, - and checks whether they agree in phase. Returns a pointer to the - resulting cube if successful; NULL otherwise.] + @return a pointer to the resulting cube if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ DdNode * cuddBddLiteralSetIntersectionRecur( DdManager * dd, @@ -156,7 +145,7 @@ cuddBddLiteralSetIntersectionRecur( DdNode *fc, *gc; DdNode *one; DdNode *zero; - unsigned int topf, topg, comple; + int topf, topg, comple; int phasef, phaseg; statLine(dd); @@ -210,6 +199,8 @@ cuddBddLiteralSetIntersectionRecur( return(res); } + checkWhetherToGiveUp(dd); + /* Here f and g are both non constant and have the same top variable. */ comple = f != F; fc = cuddT(F); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddMatMult.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddMatMult.c similarity index 78% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddMatMult.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddMatMult.c index adcbdc79f..2b1e547b3 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddMatMult.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddMatMult.c @@ -1,28 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddMatMult.c] + @ingroup cudd - PackageName [cudd] + @brief Matrix multiplication functions. - Synopsis [Matrix multiplication functions.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_addMatrixMultiply() - <li> Cudd_addTimesPlus() - <li> Cudd_addTriangle() - <li> Cudd_addOuterSum() - </ul> - Static procedures included in this module: - <ul> - <li> addMMRecur() - <li> addTriangleRecur() - <li> cuddAddOuterSumRecur() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -52,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -79,16 +66,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddMatMult.c,v 1.18 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -98,32 +81,31 @@ static DdNode * addMMRecur (DdManager *dd, DdNode *A, DdNode *B, int topP, int * static DdNode * addTriangleRecur (DdManager *dd, DdNode *f, DdNode *g, int *vars, DdNode *cube); static DdNode * cuddAddOuterSumRecur (DdManager *dd, DdNode *M, DdNode *r, DdNode *c); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Calculates the product of two matrices represented as + ADDs. - Synopsis [Calculates the product of two matrices represented as - ADDs.] - - Description [Calculates the product of two matrices, A and B, - represented as ADDs. This procedure implements the quasiring multiplication + @details This procedure implements the quasiring multiplication algorithm. A is assumed to depend on variables x (rows) and z (columns). B is assumed to depend on variables z (rows) and y (columns). The product of A and B then depends on x (rows) and y (columns). Only the z variables have to be explicitly identified; - they are the "summation" variables. Returns a pointer to the - result if successful; NULL otherwise.] + they are the "summation" variables. + + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addTimesPlus Cudd_addTriangle Cudd_bddAndAbstract] + @see Cudd_addTimesPlus Cudd_addTriangle Cudd_bddAndAbstract -******************************************************************************/ +*/ DdNode * Cudd_addMatrixMultiply( DdManager * dd, @@ -154,29 +136,32 @@ Cudd_addMatrixMultiply( res = addMMRecur(dd,A,B,-1,vars); } while (dd->reordered == 1); FREE(vars); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addMatrixMultiply */ -/**Function******************************************************************** - - Synopsis [Calculates the product of two matrices represented as - ADDs.] +/** + @brief Calculates the product of two matrices represented as + ADDs. - Description [Calculates the product of two matrices, A and B, + @details Calculates the product of two matrices, A and B, represented as ADDs, using the CMU matrix by matrix multiplication - procedure by Clarke et al.. Matrix A has x's as row variables and z's - as column variables, while matrix B has z's as row variables and y's - as column variables. Returns the pointer to the result if successful; - NULL otherwise. The resulting matrix has x's as row variables and y's - as column variables.] + procedure by Clarke et al.. Matrix A has x's as row variables and + z's as column variables, while matrix B has z's as row variables and + y's as column variables. The resulting matrix has x's as row + variables and y's as column variables. + + @return the pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addMatrixMultiply] + @see Cudd_addMatrixMultiply -******************************************************************************/ +*/ DdNode * Cudd_addTimesPlus( DdManager * dd, @@ -216,25 +201,25 @@ Cudd_addTimesPlus( } /* end of Cudd_addTimesPlus */ -/**Function******************************************************************** +/** + @brief Performs the triangulation step for the shortest path + computation. - Synopsis [Performs the triangulation step for the shortest path - computation.] - - Description [Implements the semiring multiplication algorithm used in + @details Implements the semiring multiplication algorithm used in the triangulation step for the shortest path computation. f is assumed to depend on variables x (rows) and z (columns). g is assumed to depend on variables z (rows) and y (columns). The product of f and g then depends on x (rows) and y (columns). Only the z variables have to be explicitly identified; they are the - "abstraction" variables. Returns a pointer to the result if - successful; NULL otherwise. ] + "abstraction" variables. + + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addMatrixMultiply Cudd_bddAndAbstract] + @see Cudd_addMatrixMultiply Cudd_bddAndAbstract -******************************************************************************/ +*/ DdNode * Cudd_addTriangle( DdManager * dd, @@ -269,25 +254,26 @@ Cudd_addTriangle( Cudd_RecursiveDeref(dd,cube); if (res != NULL) cuddDeref(res); FREE(vars); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addTriangle */ -/**Function******************************************************************** - - Synopsis [Takes the minimum of a matrix and the outer sum of two vectors.] +/** + @brief Takes the minimum of a matrix and the outer sum of two vectors. - Description [Takes the pointwise minimum of a matrix and the outer + @details Takes the pointwise minimum of a matrix and the outer sum of two vectors. This procedure is used in the Floyd-Warshall - all-pair shortest path algorithm. Returns a pointer to the result if - successful; NULL otherwise.] + all-pair shortest path algorithm. - SideEffects [None] + @return a pointer to the result if successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * Cudd_addOuterSum( DdManager *dd, @@ -301,6 +287,9 @@ Cudd_addOuterSum( dd->reordered = 0; res = cuddAddOuterSumRecur(dd, M, r, c); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_addOuterSum */ @@ -315,16 +304,14 @@ Cudd_addOuterSum( /* Definition of static functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_addMatrixMultiply. - Synopsis [Performs the recursive step of Cudd_addMatrixMultiply.] + @return a pointer to the result if successful; NULL otherwise. - Description [Performs the recursive step of Cudd_addMatrixMultiply. - Returns a pointer to the result if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static DdNode * addMMRecur( DdManager * dd, @@ -347,7 +334,7 @@ addMMRecur( double scale; /* scaling factor */ int index; /* index of the top variable */ CUDD_VALUE_TYPE value; - unsigned int topA, topB, topV; + int topA, topB, topV; DD_CTFP cacheOp; statLine(dd); @@ -402,7 +389,7 @@ addMMRecur( scale = 1.0; for (i = 0; i < dd->size; i++) { if (vars[i]) { - if (dd->perm[i] > topP && (unsigned) dd->perm[i] < topV) { + if (dd->perm[i] > topP && dd->perm[i] < topV) { scale *= 2; } } @@ -430,6 +417,8 @@ addMMRecur( return(res); } + checkWhetherToGiveUp(dd); + /* compute the cofactors */ if (topV == topA) { At = cuddT(A); @@ -496,7 +485,7 @@ addMMRecur( scale = 1.0; for (i = 0; i < dd->size; i++) { if (vars[i]) { - if (dd->perm[i] > topP && (unsigned) dd->perm[i] < topV) { + if (dd->perm[i] > topP && dd->perm[i] < topV) { scale *= 2; } } @@ -526,16 +515,14 @@ addMMRecur( } /* end of addMMRecur */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_addTriangle. - Synopsis [Performs the recursive step of Cudd_addTriangle.] + @return a pointer to the result if successful; NULL otherwise. - Description [Performs the recursive step of Cudd_addTriangle. Returns - a pointer to the result if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static DdNode * addTriangleRecur( DdManager * dd, @@ -571,6 +558,8 @@ addTriangleRecur( } } + checkWhetherToGiveUp(dd); + topf = cuddI(dd,f->index); topg = cuddI(dd,g->index); top = ddMin(topf,topg); @@ -619,18 +608,14 @@ addTriangleRecur( } /* end of addTriangleRecur */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_addOuterSum.] +/** + @brief Performs the recursive step of Cudd_addOuterSum. - Description [Performs the recursive step of Cudd_addOuterSum. - Returns a pointer to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static DdNode * cuddAddOuterSumRecur( DdManager *dd, @@ -670,6 +655,8 @@ cuddAddOuterSumRecur( R = cuddCacheLookup(dd,DD_ADD_OUT_SUM_TAG,M,r,c); if (R != NULL) return(R); + checkWhetherToGiveUp(dd); + topM = cuddI(dd,M->index); topr = cuddI(dd,r->index); topc = cuddI(dd,c->index); v = ddMin(topM,ddMin(topr,topc)); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddPriority.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddPriority.c similarity index 76% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddPriority.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddPriority.c index 2b59adca2..dfb530f14 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddPriority.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddPriority.c @@ -1,45 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddPriority.c] - - PackageName [cudd] - - Synopsis [Priority functions.] - - Description [External procedures included in this file: - <ul> - <li> Cudd_PrioritySelect() - <li> Cudd_Xgty() - <li> Cudd_Xeqy() - <li> Cudd_addXeqy() - <li> Cudd_Dxygtdxz() - <li> Cudd_Dxygtdyz() - <li> Cudd_Inequality() - <li> Cudd_Disequality() - <li> Cudd_bddInterval() - <li> Cudd_CProjection() - <li> Cudd_addHamming() - <li> Cudd_MinHammingDist() - <li> Cudd_bddClosestCube() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddCProjectionRecur() - <li> cuddBddClosestCube() - </ul> - Static procedures included in this module: - <ul> - <li> cuddMinHammingDistRecur() - <li> separateCube() - <li> createResult() - </ul> - ] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Priority functions. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -69,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -81,7 +51,6 @@ /* Constant declarations */ /*---------------------------------------------------------------------------*/ -#define DD_DEBUG 1 /*---------------------------------------------------------------------------*/ /* Stucture declarations */ @@ -97,16 +66,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddPriority.c,v 1.36 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -115,7 +80,7 @@ static int cuddMinHammingDistRecur (DdNode * f, int *minterm, DdHashTable * tabl static DdNode * separateCube (DdManager *dd, DdNode *f, CUDD_VALUE_TYPE *distance); static DdNode * createResult (DdManager *dd, unsigned int index, unsigned int phase, DdNode *cube, CUDD_VALUE_TYPE distance); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -123,24 +88,21 @@ static DdNode * createResult (DdManager *dd, unsigned int index, unsigned int ph /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Selects pairs from R using a priority function. - Synopsis [Selects pairs from R using a priority function.] - - Description [Selects pairs from a relation R(x,y) (given as a BDD) + @details Selects pairs from a relation R(x,y) (given as a %BDD) in such a way that a given x appears in one pair only. Uses a priority function to determine which y should be paired to a given x. - Cudd_PrioritySelect returns a pointer to - the selected function if successful; NULL otherwise. - Three of the arguments--x, y, and z--are vectors of BDD variables. + Three of the arguments--x, y, and z--are vectors of %BDD variables. The first two are the variables on which R depends. The third vector is a vector of auxiliary variables, used during the computation. This vector is optional. If a NULL value is passed instead, Cudd_PrioritySelect will create the working variables on the fly. The sizes of x and y (and z if it is not NULL) should equal n. - The priority function Pi can be passed as a BDD, or can be built by + The priority function Pi can be passed as a %BDD, or can be built by Cudd_PrioritySelect. If NULL is passed instead of a DdNode *, - parameter Pifunc is used by Cudd_PrioritySelect to build a BDD for the + parameter Pifunc is used by Cudd_PrioritySelect to build a %BDD for the priority function. (Pifunc is a pointer to a C function.) If Pi is not NULL, then Pifunc is ignored. Pifunc should have the same interface as the standard priority functions (e.g., Cudd_Dxygtdxz). @@ -158,25 +120,27 @@ static DdNode * createResult (DdManager *dd, unsigned int index, unsigned int ph Cudd_PrioritySelect normally obtains better results because it can use more powerful matching schemes (e.g., Cudd_Dxygtdxz). </ul> - ] - SideEffects [If called with z == NULL, will create new variables in - the manager.] + @return a pointer to the selected function if successful; NULL + otherwise. + + @sideeffect If called with z == NULL, will create new variables in + the manager. - SeeAlso [Cudd_Dxygtdxz Cudd_Dxygtdyz Cudd_Xgty - Cudd_bddAdjPermuteX Cudd_CProjection] + @see Cudd_Dxygtdxz Cudd_Dxygtdyz Cudd_Xgty + Cudd_bddAdjPermuteX Cudd_CProjection -******************************************************************************/ +*/ DdNode * Cudd_PrioritySelect( - DdManager * dd /* manager */, - DdNode * R /* BDD of the relation */, - DdNode ** x /* array of x variables */, - DdNode ** y /* array of y variables */, - DdNode ** z /* array of z variables (optional: may be NULL) */, - DdNode * Pi /* BDD of the priority function (optional: may be NULL) */, - int n /* size of x, y, and z */, - DD_PRFP Pifunc /* function used to build Pi if it is NULL */) + DdManager * dd /**< manager */, + DdNode * R /**< %BDD of the relation */, + DdNode ** x /**< array of x variables */, + DdNode ** y /**< array of y variables */, + DdNode ** z /**< array of z variables (optional: may be NULL) */, + DdNode * Pi /**< %BDD of the priority function (optional: may be NULL) */, + int n /**< size of x, y, and z */, + DD_PRFP Pifunc /**< function used to build Pi if it is NULL */) { DdNode *res = NULL; DdNode *zcube = NULL; @@ -254,35 +218,35 @@ endgame: } /* Cudd_PrioritySelect */ -/**Function******************************************************************** - - Synopsis [Generates a BDD for the function x > y.] +/** + @brief Generates a %BDD for the function x > y. - Description [This function generates a BDD for the function x > y. + @details This function generates a %BDD for the function x > y. Both x and y are N-bit numbers, x\[0\] x\[1\] ... x\[N-1\] and y\[0\] y\[1\] ... y\[N-1\], with 0 the most significant bit. - The BDD is built bottom-up. + The %BDD is built bottom-up. It has 3*N-1 internal nodes, if the variables are ordered as follows: x\[0\] y\[0\] x\[1\] y\[1\] ... x\[N-1\] y\[N-1\]. Argument z is not used by Cudd_Xgty: it is included to make it - call-compatible to Cudd_Dxygtdxz and Cudd_Dxygtdyz.] + call-compatible to Cudd_Dxygtdxz and Cudd_Dxygtdyz. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_PrioritySelect Cudd_Dxygtdxz Cudd_Dxygtdyz] + @see Cudd_PrioritySelect Cudd_Dxygtdxz Cudd_Dxygtdyz -******************************************************************************/ +*/ DdNode * Cudd_Xgty( - DdManager * dd /* DD manager */, - int N /* number of x and y variables */, - DdNode ** z /* array of z variables: unused */, - DdNode ** x /* array of x variables */, - DdNode ** y /* array of y variables */) + DdManager * dd /**< %DD manager */, + int N /**< number of x and y variables */, + DdNode ** z /**< array of z variables: unused */, + DdNode ** x /**< array of x variables */, + DdNode ** y /**< array of y variables */) { DdNode *u, *v, *w; int i; + (void) z; /* avoid warning */ /* Build bottom part of BDD outside loop. */ u = Cudd_bddAnd(dd, x[N-1], Cudd_Not(y[N-1])); if (u == NULL) return(NULL); @@ -321,28 +285,26 @@ Cudd_Xgty( } /* end of Cudd_Xgty */ -/**Function******************************************************************** +/** + @brief Generates a %BDD for the function x==y. - Synopsis [Generates a BDD for the function x==y.] - - Description [This function generates a BDD for the function x==y. + @details This function generates a %BDD for the function x==y. Both x and y are N-bit numbers, x\[0\] x\[1\] ... x\[N-1\] and - y\[0\] y\[1\] ... y\[N-1\], with 0 the most significant bit. - The BDD is built bottom-up. + y\[0\] y\[1\] ... y\[N-1\]. The %BDD is built bottom-up. It has 3*N-1 internal nodes, if the variables are ordered as follows: - x\[0\] y\[0\] x\[1\] y\[1\] ... x\[N-1\] y\[N-1\]. ] + x\[0\] y\[0\] x\[1\] y\[1\] ... x\[N-1\] y\[N-1\]. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addXeqy] + @see Cudd_addXeqy -******************************************************************************/ +*/ DdNode * Cudd_Xeqy( - DdManager * dd /* DD manager */, - int N /* number of x and y variables */, - DdNode ** x /* array of x variables */, - DdNode ** y /* array of y variables */) + DdManager * dd /**< %DD manager */, + int N /**< number of x and y variables */, + DdNode ** x /**< array of x variables */, + DdNode ** y /**< array of y variables */) { DdNode *u, *v, *w; int i; @@ -384,28 +346,26 @@ Cudd_Xeqy( } /* end of Cudd_Xeqy */ -/**Function******************************************************************** - - Synopsis [Generates an ADD for the function x==y.] +/** + @brief Generates an %ADD for the function x==y. - Description [This function generates an ADD for the function x==y. + @details This function generates an %ADD for the function x==y. Both x and y are N-bit numbers, x\[0\] x\[1\] ... x\[N-1\] and - y\[0\] y\[1\] ... y\[N-1\], with 0 the most significant bit. - The ADD is built bottom-up. + y\[0\] y\[1\] ... y\[N-1\]. The %ADD is built bottom-up. It has 3*N-1 internal nodes, if the variables are ordered as follows: - x\[0\] y\[0\] x\[1\] y\[1\] ... x\[N-1\] y\[N-1\]. ] + x\[0\] y\[0\] x\[1\] y\[1\] ... x\[N-1\] y\[N-1\]. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Xeqy] + @see Cudd_Xeqy -******************************************************************************/ +*/ DdNode * Cudd_addXeqy( - DdManager * dd /* DD manager */, - int N /* number of x and y variables */, - DdNode ** x /* array of x variables */, - DdNode ** y /* array of y variables */) + DdManager * dd /**< %DD manager */, + int N /**< number of x and y variables */, + DdNode ** x /**< array of x variables */, + DdNode ** y /**< array of y variables */) { DdNode *one, *zero; DdNode *u, *v, *w; @@ -466,33 +426,32 @@ Cudd_addXeqy( } /* end of Cudd_addXeqy */ -/**Function******************************************************************** - - Synopsis [Generates a BDD for the function d(x,y) > d(x,z).] +/** + @brief Generates a %BDD for the function d(x,y) > d(x,z). - Description [This function generates a BDD for the function d(x,y) + @details This function generates a %BDD for the function d(x,y) > d(x,z); x, y, and z are N-bit numbers, x\[0\] x\[1\] ... x\[N-1\], y\[0\] y\[1\] ... y\[N-1\], and z\[0\] z\[1\] ... z\[N-1\], with 0 the most significant bit. The distance d(x,y) is defined as: - \sum_{i=0}^{N-1}(|x_i - y_i| \cdot 2^{N-i-1}). - The BDD is built bottom-up. + \f$\sum_{i=0}^{N-1}(|x_i - y_i| \cdot 2^{N-i-1})\f$. + The %BDD is built bottom-up. It has 7*N-3 internal nodes, if the variables are ordered as follows: - x\[0\] y\[0\] z\[0\] x\[1\] y\[1\] z\[1\] ... x\[N-1\] y\[N-1\] z\[N-1\]. ] + x\[0\] y\[0\] z\[0\] x\[1\] y\[1\] z\[1\] ... x\[N-1\] y\[N-1\] z\[N-1\]. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_PrioritySelect Cudd_Dxygtdyz Cudd_Xgty Cudd_bddAdjPermuteX] + @see Cudd_PrioritySelect Cudd_Dxygtdyz Cudd_Xgty Cudd_bddAdjPermuteX -******************************************************************************/ +*/ DdNode * Cudd_Dxygtdxz( - DdManager * dd /* DD manager */, - int N /* number of x, y, and z variables */, - DdNode ** x /* array of x variables */, - DdNode ** y /* array of y variables */, - DdNode ** z /* array of z variables */) + DdManager * dd /**< %DD manager */, + int N /**< number of x, y, and z variables */, + DdNode ** x /**< array of x variables */, + DdNode ** y /**< array of y variables */, + DdNode ** z /**< array of z variables */) { DdNode *one, *zero; DdNode *z1, *z2, *z3, *z4, *y1_, *y2, *x1; @@ -593,33 +552,32 @@ Cudd_Dxygtdxz( } /* end of Cudd_Dxygtdxz */ -/**Function******************************************************************** - - Synopsis [Generates a BDD for the function d(x,y) > d(y,z).] +/** + @brief Generates a %BDD for the function d(x,y) > d(y,z). - Description [This function generates a BDD for the function d(x,y) + @details This function generates a %BDD for the function d(x,y) > d(y,z); x, y, and z are N-bit numbers, x\[0\] x\[1\] ... x\[N-1\], y\[0\] y\[1\] ... y\[N-1\], and z\[0\] z\[1\] ... z\[N-1\], with 0 the most significant bit. The distance d(x,y) is defined as: - \sum_{i=0}^{N-1}(|x_i - y_i| \cdot 2^{N-i-1}). - The BDD is built bottom-up. + \f$\sum_{i=0}^{N-1}(|x_i - y_i| \cdot 2^{N-i-1})\f$. + The %BDD is built bottom-up. It has 7*N-3 internal nodes, if the variables are ordered as follows: - x\[0\] y\[0\] z\[0\] x\[1\] y\[1\] z\[1\] ... x\[N-1\] y\[N-1\] z\[N-1\]. ] + x\[0\] y\[0\] z\[0\] x\[1\] y\[1\] z\[1\] ... x\[N-1\] y\[N-1\] z\[N-1\]. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_PrioritySelect Cudd_Dxygtdxz Cudd_Xgty Cudd_bddAdjPermuteX] + @see Cudd_PrioritySelect Cudd_Dxygtdxz Cudd_Xgty Cudd_bddAdjPermuteX -******************************************************************************/ +*/ DdNode * Cudd_Dxygtdyz( - DdManager * dd /* DD manager */, - int N /* number of x, y, and z variables */, - DdNode ** x /* array of x variables */, - DdNode ** y /* array of y variables */, - DdNode ** z /* array of z variables */) + DdManager * dd /**< %DD manager */, + int N /**< number of x, y, and z variables */, + DdNode ** x /**< array of x variables */, + DdNode ** y /**< array of y variables */, + DdNode ** z /**< array of z variables */) { DdNode *one, *zero; DdNode *z1, *z2, *z3, *z4, *y1_, *y2, *x1; @@ -720,29 +678,28 @@ Cudd_Dxygtdyz( } /* end of Cudd_Dxygtdyz */ -/**Function******************************************************************** +/** + @brief Generates a %BDD for the function x - y ≥ c. - Synopsis [Generates a BDD for the function x - y ≥ c.] - - Description [This function generates a BDD for the function x -y ≥ c. + @details This function generates a %BDD for the function x -y ≥ c. Both x and y are N-bit numbers, x\[0\] x\[1\] ... x\[N-1\] and y\[0\] y\[1\] ... y\[N-1\], with 0 the most significant bit. - The BDD is built bottom-up. + The %BDD is built bottom-up. It has a linear number of nodes if the variables are ordered as follows: - x\[0\] y\[0\] x\[1\] y\[1\] ... x\[N-1\] y\[N-1\].] + x\[0\] y\[0\] x\[1\] y\[1\] ... x\[N-1\] y\[N-1\]. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Xgty] + @see Cudd_Xgty -******************************************************************************/ +*/ DdNode * Cudd_Inequality( - DdManager * dd /* DD manager */, - int N /* number of x and y variables */, - int c /* right-hand side constant */, - DdNode ** x /* array of x variables */, - DdNode ** y /* array of y variables */) + DdManager * dd /**< %DD manager */, + int N /**< number of x and y variables */, + int c /**< right-hand side constant */, + DdNode ** x /**< array of x variables */, + DdNode ** y /**< array of y variables */) { /* The nodes at level i represent values of the difference that are ** multiples of 2^i. We use variables with names starting with k @@ -763,7 +720,7 @@ Cudd_Inequality( ** stored, along with their k values, in these variables. At each level, ** the old nodes are freed and the new nodes are copied into the old map. */ - DdNode *map[2]; + DdNode *map[2] = {NULL, NULL}; int invalidIndex = 1 << (N-1); int index[2] = {invalidIndex, invalidIndex}; @@ -786,7 +743,7 @@ Cudd_Inequality( int leftChild, middleChild, rightChild; DdNode *g0, *g1, *fplus, *fequal, *fminus; int j; - DdNode *newMap[2]; + DdNode *newMap[2] = {NULL, NULL}; int newIndex[2]; kTrueLower = kTrue; @@ -908,29 +865,28 @@ Cudd_Inequality( } /* end of Cudd_Inequality */ -/**Function******************************************************************** - - Synopsis [Generates a BDD for the function x - y != c.] +/** + @brief Generates a %BDD for the function x - y != c. - Description [This function generates a BDD for the function x -y != c. + @details This function generates a %BDD for the function x -y != c. Both x and y are N-bit numbers, x\[0\] x\[1\] ... x\[N-1\] and y\[0\] y\[1\] ... y\[N-1\], with 0 the most significant bit. - The BDD is built bottom-up. + The %BDD is built bottom-up. It has a linear number of nodes if the variables are ordered as follows: - x\[0\] y\[0\] x\[1\] y\[1\] ... x\[N-1\] y\[N-1\].] + x\[0\] y\[0\] x\[1\] y\[1\] ... x\[N-1\] y\[N-1\]. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Xgty] + @see Cudd_Xgty -******************************************************************************/ +*/ DdNode * Cudd_Disequality( - DdManager * dd /* DD manager */, - int N /* number of x and y variables */, - int c /* right-hand side constant */, - DdNode ** x /* array of x variables */, - DdNode ** y /* array of y variables */) + DdManager * dd /**< %DD manager */, + int N /**< number of x and y variables */, + int c /**< right-hand side constant */, + DdNode ** x /**< array of x variables */, + DdNode ** y /**< array of y variables */) { /* The nodes at level i represent values of the difference that are ** multiples of 2^i. We use variables with names starting with k @@ -952,7 +908,7 @@ Cudd_Disequality( ** stored, along with their k values, in these variables. At each level, ** the old nodes are freed and the new nodes are copied into the old map. */ - DdNode *map[2]; + DdNode *map[2] = {NULL, NULL}; int invalidIndex = 1 << (N-1); int index[2] = {invalidIndex, invalidIndex}; @@ -974,7 +930,7 @@ Cudd_Disequality( int leftChild, middleChild, rightChild; DdNode *g0, *g1, *fplus, *fequal, *fminus; int j; - DdNode *newMap[2]; + DdNode *newMap[2] = {NULL, NULL}; int newIndex[2]; kTrueLbLower = kTrueLb; @@ -1096,30 +1052,29 @@ Cudd_Disequality( } /* end of Cudd_Disequality */ -/**Function******************************************************************** - - Synopsis [Generates a BDD for the function lowerB ≤ x ≤ upperB.] +/** + @brief Generates a %BDD for the function lowerB ≤ x ≤ upperB. - Description [This function generates a BDD for the function + @details This function generates a %BDD for the function lowerB ≤ x ≤ upperB, where x is an N-bit number, x\[0\] x\[1\] ... x\[N-1\], with 0 the most significant bit (important!). The number of variables N should be sufficient to represent the bounds; otherwise, the bounds are truncated to their N least significant bits. Two BDDs are built bottom-up for lowerB ≤ x and x ≤ upperB, and they - are finally conjoined.] + are finally conjoined. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Xgty] + @see Cudd_Xgty -******************************************************************************/ +*/ DdNode * Cudd_bddInterval( - DdManager * dd /* DD manager */, - int N /* number of x variables */, - DdNode ** x /* array of x variables */, - unsigned int lowerB /* lower bound */, - unsigned int upperB /* upper bound */) + DdManager * dd /**< %DD manager */, + int N /**< number of x variables */, + DdNode ** x /**< array of x variables */, + unsigned int lowerB /**< lower bound */, + unsigned int upperB /**< upper bound */) { DdNode *one, *zero; DdNode *r, *rl, *ru; @@ -1178,20 +1133,20 @@ Cudd_bddInterval( } /* end of Cudd_bddInterval */ -/**Function******************************************************************** +/** + @brief Computes the compatible projection of R w.r.t. cube Y. - Synopsis [Computes the compatible projection of R w.r.t. cube Y.] + @details Computes the compatible projection of relation R with + respect to cube Y. For a comparison between Cudd_CProjection and + Cudd_PrioritySelect, see the documentation of the latter. - Description [Computes the compatible projection of relation R with - respect to cube Y. Returns a pointer to the c-projection if - successful; NULL otherwise. For a comparison between Cudd_CProjection - and Cudd_PrioritySelect, see the documentation of the latter.] + @return a pointer to the c-projection if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_PrioritySelect] + @see Cudd_PrioritySelect -******************************************************************************/ +*/ DdNode * Cudd_CProjection( DdManager * dd, @@ -1222,6 +1177,9 @@ Cudd_CProjection( if (res == NULL) { Cudd_RecursiveDeref(dd,support); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(NULL); } cuddRef(res); @@ -1233,20 +1191,18 @@ Cudd_CProjection( } /* end of Cudd_CProjection */ -/**Function******************************************************************** +/** + @brief Computes the Hamming distance %ADD. - Synopsis [Computes the Hamming distance ADD.] + @details The two vectors xVars and yVars identify the variables that + form the two arguments. - Description [Computes the Hamming distance ADD. Returns an ADD that - gives the Hamming distance between its two arguments if successful; - NULL otherwise. The two vectors xVars and yVars identify the variables - that form the two arguments.] + @return an %ADD that gives the Hamming distance between its two + arguments if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ DdNode * Cudd_addHamming( DdManager * dd, @@ -1294,28 +1250,29 @@ Cudd_addHamming( } /* end of Cudd_addHamming */ -/**Function******************************************************************** - - Synopsis [Returns the minimum Hamming distance between f and minterm.] +/** + @brief Returns the minimum Hamming distance between f and minterm. - Description [Returns the minimum Hamming distance between the + @details Returns the minimum Hamming distance between the minterms of a function f and a reference minterm. The function is - given as a BDD; the minterm is given as an array of integers, one - for each variable in the manager. Returns the minimum distance if - it is less than the upper bound; the upper bound if the minimum - distance is at least as large; CUDD_OUT_OF_MEM in case of failure.] + given as a %BDD; the minterm is given as an array of integers, one + for each variable in the manager. + + @return the minimum distance if it is less than the upper bound; the + upper bound if the minimum distance is at least as large; + CUDD_OUT_OF_MEM in case of failure. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addHamming Cudd_bddClosestCube] + @see Cudd_addHamming Cudd_bddClosestCube -******************************************************************************/ +*/ int Cudd_MinHammingDist( - DdManager *dd /* DD manager */, - DdNode *f /* function to examine */, - int *minterm /* reference minterm */, - int upperBound /* distance above which an approximate answer is OK */) + DdManager *dd /**< %DD manager */, + DdNode *f /**< function to examine */, + int *minterm /**< reference minterm */, + int upperBound /**< distance above which an approximate answer is OK */) { DdHashTable *table; CUDD_VALUE_TYPE epsilon; @@ -1336,21 +1293,20 @@ Cudd_MinHammingDist( } /* end of Cudd_MinHammingDist */ -/**Function******************************************************************** +/** + @brief Finds a cube of f at minimum Hamming distance from the minterms of g. - Synopsis [Finds a cube of f at minimum Hamming distance from g.] + @details All the minterms of the cube are at the minimum distance. + If the distance is 0, the cube belongs to the intersection of f and + g. - Description [Finds a cube of f at minimum Hamming distance from the - minterms of g. All the minterms of the cube are at the minimum - distance. If the distance is 0, the cube belongs to the - intersection of f and g. Returns the cube if successful; NULL - otherwise.] + @return the cube if successful; NULL otherwise. - SideEffects [The distance is returned as a side effect.] + @sideeffect The distance is returned as a side effect. - SeeAlso [Cudd_MinHammingDist] + @see Cudd_MinHammingDist -******************************************************************************/ +*/ DdNode * Cudd_bddClosestCube( DdManager *dd, @@ -1366,7 +1322,12 @@ Cudd_bddClosestCube( dd->reordered = 0; res = cuddBddClosestCube(dd,f,g,CUDD_CONST_INDEX + 1.0); } while (dd->reordered == 1); - if (res == NULL) return(NULL); + if (res == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(NULL); + } cuddRef(res); /* Unpack distance and cube. */ @@ -1376,6 +1337,9 @@ Cudd_bddClosestCube( } while (dd->reordered == 1); if (acube == NULL) { Cudd_RecursiveDeref(dd, res); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(NULL); } cuddRef(acube); @@ -1388,6 +1352,9 @@ Cudd_bddClosestCube( } while (dd->reordered == 1); if (res == NULL) { Cudd_RecursiveDeref(dd, acube); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(NULL); } cuddRef(res); @@ -1405,18 +1372,16 @@ Cudd_bddClosestCube( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_CProjection.] +/** + @brief Performs the recursive step of Cudd_CProjection. - Description [Performs the recursive step of Cudd_CProjection. Returns - the projection if successful; NULL otherwise.] + @return the projection if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_CProjection] + @see Cudd_CProjection -******************************************************************************/ +*/ DdNode * cuddCProjectionRecur( DdManager * dd, @@ -1426,14 +1391,15 @@ cuddCProjectionRecur( { DdNode *res, *res1, *res2, *resA; DdNode *r, *y, *RT, *RE, *YT, *YE, *Yrest, *Ra, *Ran, *Gamma, *Alpha; - unsigned int topR, topY, top, index; + int topR, topY, top; + unsigned int index; DdNode *one = DD_ONE(dd); statLine(dd); if (Y == one) return(R); #ifdef DD_DEBUG - assert(!Cudd_IsConstant(Y)); + assert(!Cudd_IsConstantInt(Y)); #endif if (R == Cudd_Not(one)) return(R); @@ -1441,6 +1407,8 @@ cuddCProjectionRecur( res = cuddCacheLookup2(dd, Cudd_CProjection, R, Y); if (res != NULL) return(res); + checkWhetherToGiveUp(dd); + r = Cudd_Regular(R); topR = cuddI(dd,r->index); y = Cudd_Regular(Y); @@ -1449,8 +1417,8 @@ cuddCProjectionRecur( top = ddMin(topR, topY); /* Compute the cofactors of R */ + index = r->index; if (topR == top) { - index = r->index; RT = cuddT(r); RE = cuddE(r); if (r != R) { @@ -1567,17 +1535,16 @@ cuddCProjectionRecur( } /* end of cuddCProjectionRecur */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_bddClosestCube. + + @details@parblock + The procedure uses a four-way recursion to examine all four combinations + of cofactors of <code>f</code> and <code>g</code> according to the + following formula. - Synopsis [Performs the recursive step of Cudd_bddClosestCube.] + H(f,g) = min(H(ft,gt), H(fe,ge), H(ft,ge)+1, H(fe,gt)+1) - Description [Performs the recursive step of Cudd_bddClosestCube. - Returns the cube if succesful; NULL otherwise. The procedure uses a - four-way recursion to examine all four combinations of cofactors of - <code>f</code> and <code>g</code> according to the following formula. - <pre> - H(f,g) = min(H(ft,gt), H(fe,ge), H(ft,ge)+1, H(fe,gt)+1) - </pre> Bounding is based on the following observations. <ul> <li> If we already found two points at distance 0, there is no point in @@ -1589,55 +1556,58 @@ cuddCProjectionRecur( </ul> The variable <code>bound</code> is set at the largest value of the distance that we are still interested in. Therefore, we desist when - <pre> - (bound == -1) and (F != not(G)) or (bound == 0) and (F == not(G)). - </pre> + + (bound == -1) and (F != not(G)) or (bound == 0) and (F == not(G)). + If we were maximally aggressive in using the bound, we would always set the bound to the minimum distance seen thus far minus one. That is, we would maintain the invariant - <pre> - bound < minD, - </pre> + + bound < minD, + except at the very beginning, when we have no value for - <code>minD</code>.<p> + <code>minD</code>. However, we do not use <code>bound < minD</code> when examining the two negative cofactors, because we try to find a large cube at minimum distance. To do so, we try to find a cube in the negative cofactors at the same or smaller distance from the cube found in the - positive cofactors.<p> + positive cofactors. When we compute <code>H(ft,ge)</code> and <code>H(fe,gt)</code> we know that we are going to add 1 to the result of the recursive call to account for the difference in the splitting variable. Therefore, - we decrease the bound correspondingly.<p> + we decrease the bound correspondingly. Another important observation concerns the need of examining all four pairs of cofators only when both <code>f</code> and - <code>g</code> depend on the top variable.<p> + <code>g</code> depend on the top variable. Suppose <code>gt == ge == g</code>. (That is, <code>g</code> does not depend on the top variable.) Then - <pre> - H(f,g) = min(H(ft,g), H(fe,g), H(ft,g)+1, H(fe,g)+1) - = min(H(ft,g), H(fe,g)) . - </pre> - Therefore, under these circumstances, we skip the two "cross" cases.<p> + + H(f,g) = min(H(ft,g), H(fe,g), H(ft,g)+1, H(fe,g)+1) + = min(H(ft,g), H(fe,g)) . + + Therefore, under these circumstances, we skip the two "cross" cases. An interesting feature of this function is the scheme used for caching the results in the global computed table. Since we have a - cube and a distance, we combine them to form an ADD. The + cube and a distance, we combine them to form an %ADD. The combination replaces the zero child of the top node of the cube with the negative of the distance. (The use of the negative is to avoid ambiguity with 1.) The degenerate cases (zero and one) are treated specially because the distance is known (0 for one, and infinity for - zero).] + zero). + @endparblock - SideEffects [None] + @return the cube if succesful; NULL otherwise. - SeeAlso [Cudd_bddClosestCube] + @sideeffect None -******************************************************************************/ + @see Cudd_bddClosestCube + +*/ DdNode * cuddBddClosestCube( DdManager *dd, @@ -1651,7 +1621,8 @@ cuddBddClosestCube( DdNode *one = DD_ONE(dd); DdNode *lzero = Cudd_Not(one); DdNode *azero = DD_ZERO(dd); - unsigned int topf, topg, index; + int topf, topg; + unsigned int index; statLine(dd); if (bound < (f == Cudd_Not(g))) return(azero); @@ -1667,6 +1638,8 @@ cuddBddClosestCube( if (res != NULL) return(res); } + checkWhetherToGiveUp(dd); + topf = cuddI(dd,F->index); topg = cuddI(dd,G->index); @@ -1826,30 +1799,29 @@ cuddBddClosestCube( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_MinHammingDist.] +/** + @brief Performs the recursive step of Cudd_MinHammingDist. - Description [Performs the recursive step of Cudd_MinHammingDist. - It is based on the following identity. Let H(f) be the + @details It is based on the following identity. Let H(f) be the minimum Hamming distance of the minterms of f from the reference minterm. Then: - <xmp> - H(f) = min(H(f0)+h0,H(f1)+h1) - </xmp> + + H(f) = min(H(f0)+h0,H(f1)+h1) + where f0 and f1 are the two cofactors of f with respect to its top variable; h0 is 1 if the minterm assigns 1 to the top variable of f; h1 is 1 if the minterm assigns 0 to the top variable of f. The upper bound on the distance is used to bound the depth of the recursion. - Returns the minimum distance unless it exceeds the upper bound or - computation fails.] - SideEffects [None] + @return the minimum distance unless it exceeds the upper bound or + computation fails. + + @sideeffect None - SeeAlso [Cudd_MinHammingDist] + @see Cudd_MinHammingDist -******************************************************************************/ +*/ static int cuddMinHammingDistRecur( DdNode * f, @@ -1918,18 +1890,16 @@ cuddMinHammingDistRecur( } /* end of cuddMinHammingDistRecur */ -/**Function******************************************************************** +/** + @brief Separates cube from distance. - Synopsis [Separates cube from distance.] + @return the cube if successful; NULL otherwise. - Description [Separates cube from distance. Returns the cube if - successful; NULL otherwise.] + @sideeffect The distance is returned as a side effect. - SideEffects [The distance is returned as a side effect.] + @see cuddBddClosestCube createResult - SeeAlso [cuddBddClosestCube createResult] - -******************************************************************************/ +*/ static DdNode * separateCube( DdManager *dd, @@ -1939,7 +1909,7 @@ separateCube( DdNode *cube, *t; /* One and zero are special cases because the distance is implied. */ - if (Cudd_IsConstant(f)) { + if (Cudd_IsConstantInt(f)) { *distance = (f == DD_ONE(dd)) ? 0.0 : (1.0 + (CUDD_VALUE_TYPE) CUDD_CONST_INDEX); return(f); @@ -1948,15 +1918,15 @@ separateCube( /* Find out which branch points to the distance and replace the top ** node with one pointing to zero instead. */ t = cuddT(f); - if (Cudd_IsConstant(t) && cuddV(t) <= 0) { + if (Cudd_IsConstantInt(t) && cuddV(t) <= 0) { #ifdef DD_DEBUG - assert(!Cudd_IsConstant(cuddE(f)) || cuddE(f) == DD_ONE(dd)); + assert(!Cudd_IsConstantInt(cuddE(f)) || cuddE(f) == DD_ONE(dd)); #endif *distance = -cuddV(t); cube = cuddUniqueInter(dd, f->index, DD_ZERO(dd), cuddE(f)); } else { #ifdef DD_DEBUG - assert(!Cudd_IsConstant(t) || t == DD_ONE(dd)); + assert(!Cudd_IsConstantInt(t) || t == DD_ONE(dd)); #endif *distance = -cuddV(cuddE(f)); cube = cuddUniqueInter(dd, f->index, t, DD_ZERO(dd)); @@ -1967,18 +1937,17 @@ separateCube( } /* end of separateCube */ -/**Function******************************************************************** - - Synopsis [Builds a result for cache storage.] +/** + @brief Builds a result for cache storage. - Description [Builds a result for cache storage. Returns a pointer - to the resulting ADD if successful; NULL otherwise.] + @return a pointer to the resulting %ADD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddBddClosestCube separateCube] + @see cuddBddClosestCube separateCube -******************************************************************************/ +*/ static DdNode * createResult( DdManager *dd, @@ -1992,7 +1961,7 @@ createResult( /* Special case. The cube is either one or zero, and we do not ** add any variables. Hence, the result is also one or zero, ** and the distance remains implied by the value of the constant. */ - if (index == CUDD_CONST_INDEX && Cudd_IsConstant(cube)) return(cube); + if (index == CUDD_CONST_INDEX && Cudd_IsConstantInt(cube)) return(cube); constant = cuddUniqueConst(dd,-distance); if (constant == NULL) return(NULL); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddRead.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddRead.c similarity index 77% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddRead.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddRead.c index 713668fe2..dc49bf002 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddRead.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddRead.c @@ -1,22 +1,16 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddRead.c] + @ingroup cudd - PackageName [cudd] + @brief Functions to read in a matrix - Synopsis [Functions to read in a matrix] + @see cudd_addHarwell.c - Description [External procedures included in this module: - <ul> - <li> Cudd_addRead() - <li> Cudd_bddRead() - </ul>] + @author Fabio Somenzi - SeeAlso [cudd_addHarwell.c] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -46,9 +40,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -73,23 +68,18 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddRead.c,v 1.7 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -97,11 +87,10 @@ static char rcsid[] DD_UNUSED = "$Id: cuddRead.c,v 1.7 2012/02/05 01:07:19 fabio /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Reads in a sparse matrix. - Synopsis [Reads in a sparse matrix.] - - Description [Reads in a sparse matrix specified in a simple format. + @details Reads in a sparse matrix specified in a simple format. The first line of the input contains the numbers of rows and columns. The remaining lines contain the elements of the matrix, one per line. Given a background value @@ -109,7 +98,7 @@ static char rcsid[] DD_UNUSED = "$Id: cuddRead.c,v 1.7 2012/02/05 01:07:19 fabio different from it are explicitly listed. Each foreground element is described by two integers, i.e., the row and column number, and a real number, i.e., the value.<p> - Cudd_addRead produces an ADD that depends on two sets of variables: x + Cudd_addRead produces an %ADD that depends on two sets of variables: x and y. The x variables (x\[0\] ... x\[nx-1\]) encode the row index and the y variables (y\[0\] ... y\[ny-1\]) encode the column index. x\[0\] and y\[0\] are the most significant bits in the indices. @@ -125,36 +114,37 @@ static char rcsid[] DD_UNUSED = "$Id: cuddRead.c,v 1.7 2012/02/05 01:07:19 fabio existing y variables to be by+i*sy.<p> m and n are set to the numbers of rows and columns of the matrix. Their values on input are immaterial. - The ADD for the - sparse matrix is returned in E, and its reference count is > 0. - Cudd_addRead returns 1 in case of success; 0 otherwise.] + The %ADD for the sparse matrix is returned in E, and its reference + count is > 0. + + @return 1 in case of success; 0 otherwise. - SideEffects [nx and ny are set to the numbers of row and column + @sideeffect nx and ny are set to the numbers of row and column variables. m and n are set to the numbers of rows and columns. x and y are possibly extended to represent the array of row and column variables. Similarly for xn and yn_, which hold on return from - Cudd_addRead the complements of the row and column variables.] + Cudd_addRead the complements of the row and column variables. - SeeAlso [Cudd_addHarwell Cudd_bddRead] + @see Cudd_addHarwell Cudd_bddRead -******************************************************************************/ +*/ int Cudd_addRead( - FILE * fp /* input file pointer */, - DdManager * dd /* DD manager */, - DdNode ** E /* characteristic function of the graph */, - DdNode *** x /* array of row variables */, - DdNode *** y /* array of column variables */, - DdNode *** xn /* array of complemented row variables */, - DdNode *** yn_ /* array of complemented column variables */, - int * nx /* number or row variables */, - int * ny /* number or column variables */, - int * m /* number of rows */, - int * n /* number of columns */, - int bx /* first index of row variables */, - int sx /* step of row variables */, - int by /* first index of column variables */, - int sy /* step of column variables */) + FILE * fp /**< input file pointer */, + DdManager * dd /**< %DD manager */, + DdNode ** E /**< characteristic function of the graph */, + DdNode *** x /**< array of row variables */, + DdNode *** y /**< array of column variables */, + DdNode *** xn /**< array of complemented row variables */, + DdNode *** yn_ /**< array of complemented column variables */, + int * nx /**< number or row variables */, + int * ny /**< number or column variables */, + int * m /**< number of rows */, + int * n /**< number of columns */, + int bx /**< first index of row variables */, + int sx /**< step of row variables */, + int by /**< first index of column variables */, + int sy /**< step of column variables */) { DdNode *one, *zero; DdNode *w, *neW; @@ -226,13 +216,23 @@ Cudd_addRead( dd->reordered = 0; lx[i] = cuddUniqueInter(dd, nv, one, zero); } while (dd->reordered == 1); - if (lx[i] == NULL) return(0); + if (lx[i] == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(0); + } cuddRef(lx[i]); do { dd->reordered = 0; lxn[i] = cuddUniqueInter(dd, nv, zero, one); } while (dd->reordered == 1); - if (lxn[i] == NULL) return(0); + if (lxn[i] == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(0); + } cuddRef(lxn[i]); } for (i = *ny, nv = by + (*ny) * sy; i < lny; i++, nv += sy) { @@ -240,13 +240,23 @@ Cudd_addRead( dd->reordered = 0; ly[i] = cuddUniqueInter(dd, nv, one, zero); } while (dd->reordered == 1); - if (ly[i] == NULL) return(0); + if (ly[i] == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(0); + } cuddRef(ly[i]); do { dd->reordered = 0; lyn[i] = cuddUniqueInter(dd, nv, zero, one); } while (dd->reordered == 1); - if (lyn[i] == NULL) return(0); + if (lyn[i] == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(0); + } cuddRef(lyn[i]); } *nx = lnx; @@ -325,16 +335,15 @@ Cudd_addRead( } /* end of Cudd_addRead */ -/**Function******************************************************************** +/** + @brief Reads in a graph (without labels) given as a list of arcs. - Synopsis [Reads in a graph (without labels) given as a list of arcs.] - - Description [Reads in a graph (without labels) given as an adjacency + @details Reads in a graph (without labels) given as an adjacency matrix. The first line of the input contains the numbers of rows and columns of the adjacency matrix. The remaining lines contain the arcs of the graph, one per line. Each arc is described by two integers, i.e., the row and column number, or the indices of the two endpoints. - Cudd_bddRead produces a BDD that depends on two sets of variables: x + Cudd_bddRead produces a %BDD that depends on two sets of variables: x and y. The x variables (x\[0\] ... x\[nx-1\]) encode the row index and the y variables (y\[0\] ... y\[ny-1\]) encode the column index. x\[0\] and y\[0\] are the most significant bits in the @@ -349,33 +358,34 @@ Cudd_addRead( expects the indices of the existing x variables to be bx+i*sx, and the indices of the existing y variables to be by+i*sy.<p> m and n are set to the numbers of rows and columns of the - matrix. Their values on input are immaterial. The BDD for the graph - is returned in E, and its reference count is > 0. Cudd_bddRead returns - 1 in case of success; 0 otherwise.] + matrix. Their values on input are immaterial. The %BDD for the graph + is returned in E, and its reference count is > 0. + + @return 1 in case of success; 0 otherwise. - SideEffects [nx and ny are set to the numbers of row and column + @sideeffect nx and ny are set to the numbers of row and column variables. m and n are set to the numbers of rows and columns. x and y are possibly extended to represent the array of row and column - variables.] + variables. - SeeAlso [Cudd_addHarwell Cudd_addRead] + @see Cudd_addHarwell Cudd_addRead -******************************************************************************/ +*/ int Cudd_bddRead( - FILE * fp /* input file pointer */, - DdManager * dd /* DD manager */, - DdNode ** E /* characteristic function of the graph */, - DdNode *** x /* array of row variables */, - DdNode *** y /* array of column variables */, - int * nx /* number or row variables */, - int * ny /* number or column variables */, - int * m /* number of rows */, - int * n /* number of columns */, - int bx /* first index of row variables */, - int sx /* step of row variables */, - int by /* first index of column variables */, - int sy /* step of column variables */) + FILE * fp /**< input file pointer */, + DdManager * dd /**< DD manager */, + DdNode ** E /**< characteristic function of the graph */, + DdNode *** x /**< array of row variables */, + DdNode *** y /**< array of column variables */, + int * nx /**< number or row variables */, + int * ny /**< number or column variables */, + int * m /**< number of rows */, + int * n /**< number of columns */, + int bx /**< first index of row variables */, + int sx /**< step of row variables */, + int by /**< first index of column variables */, + int sy /**< step of column variables */) { DdNode *one, *zero; DdNode *w; @@ -430,7 +440,12 @@ Cudd_bddRead( dd->reordered = 0; lx[i] = cuddUniqueInter(dd, nv, one, zero); } while (dd->reordered == 1); - if (lx[i] == NULL) return(0); + if (lx[i] == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(0); + } cuddRef(lx[i]); } for (i = *ny, nv = by + (*ny) * sy; i < lny; i++, nv += sy) { @@ -438,7 +453,12 @@ Cudd_bddRead( dd->reordered = 0; ly[i] = cuddUniqueInter(dd, nv, one, zero); } while (dd->reordered == 1); - if (ly[i] == NULL) return(0); + if (ly[i] == NULL) { + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + return(0); + } cuddRef(ly[i]); } *nx = lnx; diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddRef.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddRef.c similarity index 66% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddRef.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddRef.c index 457d71442..53dee8eec 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddRef.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddRef.c @@ -1,37 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddRef.c] + @ingroup cudd - PackageName [cudd] + @brief Functions that manipulate the reference counts. - Synopsis [Functions that manipulate the reference counts.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_Ref() - <li> Cudd_RecursiveDeref() - <li> Cudd_IterDerefBdd() - <li> Cudd_DelayedDerefBdd() - <li> Cudd_RecursiveDerefZdd() - <li> Cudd_Deref() - <li> Cudd_CheckZeroRef() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddReclaim() - <li> cuddReclaimZdd() - <li> cuddClearDeathRow() - <li> cuddShrinkDeathRow() - <li> cuddIsInDeathRow() - <li> cuddTimesInDeathRow() - </ul> - ] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -61,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -87,40 +65,33 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddRef.c,v 1.29 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Increases the reference count of a node, if it is not - saturated.] +/** + @brief Increases the reference count of a node, if it is not + saturated. - Description [] + @sideeffect None - SideEffects [None] + @see Cudd_RecursiveDeref Cudd_Deref - SeeAlso [Cudd_RecursiveDeref Cudd_Deref] - -******************************************************************************/ +*/ void Cudd_Ref( DdNode * n) @@ -133,19 +104,18 @@ Cudd_Ref( } /* end of Cudd_Ref */ -/**Function******************************************************************** - - Synopsis [Decreases the reference count of node n.] +/** + @brief Decreases the reference count of node n. - Description [Decreases the reference count of node n. If n dies, - recursively decreases the reference counts of its children. It is - used to dispose of a DD that is no longer needed.] + @details If n dies, recursively decreases the reference counts of + its children. It is used to dispose of a DD that is no longer + needed. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Deref Cudd_Ref Cudd_RecursiveDerefZdd] + @see Cudd_Deref Cudd_Ref Cudd_RecursiveDerefZdd -******************************************************************************/ +*/ void Cudd_RecursiveDeref( DdManager * table, @@ -192,23 +162,21 @@ Cudd_RecursiveDeref( } /* end of Cudd_RecursiveDeref */ -/**Function******************************************************************** - - Synopsis [Decreases the reference count of BDD node n.] +/** + @brief Decreases the reference count of %BDD node n. - Description [Decreases the reference count of node n. If n dies, - recursively decreases the reference counts of its children. It is - used to dispose of a BDD that is no longer needed. It is more - efficient than Cudd_RecursiveDeref, but it cannot be used on - ADDs. The greater efficiency comes from being able to assume that no - constant node will ever die as a result of a call to this - procedure.] + @details If n dies, recursively decreases the reference counts of + its children. It is used to dispose of a %BDD that is no longer + needed. It is more efficient than Cudd_RecursiveDeref, but it cannot + be used on ADDs. The greater efficiency comes from being able to + assume that no constant node will ever die as a result of a call to + this procedure. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_RecursiveDeref Cudd_DelayedDerefBdd] + @see Cudd_RecursiveDeref Cudd_DelayedDerefBdd -******************************************************************************/ +*/ void Cudd_IterDerefBdd( DdManager * table, @@ -250,22 +218,21 @@ Cudd_IterDerefBdd( } /* end of Cudd_IterDerefBdd */ -/**Function******************************************************************** +/** + @brief Decreases the reference count of %BDD node n. - Synopsis [Decreases the reference count of BDD node n.] - - Description [Enqueues node n for later dereferencing. If the queue + @details Enqueues node n for later dereferencing. If the queue is full decreases the reference count of the oldest node N to make room for n. If N dies, recursively decreases the reference counts of - its children. It is used to dispose of a BDD that is currently not + its children. It is used to dispose of a %BDD that is currently not needed, but may be useful again in the near future. The dereferencing - proper is done as in Cudd_IterDerefBdd.] + proper is done as in Cudd_IterDerefBdd. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_RecursiveDeref Cudd_IterDerefBdd] + @see Cudd_RecursiveDeref Cudd_IterDerefBdd -******************************************************************************/ +*/ void Cudd_DelayedDerefBdd( DdManager * table, @@ -335,10 +302,10 @@ Cudd_DelayedDerefBdd( #if 0 if (table->nextDead == table->deathRowDepth) { if (table->deathRowDepth < table->looseUpTo / 2) { - extern void (*MMoutOfMemory)(long); - void (*saveHandler)(long) = MMoutOfMemory; + extern void (*MMoutOfMemory)(size_t); + void (*saveHandler)(size_t) = MMoutOfMemory; DdNodePtr *newRow; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = table->outOfMemCallback; newRow = REALLOC(DdNodePtr,table->deathRow,2*table->deathRowDepth); MMoutOfMemory = saveHandler; if (newRow == NULL) { @@ -364,19 +331,18 @@ Cudd_DelayedDerefBdd( } /* end of Cudd_DelayedDerefBdd */ -/**Function******************************************************************** - - Synopsis [Decreases the reference count of ZDD node n.] +/** + @brief Decreases the reference count of %ZDD node n. - Description [Decreases the reference count of ZDD node n. If n dies, - recursively decreases the reference counts of its children. It is - used to dispose of a ZDD that is no longer needed.] + @details If n dies, recursively decreases the reference counts of + its children. It is used to dispose of a %ZDD that is no longer + needed. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Deref Cudd_Ref Cudd_RecursiveDeref] + @see Cudd_Deref Cudd_Ref Cudd_RecursiveDeref -******************************************************************************/ +*/ void Cudd_RecursiveDerefZdd( DdManager * table, @@ -416,20 +382,19 @@ Cudd_RecursiveDerefZdd( } /* end of Cudd_RecursiveDerefZdd */ -/**Function******************************************************************** - - Synopsis [Decreases the reference count of node.] +/** + @brief Decreases the reference count of node. - Description [Decreases the reference count of node. It is primarily - used in recursive procedures to decrease the ref count of a result - node before returning it. This accomplishes the goal of removing the - protection applied by a previous Cudd_Ref.] + @details It is primarily used in recursive procedures to decrease + the ref count of a result node before returning it. This + accomplishes the goal of removing the protection applied by a + previous Cudd_Ref. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_RecursiveDeref Cudd_RecursiveDerefZdd Cudd_Ref] + @see Cudd_RecursiveDeref Cudd_RecursiveDerefZdd Cudd_Ref -******************************************************************************/ +*/ void Cudd_Deref( DdNode * node) @@ -440,24 +405,22 @@ Cudd_Deref( } /* end of Cudd_Deref */ -/**Function******************************************************************** +/** + @brief Checks the unique table for nodes with non-zero reference + counts. - Synopsis [Checks the unique table for nodes with non-zero reference - counts.] - - Description [Checks the unique table for nodes with non-zero - reference counts. It is normally called before Cudd_Quit to make sure - that there are no memory leaks due to missing Cudd_RecursiveDeref's. + @details It is normally called before Cudd_Quit to make sure that + there are no memory leaks due to missing Cudd_RecursiveDeref's. Takes into account that reference counts may saturate and that the basic constants and the projection functions are referenced by the - manager. Returns the number of nodes with non-zero reference count. - (Except for the cases mentioned above.)] + manager. - SideEffects [None] + @return the number of nodes with non-zero reference count. + (Except for the cases mentioned above.) - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Cudd_CheckZeroRef( DdManager * manager) @@ -565,17 +528,14 @@ Cudd_CheckZeroRef( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Brings children of a dead node back.] - - Description [] +/** + @brief Brings children of a dead node back. - SideEffects [None] + @sideeffect None - SeeAlso [cuddReclaimZdd] + @see cuddReclaimZdd -******************************************************************************/ +*/ void cuddReclaim( DdManager * table, @@ -619,17 +579,14 @@ cuddReclaim( } /* end of cuddReclaim */ -/**Function******************************************************************** +/** + @brief Brings children of a dead %ZDD node back. - Synopsis [Brings children of a dead ZDD node back.] + @sideeffect None - Description [] + @see cuddReclaim - SideEffects [None] - - SeeAlso [cuddReclaim] - -******************************************************************************/ +*/ void cuddReclaimZdd( DdManager * table, @@ -669,17 +626,16 @@ cuddReclaimZdd( } /* end of cuddReclaimZdd */ -/**Function******************************************************************** - - Synopsis [Shrinks the death row.] +/** + @brief Shrinks the death row. - Description [Shrinks the death row by a factor of four.] + @details Shrinks the death row by a factor of four. - SideEffects [None] + @sideeffect None - SeeAlso [cuddClearDeathRow] + @see cuddClearDeathRow -******************************************************************************/ +*/ void cuddShrinkDeathRow( DdManager *table) @@ -706,18 +662,15 @@ cuddShrinkDeathRow( } /* end of cuddShrinkDeathRow */ -/**Function******************************************************************** +/** + @brief Clears the death row. - Synopsis [Clears the death row.] + @sideeffect None - Description [] + @see Cudd_DelayedDerefBdd Cudd_IterDerefBdd Cudd_CheckZeroRef + cuddGarbageCollect - SideEffects [None] - - SeeAlso [Cudd_DelayedDerefBdd Cudd_IterDerefBdd Cudd_CheckZeroRef - cuddGarbageCollect] - -******************************************************************************/ +*/ void cuddClearDeathRow( DdManager *table) @@ -741,19 +694,17 @@ cuddClearDeathRow( } /* end of cuddClearDeathRow */ -/**Function******************************************************************** - - Synopsis [Checks whether a node is in the death row.] +/** + @brief Checks whether a node is in the death row. - Description [Checks whether a node is in the death row. Returns the - position of the first occurrence if the node is present; -1 - otherwise.] + @return the position of the first occurrence if the node is present; + -1 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_DelayedDerefBdd cuddClearDeathRow] + @see Cudd_DelayedDerefBdd cuddClearDeathRow -******************************************************************************/ +*/ int cuddIsInDeathRow( DdManager *dd, @@ -774,17 +725,14 @@ cuddIsInDeathRow( } /* end of cuddIsInDeathRow */ -/**Function******************************************************************** - - Synopsis [Counts how many times a node is in the death row.] - - Description [] +/** + @brief Counts how many times a node is in the death row. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_DelayedDerefBdd cuddClearDeathRow cuddIsInDeathRow] + @see Cudd_DelayedDerefBdd cuddClearDeathRow cuddIsInDeathRow -******************************************************************************/ +*/ int cuddTimesInDeathRow( DdManager *dd, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddReorder.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddReorder.c similarity index 74% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddReorder.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddReorder.c index 13932d801..267cc54b0 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddReorder.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddReorder.c @@ -1,44 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddReorder.c] - - PackageName [cudd] - - Synopsis [Functions for dynamic variable reordering.] - - Description [External procedures included in this file: - <ul> - <li> Cudd_ReduceHeap() - <li> Cudd_ShuffleHeap() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddDynamicAllocNode() - <li> cuddSifting() - <li> cuddSwapping() - <li> cuddNextHigh() - <li> cuddNextLow() - <li> cuddSwapInPlace() - <li> cuddBddAlignToZdd() - </ul> - Static procedures included in this module: - <ul> - <li> ddUniqueCompare() - <li> ddSwapAny() - <li> ddSiftingAux() - <li> ddSiftingUp() - <li> ddSiftingDown() - <li> ddSiftingBackward() - <li> ddReorderPreprocess() - <li> ddReorderPostprocess() - <li> ddShuffle() - <li> ddSiftUp() - <li> bddFixTree() - </ul>] - - Author [Shipra Panda, Bernard Plessier, Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Functions for dynamic variable reordering. + + @author Shipra Panda, Bernard Plessier, Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -68,21 +38,19 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" +#include "mtrInt.h" #include "cuddInt.h" -#include "ucbqsort.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ /*---------------------------------------------------------------------------*/ -#define DD_MAX_SUBTABLE_SPARSITY 8 -#define DD_SHRINK_FACTOR 2 - /*---------------------------------------------------------------------------*/ /* Stucture declarations */ /*---------------------------------------------------------------------------*/ @@ -95,28 +63,17 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddReorder.c,v 1.71 2012/02/05 01:07:19 fabio Exp $"; -#endif - -static int *entry; - -int ddTotalNumberSwapping; -#ifdef DD_STATS -int ddTotalNISwaps; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ -static int ddUniqueCompare (int *ptrX, int *ptrY); +static int ddUniqueCompare (void const *ptrX, void const *ptrY); static Move * ddSwapAny (DdManager *table, int x, int y); static int ddSiftingAux (DdManager *table, int x, int xLow, int xHigh); static Move * ddSiftingUp (DdManager *table, int y, int xLow); @@ -130,7 +87,7 @@ static void bddFixTree (DdManager *table, MtrNode *treenode); static int ddUpdateMtrTree (DdManager *table, MtrNode *treenode, int *perm, int *invperm); static int ddCheckPermuation (DdManager *table, MtrNode *treenode, int *perm, int *invperm); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -138,12 +95,10 @@ static int ddCheckPermuation (DdManager *table, MtrNode *treenode, int *perm, in /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Main dynamic reordering routine.] +/** + @brief Main dynamic reordering routine. - Description [Main dynamic reordering routine. - Calls one of the possible reordering procedures: + @details Calls one of the possible reordering procedures: <ul> <li>Swapping <li>Sifting @@ -154,26 +109,25 @@ static int ddCheckPermuation (DdManager *table, MtrNode *treenode, int *perm, in <li>Genetic Algorithm <li>Dynamic Programming (exact) </ul> - For sifting, symmetric sifting, group sifting, and window permutation it is possible to request reordering to convergence.<p> - The core of all methods is the reordering procedure cuddSwapInPlace() which swaps two adjacent variables and is based on Rudell's paper. - Returns 1 in case of success; 0 otherwise. In the case of symmetric + + @return 1 in case of success; 0 otherwise. In the case of symmetric sifting (with and without convergence) returns 1 plus the number of - symmetric variables, in case of success.] + symmetric variables, in case of success. - SideEffects [Changes the variable order for all diagrams and clears - the cache.] + @sideeffect Changes the variable order for all diagrams and clears + the cache. -******************************************************************************/ +*/ int Cudd_ReduceHeap( - DdManager * table /* DD manager */, - Cudd_ReorderingType heuristic /* method used for reordering */, - int minsize /* bound below which no reordering occurs */) + DdManager * table /**< %DD manager */, + Cudd_ReorderingType heuristic /**< method used for reordering */, + int minsize /**< bound below which no reordering occurs */) { DdHook *hook; int result; @@ -211,14 +165,14 @@ Cudd_ReduceHeap( } if (!ddReorderPreprocess(table)) return(0); - ddTotalNumberSwapping = 0; + table->ddTotalNumberSwapping = 0; if (table->keys > table->peakLiveNodes) { table->peakLiveNodes = table->keys; } #ifdef DD_STATS - initialSize = table->keys - table->isolated; - ddTotalNISwaps = 0; + initialSize = (int) (table->keys - table->isolated); + table->totalNISwaps = 0; switch(heuristic) { case CUDD_REORDER_RANDOM: @@ -272,13 +226,14 @@ Cudd_ReduceHeap( #ifdef DD_STATS (void) fprintf(table->out,"\n"); - finalSize = table->keys - table->isolated; + finalSize = (int) (table->keys - table->isolated); (void) fprintf(table->out,"#:F_REORDER %8d: final size\n",finalSize); (void) fprintf(table->out,"#:T_REORDER %8g: total time (sec)\n", ((double)(util_cpu_time() - localTime)/1000.0)); (void) fprintf(table->out,"#:N_REORDER %8d: total swaps\n", - ddTotalNumberSwapping); - (void) fprintf(table->out,"#:M_REORDER %8d: NI swaps\n",ddTotalNISwaps); + table->ddTotalNumberSwapping); + (void) fprintf(table->out,"#:M_REORDER %8d: NI swaps\n", + table->totalNISwaps); #endif if (result == 0) @@ -299,14 +254,14 @@ Cudd_ReduceHeap( else table->nextDyn += 20; if (table->randomizeOrder != 0) { - table->nextDyn += Cudd_Random() & table->randomizeOrder; + table->nextDyn += Cudd_Random(table) & table->randomizeOrder; } table->reordered = 1; /* Run hook functions. */ hook = table->postReorderingHook; while (hook != NULL) { - int res = (hook->f)(table, "BDD", (void *)localTime); + int res = (hook->f)(table, "BDD", (void *)(ptruint)localTime); if (res == 0) return(0); hook = hook->next; } @@ -318,26 +273,26 @@ Cudd_ReduceHeap( } /* end of Cudd_ReduceHeap */ -/**Function******************************************************************** +/** + @brief Reorders variables according to given permutation. - Synopsis [Reorders variables according to given permutation.] + @details The i-th entry of the permutation array contains the index + of the variable that should be brought to the i-th level. The size + of the array should be equal or greater to the number of variables + currently in use. - Description [Reorders variables according to given permutation. - The i-th entry of the permutation array contains the index of the variable - that should be brought to the i-th level. The size of the array should be - equal or greater to the number of variables currently in use. - Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [Changes the variable order for all diagrams and clears - the cache.] + @sideeffect Changes the variable order for all diagrams and clears + the cache. - SeeAlso [Cudd_ReduceHeap] + @see Cudd_ReduceHeap -******************************************************************************/ +*/ int Cudd_ShuffleHeap( - DdManager * table /* DD manager */, - int * permutation /* required variable permutation */) + DdManager * table /**< %DD manager */, + int * permutation /**< required variable permutation */) { int result; @@ -387,21 +342,21 @@ Cudd_ShuffleHeap( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Dynamically allocates a Node. - Synopsis [Dynamically allocates a Node.] + @details This procedure is similar to cuddAllocNode in Cudd_Table.c, + but it does not attempt garbage collection, because during + reordering there are no dead nodes. - Description [Dynamically allocates a Node. This procedure is similar - to cuddAllocNode in Cudd_Table.c, but it does not attempt garbage - collection, because during reordering there are no dead nodes. - Returns a pointer to a new node if successful; NULL is memory is - full.] + @return a pointer to a new node if successful; NULL is memory is + full. - SideEffects [None] + @sideeffect None - SeeAlso [cuddAllocNode] + @see cuddAllocNode -******************************************************************************/ +*/ DdNode * cuddDynamicAllocNode( DdManager * table) @@ -415,7 +370,7 @@ cuddDynamicAllocNode( if (table->nextFree == NULL) { /* free list is empty */ /* Try to allocate a new block. */ saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = table->outOfMemCallback; mem = (DdNodePtr *) ALLOC(DdNode, DD_MEM_CHUNK + 1); MMoutOfMemory = saveHandler; if (mem == NULL && table->stash != NULL) { @@ -444,7 +399,7 @@ cuddDynamicAllocNode( #endif return(NULL); } else { /* successful allocation; slice memory */ - unsigned long offset; + size_t offset; table->memused += (DD_MEM_CHUNK + 1) * sizeof(DdNode); mem[0] = (DdNode *) table->memoryList; table->memoryList = mem; @@ -453,10 +408,10 @@ cuddDynamicAllocNode( ** power of 2 and a multiple of the size of a pointer. ** If we align one node, all the others will be aligned ** as well. */ - offset = (unsigned long) mem & (sizeof(DdNode) - 1); + offset = (size_t) mem & (sizeof(DdNode) - 1); mem += (sizeof(DdNode) - offset) / sizeof(DdNodePtr); #ifdef DD_DEBUG - assert(((unsigned long) mem & (sizeof(DdNode) - 1)) == 0); + assert(((size_t) mem & (sizeof(DdNode) - 1)) == 0); #endif list = (DdNode *) mem; @@ -480,25 +435,24 @@ cuddDynamicAllocNode( } /* end of cuddDynamicAllocNode */ -/**Function******************************************************************** +/** + @brief Implementation of Rudell's sifting algorithm. - Synopsis [Implementation of Rudell's sifting algorithm.] - - Description [Implementation of Rudell's sifting algorithm. - Assumes that no dead nodes are present. + @details Assumes that no dead nodes are present. <ol> <li> Order all the variables according to the number of entries in each unique table. <li> Sift the variable up and down, remembering each time the - total size of the DD heap. + total size of the %DD heap. <li> Select the best permutation. <li> Repeat 3 and 4 for all variables. </ol> - Returns 1 if successful; 0 otherwise.] - SideEffects [None] + @return 1 if successful; 0 otherwise. + + @sideeffect None -******************************************************************************/ +*/ int cuddSifting( DdManager * table, @@ -506,7 +460,7 @@ cuddSifting( int upper) { int i; - int *var; + IndexKey *var; int size; int x; int result; @@ -517,13 +471,7 @@ cuddSifting( size = table->size; /* Find order in which to sift variables. */ - var = NULL; - entry = ALLOC(int,size); - if (entry == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - goto cuddSiftingOutOfMem; - } - var = ALLOC(int,size); + var = ALLOC(IndexKey,size); if (var == NULL) { table->errorCode = CUDD_MEMORY_OUT; goto cuddSiftingOutOfMem; @@ -531,27 +479,32 @@ cuddSifting( for (i = 0; i < size; i++) { x = table->perm[i]; - entry[i] = table->subtables[x].keys; - var[i] = i; + var[i].index = i; + var[i].keys = table->subtables[x].keys; } - cudd__qsort((void *)var,size,sizeof(int),(DD_QSFP)ddUniqueCompare); + util_qsort(var,size,sizeof(IndexKey),ddUniqueCompare); /* Now sift. */ for (i = 0; i < ddMin(table->siftMaxVar,size); i++) { - if (ddTotalNumberSwapping >= table->siftMaxSwap) + if (table->ddTotalNumberSwapping >= table->siftMaxSwap) break; if (util_cpu_time() - table->startTime + table->reordTime > table->timeLimit) { table->autoDyn = 0; /* prevent further reordering */ break; } - x = table->perm[var[i]]; + if (table->terminationCallback != NULL && + table->terminationCallback(table->tcbArg)) { + table->autoDyn = 0; /* prevent further reordering */ + break; + } + x = table->perm[var[i].index]; if (x < lower || x > upper || table->subtables[x].bindVar == 1) continue; #ifdef DD_STATS - previousSize = table->keys - table->isolated; + previousSize = (int) (table->keys - table->isolated); #endif result = ddSiftingAux(table, x, lower, upper); if (!result) goto cuddSiftingOutOfMem; @@ -560,7 +513,7 @@ cuddSifting( (void) fprintf(table->out,"-"); } else if (table->keys > (unsigned) previousSize + table->isolated) { (void) fprintf(table->out,"+"); /* should never happen */ - (void) fprintf(table->err,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keys - table->isolated, var[i]); + (void) fprintf(table->err,"\nSize increased from %d to %u while sifting variable %d\n", previousSize, table->keys - table->isolated, var[i].index); } else { (void) fprintf(table->out,"="); } @@ -569,13 +522,11 @@ cuddSifting( } FREE(var); - FREE(entry); return(1); cuddSiftingOutOfMem: - if (entry != NULL) FREE(entry); if (var != NULL) FREE(var); return(0); @@ -583,11 +534,10 @@ cuddSiftingOutOfMem: } /* end of cuddSifting */ -/**Function******************************************************************** +/** + @brief Reorders variables by a sequence of (non-adjacent) swaps. - Synopsis [Reorders variables by a sequence of (non-adjacent) swaps.] - - Description [Implementation of Plessier's algorithm that reorders + @details Implementation of Plessier's algorithm that reorders variables by a sequence of (non-adjacent) swaps. <ol> <li> Select two variables (RANDOM or HEURISTIC). @@ -596,11 +546,12 @@ cuddSiftingOutOfMem: <li> Otherwise reconstruct the original heap. <li> Loop. </ol> - Returns 1 in case of success; 0 otherwise.] - SideEffects [None] + @return 1 in case of success; 0 otherwise. + + @sideeffect None -******************************************************************************/ +*/ int cuddSwapping( DdManager * table, @@ -615,7 +566,7 @@ cuddSwapping( int iterate; int previousSize; Move *moves, *move; - int pivot; + int pivot = 0; int modulo; int result; @@ -628,7 +579,7 @@ cuddSwapping( iterate = nvars; for (i = 0; i < iterate; i++) { - if (ddTotalNumberSwapping >= table->siftMaxSwap) + if (table->ddTotalNumberSwapping >= table->siftMaxSwap) break; if (heuristic == CUDD_REORDER_RANDOM_PIVOT) { max = -1; @@ -643,7 +594,7 @@ cuddSwapping( if (modulo == 0) { y = pivot; } else{ - y = pivot + 1 + ((int) Cudd_Random() % modulo); + y = pivot + 1 + ((int) Cudd_Random(table) % modulo); } modulo = pivot - lower - 1; @@ -651,16 +602,16 @@ cuddSwapping( x = lower; } else{ do { - x = (int) Cudd_Random() % modulo; + x = (int) Cudd_Random(table) % modulo; } while (x == y); } } else { - x = ((int) Cudd_Random() % nvars) + lower; + x = ((int) Cudd_Random(table) % nvars) + lower; do { - y = ((int) Cudd_Random() % nvars) + lower; + y = ((int) Cudd_Random(table) % nvars) + lower; } while (x == y); } - previousSize = table->keys - table->isolated; + previousSize = (int) (table->keys - table->isolated); moves = ddSwapAny(table,x,y); if (moves == NULL) goto cuddSwappingOutOfMem; result = ddSiftingBackward(table,previousSize,moves); @@ -700,63 +651,60 @@ cuddSwappingOutOfMem: } /* end of cuddSwapping */ -/**Function******************************************************************** - - Synopsis [Finds the next subtable with a larger index.] +/** + @brief Finds the next subtable with a larger index. - Description [Finds the next subtable with a larger index. Returns the - index.] + @return the index. - SideEffects [None] + @sideeffect None - SeeAlso [cuddNextLow] + @see cuddNextLow -******************************************************************************/ +*/ int cuddNextHigh( DdManager * table, int x) { + (void) table; /* avoid warning */ return(x+1); } /* end of cuddNextHigh */ -/**Function******************************************************************** +/** + @brief Finds the next subtable with a smaller index. - Synopsis [Finds the next subtable with a smaller index.] + @return the index. - Description [Finds the next subtable with a smaller index. Returns the - index.] + @sideeffect None - SideEffects [None] + @see cuddNextHigh - SeeAlso [cuddNextHigh] - -******************************************************************************/ +*/ int cuddNextLow( DdManager * table, int x) { + (void) table; /* avoid warning */ return(x-1); } /* end of cuddNextLow */ -/**Function******************************************************************** +/** + @brief Swaps two adjacent variables. - Synopsis [Swaps two adjacent variables.] + @details It assumes that no dead nodes are present on entry to this + procedure. The procedure then guarantees that no dead nodes will be + present when it terminates. cuddSwapInPlace assumes that x < y. - Description [Swaps two adjacent variables. It assumes that no dead - nodes are present on entry to this procedure. The procedure then - guarantees that no dead nodes will be present when it terminates. - cuddSwapInPlace assumes that x < y. Returns the number of keys in - the table if successful; 0 otherwise.] + @return the number of keys in the table if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ int cuddSwapInPlace( DdManager * table, @@ -796,7 +744,7 @@ cuddSwapInPlace( assert(table->subtables[y].dead == 0); #endif - ddTotalNumberSwapping++; + table->ddTotalNumberSwapping++; /* Get parameters of x subtable. */ xindex = table->invperm[x]; @@ -814,7 +762,7 @@ cuddSwapInPlace( if (!cuddTestInteract(table,xindex,yindex)) { #ifdef DD_STATS - ddTotalNISwaps++; + table->totalNISwaps++; #endif newxkeys = oldxkeys; newykeys = oldykeys; @@ -899,14 +847,11 @@ cuddSwapInPlace( } /* Try to allocate new table. Be ready to back off. */ saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = table->outOfMemCallback; newxlist = ALLOC(DdNodePtr, newxslots); MMoutOfMemory = saveHandler; if (newxlist == NULL) { (void) fprintf(table->err, "Unable to resize subtable %d for lack of memory\n", i); - newxlist = xlist; - newxslots = xslots; - newxshift = xshift; } else { table->slots += ((int) newxslots - xslots); table->minDead = (unsigned) @@ -1177,7 +1122,7 @@ cuddSwapInPlace( isolated += (table->vars[xindex]->ref == 1) + (table->vars[yindex]->ref == 1); - table->isolated += isolated; + table->isolated += (unsigned int) isolated; } /* Set the appropriate fields in table. */ @@ -1189,7 +1134,7 @@ cuddSwapInPlace( i = table->subtables[x].bindVar; table->subtables[x].bindVar = table->subtables[y].bindVar; table->subtables[y].bindVar = i; - /* Adjust filds for lazy sifting. */ + /* Adjust fields for lazy sifting. */ varType = table->subtables[x].varType; table->subtables[x].varType = table->subtables[y].varType; table->subtables[y].varType = varType; @@ -1214,7 +1159,7 @@ cuddSwapInPlace( table->keys += newxkeys + newykeys - oldxkeys - oldykeys; - return(table->keys - table->isolated); + return((int)(table->keys - table->isolated)); cuddSwapOutOfMem: (void) fprintf(table->err,"Error: cuddSwapInPlace out of memory\n"); @@ -1224,32 +1169,31 @@ cuddSwapOutOfMem: } /* end of cuddSwapInPlace */ -/**Function******************************************************************** - - Synopsis [Reorders BDD variables according to the order of the ZDD - variables.] +/** + @brief Reorders %BDD variables according to the order of the %ZDD + variables. - Description [Reorders BDD variables according to the order of the - ZDD variables. This function can be called at the end of ZDD - reordering to insure that the order of the BDD variables is - consistent with the order of the ZDD variables. The number of ZDD - variables must be a multiple of the number of BDD variables. Let + @details This function can be called at the end of %ZDD + reordering to insure that the order of the %BDD variables is + consistent with the order of the %ZDD variables. The number of %ZDD + variables must be a multiple of the number of %BDD variables. Let <code>M</code> be the ratio of the two numbers. cuddBddAlignToZdd - then considers the ZDD variables from <code>M*i</code> to - <code>(M+1)*i-1</code> as corresponding to BDD variable + then considers the %ZDD variables from <code>M*i</code> to + <code>(M+1)*i-1</code> as corresponding to %BDD variable <code>i</code>. This function should be normally called from - Cudd_zddReduceHeap, which clears the cache. Returns 1 in case of - success; 0 otherwise.] + Cudd_zddReduceHeap, which clears the cache. + + @return 1 in case of success; 0 otherwise. - SideEffects [Changes the BDD variable order for all diagrams and performs - garbage collection of the BDD unique table.] + @sideeffect Changes the %BDD variable order for all diagrams and performs + garbage collection of the %BDD unique table. - SeeAlso [Cudd_ShuffleHeap Cudd_zddReduceHeap] + @see Cudd_ShuffleHeap Cudd_zddReduceHeap -******************************************************************************/ +*/ int cuddBddAlignToZdd( - DdManager * table /* DD manager */) + DdManager * table /**< %DD manager */) { int *invperm; /* permutation array */ int M; /* ratio of ZDD variables to BDD variables */ @@ -1307,42 +1251,47 @@ cuddBddAlignToZdd( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Comparison function used by qsort. - Synopsis [Comparison function used by qsort.] + @details Used to order the variables according to the number of keys + in the subtables. - Description [Comparison function used by qsort to order the - variables according to the number of keys in the subtables. - Returns the difference in number of keys between the two - variables being compared.] + @return the difference in number of keys between the two variables + being compared. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddUniqueCompare( - int * ptrX, - int * ptrY) + void const * ptrX, + void const * ptrY) { + IndexKey const * pX = (IndexKey const *) ptrX; + IndexKey const * pY = (IndexKey const *) ptrY; #if 0 - if (entry[*ptrY] == entry[*ptrX]) { - return((*ptrX) - (*ptrY)); + /* This would make the order stable, which would be good because of + * it would platform-independent, but instability often produces + * smaller BDDs. + */ + if (pY->keys == pX->keys) { + return(pX->index - pY->index); } #endif - return(entry[*ptrY] - entry[*ptrX]); + return(pY->keys - pX->keys); } /* end of ddUniqueCompare */ -/**Function******************************************************************** +/** + @brief Swaps any two variables. - Synopsis [Swaps any two variables.] + @return the set of moves. - Description [Swaps any two variables. Returns the set of moves.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static Move * ddSwapAny( DdManager * table, @@ -1365,7 +1314,7 @@ ddSwapAny( xNext = cuddNextHigh(table,x); yNext = cuddNextLow(table,y); moves = NULL; - limitSize = table->keys - table->isolated; + limitSize = (int) (table->keys - table->isolated); for (;;) { if ( xNext == yNext) { @@ -1472,18 +1421,17 @@ ddSwapAnyOutOfMem: } /* end of ddSwapAny */ -/**Function******************************************************************** +/** + @brief Given xLow <= x <= xHigh moves x up and down between the + boundaries. - Synopsis [Given xLow <= x <= xHigh moves x up and down between the - boundaries.] + @details Finds the best position and does the required changes. - Description [Given xLow <= x <= xHigh moves x up and down between the - boundaries. Finds the best position and does the required changes. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddSiftingAux( DdManager * table, @@ -1498,7 +1446,7 @@ ddSiftingAux( int initialSize; int result; - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveDown = NULL; moveUp = NULL; @@ -1580,17 +1528,17 @@ ddSiftingAuxOutOfMem: } /* end of ddSiftingAux */ -/**Function******************************************************************** +/** + @brief Sifts a variable up. - Synopsis [Sifts a variable up.] + @details Moves y up until either it reaches the bound (xLow) or the + size of the %DD heap increases too much. - Description [Sifts a variable up. Moves y up until either it reaches - the bound (xLow) or the size of the DD heap increases too much. - Returns the set of moves in case of success; NULL if memory is full.] + @return the set of moves in case of success; NULL if memory is full. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static Move * ddSiftingUp( DdManager * table, @@ -1620,7 +1568,7 @@ ddSiftingUp( ** change. The rest may vanish in the best case, except for ** the nodes at level xLow, which will not vanish, regardless. */ - limitSize = L = table->keys - table->isolated; + limitSize = L = (int) (table->keys - table->isolated); for (x = xLow + 1; x < y; x++) { xindex = table->invperm[x]; if (cuddTestInteract(table,xindex,yindex)) { @@ -1629,22 +1577,22 @@ ddSiftingUp( } } isolated = table->vars[yindex]->ref == 1; - L -= table->subtables[y].keys - isolated; + L -= (int) table->subtables[y].keys - isolated; x = cuddNextLow(table,y); while (x >= xLow && L <= limitSize) { xindex = table->invperm[x]; #ifdef DD_DEBUG - checkL = table->keys - table->isolated; + checkL = (int) (table->keys - table->isolated); for (z = xLow + 1; z < y; z++) { zindex = table->invperm[z]; if (cuddTestInteract(table,zindex,yindex)) { isolated = table->vars[zindex]->ref == 1; - checkL -= table->subtables[z].keys - isolated; + checkL -= (int) table->subtables[z].keys - isolated; } } isolated = table->vars[yindex]->ref == 1; - checkL -= table->subtables[y].keys - isolated; + checkL -= (int) table->subtables[y].keys - isolated; assert(L == checkL); #endif size = cuddSwapInPlace(table,x,y); @@ -1652,7 +1600,7 @@ ddSiftingUp( /* Update the lower bound. */ if (cuddTestInteract(table,xindex,yindex)) { isolated = table->vars[xindex]->ref == 1; - L += table->subtables[y].keys - isolated; + L += (int) table->subtables[y].keys - isolated; } move = (Move *) cuddDynamicAllocNode(table); if (move == NULL) goto ddSiftingUpOutOfMem; @@ -1679,18 +1627,17 @@ ddSiftingUpOutOfMem: } /* end of ddSiftingUp */ -/**Function******************************************************************** +/** + @brief Sifts a variable down. - Synopsis [Sifts a variable down.] + @details Moves x down until either it reaches the bound (xHigh) or + the size of the %DD heap increases too much. - Description [Sifts a variable down. Moves x down until either it - reaches the bound (xHigh) or the size of the DD heap increases too - much. Returns the set of moves in case of success; NULL if memory is - full.] + @return the set of moves in case of success; NULL if memory is full. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static Move * ddSiftingDown( DdManager * table, @@ -1714,13 +1661,13 @@ ddSiftingDown( moves = NULL; /* Initialize R */ xindex = table->invperm[x]; - limitSize = size = table->keys - table->isolated; + limitSize = size = (int) (table->keys - table->isolated); R = 0; for (y = xHigh; y > x; y--) { yindex = table->invperm[y]; if (cuddTestInteract(table,xindex,yindex)) { isolated = table->vars[yindex]->ref == 1; - R += table->subtables[y].keys - isolated; + R += (int) table->subtables[y].keys - isolated; } } @@ -1732,7 +1679,7 @@ ddSiftingDown( zindex = table->invperm[z]; if (cuddTestInteract(table,xindex,zindex)) { isolated = table->vars[zindex]->ref == 1; - checkR += table->subtables[z].keys - isolated; + checkR += (int) table->subtables[z].keys - isolated; } } assert(R == checkR); @@ -1741,7 +1688,7 @@ ddSiftingDown( yindex = table->invperm[y]; if (cuddTestInteract(table,xindex,yindex)) { isolated = table->vars[yindex]->ref == 1; - R -= table->subtables[y].keys - isolated; + R -= (int) table->subtables[y].keys - isolated; } size = cuddSwapInPlace(table,x,y); if (size == 0) goto ddSiftingDownOutOfMem; @@ -1770,19 +1717,18 @@ ddSiftingDownOutOfMem: } /* end of ddSiftingDown */ -/**Function******************************************************************** +/** + @brief Given a set of moves, returns the %DD heap to the position + giving the minimum size. - Synopsis [Given a set of moves, returns the DD heap to the position - giving the minimum size.] + @details In case of ties, returns to the closest position giving the + minimum size. - Description [Given a set of moves, returns the DD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddSiftingBackward( DdManager * table, @@ -1809,19 +1755,19 @@ ddSiftingBackward( } /* end of ddSiftingBackward */ -/**Function******************************************************************** +/** + @brief Prepares the %DD heap for dynamic reordering. - Synopsis [Prepares the DD heap for dynamic reordering.] + @details Does garbage collection, to guarantee that there are no + dead nodes; clears the cache, which is invalidated by dynamic + reordering; initializes the number of isolated projection functions; + and initializes the interaction matrix. - Description [Prepares the DD heap for dynamic reordering. Does - garbage collection, to guarantee that there are no dead nodes; - clears the cache, which is invalidated by dynamic reordering; initializes - the number of isolated projection functions; and initializes the - interaction matrix. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddReorderPreprocess( DdManager * table) @@ -1851,15 +1797,12 @@ ddReorderPreprocess( } /* end of ddReorderPreprocess */ -/**Function******************************************************************** - - Synopsis [Cleans up at the end of reordering.] +/** + @brief Cleans up at the end of reordering. - Description [] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static int ddReorderPostprocess( DdManager * table) @@ -1877,22 +1820,20 @@ ddReorderPostprocess( } /* end of ddReorderPostprocess */ -/**Function******************************************************************** - - Synopsis [Reorders variables according to a given permutation.] +/** + @brief Reorders variables according to a given permutation. - Description [Reorders variables according to a given permutation. - The i-th permutation array contains the index of the variable that - should be brought to the i-th level. ddShuffle assumes that no - dead nodes are present and that the interaction matrix is properly - initialized. The reordering is achieved by a series of upward sifts. - Returns 1 if successful; 0 otherwise.] + @details The i-th permutation array contains the index of the + variable that should be brought to the i-th level. ddShuffle assumes + that no dead nodes are present and that the interaction matrix is + properly initialized. The reordering is achieved by a series of + upward sifts. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int ddShuffle( DdManager * table, @@ -1910,13 +1851,13 @@ ddShuffle( int previousSize; #endif - ddTotalNumberSwapping = 0; + table->ddTotalNumberSwapping = 0; #ifdef DD_STATS localTime = util_cpu_time(); initialSize = table->keys - table->isolated; (void) fprintf(table->out,"#:I_SHUFFLE %8d: initial size\n", initialSize); - ddTotalNISwaps = 0; + table->totalNISwaps = 0; #endif numvars = table->size; @@ -1948,8 +1889,9 @@ ddShuffle( (void) fprintf(table->out,"#:T_SHUFFLE %8g: total time (sec)\n", ((double)(util_cpu_time() - localTime)/1000.0)); (void) fprintf(table->out,"#:N_SHUFFLE %8d: total swaps\n", - ddTotalNumberSwapping); - (void) fprintf(table->out,"#:M_SHUFFLE %8d: NI swaps\n",ddTotalNISwaps); + table->ddTotalNumberSwapping); + (void) fprintf(table->out,"#:M_SHUFFLE %8d: NI swaps\n", + table->totalNISwaps); #endif return(1); @@ -1957,19 +1899,17 @@ ddShuffle( } /* end of ddShuffle */ -/**Function******************************************************************** - - Synopsis [Moves one variable up.] +/** + @brief Moves one variable up. - Description [Takes a variable from position x and sifts it up to + @details Takes a variable from position x and sifts it up to position xLow; xLow should be less than or equal to x. - Returns 1 if successful; 0 otherwise] - SideEffects [None] + @return 1 if successful; 0 otherwise - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int ddSiftUp( DdManager * table, @@ -1993,19 +1933,15 @@ ddSiftUp( } /* end of ddSiftUp */ -/**Function******************************************************************** +/** + @brief Fixes the %BDD variable group tree after a shuffle. - Synopsis [Fixes the BDD variable group tree after a shuffle.] + @details Assumes that the order of the variables in a terminal node + has not been changed. - Description [Fixes the BDD variable group tree after a - shuffle. Assumes that the order of the variables in a terminal node - has not been changed.] + @sideeffect Changes the %BDD variable group tree. - SideEffects [Changes the BDD variable group tree.] - - SeeAlso [] - -******************************************************************************/ +*/ static void bddFixTree( DdManager * table, @@ -2013,7 +1949,7 @@ bddFixTree( { if (treenode == NULL) return; treenode->low = ((int) treenode->index < table->size) ? - table->perm[treenode->index] : treenode->index; + (MtrHalfWord) table->perm[treenode->index] : treenode->index; if (treenode->child != NULL) { bddFixTree(table, treenode->child); } @@ -2028,18 +1964,14 @@ bddFixTree( } /* end of bddFixTree */ -/**Function******************************************************************** - - Synopsis [Updates the BDD variable group tree before a shuffle.] - - Description [Updates the BDD variable group tree before a shuffle. - Returns 1 if successful; 0 otherwise.] +/** + @brief Updates the %BDD variable group tree before a shuffle. - SideEffects [Changes the BDD variable group tree.] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect Changes the %BDD variable group tree. -******************************************************************************/ +*/ static int ddUpdateMtrTree( DdManager * table, @@ -2047,12 +1979,7 @@ ddUpdateMtrTree( int * perm, int * invperm) { - #if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 - unsigned int i; - #else - unsigned short i; - #endif - unsigned int size; + unsigned int i, size; int index, level, minLevel, maxLevel, minIndex; if (treenode == NULL) return(1); @@ -2062,14 +1989,14 @@ ddUpdateMtrTree( minIndex = -1; /* i : level */ for (i = treenode->low; i < treenode->low + treenode->size; i++) { - index = table->invperm[i]; - level = perm[index]; - if (level < minLevel) { - minLevel = level; - minIndex = index; - } - if (level > maxLevel) - maxLevel = level; + index = table->invperm[i]; + level = perm[index]; + if (level < minLevel) { + minLevel = level; + minIndex = index; + } + if (level > maxLevel) + maxLevel = level; } size = maxLevel - minLevel + 1; if (minIndex == -1) return(0); @@ -2092,18 +2019,14 @@ ddUpdateMtrTree( } -/**Function******************************************************************** - - Synopsis [Checks the BDD variable group tree before a shuffle.] +/** + @brief Checks the %BDD variable group tree before a shuffle. - Description [Checks the BDD variable group tree before a shuffle. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [Changes the BDD variable group tree.] + @sideeffect Changes the %BDD variable group tree. - SeeAlso [] - -******************************************************************************/ +*/ static int ddCheckPermuation( DdManager * table, @@ -2111,13 +2034,7 @@ ddCheckPermuation( int * perm, int * invperm) { - #if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 - unsigned int i; - #else - unsigned short i; - #endif - - unsigned int size; + unsigned int i, size; int index, level, minLevel, maxLevel; if (treenode == NULL) return(1); @@ -2125,17 +2042,17 @@ ddCheckPermuation( minLevel = table->size; maxLevel = 0; /* i : level */ - for (i = treenode->low; i < (treenode->low + treenode->size); i++) { - index = table->invperm[i]; - level = perm[index]; - if (level < minLevel) - minLevel = level; - if (level > maxLevel) - maxLevel = level; - } + for (i = treenode->low; i < treenode->low + treenode->size; i++) { + index = table->invperm[i]; + level = perm[index]; + if (level < minLevel) + minLevel = level; + if (level > maxLevel) + maxLevel = level; + } size = maxLevel - minLevel + 1; if (size != treenode->size) - return(0); + return(0); if (treenode->child != NULL) { if (!ddCheckPermuation(table, treenode->child, perm, invperm)) diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSat.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddSat.c similarity index 65% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddSat.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddSat.c index 869733f32..91daa142b 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSat.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddSat.c @@ -1,44 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddSat.c] - - PackageName [cudd] - - Synopsis [Functions for the solution of satisfiability related problems.] - - Description [External procedures included in this file: - <ul> - <li> Cudd_Eval() - <li> Cudd_ShortestPath() - <li> Cudd_LargestCube() - <li> Cudd_ShortestLength() - <li> Cudd_Decreasing() - <li> Cudd_Increasing() - <li> Cudd_EquivDC() - <li> Cudd_bddLeqUnless() - <li> Cudd_EqualSupNorm() - <li> Cudd_bddMakePrime() - <li> Cudd_bddMaximallyExpand() - <li> Cudd_bddLargestPrimeUnate() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddMakePrime() - </ul> - Static procedures included in this module: - <ul> - <li> freePathPair() - <li> getShortest() - <li> getPath() - <li> getLargest() - <li> getCube() - <li> ddBddMaximallyExpand() - <li> ddShortestPathUnate() - </ul>] - - Author [Seh-Woong Jeong, Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Functions for the solution of satisfiability related problems. + + @author Seh-Woong Jeong, Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -68,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -89,6 +60,9 @@ /* Type declarations */ /*---------------------------------------------------------------------------*/ +/** + @brief Type of item stored in memoization table. +*/ typedef struct cuddPathPair { int pos; int neg; @@ -98,11 +72,6 @@ typedef struct cuddPathPair { /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddSat.c,v 1.39 2012/02/05 01:07:19 fabio Exp $"; -#endif - -static DdNode *one, *zero; /*---------------------------------------------------------------------------*/ /* Macro declarations */ @@ -110,51 +79,42 @@ static DdNode *one, *zero; #define WEIGHT(weight, col) ((weight) == NULL ? 1 : weight[col]) -#ifdef __cplusplus -extern "C" { -#endif - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ -static enum st_retval freePathPair (char *key, char *value, char *arg); -static cuddPathPair getShortest (DdNode *root, int *cost, int *support, st_table *visited); +static enum st_retval freePathPair (void *key, void *value, void *arg); +static cuddPathPair getShortest (DdManager *dd, DdNode *root, int *cost, int *support, st_table *visited); static DdNode * getPath (DdManager *manager, st_table *visited, DdNode *f, int *weight, int cost); -static cuddPathPair getLargest (DdNode *root, st_table *visited); +static cuddPathPair getLargest (DdManager *dd, DdNode *root, st_table *visited); static DdNode * getCube (DdManager *manager, st_table *visited, DdNode *f, int cost); static DdNode * ddBddMaximallyExpand(DdManager *dd, DdNode *lb, DdNode *ub, DdNode *f); static int ddBddShortestPathUnate(DdManager *dd, DdNode *f, int *phases, st_table *table); static DdNode * ddGetLargestCubeUnate(DdManager *dd, DdNode *f, int *phases, st_table *table); -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} -#endif +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Returns the value of a DD for a given variable assignment.] +/** + @brief Returns the value of a %DD for a given variable assignment. - Description [Finds the value of a DD for a given variable - assignment. The variable assignment is passed in an array of int's, + @details The variable assignment is passed in an array of int's, that should specify a zero or a one for each variable in the support - of the function. Returns a pointer to a constant node. No new nodes - are produced.] + of the function. - SideEffects [None] + @return a pointer to a constant node. No new nodes are produced. - SeeAlso [Cudd_bddLeq Cudd_addEvalConst] + @sideeffect None -******************************************************************************/ + @see Cudd_bddLeq Cudd_addEvalConst + +*/ DdNode * Cudd_Eval( DdManager * dd, @@ -164,6 +124,7 @@ Cudd_Eval( int comple; DdNode *ptr; + (void) dd; /* avoid warning */ comple = Cudd_IsComplement(f); ptr = Cudd_Regular(f); @@ -180,25 +141,25 @@ Cudd_Eval( } /* end of Cudd_Eval */ -/**Function******************************************************************** +/** + @brief Finds a shortest path in a %DD. - Synopsis [Finds a shortest path in a DD.] + @details f is the %DD we want to get the shortest path for; + weight\[i\] is the weight of the THEN arc coming from the node whose + index is i. If weight is NULL, then unit weights are assumed for all + THEN arcs. All ELSE arcs have 0 weight. If non-NULL, both weight + and support should point to arrays with at least as many entries as + there are variables in the manager. - Description [Finds a shortest path in a DD. f is the DD we want to - get the shortest path for; weight\[i\] is the weight of the THEN arc - coming from the node whose index is i. If weight is NULL, then unit - weights are assumed for all THEN arcs. All ELSE arcs have 0 weight. - If non-NULL, both weight and support should point to arrays with at - least as many entries as there are variables in the manager. - Returns the shortest path as the BDD of a cube.] + @return the shortest path as the %BDD of a cube. - SideEffects [support contains on return the true support of f. + @sideeffect support contains on return the true support of f. If support is NULL on entry, then Cudd_ShortestPath does not compute - the true support info. length contains the length of the path.] + the true support info. length contains the length of the path. - SeeAlso [Cudd_ShortestLength Cudd_LargestCube] + @see Cudd_ShortestLength Cudd_LargestCube -******************************************************************************/ +*/ DdNode * Cudd_ShortestPath( DdManager * manager, @@ -214,8 +175,8 @@ Cudd_ShortestPath( int complement, cost; int i; - one = DD_ONE(manager); - zero = DD_ZERO(manager); + DdNode *one = DD_ONE(manager); + DdNode *zero = DD_ZERO(manager); /* Initialize support. Support does not depend on variable order. ** Hence, it does not need to be reinitialized if reordering occurs. @@ -239,13 +200,13 @@ Cudd_ShortestPath( visited = st_init_table(st_ptrcmp, st_ptrhash); /* Now get the length of the shortest path(s) from f to 1. */ - (void) getShortest(f, weight, support, visited); + (void) getShortest(manager, f, weight, support, visited); complement = Cudd_IsComplement(f); F = Cudd_Regular(f); - if (!st_lookup(visited, F, &rootPair)) return(NULL); + if (!st_lookup(visited, F, (void **) &rootPair)) return(NULL); if (complement) { cost = rootPair->neg; @@ -260,6 +221,9 @@ Cudd_ShortestPath( st_free_table(visited); } while (manager->reordered == 1); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } *length = cost; return(sol); @@ -267,37 +231,37 @@ Cudd_ShortestPath( } /* end of Cudd_ShortestPath */ -/**Function******************************************************************** +/** + @brief Finds a largest cube in a %DD. - Synopsis [Finds a largest cube in a DD.] + @details f is the %DD we want to get the largest cube for. The + problem is translated into the one of finding a shortest path in f, + when both THEN and ELSE arcs are assumed to have unit length. This + yields a largest cube in the disjoint cover corresponding to the + %DD. Therefore, it is not necessarily the largest implicant of f. - Description [Finds a largest cube in a DD. f is the DD we want to - get the largest cube for. The problem is translated into the one of - finding a shortest path in f, when both THEN and ELSE arcs are assumed to - have unit length. This yields a largest cube in the disjoint cover - corresponding to the DD. Therefore, it is not necessarily the largest - implicant of f. Returns the largest cube as a BDD.] + @return the largest cube as a %BDD. - SideEffects [The number of literals of the cube is returned in the location - pointed by length if it is non-null.] + @sideeffect The number of literals of the cube is returned in the location + pointed by length if it is non-null. - SeeAlso [Cudd_ShortestPath] + @see Cudd_ShortestPath -******************************************************************************/ +*/ DdNode * Cudd_LargestCube( DdManager * manager, DdNode * f, int * length) { - register DdNode *F; + DdNode *F; st_table *visited; DdNode *sol; cuddPathPair *rootPair; int complement, cost; - one = DD_ONE(manager); - zero = DD_ZERO(manager); + DdNode *one = DD_ONE(manager); + DdNode *zero = DD_ZERO(manager); if (f == Cudd_Not(one) || f == zero) { if (length != NULL) { @@ -314,13 +278,13 @@ Cudd_LargestCube( visited = st_init_table(st_ptrcmp, st_ptrhash); /* Now get the length of the shortest path(s) from f to 1. */ - (void) getLargest(f, visited); + (void) getLargest(manager, f, visited); complement = Cudd_IsComplement(f); F = Cudd_Regular(f); - if (!st_lookup(visited, F, &rootPair)) return(NULL); + if (!st_lookup(visited, F, (void **) &rootPair)) return(NULL); if (complement) { cost = rootPair->neg; @@ -339,40 +303,43 @@ Cudd_LargestCube( if (length != NULL) { *length = cost; } + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } return(sol); } /* end of Cudd_LargestCube */ -/**Function******************************************************************** +/** + @brief Find the length of the shortest path(s) in a %DD. - Synopsis [Find the length of the shortest path(s) in a DD.] + @details f is the %DD we want to get the shortest path for; + weight\[i\] is the weight of the THEN edge coming from the node + whose index is i. All ELSE edges have 0 weight. - Description [Find the length of the shortest path(s) in a DD. f is - the DD we want to get the shortest path for; weight\[i\] is the - weight of the THEN edge coming from the node whose index is i. All - ELSE edges have 0 weight. Returns the length of the shortest - path(s) if such a path is found; a large number if the function is - identically 0, and CUDD_OUT_OF_MEM in case of failure.] + @return the length of the shortest path(s) if such a path is found; + a large number if the function is identically 0, and CUDD_OUT_OF_MEM + in case of failure. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_ShortestPath] + @see Cudd_ShortestPath -******************************************************************************/ +*/ int Cudd_ShortestLength( DdManager * manager, DdNode * f, int * weight) { - register DdNode *F; + DdNode *F; st_table *visited; cuddPathPair *my_pair; int complement, cost; - one = DD_ONE(manager); - zero = DD_ZERO(manager); + DdNode *one = DD_ONE(manager); + DdNode *zero = DD_ZERO(manager); if (f == Cudd_Not(one) || f == zero) { return(DD_BIGGY); @@ -383,13 +350,13 @@ Cudd_ShortestLength( visited = st_init_table(st_ptrcmp, st_ptrhash); /* Now get the length of the shortest path(s) from f to 1. */ - (void) getShortest(f, weight, NULL, visited); + (void) getShortest(manager, f, weight, NULL, visited); complement = Cudd_IsComplement(f); F = Cudd_Regular(f); - if (!st_lookup(visited, F, &my_pair)) return(CUDD_OUT_OF_MEM); + if (!st_lookup(visited, F, (void **) &my_pair)) return(CUDD_OUT_OF_MEM); if (complement) { cost = my_pair->neg; @@ -405,28 +372,29 @@ Cudd_ShortestLength( } /* end of Cudd_ShortestLength */ -/**Function******************************************************************** +/** + @brief Checks whether a %BDD is negative unate in a + variable. - Synopsis [Determines whether a BDD is negative unate in a - variable.] + @details Determines whether the function represented by %BDD f is + negative unate (monotonic decreasing) in variable i. This function + does not generate any new nodes. - Description [Determines whether the function represented by BDD f is - negative unate (monotonic decreasing) in variable i. Returns the - constant one is f is unate and the (logical) constant zero if it is not. - This function does not generate any new nodes.] + @return the constant one is f is unate and the (logical) constant + zero if it is not. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Increasing] + @see Cudd_Increasing -******************************************************************************/ +*/ DdNode * Cudd_Decreasing( DdManager * dd, DdNode * f, int i) { - unsigned int topf, level; + int topf, level; DdNode *F, *fv, *fvn, *res; DD_CTFP cacheOp; @@ -455,6 +423,8 @@ Cudd_Decreasing( return(res); } + checkWhetherToGiveUp(dd); + /* Compute cofactors. */ fv = cuddT(F); fvn = cuddE(F); if (F != f) { @@ -462,7 +432,7 @@ Cudd_Decreasing( fvn = Cudd_Not(fvn); } - if (topf == (unsigned) level) { + if (topf == level) { /* Special case: if fv is regular, fv(1,...,1) = 1; ** If in addition fvn is complemented, fvn(1,...,1) = 0. ** But then f(1,1,...,1) > f(0,1,...,1). Hence f is not @@ -485,21 +455,19 @@ Cudd_Decreasing( } /* end of Cudd_Decreasing */ -/**Function******************************************************************** +/** + @brief Checks whether a %BDD is positive unate in a variable. - Synopsis [Determines whether a BDD is positive unate in a - variable.] - - Description [Determines whether the function represented by BDD f is + @details Determines whether the function represented by %BDD f is positive unate (monotonic increasing) in variable i. It is based on Cudd_Decreasing and the fact that f is monotonic increasing in i if - and only if its complement is monotonic decreasing in i.] + and only if its complement is monotonic decreasing in i. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Decreasing] + @see Cudd_Decreasing -******************************************************************************/ +*/ DdNode * Cudd_Increasing( DdManager * dd, @@ -511,20 +479,19 @@ Cudd_Increasing( } /* end of Cudd_Increasing */ -/**Function******************************************************************** +/** + @brief Tells whether F and G are identical wherever D is 0. - Synopsis [Tells whether F and G are identical wherever D is 0.] + @details F and G are either two ADDs or two BDDs. D is either a 0-1 + %ADD or a %BDD. No new nodes are created. - Description [Tells whether F and G are identical wherever D is 0. F - and G are either two ADDs or two BDDs. D is either a 0-1 ADD or a - BDD. The function returns 1 if F and G are equivalent, and 0 - otherwise. No new nodes are created.] + @return 1 if F and G are equivalent, and 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddLeqUnless] + @see Cudd_bddLeqUnless -******************************************************************************/ +*/ int Cudd_EquivDC( DdManager * dd, @@ -535,7 +502,7 @@ Cudd_EquivDC( DdNode *tmp, *One, *Gr, *Dr; DdNode *Fv, *Fvn, *Gv, *Gvn, *Dv, *Dvn; int res; - unsigned int flevel, glevel, dlevel, top; + int flevel, glevel, dlevel, top; One = DD_ONE(dd); @@ -612,19 +579,18 @@ Cudd_EquivDC( } /* end of Cudd_EquivDC */ -/**Function******************************************************************** +/** + @brief Tells whether f is less than of equal to G unless D is 1. - Synopsis [Tells whether f is less than of equal to G unless D is 1.] + @details f, g, and D are BDDs. No new nodes are created. - Description [Tells whether f is less than of equal to G unless D is - 1. f, g, and D are BDDs. The function returns 1 if f is less than - of equal to G, and 0 otherwise. No new nodes are created.] + @return 1 if f is less than of equal to G, and 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_EquivDC Cudd_bddLeq Cudd_bddIteConstant] + @see Cudd_EquivDC Cudd_bddLeq Cudd_bddIteConstant -******************************************************************************/ +*/ int Cudd_bddLeqUnless( DdManager *dd, @@ -635,7 +601,7 @@ Cudd_bddLeqUnless( DdNode *tmp, *One, *F, *G; DdNode *Ft, *Fe, *Gt, *Ge, *Dt, *De; int res; - unsigned int flevel, glevel, dlevel, top; + int flevel, glevel, dlevel, top; statLine(dd); @@ -783,37 +749,34 @@ Cudd_bddLeqUnless( } /* end of Cudd_bddLeqUnless */ -/**Function******************************************************************** +/** + @brief Compares two ADDs for equality within tolerance. - Synopsis [Compares two ADDs for equality within tolerance.] + @details Two ADDs are reported to be equal if the maximum difference + between them (the sup norm of their difference) is less than or + equal to the tolerance parameter. If parameter <code>pr</code> is + positive the first failure is reported to the standard output. - Description [Compares two ADDs for equality within tolerance. Two - ADDs are reported to be equal if the maximum difference between them - (the sup norm of their difference) is less than or equal to the - tolerance parameter. Returns 1 if the two ADDs are equal (within - tolerance); 0 otherwise. If parameter <code>pr</code> is positive - the first failure is reported to the standard output.] + @return 1 if the two ADDs are equal (within tolerance); 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int Cudd_EqualSupNorm( - DdManager * dd /* manager */, - DdNode * f /* first ADD */, - DdNode * g /* second ADD */, - CUDD_VALUE_TYPE tolerance /* maximum allowed difference */, - int pr /* verbosity level */) + DdManager * dd /**< manager */, + DdNode * f /**< first %ADD */, + DdNode * g /**< second %ADD */, + CUDD_VALUE_TYPE tolerance /**< maximum allowed difference */, + int pr /**< verbosity level */) { DdNode *fv, *fvn, *gv, *gvn, *r; - unsigned int topf, topg; + int topf, topg; statLine(dd); /* Check terminal cases. */ if (f == g) return(1); - if (Cudd_IsConstant(f) && Cudd_IsConstant(g)) { + if (cuddIsConstant(f) && cuddIsConstant(g)) { if (ddEqualVal(cuddV(f),cuddV(g),tolerance)) { return(1); } else { @@ -919,24 +882,23 @@ Cudd_EqualSupNormRel( } /* end of Cudd_EqualSupNormRel */ -/**Function******************************************************************** - - Synopsis [Expands cube to a prime implicant of f.] +/** + @brief Expands cube to a prime implicant of f. - Description [Expands cube to a prime implicant of f. Returns the prime - if successful; NULL otherwise. In particular, NULL is returned if cube - is not a real cube or is not an implicant of f.] + @return the prime if successful; NULL otherwise. In particular, + NULL is returned if cube is not a real cube or is not an implicant + of f. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddMaximallyExpand] + @see Cudd_bddMaximallyExpand -******************************************************************************/ +*/ DdNode * Cudd_bddMakePrime( - DdManager *dd /* manager */, - DdNode *cube /* cube to be expanded */, - DdNode *f /* function of which the cube is to be made a prime */) + DdManager *dd /**< manager */, + DdNode *cube /**< cube to be expanded */, + DdNode *f /**< function of which the cube is to be made a prime */) { DdNode *res; @@ -946,33 +908,37 @@ Cudd_bddMakePrime( dd->reordered = 0; res = cuddBddMakePrime(dd,cube,f); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddMakePrime */ -/**Function******************************************************************** +/** + @brief Expands lb to prime implicants of (f and ub). - Synopsis [Expands lb to prime implicants of (f and ub).] + @details Expands lb to all prime implicants of (f and ub) that + contain lb. Assumes that lb is contained in ub. - Description [Expands lb to all prime implicants of (f and ub) that contain lb. - Assumes that lb is contained in ub. Returns the disjunction of the primes if - lb is contained in f; returns the zero BDD if lb is not contained in f; - returns NULL in case of failure. In particular, NULL is returned if cube is - not a real cube or is not an implicant of f. Returning the disjunction of - all prime implicants works because the resulting function is unate.] + @return the disjunction of the primes if lb is contained in f; + returns the zero %BDD if lb is not contained in f; returns NULL in + case of failure. In particular, NULL is returned if cube is not a + real cube or is not an implicant of f. Returning the disjunction of + all prime implicants works because the resulting function is unate. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddMakePrime] + @see Cudd_bddMakePrime -******************************************************************************/ +*/ DdNode * Cudd_bddMaximallyExpand( - DdManager *dd /* manager */, - DdNode *lb /* cube to be expanded */, - DdNode *ub /* upper bound cube */, - DdNode *f /* function against which to expand */) + DdManager *dd /**< manager */, + DdNode *lb /**< cube to be expanded */, + DdNode *ub /**< upper bound cube */, + DdNode *f /**< function against which to expand */) { DdNode *res; @@ -982,31 +948,34 @@ Cudd_bddMaximallyExpand( dd->reordered = 0; res = ddBddMaximallyExpand(dd,lb,ub,f); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddMaximallyExpand */ -/**Function******************************************************************** +/** + @brief Find a largest prime implicant of a unate function. - Synopsis [Find a largest prime of a unate function.] + @details The behavior is undefined if f is not unate. The third + argument is used to determine whether f is unate positive + (increasing) or negative (decreasing) in each of the variables in + its support. - Description [Find a largest prime implicant of a unate function. - Returns the BDD for the prime if succesful; NULL otherwise. The behavior - is undefined if f is not unate. The third argument is used to determine - whether f is unate positive (increasing) or negative (decreasing) - in each of the variables in its support.] + @return the %BDD for the prime if succesful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddMaximallyExpand] + @see Cudd_bddMaximallyExpand -******************************************************************************/ +*/ DdNode * Cudd_bddLargestPrimeUnate( - DdManager *dd /* manager */, - DdNode *f /* unate function */, - DdNode *phaseBdd /* cube of the phases */) + DdManager *dd /**< manager */, + DdNode *f /**< unate function */, + DdNode *phaseBdd /**< cube of the phases */) { DdNode *res; int *phases; @@ -1034,6 +1003,9 @@ Cudd_bddLargestPrimeUnate( } while (dd->reordered == 1); FREE(phases); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddLargestPrimeUnate */ @@ -1044,32 +1016,28 @@ Cudd_bddLargestPrimeUnate( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_bddMakePrime. - Synopsis [Performs the recursive step of Cudd_bddMakePrime.] + @return the prime if successful; NULL otherwise. - Description [Performs the recursive step of Cudd_bddMakePrime. - Returns the prime if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ DdNode * cuddBddMakePrime( - DdManager *dd /* manager */, - DdNode *cube /* cube to be expanded */, - DdNode *f /* function of which the cube is to be made a prime */) + DdManager *dd /**< manager */, + DdNode *cube /**< cube to be expanded */, + DdNode *f /**< function of which the cube is to be made a prime */) { DdNode *scan; DdNode *t, *e; DdNode *res = cube; - DdNode *zero = Cudd_Not(DD_ONE(dd)); + DdNode *lzero = Cudd_Not(DD_ONE(dd)); Cudd_Ref(res); scan = cube; - while (!Cudd_IsConstant(scan)) { + while (!Cudd_IsConstantInt(scan)) { DdNode *reg = Cudd_Regular(scan); DdNode *var = dd->vars[reg->index]; DdNode *expanded = Cudd_bddExistAbstract(dd,res,var); @@ -1085,9 +1053,9 @@ cuddBddMakePrime( Cudd_RecursiveDeref(dd,expanded); } cuddGetBranches(scan,&t,&e); - if (t == zero) { + if (t == lzero) { scan = e; - } else if (e == zero) { + } else if (e == lzero) { scan = t; } else { Cudd_RecursiveDeref(dd,res); @@ -1111,51 +1079,48 @@ cuddBddMakePrime( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Frees the entries of the visited symbol table.] +/** + @brief Frees the entries of the visited symbol table. - Description [Frees the entries of the visited symbol table. Returns - ST_CONTINUE.] + @return ST_CONTINUE. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static enum st_retval freePathPair( - char * key, - char * value, - char * arg) + void * key, + void * value, + void * arg) { - cuddPathPair *pair; + cuddPathPair *pair = (cuddPathPair *) value; - pair = (cuddPathPair *) value; - FREE(pair); + (void) key; /* avoid warning */ + (void) arg; /* avoid warning */ + FREE(pair); return(ST_CONTINUE); } /* end of freePathPair */ -/**Function******************************************************************** - - Synopsis [Finds the length of the shortest path(s) in a DD.] +/** + @brief Finds the length of the shortest path(s) in a %DD. - Description [Finds the length of the shortest path(s) in a DD. - Uses a local symbol table to store the lengths for each - node. Only the lengths for the regular nodes are entered in the table, - because those for the complement nodes are simply obtained by swapping - the two lenghts. - Returns a pair of lengths: the length of the shortest path to 1; - and the length of the shortest path to 0. This is done so as to take - complement arcs into account.] + @details Uses a local symbol table to store the lengths for each + node. Only the lengths for the regular nodes are entered in the + table, because those for the complement nodes are simply obtained by + swapping the two lenghts. - SideEffects [Accumulates the support of the DD in support.] + @return a pair of lengths: the length of the shortest path to 1; and + the length of the shortest path to 0. This is done so as to take + complement arcs into account. - SeeAlso [] + @sideeffect Accumulates the support of the %DD in support. -******************************************************************************/ +*/ static cuddPathPair getShortest( + DdManager * dd, DdNode * root, int * cost, int * support, @@ -1164,10 +1129,11 @@ getShortest( cuddPathPair *my_pair, res_pair, pair_T, pair_E; DdNode *my_root, *T, *E; int weight; + DdNode *zero = DD_ZERO(dd); my_root = Cudd_Regular(root); - if (st_lookup(visited, my_root, &my_pair)) { + if (st_lookup(visited, my_root, (void **) &my_pair)) { if (Cudd_IsComplement(root)) { res_pair.pos = my_pair->neg; res_pair.neg = my_pair->pos; @@ -1195,8 +1161,8 @@ getShortest( T = cuddT(my_root); E = cuddE(my_root); - pair_T = getShortest(T, cost, support, visited); - pair_E = getShortest(E, cost, support, visited); + pair_T = getShortest(dd, T, cost, support, visited); + pair_E = getShortest(dd, E, cost, support, visited); weight = WEIGHT(cost, my_root->index); res_pair.pos = ddMin(pair_T.pos+weight, pair_E.pos); res_pair.neg = ddMin(pair_T.neg+weight, pair_E.neg); @@ -1219,7 +1185,7 @@ getShortest( my_pair->pos = res_pair.pos; my_pair->neg = res_pair.neg; - st_insert(visited, (char *)my_root, (char *)my_pair); + st_insert(visited, my_root, my_pair); if (Cudd_IsComplement(root)) { res_pair.pos = my_pair->neg; res_pair.neg = my_pair->pos; @@ -1232,24 +1198,21 @@ getShortest( } /* end of getShortest */ -/**Function******************************************************************** - - Synopsis [Build a BDD for a shortest path of f.] +/** + @brief Build a %BDD for a shortest path of f. - Description [Build a BDD for a shortest path of f. - Given the minimum length from the root, and the minimum - lengths for each node (in visited), apply triangulation at each node. - Of the two children of each node on a shortest path, at least one is - on a shortest path. In case of ties the procedure chooses the THEN - children. - Returns a pointer to the cube BDD representing the path if - successful; NULL otherwise.] + @details Given the minimum length from the root, and the minimum + lengths for each node (in visited), apply triangulation at each + node. Of the two children of each node on a shortest path, at least + one is on a shortest path. In case of ties the procedure chooses the + THEN children. - SideEffects [None] + @return a pointer to the cube %BDD representing the path if + successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static DdNode * getPath( DdManager * manager, @@ -1267,7 +1230,7 @@ getPath( my_dd = Cudd_Regular(f); complement = Cudd_IsComplement(f); - sol = one; + sol = DD_ONE(manager); cuddRef(sol); while (!cuddIsConstant(my_dd)) { @@ -1279,7 +1242,7 @@ getPath( if (complement) {T = Cudd_Not(T); E = Cudd_Not(E);} - st_lookup(visited, Cudd_Regular(T), &T_pair); + st_lookup(visited, Cudd_Regular(T), (void **) &T_pair); if ((Cudd_IsComplement(T) && T_pair->neg == Tcost) || (!Cudd_IsComplement(T) && T_pair->pos == Tcost)) { tmp = cuddBddAndRecur(manager,manager->vars[my_dd->index],sol); @@ -1296,7 +1259,7 @@ getPath( cost = Tcost; continue; } - st_lookup(visited, Cudd_Regular(E), &E_pair); + st_lookup(visited, Cudd_Regular(E), (void **) &E_pair); if ((Cudd_IsComplement(E) && E_pair->neg == Ecost) || (!Cudd_IsComplement(E) && E_pair->pos == Ecost)) { tmp = cuddBddAndRecur(manager,Cudd_Not(manager->vars[my_dd->index]),sol); @@ -1323,37 +1286,36 @@ getPath( } /* end of getPath */ -/**Function******************************************************************** - - Synopsis [Finds the size of the largest cube(s) in a DD.] +/** + @brief Finds the size of the largest cube(s) in a %DD. - Description [Finds the size of the largest cube(s) in a DD. - This problem is translated into finding the shortest paths from a node - when both THEN and ELSE arcs have unit lengths. - Uses a local symbol table to store the lengths for each - node. Only the lengths for the regular nodes are entered in the table, - because those for the complement nodes are simply obtained by swapping - the two lenghts. - Returns a pair of lengths: the length of the shortest path to 1; - and the length of the shortest path to 0. This is done so as to take - complement arcs into account.] + @details This problem is translated into finding the shortest paths + from a node when both THEN and ELSE arcs have unit lengths. Uses a + local symbol table to store the lengths for each node. Only the + lengths for the regular nodes are entered in the table, because + those for the complement nodes are simply obtained by swapping the + two lenghts. - SideEffects [none] + @return a pair of lengths: the length of the shortest path to 1; and + the length of the shortest path to 0. This is done so as to take + complement arcs into account. - SeeAlso [] + @sideeffect none -******************************************************************************/ +*/ static cuddPathPair getLargest( + DdManager * dd, DdNode * root, st_table * visited) { cuddPathPair *my_pair, res_pair, pair_T, pair_E; DdNode *my_root, *T, *E; + DdNode *zero = DD_ZERO(dd); my_root = Cudd_Regular(root); - if (st_lookup(visited, my_root, &my_pair)) { + if (st_lookup(visited, my_root, (void **) &my_pair)) { if (Cudd_IsComplement(root)) { res_pair.pos = my_pair->neg; res_pair.neg = my_pair->pos; @@ -1381,8 +1343,8 @@ getLargest( T = cuddT(my_root); E = cuddE(my_root); - pair_T = getLargest(T, visited); - pair_E = getLargest(E, visited); + pair_T = getLargest(dd, T, visited); + pair_E = getLargest(dd, E, visited); res_pair.pos = ddMin(pair_T.pos, pair_E.pos) + 1; res_pair.neg = ddMin(pair_T.neg, pair_E.neg) + 1; } @@ -1400,7 +1362,7 @@ getLargest( my_pair->neg = res_pair.neg; /* Caching may fail without affecting correctness. */ - st_insert(visited, (char *)my_root, (char *)my_pair); + st_insert(visited, my_root, my_pair); if (Cudd_IsComplement(root)) { res_pair.pos = my_pair->neg; res_pair.neg = my_pair->pos; @@ -1413,24 +1375,21 @@ getLargest( } /* end of getLargest */ -/**Function******************************************************************** - - Synopsis [Build a BDD for a largest cube of f.] +/** + @brief Build a %BDD for a largest cube of f. - Description [Build a BDD for a largest cube of f. - Given the minimum length from the root, and the minimum - lengths for each node (in visited), apply triangulation at each node. - Of the two children of each node on a shortest path, at least one is - on a shortest path. In case of ties the procedure chooses the THEN - children. - Returns a pointer to the cube BDD representing the path if - successful; NULL otherwise.] + @details Given the minimum length from the root, and the minimum + lengths for each node (in visited), apply triangulation at each + node. Of the two children of each node on a shortest path, at least + one is on a shortest path. In case of ties the procedure chooses the + THEN children. - SideEffects [None] + @return a pointer to the cube %BDD representing the path if + successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static DdNode * getCube( DdManager * manager, @@ -1447,7 +1406,7 @@ getCube( my_dd = Cudd_Regular(f); complement = Cudd_IsComplement(f); - sol = one; + sol = DD_ONE(manager); cuddRef(sol); while (!cuddIsConstant(my_dd)) { @@ -1459,7 +1418,7 @@ getCube( if (complement) {T = Cudd_Not(T); E = Cudd_Not(E);} - if (!st_lookup(visited, Cudd_Regular(T), &T_pair)) return(NULL); + if (!st_lookup(visited, Cudd_Regular(T), (void **)&T_pair)) return(NULL); if ((Cudd_IsComplement(T) && T_pair->neg == Tcost) || (!Cudd_IsComplement(T) && T_pair->pos == Tcost)) { tmp = cuddBddAndRecur(manager,manager->vars[my_dd->index],sol); @@ -1476,7 +1435,7 @@ getCube( cost = Tcost; continue; } - if (!st_lookup(visited, Cudd_Regular(E), &E_pair)) return(NULL); + if (!st_lookup(visited, Cudd_Regular(E), (void **)&E_pair)) return(NULL); if ((Cudd_IsComplement(E) && E_pair->neg == Ecost) || (!Cudd_IsComplement(E) && E_pair->pos == Ecost)) { tmp = cuddBddAndRecur(manager,Cudd_Not(manager->vars[my_dd->index]),sol); @@ -1503,36 +1462,34 @@ getCube( } /* end of getCube */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_bddMaximallyExpand.] +/** + @brief Performs the recursive step of Cudd_bddMaximallyExpand. - Description [Performs the recursive step of Cudd_bddMaximallyExpand. - Returns set of primes or zero BDD if successful; NULL otherwise. On entry - to this function, ub and lb should be different from the zero BDD. The - function then maintains this invariant.] + @details On entry to this function, ub and lb should be different + from the zero %BDD. The function then maintains this invariant. - SideEffects [None] + @return set of primes or zero %BDD if successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static DdNode * ddBddMaximallyExpand( - DdManager *dd /* manager */, - DdNode *lb /* cube to be expanded */, - DdNode *ub /* upper bound cube */, - DdNode *f /* function against which to expand */) + DdManager *dd /**< manager */, + DdNode *lb /**< cube to be expanded */, + DdNode *ub /**< upper bound cube */, + DdNode *f /**< function against which to expand */) { - DdNode *one, *zero, *lbv, *lbvn, *lbnx, *ubv, *ubvn, *fv, *fvn, *res; + DdNode *lone, *lzero, *lbv, *lbvn, *lbnx, *ubv, *ubvn, *fv, *fvn, *res; DdNode *F, *UB, *LB, *t, *e; - unsigned int top, toplb, topub, topf, index; + int top, toplb, topub, topf; + unsigned int index; statLine(dd); /* Terminal cases. */ - one = DD_ONE(dd); - zero = Cudd_Not(one); - assert(ub != zero && lb != zero); + lone = DD_ONE(dd); + lzero = Cudd_Not(lone); + assert(ub != lzero && lb != lzero); /** There are three major terminal cases in theory: ** ub -> f : return ub ** lb == f : return lb @@ -1540,11 +1497,11 @@ ddBddMaximallyExpand( ** Only the second case can be checked exactly in constant time. ** For the others, we check for sufficient conditions. */ - if (ub == f || f == one) return(ub); + if (ub == f || f == lone) return(ub); if (lb == f) return(lb); - if (f == zero || ub == Cudd_Not(f) || lb == one || lb == Cudd_Not(f)) - return(zero); - if (!Cudd_IsComplement(lb) && Cudd_IsComplement(f)) return(zero); + if (f == lzero || ub == Cudd_Not(f) || lb == lone || lb == Cudd_Not(f)) + return(lzero); + if (!Cudd_IsComplement(lb) && Cudd_IsComplement(f)) return(lzero); /* Here lb and f are not constant. */ @@ -1559,6 +1516,8 @@ ddBddMaximallyExpand( } } + checkWhetherToGiveUp(dd); + /* Compute cofactors. For lb we use the non-zero one in ** both branches of the recursion. */ @@ -1566,7 +1525,7 @@ ddBddMaximallyExpand( UB = Cudd_Regular(ub); topf = dd->perm[F->index]; toplb = dd->perm[LB->index]; - topub = (ub == one) ? CUDD_CONST_INDEX : dd->perm[UB->index]; + topub = (ub == lone) ? CUDD_CONST_INDEX : (unsigned int) dd->perm[UB->index]; assert(toplb <= topub); top = ddMin(topf,toplb); if (toplb == top) { @@ -1577,7 +1536,7 @@ ddBddMaximallyExpand( lbv = Cudd_Not(lbv); lbvn = Cudd_Not(lbvn); } - if (lbv == zero) { + if (lbv == lzero) { lbnx = lbvn; } else { lbnx = lbv; @@ -1608,12 +1567,12 @@ ddBddMaximallyExpand( } /* Recursive calls. */ - if (ubv != zero) { + if (ubv != lzero) { t = ddBddMaximallyExpand(dd, lbnx, ubv, fv); if (t == NULL) return(NULL); } else { - assert(topub == toplb && topub == top && lbv == zero); - t = zero; + assert(topub == toplb && topub == top && lbv == lzero); + t = lzero; } cuddRef(t); @@ -1625,15 +1584,15 @@ ddBddMaximallyExpand( if (ubv == ubvn && fv == fvn) { res = t; } else { - if (ubvn != zero) { + if (ubvn != lzero) { e = ddBddMaximallyExpand(dd, lbnx, ubvn, fvn); if (e == NULL) { Cudd_IterDerefBdd(dd,t); return(NULL); } } else { - assert(topub == toplb && topub == top && lbvn == zero); - e = zero; + assert(topub == toplb && topub == top && lbvn == lzero); + e = lzero; } if (t == e) { @@ -1642,12 +1601,12 @@ ddBddMaximallyExpand( cuddRef(e); if (toplb == top) { - if (lbv == zero) { + if (lbv == lzero) { /* Top variable appears in negative phase. */ - if (t != one) { + if (t != lone) { DdNode *newT; if (Cudd_IsComplement(t)) { - newT = cuddUniqueInter(dd, index, Cudd_Not(t), zero); + newT = cuddUniqueInter(dd, index, Cudd_Not(t), lzero); if (newT == NULL) { Cudd_IterDerefBdd(dd,t); Cudd_IterDerefBdd(dd,e); @@ -1655,7 +1614,7 @@ ddBddMaximallyExpand( } newT = Cudd_Not(newT); } else { - newT = cuddUniqueInter(dd, index, t, one); + newT = cuddUniqueInter(dd, index, t, lone); if (newT == NULL) { Cudd_IterDerefBdd(dd,t); Cudd_IterDerefBdd(dd,e); @@ -1666,11 +1625,11 @@ ddBddMaximallyExpand( cuddDeref(t); t = newT; } - } else if (lbvn == zero) { + } else if (lbvn == lzero) { /* Top variable appears in positive phase. */ - if (e != one) { + if (e != lone) { DdNode *newE; - newE = cuddUniqueInter(dd, index, one, e); + newE = cuddUniqueInter(dd, index, lone, e); if (newE == NULL) { Cudd_IterDerefBdd(dd,t); Cudd_IterDerefBdd(dd,e); @@ -1711,21 +1670,21 @@ ddBddMaximallyExpand( } /* end of ddBddMaximallyExpand */ -/**Function******************************************************************** +/** + @brief Performs shortest path computation on a unate function. - Synopsis [Performs shortest path computation on a unate function.] + @details This function is based on the observation that in the %BDD + of a unate function no node except the constant is reachable from + the root via paths of different parity. - Description [Performs shortest path computation on a unate function. - Returns the length of the shortest path to one if successful; - CUDD_OUT_OF_MEM otherwise. This function is based on the observation - that in the BDD of a unate function no node except the constant is - reachable from the root via paths of different parity.] + @return the length of the shortest path to one if successful; + CUDD_OUT_OF_MEM otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [getShortest] + @see getShortest -******************************************************************************/ +*/ static int ddBddShortestPathUnate( DdManager *dd, @@ -1734,16 +1693,16 @@ ddBddShortestPathUnate( st_table *table) { int positive, l, lT, lE; - DdNode *one = DD_ONE(dd); - DdNode *zero = Cudd_Not(one); + DdNode *lone = DD_ONE(dd); + DdNode *lzero = Cudd_Not(lone); DdNode *F, *fv, *fvn; if (st_lookup_int(table, f, &l)) { return(l); } - if (f == one) { + if (f == lone) { l = 0; - } else if (f == zero) { + } else if (f == lzero) { l = DD_BIGGY; } else { F = Cudd_Regular(f); @@ -1766,18 +1725,16 @@ ddBddShortestPathUnate( } /* end of ddShortestPathUnate */ -/**Function******************************************************************** - - Synopsis [Extracts largest prime of a unate function.] +/** + @brief Extracts largest prime of a unate function. - Description [Extracts largest prime of a unate function. Returns the BDD of - the prime if successful; NULL otherwise.] + @return the %BDD of the prime if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [getPath] + @see getPath -******************************************************************************/ +*/ static DdNode * ddGetLargestCubeUnate( DdManager *dd, @@ -1786,23 +1743,20 @@ ddGetLargestCubeUnate( st_table *table) { DdNode *res, *scan; - DdNode *one = DD_ONE(dd); int cost; - res = one; + res = DD_ONE(dd); cuddRef(res); scan = f; st_lookup_int(table, scan, &cost); - while (!Cudd_IsConstant(scan)) { - int Pcost, Ncost, Tcost, positive, index; - DdNode *tmp, *T, *E, *rscan; - rscan = Cudd_Regular(scan); - index = rscan->index; - - assert(phases[index] == 0 || phases[index] == 1); - - positive = phases[index] == 1; + while (!Cudd_IsConstantInt(scan)) { + int Pcost, Ncost, Tcost; + DdNode *tmp, *T, *E; + DdNode *rscan = Cudd_Regular(scan); + unsigned int index = rscan->index; + assert(phases[index] == 0 || phases[index] == 1); + int positive = phases[index] == 1; Pcost = positive ? cost - 1 : cost; Ncost = positive ? cost : cost - 1; T = cuddT(rscan); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSign.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddSign.c similarity index 68% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddSign.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddSign.c index 60520697a..e2d50f8e4 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSign.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddSign.c @@ -1,24 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddSign.c] + @ingroup cudd - PackageName [cudd] + @brief Computation of signatures. - Synopsis [Computation of signatures.] + @author Fabio Somenzi - Description [External procedures included in this module: - <ul> - <li> Cudd_CofMinterm(); - </ul> - Static procedures included in this module: - <ul> - <li> ddCofMintermAux() - </ul> - ] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -48,51 +38,35 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" - /*---------------------------------------------------------------------------*/ /* Constant declarations */ /*---------------------------------------------------------------------------*/ - /*---------------------------------------------------------------------------*/ /* Stucture declarations */ /*---------------------------------------------------------------------------*/ - /*---------------------------------------------------------------------------*/ /* Type declarations */ /*---------------------------------------------------------------------------*/ - /*---------------------------------------------------------------------------*/ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddSign.c,v 1.24 2012/02/05 01:07:19 fabio Exp $"; -#endif - -static int size; - -#ifdef DD_STATS -static int num_calls; /* should equal 2n-1 (n is the # of nodes) */ -static int table_mem; -#endif - - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -100,29 +74,29 @@ static int table_mem; static double * ddCofMintermAux (DdManager *dd, DdNode *node, st_table *table); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Computes the fraction of minterms in the on-set of all the + positive cofactors of a %BDD or %ADD. - Synopsis [Computes the fraction of minterms in the on-set of all the - positive cofactors of a BDD or ADD.] + @details The array has as many positions as there are %BDD variables + in the manager plus one. The last position of the array contains the + fraction of the minterms in the ON-set of the function represented + by the %BDD or %ADD. The other positions of the array hold the + variable signatures. - Description [Computes the fraction of minterms in the on-set of all - the positive cofactors of DD. Returns the pointer to an array of - doubles if successful; NULL otherwise. The array has as many - positions as there are BDD variables in the manager plus one. The - last position of the array contains the fraction of the minterms in - the ON-set of the function represented by the BDD or ADD. The other - positions of the array hold the variable signatures.] + @return the pointer to an array of doubles if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ double * Cudd_CofMinterm( DdManager * dd, @@ -132,12 +106,12 @@ Cudd_CofMinterm( double *values; double *result = NULL; int i, firstLevel; + int size; #ifdef DD_STATS unsigned long startTime; startTime = util_cpu_time(); - num_calls = 0; - table_mem = sizeof(st_table); + dd->num_calls = 0; #endif table = st_init_table(st_ptrcmp, st_ptrhash); @@ -152,10 +126,7 @@ Cudd_CofMinterm( if (values != NULL) { result = ALLOC(double,size + 1); if (result != NULL) { -#ifdef DD_STATS - table_mem += (size + 1) * sizeof(double); -#endif - if (Cudd_IsConstant(node)) + if (Cudd_IsConstantInt(node)) firstLevel = 1; else firstLevel = cuddI(dd,Cudd_Regular(node)->index); @@ -172,15 +143,11 @@ Cudd_CofMinterm( } } -#ifdef DD_STATS - table_mem += table->num_bins * sizeof(st_table_entry *); -#endif if (Cudd_Regular(node)->ref == 1) FREE(values); st_foreach(table, cuddStCountfree, NULL); st_free_table(table); #ifdef DD_STATS - (void) fprintf(dd->out,"Number of calls: %d\tTable memory: %d bytes\n", - num_calls, table_mem); + (void) fprintf(dd->out,"Number of calls: %d\n", dd->num_calls); (void) fprintf(dd->out,"Time to compute measures: %s\n", util_print_time(util_cpu_time() - startTime)); #endif @@ -204,26 +171,25 @@ Cudd_CofMinterm( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Recursive Step for Cudd_CofMinterm function.] +/** + @brief Recursive Step for Cudd_CofMinterm function. - Description [Traverses the DD node and computes the fraction of - minterms in the on-set of all positive cofactors simultaneously. - It allocates an array with two more entries than there are - variables below the one labeling the node. One extra entry (the - first in the array) is for the variable labeling the node. The other - entry (the last one in the array) holds the fraction of minterms of - the function rooted at node. Each other entry holds the value for - one cofactor. The array is put in a symbol table, to avoid repeated + @details Traverses the %DD node and computes the fraction of minterms + in the on-set of all positive cofactors simultaneously. It + allocates an array with two more entries than there are variables + below the one labeling the node. One extra entry (the first in the + array) is for the variable labeling the node. The other entry (the + last one in the array) holds the fraction of minterms of the + function rooted at node. Each other entry holds the value for one + cofactor. The array is put in a symbol table, to avoid repeated computation, and its address is returned by the procedure, for use - by the caller. Returns a pointer to the array of cofactor measures.] + by the caller. - SideEffects [None] + @return a pointer to the array of cofactor measures. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static double * ddCofMintermAux( DdManager * dd, @@ -237,13 +203,14 @@ ddCofMintermAux( int i; int localSize, localSizeT, localSizeE; double vT, vE; + int size = dd->size; statLine(dd); #ifdef DD_STATS - num_calls++; + dd->num_calls++; #endif - if (st_lookup(table, node, &values)) { + if (st_lookup(table, node, (void **) &values)) { return(values); } @@ -274,12 +241,12 @@ ddCofMintermAux( valuesE = ddCofMintermAux(dd, Nnv, table); if (valuesE == NULL) return(NULL); - if (Cudd_IsConstant(Nv)) { + if (Cudd_IsConstantInt(Nv)) { localSizeT = 1; } else { localSizeT = size - cuddI(dd,Cudd_Regular(Nv)->index) + 1; } - if (Cudd_IsConstant(Nnv)) { + if (Cudd_IsConstantInt(Nnv)) { localSizeE = 1; } else { localSizeE = size - cuddI(dd,Cudd_Regular(Nnv)->index) + 1; @@ -305,13 +272,10 @@ ddCofMintermAux( } if (N->ref > 1) { - if (st_add_direct(table, (char *) node, (char *) values) == ST_OUT_OF_MEM) { + if (st_add_direct(table, node, values) == ST_OUT_OF_MEM) { FREE(values); return(NULL); } -#ifdef DD_STATS - table_mem += localSize * sizeof(double) + sizeof(st_table_entry); -#endif } return(values); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSolve.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddSolve.c similarity index 64% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddSolve.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddSolve.c index e97779d8e..c1af27802 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSolve.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddSolve.c @@ -1,27 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddSolve.c] + @ingroup cudd - PackageName [cudd] + @brief Boolean equation solver and related functions. - Synopsis [Boolean equation solver and related functions.] + @author Balakrishna Kumthekar - Description [External functions included in this modoule: - <ul> - <li> Cudd_SolveEqn() - <li> Cudd_VerifySol() - </ul> - Internal functions included in this module: - <ul> - <li> cuddSolveEqnRecur() - <li> cuddVerifySol() - </ul> ] - - SeeAlso [] - - Author [Balakrishna Kumthekar] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -51,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -77,23 +65,18 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddSolve.c,v 1.13 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -101,31 +84,30 @@ static char rcsid[] DD_UNUSED = "$Id: cuddSolve.c,v 1.13 2012/02/05 01:07:19 fab /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Implements the solution of F(x,y) = 0. - Synopsis [Implements the solution of F(x,y) = 0.] + @details The return value is the consistency condition. The y + variables are the unknowns and the remaining variables are the + parameters. Cudd_SolveEqn allocates an array and fills it with the + indices of the unknowns. This array is used by Cudd_VerifySol. - Description [Implements the solution for F(x,y) = 0. The return - value is the consistency condition. The y variables are the unknowns - and the remaining variables are the parameters. Returns the - consistency condition if successful; NULL otherwise. Cudd_SolveEqn - allocates an array and fills it with the indices of the - unknowns. This array is used by Cudd_VerifySol.] + @return the consistency condition if successful; NULL otherwise. - SideEffects [The solution is returned in G; the indices of the y - variables are returned in yIndex.] + @sideeffect The solution is returned in G; the indices of the y + variables are returned in yIndex. - SeeAlso [Cudd_VerifySol] + @see Cudd_VerifySol -******************************************************************************/ +*/ DdNode * Cudd_SolveEqn( - DdManager * bdd, - DdNode * F /* the left-hand side of the equation */, - DdNode * Y /* the cube of the y variables */, - DdNode ** G /* the array of solutions (return parameter) */, - int ** yIndex /* index of y variables */, - int n /* numbers of unknowns */) + DdManager * bdd /**< CUDD manager */, + DdNode * F /**< the left-hand side of the equation */, + DdNode * Y /**< the cube of the y variables */, + DdNode ** G /**< the array of solutions (return parameter) */, + int ** yIndex /**< index of y variables */, + int n /**< numbers of unknowns */) { DdNode *res; int *temp; @@ -142,32 +124,33 @@ Cudd_SolveEqn( bdd->reordered = 0; res = cuddSolveEqnRecur(bdd, F, Y, G, n, temp, 0); } while (bdd->reordered == 1); + if (bdd->errorCode == CUDD_TIMEOUT_EXPIRED && bdd->timeoutHandler) { + bdd->timeoutHandler(bdd, bdd->tohArg); + } return(res); } /* end of Cudd_SolveEqn */ -/**Function******************************************************************** +/** + @brief Checks the solution of F(x,y) = 0. - Synopsis [Checks the solution of F(x,y) = 0.] + @details This procedure substitutes the solution components for the + unknowns of F and returns the resulting %BDD for F. - Description [Checks the solution of F(x,y) = 0. This procedure - substitutes the solution components for the unknowns of F and returns - the resulting BDD for F.] + @sideeffect Frees the memory pointed by yIndex. - SideEffects [Frees the memory pointed by yIndex.] + @see Cudd_SolveEqn - SeeAlso [Cudd_SolveEqn] - -******************************************************************************/ +*/ DdNode * Cudd_VerifySol( - DdManager * bdd, - DdNode * F /* the left-hand side of the equation */, - DdNode ** G /* the array of solutions */, - int * yIndex /* index of y variables */, - int n /* numbers of unknowns */) + DdManager * bdd /**< CUDD manager */, + DdNode * F /**< the left-hand side of the equation */, + DdNode ** G /**< the array of solutions */, + int * yIndex /**< index of y variables */, + int n /**< numbers of unknowns */) { DdNode *res; @@ -177,6 +160,9 @@ Cudd_VerifySol( } while (bdd->reordered == 1); FREE(yIndex); + if (bdd->errorCode == CUDD_TIMEOUT_EXPIRED && bdd->timeoutHandler) { + bdd->timeoutHandler(bdd, bdd->tohArg); + } return(res); @@ -188,29 +174,26 @@ Cudd_VerifySol( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Implements the recursive step of Cudd_SolveEqn.] +/** + @brief Implements the recursive step of Cudd_SolveEqn. - Description [Implements the recursive step of Cudd_SolveEqn. - Returns NULL if the intermediate solution blows up - or reordering occurs. The parametric solutions are - stored in the array G.] + @return NULL if the intermediate solution blows up or reordering + occurs. - SideEffects [none] + @sideeffect The parametric solutions are stored in the array G. - SeeAlso [Cudd_SolveEqn, Cudd_VerifySol] + @see Cudd_SolveEqn, Cudd_VerifySol -******************************************************************************/ +*/ DdNode * cuddSolveEqnRecur( - DdManager * bdd, - DdNode * F /* the left-hand side of the equation */, - DdNode * Y /* the cube of remaining y variables */, - DdNode ** G /* the array of solutions */, - int n /* number of unknowns */, - int * yIndex /* array holding the y variable indices */, - int i /* level of recursion */) + DdManager * bdd /**< CUDD manager */, + DdNode * F /**< the left-hand side of the equation */, + DdNode * Y /**< the cube of remaining y variables */, + DdNode ** G /**< the array of solutions */, + int n /**< number of unknowns */, + int * yIndex /**< array holding the y variable indices */, + int i /**< level of recursion */) { DdNode *Fn, *Fm1, *Fv, *Fvbar, *T, *w, *nextY, *one; DdNodePtr *variables; @@ -317,24 +300,21 @@ cuddSolveEqnRecur( } /* end of cuddSolveEqnRecur */ -/**Function******************************************************************** - - Synopsis [Implements the recursive step of Cudd_VerifySol. ] - - Description [] +/** + @brief Implements the recursive step of Cudd_VerifySol. - SideEffects [none] + @sideeffect none - SeeAlso [Cudd_VerifySol] + @see Cudd_VerifySol -******************************************************************************/ +*/ DdNode * cuddVerifySol( - DdManager * bdd, - DdNode * F /* the left-hand side of the equation */, - DdNode ** G /* the array of solutions */, - int * yIndex /* array holding the y variable indices */, - int n /* number of unknowns */) + DdManager * bdd /**< CUDD manager */, + DdNode * F /**< the left-hand side of the equation */, + DdNode ** G /**< the array of solutions */, + int * yIndex /**< array holding the y variable indices */, + int n /**< number of unknowns */) { DdNode *w, *R; diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSplit.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddSplit.c similarity index 76% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddSplit.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddSplit.c index 11fe86267..f806f6d63 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSplit.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddSplit.c @@ -1,31 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddSplit.c] + @ingroup cudd - PackageName [cudd] + @brief Returns a subset of minterms from a boolean function. - Synopsis [Returns a subset of minterms from a boolean function.] + @author Balakrishna Kumthekar - Description [External functions included in this modoule: - <ul> - <li> Cudd_SplitSet() - </ul> - Internal functions included in this module: - <ul> - <li> cuddSplitSetRecur() - </u> - Static functions included in this module: - <ul> - <li> selectMintermsFromUniverse() - <li> mintermsFromUniverse() - <li> bddAnnotateMintermCount() - </ul> ] - - SeeAlso [] - - Author [Balakrishna Kumthekar] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -55,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -85,8 +69,7 @@ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -96,7 +79,7 @@ static DdNode * selectMintermsFromUniverse (DdManager *manager, int *varSeen, do static DdNode * mintermsFromUniverse (DdManager *manager, DdNode **vars, int numVars, double n, int index); static double bddAnnotateMintermCount (DdManager *manager, DdNode *node, double max, st_table *table); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -104,22 +87,21 @@ static double bddAnnotateMintermCount (DdManager *manager, DdNode *node, double /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Returns m minterms from a BDD.] +/** + @brief Returns m minterms from a %BDD. - Description [Returns <code>m</code> minterms from a BDD whose + @details Returns <code>m</code> minterms from a %BDD whose support has <code>n</code> variables at most. The procedure tries to create as few extra nodes as possible. The function represented by <code>S</code> depends on at most <code>n</code> of the variables - in <code>xVars</code>. Returns a BDD with <code>m</code> minterms - of the on-set of S if successful; NULL otherwise.] + in <code>xVars</code>. - SideEffects [None] + @return a %BDD with <code>m</code> minterms of the on-set of S if + successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * Cudd_SplitSet( DdManager * manager, @@ -193,7 +175,7 @@ Cudd_SplitSet( */ num = bddAnnotateMintermCount(manager,S,max,mtable); if (m == num) { - st_foreach(mtable,cuddStCountfree,NIL(char)); + st_foreach(mtable,cuddStCountfree,NIL(void)); st_free_table(mtable); FREE(varSeen); return(S); @@ -207,6 +189,9 @@ Cudd_SplitSet( FREE(varSeen); } } while (manager->reordered == 1); + if (manager->errorCode == CUDD_TIMEOUT_EXPIRED && manager->timeoutHandler) { + manager->timeoutHandler(manager, manager->tohArg); + } cuddDeref(result); return(result); @@ -218,27 +203,23 @@ Cudd_SplitSet( /* Definition of internal functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Implements the recursive step of Cudd_SplitSet. - Synopsis [Implements the recursive step of Cudd_SplitSet.] + @details The procedure recursively traverses the %BDD and checks to + see if any node satisfies the minterm requirements as specified by + 'n'. At any node X, n is compared to the number of minterms in the + onset of X's children. If either of the child nodes have exactly n + minterms, then that node is returned; else, if n is greater than the + onset of one of the child nodes, that node is retained and the + difference in the number of minterms is extracted from the other + child. In case n minterms can be extracted from constant 1, the + algorithm returns the result with at most log(n) nodes. - Description [Implements the recursive step of Cudd_SplitSet. The - procedure recursively traverses the BDD and checks to see if any - node satisfies the minterm requirements as specified by 'n'. At any - node X, n is compared to the number of minterms in the onset of X's - children. If either of the child nodes have exactly n minterms, then - that node is returned; else, if n is greater than the onset of one - of the child nodes, that node is retained and the difference in the - number of minterms is extracted from the other child. In case n - minterms can be extracted from constant 1, the algorithm returns the - result with at most log(n) nodes.] + @sideeffect The array 'varSeen' is updated at every recursive call + to set the variables traversed by the procedure. - SideEffects [The array 'varSeen' is updated at every recursive call - to set the variables traversed by the procedure.] - - SeeAlso [] - -******************************************************************************/ +*/ DdNode* cuddSplitSetRecur( DdManager * manager, @@ -263,7 +244,7 @@ cuddSplitSetRecur( ** construction guarantees that minterms will not be extracted from ** constant 0. */ - if (Cudd_IsConstant(p)) { + if (Cudd_IsConstantInt(p)) { q = selectMintermsFromUniverse(manager,varSeen,n); return(q); } @@ -284,7 +265,7 @@ cuddSplitSetRecur( /* If both the children of 'p' are constants, extract n minterms from a ** constant node. */ - if (Cudd_IsConstant(Nv) && Cudd_IsConstant(Nnv)) { + if (Cudd_IsConstantInt(Nv) && Cudd_IsConstantInt(Nnv)) { q = selectMintermsFromUniverse(manager,varSeen,n); if (q == NULL) { return(NULL); @@ -302,20 +283,20 @@ cuddSplitSetRecur( } /* Lookup the # of minterms in the onset of the node from the table. */ - if (!Cudd_IsConstant(Nv)) { - if (!st_lookup(mtable, Nv, &dummy)) return(NULL); - numT = *dummy/(2*(1<<index)); + if (!Cudd_IsConstantInt(Nv)) { + if (!st_lookup(mtable, Nv, (void **) &dummy)) return(NULL); + numT = *dummy/(2*(1U<<index)); } else if (Nv == one) { - numT = max/(2*(1<<index)); + numT = max/(2*(1U<<index)); } else { numT = 0; } - if (!Cudd_IsConstant(Nnv)) { - if (!st_lookup(mtable, Nnv, &dummy)) return(NULL); - numE = *dummy/(2*(1<<index)); + if (!Cudd_IsConstantInt(Nnv)) { + if (!st_lookup(mtable, Nnv, (void **) &dummy)) return(NULL); + numE = *dummy/(2*(1U<<index)); } else if (Nnv == one) { - numE = max/(2*(1<<index)); + numE = max/(2*(1U<<index)); } else { numE = 0; } @@ -397,7 +378,7 @@ cuddSplitSetRecur( ** the Nv, Nnv or both are not constants. If possible extract the ** required minterms the constant branch. */ - if (Cudd_IsConstant(Nv) && !Cudd_IsConstant(Nnv)) { + if (Cudd_IsConstantInt(Nv) && !Cudd_IsConstantInt(Nnv)) { q = selectMintermsFromUniverse(manager,varSeen,n); if (q == NULL) { Cudd_RecursiveDeref(manager,v); @@ -415,7 +396,7 @@ cuddSplitSetRecur( Cudd_RecursiveDeref(manager,v); cuddDeref(result); return(result); - } else if (!Cudd_IsConstant(Nv) && Cudd_IsConstant(Nnv)) { + } else if (!Cudd_IsConstantInt(Nv) && Cudd_IsConstantInt(Nnv)) { q = selectMintermsFromUniverse(manager,varSeen,n); if (q == NULL) { Cudd_RecursiveDeref(manager,v); @@ -478,19 +459,17 @@ cuddSplitSetRecur( /* Definition of static functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [This function prepares an array of variables which have not been - encountered so far when traversing the procedure cuddSplitSetRecur.] +/** + @brief This function prepares an array of variables which have not been + encountered so far when traversing the procedure cuddSplitSetRecur. - Description [This function prepares an array of variables which have not been - encountered so far when traversing the procedure cuddSplitSetRecur. This - array is then used to extract the required number of minterms from a constant - 1. The algorithm guarantees that the size of BDD will be utmost \log(n).] + @details This array is then used to extract the required number of + minterms from a constant 1. The algorithm guarantees that the size + of %BDD will be at most log(n). - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static DdNode * selectMintermsFromUniverse( DdManager * manager, @@ -545,15 +524,12 @@ selectMintermsFromUniverse( } /* end of selectMintermsFromUniverse */ -/**Function******************************************************************** +/** + @brief Recursive procedure to extract n mintems from constant 1. - Synopsis [Recursive procedure to extract n mintems from constant 1.] + @sideeffect None - Description [Recursive procedure to extract n mintems from constant 1.] - - SideEffects [None] - -******************************************************************************/ +*/ static DdNode * mintermsFromUniverse( DdManager * manager, @@ -614,17 +590,15 @@ mintermsFromUniverse( } /* end of mintermsFromUniverse */ -/**Function******************************************************************** - - Synopsis [Annotates every node in the BDD node with its minterm count.] +/** + @brief Annotates every node in the %BDD node with its minterm count. - Description [Annotates every node in the BDD node with its minterm count. - In this function, every node and the minterm count represented by it are - stored in a hash table.] + @details In this function, every node and the minterm count + represented by it are stored in a hash table. - SideEffects [Fills up 'table' with the pair <node,minterm_count>.] + @sideeffect Fills up 'table' with the pair <node,minterm_count>. -******************************************************************************/ +*/ static double bddAnnotateMintermCount( DdManager * manager, @@ -634,8 +608,8 @@ bddAnnotateMintermCount( { DdNode *N,*Nv,*Nnv; - register double min_v,min_nv; - register double min_N; + double min_v,min_nv; + double min_N; double *pmin; double *dummy; @@ -649,7 +623,7 @@ bddAnnotateMintermCount( } } - if (st_lookup(table, node, &dummy)) { + if (st_lookup(table, node, (void **) &dummy)) { return(*dummy); } @@ -676,7 +650,7 @@ bddAnnotateMintermCount( } *pmin = min_N; - if (st_insert(table,(char *)node, (char *)pmin) == ST_OUT_OF_MEM) { + if (st_insert(table, node, pmin) == ST_OUT_OF_MEM) { FREE(pmin); return((double)CUDD_OUT_OF_MEM); } diff --git a/resources/3rdparty/cudd-3.0.0/cudd/cuddSubsetHB.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddSubsetHB.c new file mode 100644 index 000000000..793b01322 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddSubsetHB.c @@ -0,0 +1,1310 @@ +/** + @file + + @ingroup cudd + + @brief Procedure to subset the given %BDD by choosing the heavier + branches. + + @see cuddSubsetSP.c + + @author Kavita Ravi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#ifdef __STDC__ +#include <float.h> +#else +#define DBL_MAX_EXP 1024 +#endif +#include "util.h" +#include "cuddInt.h" + +/*---------------------------------------------------------------------------*/ +/* Constant declarations */ +/*---------------------------------------------------------------------------*/ + +#define DEFAULT_PAGE_SIZE 2048 +#define DEFAULT_NODE_DATA_PAGE_SIZE 1024 +#define INITIAL_PAGES 128 + +#undef max + +/*---------------------------------------------------------------------------*/ +/* Type declarations */ +/*---------------------------------------------------------------------------*/ + +typedef struct NodeData NodeData_t; + +typedef struct SubsetInfo SubsetInfo_t; + +/*---------------------------------------------------------------------------*/ +/* Stucture declarations */ +/*---------------------------------------------------------------------------*/ + +/** + * @brief Data structure to store the information on each node. + + * @details It keeps the number of minterms represented by the DAG + * rooted at this node in terms of the number of variables specified + * by the user, number of nodes in this DAG and the number of nodes of + * its child with lesser number of minterms that are not shared by the + * child with more minterms. + */ +struct NodeData { + double *mintermPointer; + int *nodesPointer; + int *lightChildNodesPointer; +}; + +/** + * @brief Miscellaneous info. + */ +struct SubsetInfo { + DdNode *zero, *one; /**< constant functions */ + double **mintermPages; /**< pointers to the pages */ + int **nodePages; /**< pointers to the pages */ + int **lightNodePages; /**< pointers to the pages */ + double *currentMintermPage; /**< pointer to the current page */ + double max; /**< to store the 2^n value of the number of variables */ + int *currentNodePage; /**< pointer to the current page */ + int *currentLightNodePage; /**< pointer to the current page */ + int pageIndex; /**< index to next element */ + int page; /**< index to current page */ + int pageSize; /**< page size */ + int maxPages; /**< number of page pointers */ + NodeData_t *currentNodeDataPage; /**< pointer to the current page */ + int nodeDataPage; /**< index to next element */ + int nodeDataPageIndex; /**< index to next element */ + NodeData_t **nodeDataPages; /**< index to current page */ + int nodeDataPageSize; /**< page size */ + int maxNodeDataPages; /**< number of page pointers */ + int memOut; +#ifdef DEBUG + int num_calls; +#endif +}; + +/*---------------------------------------------------------------------------*/ +/* Variable declarations */ +/*---------------------------------------------------------------------------*/ + + +/*---------------------------------------------------------------------------*/ +/* Macro declarations */ +/*---------------------------------------------------------------------------*/ + +/** \cond */ + +/*---------------------------------------------------------------------------*/ +/* Static function prototypes */ +/*---------------------------------------------------------------------------*/ + +static void ResizeNodeDataPages (SubsetInfo_t * info); +static void ResizeCountMintermPages (SubsetInfo_t * info); +static void ResizeCountNodePages (SubsetInfo_t * info); +static double SubsetCountMintermAux (DdNode *node, double max, st_table *table, SubsetInfo_t * info); +static st_table * SubsetCountMinterm (DdNode *node, int nvars, SubsetInfo_t * info); +static int SubsetCountNodesAux (DdNode *node, st_table *table, double max, SubsetInfo_t * info); +static int SubsetCountNodes (DdNode *node, st_table *table, int nvars, SubsetInfo_t * info); +static void StoreNodes (st_table *storeTable, DdManager *dd, DdNode *node); +static DdNode * BuildSubsetBdd (DdManager *dd, DdNode *node, int *size, st_table *visitedTable, int threshold, st_table *storeTable, st_table *approxTable, SubsetInfo_t * info); + +/** \endcond */ + + +/*---------------------------------------------------------------------------*/ +/* Definition of exported functions */ +/*---------------------------------------------------------------------------*/ + +/** + @brief Extracts a dense subset from a %BDD with the heavy branch + heuristic. + + @details This procedure builds a subset by throwing away one of the + children of each node, starting from the root, until the result is + small enough. The child that is eliminated from the result is the + one that contributes the fewer minterms. The parameter numVars is + the maximum number of variables to be used in minterm calculation + and node count calculation. The optimal number should be as close + as possible to the size of the support of f. However, it is safe to + pass the value returned by Cudd_ReadSize for numVars when the number + of variables is under 1023. If numVars is larger than 1023, it will + overflow. If a 0 parameter is passed then the procedure will compute + a value which will avoid overflow but will cause underflow with 2046 + variables or more. + + @return a pointer to the %BDD of the subset if successful. NULL if + the procedure runs out of memory. + + @sideeffect None + + @see Cudd_SubsetShortPaths Cudd_SupersetHeavyBranch Cudd_ReadSize + +*/ +DdNode * +Cudd_SubsetHeavyBranch( + DdManager * dd /**< manager */, + DdNode * f /**< function to be subset */, + int numVars /**< number of variables in the support of f */, + int threshold /**< maximum number of nodes in the subset */) +{ + DdNode *subset; + + do { + dd->reordered = 0; + subset = cuddSubsetHeavyBranch(dd, f, numVars, threshold); + } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + + return(subset); + +} /* end of Cudd_SubsetHeavyBranch */ + + +/** + @brief Extracts a dense superset from a %BDD with the heavy branch + heuristic. + + @details The procedure is identical to the subset procedure except + for the fact that it receives the complement of the given + function. Extracting the subset of the complement function is + equivalent to extracting the superset of the function. This + procedure builds a superset by throwing away one of the children of + each node starting from the root of the complement function, until + the result is small enough. The child that is eliminated from the + result is the one that contributes the fewer minterms. The + parameter numVars is the maximum number of variables to be used in + minterm calculation and node count calculation. The optimal number + should be as close as possible to the size of the support of f. + However, it is safe to pass the value returned by Cudd_ReadSize for + numVars when the number of variables is under 1023. If numVars is + larger than 1023, it will overflow. If a 0 parameter is passed then + the procedure will compute a value which will avoid overflow but + will cause underflow with 2046 variables or more. + + @return a pointer to the %BDD of the superset if successful. NULL if + intermediate result causes the procedure to run out of memory. + + @sideeffect None + + @see Cudd_SubsetHeavyBranch Cudd_SupersetShortPaths Cudd_ReadSize + +*/ +DdNode * +Cudd_SupersetHeavyBranch( + DdManager * dd /**< manager */, + DdNode * f /**< function to be superset */, + int numVars /**< number of variables in the support of f */, + int threshold /**< maximum number of nodes in the superset */) +{ + DdNode *subset, *g; + + g = Cudd_Not(f); + do { + dd->reordered = 0; + subset = cuddSubsetHeavyBranch(dd, g, numVars, threshold); + } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } + + return(Cudd_NotCond(subset, (subset != NULL))); + +} /* end of Cudd_SupersetHeavyBranch */ + + +/*---------------------------------------------------------------------------*/ +/* Definition of internal functions */ +/*---------------------------------------------------------------------------*/ + + +/** + @brief The main procedure that returns a subset by choosing the heavier + branch in the %BDD. + + @details Here a subset %BDD is built by throwing away one of the + children. Starting at root, annotate each node with the number of + minterms (in terms of the total number of variables specified - + numVars), number of nodes taken by the DAG rooted at this node and + number of additional nodes taken by the child that has the lesser + minterms. The child with the lower number of minterms is thrown away + and a dyanmic count of the nodes of the subset is kept. Once the + threshold is reached the subset is returned to the calling + procedure. + + @sideeffect None + + @see Cudd_SubsetHeavyBranch + +*/ +DdNode * +cuddSubsetHeavyBranch( + DdManager * dd /**< %DD manager */, + DdNode * f /**< current %DD */, + int numVars /**< maximum number of variables */, + int threshold /**< threshold size for the subset */) +{ + + int i, *size; + st_table *visitedTable; + int numNodes; + NodeData_t *currNodeQual; + DdNode *subset; + st_table *storeTable, *approxTable; + DdNode *key, *value; + st_generator *stGen; + SubsetInfo_t info; + + if (f == NULL) { + fprintf(dd->err, "Cannot subset, nil object\n"); + dd->errorCode = CUDD_INVALID_ARG; + return(NULL); + } + + /* If user does not know numVars value, set it to the maximum + * exponent that the pow function can take. The -1 is due to the + * discrepancy in the value that pow takes and the value that + * log gives. + */ + if (numVars == 0) { + /* set default value */ + numVars = DBL_MAX_EXP - 1; + } + + if (Cudd_IsConstantInt(f)) { + return(f); + } + + info.one = Cudd_ReadOne(dd); + info.zero = Cudd_Not(info.one); + info.mintermPages = NULL; + info.nodePages = info.lightNodePages = NULL; + info.currentMintermPage = NULL; + info.max = pow(2.0, (double)numVars); + info.currentNodePage = info.currentLightNodePage = NULL; + info.pageIndex = info.page = 0; + info.pageSize = DEFAULT_PAGE_SIZE; + info.maxPages = 0; + info.currentNodeDataPage = NULL; + info.nodeDataPage = info.nodeDataPageIndex = 0; + info.nodeDataPages = NULL; + info.nodeDataPageSize = DEFAULT_NODE_DATA_PAGE_SIZE; + info.maxNodeDataPages = 0; + info.memOut = 0; +#ifdef DEBUG + info.num_calls = 0; +#endif + + /* Create visited table where structures for node data are allocated and + stored in a st_table */ + visitedTable = SubsetCountMinterm(f, numVars, &info); + if ((visitedTable == NULL) || info.memOut) { + (void) fprintf(dd->err, "Out-of-memory; Cannot subset\n"); + dd->errorCode = CUDD_MEMORY_OUT; + return(0); + } + numNodes = SubsetCountNodes(f, visitedTable, numVars, &info); + if (info.memOut) { + (void) fprintf(dd->err, "Out-of-memory; Cannot subset\n"); + dd->errorCode = CUDD_MEMORY_OUT; + return(0); + } + + if (st_lookup(visitedTable, f, (void **) &currNodeQual) == 0) { + fprintf(dd->err, + "Something is wrong, ought to be node quality table\n"); + dd->errorCode = CUDD_INTERNAL_ERROR; + } + + size = ALLOC(int, 1); + if (size == NULL) { + dd->errorCode = CUDD_MEMORY_OUT; + return(NULL); + } + *size = numNodes; + + /* table to store nodes being created. */ + storeTable = st_init_table(st_ptrcmp, st_ptrhash); + /* insert the constant */ + cuddRef(info.one); + if (st_insert(storeTable, Cudd_ReadOne(dd), NULL) == + ST_OUT_OF_MEM) { + fprintf(dd->out, "Something wrong, st_table insert failed\n"); + } + /* table to store approximations of nodes */ + approxTable = st_init_table(st_ptrcmp, st_ptrhash); + subset = (DdNode *)BuildSubsetBdd(dd, f, size, visitedTable, threshold, + storeTable, approxTable, &info); + if (subset != NULL) { + cuddRef(subset); + } + + if (info.memOut) { + dd->errorCode = CUDD_MEMORY_OUT; + dd->reordered = 0; + } + + stGen = st_init_gen(approxTable); + if (stGen == NULL) { + st_free_table(approxTable); + return(NULL); + } + while(st_gen(stGen, (void **) &key, (void **) &value)) { + Cudd_RecursiveDeref(dd, value); + } + st_free_gen(stGen); stGen = NULL; + st_free_table(approxTable); + + stGen = st_init_gen(storeTable); + if (stGen == NULL) { + st_free_table(storeTable); + return(NULL); + } + while(st_gen(stGen, (void **) &key, (void **) &value)) { + Cudd_RecursiveDeref(dd, key); + } + st_free_gen(stGen); stGen = NULL; + st_free_table(storeTable); + + for (i = 0; i <= info.page; i++) { + FREE(info.mintermPages[i]); + } + FREE(info.mintermPages); + for (i = 0; i <= info.page; i++) { + FREE(info.nodePages[i]); + } + FREE(info.nodePages); + for (i = 0; i <= info.page; i++) { + FREE(info.lightNodePages[i]); + } + FREE(info.lightNodePages); + for (i = 0; i <= info.nodeDataPage; i++) { + FREE(info.nodeDataPages[i]); + } + FREE(info.nodeDataPages); + st_free_table(visitedTable); + FREE(size); +#if 0 + (void) Cudd_DebugCheck(dd); + (void) Cudd_CheckKeys(dd); +#endif + + if (subset != NULL) { +#ifdef DD_DEBUG + if (!Cudd_bddLeq(dd, subset, f)) { + fprintf(dd->err, "Wrong subset\n"); + dd->errorCode = CUDD_INTERNAL_ERROR; + return(NULL); + } +#endif + cuddDeref(subset); + } + return(subset); + +} /* end of cuddSubsetHeavyBranch */ + + +/*---------------------------------------------------------------------------*/ +/* Definition of static functions */ +/*---------------------------------------------------------------------------*/ + + +/** + @brief Resize the number of pages allocated to store the node data. + + @details The procedure moves the counter to the next page when the + end of the page is reached and allocates new pages when necessary. + + @sideeffect Changes the size of pages, page, page index, maximum + number of pages freeing stuff in case of memory out. + +*/ +static void +ResizeNodeDataPages(SubsetInfo_t * info) +{ + int i; + NodeData_t **newNodeDataPages; + + info->nodeDataPage++; + /* If the current page index is larger than the number of pages + * allocated, allocate a new page array. Page numbers are incremented by + * INITIAL_PAGES + */ + if (info->nodeDataPage == info->maxNodeDataPages) { + newNodeDataPages = ALLOC(NodeData_t *, info->maxNodeDataPages + INITIAL_PAGES); + if (newNodeDataPages == NULL) { + for (i = 0; i < info->nodeDataPage; i++) FREE(info->nodeDataPages[i]); + FREE(info->nodeDataPages); + info->memOut = 1; + return; + } else { + for (i = 0; i < info->maxNodeDataPages; i++) { + newNodeDataPages[i] = info->nodeDataPages[i]; + } + /* Increase total page count */ + info->maxNodeDataPages += INITIAL_PAGES; + FREE(info->nodeDataPages); + info->nodeDataPages = newNodeDataPages; + } + } + /* Allocate a new page */ + info->currentNodeDataPage = info->nodeDataPages[info->nodeDataPage] = + ALLOC(NodeData_t ,info->nodeDataPageSize); + if (info->currentNodeDataPage == NULL) { + for (i = 0; i < info->nodeDataPage; i++) FREE(info->nodeDataPages[i]); + FREE(info->nodeDataPages); + info->memOut = 1; + return; + } + /* reset page index */ + info->nodeDataPageIndex = 0; + return; + +} /* end of ResizeNodeDataPages */ + + +/** + @brief Resize the number of pages allocated to store the minterm + counts. + + @details The procedure moves the counter to the next page when the + end of the page is reached and allocates new pages when necessary. + + @sideeffect Changes the size of minterm pages, page, page index, maximum + number of pages freeing stuff in case of memory out. + +*/ +static void +ResizeCountMintermPages(SubsetInfo_t * info) +{ + int i; + double **newMintermPages; + + info->page++; + /* If the current page index is larger than the number of pages + * allocated, allocate a new page array. Page numbers are incremented by + * INITIAL_PAGES + */ + if (info->page == info->maxPages) { + newMintermPages = ALLOC(double *, info->maxPages + INITIAL_PAGES); + if (newMintermPages == NULL) { + for (i = 0; i < info->page; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + info->memOut = 1; + return; + } else { + for (i = 0; i < info->maxPages; i++) { + newMintermPages[i] = info->mintermPages[i]; + } + /* Increase total page count */ + info->maxPages += INITIAL_PAGES; + FREE(info->mintermPages); + info->mintermPages = newMintermPages; + } + } + /* Allocate a new page */ + info->currentMintermPage = info->mintermPages[info->page] = ALLOC(double,info->pageSize); + if (info->currentMintermPage == NULL) { + for (i = 0; i < info->page; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + info->memOut = 1; + return; + } + /* reset page index */ + info->pageIndex = 0; + return; + +} /* end of ResizeCountMintermPages */ + + +/** + @brief Resize the number of pages allocated to store the node counts. + + @details The procedure moves the counter to the next page when the + end of the page is reached and allocates new pages when necessary. + + @sideeffect Changes the size of pages, page, page index, maximum + number of pages freeing stuff in case of memory out. + +*/ +static void +ResizeCountNodePages(SubsetInfo_t * info) +{ + int i; + int **newNodePages; + + info->page++; + + /* If the current page index is larger than the number of pages + * allocated, allocate a new page array. The number of pages is incremented + * by INITIAL_PAGES. + */ + if (info->page == info->maxPages) { + newNodePages = ALLOC(int *, info->maxPages + INITIAL_PAGES); + if (newNodePages == NULL) { + for (i = 0; i < info->page; i++) FREE(info->nodePages[i]); + FREE(info->nodePages); + for (i = 0; i < info->page; i++) FREE(info->lightNodePages[i]); + FREE(info->lightNodePages); + info->memOut = 1; + return; + } else { + for (i = 0; i < info->maxPages; i++) { + newNodePages[i] = info->nodePages[i]; + } + FREE(info->nodePages); + info->nodePages = newNodePages; + } + + newNodePages = ALLOC(int *, info->maxPages + INITIAL_PAGES); + if (newNodePages == NULL) { + for (i = 0; i < info->page; i++) FREE(info->nodePages[i]); + FREE(info->nodePages); + for (i = 0; i < info->page; i++) FREE(info->lightNodePages[i]); + FREE(info->lightNodePages); + info->memOut = 1; + return; + } else { + for (i = 0; i < info->maxPages; i++) { + newNodePages[i] = info->lightNodePages[i]; + } + FREE(info->lightNodePages); + info->lightNodePages = newNodePages; + } + /* Increase total page count */ + info->maxPages += INITIAL_PAGES; + } + /* Allocate a new page */ + info->currentNodePage = info->nodePages[info->page] = ALLOC(int,info->pageSize); + if (info->currentNodePage == NULL) { + for (i = 0; i < info->page; i++) FREE(info->nodePages[i]); + FREE(info->nodePages); + for (i = 0; i < info->page; i++) FREE(info->lightNodePages[i]); + FREE(info->lightNodePages); + info->memOut = 1; + return; + } + /* Allocate a new page */ + info->currentLightNodePage = info->lightNodePages[info->page] + = ALLOC(int,info->pageSize); + if (info->currentLightNodePage == NULL) { + for (i = 0; i <= info->page; i++) FREE(info->nodePages[i]); + FREE(info->nodePages); + for (i = 0; i < info->page; i++) FREE(info->lightNodePages[i]); + FREE(info->lightNodePages); + info->memOut = 1; + return; + } + /* reset page index */ + info->pageIndex = 0; + return; + +} /* end of ResizeCountNodePages */ + + +/** + @brief Recursively counts minterms of each node in the DAG. + + @details Similar to the cuddCountMintermAux which recursively counts + the number of minterms for the dag rooted at each node in terms of + the total number of variables (max). This procedure creates the node + data structure and stores the minterm count as part of the node data + structure. + + @sideeffect Creates structures of type node quality and fills the st_table + + @see SubsetCountMinterm + +*/ +static double +SubsetCountMintermAux( + DdNode * node /**< function to analyze */, + double max /**< number of minterms of constant 1 */, + st_table * table /**< visitedTable table */, + SubsetInfo_t * info /**< miscellaneous info */) +{ + + DdNode *N,*Nv,*Nnv; /* nodes to store cofactors */ + double min,*pmin; /* minterm count */ + double min1, min2; /* minterm count */ + NodeData_t *dummy; + NodeData_t *newEntry; + int i; + +#ifdef DEBUG + info->num_calls++; +#endif + + /* Constant case */ + if (Cudd_IsConstantInt(node)) { + if (node == info->zero) { + return(0.0); + } else { + return(max); + } + } else { + + /* check if entry for this node exists */ + if (st_lookup(table, node, (void **) &dummy)) { + min = *(dummy->mintermPointer); + return(min); + } + + /* Make the node regular to extract cofactors */ + N = Cudd_Regular(node); + + /* store the cofactors */ + Nv = Cudd_T(N); + Nnv = Cudd_E(N); + + Nv = Cudd_NotCond(Nv, Cudd_IsComplement(node)); + Nnv = Cudd_NotCond(Nnv, Cudd_IsComplement(node)); + + min1 = SubsetCountMintermAux(Nv, max,table,info)/2.0; + if (info->memOut) return(0.0); + min2 = SubsetCountMintermAux(Nnv,max,table,info)/2.0; + if (info->memOut) return(0.0); + min = (min1+min2); + + /* if page index is at the bottom, then create a new page */ + if (info->pageIndex == info->pageSize) ResizeCountMintermPages(info); + if (info->memOut) { + for (i = 0; i <= info->nodeDataPage; i++) FREE(info->nodeDataPages[i]); + FREE(info->nodeDataPages); + st_free_table(table); + return(0.0); + } + + /* point to the correct location in the page */ + pmin = info->currentMintermPage + info->pageIndex; + info->pageIndex++; + + /* store the minterm count of this node in the page */ + *pmin = min; + + /* Note I allocate the struct here. Freeing taken care of later */ + if (info->nodeDataPageIndex == info->nodeDataPageSize) + ResizeNodeDataPages(info); + if (info->memOut) { + for (i = 0; i <= info->page; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + st_free_table(table); + return(0.0); + } + + newEntry = info->currentNodeDataPage + info->nodeDataPageIndex; + info->nodeDataPageIndex++; + + /* points to the correct location in the page */ + newEntry->mintermPointer = pmin; + /* initialize this field of the Node Quality structure */ + newEntry->nodesPointer = NULL; + + /* insert entry for the node in the table */ + if (st_insert(table,node, newEntry) == ST_OUT_OF_MEM) { + info->memOut = 1; + for (i = 0; i <= info->page; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + for (i = 0; i <= info->nodeDataPage; i++) FREE(info->nodeDataPages[i]); + FREE(info->nodeDataPages); + st_free_table(table); + return(0.0); + } + return(min); + } + +} /* end of SubsetCountMintermAux */ + + +/** + @brief Counts minterms of each node in the DAG + + @details Similar to the Cudd_CountMinterm procedure except this + returns the minterm count for all the nodes in the bdd in an + st_table. + + @sideeffect none + + @see SubsetCountMintermAux + +*/ +static st_table * +SubsetCountMinterm( + DdNode * node /**< function to be analyzed */, + int nvars /**< number of variables node depends on */, + SubsetInfo_t * info /**< miscellaneous info */) +{ + st_table *table; + int i; + + +#ifdef DEBUG + info->num_calls = 0; +#endif + + info->max = pow(2.0,(double) nvars); + table = st_init_table(st_ptrcmp,st_ptrhash); + if (table == NULL) goto OUT_OF_MEM; + info->maxPages = INITIAL_PAGES; + info->mintermPages = ALLOC(double *,info->maxPages); + if (info->mintermPages == NULL) { + st_free_table(table); + goto OUT_OF_MEM; + } + info->page = 0; + info->currentMintermPage = ALLOC(double,info->pageSize); + info->mintermPages[info->page] = info->currentMintermPage; + if (info->currentMintermPage == NULL) { + FREE(info->mintermPages); + st_free_table(table); + goto OUT_OF_MEM; + } + info->pageIndex = 0; + info->maxNodeDataPages = INITIAL_PAGES; + info->nodeDataPages = ALLOC(NodeData_t *, info->maxNodeDataPages); + if (info->nodeDataPages == NULL) { + for (i = 0; i <= info->page ; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + st_free_table(table); + goto OUT_OF_MEM; + } + info->nodeDataPage = 0; + info->currentNodeDataPage = ALLOC(NodeData_t ,info->nodeDataPageSize); + info->nodeDataPages[info->nodeDataPage] = info->currentNodeDataPage; + if (info->currentNodeDataPage == NULL) { + for (i = 0; i <= info->page ; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + FREE(info->nodeDataPages); + st_free_table(table); + goto OUT_OF_MEM; + } + info->nodeDataPageIndex = 0; + + (void) SubsetCountMintermAux(node,info->max,table,info); + if (info->memOut) goto OUT_OF_MEM; + return(table); + +OUT_OF_MEM: + info->memOut = 1; + return(NULL); + +} /* end of SubsetCountMinterm */ + + +/** + @brief Recursively counts the number of nodes under the dag. + Also counts the number of nodes under the lighter child of + this node. + + @details Note that the same dag may be the lighter child of two + different nodes and have different counts. As with the minterm + counts, the node counts are stored in pages to be space efficient + and the address for these node counts are stored in an st_table + associated to each node. + + @sideeffect Updates the node data table with node counts + + @see SubsetCountNodes + +*/ +static int +SubsetCountNodesAux( + DdNode * node /**< current node */, + st_table * table /**< table to update node count, also serves as visited table. */, + double max /**< maximum number of variables */, + SubsetInfo_t * info) +{ + int tval, eval, i; + DdNode *N, *Nv, *Nnv; + double minNv, minNnv; + NodeData_t *dummyN, *dummyNv, *dummyNnv, *dummyNBar; + int *pmin, *pminBar, *val; + + if ((node == NULL) || Cudd_IsConstantInt(node)) + return(0); + + /* if this node has been processed do nothing */ + if (st_lookup(table, node, (void **) &dummyN) == 1) { + val = dummyN->nodesPointer; + if (val != NULL) + return(0); + } else { + return(0); + } + + N = Cudd_Regular(node); + Nv = Cudd_T(N); + Nnv = Cudd_E(N); + + Nv = Cudd_NotCond(Nv, Cudd_IsComplement(node)); + Nnv = Cudd_NotCond(Nnv, Cudd_IsComplement(node)); + + /* find the minterm counts for the THEN and ELSE branches */ + if (Cudd_IsConstantInt(Nv)) { + if (Nv == info->zero) { + minNv = 0.0; + } else { + minNv = max; + } + } else { + if (st_lookup(table, Nv, (void **) &dummyNv) == 1) + minNv = *(dummyNv->mintermPointer); + else { + return(0); + } + } + if (Cudd_IsConstantInt(Nnv)) { + if (Nnv == info->zero) { + minNnv = 0.0; + } else { + minNnv = max; + } + } else { + if (st_lookup(table, Nnv, (void **) &dummyNnv) == 1) { + minNnv = *(dummyNnv->mintermPointer); + } + else { + return(0); + } + } + + + /* recur based on which has larger minterm, */ + if (minNv >= minNnv) { + tval = SubsetCountNodesAux(Nv, table, max, info); + if (info->memOut) return(0); + eval = SubsetCountNodesAux(Nnv, table, max, info); + if (info->memOut) return(0); + + /* store the node count of the lighter child. */ + if (info->pageIndex == info->pageSize) ResizeCountNodePages(info); + if (info->memOut) { + for (i = 0; i <= info->page; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + for (i = 0; i <= info->nodeDataPage; i++) FREE(info->nodeDataPages[i]); + FREE(info->nodeDataPages); + st_free_table(table); + return(0); + } + pmin = info->currentLightNodePage + info->pageIndex; + *pmin = eval; /* Here the ELSE child is lighter */ + dummyN->lightChildNodesPointer = pmin; + + } else { + eval = SubsetCountNodesAux(Nnv, table, max, info); + if (info->memOut) return(0); + tval = SubsetCountNodesAux(Nv, table, max, info); + if (info->memOut) return(0); + + /* store the node count of the lighter child. */ + if (info->pageIndex == info->pageSize) ResizeCountNodePages(info); + if (info->memOut) { + for (i = 0; i <= info->page; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + for (i = 0; i <= info->nodeDataPage; i++) FREE(info->nodeDataPages[i]); + FREE(info->nodeDataPages); + st_free_table(table); + return(0); + } + pmin = info->currentLightNodePage + info->pageIndex; + *pmin = tval; /* Here the THEN child is lighter */ + dummyN->lightChildNodesPointer = pmin; + + } + /* updating the page index for node count storage. */ + pmin = info->currentNodePage + info->pageIndex; + *pmin = tval + eval + 1; + dummyN->nodesPointer = pmin; + + /* pageIndex is parallel page index for count_nodes and count_lightNodes */ + info->pageIndex++; + + /* if this node has been reached first, it belongs to a heavier + branch. Its complement will be reached later on a lighter branch. + Hence the complement has zero node count. */ + + if (st_lookup(table, Cudd_Not(node), (void **) &dummyNBar) == 1) { + if (info->pageIndex == info->pageSize) ResizeCountNodePages(info); + if (info->memOut) { + for (i = 0; i < info->page; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + for (i = 0; i < info->nodeDataPage; i++) FREE(info->nodeDataPages[i]); + FREE(info->nodeDataPages); + st_free_table(table); + return(0); + } + pminBar = info->currentLightNodePage + info->pageIndex; + *pminBar = 0; + dummyNBar->lightChildNodesPointer = pminBar; + /* The lighter child has less nodes than the parent. + * So if parent 0 then lighter child zero + */ + if (info->pageIndex == info->pageSize) ResizeCountNodePages(info); + if (info->memOut) { + for (i = 0; i < info->page; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + for (i = 0; i < info->nodeDataPage; i++) FREE(info->nodeDataPages[i]); + FREE(info->nodeDataPages); + st_free_table(table); + return(0); + } + pminBar = info->currentNodePage + info->pageIndex; + *pminBar = 0; + dummyNBar->nodesPointer = pminBar ; /* maybe should point to zero */ + + info->pageIndex++; + } + return(*pmin); +} /*end of SubsetCountNodesAux */ + + +/** + @brief Counts the nodes under the current node and its lighter child. + + @details Calls a recursive procedure to count the number of nodes of + a DAG rooted at a particular node and the number of nodes taken by + its lighter child. + + @sideeffect None + + @see SubsetCountNodesAux + +*/ +static int +SubsetCountNodes( + DdNode * node /**< function to be analyzed */, + st_table * table /**< node quality table */, + int nvars /**< number of variables node depends on */, + SubsetInfo_t * info /**< miscellaneous info */) +{ + int num; + int i; + +#ifdef DEBUG + info->num_calls = 0; +#endif + + info->max = pow(2.0,(double) nvars); + info->maxPages = INITIAL_PAGES; + info->nodePages = ALLOC(int *, info->maxPages); + if (info->nodePages == NULL) { + goto OUT_OF_MEM; + } + + info->lightNodePages = ALLOC(int *, info->maxPages); + if (info->lightNodePages == NULL) { + for (i = 0; i <= info->page; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + for (i = 0; i <= info->nodeDataPage; i++) FREE(info->nodeDataPages[i]); + FREE(info->nodeDataPages); + FREE(info->nodePages); + goto OUT_OF_MEM; + } + + info->page = 0; + info->currentNodePage = info->nodePages[info->page] = + ALLOC(int,info->pageSize); + if (info->currentNodePage == NULL) { + for (i = 0; i <= info->page; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + for (i = 0; i <= info->nodeDataPage; i++) FREE(info->nodeDataPages[i]); + FREE(info->nodeDataPages); + FREE(info->lightNodePages); + FREE(info->nodePages); + goto OUT_OF_MEM; + } + + info->currentLightNodePage = info->lightNodePages[info->page] = + ALLOC(int,info->pageSize); + if (info->currentLightNodePage == NULL) { + for (i = 0; i <= info->page; i++) FREE(info->mintermPages[i]); + FREE(info->mintermPages); + for (i = 0; i <= info->nodeDataPage; i++) FREE(info->nodeDataPages[i]); + FREE(info->nodeDataPages); + FREE(info->currentNodePage); + FREE(info->lightNodePages); + FREE(info->nodePages); + goto OUT_OF_MEM; + } + + info->pageIndex = 0; + num = SubsetCountNodesAux(node,table,info->max,info); + if (info->memOut) goto OUT_OF_MEM; + return(num); + +OUT_OF_MEM: + info->memOut = 1; + return(0); + +} /* end of SubsetCountNodes */ + + +/** + @brief Procedure to recursively store nodes that are retained in the subset. + + @sideeffect None + + @see StoreNodes + +*/ +static void +StoreNodes( + st_table * storeTable, + DdManager * dd, + DdNode * node) +{ + DdNode *N, *Nt, *Ne; + if (Cudd_IsConstantInt(dd)) { + return; + } + N = Cudd_Regular(node); + if (st_is_member(storeTable, N)) { + return; + } + cuddRef(N); + if (st_insert(storeTable, N, NULL) == ST_OUT_OF_MEM) { + fprintf(dd->err,"Something wrong, st_table insert failed\n"); + } + + Nt = Cudd_T(N); + Ne = Cudd_E(N); + + StoreNodes(storeTable, dd, Nt); + StoreNodes(storeTable, dd, Ne); + return; + +} + + +/** + @brief Builds the subset %BDD using the heavy branch method. + + @details The procedure carries out the building of the subset %BDD + starting at the root. Using the three different counts labelling each node, + the procedure chooses the heavier branch starting from the root and keeps + track of the number of nodes it discards at each step, thus keeping count + of the size of the subset %BDD dynamically. Once the threshold is satisfied, + the procedure then calls ITE to build the %BDD. + + @sideeffect None + +*/ +static DdNode * +BuildSubsetBdd( + DdManager * dd /**< %DD manager */, + DdNode * node /**< current node */, + int * size /**< current size of the subset */, + st_table * visitedTable /**< visited table storing all node data */, + int threshold /**< subsetting threshold */, + st_table * storeTable /**< store table */, + st_table * approxTable /**< approximation table */, + SubsetInfo_t * info /**< miscellaneous info */) +{ + + DdNode *Nv, *Nnv, *N, *topv, *neW; + double minNv, minNnv; + NodeData_t *currNodeQual; + NodeData_t *currNodeQualT; + NodeData_t *currNodeQualE; + DdNode *ThenBranch, *ElseBranch; + int topid; + void *dummy; + +#ifdef DEBUG + info->num_calls++; +#endif + /*If the size of the subset is below the threshold, dont do + anything. */ + if ((*size) <= threshold) { + /* store nodes below this, so we can recombine if possible */ + StoreNodes(storeTable, dd, node); + return(node); + } + + if (Cudd_IsConstantInt(node)) + return(node); + + /* Look up minterm count for this node. */ + if (!st_lookup(visitedTable, node, (void **) &currNodeQual)) { + fprintf(dd->err, + "Something is wrong, ought to be in node quality table\n"); + } + + /* Get children. */ + N = Cudd_Regular(node); + Nv = Cudd_T(N); + Nnv = Cudd_E(N); + + /* complement if necessary */ + Nv = Cudd_NotCond(Nv, Cudd_IsComplement(node)); + Nnv = Cudd_NotCond(Nnv, Cudd_IsComplement(node)); + + if (!Cudd_IsConstantInt(Nv)) { + /* find out minterms and nodes contributed by then child */ + if (!st_lookup(visitedTable, Nv, (void **) &currNodeQualT)) { + fprintf(dd->out,"Something wrong, couldnt find nodes in node quality table\n"); + dd->errorCode = CUDD_INTERNAL_ERROR; + return(NULL); + } + else { + minNv = *(((NodeData_t *)currNodeQualT)->mintermPointer); + } + } else { + if (Nv == info->zero) { + minNv = 0; + } else { + minNv = info->max; + } + } + if (!Cudd_IsConstantInt(Nnv)) { + /* find out minterms and nodes contributed by else child */ + if (!st_lookup(visitedTable, Nnv, (void **) &currNodeQualE)) { + fprintf(dd->out,"Something wrong, couldnt find nodes in node quality table\n"); + dd->errorCode = CUDD_INTERNAL_ERROR; + return(NULL); + } else { + minNnv = *(((NodeData_t *)currNodeQualE)->mintermPointer); + } + } else { + if (Nnv == info->zero) { + minNnv = 0; + } else { + minNnv = info->max; + } + } + + /* keep track of size of subset by subtracting the number of + * differential nodes contributed by lighter child + */ + *size = (*(size)) - (int)*(currNodeQual->lightChildNodesPointer); + if (minNv >= minNnv) { /*SubsetCountNodesAux procedure takes + the Then branch in case of a tie */ + + /* recur with the Then branch */ + ThenBranch = (DdNode *)BuildSubsetBdd(dd, Nv, size, visitedTable, + threshold, storeTable, + approxTable, info); + if (ThenBranch == NULL) { + return(NULL); + } + cuddRef(ThenBranch); + /* The Else branch is either a node that already exists in the + * subset, or one whose approximation has been computed, or + * Zero. + */ + if (st_lookup(storeTable, Cudd_Regular(Nnv), &dummy)) { + ElseBranch = Nnv; + cuddRef(ElseBranch); + } else { + if (st_lookup(approxTable, Nnv, &dummy)) { + ElseBranch = (DdNode *)dummy; + cuddRef(ElseBranch); + } else { + ElseBranch = info->zero; + cuddRef(ElseBranch); + } + } + + } + else { + /* recur with the Else branch */ + ElseBranch = (DdNode *)BuildSubsetBdd(dd, Nnv, size, visitedTable, + threshold, storeTable, + approxTable, info); + if (ElseBranch == NULL) { + return(NULL); + } + cuddRef(ElseBranch); + /* The Then branch is either a node that already exists in the + * subset, or one whose approximation has been computed, or + * Zero. + */ + if (st_lookup(storeTable, Cudd_Regular(Nv), &dummy)) { + ThenBranch = Nv; + cuddRef(ThenBranch); + } else { + if (st_lookup(approxTable, Nv, &dummy)) { + ThenBranch = (DdNode *)dummy; + cuddRef(ThenBranch); + } else { + ThenBranch = info->zero; + cuddRef(ThenBranch); + } + } + } + + /* construct the Bdd with the top variable and the two children */ + topid = Cudd_NodeReadIndex(N); + topv = Cudd_ReadVars(dd, topid); + cuddRef(topv); + neW = cuddBddIteRecur(dd, topv, ThenBranch, ElseBranch); + if (neW != NULL) { + cuddRef(neW); + } + Cudd_RecursiveDeref(dd, topv); + Cudd_RecursiveDeref(dd, ThenBranch); + Cudd_RecursiveDeref(dd, ElseBranch); + + + if (neW == NULL) + return(NULL); + else { + /* store this node in the store table */ + if (!st_lookup(storeTable, Cudd_Regular(neW), &dummy)) { + cuddRef(neW); + if (st_insert(storeTable, Cudd_Regular(neW), NULL) == + ST_OUT_OF_MEM) + return (NULL); + } + /* store the approximation for this node */ + if (N != Cudd_Regular(neW)) { + if (st_lookup(approxTable, node, &dummy)) { + fprintf(dd->err, "This node should not be in the approximated table\n"); + } else { + cuddRef(neW); + if (st_insert(approxTable, node, neW) == + ST_OUT_OF_MEM) + return(NULL); + } + } + cuddDeref(neW); + return(neW); + } +} /* end of BuildSubsetBdd */ diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSubsetSP.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddSubsetSP.c similarity index 72% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddSubsetSP.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddSubsetSP.c index fa89f167f..901f6c422 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSubsetSP.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddSubsetSP.c @@ -1,40 +1,17 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddSubsetSP.c] + @ingroup cudd - PackageName [cudd] + @brief Procedure to subset the given %BDD choosing the shortest paths + (largest cubes) in the %BDD. - Synopsis [Procedure to subset the given BDD choosing the shortest paths - (largest cubes) in the BDD.] + @see cuddSubsetHB.c + @author Kavita Ravi - Description [External procedures included in this module: - <ul> - <li> Cudd_SubsetShortPaths() - <li> Cudd_SupersetShortPaths() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddSubsetShortPaths() - </ul> - Static procedures included in this module: - <ul> - <li> BuildSubsetBdd() - <li> CreatePathTable() - <li> AssessPathLength() - <li> CreateTopDist() - <li> CreateBotDist() - <li> ResizeNodeDistPages() - <li> ResizeQueuePages() - <li> stPathTableDdFree() - </ul> - ] - - SeeAlso [cuddSubsetHB.c] - - Author [Kavita Ravi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -64,9 +41,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -88,9 +66,12 @@ /* Stucture declarations */ /*---------------------------------------------------------------------------*/ -/* structure created to store subset results for each node and distances with - * odd and even parity of the node from the root and sink. Main data structure - * in this procedure. +/** + * @brief structure created to store subset results for each node and + * distances with odd and even parity of the node from the root and + * sink. + * + * Main data structure in this procedure. */ struct NodeDist { DdHalfWord oddTopDist; @@ -101,7 +82,9 @@ struct NodeDist { DdNode *compResult; }; -/* assorted information needed by the BuildSubsetBdd procedure. */ +/** + @brief assorted information needed by the BuildSubsetBdd procedure. +*/ struct AssortedInfo { unsigned int maxpath; int findShortestPath; @@ -110,19 +93,22 @@ struct AssortedInfo { int threshold; }; +/** + * @brief Bookkeeping data structure for subsetting algorithm. + */ struct GlobalInfo { - struct NodeDist **nodeDistPages; /* pointers to the pages */ - int nodeDistPageIndex; /* index to next element */ - int nodeDistPage; /* index to current page */ - int nodeDistPageSize; /* page size */ - int maxNodeDistPages; /* number of page pointers */ - struct NodeDist *currentNodeDistPage; /* current page */ - DdNode ***queuePages; /* pointers to the pages */ - int queuePageIndex; /* index to next element */ - int queuePage; /* index to current page */ - int queuePageSize; /* page size */ - int maxQueuePages; /* number of page pointers */ - DdNode **currentQueuePage; /* current page */ + struct NodeDist **nodeDistPages; /**< pointers to the pages */ + int nodeDistPageIndex; /**< index to next element */ + int nodeDistPage; /**< index to current page */ + int nodeDistPageSize; /**< page size */ + int maxNodeDistPages; /**< number of page pointers */ + struct NodeDist *currentNodeDistPage; /**< current page */ + DdNode ***queuePages; /**< pointers to the pages */ + int queuePageIndex; /**< index to next element */ + int queuePage; /**< index to current page */ + int queuePageSize; /**< page size */ + int maxQueuePages; /**< number of page pointers */ + DdNode **currentQueuePage; /**< current page */ #ifdef DD_DEBUG int numCalls; int hits; @@ -141,20 +127,12 @@ typedef struct GlobalInfo GlobalInfo_t; /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddSubsetSP.c,v 1.36 2012/02/05 01:07:19 fabio Exp $"; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -#ifdef __cplusplus -extern "C" { -#endif - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -167,54 +145,50 @@ static int CreateBotDist (DdNode *node, st_table *pathTable, unsigned int *pathL static st_table * CreatePathTable (DdManager *dd, GlobalInfo_t *gInfo, DdNode *node, unsigned int *pathLengthArray, FILE *fp); static unsigned int AssessPathLength (unsigned int *pathLengthArray, int threshold, int numVars, unsigned int *excess, FILE *fp); static DdNode * BuildSubsetBdd (DdManager *dd, GlobalInfo_t *gInfo, st_table *pathTable, DdNode *node, struct AssortedInfo *info, st_table *subsetNodeTable); -static enum st_retval stPathTableDdFree (char *key, char *value, char *arg); - -/**AutomaticEnd***************************************************************/ +static enum st_retval stPathTableDdFree (void *key, void *value, void *arg); -#ifdef __cplusplus -} -#endif +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of Exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Extracts a dense subset from a BDD with the shortest paths - heuristic.] - - Description [Extracts a dense subset from a BDD. This procedure - tries to preserve the shortest paths of the input BDD, because they - give many minterms and contribute few nodes. This procedure may - increase the number of nodes in trying to create the subset or - reduce the number of nodes due to recombination as compared to the - original BDD. Hence the threshold may not be strictly adhered to. In - practice, recombination overshadows the increase in the number of - nodes and results in small BDDs as compared to the threshold. The - hardlimit specifies whether threshold needs to be strictly adhered - to. If it is set to 1, the procedure ensures that result is never - larger than the specified limit but may be considerably less than - the threshold. Returns a pointer to the BDD for the subset if - successful; NULL otherwise. The value for numVars should be as - close as possible to the size of the support of f for better - efficiency. However, it is safe to pass the value returned by +/** + @brief Extracts a dense subset from a %BDD with the shortest paths + heuristic. + + @details This procedure tries to preserve the shortest paths of the + input %BDD, because they give many minterms and contribute few nodes. + This procedure may increase the number of nodes in trying to create + the subset or reduce the number of nodes due to recombination as + compared to the original %BDD. Hence the threshold may not be + strictly adhered to. In practice, recombination overshadows the + increase in the number of nodes and results in small BDDs as + compared to the threshold. The hardlimit specifies whether threshold + needs to be strictly adhered to. If it is set to 1, the procedure + ensures that result is never larger than the specified limit but may + be considerably less than the threshold. The value for numVars + should be as close as possible to the size of the support of f for + better efficiency. However, it is safe to pass the value returned by Cudd_ReadSize for numVars. If 0 is passed, then the value returned - by Cudd_ReadSize is used.] + by Cudd_ReadSize is used. + + @return a pointer to the %BDD for the subset if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_SupersetShortPaths Cudd_SubsetHeavyBranch Cudd_ReadSize] + @see Cudd_SupersetShortPaths Cudd_SubsetHeavyBranch Cudd_ReadSize -******************************************************************************/ +*/ DdNode * Cudd_SubsetShortPaths( - DdManager * dd /* manager */, - DdNode * f /* function to be subset */, - int numVars /* number of variables in the support of f */, - int threshold /* maximum number of nodes in the subset */, - int hardlimit /* flag: 1 if threshold is a hard limit */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be subset */, + int numVars /**< number of variables in the support of f */, + int threshold /**< maximum number of nodes in the subset */, + int hardlimit /**< flag: 1 if threshold is a hard limit */) { DdNode *subset; @@ -228,44 +202,45 @@ Cudd_SubsetShortPaths( } /* end of Cudd_SubsetShortPaths */ -/**Function******************************************************************** - - Synopsis [Extracts a dense superset from a BDD with the shortest paths - heuristic.] - - Description [Extracts a dense superset from a BDD. The procedure is - identical to the subset procedure except for the fact that it - receives the complement of the given function. Extracting the subset - of the complement function is equivalent to extracting the superset - of the function. This procedure tries to preserve the shortest - paths of the complement BDD, because they give many minterms and - contribute few nodes. This procedure may increase the number of - nodes in trying to create the superset or reduce the number of nodes - due to recombination as compared to the original BDD. Hence the - threshold may not be strictly adhered to. In practice, recombination - overshadows the increase in the number of nodes and results in small - BDDs as compared to the threshold. The hardlimit specifies whether +/** + @brief Extracts a dense superset from a %BDD with the shortest paths + heuristic. + + @details The procedure is identical to the subset procedure except + for the fact that it receives the complement of the given + function. Extracting the subset of the complement function is + equivalent to extracting the superset of the function. This + procedure tries to preserve the shortest paths of the complement + %BDD, because they give many minterms and contribute few nodes. This + procedure may increase the number of nodes in trying to create the + superset or reduce the number of nodes due to recombination as + compared to the original %BDD. Hence the threshold may not be + strictly adhered to. In practice, recombination overshadows the + increase in the number of nodes and results in small BDDs as + compared to the threshold. The hardlimit specifies whether threshold needs to be strictly adhered to. If it is set to 1, the procedure ensures that result is never larger than the specified - limit but may be considerably less than the threshold. Returns a - pointer to the BDD for the superset if successful; NULL - otherwise. The value for numVars should be as close as possible to - the size of the support of f for better efficiency. However, it is - safe to pass the value returned by Cudd_ReadSize for numVar. If 0 - is passed, then the value returned by Cudd_ReadSize is used.] + limit but may be considerably less than the threshold. The value + for numVars should be as close as possible to the size of the + support of f for better efficiency. However, it is safe to pass the + value returned by Cudd_ReadSize for numVar. If 0 is passed, then + the value returned by Cudd_ReadSize is used. - SideEffects [None] + @return a pointer to the %BDD for the superset if successful; NULL + otherwise. + + @sideeffect None - SeeAlso [Cudd_SubsetShortPaths Cudd_SupersetHeavyBranch Cudd_ReadSize] + @see Cudd_SubsetShortPaths Cudd_SupersetHeavyBranch Cudd_ReadSize -******************************************************************************/ +*/ DdNode * Cudd_SupersetShortPaths( - DdManager * dd /* manager */, - DdNode * f /* function to be superset */, - int numVars /* number of variables in the support of f */, - int threshold /* maximum number of nodes in the subset */, - int hardlimit /* flag: 1 if threshold is a hard limit */) + DdManager * dd /**< manager */, + DdNode * f /**< function to be superset */, + int numVars /**< number of variables in the support of f */, + int threshold /**< maximum number of nodes in the subset */, + int hardlimit /**< flag: 1 if threshold is a hard limit */) { DdNode *subset, *g; @@ -285,30 +260,27 @@ Cudd_SupersetShortPaths( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [The outermost procedure to return a subset of the given BDD - with the shortest path lengths.] +/** + @brief The outermost procedure to return a subset of the given %BDD + with the shortest path lengths. - Description [The outermost procedure to return a subset of the given - BDD with the largest cubes. The path lengths are calculated, the maximum - allowable path length is determined and the number of nodes of this - path length that can be used to build a subset. If the threshold is - larger than the size of the original BDD, the original BDD is - returned. ] + @details The path lengths are calculated, the maximum allowable path + length is determined and the number of nodes of this path length + that can be used to build a subset. If the threshold is larger than + the size of the original %BDD, the original %BDD is returned. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_SubsetShortPaths] + @see Cudd_SubsetShortPaths -******************************************************************************/ +*/ DdNode * cuddSubsetShortPaths( - DdManager * dd /* DD manager */, - DdNode * f /* function to be subset */, - int numVars /* total number of variables in consideration */, - int threshold /* maximum number of nodes allowed in the subset */, - int hardlimit /* flag determining whether threshold should be respected strictly */) + DdManager * dd /**< %DD manager */, + DdNode * f /**< function to be subset */, + int numVars /**< total number of variables in consideration */, + int threshold /**< maximum number of nodes allowed in the subset */, + int hardlimit /**< flag determining whether threshold should be respected strictly */) { GlobalInfo_t gInfo; st_table *pathTable; @@ -337,7 +309,7 @@ cuddSubsetShortPaths( dd->errorCode = CUDD_INVALID_ARG; return(NULL); } - if (Cudd_IsConstant(f)) + if (Cudd_IsConstantInt(f)) return (f); pathLengthArray = ALLOC(unsigned int, numVars+1); @@ -388,7 +360,7 @@ cuddSubsetShortPaths( #endif N = Cudd_Regular(f); - if (!st_lookup(pathTable, N, &nodeStat)) { + if (!st_lookup(pathTable, N, (void **) &nodeStat)) { fprintf(dd->err, "Something wrong, root node must be in table\n"); dd->errorCode = CUDD_INTERNAL_ERROR; FREE(excess); @@ -441,7 +413,7 @@ cuddSubsetShortPaths( st_free_table(subsetNodeTable); } st_free_table(info->maxpathTable); - st_foreach(pathTable, stPathTableDdFree, (char *)dd); + st_foreach(pathTable, stPathTableDdFree, (void *)dd); FREE(info); @@ -481,26 +453,21 @@ cuddSubsetShortPaths( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Resize the number of pages allocated to store the distances - related to each node.] +/** + @brief Resize the number of pages allocated to store the distances + related to each node. - Description [Resize the number of pages allocated to store the distances - related to each node. The procedure moves the counter to the - next page when the end of the page is reached and allocates new - pages when necessary. ] + @details The procedure moves the counter to the next page when the + end of the page is reached and allocates new pages when necessary. - SideEffects [Changes the size of pages, page, page index, maximum - number of pages freeing stuff in case of memory out. ] + @sideeffect Changes the size of pages, page, page index, maximum + number of pages freeing stuff in case of memory out. - SeeAlso [] - -******************************************************************************/ +*/ static void ResizeNodeDistPages( - DdManager *dd /* DD manager */, - GlobalInfo_t *gInfo /* global information */) + DdManager *dd /**< %DD manager */, + GlobalInfo_t *gInfo /**< global information */) { int i; NodeDist_t **newNodeDistPages; @@ -545,26 +512,21 @@ ResizeNodeDistPages( } /* end of ResizeNodeDistPages */ -/**Function******************************************************************** - - Synopsis [Resize the number of pages allocated to store nodes in the BFS - traversal of the Bdd .] - - Description [Resize the number of pages allocated to store nodes in the BFS - traversal of the Bdd. The procedure moves the counter to the - next page when the end of the page is reached and allocates new - pages when necessary.] +/** + @brief Resize the number of pages allocated to store nodes in the BFS + traversal of the %BDD. - SideEffects [Changes the size of pages, page, page index, maximum - number of pages freeing stuff in case of memory out. ] + @details The procedure moves the counter to the next page when the + end of the page is reached and allocates new pages when necessary. - SeeAlso [] + @sideeffect Changes the size of pages, page, page index, maximum + number of pages freeing stuff in case of memory out. -******************************************************************************/ +*/ static void ResizeQueuePages( - DdManager *dd /* DD manager */, - GlobalInfo_t *gInfo /* global information */) + DdManager *dd /**< %DD manager */, + GlobalInfo_t *gInfo /**< global information */) { int i; DdNode ***newQueuePages; @@ -607,36 +569,33 @@ ResizeQueuePages( } /* end of ResizeQueuePages */ -/**Function******************************************************************** +/** + @brief Labels each node with its shortest distance from the root. - Synopsis [ Labels each node with its shortest distance from the root] + @details This is done in a BFS search of the %BDD. The nodes are + processed in a queue implemented as pages(array) to reduce memory + fragmentation. An entry is created for each node visited. The + distance from the root to the node with the corresponding parity is + updated. The procedure is called recursively each recusion level + handling nodes at a given level from the root. - Description [ Labels each node with its shortest distance from the root. - This is done in a BFS search of the BDD. The nodes are processed - in a queue implemented as pages(array) to reduce memory fragmentation. - An entry is created for each node visited. The distance from the root - to the node with the corresponding parity is updated. The procedure - is called recursively each recusion level handling nodes at a given - level from the root.] + @sideeffect Creates entries in the pathTable + @see CreatePathTable CreateBotDist - SideEffects [Creates entries in the pathTable] - - SeeAlso [CreatePathTable CreateBotDist] - -******************************************************************************/ +*/ static void CreateTopDist( - DdManager *dd /* DD manager */, - GlobalInfo_t *gInfo /* global information */, - st_table * pathTable /* hast table to store path lengths */, - int parentPage /* the pointer to the page on which the first parent in the queue is to be found. */, - int parentQueueIndex /* pointer to the first parent on the page */, - int topLen /* current distance from the root */, - DdNode ** childPage /* pointer to the page on which the first child is to be added. */, - int childQueueIndex /* pointer to the first child */, - int numParents /* number of parents to process in this recursive call */, - FILE *fp /* where to write messages */) + DdManager *dd /**< %DD manager */, + GlobalInfo_t *gInfo /**< global information */, + st_table * pathTable /**< hash table to store path lengths */, + int parentPage /**< the pointer to the page on which the first parent in the queue is to be found. */, + int parentQueueIndex /**< pointer to the first parent on the page */, + int topLen /**< current distance from the root */, + DdNode ** childPage /**< pointer to the page on which the first child is to be added. */, + int childQueueIndex /**< pointer to the first child */, + int numParents /**< number of parents to process in this recursive call */, + FILE *fp /**< where to write messages */) { NodeDist_t *nodeStat; DdNode *N, *Nv, *Nnv, *node, *child, *regChild; @@ -691,11 +650,11 @@ CreateTopDist( regChild = Cudd_Regular(child); /* dont process if the child is a constant */ - if (!Cudd_IsConstant(child)) { + if (!Cudd_IsConstantInt(child)) { /* check is already visited, if not add a new entry in * the path Table */ - if (!st_lookup(pathTable, regChild, &nodeStat)) { + if (!st_lookup(pathTable, regChild, (void **) &nodeStat)) { /* if not in table, has never been visited */ /* create entry for table */ if (gInfo->nodeDistPageIndex == gInfo->nodeDistPageSize) @@ -809,25 +768,23 @@ CreateTopDist( } /* end of CreateTopDist */ -/**Function******************************************************************** +/** + @brief Labels each node with the shortest distance from the constant. - Synopsis [ Labels each node with the shortest distance from the constant.] + @details This is done in a DFS search of the %BDD. Each node has an + odd and even parity distance from the sink (since there exists paths + to both zero and one) which is less than MAXSHORTINT. At each node + these distances are updated using the minimum distance of its + children from the constant. SInce now both the length from the root + and child is known, the minimum path length(length of the shortest + path between the root and the constant that this node lies on) of + this node can be calculated and used to update the pathLengthArray. - Description [Labels each node with the shortest distance from the constant. - This is done in a DFS search of the BDD. Each node has an odd - and even parity distance from the sink (since there exists paths to both - zero and one) which is less than MAXSHORTINT. At each node these distances - are updated using the minimum distance of its children from the constant. - SInce now both the length from the root and child is known, the minimum path - length(length of the shortest path between the root and the constant that - this node lies on) of this node can be calculated and used to update the - pathLengthArray] + @sideeffect Updates Path Table and path length array - SideEffects [Updates Path Table and path length array] + @see CreatePathTable CreateTopDist AssessPathLength - SeeAlso [CreatePathTable CreateTopDist AssessPathLength] - -******************************************************************************/ +*/ static int CreateBotDist( DdNode * node /* current node */, @@ -843,13 +800,13 @@ CreateBotDist( DdHalfWord botDist; int processingDone; - if (Cudd_IsConstant(node)) + if (Cudd_IsConstantInt(node)) return(1); N = Cudd_Regular(node); /* each node has one table entry */ /* update as you go down the min dist of each node from the root in each (odd and even) parity */ - if (!st_lookup(pathTable, N, &nodeStat)) { + if (!st_lookup(pathTable, N, (void **) &nodeStat)) { fprintf(fp, "Something wrong, the entry doesn't exist\n"); return(0); } @@ -885,7 +842,7 @@ CreateBotDist( realChild = Cudd_NotCond(child, Cudd_IsComplement(node)); regChild = Cudd_Regular(child); - if (Cudd_IsConstant(realChild)) { + if (Cudd_IsConstantInt(realChild)) { /* Found a minterm; count parity and shortest distance ** from the constant. */ @@ -895,7 +852,7 @@ CreateBotDist( nodeStat->evenBotDist = 1; } else { /* If node not in table, recur. */ - if (!st_lookup(pathTable, regChild, &nodeStatChild)) { + if (!st_lookup(pathTable, regChild, (void **) &nodeStatChild)) { fprintf(fp, "Something wrong, node in table should have been created in top dist proc.\n"); return(0); } @@ -993,33 +950,30 @@ CreateBotDist( } /*end of CreateBotDist */ -/**Function******************************************************************** - - Synopsis [ The outer procedure to label each node with its shortest - distance from the root and constant] +/** + @brief The outer procedure to label each node with its shortest + distance from the root and constant - Description [ The outer procedure to label each node with its shortest - distance from the root and constant. Calls CreateTopDist and CreateBotDist. - The basis for computing the distance between root and constant is that - the distance may be the sum of even distances from the node to the root - and constant or the sum of odd distances from the node to the root and - constant. Both CreateTopDist and CreateBotDist create the odd and - even parity distances from the root and constant respectively.] + @details Calls CreateTopDist and CreateBotDist. The basis for + computing the distance between root and constant is that the + distance may be the sum of even distances from the node to the root + and constant or the sum of odd distances from the node to the root + and constant. Both CreateTopDist and CreateBotDist create the odd + and even parity distances from the root and constant respectively. - SideEffects [None] + @sideeffect None - SeeAlso [CreateTopDist CreateBotDist] + @see CreateTopDist CreateBotDist -******************************************************************************/ +*/ static st_table * CreatePathTable( - DdManager *dd /* DD manager */, - GlobalInfo_t *gInfo /* global information */, - DdNode * node /* root of function */, - unsigned int * pathLengthArray /* array of path lengths to store nodes labeled with the various path lengths */, - FILE *fp /* where to write messages */) + DdManager *dd /**< %DD manager */, + GlobalInfo_t *gInfo /**< global information */, + DdNode * node /**< root of function */, + unsigned int * pathLengthArray /**< array of path lengths to store nodes labeled with the various path lengths */, + FILE *fp /**< where to write messages */) { - st_table *pathTable; NodeDist_t *nodeStat; DdHalfWord topLen; @@ -1030,15 +984,16 @@ CreatePathTable( int parentPage; int childQueueIndex, parentQueueIndex; - /* Creating path Table for storing data about nodes */ + /* Creating path table for storing data about nodes */ pathTable = st_init_table(st_ptrcmp,st_ptrhash); - /* initializing pages for info about each node */ + /* Initializing pages for info about each node */ gInfo->maxNodeDistPages = INITIAL_PAGES; gInfo->nodeDistPages = ALLOC(NodeDist_t *, gInfo->maxNodeDistPages); if (gInfo->nodeDistPages == NULL) { goto OUT_OF_MEM; } + assert(gInfo->nodeDistPageSize > 0); gInfo->nodeDistPage = 0; gInfo->currentNodeDistPage = gInfo->nodeDistPages[gInfo->nodeDistPage] = ALLOC(NodeDist_t, gInfo->nodeDistPageSize); @@ -1055,6 +1010,7 @@ CreatePathTable( if (gInfo->queuePages == NULL) { goto OUT_OF_MEM; } + assert(gInfo->queuePageSize > 0); gInfo->queuePage = 0; gInfo->currentQueuePage = gInfo->queuePages[gInfo->queuePage] = ALLOC(DdNode *, gInfo->queuePageSize); @@ -1076,10 +1032,14 @@ CreatePathTable( N = Cudd_Regular(node); - if (gInfo->nodeDistPageIndex == gInfo->nodeDistPageSize) ResizeNodeDistPages(dd, gInfo); + if (gInfo->nodeDistPageIndex == gInfo->nodeDistPageSize) + ResizeNodeDistPages(dd, gInfo); if (dd->errorCode == CUDD_MEMORY_OUT) { - for (i = 0; i <= gInfo->nodeDistPage; i++) FREE(gInfo->nodeDistPages[i]); - FREE(gInfo->nodeDistPages); + if (gInfo->nodeDistPages != NULL) { + for (i = 0; i <= gInfo->nodeDistPage; i++) + FREE(gInfo->nodeDistPages[i]); + FREE(gInfo->nodeDistPages); + } for (i = 0; i <= gInfo->queuePage; i++) FREE(gInfo->queuePages[i]); FREE(gInfo->queuePages); st_free_table(pathTable); @@ -1150,22 +1110,18 @@ OUT_OF_MEM: } /*end of CreatePathTable */ -/**Function******************************************************************** - - Synopsis [Chooses the maximum allowable path length of nodes under the - threshold.] - - Description [Chooses the maximum allowable path length under each node. - The corner cases are when the threshold is larger than the number - of nodes in the BDD iself, in which case 'numVars + 1' is returned. - If all nodes of a particular path length are needed, then the - maxpath returned is the next one with excess nodes = 0;] +/** + @brief Chooses the maximum allowable path length of nodes under the + threshold. - SideEffects [None] + @details The corner cases are when the threshold is larger than the + number of nodes in the %BDD iself, in which case 'numVars + 1' is + returned. If all nodes of a particular path length are needed, then + the maxpath returned is the next one with excess nodes = 0. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static unsigned int AssessPathLength( unsigned int * pathLengthArray /* array determining number of nodes belonging to the different path lengths */, @@ -1208,11 +1164,11 @@ AssessPathLength( } /* end of AssessPathLength */ -/**Function******************************************************************** +/** + @brief Builds the %BDD with nodes labeled with path length less than + or equal to maxpath. - Synopsis [Builds the BDD with nodes labeled with path length less than or equal to maxpath] - - Description [Builds the BDD with nodes labeled with path length + @details Builds the %BDD with nodes labeled with path length under maxpath and as many nodes labeled maxpath as determined by the threshold. The procedure uses the path table to determine which nodes in the original bdd need to be retained. This procedure picks a @@ -1243,44 +1199,43 @@ AssessPathLength( The subsetNodeTable is NIL when there is no hard limit on the number of nodes. Further efforts towards keeping the subset closer to the threshold number were abandoned in favour of keeping the procedure - simple and fast.] - - SideEffects [SubsetNodeTable is changed if it is not NIL.] + simple and fast. - SeeAlso [] + @sideeffect SubsetNodeTable is changed if it is not NIL. -******************************************************************************/ +*/ static DdNode * BuildSubsetBdd( - DdManager * dd /* DD manager */, - GlobalInfo_t *gInfo /* global information */, - st_table * pathTable /* path table with path lengths and computed results */, - DdNode * node /* current node */, - struct AssortedInfo * info /* assorted information structure */, - st_table * subsetNodeTable /* table storing computed results */) + DdManager * dd /**< %DD manager */, + GlobalInfo_t *gInfo /**< global information */, + st_table * pathTable /**< path table with path lengths and computed results */, + DdNode * node /**< current node */, + struct AssortedInfo * info /**< assorted information structure */, + st_table * subsetNodeTable /**< table storing computed results */) { DdNode *N, *Nv, *Nnv; DdNode *ThenBranch, *ElseBranch, *childBranch; - DdNode *child, *regChild, *regNnv, *regNv; + DdNode *child = NULL, *regChild = NULL, *regNnv = NULL, *regNv = NULL; NodeDist_t *nodeStatNv, *nodeStat, *nodeStatNnv; DdNode *neW, *topv, *regNew; char *entry; - unsigned int topid; - unsigned int childPathLength, oddLen, evenLen, NnvPathLength, NvPathLength; + int topid; + unsigned int childPathLength, oddLen, evenLen; + unsigned int NnvPathLength = 0, NvPathLength = 0; unsigned int NvBotDist, NnvBotDist; int tiebreakChild; - int processingDone, thenDone, elseDone; + int processingDone, thenDone; DdNode *zero = Cudd_Not(DD_ONE(dd)); #ifdef DD_DEBUG gInfo->numCalls++; #endif - if (Cudd_IsConstant(node)) + if (Cudd_IsConstantInt(node)) return(node); N = Cudd_Regular(node); /* Find node in table. */ - if (!st_lookup(pathTable, N, &nodeStat)) { + if (!st_lookup(pathTable, N, (void **) &nodeStat)) { (void) fprintf(dd->err, "Something wrong, node must be in table \n"); dd->errorCode = CUDD_INTERNAL_ERROR; return(NULL); @@ -1327,10 +1282,9 @@ BuildSubsetBdd( thenDone = 0; ThenBranch = NULL; /* else child not processed */ - elseDone = 0; ElseBranch = NULL; /* if then child constant, branch is the child */ - if (Cudd_IsConstant(Nv)) { + if (Cudd_IsConstantInt(Nv)) { /*shortest path found */ if ((Nv == DD_ONE(dd)) && (info->findShortestPath)) { info->findShortestPath = 0; @@ -1349,7 +1303,7 @@ BuildSubsetBdd( /* Derive regular child for table lookup. */ regNv = Cudd_Regular(Nv); /* Get node data for shortest path length. */ - if (!st_lookup(pathTable, regNv, &nodeStatNv) ) { + if (!st_lookup(pathTable, regNv, (void **) &nodeStatNv) ) { (void) fprintf(dd->err, "Something wrong, node must be in table\n"); dd->errorCode = CUDD_INTERNAL_ERROR; return(NULL); @@ -1374,7 +1328,7 @@ BuildSubsetBdd( nodeStatNv->evenBotDist; } /* if else child constant, branch is the child */ - if (Cudd_IsConstant(Nnv)) { + if (Cudd_IsConstantInt(Nnv)) { /*shortest path found */ if ((Nnv == DD_ONE(dd)) && (info->findShortestPath)) { info->findShortestPath = 0; @@ -1386,14 +1340,13 @@ BuildSubsetBdd( return(NULL); } - elseDone++; processingDone++; NnvBotDist = MAXSHORTINT; } else { /* Derive regular child for table lookup. */ regNnv = Cudd_Regular(Nnv); /* Get node data for shortest path length. */ - if (!st_lookup(pathTable, regNnv, &nodeStatNnv) ) { + if (!st_lookup(pathTable, regNnv, (void **) &nodeStatNnv) ) { (void) fprintf(dd->err, "Something wrong, node must be in table\n"); dd->errorCode = CUDD_INTERNAL_ERROR; return(NULL); @@ -1435,7 +1388,6 @@ BuildSubsetBdd( } else { child = Nnv; regChild = regNnv; - elseDone = 1; childPathLength = NnvPathLength; } /* then path length less than else path length */ } else { @@ -1443,7 +1395,6 @@ BuildSubsetBdd( if (thenDone) { child = Nnv; regChild = regNnv; - elseDone = 1; childPathLength = NnvPathLength; } else { child = Nv; @@ -1470,7 +1421,7 @@ BuildSubsetBdd( } else { /* Case: path length of node = maxpath */ /* If the node labeled with maxpath is found in the ** maxpathTable, use it to build the subset BDD. */ - if (st_lookup(info->maxpathTable, regChild, &entry)) { + if (st_lookup(info->maxpathTable, regChild, (void **) &entry)) { /* When a node that is already been chosen is hit, ** the quest for a complete path is over. */ if (info->findShortestPath) { @@ -1558,31 +1509,32 @@ BuildSubsetBdd( Cudd_RecursiveDeref(dd, ElseBranch); - /* Hard Limit of threshold has been imposed */ - if (subsetNodeTable != NIL(st_table)) { - /* check if a new node is created */ - regNew = Cudd_Regular(neW); - /* subset node table keeps all new nodes that have been created to keep - * a running count of how many nodes have been built in the subset. - */ - if (!st_lookup(subsetNodeTable, regNew, &entry)) { - if (!Cudd_IsConstant(regNew)) { - if (st_insert(subsetNodeTable, regNew, - NULL) == ST_OUT_OF_MEM) { - (void) fprintf(dd->err, "Out of memory\n"); - return (NULL); - } - if (st_count(subsetNodeTable) > info->threshold) { - info->thresholdReached = 0; - } - } - } - } - - if (neW == NULL) { return(NULL); } else { + + /* Hard Limit of threshold has been imposed */ + if (subsetNodeTable != NIL(st_table)) { + /* check if a new node is created */ + regNew = Cudd_Regular(neW); + /* subset node table keeps all new nodes that have been created to + * keep a running count of how many nodes have been built in the + * subset. + */ + if (!st_lookup(subsetNodeTable, regNew, (void **) &entry)) { + if (!Cudd_IsConstantInt(regNew)) { + if (st_insert(subsetNodeTable, regNew, + NULL) == ST_OUT_OF_MEM) { + (void) fprintf(dd->err, "Out of memory\n"); + return (NULL); + } + if (st_count(subsetNodeTable) > info->threshold) { + info->thresholdReached = 0; + } + } + } + } + /*store computed result in regular form*/ if (Cudd_IsComplement(node)) { nodeStat->compResult = neW; @@ -1627,28 +1579,22 @@ BuildSubsetBdd( } /* end of BuildSubsetBdd */ -/**Function******************************************************************** - - Synopsis [Procedure to free te result dds stored in the NodeDist pages.] - - Description [None] +/** + @brief Procedure to free the result dds stored in the NodeDist pages. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static enum st_retval stPathTableDdFree( - char * key, - char * value, - char * arg) + void * key, + void * value, + void * arg) { - NodeDist_t *nodeStat; - DdManager *dd; + NodeDist_t *nodeStat = (NodeDist_t *) value; + DdManager *dd = (DdManager *) arg; - nodeStat = (NodeDist_t *)value; - dd = (DdManager *)arg; + (void) key; /* avoid warning */ if (nodeStat->regResult != NULL) { Cudd_RecursiveDeref(dd, nodeStat->regResult); } diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSymmetry.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddSymmetry.c similarity index 79% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddSymmetry.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddSymmetry.c index 571636ea1..61b6c51c6 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddSymmetry.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddSymmetry.c @@ -1,37 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddSymmetry.c] - - PackageName [cudd] - - Synopsis [Functions for symmetry-based variable reordering.] - - Description [External procedures included in this file: - <ul> - <li> Cudd_SymmProfile() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddSymmCheck() - <li> cuddSymmSifting() - <li> cuddSymmSiftingConv() - </ul> - Static procedures included in this module: - <ul> - <li> ddSymmUniqueCompare() - <li> ddSymmSiftingAux() - <li> ddSymmSiftingConvAux() - <li> ddSymmSiftingUp() - <li> ddSymmSiftingDown() - <li> ddSymmGroupMove() - <li> ddSymmGroupMoveBackward() - <li> ddSymmSiftingBackward() - <li> ddSymmSummary() - </ul>] - - Author [Shipra Panda, Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Functions for symmetry-based variable reordering. + + @author Shipra Panda, Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -61,13 +38,13 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" -#include "ucbqsort.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ @@ -87,28 +64,17 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddSymmetry.c,v 1.28 2012/02/05 01:07:19 fabio Exp $"; -#endif - -static int *entry; - -extern int ddTotalNumberSwapping; -#ifdef DD_STATS -extern int ddTotalNISwaps; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ -static int ddSymmUniqueCompare (int *ptrX, int *ptrY); +static int ddSymmUniqueCompare (void const *ptrX, void const *ptrY); static int ddSymmSiftingAux (DdManager *table, int x, int xLow, int xHigh); static int ddSymmSiftingConvAux (DdManager *table, int x, int xLow, int xHigh); static Move * ddSymmSiftingUp (DdManager *table, int y, int xLow); @@ -118,7 +84,7 @@ static int ddSymmGroupMoveBackward (DdManager *table, int x, int y); static int ddSymmSiftingBackward (DdManager *table, Move *moves, int size); static void ddSymmSummary (DdManager *table, int lower, int upper, int *symvars, int *symgroups); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -126,15 +92,16 @@ static void ddSymmSummary (DdManager *table, int lower, int upper, int *symvars, /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Prints statistics on symmetric variables.] +/** + @brief Prints statistics on symmetric variables. - Description [] + @details The information is accurate only if this function is called + right after reordering with methods CUDD_REORDER_SYMM_SIFT or + CUDD_REORDER_SYMM_SIFT_CONV. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ void Cudd_SymmProfile( DdManager * table, @@ -174,17 +141,16 @@ Cudd_SymmProfile( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Checks for symmetry of x and y. - Synopsis [Checks for symmetry of x and y.] + @details Ignores projection functions, unless they are isolated. - Description [Checks for symmetry of x and y. Ignores projection - functions, unless they are isolated. Returns 1 in case of symmetry; 0 - otherwise.] + @return 1 in case of symmetry; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ int cuddSymmCheck( DdManager * table, @@ -293,12 +259,10 @@ cuddSymmCheck( } /* end of cuddSymmCheck */ -/**Function******************************************************************** - - Synopsis [Symmetric sifting algorithm.] +/** + @brief Symmetric sifting algorithm. - Description [Symmetric sifting algorithm. - Assumes that no dead nodes are present. + @details Assumes that no dead nodes are present. <ol> <li> Order all the variables according to the number of entries in each unique subtable. @@ -307,14 +271,15 @@ cuddSymmCheck( <li> Select the best permutation. <li> Repeat 3 and 4 for all variables. </ol> - Returns 1 plus the number of symmetric variables if successful; 0 - otherwise.] - SideEffects [None] + @return 1 plus the number of symmetric variables if successful; 0 + otherwise. - SeeAlso [cuddSymmSiftingConv] + @sideeffect None -******************************************************************************/ + @see cuddSymmSiftingConv + +*/ int cuddSymmSifting( DdManager * table, @@ -322,7 +287,7 @@ cuddSymmSifting( int upper) { int i; - int *var; + IndexKey *var; int size; int x; int result; @@ -335,13 +300,7 @@ cuddSymmSifting( size = table->size; /* Find order in which to sift variables. */ - var = NULL; - entry = ALLOC(int,size); - if (entry == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - goto ddSymmSiftingOutOfMem; - } - var = ALLOC(int,size); + var = ALLOC(IndexKey,size); if (var == NULL) { table->errorCode = CUDD_MEMORY_OUT; goto ddSymmSiftingOutOfMem; @@ -349,11 +308,11 @@ cuddSymmSifting( for (i = 0; i < size; i++) { x = table->perm[i]; - entry[i] = table->subtables[x].keys; - var[i] = i; + var[i].index = i; + var[i].keys = table->subtables[x].keys; } - cudd__qsort((void *)var,size,sizeof(int),(DD_QSFP)ddSymmUniqueCompare); + util_qsort(var,size,sizeof(IndexKey),ddSymmUniqueCompare); /* Initialize the symmetry of each subtable to itself. */ for (i = lower; i <= upper; i++) { @@ -361,15 +320,20 @@ cuddSymmSifting( } for (i = 0; i < ddMin(table->siftMaxVar,size); i++) { - if (ddTotalNumberSwapping >= table->siftMaxSwap) + if (table->ddTotalNumberSwapping >= table->siftMaxSwap) break; if (util_cpu_time() - table->startTime > table->timeLimit) { table->autoDyn = 0; /* prevent further reordering */ break; } - x = table->perm[var[i]]; + if (table->terminationCallback != NULL && + table->terminationCallback(table->tcbArg)) { + table->autoDyn = 0; /* prevent further reordering */ + break; + } + x = table->perm[var[i].index]; #ifdef DD_STATS - previousSize = table->keys - table->isolated; + previousSize = (int) (table->keys - table->isolated); #endif if (x < lower || x > upper) continue; if (table->subtables[x].next == (unsigned) x) { @@ -390,7 +354,6 @@ cuddSymmSifting( } FREE(var); - FREE(entry); ddSymmSummary(table, lower, upper, &symvars, &symgroups); @@ -405,7 +368,6 @@ cuddSymmSifting( ddSymmSiftingOutOfMem: - if (entry != NULL) FREE(entry); if (var != NULL) FREE(var); return(0); @@ -413,29 +375,28 @@ ddSymmSiftingOutOfMem: } /* end of cuddSymmSifting */ -/**Function******************************************************************** - - Synopsis [Symmetric sifting to convergence algorithm.] +/** + @brief Symmetric sifting to convergence algorithm. - Description [Symmetric sifting to convergence algorithm. - Assumes that no dead nodes are present. + @details Assumes that no dead nodes are present. <ol> <li> Order all the variables according to the number of entries in each unique subtable. <li> Sift the variable up and down, remembering each time the total - size of the DD heap and grouping variables that are symmetric. + size of the %DD heap and grouping variables that are symmetric. <li> Select the best permutation. <li> Repeat 3 and 4 for all variables. <li> Repeat 1-4 until no further improvement. </ol> - Returns 1 plus the number of symmetric variables if successful; 0 - otherwise.] - SideEffects [None] + @return 1 plus the number of symmetric variables if successful; 0 + otherwise. - SeeAlso [cuddSymmSifting] + @sideeffect None -******************************************************************************/ + @see cuddSymmSifting + +*/ int cuddSymmSiftingConv( DdManager * table, @@ -443,7 +404,7 @@ cuddSymmSiftingConv( int upper) { int i; - int *var; + IndexKey *var; int size; int x; int result; @@ -455,18 +416,12 @@ cuddSymmSiftingConv( int previousSize; #endif - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); size = table->size; /* Find order in which to sift variables. */ - var = NULL; - entry = ALLOC(int,size); - if (entry == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - goto ddSymmSiftingConvOutOfMem; - } - var = ALLOC(int,size); + var = ALLOC(IndexKey,size); if (var == NULL) { table->errorCode = CUDD_MEMORY_OUT; goto ddSymmSiftingConvOutOfMem; @@ -474,11 +429,11 @@ cuddSymmSiftingConv( for (i = 0; i < size; i++) { x = table->perm[i]; - entry[i] = table->subtables[x].keys; - var[i] = i; + var[i].index = i; + var[i].keys = table->subtables[x].keys; } - cudd__qsort((void *)var,size,sizeof(int),(DD_QSFP)ddSymmUniqueCompare); + util_qsort(var,size,sizeof(IndexKey),ddSymmUniqueCompare); /* Initialize the symmetry of each subtable to itself ** for first pass of converging symmetric sifting. @@ -488,18 +443,23 @@ cuddSymmSiftingConv( } for (i = 0; i < ddMin(table->siftMaxVar, table->size); i++) { - if (ddTotalNumberSwapping >= table->siftMaxSwap) + if (table->ddTotalNumberSwapping >= table->siftMaxSwap) break; if (util_cpu_time() - table->startTime > table->timeLimit) { table->autoDyn = 0; /* prevent further reordering */ break; } - x = table->perm[var[i]]; + if (table->terminationCallback != NULL && + table->terminationCallback(table->tcbArg)) { + table->autoDyn = 0; /* prevent further reordering */ + break; + } + x = table->perm[var[i].index]; if (x < lower || x > upper) continue; /* Only sift if not in symmetry group already. */ if (table->subtables[x].next == (unsigned) x) { #ifdef DD_STATS - previousSize = table->keys - table->isolated; + previousSize = (int) (table->keys - table->isolated); #endif result = ddSymmSiftingAux(table,x,lower,upper); if (!result) goto ddSymmSiftingConvOutOfMem; @@ -519,7 +479,7 @@ cuddSymmSiftingConv( /* Sifting now until convergence. */ while ((unsigned) initialSize > table->keys - table->isolated) { - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); #ifdef DD_STATS (void) fprintf(table->out,"\n"); #endif @@ -533,24 +493,29 @@ cuddSymmSiftingConv( ** Hence, the next increment of x will move it to a new group. */ i = table->invperm[x]; - entry[i] = table->subtables[x].keys; - var[classes] = i; + var[classes].keys = table->subtables[x].keys; + var[classes].index = i; } - cudd__qsort((void *)var,classes,sizeof(int),(DD_QSFP)ddSymmUniqueCompare); + util_qsort(var,classes,sizeof(IndexKey),ddSymmUniqueCompare); /* Now sift. */ for (i = 0; i < ddMin(table->siftMaxVar,classes); i++) { - if (ddTotalNumberSwapping >= table->siftMaxSwap) + if (table->ddTotalNumberSwapping >= table->siftMaxSwap) break; if (util_cpu_time() - table->startTime > table->timeLimit) { table->autoDyn = 0; /* prevent further reordering */ break; } - x = table->perm[var[i]]; + if (table->terminationCallback != NULL && + table->terminationCallback(table->tcbArg)) { + table->autoDyn = 0; /* prevent further reordering */ + break; + } + x = table->perm[var[i].index]; if ((unsigned) x >= table->subtables[x].next) { #ifdef DD_STATS - previousSize = table->keys - table->isolated; + previousSize = (int) (table->keys - table->isolated); #endif result = ddSymmSiftingConvAux(table,x,lower,upper); if (!result ) goto ddSymmSiftingConvOutOfMem; @@ -579,13 +544,11 @@ cuddSymmSiftingConv( #endif FREE(var); - FREE(entry); return(1+symvars); ddSymmSiftingConvOutOfMem: - if (entry != NULL) FREE(entry); if (var != NULL) FREE(var); return(0); @@ -598,46 +561,47 @@ ddSymmSiftingConvOutOfMem: /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Comparison function used by qsort. - Synopsis [Comparison function used by qsort.] + @details Used to order the variables according to the number of keys + in the subtables. - Description [Comparison function used by qsort to order the variables - according to the number of keys in the subtables. - Returns the difference in number of keys between the two - variables being compared.] + @return the difference in number of keys between the two variables + being compared. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddSymmUniqueCompare( - int * ptrX, - int * ptrY) + void const * ptrX, + void const * ptrY) { + IndexKey const * pX = (IndexKey const *) ptrX; + IndexKey const * pY = (IndexKey const *) ptrY; #if 0 - if (entry[*ptrY] == entry[*ptrX]) { - return((*ptrX) - (*ptrY)); + if (pY->keys == pX->keys) { + return(pX->index - pY->index); } #endif - return(entry[*ptrY] - entry[*ptrX]); + return(pY->keys - pX->keys); } /* end of ddSymmUniqueCompare */ -/**Function******************************************************************** +/** + @brief Given xLow <= x <= xHigh moves x up and down between the + boundaries. - Synopsis [Given xLow <= x <= xHigh moves x up and down between the - boundaries.] + @details Finds the best position and does the required changes. + Assumes that x is not part of a symmetry group. - Description [Given xLow <= x <= xHigh moves x up and down between the - boundaries. Finds the best position and does the required changes. - Assumes that x is not part of a symmetry group. Returns 1 if - successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddSymmSiftingAux( DdManager * table, @@ -660,7 +624,7 @@ ddSymmSiftingAux( assert(table->subtables[x].next == (unsigned) x); #endif - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveDown = NULL; moveUp = NULL; @@ -734,7 +698,7 @@ ddSymmSiftingAux( /* No new symmetry groups detected, return to best position */ result = ddSymmSiftingBackward(table,moveDown,initialSize); } else { - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveUp = ddSymmSiftingUp(table,x,xLow); result = ddSymmSiftingBackward(table,moveUp,initialSize); } @@ -768,7 +732,7 @@ ddSymmSiftingAux( /* No new symmetry groups detected, return to best position */ result = ddSymmSiftingBackward(table,moveUp,initialSize); } else { - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveDown = ddSymmSiftingDown(table,x,xHigh); result = ddSymmSiftingBackward(table,moveDown,initialSize); } @@ -827,7 +791,7 @@ ddSymmSiftingAux( cuddDeallocMove(table, moveDown); moveDown = move; } - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveDown = ddSymmSiftingDown(table,x,xHigh); result = ddSymmSiftingBackward(table,moveDown,initialSize); } @@ -885,7 +849,7 @@ ddSymmSiftingAux( cuddDeallocMove(table, moveUp); moveUp = move; } - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveUp = ddSymmSiftingUp(table,x,xLow); result = ddSymmSiftingBackward(table,moveUp,initialSize); } @@ -926,20 +890,20 @@ ddSymmSiftingAuxOutOfMem: } /* end of ddSymmSiftingAux */ -/**Function******************************************************************** - - Synopsis [Given xLow <= x <= xHigh moves x up and down between the - boundaries.] +/** + @brief Given xLow <= x <= xHigh moves x up and down between the + boundaries. - Description [Given xLow <= x <= xHigh moves x up and down between the - boundaries. Finds the best position and does the required changes. + @details Finds the best position and does the required changes. Assumes that x is either an isolated variable, or it is the bottom of a symmetry group. All symmetries may not have been found, because of - exceeded growth limit. Returns 1 if successful; 0 otherwise.] + exceeded growth limit. - SideEffects [None] + @return 1 if successful; 0 otherwise. -******************************************************************************/ + @sideeffect None + +*/ static int ddSymmSiftingConvAux( DdManager * table, @@ -956,7 +920,7 @@ ddSymmSiftingConvAux( int initGroupSize, finalGroupSize; - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveDown = NULL; moveUp = NULL; @@ -990,7 +954,7 @@ ddSymmSiftingConvAux( /* No new symmetries detected, go back to best position */ result = ddSymmSiftingBackward(table,moveDown,initialSize); } else { - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveUp = ddSymmSiftingUp(table,x,xLow); result = ddSymmSiftingBackward(table,moveUp,initialSize); } @@ -1025,7 +989,7 @@ ddSymmSiftingConvAux( /* No new symmetry groups detected, return to best position */ result = ddSymmSiftingBackward(table,moveUp,initialSize); } else { - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveDown = ddSymmSiftingDown(table,x,xHigh); result = ddSymmSiftingBackward(table,moveDown,initialSize); } @@ -1083,7 +1047,7 @@ ddSymmSiftingConvAux( cuddDeallocMove(table, moveDown); moveDown = move; } - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveDown = ddSymmSiftingDown(table,x,xHigh); result = ddSymmSiftingBackward(table,moveDown,initialSize); } @@ -1141,7 +1105,7 @@ ddSymmSiftingConvAux( cuddDeallocMove(table, moveUp); moveUp = move; } - initialSize = table->keys - table->isolated; + initialSize = (int) (table->keys - table->isolated); moveUp = ddSymmSiftingUp(table,x,xLow); result = ddSymmSiftingBackward(table,moveUp,initialSize); } @@ -1182,21 +1146,21 @@ ddSymmSiftingConvAuxOutOfMem: } /* end of ddSymmSiftingConvAux */ -/**Function******************************************************************** +/** + @brief Moves x up until either it reaches the bound (xLow) or + the size of the %DD heap increases too much. - Synopsis [Moves x up until either it reaches the bound (xLow) or - the size of the DD heap increases too much.] + @details Assumes that x is the top of a symmetry group. Checks x + for symmetry to the adjacent variables. If symmetry is found, the + symmetry group of x is merged with the symmetry group of the other + variable. - Description [Moves x up until either it reaches the bound (xLow) or - the size of the DD heap increases too much. Assumes that x is the top - of a symmetry group. Checks x for symmetry to the adjacent - variables. If symmetry is found, the symmetry group of x is merged - with the symmetry group of the other variable. Returns the set of - moves in case of success; MV_OOM if memory is full.] + @return the set of moves in case of success; MV_OOM if memory is + full. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static Move * ddSymmSiftingUp( DdManager * table, @@ -1229,7 +1193,7 @@ ddSymmSiftingUp( ** change. The rest may vanish in the best case, except for ** the nodes at level xLow, which will not vanish, regardless. */ - limitSize = L = table->keys - table->isolated; + limitSize = L = (int) (table->keys - table->isolated); gybot = y; while ((unsigned) gybot < table->subtables[gybot].next) gybot = table->subtables[gybot].next; @@ -1237,7 +1201,7 @@ ddSymmSiftingUp( zindex = table->invperm[z]; if (zindex == yindex || cuddTestInteract(table,zindex,yindex)) { isolated = table->vars[zindex]->ref == 1; - L -= table->subtables[z].keys - isolated; + L -= (int) table->subtables[z].keys - isolated; } } @@ -1247,12 +1211,12 @@ ddSymmSiftingUp( gybot = y; while ((unsigned) gybot < table->subtables[gybot].next) gybot = table->subtables[gybot].next; - checkL = table->keys - table->isolated; + checkL = (int) (table->keys - table->isolated); for (z = xLow + 1; z <= gybot; z++) { zindex = table->invperm[z]; if (zindex == yindex || cuddTestInteract(table,zindex,yindex)) { isolated = table->vars[zindex]->ref == 1; - checkL -= table->subtables[z].keys - isolated; + checkL -= (int) table->subtables[z].keys - isolated; } } assert(L == checkL); @@ -1278,7 +1242,7 @@ ddSymmSiftingUp( /* Update the lower bound. */ if (cuddTestInteract(table,xindex,yindex)) { isolated = table->vars[xindex]->ref == 1; - L += table->subtables[y].keys - isolated; + L += (int) table->subtables[y].keys - isolated; } move = (Move *) cuddDynamicAllocNode(table); if (move == NULL) goto ddSymmSiftingUpOutOfMem; @@ -1299,7 +1263,7 @@ ddSymmSiftingUp( zindex = table->invperm[z]; if (cuddTestInteract(table,zindex,yindex)) { isolated = table->vars[zindex]->ref == 1; - L += table->subtables[z].keys - isolated; + L += (int) table->subtables[z].keys - isolated; } z = table->subtables[z].next; } while (z != (int) moves->y); @@ -1324,21 +1288,21 @@ ddSymmSiftingUpOutOfMem: } /* end of ddSymmSiftingUp */ -/**Function******************************************************************** +/** + @brief Moves x down until either it reaches the bound (xHigh) or + the size of the %DD heap increases too much. - Synopsis [Moves x down until either it reaches the bound (xHigh) or - the size of the DD heap increases too much.] + @details Assumes that x is the bottom of a symmetry group. Checks x + for symmetry to the adjacent variables. If symmetry is found, the + symmetry group of x is merged with the symmetry group of the other + variable. - Description [Moves x down until either it reaches the bound (xHigh) - or the size of the DD heap increases too much. Assumes that x is the - bottom of a symmetry group. Checks x for symmetry to the adjacent - variables. If symmetry is found, the symmetry group of x is merged - with the symmetry group of the other variable. Returns the set of - moves in case of success; MV_OOM if memory is full.] + @return the set of moves in case of success; MV_OOM if memory is + full. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static Move * ddSymmSiftingDown( DdManager * table, @@ -1364,13 +1328,13 @@ ddSymmSiftingDown( /* Initialize R */ xindex = table->invperm[x]; gxtop = table->subtables[x].next; - limitSize = size = table->keys - table->isolated; + limitSize = size = (int) (table->keys - table->isolated); R = 0; for (z = xHigh; z > gxtop; z--) { zindex = table->invperm[z]; if (zindex == xindex || cuddTestInteract(table,xindex,zindex)) { isolated = table->vars[zindex]->ref == 1; - R += table->subtables[z].keys - isolated; + R += (int) table->subtables[z].keys - isolated; } } @@ -1383,7 +1347,7 @@ ddSymmSiftingDown( zindex = table->invperm[z]; if (zindex == xindex || cuddTestInteract(table,xindex,zindex)) { isolated = table->vars[zindex]->ref == 1; - checkR += table->subtables[z].keys - isolated; + checkR += (int) table->subtables[z].keys - isolated; } } assert(R == checkR); @@ -1403,7 +1367,7 @@ ddSymmSiftingDown( yindex = table->invperm[y]; if (cuddTestInteract(table,xindex,yindex)) { isolated = table->vars[yindex]->ref == 1; - R -= table->subtables[y].keys - isolated; + R -= (int) table->subtables[y].keys - isolated; } size = cuddSwapInPlace(table,x,y); #ifdef DD_DEBUG @@ -1429,7 +1393,7 @@ ddSymmSiftingDown( zindex = table->invperm[z]; if (zindex == xindex || cuddTestInteract(table,xindex,zindex)) { isolated = table->vars[zindex]->ref == 1; - R -= table->subtables[z].keys - isolated; + R -= (int) table->subtables[z].keys - isolated; } z++; } while (z <= gybot); @@ -1444,7 +1408,7 @@ ddSymmSiftingDown( zindex = table->invperm[z]; if (zindex == xindex || cuddTestInteract(table,xindex,zindex)) { isolated = table->vars[zindex]->ref == 1; - R += table->subtables[z].keys - isolated; + R += (int) table->subtables[z].keys - isolated; } } } @@ -1465,18 +1429,18 @@ ddSymmSiftingDownOutOfMem: } /* end of ddSymmSiftingDown */ -/**Function******************************************************************** +/** + @brief Swaps two groups. - Synopsis [Swaps two groups.] + @details x is assumed to be the bottom variable of the first + group. y is assumed to be the top variable of the second group. + Updates the list of moves. - Description [Swaps two groups. x is assumed to be the bottom variable - of the first group. y is assumed to be the top variable of the second - group. Updates the list of moves. Returns the number of keys in the - table if successful; 0 otherwise.] + @return the number of keys in the table if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddSymmGroupMove( DdManager * table, @@ -1485,10 +1449,10 @@ ddSymmGroupMove( Move ** moves) { Move *move; - int size; + int size = 0; int i,j; int xtop,xbot,xsize,ytop,ybot,ysize,newxtop; - int swapx,swapy; + int swapx = 0, swapy = 0; #ifdef DD_DEBUG assert(x < y); /* we assume that x < y */ @@ -1546,25 +1510,24 @@ ddSymmGroupMove( } /* end of ddSymmGroupMove */ -/**Function******************************************************************** +/** + @brief Undoes the swap of two groups. - Synopsis [Undoes the swap of two groups.] + @details x is assumed to be the bottom variable of the first + group. y is assumed to be the top variable of the second group. - Description [Undoes the swap of two groups. x is assumed to be the - bottom variable of the first group. y is assumed to be the top - variable of the second group. Returns the number of keys in the table - if successful; 0 otherwise.] + @return the number of keys in the table if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddSymmGroupMoveBackward( DdManager * table, int x, int y) { - int size; + int size = (int) (table->keys - table->isolated); int i,j; int xtop,xbot,xsize,ytop,ybot,ysize,newxtop; @@ -1581,6 +1544,10 @@ ddSymmGroupMoveBackward( ybot = table->subtables[ybot].next; ytop = y; ysize = ybot - ytop + 1; +#ifdef DD_DEBUG + assert(xsize > 0); + assert(ysize > 0); +#endif /* Sift the variables of the second group up through the first group. */ for (i = 1; i <= ysize; i++) { @@ -1616,19 +1583,18 @@ ddSymmGroupMoveBackward( } /* end of ddSymmGroupMoveBackward */ -/**Function******************************************************************** +/** + @brief Given a set of moves, returns the %DD heap to the position + giving the minimum size. - Synopsis [Given a set of moves, returns the DD heap to the position - giving the minimum size.] + @details In case of ties, returns to the closest position giving the + minimum size. - Description [Given a set of moves, returns the DD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddSymmSiftingBackward( DdManager * table, @@ -1663,16 +1629,12 @@ ddSymmSiftingBackward( } /* end of ddSymmSiftingBackward */ -/**Function******************************************************************** - - Synopsis [Counts numbers of symmetric variables and symmetry - groups.] - - Description [] +/** + @brief Counts numbers of symmetric variables and symmetry groups. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static void ddSymmSummary( DdManager * table, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddTable.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddTable.c similarity index 83% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddTable.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddTable.c index b8e989375..a6275748a 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddTable.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddTable.c @@ -1,53 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddTable.c] - - PackageName [cudd] - - Synopsis [Unique table management functions.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_Prime() - <li> Cudd_Reserve() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddAllocNode() - <li> cuddInitTable() - <li> cuddFreeTable() - <li> cuddGarbageCollect() - <li> cuddZddGetNode() - <li> cuddZddGetNodeIVO() - <li> cuddUniqueInter() - <li> cuddUniqueInterIVO() - <li> cuddUniqueInterZdd() - <li> cuddUniqueConst() - <li> cuddRehash() - <li> cuddShrinkSubtable() - <li> cuddInsertSubtables() - <li> cuddDestroySubtables() - <li> cuddResizeTableZdd() - <li> cuddSlowTableGrowth() - </ul> - Static procedures included in this module: - <ul> - <li> ddRehashZdd() - <li> ddResizeTable() - <li> cuddFindParent() - <li> cuddOrderedInsert() - <li> cuddOrderedThread() - <li> cuddRotateLeft() - <li> cuddRotateRight() - <li> cuddDoRebalance() - <li> cuddCheckCollisionOrdering() - </ul>] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Unique table management functions. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -77,11 +38,13 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" +#include "mtrInt.h" #include "cuddInt.h" /*---------------------------------------------------------------------------*/ @@ -103,7 +66,9 @@ /* Stucture declarations */ /*---------------------------------------------------------------------------*/ -/* This is a hack for when CUDD_VALUE_TYPE is double */ +/** + * @brief This is a hack for when CUDD_VALUE_TYPE is double + */ typedef union hack { CUDD_VALUE_TYPE value; unsigned int bits[2]; @@ -117,15 +82,11 @@ typedef union hack { /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddTable.c,v 1.126 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - #ifndef DD_UNSORTED_FREE_LIST #ifdef DD_RED_BLACK_FREE_LIST /* Macros for red/black trees. */ @@ -141,7 +102,7 @@ static char rcsid[] DD_UNUSED = "$Id: cuddTable.c,v 1.126 2012/02/05 01:07:19 fa #endif -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -150,7 +111,7 @@ static char rcsid[] DD_UNUSED = "$Id: cuddTable.c,v 1.126 2012/02/05 01:07:19 fa static void ddRehashZdd (DdManager *unique, int i); static int ddResizeTable (DdManager *unique, int index, int amount); static int cuddFindParent (DdManager *table, DdNode *node); -DD_INLINE static void ddFixLimits (DdManager *unique); +static void ddFixLimits (DdManager *unique); #ifdef DD_RED_BLACK_FREE_LIST static void cuddOrderedInsert (DdNodePtr *root, DdNodePtr node); static DdNode * cuddOrderedThread (DdNode *root, DdNode *list); @@ -164,7 +125,7 @@ static int cuddCheckCollisionOrdering (DdManager *unique, int i, int j); #endif static void ddReportRefMess (DdManager *unique, int i, const char *caller); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -172,20 +133,17 @@ static void ddReportRefMess (DdManager *unique, int i, const char *caller); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Returns the next prime >= p.] +/** + @brief Returns the next prime ≥ p. - Description [] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ unsigned int Cudd_Prime( unsigned int p) { - int i,pn; + unsigned int i, pn; p--; do { @@ -209,23 +167,24 @@ Cudd_Prime( } /* end of Cudd_Prime */ -/**Function******************************************************************** - - Synopsis [Expand manager without creating variables.] +/** + @brief Expand manager without creating variables. - Description [Expand a manager by a specified number of subtables without + @details Expand a manager by a specified number of subtables without actually creating new variables. This function can be used to reduce the frequency of resizing when an estimate of the number of variables is available. One would call this function instead of passing the number of variables to Cudd_Init if variables should not be created right away of if the estimate on their number became available only after the manager - has been created. Returns 1 if successful; 0 otherwise.] + has been created. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [Cudd_Init] + @sideeffect None -******************************************************************************/ + @see Cudd_Init + +*/ int Cudd_Reserve( DdManager *manager, @@ -248,20 +207,20 @@ Cudd_Reserve( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Fast storage allocation for DdNodes in the table. - Synopsis [Fast storage allocation for DdNodes in the table.] + @details The first 4 bytes of a chunk contain a pointer to the next + block; the rest contains DD_MEM_CHUNK spaces for DdNodes. - Description [Fast storage allocation for DdNodes in the table. The - first 4 bytes of a chunk contain a pointer to the next block; the - rest contains DD_MEM_CHUNK spaces for DdNodes. Returns a pointer to - a new node if successful; NULL is memory is full.] + @return a pointer to a new node if successful; NULL is memory is + full. - SideEffects [None] + @sideeffect None - SeeAlso [cuddDynamicAllocNode] + @see cuddDynamicAllocNode -******************************************************************************/ +*/ DdNode * cuddAllocNode( DdManager * unique) @@ -274,15 +233,20 @@ cuddAllocNode( if (unique->nextFree == NULL) { /* free list is empty */ /* Check for exceeded limits. */ + if (unique->terminationCallback != NULL && + unique->terminationCallback(unique->tcbArg)) { + unique->errorCode = CUDD_TERMINATION; + return(NULL); + } + if (util_cpu_time() - unique->startTime > unique->timeLimit) { + unique->errorCode = CUDD_TIMEOUT_EXPIRED; + return(NULL); + } if ((unique->keys - unique->dead) + (unique->keysZ - unique->deadZ) > unique->maxLive) { unique->errorCode = CUDD_TOO_MANY_NODES; return(NULL); } - if (util_cpu_time() - unique->startTime > unique->timeLimit) { - unique->errorCode = CUDD_TIMEOUT_EXPIRED; - return(NULL); - } if (unique->stash == NULL || unique->memused > unique->maxmemhard) { (void) cuddGarbageCollect(unique,1); mem = NULL; @@ -294,7 +258,7 @@ cuddAllocNode( } /* Try to allocate a new block. */ saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = unique->outOfMemCallback; mem = (DdNodePtr *) ALLOC(DdNode,DD_MEM_CHUNK + 1); MMoutOfMemory = saveHandler; if (mem == NULL) { @@ -364,24 +328,22 @@ cuddAllocNode( } /* end of cuddAllocNode */ -/**Function******************************************************************** - - Synopsis [Creates and initializes the unique table.] +/** + @brief Creates and initializes the unique table. - Description [Creates and initializes the unique table. Returns a pointer - to the table if successful; NULL otherwise.] + @return a pointer to the table if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Init cuddFreeTable] + @see Cudd_Init cuddFreeTable -******************************************************************************/ +*/ DdManager * cuddInitTable( - unsigned int numVars /* Initial number of BDD variables (and subtables) */, - unsigned int numVarsZ /* Initial number of ZDD variables (and subtables) */, - unsigned int numSlots /* Initial size of the BDD subtables */, - unsigned int looseUpTo /* Limit for fast table growth */) + unsigned int numVars /**< Initial number of %BDD variables (and subtables) */, + unsigned int numVarsZ /**< Initial number of %ZDD variables (and subtables) */, + unsigned int numSlots /**< Initial size of the %BDD subtables */, + unsigned int looseUpTo /**< Limit for fast table growth */) { DdManager *unique = ALLOC(DdManager,1); int i, j; @@ -485,7 +447,7 @@ cuddInitTable( unique->stack[0] = NULL; /* to suppress harmless UMR */ #ifndef DD_NO_DEATH_ROW - unique->deathRowDepth = 1 << cuddComputeFloorLog2(unique->looseUpTo >> 2); + unique->deathRowDepth = 1U << cuddComputeFloorLog2(unique->looseUpTo >> 2); unique->deathRow = ALLOC(DdNodePtr,unique->deathRowDepth); if (unique->deathRow == NULL) { FREE(unique->subtables); @@ -510,6 +472,7 @@ cuddInitTable( unique->subtables[i].shift = shift; unique->subtables[i].keys = 0; unique->subtables[i].dead = 0; + unique->subtables[i].next = i; unique->subtables[i].maxKeys = slots * DD_MAX_SUBTABLE_DENSITY; unique->subtables[i].bindVar = 0; unique->subtables[i].varType = CUDD_VAR_PRIMARY_INPUT; @@ -543,6 +506,7 @@ cuddInitTable( unique->subtableZ[i].shift = shift; unique->subtableZ[i].keys = 0; unique->subtableZ[i].dead = 0; + unique->subtableZ[i].next = i; unique->subtableZ[i].maxKeys = slots * DD_MAX_SUBTABLE_DENSITY; nodelist = unique->subtableZ[i].nodelist = ALLOC(DdNodePtr,slots); if (nodelist == NULL) { @@ -572,6 +536,12 @@ cuddInitTable( unique->constants.shift = shift; unique->constants.keys = 0; unique->constants.dead = 0; + unique->constants.next = 0; + unique->constants.bindVar = 0; + unique->constants.varType = CUDD_VAR_PRIMARY_INPUT; + unique->constants.pairIndex = 0; + unique->constants.varHandled = 0; + unique->constants.varToBeGrouped = CUDD_LAZY_NONE; unique->constants.maxKeys = slots * DD_MAX_SUBTABLE_DENSITY; nodelist = unique->constants.nodelist = ALLOC(DdNodePtr,slots); if (nodelist == NULL) { @@ -633,6 +603,7 @@ cuddInitTable( unique->numberXovers = 0; unique->randomizeOrder = 0; unique->linear = NULL; + unique->originalSize = 0; unique->linearSize = 0; /* Initialize ZDD universe. */ @@ -649,17 +620,22 @@ cuddInitTable( unique->errorCode = CUDD_NO_ERROR; unique->startTime = util_cpu_time(); unique->timeLimit = ~0UL; + unique->terminationCallback = NULL; + unique->tcbArg = NULL; + unique->outOfMemCallback = Cudd_OutOfMem; + unique->timeoutHandler = NULL; /* Initialize statistical counters. */ - unique->maxmemhard = ~ 0UL; + unique->maxmemhard = ~ (size_t) 0; unique->garbageCollections = 0; unique->GCTime = 0; unique->reordTime = 0; + unique->peakLiveNodes = 0; + unique->cuddRand = 0; #ifdef DD_STATS unique->nodesDropped = 0; unique->nodesFreed = 0; #endif - unique->peakLiveNodes = 0; #ifdef DD_UNIQUE_PROFILE unique->uniqueLookUps = 0; unique->uniqueLinks = 0; @@ -670,6 +646,9 @@ cuddInitTable( #ifdef DD_STATS unique->nextSample = 250000; #endif +#endif +#ifdef DD_DEBUG + unique->enableExtraDebug = 0; #endif return(unique); @@ -677,17 +656,14 @@ cuddInitTable( } /* end of cuddInitTable */ -/**Function******************************************************************** - - Synopsis [Frees the resources associated to a unique table.] - - Description [] +/** + @brief Frees the resources associated to a unique table. - SideEffects [None] + @sideeffect None - SeeAlso [cuddInitTable] + @see cuddInitTable -******************************************************************************/ +*/ void cuddFreeTable( DdManager * unique) @@ -696,6 +672,7 @@ cuddFreeTable( DdNodePtr *memlist = unique->memoryList; int i; + if (unique->stash != NULL) FREE(unique->stash); if (unique->univ != NULL) cuddZddFreeUniv(unique); while (memlist != NULL) { next = (DdNodePtr *) memlist[0]; /* link to next block */ @@ -743,25 +720,22 @@ cuddFreeTable( } /* end of cuddFreeTable */ -/**Function******************************************************************** +/** + @brief Performs garbage collection on the %BDD and %ZDD unique tables. - Synopsis [Performs garbage collection on the unique tables.] - - Description [Performs garbage collection on the BDD and ZDD unique tables. - If clearCache is 0, the cache is not cleared. This should only be - specified if the cache has been cleared right before calling + @details If clearCache is 0, the cache is not cleared. This should + only be specified if the cache has been cleared right before calling cuddGarbageCollect. (As in the case of dynamic reordering.) - Returns the total number of deleted nodes.] - SideEffects [None] + @return the total number of deleted nodes. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int cuddGarbageCollect( DdManager * unique, - int clearCache) + int clearCache) { DdHook *hook; DdCache *cache = unique->cache; @@ -783,6 +757,11 @@ cuddGarbageCollect( #endif #endif + if (util_cpu_time() - unique->startTime > unique->timeLimit) { + unique->errorCode = CUDD_TIMEOUT_EXPIRED; + return(0); + } + #ifndef DD_NO_DEATH_ROW cuddClearDeathRow(unique); #endif @@ -1033,19 +1012,19 @@ cuddGarbageCollect( } /* end of cuddGarbageCollect */ -/**Function******************************************************************** +/** + @brief Wrapper for cuddUniqueInterZdd. - Synopsis [Wrapper for cuddUniqueInterZdd.] + @details It applies the %ZDD reduction rule. - Description [Wrapper for cuddUniqueInterZdd, which applies the ZDD - reduction rule. Returns a pointer to the result node under normal - conditions; NULL if reordering occurred or memory was exhausted.] + @return a pointer to the result node under normal conditions; NULL + if reordering occurred or memory was exhausted. - SideEffects [None] + @sideeffect None - SeeAlso [cuddUniqueInterZdd] + @see cuddUniqueInterZdd -******************************************************************************/ +*/ DdNode * cuddZddGetNode( DdManager * zdd, @@ -1063,22 +1042,23 @@ cuddZddGetNode( } /* end of cuddZddGetNode */ -/**Function******************************************************************** +/** + @brief Wrapper for cuddUniqueInterZdd that is independent of variable + ordering. - Synopsis [Wrapper for cuddUniqueInterZdd that is independent of variable - ordering.] - - Description [Wrapper for cuddUniqueInterZdd that is independent of + @details Wrapper for cuddUniqueInterZdd that is independent of variable ordering (IVO). This function does not require parameter index to precede the indices of the top nodes of g and h in the - variable order. Returns a pointer to the result node under normal - conditions; NULL if reordering occurred or memory was exhausted.] + variable order. + + @return a pointer to the result node under normal conditions; NULL + if reordering occurred or memory was exhausted. - SideEffects [None] + @sideeffect None - SeeAlso [cuddZddGetNode cuddZddIsop] + @see cuddZddGetNode cuddZddIsop -******************************************************************************/ +*/ DdNode * cuddZddGetNodeIVO( DdManager * dd, @@ -1116,23 +1096,24 @@ cuddZddGetNodeIVO( } /* end of cuddZddGetNodeIVO */ -/**Function******************************************************************** - - Synopsis [Checks the unique table for the existence of an internal node.] +/** + @brief Checks the unique table for the existence of an internal node. - Description [Checks the unique table for the existence of an internal - node. If it does not exist, it creates a new one. Does not + @details If it does not exist, it creates a new one. Does not modify the reference count of whatever is returned. A newly created internal node comes back with a reference count 0. For a newly created node, increments the reference counts of what T and E point - to. Returns a pointer to the new node if successful; NULL if memory - is exhausted or if reordering took place.] + to. - SideEffects [None] + @return a pointer to the new node if successful; NULL if memory is + exhausted, if a termination request was detected, if a timeout expired, + or if reordering took place. - SeeAlso [cuddUniqueInterZdd] + @sideeffect None -******************************************************************************/ + @see cuddUniqueInterZdd + +*/ DdNode * cuddUniqueInter( DdManager * unique, @@ -1153,7 +1134,12 @@ cuddUniqueInter( unique->uniqueLookUps++; #endif - if ((0x1ffffUL & (unsigned long) unique->cacheMisses) == 0) { + if (((int64_t) 0x1ffff & (int64_t) unique->cacheMisses) == 0) { + if (unique->terminationCallback != NULL && + unique->terminationCallback(unique->tcbArg)) { + unique->errorCode = CUDD_TERMINATION; + return(NULL); + } if (util_cpu_time() - unique->startTime > unique->timeLimit) { unique->errorCode = CUDD_TIMEOUT_EXPIRED; return(NULL); @@ -1213,11 +1199,20 @@ cuddUniqueInter( unique->maxReorderings--; if (retval == 0) { unique->reordered = 2; - } else if ((cpuTime = util_cpu_time()) - unique->startTime > unique->timeLimit) { + } else if (unique->terminationCallback != NULL && + unique->terminationCallback(unique->tcbArg)) { + unique->errorCode = CUDD_TERMINATION; + unique->reordered = 0; + } else if ((cpuTime = util_cpu_time()) - unique->startTime > + unique->timeLimit) { unique->errorCode = CUDD_TIMEOUT_EXPIRED; unique->reordered = 0; } else if (unique->timeLimit - (cpuTime - unique->startTime) < unique->reordTime) { + /* No risk of overflow because here unique->timeLimit is known + * to be greater than or equal to (cpuTime - unique->startTime). + * If the remaining time is less than the time spent on + * reordering so far, we disable reordering. */ unique->autoDyn = 0; } #ifdef DD_DEBUG @@ -1234,6 +1229,11 @@ cuddUniqueInter( ((unique->dead > unique->minDead) || ((unique->dead > unique->minDead / 2) && (subtable->dead > subtable->keys * 0.95)))) { /* too many dead */ + if (unique->terminationCallback != NULL && + unique->terminationCallback(unique->tcbArg)) { + unique->errorCode = CUDD_TERMINATION; + return(NULL); + } if (util_cpu_time() - unique->startTime > unique->timeLimit) { unique->errorCode = CUDD_TIMEOUT_EXPIRED; return(NULL); @@ -1313,22 +1313,23 @@ cuddUniqueInter( } /* end of cuddUniqueInter */ -/**Function******************************************************************** +/** + @brief Wrapper for cuddUniqueInter that is independent of variable + ordering. - Synopsis [Wrapper for cuddUniqueInter that is independent of variable - ordering.] - - Description [Wrapper for cuddUniqueInter that is independent of + @details Wrapper for cuddUniqueInter that is independent of variable ordering (IVO). This function does not require parameter index to precede the indices of the top nodes of T and E in the - variable order. Returns a pointer to the result node under normal - conditions; NULL if reordering occurred or memory was exhausted.] + variable order. + + @return a pointer to the result node under normal conditions; NULL + if reordering occurred or memory was exhausted. - SideEffects [None] + @sideeffect None - SeeAlso [cuddUniqueInter Cudd_MakeBddFromZddCover] + @see cuddUniqueInter Cudd_MakeBddFromZddCover -******************************************************************************/ +*/ DdNode * cuddUniqueInterIVO( DdManager * unique, @@ -1350,24 +1351,25 @@ cuddUniqueInterIVO( } /* end of cuddUniqueInterIVO */ -/**Function******************************************************************** +/** + @brief Checks the unique table for the existence of an internal + %ZDD node. - Synopsis [Checks the unique table for the existence of an internal - ZDD node.] - - Description [Checks the unique table for the existence of an internal - ZDD node. If it does not exist, it creates a new one. Does not + @details If it does not exist, it creates a new one. Does not modify the reference count of whatever is returned. A newly created internal node comes back with a reference count 0. For a newly created node, increments the reference counts of what T and E point - to. Returns a pointer to the new node if successful; NULL if memory - is exhausted or if reordering took place.] + to. + + @return a pointer to the new node if successful; NULL if memory is + exhausted, if a termination request was detected, if a timeout expired, + or if reordering took place. - SideEffects [None] + @sideeffect None - SeeAlso [cuddUniqueInter] + @see cuddUniqueInter -******************************************************************************/ +*/ DdNode * cuddUniqueInterZdd( DdManager * unique, @@ -1386,6 +1388,17 @@ cuddUniqueInterZdd( unique->uniqueLookUps++; #endif + if (((int64_t) 0x1ffff & (int64_t) unique->cacheMisses) == 0) { + if (unique->terminationCallback != NULL && + unique->terminationCallback(unique->tcbArg)) { + unique->errorCode = CUDD_TERMINATION; + return(NULL); + } + if (util_cpu_time() - unique->startTime > unique->timeLimit) { + unique->errorCode = CUDD_TIMEOUT_EXPIRED; + return(NULL); + } + } if (index >= unique->sizeZ) { if (!cuddResizeTableZdd(unique,index)) return(NULL); } @@ -1401,6 +1414,15 @@ cuddUniqueInterZdd( if (subtable->keys > subtable->maxKeys) { if (unique->gcEnabled && ((unique->deadZ > unique->minDead) || (10 * subtable->dead > 9 * subtable->keys))) { /* too many dead */ + if (unique->terminationCallback != NULL && + unique->terminationCallback(unique->tcbArg)) { + unique->errorCode = CUDD_TERMINATION; + return(NULL); + } + if (util_cpu_time() - unique->startTime > unique->timeLimit) { + unique->errorCode = CUDD_TIMEOUT_EXPIRED; + return(NULL); + } (void) cuddGarbageCollect(unique,1); } else { ddRehashZdd(unique,(int)level); @@ -1426,7 +1448,7 @@ cuddUniqueInterZdd( /* countDead is 0 if deads should be counted and ~0 if they should not. */ if (unique->autoDynZ && - unique->keysZ - (unique->deadZ & unique->countDead) >= unique->nextDyn) { + unique->keysZ - (unique->deadZ & unique->countDead) >= unique->nextDyn) { #ifdef DD_DEBUG retval = Cudd_DebugCheck(unique); if (retval != 0) return(NULL); @@ -1434,7 +1456,16 @@ cuddUniqueInterZdd( if (retval != 0) return(NULL); #endif retval = Cudd_zddReduceHeap(unique,unique->autoMethodZ,10); /* 10 = whatever */ - if (retval == 0) unique->reordered = 2; + if (retval == 0) { + unique->reordered = 2; + } else if (unique->terminationCallback != NULL && + unique->terminationCallback(unique->tcbArg)) { + unique->errorCode = CUDD_TERMINATION; + unique->reordered = 0; + } else if (util_cpu_time() - unique->startTime > unique->timeLimit) { + unique->errorCode = CUDD_TIMEOUT_EXPIRED; + unique->reordered = 0; + } #ifdef DD_DEBUG retval = Cudd_DebugCheck(unique); if (retval != 0) unique->reordered = 2; @@ -1462,19 +1493,18 @@ cuddUniqueInterZdd( } /* end of cuddUniqueInterZdd */ -/**Function******************************************************************** +/** + @brief Checks the unique table for the existence of a constant node. - Synopsis [Checks the unique table for the existence of a constant node.] - - Description [Checks the unique table for the existence of a constant node. - If it does not exist, it creates a new one. Does not + @details If it does not exist, it creates a new one. Does not modify the reference count of whatever is returned. A newly created - internal node comes back with a reference count 0. Returns a - pointer to the new node.] + internal node comes back with a reference count 0. + + @return a pointer to the new node. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ DdNode * cuddUniqueConst( DdManager * unique, @@ -1492,6 +1522,15 @@ cuddUniqueConst( if (unique->constants.keys > unique->constants.maxKeys) { if (unique->gcEnabled && ((unique->dead > unique->minDead) || (10 * unique->constants.dead > 9 * unique->constants.keys))) { /* too many dead */ + if (unique->terminationCallback != NULL && + unique->terminationCallback(unique->tcbArg)) { + unique->errorCode = CUDD_TERMINATION; + return(NULL); + } + if (util_cpu_time() - unique->startTime > unique->timeLimit) { + unique->errorCode = CUDD_TIMEOUT_EXPIRED; + return(NULL); + } (void) cuddGarbageCollect(unique,1); } else { cuddRehash(unique,CUDD_CONST_INDEX); @@ -1543,18 +1582,15 @@ cuddUniqueConst( } /* end of cuddUniqueConst */ -/**Function******************************************************************** - - Synopsis [Rehashes a unique subtable.] - - Description [Doubles the size of a unique subtable and rehashes its - contents.] +/** + @brief Rehashes a unique subtable. - SideEffects [None] + @details Doubles the size of a unique subtable and rehashes its + contents. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ void cuddRehash( DdManager * unique, @@ -1600,7 +1636,7 @@ cuddRehash( shift = oldshift - 1; saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = unique->outOfMemCallback; nodelist = ALLOC(DdNodePtr, slots); MMoutOfMemory = saveHandler; if (nodelist == NULL) { @@ -1667,7 +1703,7 @@ cuddRehash( slots = oldslots << 1; shift = oldshift - 1; saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = unique->outOfMemCallback; nodelist = ALLOC(DdNodePtr, slots); MMoutOfMemory = saveHandler; if (nodelist == NULL) { @@ -1716,17 +1752,14 @@ cuddRehash( } /* end of cuddRehash */ -/**Function******************************************************************** +/** + @brief Shrinks a subtable. - Synopsis [Shrinks a subtable.] + @sideeffect None - Description [Shrinks a subtable.] + @see cuddRehash - SideEffects [None] - - SeeAlso [cuddRehash] - -******************************************************************************/ +*/ void cuddShrinkSubtable( DdManager *unique, @@ -1745,7 +1778,7 @@ cuddShrinkSubtable( oldslots = unique->subtables[i].slots; slots = oldslots >> 1; saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = unique->outOfMemCallback; nodelist = ALLOC(DdNodePtr, slots); MMoutOfMemory = saveHandler; if (nodelist == NULL) { @@ -1807,19 +1840,19 @@ cuddShrinkSubtable( } /* end of cuddShrinkSubtable */ -/**Function******************************************************************** +/** + @brief Inserts n new subtables in a unique table at level. - Synopsis [Inserts n new subtables in a unique table at level.] + @details The number n should be positive, and level should be an + existing level. - Description [Inserts n new subtables in a unique table at level. - The number n should be positive, and level should be an existing level. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddDestroySubtables] + @see cuddDestroySubtables -******************************************************************************/ +*/ int cuddInsertSubtables( DdManager * unique, @@ -1833,7 +1866,7 @@ cuddInsertSubtables( int oldsize,newsize; int i,j,index,reorderSave; unsigned int numSlots = unique->initSlots; - int *newperm, *newinvperm, *newmap; + int *newperm, *newinvperm, *newmap = NULL; DdNode *one, *zero; #ifdef DD_DEBUG @@ -1850,6 +1883,7 @@ cuddInsertSubtables( unique->subtables[i+n].keys = unique->subtables[i].keys; unique->subtables[i+n].maxKeys = unique->subtables[i].maxKeys; unique->subtables[i+n].dead = unique->subtables[i].dead; + unique->subtables[i+n].next = i+n; unique->subtables[i+n].nodelist = unique->subtables[i].nodelist; unique->subtables[i+n].bindVar = unique->subtables[i].bindVar; unique->subtables[i+n].varType = unique->subtables[i].varType; @@ -1870,6 +1904,7 @@ cuddInsertSubtables( unique->subtables[level+i].keys = 0; unique->subtables[level+i].maxKeys = numSlots * DD_MAX_SUBTABLE_DENSITY; unique->subtables[level+i].dead = 0; + unique->subtables[level+i].next = level+i; unique->subtables[level+i].bindVar = 0; unique->subtables[level+i].varType = CUDD_VAR_PRIMARY_INPUT; unique->subtables[level+i].pairIndex = 0; @@ -1952,6 +1987,7 @@ cuddInsertSubtables( newsubtables[i].keys = unique->subtables[i].keys; newsubtables[i].maxKeys = unique->subtables[i].maxKeys; newsubtables[i].dead = unique->subtables[i].dead; + newsubtables[i].next = i; newsubtables[i].nodelist = unique->subtables[i].nodelist; newsubtables[i].bindVar = unique->subtables[i].bindVar; newsubtables[i].varType = unique->subtables[i].varType; @@ -1975,6 +2011,7 @@ cuddInsertSubtables( newsubtables[i].keys = 0; newsubtables[i].maxKeys = numSlots * DD_MAX_SUBTABLE_DENSITY; newsubtables[i].dead = 0; + newsubtables[i].next = i; newsubtables[i].bindVar = 0; newsubtables[i].varType = CUDD_VAR_PRIMARY_INPUT; newsubtables[i].pairIndex = 0; @@ -2000,6 +2037,7 @@ cuddInsertSubtables( newsubtables[i+n].keys = unique->subtables[i].keys; newsubtables[i+n].maxKeys = unique->subtables[i].maxKeys; newsubtables[i+n].dead = unique->subtables[i].dead; + newsubtables[i+n].next = i+n; newsubtables[i+n].nodelist = unique->subtables[i].nodelist; newsubtables[i+n].bindVar = unique->subtables[i].bindVar; newsubtables[i+n].varType = unique->subtables[i].varType; @@ -2080,6 +2118,7 @@ cuddInsertSubtables( unique->subtables[j].maxKeys = unique->subtables[j+n].maxKeys; unique->subtables[j].dead = unique->subtables[j+n].dead; + unique->subtables[j].next = j; FREE(unique->subtables[j].nodelist); unique->subtables[j].nodelist = unique->subtables[j+n].nodelist; @@ -2118,21 +2157,21 @@ cuddInsertSubtables( } /* end of cuddInsertSubtables */ -/**Function******************************************************************** - - Synopsis [Destroys the n most recently created subtables in a unique table.] +/** + @brief Destroys the n most recently created subtables in a unique table. - Description [Destroys the n most recently created subtables in a unique - table. n should be positive. The subtables should not contain any live + @details n should be positive. The subtables should not contain any live nodes, except the (isolated) projection function. The projection - functions are freed. Returns 1 if successful; 0 otherwise.] + functions are freed. - SideEffects [The variable map used for fast variable substitution is - destroyed if it exists. In this case the cache is also cleared.] + @return 1 if successful; 0 otherwise. - SeeAlso [cuddInsertSubtables Cudd_SetVarMap] + @sideeffect The variable map used for fast variable substitution is + destroyed if it exists. In this case the cache is also cleared. -******************************************************************************/ + @see cuddInsertSubtables Cudd_SetVarMap + +*/ int cuddDestroySubtables( DdManager * unique, @@ -2166,7 +2205,6 @@ cuddDestroySubtables( for (index = firstIndex; index < lastIndex; index++) { level = unique->perm[index]; if (level < lowestLevel) lowestLevel = level; - nodelist = subtables[level].nodelist; if (subtables[level].keys - subtables[level].dead != 1) return(0); /* The projection function should be isolated. If the ref count ** is 1, everything is OK. If the ref count is saturated, then @@ -2223,6 +2261,7 @@ cuddDestroySubtables( subtables[newlevel].keys = subtables[level].keys; subtables[newlevel].maxKeys = subtables[level].maxKeys; subtables[newlevel].dead = subtables[level].dead; + subtables[newlevel].next = newlevel; subtables[newlevel].nodelist = subtables[level].nodelist; index = unique->invperm[level]; unique->perm[index] = newlevel; @@ -2250,22 +2289,22 @@ cuddDestroySubtables( } /* end of cuddDestroySubtables */ -/**Function******************************************************************** +/** + @brief Increases the number of %ZDD subtables in a unique table so + that it meets or exceeds index. - Synopsis [Increases the number of ZDD subtables in a unique table so - that it meets or exceeds index.] + @details When new %ZDD variables are created, it is possible to + preserve the functions unchanged, or it is possible to preserve the + covers unchanged, but not both. cuddResizeTableZdd preserves the + covers. - Description [Increases the number of ZDD subtables in a unique table so - that it meets or exceeds index. When new ZDD variables are created, it - is possible to preserve the functions unchanged, or it is possible to - preserve the covers unchanged, but not both. cuddResizeTableZdd preserves - the covers. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [ddResizeTable] + @see ddResizeTable -******************************************************************************/ +*/ int cuddResizeTableZdd( DdManager * unique, @@ -2288,6 +2327,7 @@ cuddResizeTableZdd( unique->subtableZ[i].keys = 0; unique->subtableZ[i].maxKeys = numSlots * DD_MAX_SUBTABLE_DENSITY; unique->subtableZ[i].dead = 0; + unique->subtableZ[i].next = i; unique->permZ[i] = i; unique->invpermZ[i] = i; newnodelist = unique->subtableZ[i].nodelist = @@ -2346,6 +2386,7 @@ cuddResizeTableZdd( newsubtables[i].keys = unique->subtableZ[i].keys; newsubtables[i].maxKeys = unique->subtableZ[i].maxKeys; newsubtables[i].dead = unique->subtableZ[i].dead; + newsubtables[i].next = i; newsubtables[i].nodelist = unique->subtableZ[i].nodelist; newperm[i] = unique->permZ[i]; newinvperm[i] = unique->invpermZ[i]; @@ -2357,6 +2398,7 @@ cuddResizeTableZdd( newsubtables[i].keys = 0; newsubtables[i].maxKeys = numSlots * DD_MAX_SUBTABLE_DENSITY; newsubtables[i].dead = 0; + newsubtables[i].next = i; newperm[i] = i; newinvperm[i] = i; newnodelist = newsubtables[i].nodelist = ALLOC(DdNodePtr, numSlots); @@ -2399,17 +2441,12 @@ cuddResizeTableZdd( } /* end of cuddResizeTableZdd */ -/**Function******************************************************************** - - Synopsis [Adjusts parameters of a table to slow down its growth.] +/** + @brief Adjusts parameters of a table to slow down its growth. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ void cuddSlowTableGrowth( DdManager *unique) @@ -2424,9 +2461,11 @@ cuddSlowTableGrowth( unique->gcFrac = DD_GC_FRAC_MIN; unique->minDead = (unsigned) (DD_GC_FRAC_MIN * (double) unique->slots); cuddShrinkDeathRow(unique); - (void) fprintf(unique->err,"Slowing down table growth: "); +#ifdef DD_VERBOSE + (void) fprintf(unique->err,"CUDD: slowing down table growth: "); (void) fprintf(unique->err,"GC fraction = %.2f\t", unique->gcFrac); (void) fprintf(unique->err,"minDead = %u\n", unique->minDead); +#endif } /* end of cuddSlowTableGrowth */ @@ -2436,17 +2475,14 @@ cuddSlowTableGrowth( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Rehashes a %ZDD unique subtable. - Synopsis [Rehashes a ZDD unique subtable.] + @sideeffect None - Description [] + @see cuddRehash - SideEffects [None] - - SeeAlso [cuddRehash] - -******************************************************************************/ +*/ static void ddRehashZdd( DdManager * unique, @@ -2488,7 +2524,7 @@ ddRehashZdd( } while (slots * DD_MAX_SUBTABLE_DENSITY < unique->subtableZ[i].keys); saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = unique->outOfMemCallback; nodelist = ALLOC(DdNodePtr, slots); MMoutOfMemory = saveHandler; if (nodelist == NULL) { @@ -2535,22 +2571,21 @@ ddRehashZdd( } /* end of ddRehashZdd */ -/**Function******************************************************************** +/** + @brief Increases the number of subtables in a unique table so + that it meets or exceeds index. - Synopsis [Increases the number of subtables in a unique table so - that it meets or exceeds index.] + @details The parameter amount determines how much spare space is + allocated to prevent too frequent resizing. If index is negative, + the table is resized, but no new variables are created. - Description [Increases the number of subtables in a unique table so - that it meets or exceeds index. The parameter amount determines how - much spare space is allocated to prevent too frequent resizing. If - index is negative, the table is resized, but no new variables are - created. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Reserve cuddResizeTableZdd] + @see Cudd_Reserve cuddResizeTableZdd -******************************************************************************/ +*/ static int ddResizeTable( DdManager * unique, @@ -2564,7 +2599,7 @@ ddResizeTable( int oldsize,newsize; int i,j,reorderSave; int numSlots = unique->initSlots; - int *newperm, *newinvperm, *newmap; + int *newperm, *newinvperm, *newmap = NULL; DdNode *one, *zero; oldsize = unique->size; @@ -2577,6 +2612,7 @@ ddResizeTable( unique->subtables[i].keys = 0; unique->subtables[i].maxKeys = numSlots * DD_MAX_SUBTABLE_DENSITY; unique->subtables[i].dead = 0; + unique->subtables[i].next = i; unique->subtables[i].bindVar = 0; unique->subtables[i].varType = CUDD_VAR_PRIMARY_INPUT; unique->subtables[i].pairIndex = 0; @@ -2608,7 +2644,7 @@ ddResizeTable( ** larger one; move all old subtables, and initialize the new ** subtables up to index included. */ - newsize = (index < 0) ? amount : index + amount; + newsize = (index < 0) ? amount + oldsize : index + amount; #ifdef DD_VERBOSE (void) fprintf(unique->err, "Increasing the table size from %d to %d\n", @@ -2679,6 +2715,7 @@ ddResizeTable( newsubtables[i].keys = unique->subtables[i].keys; newsubtables[i].maxKeys = unique->subtables[i].maxKeys; newsubtables[i].dead = unique->subtables[i].dead; + newsubtables[i].next = i; newsubtables[i].nodelist = unique->subtables[i].nodelist; newsubtables[i].bindVar = unique->subtables[i].bindVar; newsubtables[i].varType = unique->subtables[i].varType; @@ -2697,6 +2734,7 @@ ddResizeTable( newsubtables[i].keys = 0; newsubtables[i].maxKeys = numSlots * DD_MAX_SUBTABLE_DENSITY; newsubtables[i].dead = 0; + newsubtables[i].next = i; newsubtables[i].bindVar = 0; newsubtables[i].varType = CUDD_VAR_PRIMARY_INPUT; newsubtables[i].pairIndex = 0; @@ -2745,7 +2783,7 @@ ddResizeTable( unique->size = index + 1; if (unique->tree != NULL) { - unique->tree->size = ddMax(unique->tree->size, unique->size); + unique->tree->size = ddMax(unique->tree->size, (MtrHalfWord) unique->size); } unique->slots += (index + 1 - oldsize) * numSlots; ddFixLimits(unique); @@ -2780,18 +2818,15 @@ ddResizeTable( } /* end of ddResizeTable */ -/**Function******************************************************************** - - Synopsis [Searches the subtables above node for a parent.] +/** + @brief Searches the subtables above node for a parent. - Description [Searches the subtables above node for a parent. Returns 1 - as soon as one parent is found. Returns 0 is the search is fruitless.] + @details Returns 1 as soon as one parent is found. Returns 0 is the + search is fruitless. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int cuddFindParent( DdManager * table, @@ -2825,20 +2860,16 @@ cuddFindParent( } /* end of cuddFindParent */ -/**Function******************************************************************** - - Synopsis [Adjusts the values of table limits.] - - Description [Adjusts the values of table fields controlling the. - sizes of subtables and computed table. If the computed table is too small - according to the new values, it is resized.] +/** + @brief Adjusts the values of table limits. - SideEffects [Modifies manager fields. May resize computed table.] + @details Adjusts the values of table fields controlling the sizes of + subtables and computed table. If the computed table is too small + according to the new values, it is resized. - SeeAlso [] + @sideeffect Modifies manager fields. May resize computed table. -******************************************************************************/ -DD_INLINE +*/ static void ddFixLimits( DdManager *unique) @@ -2856,18 +2887,17 @@ ddFixLimits( #ifndef DD_UNSORTED_FREE_LIST #ifdef DD_RED_BLACK_FREE_LIST -/**Function******************************************************************** +/** + @brief Inserts a DdNode in a red/black search tree. - Synopsis [Inserts a DdNode in a red/black search tree.] + @details Nodes from the same "page" (defined by DD_PAGE_MASK) are + linked in a LIFO list. - Description [Inserts a DdNode in a red/black search tree. Nodes from - the same "page" (defined by DD_PAGE_MASK) are linked in a LIFO list.] + @sideeffect None - SideEffects [None] + @see cuddOrderedThread - SeeAlso [cuddOrderedThread] - -******************************************************************************/ +*/ static void cuddOrderedInsert( DdNodePtr * root, @@ -2897,26 +2927,24 @@ cuddOrderedInsert( } /* end of cuddOrderedInsert */ -/**Function******************************************************************** - - Synopsis [Threads all the nodes of a search tree into a linear list.] +/** + @brief Threads all the nodes of a search tree into a linear list. - Description [Threads all the nodes of a search tree into a linear - list. For each node of the search tree, the "left" child, if non-null, has - a lower address than its parent, and the "right" child, if non-null, has a - higher address than its parent. - The list is sorted in order of increasing addresses. The search - tree is destroyed as a result of this operation. The last element of - the linear list is made to point to the address passed in list. Each + @details For each node of the search tree, the "left" child, if + non-null, has a lower address than its parent, and the "right" + child, if non-null, has a higher address than its parent. The list + is sorted in order of increasing addresses. The search tree is + destroyed as a result of this operation. The last element of the + linear list is made to point to the address passed in list. Each node if the search tree is a linearly-linked list of nodes from the - same memory page (as defined in DD_PAGE_MASK). When a node is added to - the linear list, all the elements of the linked list are added.] + same memory page (as defined in DD_PAGE_MASK). When a node is added + to the linear list, all the elements of the linked list are added. - SideEffects [The search tree is destroyed as a result of this operation.] + @sideeffect The search tree is destroyed as a result of this operation. - SeeAlso [cuddOrderedInsert] + @see cuddOrderedInsert -******************************************************************************/ +*/ static DdNode * cuddOrderedThread( DdNode * root, @@ -2974,18 +3002,14 @@ cuddOrderedThread( } /* end of cuddOrderedThread */ -/**Function******************************************************************** - - Synopsis [Performs the left rotation for red/black trees.] +/** + @brief Performs the left rotation for red/black trees. - Description [] + @sideeffect None - SideEffects [None] + @see cuddRotateRight - SeeAlso [cuddRotateRight] - -******************************************************************************/ -DD_INLINE +*/ static void cuddRotateLeft( DdNodePtr * nodeP) @@ -3000,18 +3024,14 @@ cuddRotateLeft( } /* end of cuddRotateLeft */ -/**Function******************************************************************** - - Synopsis [Performs the right rotation for red/black trees.] +/** + @brief Performs the right rotation for red/black trees. - Description [] + @sideeffect None - SideEffects [None] + @see cuddRotateLeft - SeeAlso [cuddRotateLeft] - -******************************************************************************/ -DD_INLINE +*/ static void cuddRotateRight( DdNodePtr * nodeP) @@ -3026,17 +3046,12 @@ cuddRotateRight( } /* end of cuddRotateRight */ -/**Function******************************************************************** - - Synopsis [Rebalances a red/black tree.] +/** + @brief Rebalances a red/black tree. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static void cuddDoRebalance( DdNodePtr ** stack, @@ -3101,19 +3116,15 @@ cuddDoRebalance( #endif -/**Function******************************************************************** - - Synopsis [Fixes a variable tree after the insertion of new subtables.] +/** + @brief Fixes a variable tree after the insertion of new subtables. - Description [Fixes a variable tree after the insertion of new subtables. - After such an insertion, the low fields of the tree below the insertion - point are inconsistent.] + @details After such an insertion, the low fields of the tree below + the insertion point are inconsistent. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static void ddPatchTree( DdManager *dd, @@ -3135,30 +3146,23 @@ ddPatchTree( #ifdef DD_DEBUG -/**Function******************************************************************** - - Synopsis [Checks whether a collision list is ordered.] - - Description [] +/** + @brief Checks whether a collision list is ordered. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int cuddCheckCollisionOrdering( DdManager *unique, int i, int j) { - int slots; DdNode *node, *next; DdNodePtr *nodelist; DdNode *sentinel = &(unique->sentinel); nodelist = unique->subtables[i].nodelist; - slots = unique->subtables[i].slots; node = nodelist[j]; if (node == sentinel) return(1); next = node->next; @@ -3180,22 +3184,19 @@ cuddCheckCollisionOrdering( -/**Function******************************************************************** - - Synopsis [Reports problem in garbage collection.] - - Description [] +/** + @brief Reports problem in garbage collection. - SideEffects [None] + @sideeffect None - SeeAlso [cuddGarbageCollect cuddGarbageCollectZdd] + @see cuddGarbageCollect cuddGarbageCollectZdd -******************************************************************************/ +*/ static void ddReportRefMess( - DdManager *unique /* manager */, - int i /* table in which the problem occurred */, - const char *caller /* procedure that detected the problem */) + DdManager *unique /**< manager */, + int i /**< table in which the problem occurred */, + const char *caller /**< procedure that detected the problem */) { if (i == CUDD_CONST_INDEX) { (void) fprintf(unique->err, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddUtil.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddUtil.c similarity index 56% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddUtil.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddUtil.c index 4acb576b8..0271fa2bc 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddUtil.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddUtil.c @@ -1,82 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddUtil.c] - - PackageName [cudd] - - Synopsis [Utility functions.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_PrintMinterm() - <li> Cudd_bddPrintCover() - <li> Cudd_PrintDebug() - <li> Cudd_DagSize() - <li> Cudd_EstimateCofactor() - <li> Cudd_EstimateCofactorSimple() - <li> Cudd_SharingSize() - <li> Cudd_CountMinterm() - <li> Cudd_EpdCountMinterm() - <li> Cudd_CountPath() - <li> Cudd_CountPathsToNonZero() - <li> Cudd_SupportIndices() - <li> Cudd_Support() - <li> Cudd_SupportIndex() - <li> Cudd_SupportSize() - <li> Cudd_VectorSupportIndices() - <li> Cudd_VectorSupport() - <li> Cudd_VectorSupportIndex() - <li> Cudd_VectorSupportSize() - <li> Cudd_ClassifySupport() - <li> Cudd_CountLeaves() - <li> Cudd_bddPickOneCube() - <li> Cudd_bddPickOneMinterm() - <li> Cudd_bddPickArbitraryMinterms() - <li> Cudd_SubsetWithMaskVars() - <li> Cudd_FirstCube() - <li> Cudd_NextCube() - <li> Cudd_bddComputeCube() - <li> Cudd_addComputeCube() - <li> Cudd_FirstNode() - <li> Cudd_NextNode() - <li> Cudd_GenFree() - <li> Cudd_IsGenEmpty() - <li> Cudd_IndicesToCube() - <li> Cudd_PrintVersion() - <li> Cudd_AverageDistance() - <li> Cudd_Random() - <li> Cudd_Srandom() - <li> Cudd_Density() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddP() - <li> cuddStCountfree() - <li> cuddCollectNodes() - <li> cuddNodeArray() - </ul> - Static procedures included in this module: - <ul> - <li> dp2() - <li> ddPrintMintermAux() - <li> ddDagInt() - <li> ddCountMintermAux() - <li> ddEpdCountMintermAux() - <li> ddCountPathAux() - <li> ddSupportStep() - <li> ddClearFlag() - <li> ddLeavesInt() - <li> ddPickArbitraryMinterms() - <li> ddPickRepresentativeCube() - <li> ddEpdFree() - <li> ddFindSupport() - <li> ddClearVars() - <li> indexCompare() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Utility functions. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -106,13 +38,16 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ +#include <stddef.h> +#include <float.h> #include "util.h" +#include "epdInt.h" #include "cuddInt.h" -#include "ucbqsort.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ @@ -127,7 +62,6 @@ #define LEQA2 40692 #define LEQQ2 52774 #define LEQR2 3791 -#define STAB_SIZE 64 #define STAB_DIV (1 + (MODULUS1 - 1) / STAB_SIZE) /*---------------------------------------------------------------------------*/ @@ -143,16 +77,6 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddUtil.c,v 1.83 2012/02/05 01:07:19 fabio Exp $"; -#endif - -static DdNode *background, *zero; - -static long cuddRand = 0; -static long cuddRand2; -static long shuffleSelect; -static long shuffleTable[STAB_SIZE]; /*---------------------------------------------------------------------------*/ /* Macro declarations */ @@ -160,11 +84,7 @@ static long shuffleTable[STAB_SIZE]; #define bang(f) ((Cudd_IsComplement(f)) ? '!' : ' ') -#ifdef __cplusplus -extern "C" { -#endif - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -177,8 +97,9 @@ static int cuddNodeArrayRecur (DdNode *f, DdNodePtr *table, int index); static int cuddEstimateCofactor (DdManager *dd, st_table *table, DdNode * node, int i, int phase, DdNode ** ptr); static DdNode * cuddUniqueLookup (DdManager * unique, int index, DdNode * T, DdNode * E); static int cuddEstimateCofactorSimple (DdNode * node, int i); -static double ddCountMintermAux (DdNode *node, double max, DdHashTable *table); -static int ddEpdCountMintermAux (DdNode *node, EpDouble *max, EpDouble *epd, st_table *table); +static double ddCountMintermAux (DdManager *dd, DdNode *node, double max, DdHashTable *table); +static int ddEpdCountMintermAux (DdManager const *dd, DdNode *node, EpDouble *max, EpDouble *epd, st_table *table); +static long double ddLdblCountMintermAux(DdManager const *manager, DdNode *node, long double max, st_table *table); static double ddCountPathAux (DdNode *node, st_table *table); static double ddCountPathsToNonZero (DdNode * N, st_table * table); static void ddSupportStep (DdNode *f, int *support); @@ -186,37 +107,36 @@ static void ddClearFlag (DdNode *f); static int ddLeavesInt (DdNode *n); static int ddPickArbitraryMinterms (DdManager *dd, DdNode *node, int nvars, int nminterms, char **string); static int ddPickRepresentativeCube (DdManager *dd, DdNode *node, double *weight, char *string); -static enum st_retval ddEpdFree (char * key, char * value, char * arg); +static enum st_retval ddEpdFree (void * key, void * value, void * arg); static void ddFindSupport(DdManager *dd, DdNode *f, int *SP); static void ddClearVars(DdManager *dd, int SP); static int indexCompare(const void *a, const void *b); - -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} +static enum st_retval ddLdblFree(void * key, void * value, void * arg); +#if HAVE_POWL != 1 +static long double powl(long double base, long double exponent); #endif +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Prints a disjoint sum of products.] +/** + @brief Prints a disjoint sum of products. - Description [Prints a disjoint sum of product cover for the function + @details Prints a disjoint sum of product cover for the function rooted at node. Each product corresponds to a path from node to a leaf node different from the logical zero, and different from the - background value. Uses the package default output file. Returns 1 - if successful; 0 otherwise.] + background value. Uses the package default output file. + + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_PrintDebug Cudd_bddPrintCover] + @see Cudd_PrintDebug Cudd_bddPrintCover -******************************************************************************/ +*/ int Cudd_PrintMinterm( DdManager * manager, @@ -224,8 +144,6 @@ Cudd_PrintMinterm( { int i, *list; - background = manager->background; - zero = Cudd_Not(manager->one); list = ALLOC(int,manager->size); if (list == NULL) { manager->errorCode = CUDD_MEMORY_OUT; @@ -239,21 +157,22 @@ Cudd_PrintMinterm( } /* end of Cudd_PrintMinterm */ -/**Function******************************************************************** - - Synopsis [Prints a sum of prime implicants of a BDD.] +/** + @brief Prints a sum of prime implicants of a %BDD. - Description [Prints a sum of product cover for an incompletely + @details Prints a sum of product cover for an incompletely specified function given by a lower bound and an upper bound. Each product is a prime implicant obtained by expanding the product corresponding to a path from node to the constant one. Uses the - package default output file. Returns 1 if successful; 0 otherwise.] + package default output file. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [Cudd_PrintMinterm] + @sideeffect None -******************************************************************************/ + @see Cudd_PrintMinterm + +*/ int Cudd_bddPrintCover( DdManager *dd, @@ -357,13 +276,11 @@ Cudd_bddPrintCover( } /* end of Cudd_bddPrintCover */ -/**Function******************************************************************** - - Synopsis [Prints to the standard output a DD and its statistics.] +/** + @brief Prints to the manager standard output a %DD and its statistics. - Description [Prints to the standard output a DD and its statistics. - The statistics include the number of nodes, the number of leaves, and - the number of minterms. (The number of minterms is the number of + @details The statistics include the number of nodes, the number of leaves, + and the number of minterms. (The number of minterms is the number of assignments to the variables that cause the function to be different from the logical zero (for BDDs) and from the background value (for ADDs.) The statistics are printed if pr > 0. Specifically: @@ -375,14 +292,16 @@ Cudd_bddPrintCover( <li> pr > 3 : prints counts + disjoint sum of product + list of nodes </ul> For the purpose of counting the number of minterms, the function is - supposed to depend on n variables. Returns 1 if successful; 0 otherwise.] + supposed to depend on n variables. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [Cudd_DagSize Cudd_CountLeaves Cudd_CountMinterm - Cudd_PrintMinterm] + @sideeffect None -******************************************************************************/ + @see Cudd_DagSize Cudd_CountLeaves Cudd_CountMinterm + Cudd_PrintMinterm + +*/ int Cudd_PrintDebug( DdManager * dd, @@ -396,9 +315,13 @@ Cudd_PrintDebug( double minterms; int retval = 1; + if (dd == NULL) { + return(0); + } if (f == NULL) { (void) fprintf(dd->out,": is the NULL DD\n"); (void) fflush(dd->out); + dd->errorCode = CUDD_INVALID_ARG; return(0); } azero = DD_ZERO(dd); @@ -414,9 +337,14 @@ Cudd_PrintDebug( leaves = Cudd_CountLeaves(f); if (leaves == CUDD_OUT_OF_MEM) retval = 0; minterms = Cudd_CountMinterm(dd, f, n); - if (minterms == (double)CUDD_OUT_OF_MEM) retval = 0; - (void) fprintf(dd->out,": %d nodes %d leaves %g minterms\n", - nodes, leaves, minterms); + if (minterms == (double)CUDD_OUT_OF_MEM) { + retval = 0; + (void) fprintf(dd->out,": %d nodes %d leaves unknown minterms\n", + nodes, leaves); + } else { + (void) fprintf(dd->out,": %d nodes %d leaves %g minterms\n", + nodes, leaves, minterms); + } if (pr > 2) { if (!cuddP(dd, f)) retval = 0; } @@ -431,18 +359,79 @@ Cudd_PrintDebug( } /* end of Cudd_PrintDebug */ -/**Function******************************************************************** +/** + @brief Prints a one-line summary of an %ADD or %BDD to the manager stdout. - Synopsis [Counts the number of nodes in a DD.] + @details The summary includes the number of nodes, the number of leaves, + and the number of minterms. The number of minterms is computed with + arbitrary precision unlike Cudd_PrintDebug(). For the purpose of counting + minterms, the function `f` is supposed to depend on `n` variables. - Description [Counts the number of nodes in a DD. Returns the number - of nodes in the graph rooted at node.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @see Cudd_PrintDebug Cudd_ApaPrintMinterm Cudd_ApaPrintMintermExp +*/ +int +Cudd_PrintSummary( + DdManager * dd /**< manager */, + DdNode * f /**< %DD to be summarized */, + int n /**< number of variables for minterm computation */, + int mode /**< integer (0) or exponential (1) format */) +{ + DdNode *azero, *bzero; + int nodes, leaves, digits; + int retval = 1; + DdApaNumber count; - SeeAlso [Cudd_SharingSize Cudd_PrintDebug] + if (dd == NULL) { + return(0); + } + if (f == NULL) { + (void) fprintf(dd->out,": is the NULL DD\n"); + (void) fflush(dd->out); + dd->errorCode = CUDD_INVALID_ARG; + return(0); + } + azero = DD_ZERO(dd); + bzero = Cudd_Not(DD_ONE(dd)); + if (f == azero || f == bzero){ + (void) fprintf(dd->out,": is the zero DD\n"); + (void) fflush(dd->out); + return(1); + } + nodes = Cudd_DagSize(f); + if (nodes == CUDD_OUT_OF_MEM) retval = 0; + leaves = Cudd_CountLeaves(f); + if (leaves == CUDD_OUT_OF_MEM) retval = 0; + (void) fprintf(dd->out,": %d nodes %d leaves ", nodes, leaves); + count = Cudd_ApaCountMinterm(dd, f, n, &digits); + if (count == NULL) { + retval = 0; + } else if (mode) { + if (!Cudd_ApaPrintExponential(dd->out, digits, count, 6)) + retval = 0; + } else { + if (!Cudd_ApaPrintDecimal(dd->out, digits, count)) + retval = 0; + } + FREE(count); + (void) fprintf(dd->out, " minterms\n"); + (void) fflush(dd->out); + return(retval); -******************************************************************************/ +} /* end of Cudd_PrintSummary */ + + +/** + @brief Counts the number of nodes in a %DD. + + @return the number of nodes in the graph rooted at node. + + @sideeffect None + + @see Cudd_SharingSize Cudd_PrintDebug + +*/ int Cudd_DagSize( DdNode * node) @@ -457,33 +446,33 @@ Cudd_DagSize( } /* end of Cudd_DagSize */ -/**Function******************************************************************** +/** + @brief Estimates the number of nodes in a cofactor of a %DD. - Synopsis [Estimates the number of nodes in a cofactor of a DD.] + @details This function uses a refinement of the algorithm of Cabodi + et al. (ICCAD96). The refinement allows the procedure to account + for part of the recombination that may occur in the part of the + cofactor above the cofactoring variable. This procedure does not + create any new node. It does keep a small table of results; + therefore it may run out of memory. If this is a concern, one + should use Cudd_EstimateCofactorSimple, which is faster, does not + allocate any memory, but is less accurate. - Description [Estimates the number of nodes in a cofactor of a DD. - Returns an estimate of the number of nodes in a cofactor of - the graph rooted at node with respect to the variable whose index is i. + @return an estimate of the number of nodes in a cofactor of the + graph rooted at node with respect to the variable whose index is i. In case of failure, returns CUDD_OUT_OF_MEM. - This function uses a refinement of the algorithm of Cabodi et al. - (ICCAD96). The refinement allows the procedure to account for part - of the recombination that may occur in the part of the cofactor above - the cofactoring variable. This procedure does not create any new node. - It does keep a small table of results; therefore it may run out of memory. - If this is a concern, one should use Cudd_EstimateCofactorSimple, which - is faster, does not allocate any memory, but is less accurate.] - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_DagSize Cudd_EstimateCofactorSimple] + @see Cudd_DagSize Cudd_EstimateCofactorSimple -******************************************************************************/ +*/ int Cudd_EstimateCofactor( - DdManager *dd /* manager */, - DdNode * f /* function */, - int i /* index of variable */, - int phase /* 1: positive; 0: negative */ + DdManager *dd /**< manager */, + DdNode * f /**< function */, + int i /**< index of variable */, + int phase /**< 1: positive; 0: negative */ ) { int val; @@ -491,33 +480,37 @@ Cudd_EstimateCofactor( st_table *table; table = st_init_table(st_ptrcmp,st_ptrhash); - if (table == NULL) return(CUDD_OUT_OF_MEM); + if (table == NULL) { + dd->errorCode = CUDD_MEMORY_OUT; + return(CUDD_OUT_OF_MEM); + } val = cuddEstimateCofactor(dd,table,Cudd_Regular(f),i,phase,&ptr); ddClearFlag(Cudd_Regular(f)); st_free_table(table); - + if (val == CUDD_OUT_OF_MEM) + dd->errorCode = CUDD_MEMORY_OUT; + return(val); } /* end of Cudd_EstimateCofactor */ -/**Function******************************************************************** - - Synopsis [Estimates the number of nodes in a cofactor of a DD.] +/** + @brief Estimates the number of nodes in a cofactor of a %DD. - Description [Estimates the number of nodes in a cofactor of a DD. - Returns an estimate of the number of nodes in the positive cofactor of - the graph rooted at node with respect to the variable whose index is i. - This procedure implements with minor changes the algorithm of Cabodi et al. - (ICCAD96). It does not allocate any memory, it does not change the - state of the manager, and it is fast. However, it has been observed to - overestimate the size of the cofactor by as much as a factor of 2.] + @details Returns an estimate of the number of nodes in the positive + cofactor of the graph rooted at node with respect to the variable + whose index is i. This procedure implements with minor changes the + algorithm of Cabodi et al. (ICCAD96). It does not allocate any + memory, it does not change the state of the manager, and it is + fast. However, it has been observed to overestimate the size of the + cofactor by as much as a factor of 2. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_DagSize] + @see Cudd_DagSize -******************************************************************************/ +*/ int Cudd_EstimateCofactorSimple( DdNode * node, @@ -533,18 +526,18 @@ Cudd_EstimateCofactorSimple( } /* end of Cudd_EstimateCofactorSimple */ -/**Function******************************************************************** +/** + @brief Counts the number of nodes in an array of DDs. - Synopsis [Counts the number of nodes in an array of DDs.] + @details Shared nodes are counted only once. - Description [Counts the number of nodes in an array of DDs. Shared - nodes are counted only once. Returns the total number of nodes.] + @return the total number of nodes. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_DagSize] + @see Cudd_DagSize -******************************************************************************/ +*/ int Cudd_SharingSize( DdNode ** nodeArray, @@ -564,66 +557,128 @@ Cudd_SharingSize( } /* end of Cudd_SharingSize */ -/**Function******************************************************************** - - Synopsis [Counts the number of minterms of a DD.] - - Description [Counts the number of minterms of a DD. The function is - assumed to depend on nvars variables. The minterm count is - represented as a double, to allow for a larger number of variables. - Returns the number of minterms of the function rooted at node if - successful; (double) CUDD_OUT_OF_MEM otherwise.] - - SideEffects [None] - - SeeAlso [Cudd_PrintDebug Cudd_CountPath] +/** + @brief Counts the minterms of an %ADD or %BDD. + + @details The function is assumed to depend on `nvars` variables. The + minterm count is represented as a double; hence overflow is + possible. For functions with many variables (more than 1023 if + floating point conforms to IEEE 754), one should consider + Cudd_ApaCountMinterm() or Cudd_EpdCountMinterm(). + + @return the number of minterms of the function rooted at node if + successful; +infinity if the number of minterms is known to be larger + than the maximum value representable as a double; `(double) CUDD_OUT_OF_MEM` + otherwise. + + @sideeffect None + + @see Cudd_ApaCountMinterm Cudd_EpdCountMinterm Cudd_LdblCountMinterm + Cudd_PrintDebug Cudd_CountPath + +*/ +//double +//Cudd_CountMinterm( +// DdManager * manager, +// DdNode * node, +// int nvars) +//{ +// double max; +// DdHashTable *table; +// double res; +// CUDD_VALUE_TYPE epsilon; +// +// /* Scale the maximum number of minterm. This is done in an attempt +// * to deal with functions that depend on more than 1023, but less +// * than 2044 variables and don't have too many minterms. +// */ +// printf("vars: %i, min_exp: %.400f, %i\n", nvars, DBL_MIN_EXP, DBL_MIN_EXP); +// printf("1: %f, 2: %i \n", (double)(nvars + DBL_MIN_EXP), (nvars + DBL_MIN_EXP)); +// max = pow(2.0,(double)(nvars + DBL_MIN_EXP)); +// printf("max: %f, DD_PLUS_INF_VAL: %.50f\n", max, DD_PLUS_INF_VAL); +// if (max >= DD_PLUS_INF_VAL) { +// return((double)CUDD_OUT_OF_MEM); +// } +// table = cuddHashTableInit(manager,1,2); +// if (table == NULL) { +// return((double)CUDD_OUT_OF_MEM); +// } +// /* Temporarily set epsilon to 0 to avoid rounding errors. */ +// epsilon = Cudd_ReadEpsilon(manager); +// Cudd_SetEpsilon(manager,(CUDD_VALUE_TYPE)0.0); +// res = ddCountMintermAux(manager,node,max,table); +// cuddHashTableQuit(table); +// Cudd_SetEpsilon(manager,epsilon); +// if (res == (double)CUDD_OUT_OF_MEM) { +// return((double)CUDD_OUT_OF_MEM); +// } else if (res >= pow(2.0,(double)(DBL_MAX_EXP + DBL_MIN_EXP))) { +// /* Minterm count is too large to be scaled back. */ +// return(DD_PLUS_INF_VAL); +// } else { +// printf("in third case: %.400f\n", res); +// /* Undo the scaling. */ +// res *= pow(2.0,(double)-DBL_MIN_EXP); +// printf("after rescaling: %f\n", res); +// return(res); +// } +// +//} /* end of Cudd_CountMinterm */ -******************************************************************************/ +/**Function******************************************************************** + + Synopsis [Counts the number of minterms of a DD.] + + Description [Counts the number of minterms of a DD. The function is + assumed to depend on nvars variables. The minterm count is + represented as a double, to allow for a larger number of variables. + Returns the number of minterms of the function rooted at node if + successful; (double) CUDD_OUT_OF_MEM otherwise.] + + SideEffects [None] + + SeeAlso [Cudd_PrintDebug Cudd_CountPath] + + ******************************************************************************/ double Cudd_CountMinterm( - DdManager * manager, - DdNode * node, - int nvars) + DdManager * manager, + DdNode * node, + int nvars) { double max; DdHashTable *table; double res; CUDD_VALUE_TYPE epsilon; - - background = manager->background; - zero = Cudd_Not(manager->one); - + max = pow(2.0,(double)nvars); table = cuddHashTableInit(manager,1,2); if (table == NULL) { - return((double)CUDD_OUT_OF_MEM); + return((double)CUDD_OUT_OF_MEM); } epsilon = Cudd_ReadEpsilon(manager); Cudd_SetEpsilon(manager,(CUDD_VALUE_TYPE)0.0); - res = ddCountMintermAux(node,max,table); + res = ddCountMintermAux(manager,node,max,table); cuddHashTableQuit(table); Cudd_SetEpsilon(manager,epsilon); - + return(res); - + } /* end of Cudd_CountMinterm */ +/** + @brief Counts the paths of a %DD. -/**Function******************************************************************** - - Synopsis [Counts the number of paths of a DD.] + @details Paths to all terminal nodes are counted. The path count is + represented as a double; hence overflow is possible. - Description [Counts the number of paths of a DD. Paths to all - terminal nodes are counted. The path count is represented as a - double, to allow for a larger number of variables. Returns the - number of paths of the function rooted at node if successful; - (double) CUDD_OUT_OF_MEM otherwise.] + @return the number of paths of the function rooted at node if + successful; `(double) CUDD_OUT_OF_MEM` otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_CountMinterm] + @see Cudd_CountMinterm -******************************************************************************/ +*/ double Cudd_CountPath( DdNode * node) @@ -644,23 +699,24 @@ Cudd_CountPath( } /* end of Cudd_CountPath */ -/**Function******************************************************************** +/** + @brief Counts the minterms of an %ADD or %BDD with extended range. - Synopsis [Counts the number of minterms of a DD with extended precision.] + @details The function is assumed to depend on `nvars` variables. The + minterm count is represented as an `EpDouble`, to allow for any + number of variables. - Description [Counts the number of minterms of a DD with extended precision. - The function is assumed to depend on nvars variables. The minterm count is - represented as an EpDouble, to allow any number of variables. - Returns 0 if successful; CUDD_OUT_OF_MEM otherwise.] + @return 0 if successful; `CUDD_OUT_OF_MEM` otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_PrintDebug Cudd_CountPath] + @see Cudd_CountMinterm Cudd_LdblCountMinterm Cudd_ApaCountMinterm + Cudd_PrintDebug Cudd_CountPath -******************************************************************************/ +*/ int Cudd_EpdCountMinterm( - DdManager * manager, + DdManager const * manager, DdNode * node, int nvars, EpDouble * epd) @@ -669,16 +725,13 @@ Cudd_EpdCountMinterm( st_table *table; int status; - background = manager->background; - zero = Cudd_Not(manager->one); - EpdPow2(nvars, &max); - table = st_init_table(EpdCmp, st_ptrhash); + table = st_init_table(st_ptrcmp, st_ptrhash); if (table == NULL) { EpdMakeZero(epd, 0); return(CUDD_OUT_OF_MEM); } - status = ddEpdCountMintermAux(Cudd_Regular(node),&max,epd,table); + status = ddEpdCountMintermAux(manager,Cudd_Regular(node),&max,epd,table); st_foreach(table, ddEpdFree, NULL); st_free_table(table); if (status == CUDD_OUT_OF_MEM) { @@ -694,20 +747,101 @@ Cudd_EpdCountMinterm( } /* end of Cudd_EpdCountMinterm */ -/**Function******************************************************************** +/** + @brief Returns the number of minterms of aa %ADD or %BDD as a long double. - Synopsis [Counts the number of paths to a non-zero terminal of a DD.] + @details On systems where double and long double are the same type, + Cudd_CountMinterm() is preferable. On systems where long double values + have 15-bit exponents, this function avoids overflow for up to 16383 + variables. It applies scaling to try to avoid overflow when the number of + variables is larger than 16383, but smaller than 32764. - Description [Counts the number of paths to a non-zero terminal of a - DD. The path count is - represented as a double, to allow for a larger number of variables. - Returns the number of paths of the function rooted at node.] + @return The nimterm count if successful; +infinity if the number is known to + be too large for representation as a long double; + `(long double)CUDD_OUT_OF_MEM` otherwise. - SideEffects [None] + @see Cudd_CountMinterm Cudd_EpdCountMinterm Cudd_ApaCountMinterm +*/ +long double +Cudd_LdblCountMinterm( + DdManager const *manager, + DdNode *node, + int nvars) +{ + long double max, count; + st_table *table; + + max = powl(2.0L, (long double) (nvars+LDBL_MIN_EXP)); + if (max == HUGE_VALL) { + return((long double)CUDD_OUT_OF_MEM); + } + table = st_init_table(st_ptrcmp, st_ptrhash); + if (table == NULL) { + return((long double)CUDD_OUT_OF_MEM); + } + count = ddLdblCountMintermAux(manager, Cudd_Regular(node), max, table); + st_foreach(table, ddLdblFree, NULL); + st_free_table(table); + if (count == (long double)CUDD_OUT_OF_MEM) { + return((long double)CUDD_OUT_OF_MEM); + } + if (Cudd_IsComplement(node)) { + count = max - count; + } + if (count >= powl(2.0L, (long double)(LDBL_MAX_EXP + LDBL_MIN_EXP))) { + /* Minterm count is too large to be scaled back. */ + return(HUGE_VALL); + } else { + /* Undo the scaling. */ + count *= powl(2.0L,(long double)-LDBL_MIN_EXP); + return(count); + } + +} /* end of Cudd_LdlbCountMinterm */ + + +/** + @brief Prints the number of minterms of an %ADD or %BDD with extended range. + + @return 1 if successful; 0 otherwise. + + @sideeffect None + + @see Cudd_EpdCountMinterm Cudd_ApaPrintMintermExp + +*/ +int +Cudd_EpdPrintMinterm( + DdManager const * dd, + DdNode * node, + int nvars) +{ + EpDouble epd; + int ret; + char pstring[128]; + + ret = Cudd_EpdCountMinterm(dd, node, nvars, &epd); + if (ret !=0) return(0); + EpdGetString(&epd, pstring); + fprintf(dd->out, "%s", pstring); + return(1); + +} /* end of Cudd_EpdPrintMinterm */ - SeeAlso [Cudd_CountMinterm Cudd_CountPath] -******************************************************************************/ +/** + @brief Counts the paths to a non-zero terminal of a %DD. + + @details The path count is represented as a double; hence overflow is + possible. + + @return the number of paths of the function rooted at node. + + @sideeffect None + + @see Cudd_CountMinterm Cudd_CountPath + +*/ double Cudd_CountPathsToNonZero( DdNode * node) @@ -728,24 +862,23 @@ Cudd_CountPathsToNonZero( } /* end of Cudd_CountPathsToNonZero */ -/**Function******************************************************************** - - Synopsis [Finds the variables on which a DD depends.] +/** + @brief Finds the variables on which a %DD depends. - Description [Finds the variables on which a DD depends. Returns the - number of variables if successful; CUDD_OUT_OF_MEM otherwise.] + @return the number of variables if successful; CUDD_OUT_OF_MEM + otherwise. - SideEffects [The indices of the support variables are returned as - side effects. If the function is constant, no array is allocated.] + @sideeffect The indices of the support variables are returned as + side effects. If the function is constant, no array is allocated. - SeeAlso [Cudd_Support Cudd_SupportIndex Cudd_VectorSupportIndices] + @see Cudd_Support Cudd_SupportIndex Cudd_VectorSupportIndices -******************************************************************************/ +*/ int Cudd_SupportIndices( - DdManager * dd /* manager */, - DdNode * f /* DD whose support is sought */, - int **indices /* array containing (on return) the indices */) + DdManager * dd /**< manager */, + DdNode * f /**< %DD whose support is sought */, + int **indices /**< array containing (on return) the indices */) { int SP = 0; @@ -763,7 +896,7 @@ Cudd_SupportIndices( for (i = 0; i < SP; i++) (*indices)[i] = (int) (ptrint) dd->stack[i]; - cudd__qsort(*indices, SP, sizeof(int), indexCompare); + util_qsort(*indices, SP, sizeof(int), indexCompare); } else { *indices = NULL; } @@ -773,23 +906,21 @@ Cudd_SupportIndices( } /* end of Cudd_SupportIndices */ -/**Function******************************************************************** +/** + @brief Finds the variables on which a %DD depends. - Synopsis [Finds the variables on which a DD depends.] + @return a %BDD consisting of the product of the variables if + successful; NULL otherwise. - Description [Finds the variables on which a DD depends. - Returns a BDD consisting of the product of the variables if - successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_VectorSupport Cudd_ClassifySupport - SeeAlso [Cudd_VectorSupport Cudd_ClassifySupport] - -******************************************************************************/ +*/ DdNode * Cudd_Support( - DdManager * dd /* manager */, - DdNode * f /* DD whose support is sought */) + DdManager * dd /**< manager */, + DdNode * f /**< %DD whose support is sought */) { int *support; DdNode *res; @@ -824,25 +955,23 @@ Cudd_Support( } /* end of Cudd_Support */ -/**Function******************************************************************** - - Synopsis [Finds the variables on which a DD depends.] +/** + @brief Finds the variables on which a %DD depends. - Description [Finds the variables on which a DD depends. Returns an - index array of the variables if successful; NULL otherwise. The - size of the array equals the number of variables in the manager. - Each entry of the array is 1 if the corresponding variable is in the - support of the DD and 0 otherwise.] + @return an index array of the variables if successful; NULL + otherwise. The size of the array equals the number of variables in + the manager. Each entry of the array is 1 if the corresponding + variable is in the support of the %DD and 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Support Cudd_SupportIndices Cudd_ClassifySupport] + @see Cudd_Support Cudd_SupportIndices Cudd_ClassifySupport -******************************************************************************/ +*/ int * Cudd_SupportIndex( - DdManager * dd /* manager */, - DdNode * f /* DD whose support is sought */) + DdManager * dd /**< manager */, + DdNode * f /**< %DD whose support is sought */) { int *support; int i; @@ -868,21 +997,20 @@ Cudd_SupportIndex( } /* end of Cudd_SupportIndex */ -/**Function******************************************************************** - - Synopsis [Counts the variables on which a DD depends.] +/** + @brief Counts the variables on which a %DD depends. - Description [Returns the variables on which a DD depends.] + @return the variables on which a %DD depends. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Support Cudd_SupportIndices] + @see Cudd_Support Cudd_SupportIndices -******************************************************************************/ +*/ int Cudd_SupportSize( - DdManager * dd /* manager */, - DdNode * f /* DD whose support size is sought */) + DdManager * dd /**< manager */, + DdNode * f /**< %DD whose support size is sought */) { int SP = 0; @@ -895,26 +1023,26 @@ Cudd_SupportSize( } /* end of Cudd_SupportSize */ -/**Function******************************************************************** +/** + @brief Finds the variables on which a set of DDs depends. - Synopsis [Finds the variables on which a set of DDs depends.] + @details The set must contain either BDDs and ADDs, or ZDDs. - Description [Finds the variables on which a set of DDs depends. The - set must contain either BDDs and ADDs, or ZDDs. Returns the number - of variables if successful; CUDD_OUT_OF_MEM otherwise.] + @return the number of variables if successful; CUDD_OUT_OF_MEM + otherwise. - SideEffects [The indices of the support variables are returned as - side effects. If the function is constant, no array is allocated.] + @sideeffect The indices of the support variables are returned as + side effects. If the function is constant, no array is allocated. - SeeAlso [Cudd_Support Cudd_SupportIndex Cudd_VectorSupportIndices] + @see Cudd_Support Cudd_SupportIndex Cudd_VectorSupportIndices -******************************************************************************/ +*/ int Cudd_VectorSupportIndices( - DdManager * dd /* manager */, - DdNode ** F /* DD whose support is sought */, - int n /* size of the array */, - int **indices /* array containing (on return) the indices */) + DdManager * dd /**< manager */, + DdNode ** F /**< %DD whose support is sought */, + int n /**< size of the array */, + int **indices /**< array containing (on return) the indices */) { int i; int SP = 0; @@ -929,7 +1057,6 @@ Cudd_VectorSupportIndices( ddClearVars(dd, SP); if (SP > 0) { - int i; *indices = ALLOC(int, SP); if (*indices == NULL) { dd->errorCode = CUDD_MEMORY_OUT; @@ -939,7 +1066,7 @@ Cudd_VectorSupportIndices( for (i = 0; i < SP; i++) (*indices)[i] = (int) (ptrint) dd->stack[i]; - cudd__qsort(*indices, SP, sizeof(int), indexCompare); + util_qsort(*indices, SP, sizeof(int), indexCompare); } else { *indices = NULL; } @@ -949,25 +1076,24 @@ Cudd_VectorSupportIndices( } /* end of Cudd_VectorSupportIndices */ -/**Function******************************************************************** +/** + @brief Finds the variables on which a set of DDs depends. - Synopsis [Finds the variables on which a set of DDs depends.] + @details The set must contain either BDDs and ADDs, or ZDDs. - Description [Finds the variables on which a set of DDs depends. - The set must contain either BDDs and ADDs, or ZDDs. - Returns a BDD consisting of the product of the variables if - successful; NULL otherwise.] + @return a %BDD consisting of the product of the variables if + successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Support Cudd_ClassifySupport] + @see Cudd_Support Cudd_ClassifySupport -******************************************************************************/ +*/ DdNode * Cudd_VectorSupport( - DdManager * dd /* manager */, - DdNode ** F /* array of DDs whose support is sought */, - int n /* size of the array */) + DdManager * dd /**< manager */, + DdNode ** F /**< array of DDs whose support is sought */, + int n /**< size of the array */) { int *support; DdNode *res; @@ -1001,24 +1127,24 @@ Cudd_VectorSupport( } /* end of Cudd_VectorSupport */ -/**Function******************************************************************** +/** + @brief Finds the variables on which a set of DDs depends. - Synopsis [Finds the variables on which a set of DDs depends.] + @details The set must contain either BDDs and ADDs, or ZDDs. - Description [Finds the variables on which a set of DDs depends. - The set must contain either BDDs and ADDs, or ZDDs. - Returns an index array of the variables if successful; NULL otherwise.] + @return an index array of the variables if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_SupportIndex Cudd_VectorSupport Cudd_VectorSupportIndices] + @see Cudd_SupportIndex Cudd_VectorSupport Cudd_VectorSupportIndices -******************************************************************************/ +*/ int * Cudd_VectorSupportIndex( - DdManager * dd /* manager */, - DdNode ** F /* array of DDs whose support is sought */, - int n /* size of the array */) + DdManager * dd /**< manager */, + DdNode ** F /**< array of DDs whose support is sought */, + int n /**< size of the array */) { int *support; int i; @@ -1048,23 +1174,23 @@ Cudd_VectorSupportIndex( } /* end of Cudd_VectorSupportIndex */ -/**Function******************************************************************** +/** + @brief Counts the variables on which a set of DDs depends. - Synopsis [Counts the variables on which a set of DDs depends.] + @details The set must contain either BDDs and ADDs, or ZDDs. - Description [Returns the variables on which a set of DDs depends. - The set must contain either BDDs and ADDs, or ZDDs.] + @return the number of variables on which a set of DDs depends. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_VectorSupport Cudd_SupportSize] + @see Cudd_VectorSupport Cudd_SupportSize -******************************************************************************/ +*/ int Cudd_VectorSupportSize( - DdManager * dd /* manager */, - DdNode ** F /* array of DDs whose support is sought */, - int n /* size of the array */) + DdManager * dd /**< manager */, + DdNode ** F /**< array of DDs whose support is sought */, + int n /**< size of the array */) { int i; int SP = 0; @@ -1083,29 +1209,29 @@ Cudd_VectorSupportSize( } /* end of Cudd_VectorSupportSize */ -/**Function******************************************************************** - - Synopsis [Classifies the variables in the support of two DDs.] +/** + @brief Classifies the variables in the support of two DDs. - Description [Classifies the variables in the support of two DDs - <code>f</code> and <code>g</code>, depending on whther they appear + @details Classifies the variables in the support of two DDs + <code>f</code> and <code>g</code>, depending on whether they appear in both DDs, only in <code>f</code>, or only in <code>g</code>. - Returns 1 if successful; 0 otherwise.] - SideEffects [The cubes of the three classes of variables are - returned as side effects.] + @return 1 if successful; 0 otherwise. - SeeAlso [Cudd_Support Cudd_VectorSupport] + @sideeffect The cubes of the three classes of variables are + returned as side effects. -******************************************************************************/ + @see Cudd_Support Cudd_VectorSupport + +*/ int Cudd_ClassifySupport( - DdManager * dd /* manager */, - DdNode * f /* first DD */, - DdNode * g /* second DD */, - DdNode ** common /* cube of shared variables */, - DdNode ** onlyF /* cube of variables only in f */, - DdNode ** onlyG /* cube of variables only in g */) + DdManager * dd /**< manager */, + DdNode * f /**< first %DD */, + DdNode * g /**< second %DD */, + DdNode ** common /**< cube of shared variables */, + DdNode ** onlyF /**< cube of variables only in f */, + DdNode ** onlyG /**< cube of variables only in g */) { int *supportF, *supportG; int fi, gi; @@ -1186,19 +1312,17 @@ Cudd_ClassifySupport( } /* end of Cudd_ClassifySupport */ -/**Function******************************************************************** - - Synopsis [Counts the number of leaves in a DD.] +/** + @brief Counts the number of leaves in a %DD. - Description [Counts the number of leaves in a DD. Returns the number - of leaves in the DD rooted at node if successful; CUDD_OUT_OF_MEM - otherwise.] + @return the number of leaves in the %DD rooted at node if successful; + CUDD_OUT_OF_MEM otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_PrintDebug] + @see Cudd_PrintDebug -******************************************************************************/ +*/ int Cudd_CountLeaves( DdNode * node) @@ -1212,20 +1336,19 @@ Cudd_CountLeaves( } /* end of Cudd_CountLeaves */ -/**Function******************************************************************** +/** + @brief Picks one on-set cube randomly from the given %DD. - Synopsis [Picks one on-set cube randomly from the given DD.] + @details The cube is written into an array of characters. The array + must have at least as many entries as there are variables. - Description [Picks one on-set cube randomly from the given DD. The - cube is written into an array of characters. The array must have at - least as many entries as there are variables. Returns 1 if - successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddPickOneMinterm] + @see Cudd_bddPickOneMinterm -******************************************************************************/ +*/ int Cudd_bddPickOneCube( DdManager * ddm, @@ -1242,7 +1365,10 @@ Cudd_bddPickOneCube( /* The constant 0 function has no on-set cubes. */ one = DD_ONE(ddm); bzero = Cudd_Not(one); - if (node == bzero) return(0); + if (node == bzero) { + ddm->errorCode = CUDD_INVALID_ARG; + return(0); + } for (i = 0; i < ddm->size; i++) string[i] = 2; @@ -1263,7 +1389,7 @@ Cudd_bddPickOneCube( string[N->index] = 1; node = T; } else { - dir = (char) ((Cudd_Random() & 0x2000) >> 13); + dir = (char) ((Cudd_Random(ddm) & 0x2000) >> 13); string[N->index] = dir; node = dir ? T : E; } @@ -1273,35 +1399,33 @@ Cudd_bddPickOneCube( } /* end of Cudd_bddPickOneCube */ -/**Function******************************************************************** +/** + @brief Picks one on-set minterm randomly from the given %DD. - Synopsis [Picks one on-set minterm randomly from the given DD.] - - Description [Picks one on-set minterm randomly from the given - DD. The minterm is in terms of <code>vars</code>. The array + @details The minterm is in terms of <code>vars</code>. The array <code>vars</code> should contain at least all variables in the support of <code>f</code>; if this condition is not met the minterm - built by this procedure may not be contained in - <code>f</code>. Builds a BDD for the minterm and returns a pointer - to it if successful; NULL otherwise. There are three reasons why the - procedure may fail: + built by this procedure may not be contained in <code>f</code>. + + @return a pointer to the %BDD for the minterm if successful; NULL otherwise. + There are three reasons why the procedure may fail: <ul> <li> It may run out of memory; <li> the function <code>f</code> may be the constant 0; <li> the minterm may not be contained in <code>f</code>. - </ul>] + </ul> - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddPickOneCube] + @see Cudd_bddPickOneCube -******************************************************************************/ +*/ DdNode * Cudd_bddPickOneMinterm( - DdManager * dd /* manager */, - DdNode * f /* function from which to pick one minterm */, - DdNode ** vars /* array of variables */, - int n /* size of <code>vars</code> */) + DdManager * dd /**< manager */, + DdNode * f /**< function from which to pick one minterm */, + DdNode ** vars /**< array of variables */, + int n /**< size of <code>vars</code> */) { char *string; int i, size; @@ -1336,7 +1460,7 @@ Cudd_bddPickOneMinterm( /* Randomize choice for don't cares. */ for (i = 0; i < n; i++) { if (string[indices[i]] == 2) - string[indices[i]] = (char) ((Cudd_Random() & 0x20) >> 5); + string[indices[i]] = (char) ((Cudd_Random(dd) & 0x20) >> 5); } /* Build result BDD. */ @@ -1375,36 +1499,34 @@ Cudd_bddPickOneMinterm( } /* end of Cudd_bddPickOneMinterm */ -/**Function******************************************************************** - - Synopsis [Picks k on-set minterms evenly distributed from given DD.] +/** + @brief Picks k on-set minterms evenly distributed from given %DD. - Description [Picks k on-set minterms evenly distributed from given DD. - The minterms are in terms of <code>vars</code>. The array + @details The minterms are in terms of <code>vars</code>. The array <code>vars</code> should contain at least all variables in the support of <code>f</code>; if this condition is not met the minterms - built by this procedure may not be contained in - <code>f</code>. Builds an array of BDDs for the minterms and returns a - pointer to it if successful; NULL otherwise. There are three reasons - why the procedure may fail: + built by this procedure may not be contained in <code>f</code>. + + @return an array of BDDs for the minterms if successful; NULL otherwise. + There are three reasons why the procedure may fail: <ul> <li> It may run out of memory; <li> the function <code>f</code> may be the constant 0; <li> the minterms may not be contained in <code>f</code>. - </ul>] + </ul> - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddPickOneMinterm Cudd_bddPickOneCube] + @see Cudd_bddPickOneMinterm Cudd_bddPickOneCube -******************************************************************************/ +*/ DdNode ** Cudd_bddPickArbitraryMinterms( - DdManager * dd /* manager */, - DdNode * f /* function from which to pick k minterms */, - DdNode ** vars /* array of variables */, - int n /* size of <code>vars</code> */, - int k /* number of minterms to find */) + DdManager * dd /**< manager */, + DdNode * f /**< function from which to pick k minterms */, + DdNode ** vars /**< array of variables */, + int n /**< size of <code>vars</code> */, + int k /**< number of minterms to find */) { char **string; int i, j, l, size; @@ -1413,7 +1535,7 @@ Cudd_bddPickArbitraryMinterms( DdNode **old, *neW; double minterms; char *saveString; - int saveFlag, savePoint, isSame; + int saveFlag, savePoint = 0, isSame; minterms = Cudd_CountMinterm(dd,f,n); if ((double)k > minterms) { @@ -1512,7 +1634,7 @@ Cudd_bddPickArbitraryMinterms( for (j = 0; j < n; j++) { if (string[i][indices[j]] == '2') string[i][indices[j]] = - (char) ((Cudd_Random() & 0x20) ? '1' : '0'); + (char) ((Cudd_Random(dd) & 0x20) ? '1' : '0'); } while (isSame) { @@ -1529,7 +1651,7 @@ Cudd_bddPickArbitraryMinterms( for (j = 0; j < n; j++) { if (string[i][indices[j]] == '2') string[i][indices[j]] = - (char) ((Cudd_Random() & 0x20) ? '1' : '0'); + (char) ((Cudd_Random(dd) & 0x20) ? '1' : '0'); } } } @@ -1585,51 +1707,48 @@ Cudd_bddPickArbitraryMinterms( } /* end of Cudd_bddPickArbitraryMinterms */ -/**Function******************************************************************** - - Synopsis [Extracts a subset from a BDD.] +/** + @brief Extracts a subset from a %BDD. - Description [Extracts a subset from a BDD in the following procedure. + @details Extracts a subset from a %BDD in the following procedure. 1. Compute the weight for each mask variable by counting the number of - minterms for both positive and negative cofactors of the BDD with - respect to each mask variable. (weight = #positive - #negative) - 2. Find a representative cube of the BDD by using the weight. From the - top variable of the BDD, for each variable, if the weight is greater + minterms for both positive and negative cofactors of the %BDD with + respect to each mask variable. (weight = # positive - # negative) + 2. Find a representative cube of the %BDD by using the weight. From the + top variable of the %BDD, for each variable, if the weight is greater than 0.0, choose THEN branch, othereise ELSE branch, until meeting the constant 1. 3. Quantify out the variables not in maskVars from the representative cube and if a variable in maskVars is don't care, replace the variable with a constant(1 or 0) depending on the weight. - 4. Make a subset of the BDD by multiplying with the modified cube.] - - SideEffects [None] + 4. Make a subset of the %BDD by multiplying with the modified cube. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * Cudd_SubsetWithMaskVars( - DdManager * dd /* manager */, - DdNode * f /* function from which to pick a cube */, - DdNode ** vars /* array of variables */, - int nvars /* size of <code>vars</code> */, - DdNode ** maskVars /* array of variables */, - int mvars /* size of <code>maskVars</code> */) + DdManager * dd /**< manager */, + DdNode * f /**< function from which to pick a cube */, + DdNode ** vars /**< array of variables */, + int nvars /**< size of <code>vars</code> */, + DdNode ** maskVars /**< array of variables */, + int mvars /**< size of <code>maskVars</code> */) { double *weight; char *string; int i, size; int *indices, *mask; int result; - DdNode *zero, *cube, *newCube, *subset; + DdNode *cube, *newCube, *subset; DdNode *cof; - DdNode *support; + DdNode *zero; + support = Cudd_Support(dd,f); cuddRef(support); Cudd_RecursiveDeref(dd,support); - zero = Cudd_Not(dd->one); size = dd->size; weight = ALLOC(double,size); @@ -1777,14 +1896,11 @@ Cudd_SubsetWithMaskVars( } /* end of Cudd_SubsetWithMaskVars */ -/**Function******************************************************************** - - Synopsis [Finds the first cube of a decision diagram.] +/** + @brief Finds the first cube of a decision diagram. - Description [Defines an iterator on the onset of a decision diagram - and finds its first cube. Returns a generator that contains the - information necessary to continue the enumeration if successful; NULL - otherwise.<p> + @details Defines an iterator on the onset of a decision diagram + and finds its first cube.<p> A cube is represented as an array of literals, which are integers in {0, 1, 2}; 0 represents a complemented literal, 1 represents an uncomplemented literal, and 2 stands for don't care. The enumeration @@ -1792,17 +1908,20 @@ Cudd_SubsetWithMaskVars( The size of the array equals the number of variables in the manager at the time Cudd_FirstCube is called.<p> For each cube, a value is also returned. This value is always 1 for a - BDD, while it may be different from 1 for an ADD. + %BDD, while it may be different from 1 for an %ADD. For BDDs, the offset is the set of cubes whose value is the logical zero. For ADDs, the offset is the set of cubes whose value is the - background value. The cubes of the offset are not enumerated.] + background value. The cubes of the offset are not enumerated. + + @return a generator that contains the information necessary to + continue the enumeration if successful; NULL otherwise. - SideEffects [The first cube and its value are returned as side effects.] + @sideeffect The first cube and its value are returned as side effects. - SeeAlso [Cudd_ForeachCube Cudd_NextCube Cudd_GenFree Cudd_IsGenEmpty - Cudd_FirstNode] + @see Cudd_ForeachCube Cudd_NextCube Cudd_GenFree Cudd_IsGenEmpty + Cudd_FirstNode -******************************************************************************/ +*/ DdGen * Cudd_FirstCube( DdManager * dd, @@ -1890,7 +2009,6 @@ Cudd_FirstCube( gen->gen.cubes.cube[preg->index] = 2; gen->stack.sp--; top = gen->stack.stack[gen->stack.sp-1]; - treg = Cudd_Regular(top); } } else { gen->status = CUDD_GEN_NONEMPTY; @@ -1907,21 +2025,18 @@ done: } /* end of Cudd_FirstCube */ -/**Function******************************************************************** - - Synopsis [Generates the next cube of a decision diagram onset.] +/** + @brief Generates the next cube of a decision diagram onset. - Description [Generates the next cube of a decision diagram onset, - using generator gen. Returns 0 if the enumeration is completed; 1 - otherwise.] + @return 0 if the enumeration is completed; 1 otherwise. - SideEffects [The cube and its value are returned as side effects. The - generator is modified.] + @sideeffect The cube and its value are returned as side effects. The + generator is modified. - SeeAlso [Cudd_ForeachCube Cudd_FirstCube Cudd_GenFree Cudd_IsGenEmpty - Cudd_NextNode] + @see Cudd_ForeachCube Cudd_FirstCube Cudd_GenFree Cudd_IsGenEmpty + Cudd_NextNode -******************************************************************************/ +*/ int Cudd_NextCube( DdGen * gen, @@ -1940,7 +2055,6 @@ Cudd_NextCube( goto done; } top = gen->stack.stack[gen->stack.sp-1]; - treg = Cudd_Regular(top); prev = gen->stack.stack[gen->stack.sp-2]; preg = Cudd_Regular(prev); nreg = cuddT(preg); @@ -1986,7 +2100,6 @@ Cudd_NextCube( gen->gen.cubes.cube[preg->index] = 2; gen->stack.sp--; top = gen->stack.stack[gen->stack.sp-1]; - treg = Cudd_Regular(top); } } else { gen->status = CUDD_GEN_NONEMPTY; @@ -2004,35 +2117,37 @@ done: } /* end of Cudd_NextCube */ -/**Function******************************************************************** - - Synopsis [Finds the first prime of a Boolean function.] +/** + @brief Finds the first prime of a Boolean function. - Description [Defines an iterator on a pair of BDDs describing a + @details@parblock + Defines an iterator on a pair of BDDs describing a (possibly incompletely specified) Boolean functions and finds the - first cube of a cover of the function. Returns a generator - that contains the information necessary to continue the enumeration - if successful; NULL otherwise.<p> + first cube of a cover of the function. The two argument BDDs are the lower and upper bounds of an interval. It is a mistake to call this function with a lower bound that is not - less than or equal to the upper bound.<p> + less than or equal to the upper bound. A cube is represented as an array of literals, which are integers in {0, 1, 2}; 0 represents a complemented literal, 1 represents an uncomplemented literal, and 2 stands for don't care. The enumeration produces a prime and irredundant cover of the function associated with the two BDDs. The size of the array equals the number of - variables in the manager at the time Cudd_FirstCube is called.<p> + variables in the manager at the time Cudd_FirstCube is called. - This iterator can only be used on BDDs.] + This iterator can only be used on BDDs. + @endparblock - SideEffects [The first cube is returned as side effect.] + @return a generator that contains the information necessary to + continue the enumeration if successful; NULL otherwise. - SeeAlso [Cudd_ForeachPrime Cudd_NextPrime Cudd_GenFree Cudd_IsGenEmpty - Cudd_FirstCube Cudd_FirstNode] + @sideeffect The first cube is returned as side effect. -******************************************************************************/ + @see Cudd_ForeachPrime Cudd_NextPrime Cudd_GenFree Cudd_IsGenEmpty + Cudd_FirstCube Cudd_FirstNode + +*/ DdGen * Cudd_FirstPrime( DdManager *dd, @@ -2120,21 +2235,18 @@ Cudd_FirstPrime( } /* end of Cudd_FirstPrime */ -/**Function******************************************************************** - - Synopsis [Generates the next prime of a Boolean function.] +/** + @brief Generates the next prime of a Boolean function. - Description [Generates the next cube of a Boolean function, - using generator gen. Returns 0 if the enumeration is completed; 1 - otherwise.] + @return 0 if the enumeration is completed; 1 otherwise. - SideEffects [The cube and is returned as side effects. The - generator is modified.] + @sideeffect The cube and is returned as side effects. The + generator is modified. - SeeAlso [Cudd_ForeachPrime Cudd_FirstPrime Cudd_GenFree Cudd_IsGenEmpty - Cudd_NextCube Cudd_NextNode] + @see Cudd_ForeachPrime Cudd_FirstPrime Cudd_GenFree Cudd_IsGenEmpty + Cudd_NextCube Cudd_NextNode -******************************************************************************/ +*/ int Cudd_NextPrime( DdGen *gen, @@ -2186,21 +2298,21 @@ Cudd_NextPrime( } /* end of Cudd_NextPrime */ -/**Function******************************************************************** +/** + @brief Computes the cube of an array of %BDD variables. - Synopsis [Computes the cube of an array of BDD variables.] + @details If non-null, the phase argument indicates which literal of + each variable should appear in the cube. If phase\[i\] is nonzero, + then the positive literal is used. If phase is NULL, the cube is + positive unate. - Description [Computes the cube of an array of BDD variables. If - non-null, the phase argument indicates which literal of each - variable should appear in the cube. If phase\[i\] is nonzero, then the - positive literal is used. If phase is NULL, the cube is positive unate. - Returns a pointer to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_addComputeCube Cudd_IndicesToCube Cudd_CubeArrayToBdd] + @see Cudd_addComputeCube Cudd_IndicesToCube Cudd_CubeArrayToBdd -******************************************************************************/ +*/ DdNode * Cudd_bddComputeCube( DdManager * dd, @@ -2236,21 +2348,21 @@ Cudd_bddComputeCube( } /* end of Cudd_bddComputeCube */ -/**Function******************************************************************** +/** + @brief Computes the cube of an array of %ADD variables. - Synopsis [Computes the cube of an array of ADD variables.] + @details If non-null, the phase argument indicates which literal of + each variable should appear in the cube. If phase\[i\] is nonzero, + then the positive literal is used. If phase is NULL, the cube is + positive unate. - Description [Computes the cube of an array of ADD variables. If - non-null, the phase argument indicates which literal of each - variable should appear in the cube. If phase\[i\] is nonzero, then the - positive literal is used. If phase is NULL, the cube is positive unate. - Returns a pointer to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [none] + @sideeffect none - SeeAlso [Cudd_bddComputeCube] + @see Cudd_bddComputeCube -******************************************************************************/ +*/ DdNode * Cudd_addComputeCube( DdManager * dd, @@ -2258,19 +2370,19 @@ Cudd_addComputeCube( int * phase, int n) { - DdNode *cube, *zero; + DdNode *cube, *azero; DdNode *fn; int i; cube = DD_ONE(dd); cuddRef(cube); - zero = DD_ZERO(dd); + azero = DD_ZERO(dd); for (i = n - 1; i >= 0; i--) { if (phase == NULL || phase[i] != 0) { - fn = Cudd_addIte(dd,vars[i],cube,zero); + fn = Cudd_addIte(dd,vars[i],cube,azero); } else { - fn = Cudd_addIte(dd,vars[i],zero,cube); + fn = Cudd_addIte(dd,vars[i],azero,cube); } if (fn == NULL) { Cudd_RecursiveDeref(dd,cube); @@ -2287,22 +2399,23 @@ Cudd_addComputeCube( } /* end of Cudd_addComputeCube */ -/**Function******************************************************************** +/** + @brief Builds the %BDD of a cube from a positional array. - Synopsis [Builds the BDD of a cube from a positional array.] + @details The array must have one integer entry for each %BDD + variable. If the i-th entry is 1, the variable of index i appears + in true form in the cube; If the i-th entry is 0, the variable of + index i appears complemented in the cube; otherwise the variable + does not appear in the cube. - Description [Builds a cube from a positional array. The array must - have one integer entry for each BDD variable. If the i-th entry is - 1, the variable of index i appears in true form in the cube; If the - i-th entry is 0, the variable of index i appears complemented in the - cube; otherwise the variable does not appear in the cube. Returns a - pointer to the BDD for the cube if successful; NULL otherwise.] + @return a pointer to the %BDD for the cube if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddComputeCube Cudd_IndicesToCube Cudd_BddToCubeArray] + @see Cudd_bddComputeCube Cudd_IndicesToCube Cudd_BddToCubeArray -******************************************************************************/ +*/ DdNode * Cudd_CubeArrayToBdd( DdManager *dd, @@ -2333,24 +2446,23 @@ Cudd_CubeArrayToBdd( } /* end of Cudd_CubeArrayToBdd */ -/**Function******************************************************************** +/** + @brief Builds a positional array from the %BDD of a cube. - Synopsis [Builds a positional array from the BDD of a cube.] + @details Array must have one entry for each %BDD variable. The + positional array has 1 in i-th position if the variable of index i + appears in true form in the cube; it has 0 in i-th position if the + variable of index i appears in complemented form in the cube; + finally, it has 2 in i-th position if the variable of index i does + not appear in the cube. - Description [Builds a positional array from the BDD of a cube. - Array must have one entry for each BDD variable. The positional - array has 1 in i-th position if the variable of index i appears in - true form in the cube; it has 0 in i-th position if the variable of - index i appears in complemented form in the cube; finally, it has 2 - in i-th position if the variable of index i does not appear in the - cube. Returns 1 if successful (the BDD is indeed a cube); 0 - otherwise.] + @return 1 if successful (the %BDD is indeed a cube); 0 otherwise. - SideEffects [The result is in the array passed by reference.] + @sideeffect The result is in the array passed by reference. - SeeAlso [Cudd_CubeArrayToBdd] + @see Cudd_CubeArrayToBdd -******************************************************************************/ +*/ int Cudd_BddToCubeArray( DdManager *dd, @@ -2360,26 +2472,26 @@ Cudd_BddToCubeArray( DdNode *scan, *t, *e; int i; int size = Cudd_ReadSize(dd); - DdNode *zero = Cudd_Not(DD_ONE(dd)); + DdNode *lzero = Cudd_Not(DD_ONE(dd)); for (i = size-1; i >= 0; i--) { array[i] = 2; } scan = cube; - while (!Cudd_IsConstant(scan)) { - int index = Cudd_Regular(scan)->index; + while (!Cudd_IsConstantInt(scan)) { + unsigned int index = Cudd_Regular(scan)->index; cuddGetBranches(scan,&t,&e); - if (t == zero) { + if (t == lzero) { array[index] = 0; scan = e; - } else if (e == zero) { + } else if (e == lzero) { array[index] = 1; scan = t; } else { return(0); /* cube is not a cube */ } } - if (scan == zero) { + if (scan == lzero) { return(0); } else { return(1); @@ -2388,23 +2500,23 @@ Cudd_BddToCubeArray( } /* end of Cudd_BddToCubeArray */ -/**Function******************************************************************** +/** + @brief Finds the first node of a decision diagram. - Synopsis [Finds the first node of a decision diagram.] + @details Defines an iterator on the nodes of a decision diagram and + finds its first node. The nodes are enumerated in a reverse + topological order, so that a node is always preceded in the + enumeration by its descendants. - Description [Defines an iterator on the nodes of a decision diagram - and finds its first node. Returns a generator that contains the - information necessary to continue the enumeration if successful; - NULL otherwise. The nodes are enumerated in a reverse topological - order, so that a node is always preceded in the enumeration by its - descendants.] + @return a generator that contains the information necessary to + continue the enumeration if successful; NULL otherwise. - SideEffects [The first node is returned as a side effect.] + @sideeffect The first node is returned as a side effect. - SeeAlso [Cudd_ForeachNode Cudd_NextNode Cudd_GenFree Cudd_IsGenEmpty - Cudd_FirstCube] + @see Cudd_ForeachNode Cudd_NextNode Cudd_GenFree Cudd_IsGenEmpty + Cudd_FirstCube -******************************************************************************/ +*/ DdGen * Cudd_FirstNode( DdManager * dd, @@ -2451,19 +2563,17 @@ Cudd_FirstNode( } /* end of Cudd_FirstNode */ -/**Function******************************************************************** +/** + @brief Finds the next node of a decision diagram. - Synopsis [Finds the next node of a decision diagram.] + @return 0 if the enumeration is completed; 1 otherwise. - Description [Finds the node of a decision diagram, using generator - gen. Returns 0 if the enumeration is completed; 1 otherwise.] + @sideeffect The next node is returned as a side effect. - SideEffects [The next node is returned as a side effect.] + @see Cudd_ForeachNode Cudd_FirstNode Cudd_GenFree Cudd_IsGenEmpty + Cudd_NextCube - SeeAlso [Cudd_ForeachNode Cudd_FirstNode Cudd_GenFree Cudd_IsGenEmpty - Cudd_NextCube] - -******************************************************************************/ +*/ int Cudd_NextNode( DdGen * gen, @@ -2483,19 +2593,17 @@ Cudd_NextNode( } /* end of Cudd_NextNode */ -/**Function******************************************************************** - - Synopsis [Frees a CUDD generator.] +/** + @brief Frees a CUDD generator. - Description [Frees a CUDD generator. Always returns 0, so that it can - be used in mis-like foreach constructs.] + @return always 0. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_ForeachCube Cudd_ForeachNode Cudd_FirstCube Cudd_NextCube - Cudd_FirstNode Cudd_NextNode Cudd_IsGenEmpty] + @see Cudd_ForeachCube Cudd_ForeachNode Cudd_FirstCube Cudd_NextCube + Cudd_FirstNode Cudd_NextNode Cudd_IsGenEmpty -******************************************************************************/ +*/ int Cudd_GenFree( DdGen * gen) @@ -2523,19 +2631,17 @@ Cudd_GenFree( } /* end of Cudd_GenFree */ -/**Function******************************************************************** - - Synopsis [Queries the status of a generator.] +/** + @brief Queries the status of a generator. - Description [Queries the status of a generator. Returns 1 if the - generator is empty or NULL; 0 otherswise.] + @return 1 if the generator is empty or NULL; 0 otherswise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_ForeachCube Cudd_ForeachNode Cudd_FirstCube Cudd_NextCube - Cudd_FirstNode Cudd_NextNode Cudd_GenFree] + @see Cudd_ForeachCube Cudd_ForeachNode Cudd_FirstCube Cudd_NextCube + Cudd_FirstNode Cudd_NextNode Cudd_GenFree -******************************************************************************/ +*/ int Cudd_IsGenEmpty( DdGen * gen) @@ -2546,18 +2652,16 @@ Cudd_IsGenEmpty( } /* end of Cudd_IsGenEmpty */ -/**Function******************************************************************** - - Synopsis [Builds a cube of BDD variables from an array of indices.] +/** + @brief Builds a cube of %BDD variables from an array of indices. - Description [Builds a cube of BDD variables from an array of indices. - Returns a pointer to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_bddComputeCube Cudd_CubeArrayToBdd] + @see Cudd_bddComputeCube Cudd_CubeArrayToBdd -******************************************************************************/ +*/ DdNode * Cudd_IndicesToCube( DdManager * dd, @@ -2586,17 +2690,12 @@ Cudd_IndicesToCube( } /* end of Cudd_IndicesToCube */ -/**Function******************************************************************** +/** + @brief Prints the package version number. - Synopsis [Prints the package version number.] + @sideeffect None - Description [] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ void Cudd_PrintVersion( FILE * fp) @@ -2606,19 +2705,15 @@ Cudd_PrintVersion( } /* end of Cudd_PrintVersion */ -/**Function******************************************************************** - - Synopsis [Computes the average distance between adjacent nodes.] +/** + @brief Computes the average distance between adjacent nodes in the manager. - Description [Computes the average distance between adjacent nodes in - the manager. Adjacent nodes are node pairs such that the second node - is the then child, else child, or next node in the collision list.] + @details Adjacent nodes are node pairs such that the second node + is the then child, else child, or next node in the collision list. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ double Cudd_AverageDistance( DdManager * dd) @@ -2628,7 +2723,7 @@ Cudd_AverageDistance( double temeasured, nextmeasured; int i, j; int slots, nvars; - long diff; + ptrdiff_t diff; DdNode *scan; DdNodePtr *nodelist; DdNode *sentinel = &(dd->sentinel); @@ -2651,13 +2746,13 @@ Cudd_AverageDistance( for (j = 0; j < slots; j++) { scan = nodelist[j]; while (scan != sentinel) { - diff = (long) scan - (long) cuddT(scan); + diff = (ptrint) scan - (ptrint) cuddT(scan); tesubtotal += (double) ddAbs(diff); - diff = (long) scan - (long) Cudd_Regular(cuddE(scan)); + diff = (ptrint) scan - (ptrint) Cudd_Regular(cuddE(scan)); tesubtotal += (double) ddAbs(diff); temeasured += 2.0; if (scan->next != sentinel) { - diff = (long) scan - (long) scan->next; + diff = (ptrint) scan - (ptrint) scan->next; nextsubtotal += (double) ddAbs(diff); nextmeasured += 1.0; } @@ -2676,7 +2771,7 @@ Cudd_AverageDistance( scan = nodelist[j]; while (scan != NULL) { if (scan->next != NULL) { - diff = (long) scan - (long) scan->next; + diff = (ptrint) scan - (ptrint) scan->next; nextsubtotal += (double) ddAbs(diff); nextmeasured += 1.0; } @@ -2690,128 +2785,127 @@ Cudd_AverageDistance( } /* end of Cudd_AverageDistance */ -/**Function******************************************************************** +/** + @brief Portable random number generator. - Synopsis [Portable random number generator.] + @details Based on ran2 from "Numerical Recipes in C." It is a long + period (> 2 * 10^18) random number generator of L'Ecuyer with + Bays-Durham shuffle. The random generator can be explicitly + initialized by calling Cudd_Srandom. If no explicit initialization + is performed, then the seed 1 is assumed. - Description [Portable number generator based on ran2 from "Numerical - Recipes in C." It is a long period (> 2 * 10^18) random number generator - of L'Ecuyer with Bays-Durham shuffle. Returns a long integer uniformly - distributed between 0 and 2147483561 (inclusive of the endpoint values). - The random generator can be explicitly initialized by calling - Cudd_Srandom. If no explicit initialization is performed, then the - seed 1 is assumed.] + @return a long integer uniformly distributed between 0 and + 2147483561 (inclusive of the endpoint values). - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_Srandom] + @see Cudd_Srandom -******************************************************************************/ -long -Cudd_Random(void) +*/ +int32_t +Cudd_Random(DdManager *dd) { int i; /* index in the shuffle table */ - long int w; /* work variable */ + int32_t w; /* work variable */ - /* cuddRand == 0 if the geneartor has not been initialized yet. */ - if (cuddRand == 0) Cudd_Srandom(1); + /* dd->cuddRand == 0 if the geneartor has not been initialized yet. */ + if (dd->cuddRand == 0) Cudd_Srandom(dd,1); /* Compute cuddRand = (cuddRand * LEQA1) % MODULUS1 avoiding ** overflows by Schrage's method. */ - w = cuddRand / LEQQ1; - cuddRand = LEQA1 * (cuddRand - w * LEQQ1) - w * LEQR1; - cuddRand += (cuddRand < 0) * MODULUS1; + w = dd->cuddRand / LEQQ1; + dd->cuddRand = LEQA1 * (dd->cuddRand - w * LEQQ1) - w * LEQR1; + dd->cuddRand += (dd->cuddRand < 0) * MODULUS1; - /* Compute cuddRand2 = (cuddRand2 * LEQA2) % MODULUS2 avoiding + /* Compute dd->cuddRand2 = (dd->cuddRand2 * LEQA2) % MODULUS2 avoiding ** overflows by Schrage's method. */ - w = cuddRand2 / LEQQ2; - cuddRand2 = LEQA2 * (cuddRand2 - w * LEQQ2) - w * LEQR2; - cuddRand2 += (cuddRand2 < 0) * MODULUS2; + w = dd->cuddRand2 / LEQQ2; + dd->cuddRand2 = LEQA2 * (dd->cuddRand2 - w * LEQQ2) - w * LEQR2; + dd->cuddRand2 += (dd->cuddRand2 < 0) * MODULUS2; - /* cuddRand is shuffled with the Bays-Durham algorithm. - ** shuffleSelect and cuddRand2 are combined to generate the output. + /* dd->cuddRand is shuffled with the Bays-Durham algorithm. + ** dd->shuffleSelect and cuddRand2 are combined to generate the output. */ /* Pick one element from the shuffle table; "i" will be in the range ** from 0 to STAB_SIZE-1. */ - i = (int) (shuffleSelect / STAB_DIV); + i = (int) (dd->shuffleSelect / STAB_DIV); /* Mix the element of the shuffle table with the current iterate of ** the second sub-generator, and replace the chosen element of the ** shuffle table with the current iterate of the first sub-generator. */ - shuffleSelect = shuffleTable[i] - cuddRand2; - shuffleTable[i] = cuddRand; - shuffleSelect += (shuffleSelect < 1) * (MODULUS1 - 1); - /* Since shuffleSelect != 0, and we want to be able to return 0, + dd->shuffleSelect = dd->shuffleTable[i] - dd->cuddRand2; + dd->shuffleTable[i] = dd->cuddRand; + dd->shuffleSelect += (dd->shuffleSelect < 1) * (MODULUS1 - 1); + /* Since dd->shuffleSelect != 0, and we want to be able to return 0, ** here we subtract 1 before returning. */ - return(shuffleSelect - 1); + return(dd->shuffleSelect - 1); } /* end of Cudd_Random */ -/**Function******************************************************************** +/** + @brief Initializer for the portable random number generator. - Synopsis [Initializer for the portable random number generator.] + @details Based on ran2 in "Numerical Recipes in C." The input is the + seed for the generator. If it is negative, its absolute value is + taken as seed. If it is 0, then 1 is taken as seed. The initialized + sets up the two recurrences used to generate a long-period stream, + and sets up the shuffle table. - Description [Initializer for the portable number generator based on - ran2 in "Numerical Recipes in C." The input is the seed for the - generator. If it is negative, its absolute value is taken as seed. - If it is 0, then 1 is taken as seed. The initialized sets up the two - recurrences used to generate a long-period stream, and sets up the - shuffle table.] + @sideeffect None - SideEffects [None] + @see Cudd_Random - SeeAlso [Cudd_Random] - -******************************************************************************/ +*/ void Cudd_Srandom( - long seed) + DdManager *dd, + int32_t seed) { - int i; + int32_t i; - if (seed < 0) cuddRand = -seed; - else if (seed == 0) cuddRand = 1; - else cuddRand = seed; - cuddRand2 = cuddRand; + if (seed < 0) dd->cuddRand = -seed; + else if (seed == 0) dd->cuddRand = 1; + else dd->cuddRand = seed; + dd->cuddRand2 = dd->cuddRand; /* Load the shuffle table (after 11 warm-ups). */ for (i = 0; i < STAB_SIZE + 11; i++) { - long int w; - w = cuddRand / LEQQ1; - cuddRand = LEQA1 * (cuddRand - w * LEQQ1) - w * LEQR1; - cuddRand += (cuddRand < 0) * MODULUS1; - shuffleTable[i % STAB_SIZE] = cuddRand; + int32_t w; + w = dd->cuddRand / LEQQ1; + dd->cuddRand = LEQA1 * (dd->cuddRand - w * LEQQ1) - w * LEQR1; + dd->cuddRand += (dd->cuddRand < 0) * MODULUS1; + dd->shuffleTable[i % STAB_SIZE] = dd->cuddRand; } - shuffleSelect = shuffleTable[1 % STAB_SIZE]; + dd->shuffleSelect = dd->shuffleTable[1 % STAB_SIZE]; } /* end of Cudd_Srandom */ -/**Function******************************************************************** +/** + @brief Computes the density of a %BDD or %ADD. - Synopsis [Computes the density of a BDD or ADD.] + @details The density is the ratio of the number of minterms to the + number of nodes. If 0 is passed as number of variables, the number + of variables existing in the manager is used. - Description [Computes the density of a BDD or ADD. The density is - the ratio of the number of minterms to the number of nodes. If 0 is - passed as number of variables, the number of variables existing in - the manager is used. Returns the density if successful; (double) - CUDD_OUT_OF_MEM otherwise.] + @return the density if successful; (double) CUDD_OUT_OF_MEM + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_CountMinterm Cudd_DagSize] + @see Cudd_CountMinterm Cudd_DagSize -******************************************************************************/ +*/ double Cudd_Density( - DdManager * dd /* manager */, - DdNode * f /* function whose density is sought */, - int nvars /* size of the support of f */) + DdManager * dd /**< manager */, + DdNode * f /**< function whose density is sought */, + int nvars /**< size of the support of f */) { double minterms; int nodes; @@ -2827,28 +2921,50 @@ Cudd_Density( } /* end of Cudd_Density */ -/**Function******************************************************************** +/** + @brief Warns that a memory allocation failed. - Synopsis [Warns that a memory allocation failed.] + @details This function can be used as replacement of MMout_of_memory + to prevent the safe_mem functions of the util package from exiting + when malloc returns NULL. One possible use is in case of + discretionary allocations; for instance, an allocation of memory to + enlarge the computed table. - Description [Warns that a memory allocation failed. - This function can be used as replacement of MMout_of_memory to prevent - the safe_mem functions of the util package from exiting when malloc - returns NULL. One possible use is in case of discretionary allocations; - for instance, the allocation of memory to enlarge the computed table.] + @sideeffect None - SideEffects [None] + @see Cudd_OutOfMemSilent Cudd_RegisterOutOfMemoryCallback - SeeAlso [] - -******************************************************************************/ +*/ void Cudd_OutOfMem( - long size /* size of the allocation that failed */) + size_t size /**< size of the allocation that failed */) { (void) fflush(stdout); - (void) fprintf(stderr, "\nunable to allocate %ld bytes\n", size); - return; + (void) fprintf(stderr, "\nCUDD: unable to allocate %" PRIszt " bytes\n", + size); + +} /* end of Cudd_OutOfMem */ + + +/** + @brief Doesn not warn that a memory allocation failed. + + @details This function can be used as replacement of MMout_of_memory + to prevent the safe_mem functions of the util package from exiting + when malloc returns NULL. One possible use is in case of + discretionary allocations; for instance, an allocation of memory to + enlarge the computed table. + + @sideeffect None + + @see Cudd_OutOfMem Cudd_RegisterOutOfMemoryCallback + +*/ +void +Cudd_OutOfMemSilent( + size_t size /**< size of the allocation that failed */) +{ + (void) size; /* suppress warning */ } /* end of Cudd_OutOfMem */ @@ -2858,19 +2974,17 @@ Cudd_OutOfMem( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Prints a DD to the standard output. One line per node is - printed.] +/** + @brief Prints a %DD to the standard output. One line per node is + printed. - Description [Prints a DD to the standard output. One line per node is - printed. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_PrintDebug] + @see Cudd_PrintDebug -******************************************************************************/ +*/ int cuddP( DdManager * dd, @@ -2889,47 +3003,44 @@ cuddP( } /* end of cuddP */ -/**Function******************************************************************** +/** + @brief Frees the memory used to store the minterm counts recorded + in the visited table. - Synopsis [Frees the memory used to store the minterm counts recorded - in the visited table.] + @return ST_CONTINUE. - Description [Frees the memory used to store the minterm counts - recorded in the visited table. Returns ST_CONTINUE.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ enum st_retval cuddStCountfree( - char * key, - char * value, - char * arg) + void * key, + void * value, + void * arg) { - double *d; + double *d = (double *)value; - d = (double *)value; + (void) key; /* avoid warning */ + (void) arg; /* avoid warning */ FREE(d); return(ST_CONTINUE); } /* end of cuddStCountfree */ -/**Function******************************************************************** - - Synopsis [Recursively collects all the nodes of a DD in a symbol - table.] +/** + @brief Recursively collects all the nodes of a %DD in a symbol + table. - Description [Traverses the DD f and collects all its nodes in a + @details Traverses the %DD f and collects all its nodes in a symbol table. f is assumed to be a regular pointer and cuddCollectNodes guarantees this assumption in the recursive calls. - Returns 1 in case of success; 0 otherwise.] - SideEffects [None] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int cuddCollectNodes( DdNode * f, @@ -2943,7 +3054,7 @@ cuddCollectNodes( #endif /* If already visited, nothing to do. */ - if (st_is_member(visited, (char *) f) == 1) + if (st_is_member(visited, f) == 1) return(1); /* Check for abnormal condition that should never happen. */ @@ -2951,7 +3062,7 @@ cuddCollectNodes( return(0); /* Mark node as visited. */ - if (st_add_direct(visited, (char *) f, NULL) == ST_OUT_OF_MEM) + if (st_add_direct(visited, f, NULL) == ST_OUT_OF_MEM) return(0); /* Check terminal case. */ @@ -2969,21 +3080,22 @@ cuddCollectNodes( } /* end of cuddCollectNodes */ -/**Function******************************************************************** +/** + @brief Recursively collects all the nodes of a %DD in an array. - Synopsis [Recursively collects all the nodes of a DD in an array.] + @details Traverses the %DD f and collects all its nodes in an array. + The caller should free the array returned by cuddNodeArray. The + nodes are collected in reverse topological order, so that a node is + always preceded in the array by all its descendants. - Description [Traverses the DD f and collects all its nodes in an array. - The caller should free the array returned by cuddNodeArray. - Returns a pointer to the array of nodes in case of success; NULL - otherwise. The nodes are collected in reverse topological order, so - that a node is always preceded in the array by all its descendants.] + @return a pointer to the array of nodes in case of success; NULL + otherwise. - SideEffects [The number of nodes is returned as a side effect.] + @sideeffect The number of nodes is returned as a side effect. - SeeAlso [Cudd_FirstNode] + @see Cudd_FirstNode -******************************************************************************/ +*/ DdNodePtr * cuddNodeArray( DdNode *f, @@ -3013,16 +3125,14 @@ cuddNodeArray( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of cuddP. - Synopsis [Performs the recursive step of cuddP.] + @return 1 in case of success; 0 otherwise. - Description [Performs the recursive step of cuddP. Returns 1 in case - of success; 0 otherwise.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static int dp2( DdManager *dd, @@ -3037,47 +3147,29 @@ dp2( } g = Cudd_Regular(f); if (cuddIsConstant(g)) { -#if SIZEOF_VOID_P == 8 - (void) fprintf(dd->out,"ID = %c0x%lx\tvalue = %-9g\n", bang(f), + (void) fprintf(dd->out,"ID = %c0x%" PRIxPTR "\tvalue = %-9g\n", bang(f), (ptruint) g / (ptruint) sizeof(DdNode),cuddV(g)); -#else - (void) fprintf(dd->out,"ID = %c0x%x\tvalue = %-9g\n", bang(f), - (ptruint) g / (ptruint) sizeof(DdNode),cuddV(g)); -#endif return(1); } - if (st_is_member(t,(char *) g) == 1) { + if (st_is_member(t,g) == 1) { return(1); } - if (st_add_direct(t,(char *) g,NULL) == ST_OUT_OF_MEM) + if (st_add_direct(t,g,NULL) == ST_OUT_OF_MEM) return(0); #ifdef DD_STATS -#if SIZEOF_VOID_P == 8 - (void) fprintf(dd->out,"ID = %c0x%lx\tindex = %d\tr = %d\t", bang(f), + (void) fprintf(dd->out,"ID = %c0x%"PRIxPTR"\tindex = %d\tr = %d\t", bang(f), (ptruint) g / (ptruint) sizeof(DdNode), g->index, g->ref); #else - (void) fprintf(dd->out,"ID = %c0x%x\tindex = %d\tr = %d\t", bang(f), - (ptruint) g / (ptruint) sizeof(DdNode),g->index,g->ref); -#endif -#else -#if SIZEOF_VOID_P == 8 - (void) fprintf(dd->out,"ID = %c0x%lx\tindex = %u\t", bang(f), - (ptruint) g / (ptruint) sizeof(DdNode),g->index); -#else - (void) fprintf(dd->out,"ID = %c0x%x\tindex = %hu\t", bang(f), + (void) fprintf(dd->out,"ID = %c0x%" PRIxPTR "\tindex = %u\t", bang(f), (ptruint) g / (ptruint) sizeof(DdNode),g->index); -#endif #endif n = cuddT(g); if (cuddIsConstant(n)) { (void) fprintf(dd->out,"T = %-9g\t",cuddV(n)); T = 1; } else { -#if SIZEOF_VOID_P == 8 - (void) fprintf(dd->out,"T = 0x%lx\t",(ptruint) n / (ptruint) sizeof(DdNode)); -#else - (void) fprintf(dd->out,"T = 0x%x\t",(ptruint) n / (ptruint) sizeof(DdNode)); -#endif + (void) fprintf(dd->out,"T = 0x%" PRIxPTR "\t", + (ptruint) n / (ptruint) sizeof(DdNode)); T = 0; } @@ -3087,11 +3179,8 @@ dp2( (void) fprintf(dd->out,"E = %c%-9g\n",bang(n),cuddV(N)); E = 1; } else { -#if SIZEOF_VOID_P == 8 - (void) fprintf(dd->out,"E = %c0x%lx\n", bang(n), (ptruint) N/(ptruint) sizeof(DdNode)); -#else - (void) fprintf(dd->out,"E = %c0x%x\n", bang(n), (ptruint) N/(ptruint) sizeof(DdNode)); -#endif + (void) fprintf(dd->out,"E = %c0x%" PRIxPTR "\n", + bang(n), (ptruint) N/(ptruint) sizeof(DdNode)); E = 0; } if (E == 0) { @@ -3107,23 +3196,21 @@ dp2( } /* end of dp2 */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_PrintMinterm.] +/** + @brief Performs the recursive step of Cudd_PrintMinterm. - Description [] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static void ddPrintMintermAux( - DdManager * dd /* manager */, - DdNode * node /* current node */, - int * list /* current recursion path */) + DdManager * dd /**< manager */, + DdNode * node /**< current node */, + int * list /**< current recursion path */) { - DdNode *N,*Nv,*Nnv; - int i,v,index; + DdNode *N,*Nv,*Nnv; + int i,v; + unsigned int index; N = Cudd_Regular(node); @@ -3132,7 +3219,7 @@ ddPrintMintermAux( ** path, unless we have reached the background value (ADDs) or ** the logical zero (BDDs). */ - if (node != background && node != zero) { + if (node != dd->background && node != Cudd_Not(dd->one)) { for (i = 0; i < dd->size; i++) { v = list[i]; if (v == 0) (void) fprintf(dd->out,"0"); @@ -3160,16 +3247,14 @@ ddPrintMintermAux( } /* end of ddPrintMintermAux */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_DagSize.] +/** + @brief Performs the recursive step of Cudd_DagSize. - Description [Performs the recursive step of Cudd_DagSize. Returns the - number of nodes in the graph rooted at n.] + @return the number of nodes in the graph rooted at n. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddDagInt( DdNode * n) @@ -3190,21 +3275,19 @@ ddDagInt( } /* end of ddDagInt */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of cuddNodeArray.] +/** + @brief Performs the recursive step of cuddNodeArray. - Description [Performs the recursive step of cuddNodeArray. Returns - an the number of nodes in the DD. Clear the least significant bit - of the next field that was used as visited flag by - cuddNodeArrayRecur when counting the nodes. node is supposed to be - regular; the invariant is maintained by this procedure.] + @details node is supposed to be regular; the invariant is maintained + by this procedure. - SideEffects [None] + @return an the number of nodes in the %DD. - SeeAlso [] + @sideeffect Clears the least significant bit of the next field that + was used as visited flag by cuddNodeArrayRecur when counting the + nodes. -******************************************************************************/ +*/ static int cuddNodeArrayRecur( DdNode *f, @@ -3230,21 +3313,19 @@ cuddNodeArrayRecur( } /* end of cuddNodeArrayRecur */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_CofactorEstimate.] +/** + @brief Performs the recursive step of Cudd_CofactorEstimate. - Description [Performs the recursive step of Cudd_CofactorEstimate. - Returns an estimate of the number of nodes in the DD of a - cofactor of node. Uses the least significant bit of the next field as - visited flag. node is supposed to be regular; the invariant is maintained - by this procedure.] + @details Uses the least significant bit of the next field as visited + flag. node is supposed to be regular; the invariant is maintained by + this procedure. - SideEffects [None] + @return an estimate of the number of nodes in the %DD of a cofactor + of node. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int cuddEstimateCofactor( DdManager *dd, @@ -3257,10 +3338,12 @@ cuddEstimateCofactor( int tval, eval, val; DdNode *ptrT, *ptrE; +#ifdef DD_DEBUG + assert(!Cudd_IsComplement(node)); +#endif if (Cudd_IsComplement(node->next)) { - if (!st_lookup(table,(char *)node,(char **)ptr)) { - if (st_add_direct(table,(char *)node,(char *)node) == - ST_OUT_OF_MEM) + if (!st_lookup(table, node, (void **)ptr)) { + if (st_add_direct(table, node, node) == ST_OUT_OF_MEM) return(CUDD_OUT_OF_MEM); *ptr = node; } @@ -3269,7 +3352,7 @@ cuddEstimateCofactor( node->next = Cudd_Not(node->next); if (cuddIsConstant(node)) { *ptr = node; - if (st_add_direct(table,(char *)node,(char *)node) == ST_OUT_OF_MEM) + if (st_add_direct(table, node, node) == ST_OUT_OF_MEM) return(CUDD_OUT_OF_MEM); return(1); } @@ -3282,69 +3365,73 @@ cuddEstimateCofactor( val = ddDagInt(Cudd_Regular(cuddE(node))); } if (node->ref > 1) { - if (st_add_direct(table,(char *)node,(char *)*ptr) == - ST_OUT_OF_MEM) + if (st_add_direct(table,node,*ptr) == ST_OUT_OF_MEM) return(CUDD_OUT_OF_MEM); } return(val); } if (dd->perm[node->index] > dd->perm[i]) { *ptr = node; - tval = ddDagInt(cuddT(node)); - eval = ddDagInt(Cudd_Regular(cuddE(node))); if (node->ref > 1) { - if (st_add_direct(table,(char *)node,(char *)node) == - ST_OUT_OF_MEM) + if (st_add_direct(table,node,node) == ST_OUT_OF_MEM) return(CUDD_OUT_OF_MEM); } - val = 1 + tval + eval; + val = 1 + ddDagInt(cuddT(node)) + ddDagInt(Cudd_Regular(cuddE(node))); return(val); } tval = cuddEstimateCofactor(dd,table,cuddT(node),i,phase,&ptrT); + if (tval == CUDD_OUT_OF_MEM) return(CUDD_OUT_OF_MEM); eval = cuddEstimateCofactor(dd,table,Cudd_Regular(cuddE(node)),i, phase,&ptrE); + if (eval == CUDD_OUT_OF_MEM) return(CUDD_OUT_OF_MEM); ptrE = Cudd_NotCond(ptrE,Cudd_IsComplement(cuddE(node))); if (ptrT == ptrE) { /* recombination */ *ptr = ptrT; val = tval; if (node->ref > 1) { - if (st_add_direct(table,(char *)node,(char *)*ptr) == - ST_OUT_OF_MEM) - return(CUDD_OUT_OF_MEM); - } - } else if ((ptrT != cuddT(node) || ptrE != cuddE(node)) && - (*ptr = cuddUniqueLookup(dd,node->index,ptrT,ptrE)) != NULL) { - if (Cudd_IsComplement((*ptr)->next)) { - val = 0; - } else { - val = 1 + tval + eval; - } - if (node->ref > 1) { - if (st_add_direct(table,(char *)node,(char *)*ptr) == - ST_OUT_OF_MEM) + if (st_add_direct(table,node,*ptr) == ST_OUT_OF_MEM) return(CUDD_OUT_OF_MEM); } } else { - *ptr = node; - val = 1 + tval + eval; + int complement = Cudd_IsComplement(ptrT); + if (complement) { + ptrT = Cudd_Regular(ptrT); + ptrE = Cudd_Complement(ptrE); + } + if ((ptrT != cuddT(node) || ptrE != cuddE(node)) && + (*ptr = cuddUniqueLookup(dd,node->index,ptrT,ptrE)) != NULL) { + if (Cudd_IsComplement((*ptr)->next)) { + val = 0; + } else { + val = 1 + tval + eval; + } + if (node->ref > 1) { + if (st_add_direct(table,node,*ptr) == ST_OUT_OF_MEM) + return(CUDD_OUT_OF_MEM); + } + if (complement) { + *ptr = Cudd_Complement(*ptr); + } + } else { + *ptr = node; + val = 1 + tval + eval; + } } return(val); } /* end of cuddEstimateCofactor */ -/**Function******************************************************************** - - Synopsis [Checks the unique table for the existence of an internal node.] +/** + @brief Checks the unique table for the existence of an internal node. - Description [Checks the unique table for the existence of an internal - node. Returns a pointer to the node if it is in the table; NULL otherwise.] + @return a pointer to the node if it is in the table; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddUniqueInter] + @see cuddUniqueInter -******************************************************************************/ +*/ static DdNode * cuddUniqueLookup( DdManager * unique, @@ -3352,8 +3439,8 @@ cuddUniqueLookup( DdNode * T, DdNode * E) { - int posn; - unsigned int level; + unsigned int posn; + int level; DdNodePtr *nodelist; DdNode *looking; DdSubtable *subtable; @@ -3366,8 +3453,8 @@ cuddUniqueLookup( subtable = &(unique->subtables[level]); #ifdef DD_DEBUG - assert(level < (unsigned) cuddI(unique,T->index)); - assert(level < (unsigned) cuddI(unique,Cudd_Regular(E)->index)); + assert(level < cuddI(unique,T->index)); + assert(level < cuddI(unique,Cudd_Regular(E)->index)); #endif posn = ddHash(T, E, subtable->shift); @@ -3389,21 +3476,19 @@ cuddUniqueLookup( } /* end of cuddUniqueLookup */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_CofactorEstimateSimple. - Synopsis [Performs the recursive step of Cudd_CofactorEstimateSimple.] + @details Uses the least significant bit of the next field as visited + flag. node is supposed to be regular; the invariant is maintained by + this procedure. - Description [Performs the recursive step of Cudd_CofactorEstimateSimple. - Returns an estimate of the number of nodes in the DD of the positive - cofactor of node. Uses the least significant bit of the next field as - visited flag. node is supposed to be regular; the invariant is maintained - by this procedure.] + @return an estimate of the number of nodes in the %DD of the positive + cofactor of node. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int cuddEstimateCofactorSimple( DdNode * node, @@ -3426,26 +3511,26 @@ cuddEstimateCofactorSimple( } /* end of cuddEstimateCofactorSimple */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_CountMinterm.] +/** + @brief Performs the recursive step of Cudd_CountMinterm. - Description [Performs the recursive step of Cudd_CountMinterm. - It is based on the following identity. Let |f| be the + @details It is based on the following identity. Let |f| be the number of minterms of f. Then: - <xmp> - |f| = (|f0|+|f1|)/2 - </xmp> + + |f| = (|f0|+|f1|)/2 + where f0 and f1 are the two cofactors of f. Does not use the identity |f'| = max - |f|, to minimize loss of accuracy due to - roundoff. Returns the number of minterms of the function rooted at - node.] + roundoff. - SideEffects [None] + @return the number of minterms of the function rooted at node. -******************************************************************************/ + @sideeffect None + +*/ static double ddCountMintermAux( + DdManager * dd, DdNode * node, double max, DdHashTable * table) @@ -3457,7 +3542,7 @@ ddCountMintermAux( N = Cudd_Regular(node); if (cuddIsConstant(N)) { - if (node == background || node == zero) { + if (node == dd->background || node == Cudd_Not(dd->one)) { return(0.0); } else { return(max); @@ -3477,10 +3562,10 @@ ddCountMintermAux( Nt = Cudd_Not(Nt); Ne = Cudd_Not(Ne); } - minT = ddCountMintermAux(Nt,max,table); + minT = ddCountMintermAux(dd,Nt,max,table); if (minT == (double)CUDD_OUT_OF_MEM) return((double)CUDD_OUT_OF_MEM); minT *= 0.5; - minE = ddCountMintermAux(Ne,max,table); + minE = ddCountMintermAux(dd,Ne,max,table); if (minE == (double)CUDD_OUT_OF_MEM) return((double)CUDD_OUT_OF_MEM); minE *= 0.5; min = minT + minE; @@ -3489,6 +3574,9 @@ ddCountMintermAux( ptrint fanout = (ptrint) N->ref; cuddSatDec(fanout); res = cuddUniqueConst(table->manager,min); + if (!res) { + return((double)CUDD_OUT_OF_MEM); + } if (!cuddHashTableInsert1(table,node,res,fanout)) { cuddRef(res); Cudd_RecursiveDeref(table->manager, res); return((double)CUDD_OUT_OF_MEM); @@ -3500,23 +3588,22 @@ ddCountMintermAux( } /* end of ddCountMintermAux */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_CountPath. - Synopsis [Performs the recursive step of Cudd_CountPath.] - - Description [Performs the recursive step of Cudd_CountPath. - It is based on the following identity. Let |f| be the + @details It is based on the following identity. Let |f| be the number of paths of f. Then: - <xmp> - |f| = |f0|+|f1| - </xmp> + + |f| = |f0|+|f1| + where f0 and f1 are the two cofactors of f. Uses the identity |f'| = |f|, to improve the utilization of the (local) cache. - Returns the number of paths of the function rooted at node.] - SideEffects [None] + @return the number of paths of the function rooted at node. + + @sideeffect None -******************************************************************************/ +*/ static double ddCountPathAux( DdNode * node, @@ -3525,14 +3612,14 @@ ddCountPathAux( DdNode *Nv, *Nnv; double paths, *ppaths, paths1, paths2; - double *dummy; + void *dummy; if (cuddIsConstant(node)) { return(1.0); } if (st_lookup(table, node, &dummy)) { - paths = *dummy; + paths = *(double *) dummy; return(paths); } @@ -3551,7 +3638,7 @@ ddCountPathAux( *ppaths = paths; - if (st_add_direct(table,(char *)node, (char *)ppaths) == ST_OUT_OF_MEM) { + if (st_add_direct(table, node, ppaths) == ST_OUT_OF_MEM) { FREE(ppaths); return((double)CUDD_OUT_OF_MEM); } @@ -3560,26 +3647,26 @@ ddCountPathAux( } /* end of ddCountPathAux */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_EpdCountMinterm. - Synopsis [Performs the recursive step of Cudd_EpdCountMinterm.] - - Description [Performs the recursive step of Cudd_EpdCountMinterm. - It is based on the following identity. Let |f| be the + @details It is based on the following identity. Let |f| be the number of minterms of f. Then: - <xmp> - |f| = (|f0|+|f1|)/2 - </xmp> + + |f| = (|f0|+|f1|)/2 + where f0 and f1 are the two cofactors of f. Does not use the identity |f'| = max - |f|, to minimize loss of accuracy due to - roundoff. Returns the number of minterms of the function rooted at - node.] + roundoff. + + @return the number of minterms of the function rooted at node. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddEpdCountMintermAux( + DdManager const * dd, DdNode * node, EpDouble * max, EpDouble * epd, @@ -3592,24 +3679,24 @@ ddEpdCountMintermAux( /* node is assumed to be regular */ if (cuddIsConstant(node)) { - if (node == background || node == zero) { + if (node == dd->background) { EpdMakeZero(epd, 0); } else { EpdCopy(max, epd); } return(0); } - if (node->ref != 1 && st_lookup(table, node, &res)) { + if (node->ref != 1 && st_lookup(table, node, (void **) &res)) { EpdCopy(res, epd); return(0); } Nt = cuddT(node); Ne = cuddE(node); - status = ddEpdCountMintermAux(Nt,max,&minT,table); + status = ddEpdCountMintermAux(dd,Nt,max,&minT,table); if (status == CUDD_OUT_OF_MEM) return(CUDD_OUT_OF_MEM); EpdMultiply(&minT, (double)0.5); - status = ddEpdCountMintermAux(Cudd_Regular(Ne),max,&minE,table); + status = ddEpdCountMintermAux(dd,Cudd_Regular(Ne),max,&minE,table); if (status == CUDD_OUT_OF_MEM) return(CUDD_OUT_OF_MEM); if (Cudd_IsComplement(Ne)) { EpdSubtract3(max, &minE, epd); @@ -3623,7 +3710,7 @@ ddEpdCountMintermAux( if (!min) return(CUDD_OUT_OF_MEM); EpdCopy(epd, min); - if (st_insert(table, (char *)node, (char *)min) == ST_OUT_OF_MEM) { + if (st_insert(table, node, min) == ST_OUT_OF_MEM) { EpdFree(min); return(CUDD_OUT_OF_MEM); } @@ -3634,22 +3721,88 @@ ddEpdCountMintermAux( } /* end of ddEpdCountMintermAux */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_LdblCountMinterm. + + @details It is based on the following identity. Let |f| be the + number of minterms of f. Then: + + |f| = (|f0|+|f1|)/2 + + where f0 and f1 are the two cofactors of f. Does not use the + identity |f'| = max - |f|, to minimize loss of accuracy due to + roundoff. + + @return the number of minterms of the function rooted at node. - Synopsis [Performs the recursive step of Cudd_CountPathsToNonZero.] + @sideeffect None - Description [Performs the recursive step of Cudd_CountPathsToNonZero. - It is based on the following identity. Let |f| be the +*/ +static long double +ddLdblCountMintermAux( + DdManager const *manager, + DdNode *node, + long double max, + st_table *table) +{ + DdNode *t, *e; + long double min, minT, minE; + long double *res; + if (cuddIsConstant(node)) { + if (node == manager->background) { + return 0.0L; + } else { + return max; + } + } + if (node->ref != 1 && st_lookup(table, node, (void **) &res)) { + return *res; + } + + t = cuddT(node); e = cuddE(node); + + minT = ddLdblCountMintermAux(manager, t, max, table); + if (minT == (long double) CUDD_OUT_OF_MEM) + return((long double) CUDD_OUT_OF_MEM); + minT *= 0.5L; + minE = ddLdblCountMintermAux(manager, Cudd_Regular(e), max, table); + if (minE == (long double) CUDD_OUT_OF_MEM) + return((long double) CUDD_OUT_OF_MEM); + if (Cudd_IsComplement(e)) { + minE = max - minE; + } + minE *= 0.5L; + min = minT + minE; + if (node->ref != 1) { + res = ALLOC(long double, 1); + if (res == NULL) + return((long double) CUDD_OUT_OF_MEM); + *res = min; + if (st_insert(table, node, res) == ST_OUT_OF_MEM) { + FREE(res); + return((long double) CUDD_OUT_OF_MEM); + } + } + return(min); + +} /* end of ddLdblCountMintermAux */ + + +/** + @brief Performs the recursive step of Cudd_CountPathsToNonZero. + + @details It is based on the following identity. Let |f| be the number of paths of f. Then: - <xmp> - |f| = |f0|+|f1| - </xmp> - where f0 and f1 are the two cofactors of f. Returns the number of - paths of the function rooted at node.] - SideEffects [None] + |f| = |f0|+|f1| + + where f0 and f1 are the two cofactors of f. + + @return the number of paths of the function rooted at node. + + @sideeffect None -******************************************************************************/ +*/ static double ddCountPathsToNonZero( DdNode * N, @@ -3658,14 +3811,14 @@ ddCountPathsToNonZero( DdNode *node, *Nt, *Ne; double paths, *ppaths, paths1, paths2; - double *dummy; + void *dummy; node = Cudd_Regular(N); if (cuddIsConstant(node)) { return((double) !(Cudd_IsComplement(N) || cuddV(node)==DD_ZERO_VAL)); } if (st_lookup(table, N, &dummy)) { - paths = *dummy; + paths = *(double *) dummy; return(paths); } @@ -3687,7 +3840,7 @@ ddCountPathsToNonZero( *ppaths = paths; - if (st_add_direct(table,(char *)N, (char *)ppaths) == ST_OUT_OF_MEM) { + if (st_add_direct(table, N, ppaths) == ST_OUT_OF_MEM) { FREE(ppaths); return((double)CUDD_OUT_OF_MEM); } @@ -3696,19 +3849,17 @@ ddCountPathsToNonZero( } /* end of ddCountPathsToNonZero */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_Support.] +/** + @brief Performs the recursive step of Cudd_Support. - Description [Performs the recursive step of Cudd_Support. Performs a - DFS from f. The support is accumulated in supp as a side effect. Uses - the LSB of the then pointer as visited flag.] + @details Performs a DFS from f. The support is accumulated in supp + as a side effect. Uses the LSB of the then pointer as visited flag. - SideEffects [None] + @sideeffect None - SeeAlso [ddClearFlag] + @see ddClearFlag -******************************************************************************/ +*/ static void ddSupportStep( DdNode * f, @@ -3726,18 +3877,14 @@ ddSupportStep( } /* end of ddSupportStep */ -/**Function******************************************************************** - - Synopsis [Performs a DFS from f, clearing the LSB of the next - pointers.] - - Description [] +/** + @brief Performs a DFS from f, clearing the LSB of the next pointers. - SideEffects [None] + @sideeffect None - SeeAlso [ddSupportStep ddFindSupport ddLeavesInt ddDagInt] + @see ddSupportStep ddFindSupport ddLeavesInt ddDagInt -******************************************************************************/ +*/ static void ddClearFlag( DdNode * f) @@ -3757,18 +3904,16 @@ ddClearFlag( } /* end of ddClearFlag */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_CountLeaves.] +/** + @brief Performs the recursive step of Cudd_CountLeaves. - Description [Performs the recursive step of Cudd_CountLeaves. Returns - the number of leaves in the DD rooted at n.] + @return the number of leaves in the %DD rooted at n. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_CountLeaves] + @see Cudd_CountLeaves -******************************************************************************/ +*/ static int ddLeavesInt( DdNode * n) @@ -3789,18 +3934,16 @@ ddLeavesInt( } /* end of ddLeavesInt */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_bddPickArbitraryMinterms. - Synopsis [Performs the recursive step of Cudd_bddPickArbitraryMinterms.] + @return 1 if successful; 0 otherwise. - Description [Performs the recursive step of Cudd_bddPickArbitraryMinterms. - Returns 1 if successful; 0 otherwise.] + @sideeffect none - SideEffects [none] + @see Cudd_bddPickArbitraryMinterms - SeeAlso [Cudd_bddPickArbitraryMinterms] - -******************************************************************************/ +*/ static int ddPickArbitraryMinterms( DdManager *dd, @@ -3850,18 +3993,17 @@ ddPickArbitraryMinterms( } /* end of ddPickArbitraryMinterms */ -/**Function******************************************************************** - - Synopsis [Finds a representative cube of a BDD.] +/** + @brief Finds a representative cube of a %BDD. - Description [Finds a representative cube of a BDD with the weight of + @details Finds a representative cube of a %BDD with the weight of each variable. From the top variable, if the weight is greater than or equal to 0.0, choose THEN branch unless the child is the constant 0. - Otherwise, choose ELSE branch unless the child is the constant 0.] + Otherwise, choose ELSE branch unless the child is the constant 0. - SideEffects [Cudd_SubsetWithMaskVars Cudd_bddPickOneCube] + @sideeffect Cudd_SubsetWithMaskVars Cudd_bddPickOneCube -******************************************************************************/ +*/ static int ddPickRepresentativeCube( DdManager *dd, @@ -3914,53 +4056,51 @@ ddPickRepresentativeCube( } /* end of ddPickRepresentativeCube */ -/**Function******************************************************************** - - Synopsis [Frees the memory used to store the minterm counts recorded - in the visited table.] +/** + @brief Frees the memory used to store the minterm counts recorded + in the visited table. - Description [Frees the memory used to store the minterm counts - recorded in the visited table. Returns ST_CONTINUE.] + @return ST_CONTINUE. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static enum st_retval ddEpdFree( - char * key, - char * value, - char * arg) + void * key, + void * value, + void * arg) { - EpDouble *epd; + EpDouble *epd = (EpDouble *) value; - epd = (EpDouble *) value; + (void) key; /* avoid warning */ + (void) arg; /* avoid warning */ EpdFree(epd); return(ST_CONTINUE); } /* end of ddEpdFree */ -/**Function******************************************************************** - - Synopsis [Recursively find the support of f.] +/** + @brief Recursively find the support of f. - Description [Recursively find the support of f. This function uses the - LSB of the next field of the nodes of f as visited flag. It also uses the - LSB of the next field of the variables as flag to remember whether a - certain index has already been seen. Finally, it uses the manager stack - to record all seen indices.] + @details This function uses the LSB of the next field of the nodes + of f as visited flag. It also uses the LSB of the next field of the + variables as flag to remember whether a certain index has already + been seen. Finally, it uses the manager stack to record all seen + indices. - SideEffects [The stack pointer SP is modified by side-effect. The next - fields are changed and need to be reset.] + @sideeffect The stack pointer SP is modified by side-effect. The next + fields are changed and need to be reset. -******************************************************************************/ +*/ static void ddFindSupport( DdManager *dd, DdNode *f, int *SP) { - int index; + unsigned int index; DdNode *var; if (cuddIsConstant(f) || Cudd_IsComplement(f->next)) { @@ -3975,7 +4115,7 @@ ddFindSupport( */ if (!Cudd_IsComplement(var->next)) { var->next = Cudd_Complement(var->next); - dd->stack[*SP] = (DdNode *)(ptrint) index; + dd->stack[*SP] = (DdNode *)(ptruint) index; (*SP)++; } ddFindSupport(dd, cuddT(f), SP); @@ -3986,15 +4126,12 @@ ddFindSupport( } /* end of ddFindSupport */ -/**Function******************************************************************** - - Synopsis [Clears visited flags for variables.] - - Description [Clears visited flags for variables.] +/** + @brief Clears visited flags for variables. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static void ddClearVars( DdManager *dd, @@ -4011,23 +4148,86 @@ ddClearVars( } /* end of ddClearVars */ -/**Function******************************************************************** - - Synopsis [Compares indices for qsort.] +/** + @brief Compares indices for qsort. - Description [Compares indices for qsort. Subtracting these integers - cannot produce overflow, because they are non-negative.] + @details Subtracting these integers cannot produce overflow, because + they are non-negative. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int indexCompare( const void *a, const void *b) { - int ia = *((int *) a); - int ib = *((int *) b); + int ia = *(int const *) a; + int ib = *(int const *) b; return(ia - ib); } /* end of indexCompare */ + + +/** + @brief Frees the memory used to store the minterm counts recorded in the + visited table by Cudd_LdblCountMinterm. + + @returns ST_CONTINUE. + + @sideeffect None +*/ +static enum st_retval +ddLdblFree( + void * key, + void * value, + void * arg) +{ + long double * ld = (long double *) value; + + (void) key; /* avoid warning */ + (void) arg; /* avoid warning */ + FREE(ld); + return(ST_CONTINUE); + +} /* end of ddLdblFree */ + + +#if HAVE_POWL != 1 +/** + @brief Replacement for standard library powl. + + @details Some systems' C libraries, notably Cygwin as of 2015, + lack an implementation of powl. This simple-minded replacement + works for integral powers. It is based on iterative squaring. + + @return base raised to the exponent. +*/ +static long double +powl( + long double base, + long double exponent) +{ + long exp; + long double power = 1.0L, square = base; + if (exponent < 0.0L) { + exp = (long) -exponent; + } else { + exp = (long) exponent; + } + /* Compute base^exponent by iterative squaring. + * The loop invariant is power * square^exp = base^exponent. + */ + while (exp > 0) { + if (exp & 1L) + power *= square; + square *= square; + exp >>= 1L; + } + if (exponent < 0.0L) { + power = 1.0L / power; + } + return(power); + +} /* end of powl */ +#endif diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddWindow.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddWindow.c similarity index 77% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddWindow.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddWindow.c index 2f80beb16..5adbe2caf 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddWindow.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddWindow.c @@ -1,30 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddWindow.c] + @ingroup cudd - PackageName [cudd] + @brief Functions for variable reordering by window permutation. - Synopsis [Functions for variable reordering by window permutation.] + @author Fabio Somenzi - Description [Internal procedures included in this module: - <ul> - <li> cuddWindowReorder() - </ul> - Static procedures included in this module: - <ul> - <li> ddWindow2() - <li> ddWindowConv2() - <li> ddPermuteWindow3() - <li> ddWindow3() - <li> ddWindowConv3() - <li> ddPermuteWindow4() - <li> ddWindow4() - <li> ddWindowConv4() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -54,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -65,36 +50,23 @@ /* Constant declarations */ /*---------------------------------------------------------------------------*/ - /*---------------------------------------------------------------------------*/ /* Stucture declarations */ /*---------------------------------------------------------------------------*/ - /*---------------------------------------------------------------------------*/ /* Type declarations */ /*---------------------------------------------------------------------------*/ - /*---------------------------------------------------------------------------*/ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddWindow.c,v 1.15 2012/02/05 01:07:19 fabio Exp $"; -#endif - -#ifdef DD_STATS -extern int ddTotalNumberSwapping; -extern int ddTotalNISwaps; -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -109,7 +81,7 @@ static int ddPermuteWindow4 (DdManager *table, int w); static int ddWindow4 (DdManager *table, int low, int high); static int ddWindowConv4 (DdManager *table, int low, int high); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -121,25 +93,24 @@ static int ddWindowConv4 (DdManager *table, int low, int high); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Reorders by applying the method of the sliding window. - Synopsis [Reorders by applying the method of the sliding window.] + @details Tries all possible permutations to the variables in a + window that slides from low to high. The size of the window is + determined by submethod. Assumes that no dead nodes are present. - Description [Reorders by applying the method of the sliding window. - Tries all possible permutations to the variables in a window that - slides from low to high. The size of the window is determined by - submethod. Assumes that no dead nodes are present. Returns 1 in - case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ int cuddWindowReorder( - DdManager * table /* DD table */, - int low /* lowest index to reorder */, - int high /* highest index to reorder */, - Cudd_ReorderingType submethod /* window reordering option */) + DdManager * table /**< %DD table */, + int low /**< lowest index to reorder */, + int high /**< highest index to reorder */, + Cudd_ReorderingType submethod /**< window reordering option */) { int res; @@ -163,7 +134,7 @@ cuddWindowReorder( case CUDD_REORDER_WINDOW3_CONV: res = ddWindowConv3(table,low,high); #ifdef DD_DEBUG - supposedOpt = table->keys - table->isolated; + supposedOpt = (int) (table->keys - table->isolated); res = ddWindow3(table,low,high); if (table->keys - table->isolated != (unsigned) supposedOpt) { (void) fprintf(table->err, "Convergence failed! (%d != %d)\n", @@ -174,7 +145,7 @@ cuddWindowReorder( case CUDD_REORDER_WINDOW4_CONV: res = ddWindowConv4(table,low,high); #ifdef DD_DEBUG - supposedOpt = table->keys - table->isolated; + supposedOpt = (int) (table->keys - table->isolated); res = ddWindow4(table,low,high); if (table->keys - table->isolated != (unsigned) supposedOpt) { (void) fprintf(table->err,"Convergence failed! (%d != %d)\n", @@ -194,18 +165,17 @@ cuddWindowReorder( /* Definition of static functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Reorders by applying a sliding window of width 2. - Synopsis [Reorders by applying a sliding window of width 2.] + @details Tries both permutations of the variables in a window that + slides from low to high. Assumes that no dead nodes are present. - Description [Reorders by applying a sliding window of width 2. - Tries both permutations of the variables in a window - that slides from low to high. Assumes that no dead nodes are - present. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddWindow2( DdManager * table, @@ -223,7 +193,7 @@ ddWindow2( if (high-low < 1) return(0); - res = table->keys - table->isolated; + res = (int) (table->keys - table->isolated); for (x = low; x < high; x++) { size = res; res = cuddSwapInPlace(table,x,x+1); @@ -247,19 +217,18 @@ ddWindow2( } /* end of ddWindow2 */ -/**Function******************************************************************** +/** + @brief Reorders by repeatedly applying a sliding window of width 2. - Synopsis [Reorders by repeatedly applying a sliding window of width 2.] + @details Tries both permutations of the variables in a window that + slides from low to high. Assumes that no dead nodes are present. + Uses an event-driven approach to determine convergence. - Description [Reorders by repeatedly applying a sliding window of width - 2. Tries both permutations of the variables in a window - that slides from low to high. Assumes that no dead nodes are - present. Uses an event-driven approach to determine convergence. - Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddWindowConv2( DdManager * table, @@ -289,7 +258,7 @@ ddWindowConv2( events[x] = 1; } - res = table->keys - table->isolated; + res = (int) (table->keys - table->isolated); do { newevent = 0; for (x=0; x<nwin; x++) { @@ -338,21 +307,18 @@ ddWindowConv2( } /* end of ddWindowConv3 */ -/**Function******************************************************************** +/** + @brief Tries all the permutations of the three variables between + x and x+2 and retains the best. - Synopsis [Tries all the permutations of the three variables between - x and x+2 and retains the best.] + @details Assumes that no dead nodes are present. - Description [Tries all the permutations of the three variables between - x and x+2 and retains the best. Assumes that no dead nodes are - present. Returns the index of the best permutation (1-6) in case of - success; 0 otherwise.Assumes that no dead nodes are present. Returns - the index of the best permutation (1-6) in case of success; 0 - otherwise.] + @return the index of the best permutation (1-6) in case of success; + 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddPermuteWindow3( DdManager * table, @@ -367,7 +333,7 @@ ddPermuteWindow3( assert(x+2 < table->size); #endif - size = table->keys - table->isolated; + size = (int) (table->keys - table->isolated); y = x+1; z = y+1; /* The permutation pattern is: @@ -436,18 +402,18 @@ ddPermuteWindow3( } /* end of ddPermuteWindow3 */ -/**Function******************************************************************** - - Synopsis [Reorders by applying a sliding window of width 3.] +/** + @brief Reorders by applying a sliding window of width 3. - Description [Reorders by applying a sliding window of width 3. - Tries all possible permutations to the variables in a + @details Tries all possible permutations to the variables in a window that slides from low to high. Assumes that no dead nodes are - present. Returns 1 in case of success; 0 otherwise.] + present. - SideEffects [None] + @return 1 in case of success; 0 otherwise. -******************************************************************************/ + @sideeffect None + +*/ static int ddWindow3( DdManager * table, @@ -482,19 +448,18 @@ ddWindow3( } /* end of ddWindow3 */ -/**Function******************************************************************** - - Synopsis [Reorders by repeatedly applying a sliding window of width 3.] +/** + @brief Reorders by repeatedly applying a sliding window of width 3. - Description [Reorders by repeatedly applying a sliding window of width - 3. Tries all possible permutations to the variables in a + @details Tries all possible permutations to the variables in a window that slides from low to high. Assumes that no dead nodes are present. Uses an event-driven approach to determine convergence. - Returns 1 in case of success; 0 otherwise.] - SideEffects [None] + @return 1 in case of success; 0 otherwise. -******************************************************************************/ + @sideeffect None + +*/ static int ddWindowConv3( DdManager * table, @@ -580,19 +545,18 @@ ddWindowConv3( } /* end of ddWindowConv3 */ -/**Function******************************************************************** +/** + @brief Tries all the permutations of the four variables between w + and w+3 and retains the best. - Synopsis [Tries all the permutations of the four variables between w - and w+3 and retains the best.] + @details Assumes that no dead nodes are present. - Description [Tries all the permutations of the four variables between - w and w+3 and retains the best. Assumes that no dead nodes are - present. Returns the index of the best permutation (1-24) in case of - success; 0 otherwise.] + @return the index of the best permutation (1-24) in case of success; + 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddPermuteWindow4( DdManager * table, @@ -607,7 +571,7 @@ ddPermuteWindow4( assert(w+3 < table->size); #endif - size = table->keys - table->isolated; + size = (int) (table->keys - table->isolated); x = w+1; y = x+1; z = y+1; /* The permutation pattern is: @@ -837,18 +801,18 @@ ddPermuteWindow4( } /* end of ddPermuteWindow4 */ -/**Function******************************************************************** - - Synopsis [Reorders by applying a sliding window of width 4.] +/** + @brief Reorders by applying a sliding window of width 4. - Description [Reorders by applying a sliding window of width 4. - Tries all possible permutations to the variables in a + @details Tries all possible permutations to the variables in a window that slides from low to high. Assumes that no dead nodes are - present. Returns 1 in case of success; 0 otherwise.] + present. + + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ddWindow4( DdManager * table, @@ -883,19 +847,18 @@ ddWindow4( } /* end of ddWindow4 */ -/**Function******************************************************************** +/** + @brief Reorders by repeatedly applying a sliding window of width 4. - Synopsis [Reorders by repeatedly applying a sliding window of width 4.] - - Description [Reorders by repeatedly applying a sliding window of width - 4. Tries all possible permutations to the variables in a + @details Tries all possible permutations to the variables in a window that slides from low to high. Assumes that no dead nodes are present. Uses an event-driven approach to determine convergence. - Returns 1 in case of success; 0 otherwise.] - SideEffects [None] + @return 1 in case of success; 0 otherwise. + + @sideeffect None -******************************************************************************/ +*/ static int ddWindowConv4( DdManager * table, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddCount.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddCount.c similarity index 61% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddCount.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddZddCount.c index b65d1022f..a0a08a390 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddCount.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddCount.c @@ -1,33 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddZddCount.c] + @ingroup cudd - PackageName [cudd] + @brief Procedures to count the number of minterms of a %ZDD. - Synopsis [Procedures to count the number of minterms of a ZDD.] + @author Hyong-Kyoon Shin, In-Ho Moon - Description [External procedures included in this module: - <ul> - <li> Cudd_zddCount(); - <li> Cudd_zddCountDouble(); - </ul> - Internal procedures included in this module: - <ul> - </ul> - Static procedures included in this module: - <ul> - <li> cuddZddCountStep(); - <li> cuddZddCountDoubleStep(); - <li> st_zdd_count_dbl_free() - <li> st_zdd_countfree() - </ul> - ] - - SeeAlso [] - - Author [Hyong-Kyoon Shin, In-Ho Moon] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -57,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -83,19 +65,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddZddCount.c,v 1.15 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -#ifdef __cplusplus -extern "C" { -#endif - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -103,32 +78,27 @@ extern "C" { static int cuddZddCountStep (DdNode *P, st_table *table, DdNode *base, DdNode *empty); static double cuddZddCountDoubleStep (DdNode *P, st_table *table, DdNode *base, DdNode *empty); -static enum st_retval st_zdd_countfree (char *key, char *value, char *arg); -static enum st_retval st_zdd_count_dbl_free (char *key, char *value, char *arg); - -/**AutomaticEnd***************************************************************/ +static enum st_retval st_zdd_countfree (void *key, void *value, void *arg); +static enum st_retval st_zdd_count_dbl_free (void *key, void *value, void *arg); -#ifdef __cplusplus -} -#endif +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Counts the number of minterms in a %ZDD. - Synopsis [Counts the number of minterms in a ZDD.] + @details Returns an integer representing the number of minterms + in a %ZDD. - Description [Returns an integer representing the number of minterms - in a ZDD.] + @sideeffect None - SideEffects [None] + @see Cudd_zddCountDouble - SeeAlso [Cudd_zddCountDouble] - -******************************************************************************/ +*/ int Cudd_zddCount( DdManager * zdd, @@ -146,7 +116,7 @@ Cudd_zddCount( if (res == CUDD_OUT_OF_MEM) { zdd->errorCode = CUDD_MEMORY_OUT; } - st_foreach(table, st_zdd_countfree, NIL(char)); + st_foreach(table, st_zdd_countfree, NIL(void)); st_free_table(table); return(res); @@ -154,20 +124,19 @@ Cudd_zddCount( } /* end of Cudd_zddCount */ -/**Function******************************************************************** +/** + @brief Counts the number of minterms of a %ZDD. - Synopsis [Counts the number of minterms of a ZDD.] + @details This procedure is used in Cudd_zddCountMinterm. - Description [Counts the number of minterms of a ZDD. The result is - returned as a double. If the procedure runs out of memory, it - returns (double) CUDD_OUT_OF_MEM. This procedure is used in - Cudd_zddCountMinterm.] + @result the count. If the procedure runs out of memory, it returns + (double) CUDD_OUT_OF_MEM. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddCountMinterm Cudd_zddCount] + @see Cudd_zddCountMinterm Cudd_zddCount -******************************************************************************/ +*/ double Cudd_zddCountDouble( DdManager * zdd, @@ -185,7 +154,7 @@ Cudd_zddCountDouble( if (res == (double)CUDD_OUT_OF_MEM) { zdd->errorCode = CUDD_MEMORY_OUT; } - st_foreach(table, st_zdd_count_dbl_free, NIL(char)); + st_foreach(table, st_zdd_count_dbl_free, NIL(void)); st_free_table(table); return(res); @@ -203,17 +172,12 @@ Cudd_zddCountDouble( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddCount.] - - Description [] - - SideEffects [None] +/** + @brief Performs the recursive step of Cudd_zddCount. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int cuddZddCountStep( DdNode * P, @@ -230,7 +194,7 @@ cuddZddCountStep( return(1); /* Check cache. */ - if (st_lookup(table, P, &dummy)) { + if (st_lookup(table, P, (void **) &dummy)) { res = *dummy; return(res); } @@ -243,7 +207,7 @@ cuddZddCountStep( return(CUDD_OUT_OF_MEM); } *dummy = res; - if (st_insert(table, (char *)P, (char *)dummy) == ST_OUT_OF_MEM) { + if (st_insert(table, P, dummy) == ST_OUT_OF_MEM) { FREE(dummy); return(CUDD_OUT_OF_MEM); } @@ -253,17 +217,12 @@ cuddZddCountStep( } /* end of cuddZddCountStep */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_zddCountDouble. - Synopsis [Performs the recursive step of Cudd_zddCountDouble.] + @sideeffect None - Description [] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static double cuddZddCountDoubleStep( DdNode * P, @@ -280,7 +239,7 @@ cuddZddCountDoubleStep( return((double)1.0); /* Check cache */ - if (st_lookup(table, P, &dummy)) { + if (st_lookup(table, P, (void **) &dummy)) { res = *dummy; return(res); } @@ -293,7 +252,7 @@ cuddZddCountDoubleStep( return((double)CUDD_OUT_OF_MEM); } *dummy = res; - if (st_insert(table, (char *)P, (char *)dummy) == ST_OUT_OF_MEM) { + if (st_insert(table, P, dummy) == ST_OUT_OF_MEM) { FREE(dummy); return((double)CUDD_OUT_OF_MEM); } @@ -303,54 +262,46 @@ cuddZddCountDoubleStep( } /* end of cuddZddCountDoubleStep */ -/**Function******************************************************************** - - Synopsis [Frees the memory associated with the computed table of - Cudd_zddCount.] - - Description [] +/** + @brief Frees the memory associated with the computed table of + Cudd_zddCount. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static enum st_retval st_zdd_countfree( - char * key, - char * value, - char * arg) + void * key, + void * value, + void * arg) { - int *d; + int *d = (int *) value; - d = (int *)value; + (void) key; /* avoid warning */ + (void) arg; /* avoid warning */ FREE(d); return(ST_CONTINUE); } /* end of st_zdd_countfree */ -/**Function******************************************************************** - - Synopsis [Frees the memory associated with the computed table of - Cudd_zddCountDouble.] - - Description [] - - SideEffects [None] +/** + @brief Frees the memory associated with the computed table of + Cudd_zddCountDouble. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static enum st_retval st_zdd_count_dbl_free( - char * key, - char * value, - char * arg) + void * key, + void * value, + void * arg) { - double *d; + double *d = (double *) value; - d = (double *)value; + (void) key; /* avoid warning */ + (void) arg; /* avoid warning */ FREE(d); return(ST_CONTINUE); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddFuncs.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddFuncs.c similarity index 75% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddFuncs.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddZddFuncs.c index 9d818212b..5f6d63c74 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddFuncs.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddFuncs.c @@ -1,47 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddZddFuncs.c] - - PackageName [cudd] - - Synopsis [Functions to manipulate covers represented as ZDDs.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_zddProduct(); - <li> Cudd_zddUnateProduct(); - <li> Cudd_zddWeakDiv(); - <li> Cudd_zddWeakDivF(); - <li> Cudd_zddDivide(); - <li> Cudd_zddDivideF(); - <li> Cudd_zddComplement(); - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddProduct(); - <li> cuddZddUnateProduct(); - <li> cuddZddWeakDiv(); - <li> cuddZddWeakDivF(); - <li> cuddZddDivide(); - <li> cuddZddDivideF(); - <li> cuddZddGetCofactors3() - <li> cuddZddGetCofactors2() - <li> cuddZddComplement(); - <li> cuddZddGetPosVarIndex(); - <li> cuddZddGetNegVarIndex(); - <li> cuddZddGetPosVarLevel(); - <li> cuddZddGetNegVarLevel(); - </ul> - Static procedures included in this module: - <ul> - </ul> - ] - - SeeAlso [] - - Author [In-Ho Moon] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Functions to manipulate covers represented as ZDDs. + + @author In-Ho Moon + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -71,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -97,23 +65,18 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddZddFuncs.c,v 1.17 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -121,22 +84,21 @@ static char rcsid[] DD_UNUSED = "$Id: cuddZddFuncs.c,v 1.17 2012/02/05 01:07:19 /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Computes the product of two covers represented by ZDDs. - Synopsis [Computes the product of two covers represented by ZDDs.] + @details The result is also a %ZDD. The covers on which + Cudd_zddProduct operates use two %ZDD variables for each function + variable (one %ZDD variable for each literal of the variable). Those + two %ZDD variables should be adjacent in the order. - Description [Computes the product of two covers represented by - ZDDs. The result is also a ZDD. Returns a pointer to the result if - successful; NULL otherwise. The covers on which Cudd_zddProduct - operates use two ZDD variables for each function variable (one ZDD - variable for each literal of the variable). Those two ZDD variables - should be adjacent in the order.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddUnateProduct] + @see Cudd_zddUnateProduct -******************************************************************************/ +*/ DdNode * Cudd_zddProduct( DdManager * dd, @@ -149,25 +111,27 @@ Cudd_zddProduct( dd->reordered = 0; res = cuddZddProduct(dd, f, g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddProduct */ -/**Function******************************************************************** +/** + @brief Computes the product of two unate covers represented as ZDDs. - Synopsis [Computes the product of two unate covers.] + @details Unate covers use one %ZDD variable for each %BDD + variable. - Description [Computes the product of two unate covers represented as - ZDDs. Unate covers use one ZDD variable for each BDD - variable. Returns a pointer to the result if successful; NULL - otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddProduct] + @see Cudd_zddProduct -******************************************************************************/ +*/ DdNode * Cudd_zddUnateProduct( DdManager * dd, @@ -180,28 +144,31 @@ Cudd_zddUnateProduct( dd->reordered = 0; res = cuddZddUnateProduct(dd, f, g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddUnateProduct */ -/**Function******************************************************************** +/** + @brief Applies weak division to two covers. - Synopsis [Applies weak division to two covers.] + @details Applies weak division to two ZDDs representing two covers. + The result of weak division depends on the variable order. The + covers on which Cudd_zddWeakDiv operates use two %ZDD variables for + each function variable (one %ZDD variable for each literal of the + variable). Those two %ZDD variables should be adjacent in the order. - Description [Applies weak division to two ZDDs representing two - covers. Returns a pointer to the ZDD representing the result if - successful; NULL otherwise. The result of weak division depends on - the variable order. The covers on which Cudd_zddWeakDiv operates use - two ZDD variables for each function variable (one ZDD variable for - each literal of the variable). Those two ZDD variables should be - adjacent in the order.] + @return a pointer to the %ZDD representing the result if successful; + NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddDivide] + @see Cudd_zddDivide -******************************************************************************/ +*/ DdNode * Cudd_zddWeakDiv( DdManager * dd, @@ -214,25 +181,28 @@ Cudd_zddWeakDiv( dd->reordered = 0; res = cuddZddWeakDiv(dd, f, g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddWeakDiv */ -/**Function******************************************************************** +/** + @brief Computes the quotient of two unate covers. - Synopsis [Computes the quotient of two unate covers.] + @details Computes the quotient of two unate covers represented by + ZDDs. Unate covers use one %ZDD variable for each %BDD variable. - Description [Computes the quotient of two unate covers represented - by ZDDs. Unate covers use one ZDD variable for each BDD - variable. Returns a pointer to the resulting ZDD if successful; NULL - otherwise.] + @return a pointer to the resulting %ZDD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddWeakDiv] + @see Cudd_zddWeakDiv -******************************************************************************/ +*/ DdNode * Cudd_zddDivide( DdManager * dd, @@ -245,23 +215,24 @@ Cudd_zddDivide( dd->reordered = 0; res = cuddZddDivide(dd, f, g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddDivide */ -/**Function******************************************************************** - - Synopsis [Modified version of Cudd_zddWeakDiv.] +/** + @brief Modified version of Cudd_zddWeakDiv. - Description [Modified version of Cudd_zddWeakDiv. This function may - disappear in future releases.] + @details This function may disappear in future releases. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddWeakDiv] + @see Cudd_zddWeakDiv -******************************************************************************/ +*/ DdNode * Cudd_zddWeakDivF( DdManager * dd, @@ -274,23 +245,22 @@ Cudd_zddWeakDivF( dd->reordered = 0; res = cuddZddWeakDivF(dd, f, g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddWeakDivF */ -/**Function******************************************************************** - - Synopsis [Modified version of Cudd_zddDivide.] - - Description [Modified version of Cudd_zddDivide. This function may - disappear in future releases.] +/** + @brief Modified version of Cudd_zddDivide. - SideEffects [None] + @details This function may disappear in future releases. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * Cudd_zddDivideF( DdManager * dd, @@ -303,27 +273,28 @@ Cudd_zddDivideF( dd->reordered = 0; res = cuddZddDivideF(dd, f, g); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddDivideF */ -/**Function******************************************************************** - - Synopsis [Computes a complement cover for a ZDD node.] +/** + @brief Computes a complement cover for a %ZDD node. - Description [Computes a complement cover for a ZDD node. For lack of a - better method, we first extract the function BDD from the ZDD cover, - then make the complement of the ZDD cover from the complement of the - BDD node by using ISOP. Returns a pointer to the resulting cover if - successful; NULL otherwise. The result depends on current variable - order.] + @details For lack of a better method, we first extract the function + %BDD from the %ZDD cover, then make the complement of the %ZDD cover + from the complement of the %BDD node by using ISOP. The result + depends on current variable order. - SideEffects [The result depends on current variable order.] + @return a pointer to the resulting cover if successful; NULL + otherwise. - SeeAlso [] + @sideeffect The result depends on current variable order. -******************************************************************************/ +*/ DdNode * Cudd_zddComplement( DdManager *dd, @@ -361,24 +332,22 @@ Cudd_zddComplement( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddProduct.] - - Description [] +/** + @brief Performs the recursive step of Cudd_zddProduct. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddProduct] + @see Cudd_zddProduct -******************************************************************************/ +*/ DdNode * cuddZddProduct( DdManager * dd, DdNode * f, DdNode * g) { - int v, top_f, top_g; + int v; + int top_f, top_g; DdNode *tmp, *term1, *term2, *term3; DdNode *f0, *f1, *fd, *g0, *g1, *gd; DdNode *R0, *R1, *Rd, *N0, *N1; @@ -407,7 +376,7 @@ cuddZddProduct( if (r) return(r); - v = f->index; /* either yi or zi */ + v = (int) f->index; /* either yi or zi */ flag = cuddZddGetCofactors3(dd, f, v, &f1, &f0, &fd); if (flag == 1) return(NULL); @@ -598,24 +567,22 @@ cuddZddProduct( } /* end of cuddZddProduct */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddUnateProduct.] - - Description [] +/** + @brief Performs the recursive step of Cudd_zddUnateProduct. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddUnateProduct] + @see Cudd_zddUnateProduct -******************************************************************************/ +*/ DdNode * cuddZddUnateProduct( DdManager * dd, DdNode * f, DdNode * g) { - int v, top_f, top_g; + int v; + int top_f, top_g; DdNode *term1, *term2, *term3, *term4; DdNode *sum1, *sum2; DdNode *f0, *f1, *g0, *g1; @@ -643,7 +610,7 @@ cuddZddUnateProduct( if (r) return(r); - v = f->index; /* either yi or zi */ + v = (int) f->index; /* either yi or zi */ flag = cuddZddGetCofactors2(dd, f, v, &f1, &f0); if (flag == 1) return(NULL); @@ -742,17 +709,14 @@ cuddZddUnateProduct( } /* end of cuddZddUnateProduct */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddWeakDiv.] +/** + @brief Performs the recursive step of Cudd_zddWeakDiv. - Description [] + @sideeffect None - SideEffects [None] + @see Cudd_zddWeakDiv - SeeAlso [Cudd_zddWeakDiv] - -******************************************************************************/ +*/ DdNode * cuddZddWeakDiv( DdManager * dd, @@ -780,7 +744,7 @@ cuddZddWeakDiv( if (r) return(r); - v = g->index; + v = (int) g->index; flag = cuddZddGetCofactors3(dd, f, v, &f1, &f0, &fd); if (flag == 1) @@ -903,24 +867,22 @@ cuddZddWeakDiv( } /* end of cuddZddWeakDiv */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddWeakDivF.] +/** + @brief Performs the recursive step of Cudd_zddWeakDivF. - Description [] + @sideeffect None - SideEffects [None] + @see Cudd_zddWeakDivF - SeeAlso [Cudd_zddWeakDivF] - -******************************************************************************/ +*/ DdNode * cuddZddWeakDivF( DdManager * dd, DdNode * f, DdNode * g) { - int v, top_f, top_g, vf, vg; + int v; + int top_f, top_g, vf, vg; DdNode *one = DD_ONE(dd); DdNode *zero = DD_ZERO(dd); DdNode *f0, *f1, *fd, *g0, *g1, *gd; @@ -950,7 +912,7 @@ cuddZddWeakDivF( v = ddMin(top_f, top_g); if (v == top_f && vf < vg) { - v = f->index; + v = (int) f->index; flag = cuddZddGetCofactors3(dd, f, v, &f1, &f0, &fd); if (flag == 1) return(NULL); @@ -1015,9 +977,9 @@ cuddZddWeakDivF( } if (v == top_f) - v = f->index; + v = (int) f->index; else - v = g->index; + v = (int) g->index; flag = cuddZddGetCofactors3(dd, f, v, &f1, &f0, &fd); if (flag == 1) @@ -1140,17 +1102,14 @@ cuddZddWeakDivF( } /* end of cuddZddWeakDivF */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddDivide.] +/** + @brief Performs the recursive step of Cudd_zddDivide. - Description [] + @sideeffect None - SideEffects [None] + @see Cudd_zddDivide - SeeAlso [Cudd_zddDivide] - -******************************************************************************/ +*/ DdNode * cuddZddDivide( DdManager * dd, @@ -1177,7 +1136,7 @@ cuddZddDivide( if (r) return(r); - v = g->index; + v = (int) g->index; flag = cuddZddGetCofactors2(dd, f, v, &f1, &f0); if (flag == 1) @@ -1240,17 +1199,14 @@ cuddZddDivide( } /* end of cuddZddDivide */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddDivideF.] +/** + @brief Performs the recursive step of Cudd_zddDivideF. - Description [] + @sideeffect None - SideEffects [None] + @see Cudd_zddDivideF - SeeAlso [Cudd_zddDivideF] - -******************************************************************************/ +*/ DdNode * cuddZddDivideF( DdManager * dd, @@ -1277,7 +1233,7 @@ cuddZddDivideF( if (r) return(r); - v = g->index; + v = (int) g->index; flag = cuddZddGetCofactors2(dd, f, v, &f1, &f0); if (flag == 1) @@ -1340,18 +1296,19 @@ cuddZddDivideF( } /* end of cuddZddDivideF */ -/**Function******************************************************************** +/** + @brief Computes the three-way decomposition of f w.r.t. v. - Synopsis [Computes the three-way decomposition of f w.r.t. v.] + @details Computes the three-way decomposition of function f + (represented by a %ZDD) with respect to variable v. - Description [Computes the three-way decomposition of function f (represented - by a ZDD) wit respect to variable v. Returns 0 if successful; 1 otherwise.] + @return 0 if successful; 1 otherwise. - SideEffects [The results are returned in f1, f0, and fd.] + @sideeffect The results are returned in f1, f0, and fd. - SeeAlso [cuddZddGetCofactors2] + @see cuddZddGetCofactors2 -******************************************************************************/ +*/ int cuddZddGetCofactors3( DdManager * dd, @@ -1468,17 +1425,14 @@ cuddZddGetCofactors3( } /* end of cuddZddGetCofactors3 */ -/**Function******************************************************************** - - Synopsis [Computes the two-way decomposition of f w.r.t. v.] +/** + @brief Computes the two-way decomposition of f w.r.t. v. - Description [] + @sideeffect The results are returned in f1 and f0. - SideEffects [The results are returned in f1 and f0.] + @see cuddZddGetCofactors3 - SeeAlso [cuddZddGetCofactors3] - -******************************************************************************/ +*/ int cuddZddGetCofactors2( DdManager * dd, @@ -1500,20 +1454,15 @@ cuddZddGetCofactors2( } /* end of cuddZddGetCofactors2 */ -/**Function******************************************************************** - - Synopsis [Computes a complement of a ZDD node.] - - Description [Computes the complement of a ZDD node. So far, since we - couldn't find a direct way to get the complement of a ZDD cover, we first - convert a ZDD cover to a BDD, then make the complement of the ZDD cover - from the complement of the BDD node by using ISOP.] +/** + @brief Computes a complement of a %ZDD node. - SideEffects [The result depends on current variable order.] + @details So far, since we couldn't find a direct way to get the + complement of a %ZDD cover, we first convert a %ZDD cover to a %BDD, + then make the complement of the %ZDD cover from the complement of the + %BDD node by using ISOP. The result depends on current variable order. - SeeAlso [] - -******************************************************************************/ +*/ DdNode * cuddZddComplement( DdManager * dd, @@ -1546,59 +1495,37 @@ cuddZddComplement( } /* end of cuddZddComplement */ -/**Function******************************************************************** - - Synopsis [Returns the index of positive ZDD variable.] - - Description [Returns the index of positive ZDD variable.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Returns the index of positive %ZDD variable. +*/ int cuddZddGetPosVarIndex( DdManager * dd, int index) { - int pv = (index >> 1) << 1; + (void) dd; /* avoid warning */ + int pv = index & ~0x1; return(pv); } /* end of cuddZddGetPosVarIndex */ -/**Function******************************************************************** - - Synopsis [Returns the index of negative ZDD variable.] - - Description [Returns the index of negative ZDD variable.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Returns the index of negative %ZDD variable. +*/ int cuddZddGetNegVarIndex( DdManager * dd, int index) { + (void) dd; /* avoid warning */ int nv = index | 0x1; return(nv); } /* end of cuddZddGetPosVarIndex */ -/**Function******************************************************************** - - Synopsis [Returns the level of positive ZDD variable.] - - Description [Returns the level of positive ZDD variable.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Returns the level of positive %ZDD variable. +*/ int cuddZddGetPosVarLevel( DdManager * dd, @@ -1609,17 +1536,9 @@ cuddZddGetPosVarLevel( } /* end of cuddZddGetPosVarLevel */ -/**Function******************************************************************** - - Synopsis [Returns the level of negative ZDD variable.] - - Description [Returns the level of negative ZDD variable.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Returns the level of negative %ZDD variable. +*/ int cuddZddGetNegVarLevel( DdManager * dd, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddGroup.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddGroup.c similarity index 71% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddGroup.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddZddGroup.c index a3fb2cb87..2068891d1 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddGroup.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddGroup.c @@ -1,39 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddZddGroup.c] - - PackageName [cudd] - - Synopsis [Functions for ZDD group sifting.] - - Description [External procedures included in this file: - <ul> - <li> Cudd_MakeZddTreeNode() - </ul> - Internal procedures included in this file: - <ul> - <li> cuddZddTreeSifting() - </ul> - Static procedures included in this module: - <ul> - <li> zddTreeSiftingAux() - <li> zddCountInternalMtrNodes() - <li> zddReorderChildren() - <li> zddFindNodeHiLo() - <li> zddUniqueCompareGroup() - <li> zddGroupSifting() - <li> zddGroupSiftingAux() - <li> zddGroupSiftingUp() - <li> zddGroupSiftingDown() - <li> zddGroupMove() - <li> zddGroupMoveBackward() - <li> zddGroupSiftingBackward() - <li> zddMergeGroups() - </ul>] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Functions for %ZDD group sifting. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -63,13 +38,14 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" +#include "mtrInt.h" #include "cuddInt.h" -#include "ucbqsort.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ @@ -87,29 +63,11 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddZddGroup.c,v 1.22 2012/02/05 01:07:19 fabio Exp $"; -#endif - -static int *entry; -extern int zddTotalNumberSwapping; -#ifdef DD_STATS -static int extsymmcalls; -static int extsymm; -static int secdiffcalls; -static int secdiff; -static int secdiffmisfire; -#endif -#ifdef DD_DEBUG -static int pr = 0; /* flag to enable printing while debugging */ - /* by depositing a 1 into it */ -#endif - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -121,7 +79,7 @@ static int zddCountInternalMtrNodes (DdManager *table, MtrNode *treenode); #endif static int zddReorderChildren (DdManager *table, MtrNode *treenode, Cudd_ReorderingType method); static void zddFindNodeHiLo (DdManager *table, MtrNode *treenode, int *lower, int *upper); -static int zddUniqueCompareGroup (int *ptrX, int *ptrY); +static int zddUniqueCompareGroup (void const *ptrX, void const *ptrY); static int zddGroupSifting (DdManager *table, int lower, int upper); static int zddGroupSiftingAux (DdManager *table, int x, int xLow, int xHigh); static int zddGroupSiftingUp (DdManager *table, int y, int xLow, Move **moves); @@ -131,7 +89,7 @@ static int zddGroupMoveBackward (DdManager *table, int x, int y); static int zddGroupSiftingBackward (DdManager *table, Move *moves, int size); static void zddMergeGroups (DdManager *table, MtrNode *treenode, int low, int high); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -139,29 +97,29 @@ static void zddMergeGroups (DdManager *table, MtrNode *treenode, int low, int hi /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Creates a new %ZDD variable group. - Synopsis [Creates a new ZDD variable group.] + @details The group starts at variable and contains size + variables. The parameter low is the index of the first variable. If + the variable already exists, its current position in the order is + known to the manager. If the variable does not exist yet, the + position is assumed to be the same as the index. The group tree is + created if it does not exist yet. - Description [Creates a new ZDD variable group. The group starts at - variable and contains size variables. The parameter low is the index - of the first variable. If the variable already exists, its current - position in the order is known to the manager. If the variable does - not exist yet, the position is assumed to be the same as the index. - The group tree is created if it does not exist yet. - Returns a pointer to the group if successful; NULL otherwise.] + @return a pointer to the group if successful; NULL otherwise. - SideEffects [The ZDD variable tree is changed.] + @sideeffect The %ZDD variable tree is changed. - SeeAlso [Cudd_MakeTreeNode] + @see Cudd_MakeTreeNode -******************************************************************************/ +*/ MtrNode * Cudd_MakeZddTreeNode( - DdManager * dd /* manager */, - unsigned int low /* index of the first group variable */, - unsigned int size /* number of variables in the group */, - unsigned int type /* MTR_DEFAULT or MTR_FIXED */) + DdManager * dd /**< manager */, + unsigned int low /**< index of the first group variable */, + unsigned int size /**< number of variables in the group */, + unsigned int type /**< MTR_DEFAULT or MTR_FIXED */) { MtrNode *group; MtrNode *tree; @@ -172,7 +130,7 @@ Cudd_MakeZddTreeNode( ** Cudd_bddNewVarAtLevel or Cudd_addNewVarAtLevel to create new ** variables have to create the variables before they group them. */ - level = (low < (unsigned int) dd->sizeZ) ? dd->permZ[low] : low; + level = (low < (unsigned int) dd->sizeZ) ? (unsigned int) dd->permZ[low] : low; if (level + size - 1> (int) MTR_MAXHIGH) return(NULL); @@ -212,23 +170,23 @@ Cudd_MakeZddTreeNode( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Tree sifting algorithm for %ZDDs. - Synopsis [Tree sifting algorithm for ZDDs.] + @details Assumes that a tree representing a group hierarchy is + passed as a parameter. It then reorders each group in postorder + fashion by calling zddTreeSiftingAux. Assumes that no dead nodes + are present. - Description [Tree sifting algorithm for ZDDs. Assumes that a tree - representing a group hierarchy is passed as a parameter. It then - reorders each group in postorder fashion by calling - zddTreeSiftingAux. Assumes that no dead nodes are present. Returns - 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ int cuddZddTreeSifting( - DdManager * table /* DD table */, - Cudd_ReorderingType method /* reordering method for the groups of leaves */) + DdManager * table /**< %DD table */, + Cudd_ReorderingType method /**< reordering method for the groups of leaves */) { int i; int nvars; @@ -247,9 +205,9 @@ cuddZddTreeSifting( nvars = table->sizeZ; #ifdef DD_DEBUG - if (pr > 0 && !tempTree) + if (table->enableExtraDebug > 0 && !tempTree) (void) fprintf(table->out,"cuddZddTreeSifting:"); - Mtr_PrintGroups(table->treeZ,pr <= 0); + Mtr_PrintGroups(table->treeZ,table->enableExtraDebug <= 0); #endif #if 0 /* Debugging code. */ @@ -283,11 +241,11 @@ cuddZddTreeSifting( /* End of debugging code. */ #endif #ifdef DD_STATS - extsymmcalls = 0; - extsymm = 0; - secdiffcalls = 0; - secdiff = 0; - secdiffmisfire = 0; + table->extsymmcalls = 0; + table->extsymm = 0; + table->secdiffcalls = 0; + table->secdiff = 0; + table->secdiffmisfire = 0; (void) fprintf(table->out,"\n"); if (!tempTree) @@ -309,14 +267,14 @@ cuddZddTreeSifting( if (!tempTree && method == CUDD_REORDER_GROUP_SIFT && (table->groupcheck == CUDD_GROUP_CHECK7 || table->groupcheck == CUDD_GROUP_CHECK5)) { - (void) fprintf(table->out,"\nextsymmcalls = %d\n",extsymmcalls); - (void) fprintf(table->out,"extsymm = %d",extsymm); + (void) fprintf(table->out,"\nextsymmcalls = %d\n",table->extsymmcalls); + (void) fprintf(table->out,"extsymm = %d",table->extsymm); } if (!tempTree && method == CUDD_REORDER_GROUP_SIFT && table->groupcheck == CUDD_GROUP_CHECK7) { - (void) fprintf(table->out,"\nsecdiffcalls = %d\n",secdiffcalls); - (void) fprintf(table->out,"secdiff = %d\n",secdiff); - (void) fprintf(table->out,"secdiffmisfire = %d",secdiffmisfire); + (void) fprintf(table->out,"\nsecdiffcalls = %d\n",table->secdiffcalls); + (void) fprintf(table->out,"secdiff = %d\n",table->secdiff); + (void) fprintf(table->out,"secdiffmisfire = %d",table->secdiffmisfire); } #endif @@ -332,16 +290,17 @@ cuddZddTreeSifting( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Visits the group tree and reorders each group. - Synopsis [Visits the group tree and reorders each group.] + @details Recursively visits the group tree and reorders each group + in postorder fashion. - Description [Recursively visits the group tree and reorders each - group in postorder fashion. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int zddTreeSiftingAux( DdManager * table, @@ -376,16 +335,14 @@ zddTreeSiftingAux( #ifdef DD_STATS -/**Function******************************************************************** +/** + @brief Counts the number of internal nodes of the group tree. - Synopsis [Counts the number of internal nodes of the group tree.] + @return the count. - Description [Counts the number of internal nodes of the group tree. - Returns the count.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static int zddCountInternalMtrNodes( DdManager * table, @@ -412,20 +369,20 @@ zddCountInternalMtrNodes( #endif -/**Function******************************************************************** - - Synopsis [Reorders the children of a group tree node according to - the options.] +/** + @brief Reorders the children of a group tree node according to + the options. - Description [Reorders the children of a group tree node according to - the options. After reordering puts all the variables in the group - and/or its descendents in a single group. This allows hierarchical + @details After reordering puts all the variables in the group and/or + its descendents in a single group. This allows hierarchical reordering. If the variables in the group do not exist yet, simply - does nothing. Returns 1 if successful; 0 otherwise.] + does nothing. + + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int zddReorderChildren( DdManager * table, @@ -433,7 +390,7 @@ zddReorderChildren( Cudd_ReorderingType method) { int lower; - int upper; + int upper = 0; int result; unsigned int initialSize; @@ -477,6 +434,14 @@ zddReorderChildren( case CUDD_REORDER_GROUP_SIFT: result = zddGroupSifting(table,lower,upper); break; + case CUDD_REORDER_GROUP_SIFT_CONV: + do { + initialSize = table->keysZ; + result = zddGroupSifting(table,lower,upper); + if (initialSize <= table->keysZ) + break; + } while (result != 0); + break; case CUDD_REORDER_LINEAR: result = cuddZddLinearSifting(table,lower,upper); break; @@ -504,7 +469,8 @@ zddReorderChildren( zddMergeGroups(table,treenode,lower,upper); #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"zddReorderChildren:"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out,"zddReorderChildren:"); #endif return(result); @@ -512,21 +478,17 @@ zddReorderChildren( } /* end of zddReorderChildren */ -/**Function******************************************************************** - - Synopsis [Finds the lower and upper bounds of the group represented - by treenode.] +/** + @brief Finds the lower and upper bounds of the group represented + by treenode. - Description [Finds the lower and upper bounds of the group represented - by treenode. The high and low fields of treenode are indices. From + @details The high and low fields of treenode are indices. From those we need to derive the current positions, and find maximum and - minimum.] + minimum. - SideEffects [The bounds are returned as side effects.] + @sideeffect The bounds are returned as side effects. - SeeAlso [] - -******************************************************************************/ +*/ static void zddFindNodeHiLo( DdManager * table, @@ -582,7 +544,7 @@ zddFindNodeHiLo( #ifdef DD_DEBUG /* Make sure that all variables in group are contiguous. */ - assert(treenode->size >= *upper - *lower + 1); + assert(treenode->size >= (MtrHalfWord) (*upper - *lower + 1)); #endif return; @@ -590,53 +552,55 @@ zddFindNodeHiLo( } /* end of zddFindNodeHiLo */ -/**Function******************************************************************** +/** + @brief Comparison function used by qsort. - Synopsis [Comparison function used by qsort.] + @details Comparison function used by qsort to order the variables + according to the number of keys in the subtables. - Description [Comparison function used by qsort to order the variables - according to the number of keys in the subtables. Returns the - difference in number of keys between the two variables being - compared.] + @return the difference in number of keys between the two variables + being compared. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int zddUniqueCompareGroup( - int * ptrX, - int * ptrY) + void const * ptrX, + void const * ptrY) { + IndexKey const * pX = (IndexKey const *) ptrX; + IndexKey const * pY = (IndexKey const *) ptrY; #if 0 - if (entry[*ptrY] == entry[*ptrX]) { - return((*ptrX) - (*ptrY)); + if (pY->keys == pX->keys) { + return(pX->index - pY->index); } #endif - return(entry[*ptrY] - entry[*ptrX]); + return(pY->keys - pX->keys); } /* end of zddUniqueCompareGroup */ -/**Function******************************************************************** +/** + @brief Sifts from treenode->low to treenode->high. - Synopsis [Sifts from treenode->low to treenode->high.] + @details If croupcheck == CUDD_GROUP_CHECK7, it checks for group + creation at the end of the initial sifting. If a group is created, + it is then sifted again. After sifting one variable, the group that + contains it is dissolved. - Description [Sifts from treenode->low to treenode->high. If - croupcheck == CUDD_GROUP_CHECK7, it checks for group creation at the - end of the initial sifting. If a group is created, it is then sifted - again. After sifting one variable, the group that contains it is - dissolved. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int zddGroupSifting( DdManager * table, int lower, int upper) { - int *var; + IndexKey *var; int i,j,x,xInit; int nvars; int classes; @@ -650,18 +614,12 @@ zddGroupSifting( nvars = table->sizeZ; /* Order variables to sift. */ - entry = NULL; sifted = NULL; - var = ALLOC(int,nvars); + var = ALLOC(IndexKey,nvars); if (var == NULL) { table->errorCode = CUDD_MEMORY_OUT; goto zddGroupSiftingOutOfMem; } - entry = ALLOC(int,nvars); - if (entry == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - goto zddGroupSiftingOutOfMem; - } sifted = ALLOC(int,nvars); if (sifted == NULL) { table->errorCode = CUDD_MEMORY_OUT; @@ -673,23 +631,28 @@ zddGroupSifting( sifted[i] = 0; x = table->permZ[i]; if ((unsigned) x >= table->subtableZ[x].next) { - entry[i] = table->subtableZ[x].keys; - var[classes] = i; + var[classes].index = i; + var[classes].keys = table->subtableZ[x].keys; classes++; } } - cudd__qsort((void *)var,classes,sizeof(int),(DD_QSFP)zddUniqueCompareGroup); + util_qsort(var,classes,sizeof(IndexKey),zddUniqueCompareGroup); /* Now sift. */ for (i = 0; i < ddMin(table->siftMaxVar,classes); i++) { - if (zddTotalNumberSwapping >= table->siftMaxSwap) + if (table->zddTotalNumberSwapping >= table->siftMaxSwap) break; if (util_cpu_time() - table->startTime > table->timeLimit) { table->autoDynZ = 0; /* prevent further reordering */ break; } - xindex = var[i]; + if (table->terminationCallback != NULL && + table->terminationCallback(table->tcbArg)) { + table->autoDynZ = 0; /* prevent further reordering */ + break; + } + xindex = var[i].index; if (sifted[xindex] == 1) /* variable already sifted as part of group */ continue; x = table->permZ[xindex]; /* find current level of this variable */ @@ -728,18 +691,17 @@ zddGroupSifting( } #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"zddGroupSifting:"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out,"zddGroupSifting:"); #endif } /* for */ FREE(sifted); FREE(var); - FREE(entry); return(1); zddGroupSiftingOutOfMem: - if (entry != NULL) FREE(entry); if (var != NULL) FREE(var); if (sifted != NULL) FREE(sifted); @@ -748,21 +710,20 @@ zddGroupSiftingOutOfMem: } /* end of zddGroupSifting */ -/**Function******************************************************************** +/** + @brief Sifts one variable up and down until it has taken all + positions. Checks for aggregation. - Synopsis [Sifts one variable up and down until it has taken all - positions. Checks for aggregation.] + @details There may be at most two sweeps, even if the group grows. + Assumes that x is either an isolated variable, or it is the bottom + of a group. All groups may not have been found. The variable being + moved is returned to the best position seen during sifting. - Description [Sifts one variable up and down until it has taken all - positions. Checks for aggregation. There may be at most two sweeps, - even if the group grows. Assumes that x is either an isolated - variable, or it is the bottom of a group. All groups may not have - been found. The variable being moved is returned to the best position - seen during sifting. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int zddGroupSiftingAux( DdManager * table, @@ -777,7 +738,9 @@ zddGroupSiftingAux( #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"zddGroupSiftingAux from %d to %d\n",xLow,xHigh); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out, + "zddGroupSiftingAux from %d to %d\n",xLow,xHigh); assert((unsigned) x >= table->subtableZ[x].next); /* x is bottom of group */ #endif @@ -897,21 +860,20 @@ zddGroupSiftingAuxOutOfMem: } /* end of zddGroupSiftingAux */ -/**Function******************************************************************** +/** + @brief Sifts up a variable until either it reaches position xLow + or the size of the %DD heap increases too much. - Synopsis [Sifts up a variable until either it reaches position xLow - or the size of the DD heap increases too much.] + @details Assumes that y is the top of a group (or a singleton). + Checks y for aggregation to the adjacent variables. Records all the + moves that are appended to the list of moves received as input and + returned as a side effect. - Description [Sifts up a variable until either it reaches position - xLow or the size of the DD heap increases too much. Assumes that y is - the top of a group (or a singleton). Checks y for aggregation to the - adjacent variables. Records all the moves that are appended to the - list of moves received as input and returned as a side effect. - Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int zddGroupSiftingUp( DdManager * table, @@ -949,7 +911,9 @@ zddGroupSiftingUp( *moves = move; #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"zddGroupSiftingUp (2 single groups):\n"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out, + "zddGroupSiftingUp (2 single groups):\n"); #endif if ((double) size > (double) limitSize * table->maxGrowth) return(1); @@ -978,17 +942,17 @@ zddGroupSiftingUpOutOfMem: } /* end of zddGroupSiftingUp */ -/**Function******************************************************************** +/** + @brief Sifts down a variable until it reaches position xHigh. - Synopsis [Sifts down a variable until it reaches position xHigh.] + @details Assumes that x is the bottom of a group (or a singleton). + Records all the moves. - Description [Sifts down a variable until it reaches position xHigh. - Assumes that x is the bottom of a group (or a singleton). Records - all the moves. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int zddGroupSiftingDown( DdManager * table, @@ -1033,13 +997,13 @@ zddGroupSiftingDown( *moves = move; #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"zddGroupSiftingDown (2 single groups):\n"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out, + "zddGroupSiftingDown (2 single groups):\n"); #endif if ((double) size > (double) limitSize * table->maxGrowth) return(1); if (size < limitSize) limitSize = size; - x = y; - y = cuddZddNextHigh(table,x); } else { /* Group move */ size = zddGroupMove(table,x,y,moves); if (size == 0) goto zddGroupSiftingDownOutOfMem; @@ -1065,16 +1029,15 @@ zddGroupSiftingDownOutOfMem: } /* end of zddGroupSiftingDown */ -/**Function******************************************************************** - - Synopsis [Swaps two groups and records the move.] +/** + @brief Swaps two groups and records the move. - Description [Swaps two groups and records the move. Returns the - number of keys in the DD table in case of success; 0 otherwise.] + @return the number of keys in the %DD table in case of success; 0 + otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int zddGroupMove( DdManager * table, @@ -1085,7 +1048,7 @@ zddGroupMove( Move *move; int size; int i,j,xtop,xbot,xsize,ytop,ybot,ysize,newxtop; - int swapx,swapy; + int swapx = 0, swapy = 0; #if defined(DD_DEBUG) && defined(DD_VERBOSE) int initialSize,bestSize; #endif @@ -1145,7 +1108,8 @@ zddGroupMove( table->subtableZ[x].next = newxtop; /* x is bottom of its group, join */ /* it to top of its group */ #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"zddGroupMove:\n"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out,"zddGroupMove:\n"); #endif /* Store group move */ @@ -1171,16 +1135,14 @@ zddGroupMoveOutOfMem: } /* end of zddGroupMove */ -/**Function******************************************************************** +/** + @brief Undoes the swap two groups. - Synopsis [Undoes the swap two groups.] + @return 1 in case of success; 0 otherwise. - Description [Undoes the swap two groups. Returns 1 in case of - success; 0 otherwise.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static int zddGroupMoveBackward( DdManager * table, @@ -1236,7 +1198,8 @@ zddGroupMoveBackward( table->subtableZ[x].next = newxtop; /* x is bottom of its group, join */ /* to its top */ #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"zddGroupMoveBackward:\n"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out,"zddGroupMoveBackward:\n"); #endif return(1); @@ -1244,17 +1207,15 @@ zddGroupMoveBackward( } /* end of zddGroupMoveBackward */ -/**Function******************************************************************** - - Synopsis [Determines the best position for a variables and returns - it there.] +/** + @brief Determines the best position for a variables and returns + it there. - Description [Determines the best position for a variables and returns - it there. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int zddGroupSiftingBackward( DdManager * table, @@ -1278,7 +1239,8 @@ zddGroupSiftingBackward( res = cuddZddSwapInPlace(table,(int)move->x,(int)move->y); if (!res) return(0); #ifdef DD_DEBUG - if (pr > 0) (void) fprintf(table->out,"zddGroupSiftingBackward:\n"); + if (table->enableExtraDebug > 0) + (void) fprintf(table->out,"zddGroupSiftingBackward:\n"); assert(table->subtableZ[move->x].next == move->x); assert(table->subtableZ[move->y].next == move->y); #endif @@ -1293,16 +1255,15 @@ zddGroupSiftingBackward( } /* end of zddGroupSiftingBackward */ -/**Function******************************************************************** - - Synopsis [Merges groups in the DD table.] +/** + @brief Merges groups in the %DD table. - Description [Creates a single group from low to high and adjusts the - idex field of the tree node.] + @details Creates a single group from low to high and adjusts the + idex field of the tree node. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static void zddMergeGroups( DdManager * table, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddIsop.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddIsop.c similarity index 82% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddIsop.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddZddIsop.c index c1eaea3d6..f1b50d33d 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddIsop.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddIsop.c @@ -1,33 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddZddIsop.c] + @ingroup cudd - PackageName [cudd] + @brief Functions to find irredundant SOP covers as ZDDs from BDDs. - Synopsis [Functions to find irredundant SOP covers as ZDDs from BDDs.] + @author In-Ho Moon - Description [External procedures included in this module: - <ul> - <li> Cudd_bddIsop() - <li> Cudd_zddIsop() - <li> Cudd_MakeBddFromZddCover() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddBddIsop() - <li> cuddZddIsop() - <li> cuddMakeBddFromZddCover() - </ul> - Static procedures included in this module: - <ul> - </ul> - ] - - SeeAlso [] - - Author [In-Ho Moon] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -57,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -83,51 +65,48 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddZddIsop.c,v 1.22 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ +/** \endcond */ -/**AutomaticEnd***************************************************************/ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Computes an ISOP in %ZDD form from BDDs. - Synopsis [Computes an ISOP in ZDD form from BDDs.] - - Description [Computes an irredundant sum of products (ISOP) in ZDD + @details Computes an irredundant sum of products (ISOP) in %ZDD form from BDDs. The two BDDs L and U represent the lower bound and the upper bound, respectively, of the function. The ISOP uses two - ZDD variables for each BDD variable: One for the positive literal, + %ZDD variables for each %BDD variable: One for the positive literal, and one for the negative literal. These two variables should be - adjacent in the ZDD order. The two ZDD variables corresponding to - BDD variable <code>i</code> should have indices <code>2i</code> and + adjacent in the %ZDD order. The two %ZDD variables corresponding to + %BDD variable <code>i</code> should have indices <code>2i</code> and <code>2i+1</code>. The result of this procedure depends on the - variable order. If successful, Cudd_zddIsop returns the BDD for - the function chosen from the interval. The ZDD representing the + variable order. If successful, Cudd_zddIsop returns the %BDD for + the function chosen from the interval. The %ZDD representing the irredundant cover is returned as a side effect in zdd_I. In case of - failure, NULL is returned.] + failure, NULL is returned. + + @return the %BDD for the chosen function if successful; NULL otherwise. - SideEffects [zdd_I holds the pointer to the ZDD for the ISOP on - successful return.] + @sideeffect zdd_I holds the pointer to the %ZDD for the ISOP on + successful return. - SeeAlso [Cudd_bddIsop Cudd_zddVarsFromBddVars] + @see Cudd_bddIsop Cudd_zddVarsFromBddVars -******************************************************************************/ +*/ DdNode * Cudd_zddIsop( DdManager * dd, @@ -146,26 +125,28 @@ Cudd_zddIsop( res = cuddZddIsop(dd, L, U, zdd_I); } while (dd->reordered == 1); dd->autoDynZ = autoDynZ; + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddIsop */ -/**Function******************************************************************** +/** + @brief Computes a %BDD in the interval between L and U with a + simple sum-of-product cover. - Synopsis [Computes a BDD in the interval between L and U with a - simple sum-of-product cover.] + @details This procedure is similar to Cudd_zddIsop, but it does not + return the %ZDD for the cover. - Description [Computes a BDD in the interval between L and U with a - simple sum-of-product cover. This procedure is similar to - Cudd_zddIsop, but it does not return the ZDD for the cover. Returns - a pointer to the BDD if successful; NULL otherwise.] + @return a pointer to the %BDD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddIsop] + @see Cudd_zddIsop -******************************************************************************/ +*/ DdNode * Cudd_bddIsop( DdManager * dd, @@ -178,24 +159,25 @@ Cudd_bddIsop( dd->reordered = 0; res = cuddBddIsop(dd, L, U); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_bddIsop */ -/**Function******************************************************************** +/** + @brief Converts a %ZDD cover to a %BDD. - Synopsis [Converts a ZDD cover to a BDD.] + @details Converts a %ZDD cover to a %BDD for the function represented + by the cover. - Description [Converts a ZDD cover to a BDD for the function represented - by the cover. If successful, it returns a BDD node, otherwise it returns - NULL.] + @return a %BDD node if successful; otherwise it returns NULL. - SideEffects [] + @see Cudd_zddIsop - SeeAlso [Cudd_zddIsop] - -******************************************************************************/ +*/ DdNode * Cudd_MakeBddFromZddCover( DdManager * dd, @@ -207,7 +189,11 @@ Cudd_MakeBddFromZddCover( dd->reordered = 0; res = cuddMakeBddFromZddCover(dd, node); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); + } /* end of Cudd_MakeBddFromZddCover */ @@ -216,17 +202,14 @@ Cudd_MakeBddFromZddCover( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddIsop.] +/** + @brief Performs the recursive step of Cudd_zddIsop. - Description [] + @sideeffect None - SideEffects [None] + @see Cudd_zddIsop - SeeAlso [Cudd_zddIsop] - -******************************************************************************/ +*/ DdNode * cuddZddIsop( DdManager * dd, @@ -247,7 +230,7 @@ cuddZddIsop( DdNode *term0, *term1, *sum; DdNode *Lv, *Uv, *Lnv, *Unv; DdNode *r, *y, *z; - int index; + unsigned index; DD_CTFP cacheOp; statLine(dd); @@ -557,17 +540,14 @@ cuddZddIsop( } /* end of cuddZddIsop */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_bddIsop.] +/** + @brief Performs the recursive step of Cudd_bddIsop. - Description [] + @sideeffect None - SideEffects [None] + @see Cudd_bddIsop - SeeAlso [Cudd_bddIsop] - -******************************************************************************/ +*/ DdNode * cuddBddIsop( DdManager * dd, @@ -584,7 +564,7 @@ cuddBddIsop( DdNode *term0, *term1, *sum; DdNode *Lv, *Uv, *Lnv, *Unv; DdNode *r; - int index; + unsigned index; statLine(dd); if (L == zero) @@ -774,32 +754,30 @@ cuddBddIsop( } /* end of cuddBddIsop */ -/**Function******************************************************************** - - Synopsis [Converts a ZDD cover to a BDD.] +/** + @brief Converts a %ZDD cover to a %BDD. - Description [Converts a ZDD cover to a BDD. If successful, it returns - a BDD node, otherwise it returns NULL. It is a recursive algorithm - that works as follows. First it computes 3 cofactors of a ZDD cover: - f1, f0 and fd. Second, it compute BDDs (b1, b0 and bd) of f1, f0 and fd. - Third, it computes T=b1+bd and E=b0+bd. Fourth, it computes ITE(v,T,E) where - v is the variable which has the index of the top node of the ZDD cover. - In this case, since the index of v can be larger than either the one of T - or the one of E, cuddUniqueInterIVO is called, where IVO stands for - independent from variable ordering.] + @details It is a recursive algorithm that works as follows. First it + computes 3 cofactors of a %ZDD cover: f1, f0 and fd. Second, it + compute BDDs (b1, b0 and bd) of f1, f0 and fd. Third, it computes + T=b1+bd and E=b0+bd. Fourth, it computes ITE(v,T,E) where v is the + variable which has the index of the top node of the %ZDD cover. In + this case, since the index of v can be larger than either the one of + T or the one of E, cuddUniqueInterIVO is called, where IVO stands + for independent from variable ordering. - SideEffects [] + @return a %BDD node if successful; otherwise it returns NULL. - SeeAlso [Cudd_MakeBddFromZddCover] + @see Cudd_MakeBddFromZddCover -******************************************************************************/ +*/ DdNode * cuddMakeBddFromZddCover( DdManager * dd, DdNode * node) { DdNode *neW; - int v; + unsigned v; DdNode *f1, *f0, *fd; DdNode *b1, *b0, *bd; DdNode *T, *E; diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddLin.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddLin.c similarity index 80% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddLin.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddZddLin.c index aaa0bd6be..12d75cda1 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddLin.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddLin.c @@ -1,31 +1,16 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddZddLin.c] + @ingroup cudd - PackageName [cudd] + @brief Procedures for dynamic variable ordering of ZDDs. - Synopsis [Procedures for dynamic variable ordering of ZDDs.] + @see cuddLinear.c cuddZddReord.c - Description [Internal procedures included in this module: - <ul> - <li> cuddZddLinearSifting() - </ul> - Static procedures included in this module: - <ul> - <li> cuddZddLinearInPlace() - <li> cuddZddLinerAux() - <li> cuddZddLinearUp() - <li> cuddZddLinearDown() - <li> cuddZddLinearBackward() - <li> cuddZddUndoMoves() - </ul> - ] + @author Fabio Somenzi - SeeAlso [cuddLinear.c cuddZddReord.c] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -55,13 +40,13 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" -#include "ucbqsort.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ @@ -85,22 +70,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddZddLin.c,v 1.16 2012/02/05 01:07:19 fabio Exp $"; -#endif - -extern int *zdd_entry; -extern int zddTotalNumberSwapping; -static int zddTotalNumberLinearTr; -static DdNode *empty; - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -113,7 +88,7 @@ static Move * cuddZddLinearDown (DdManager *table, int x, int xHigh, Move *prevM static int cuddZddLinearBackward (DdManager *table, int size, Move *moves); static Move* cuddZddUndoMoves (DdManager *table, Move *moves); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -128,27 +103,24 @@ static Move* cuddZddUndoMoves (DdManager *table, Move *moves); -/**Function******************************************************************** - - Synopsis [Implementation of the linear sifting algorithm for ZDDs.] +/** + @brief Implementation of the linear sifting algorithm for ZDDs. - Description [Implementation of the linear sifting algorithm for ZDDs. - Assumes that no dead nodes are present. + @details Assumes that no dead nodes are present. <ol> <li> Order all the variables according to the number of entries in each unique table. <li> Sift the variable up and down and applies the XOR transformation, - remembering each time the total size of the DD heap. + remembering each time the total size of the %DD heap. <li> Select the best permutation. <li> Repeat 3 and 4 for all variables. </ol> - Returns 1 if successful; 0 otherwise.] - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int cuddZddLinearSifting( DdManager * table, @@ -156,7 +128,7 @@ cuddZddLinearSifting( int upper) { int i; - int *var; + IndexKey *var; int size; int x; int result; @@ -165,16 +137,9 @@ cuddZddLinearSifting( #endif size = table->sizeZ; - empty = table->zero; /* Find order in which to sift variables. */ - var = NULL; - zdd_entry = ALLOC(int, size); - if (zdd_entry == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - goto cuddZddSiftingOutOfMem; - } - var = ALLOC(int, size); + var = ALLOC(IndexKey, size); if (var == NULL) { table->errorCode = CUDD_MEMORY_OUT; goto cuddZddSiftingOutOfMem; @@ -182,21 +147,26 @@ cuddZddLinearSifting( for (i = 0; i < size; i++) { x = table->permZ[i]; - zdd_entry[i] = table->subtableZ[x].keys; - var[i] = i; + var[i].index = i; + var[i].keys = table->subtableZ[x].keys; } - cudd__qsort((void *)var, size, sizeof(int), (DD_QSFP)cuddZddUniqueCompare); + util_qsort(var, size, sizeof(IndexKey), cuddZddUniqueCompare); /* Now sift. */ for (i = 0; i < ddMin(table->siftMaxVar, size); i++) { - if (zddTotalNumberSwapping >= table->siftMaxSwap) + if (table->zddTotalNumberSwapping >= table->siftMaxSwap) break; if (util_cpu_time() - table->startTime > table->timeLimit) { table->autoDynZ = 0; /* prevent further reordering */ break; } - x = table->permZ[var[i]]; + if (table->terminationCallback != NULL && + table->terminationCallback(table->tcbArg)) { + table->autoDynZ = 0; /* prevent further reordering */ + break; + } + x = table->permZ[var[i].index]; if (x < lower || x > upper) continue; #ifdef DD_STATS previousSize = table->keysZ; @@ -209,7 +179,7 @@ cuddZddLinearSifting( (void) fprintf(table->out,"-"); } else if (table->keysZ > (unsigned) previousSize) { (void) fprintf(table->out,"+"); /* should never happen */ - (void) fprintf(table->out,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keysZ , var[i]); + (void) fprintf(table->out,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keysZ , var[i].index); } else { (void) fprintf(table->out,"="); } @@ -218,13 +188,11 @@ cuddZddLinearSifting( } FREE(var); - FREE(zdd_entry); return(1); cuddZddSiftingOutOfMem: - if (zdd_entry != NULL) FREE(zdd_entry); if (var != NULL) FREE(var); return(0); @@ -237,21 +205,21 @@ cuddZddSiftingOutOfMem: /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Linearly combines two adjacent variables. - Synopsis [Linearly combines two adjacent variables.] + @details It assumes that no dead nodes are present on entry to this + procedure. The procedure then guarantees that no dead nodes will be + present when it terminates. cuddZddLinearInPlace assumes that x + < y. - Description [Linearly combines two adjacent variables. It assumes - that no dead nodes are present on entry to this procedure. The - procedure then guarantees that no dead nodes will be present when it - terminates. cuddZddLinearInPlace assumes that x < y. Returns the - number of keys in the table if successful; 0 otherwise.] + @return the number of keys in the table if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddZddSwapInPlace cuddLinearInPlace] + @see cuddZddSwapInPlace cuddLinearInPlace -******************************************************************************/ +*/ static int cuddZddLinearInPlace( DdManager * table, @@ -269,6 +237,7 @@ cuddZddLinearInPlace( DdNode *f, *f1, *f0, *f11, *f10, *f01, *f00; DdNode *newf1, *newf0, *g, *next, *previous; DdNode *special; + DdNode *empty = table->zero; #ifdef DD_DEBUG assert(x < y); @@ -279,8 +248,6 @@ cuddZddLinearInPlace( assert(table->subtableZ[y].dead == 0); #endif - zddTotalNumberLinearTr++; - /* Get parameters of x subtable. */ xindex = table->invpermZ[x]; xlist = table->subtableZ[x].nodelist; @@ -560,20 +527,17 @@ zddSwapOutOfMem: } /* end of cuddZddLinearInPlace */ -/**Function******************************************************************** - - Synopsis [Given xLow <= x <= xHigh moves x up and down between the - boundaries.] +/** + @brief Given xLow <= x <= xHigh moves x up and down between the + boundaries. - Description [Given xLow <= x <= xHigh moves x up and down between the - boundaries. Finds the best position and does the required changes. - Returns 1 if successful; 0 otherwise.] + @details Finds the best position and does the required changes. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int cuddZddLinearAux( DdManager * table, @@ -624,7 +588,7 @@ cuddZddLinearAux( goto cuddZddLinearAuxOutOfMem; moveUp = cuddZddUndoMoves(table,moveDown); #ifdef DD_DEBUG - assert(moveUp == NULL || moveUp->x == x); + assert(moveUp == NULL || moveUp->x == (DdHalfWord) x); #endif moveUp = cuddZddLinearUp(table, x, xLow, moveUp); if (moveUp == (Move *) CUDD_OUT_OF_MEM) @@ -642,7 +606,7 @@ cuddZddLinearAux( /* Then move up. */ moveDown = cuddZddUndoMoves(table,moveUp); #ifdef DD_DEBUG - assert(moveDown == NULL || moveDown->y == x); + assert(moveDown == NULL || moveDown->y == (DdHalfWord) x); #endif moveDown = cuddZddLinearDown(table, x, xHigh, moveDown); if (moveDown == (Move *) CUDD_OUT_OF_MEM) @@ -687,20 +651,17 @@ cuddZddLinearAuxOutOfMem: } /* end of cuddZddLinearAux */ -/**Function******************************************************************** +/** + @brief Sifts a variable up applying the XOR transformation. - Synopsis [Sifts a variable up applying the XOR transformation.] + @details Moves y up until either it reaches the bound (xLow) or the + size of the %ZDD heap increases too much. - Description [Sifts a variable up applying the XOR - transformation. Moves y up until either it reaches the bound (xLow) - or the size of the ZDD heap increases too much. Returns the set of - moves in case of success; NULL if memory is full.] + @return the set of moves in case of success; NULL if memory is full. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static Move * cuddZddLinearUp( DdManager * table, @@ -772,20 +733,18 @@ cuddZddLinearUpOutOfMem: } /* end of cuddZddLinearUp */ -/**Function******************************************************************** - - Synopsis [Sifts a variable down and applies the XOR transformation.] +/** + @brief Sifts a variable down and applies the XOR transformation. - Description [Sifts a variable down. Moves x down until either it - reaches the bound (xHigh) or the size of the ZDD heap increases too - much. Returns the set of moves in case of success; NULL if memory is - full.] + @details Sifts a variable down. Moves x down until either it + reaches the bound (xHigh) or the size of the %ZDD heap increases too + much. - SideEffects [None] + @return the set of moves in case of success; NULL if memory is full. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static Move * cuddZddLinearDown( DdManager * table, @@ -855,21 +814,18 @@ cuddZddLinearDownOutOfMem: } /* end of cuddZddLinearDown */ -/**Function******************************************************************** +/** + @brief Given a set of moves, returns the %ZDD heap to the position + giving the minimum size. - Synopsis [Given a set of moves, returns the ZDD heap to the position - giving the minimum size.] + @details In case of ties, returns to the closest position giving the + minimum size. - Description [Given a set of moves, returns the ZDD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int cuddZddLinearBackward( DdManager * table, @@ -906,18 +862,15 @@ cuddZddLinearBackward( } /* end of cuddZddLinearBackward */ -/**Function******************************************************************** - - Synopsis [Given a set of moves, returns the ZDD heap to the order - in effect before the moves.] +/** + @brief Given a set of moves, returns the %ZDD heap to the order + in effect before the moves. - Description [Given a set of moves, returns the ZDD heap to the - order in effect before the moves. Returns 1 in case of success; - 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static Move* cuddZddUndoMoves( DdManager * table, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddMisc.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddMisc.c similarity index 60% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddMisc.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddZddMisc.c index ec7686276..336be8563 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddMisc.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddMisc.c @@ -1,31 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddZddMisc.c] + @ingroup cudd - PackageName [cudd] + @brief Miscellaneous utility functions for ZDDs. - Synopsis [Miscellaneous utility functions for ZDDs.] + @author Hyong-Kyoon Shin, In-Ho Moon - Description [External procedures included in this module: - <ul> - <li> Cudd_zddDagSize() - <li> Cudd_zddCountMinterm() - <li> Cudd_zddPrintSubtable() - </ul> - Internal procedures included in this module: - <ul> - </ul> - Static procedures included in this module: - <ul> - <li> cuddZddDagInt() - </ul> - ] - - SeeAlso [] - - Author [Hyong-Kyoon Shin, In-Ho Moon] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -55,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include <math.h> #include "util.h" @@ -82,16 +66,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddZddMisc.c,v 1.18 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -99,7 +79,7 @@ static char rcsid[] DD_UNUSED = "$Id: cuddZddMisc.c,v 1.18 2012/02/05 01:07:19 f static int cuddZddDagInt (DdNode *n, st_table *tab); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -107,18 +87,17 @@ static int cuddZddDagInt (DdNode *n, st_table *tab); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Counts the number of nodes in a %ZDD. - Synopsis [Counts the number of nodes in a ZDD.] + @deprecated This function duplicates Cudd_DagSize and is only + retained for compatibility. - Description [Counts the number of nodes in a ZDD. This function - duplicates Cudd_DagSize and is only retained for compatibility.] + @sideeffect None - SideEffects [None] + @see Cudd_DagSize - SeeAlso [Cudd_DagSize] - -******************************************************************************/ +*/ int Cudd_zddDagSize( DdNode * p_node) @@ -135,21 +114,22 @@ Cudd_zddDagSize( } /* end of Cudd_zddDagSize */ -/**Function******************************************************************** - - Synopsis [Counts the number of minterms of a ZDD.] +/** + @brief Counts the number of minterms of a %ZDD. - Description [Counts the number of minterms of the ZDD rooted at - <code>node</code>. This procedure takes a parameter + @details Counts the number of minterms of the %ZDD rooted at + <code>node</code>. This procedure takes a parameter <code>path</code> that specifies how many variables are in the - support of the function. If the procedure runs out of memory, it - returns (double) CUDD_OUT_OF_MEM.] + support of the function. - SideEffects [None] + @return the count. If the procedure runs out of memory, it returns + (double) CUDD_OUT_OF_MEM. - SeeAlso [Cudd_zddCountDouble] + @sideeffect None -******************************************************************************/ + @see Cudd_zddCountDouble + +*/ double Cudd_zddCountMinterm( DdManager * zdd, @@ -165,17 +145,12 @@ Cudd_zddCountMinterm( } /* end of Cudd_zddCountMinterm */ -/**Function******************************************************************** - - Synopsis [Prints the ZDD table.] +/** + @brief Prints the %ZDD table for debugging purposes. - Description [Prints the ZDD table for debugging purposes.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ void Cudd_zddPrintSubtable( DdManager * table) @@ -192,42 +167,26 @@ Cudd_zddPrintSubtable( z1 = ZSubTable->nodelist[j]; while (z1 != NIL(DdNode)) { (void) fprintf(table->out, -#if SIZEOF_VOID_P == 8 - "ID = 0x%lx\tindex = %u\tr = %u\t", - (ptruint) z1 / (ptruint) sizeof(DdNode), - z1->index, z1->ref); -#else - "ID = 0x%x\tindex = %hu\tr = %hu\t", + "ID = 0x%" PRIxPTR "\tindex = %u\tr = %u\t", (ptruint) z1 / (ptruint) sizeof(DdNode), z1->index, z1->ref); -#endif z1_next = cuddT(z1); - if (Cudd_IsConstant(z1_next)) { + if (Cudd_IsConstantInt(z1_next)) { (void) fprintf(table->out, "T = %d\t\t", (z1_next == base)); } else { -#if SIZEOF_VOID_P == 8 - (void) fprintf(table->out, "T = 0x%lx\t", + (void) fprintf(table->out, "T = 0x%" PRIxPTR "\t", (ptruint) z1_next / (ptruint) sizeof(DdNode)); -#else - (void) fprintf(table->out, "T = 0x%x\t", - (ptruint) z1_next / (ptruint) sizeof(DdNode)); -#endif } z1_next = cuddE(z1); - if (Cudd_IsConstant(z1_next)) { + if (Cudd_IsConstantInt(z1_next)) { (void) fprintf(table->out, "E = %d\n", (z1_next == base)); } else { -#if SIZEOF_VOID_P == 8 - (void) fprintf(table->out, "E = 0x%lx\n", - (ptruint) z1_next / (ptruint) sizeof(DdNode)); -#else - (void) fprintf(table->out, "E = 0x%x\n", + (void) fprintf(table->out, "E = 0x%" PRIxPTR "\n", (ptruint) z1_next / (ptruint) sizeof(DdNode)); -#endif } z1_next = z1->next; @@ -245,18 +204,14 @@ Cudd_zddPrintSubtable( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddDagSize.] - - Description [Performs the recursive step of Cudd_zddDagSize. Does - not check for out-of-memory conditions.] +/** + @brief Performs the recursive step of Cudd_zddDagSize. - SideEffects [None] + @details Does not check for out-of-memory conditions. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int cuddZddDagInt( DdNode * n, @@ -265,13 +220,13 @@ cuddZddDagInt( if (n == NIL(DdNode)) return(0); - if (st_is_member(tab, (char *)n) == 1) + if (st_is_member(tab, n) == 1) return(0); - if (Cudd_IsConstant(n)) + if (Cudd_IsConstantInt(n)) return(0); - (void)st_insert(tab, (char *)n, NIL(char)); + (void)st_insert(tab, n, NIL(void)); return(1 + cuddZddDagInt(cuddT(n), tab) + cuddZddDagInt(cuddE(n), tab)); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddPort.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddPort.c similarity index 73% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddPort.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddZddPort.c index c661c6a88..627725076 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddPort.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddPort.c @@ -1,31 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [cuddZddPort.c] + @ingroup cudd - PackageName [cudd] + @brief Functions that translate BDDs to ZDDs. - Synopsis [Functions that translate BDDs to ZDDs.] + @author Hyong-kyoon Shin, In-Ho Moon - Description [External procedures included in this module: - <ul> - <li> Cudd_zddPortFromBdd() - <li> Cudd_zddPortToBdd() - </ul> - Internal procedures included in this module: - <ul> - </ul> - Static procedures included in this module: - <ul> - <li> zddPortFromBddStep() - <li> zddPortToBddStep() - </ul> - ] - - SeeAlso [] - - Author [Hyong-kyoon Shin, In-Ho Moon] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -55,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -81,16 +65,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddZddPort.c,v 1.14 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -99,7 +79,7 @@ static char rcsid[] DD_UNUSED = "$Id: cuddZddPort.c,v 1.14 2012/02/05 01:07:19 f static DdNode * zddPortFromBddStep (DdManager *dd, DdNode *B, int expected); static DdNode * zddPortToBddStep (DdManager *dd, DdNode *f, int depth); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -107,22 +87,22 @@ static DdNode * zddPortToBddStep (DdManager *dd, DdNode *f, int depth); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Converts a %BDD into a %ZDD. - Synopsis [Converts a BDD into a ZDD.] + @details This function assumes that there is a one-to-one + correspondence between the %BDD variables and the %ZDD variables, and + that the variable order is the same for both types of + variables. These conditions are established if the %ZDD variables are + created by one call to Cudd_zddVarsFromBddVars with multiplicity = 1. - Description [Converts a BDD into a ZDD. This function assumes that - there is a one-to-one correspondence between the BDD variables and the - ZDD variables, and that the variable order is the same for both types - of variables. These conditions are established if the ZDD variables - are created by one call to Cudd_zddVarsFromBddVars with multiplicity = - 1. Returns a pointer to the resulting ZDD if successful; NULL otherwise.] + @return a pointer to the resulting %ZDD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddVarsFromBddVars] + @see Cudd_zddVarsFromBddVars -******************************************************************************/ +*/ DdNode * Cudd_zddPortFromBdd( DdManager * dd, @@ -134,24 +114,26 @@ Cudd_zddPortFromBdd( dd->reordered = 0; res = zddPortFromBddStep(dd,B,0); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddPortFromBdd */ -/**Function******************************************************************** - - Synopsis [Converts a ZDD into a BDD.] +/** + @brief Converts a %ZDD into a %BDD. - Description [Converts a ZDD into a BDD. Returns a pointer to the resulting - ZDD if successful; NULL otherwise.] + @return a pointer to the resulting %ZDD if successful; NULL + otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddPortFromBdd] + @see Cudd_zddPortFromBdd -******************************************************************************/ +*/ DdNode * Cudd_zddPortToBdd( DdManager * dd, @@ -163,6 +145,9 @@ Cudd_zddPortToBdd( dd->reordered = 0; res = zddPortToBddStep(dd,f,0); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); @@ -178,17 +163,12 @@ Cudd_zddPortToBdd( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_zddPortFromBdd. - Synopsis [Performs the recursive step of Cudd_zddPortFromBdd.] + @sideeffect None - Description [] - - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static DdNode * zddPortFromBddStep( DdManager * dd, @@ -197,7 +177,8 @@ zddPortFromBddStep( { DdNode *res, *prevZdd, *t, *e; DdNode *Breg, *Bt, *Be; - int id, level; + int id; + int level; statLine(dd); /* Terminal cases. */ @@ -245,7 +226,7 @@ zddPortFromBddStep( Be = cuddE(Breg); } - id = Breg->index; + id = (int) Breg->index; level = cuddI(dd,id); t = zddPortFromBddStep(dd, Bt, level+1); if (t == NULL) return(NULL); @@ -286,26 +267,21 @@ zddPortFromBddStep( } /* end of zddPortFromBddStep */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddPortToBdd.] - - Description [] - - SideEffects [None] +/** + @brief Performs the recursive step of Cudd_zddPortToBdd. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static DdNode * zddPortToBddStep( DdManager * dd /* manager */, - DdNode * f /* ZDD to be converted */, + DdNode * f /* %ZDD to be converted */, int depth /* recursion depth */) { DdNode *one, *zero, *T, *E, *res, *var; - unsigned int index; - unsigned int level; + int index; + int level; statLine(dd); one = DD_ONE(dd); @@ -320,7 +296,7 @@ zddPortToBddStep( if (var == NULL) return(NULL); cuddRef(var); - if (level > (unsigned) depth) { + if (level > depth) { E = zddPortToBddStep(dd,f,depth+1); if (E == NULL) { Cudd_RecursiveDeref(dd,var); diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddReord.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddReord.c similarity index 72% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddReord.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddZddReord.c index f9d710bda..d443e5ef4 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddReord.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddReord.c @@ -1,45 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddZddReord.c] - - PackageName [cudd] - - Synopsis [Procedures for dynamic variable ordering of ZDDs.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_zddReduceHeap() - <li> Cudd_zddShuffleHeap() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddAlignToBdd() - <li> cuddZddNextHigh() - <li> cuddZddNextLow() - <li> cuddZddUniqueCompare() - <li> cuddZddSwapInPlace() - <li> cuddZddSwapping() - <li> cuddZddSifting() - </ul> - Static procedures included in this module: - <ul> - <li> zddSwapAny() - <li> cuddZddSiftingAux() - <li> cuddZddSiftingUp() - <li> cuddZddSiftingDown() - <li> cuddZddSiftingBackward() - <li> zddReorderPreprocess() - <li> zddReorderPostprocess() - <li> zddShuffle() - <li> zddSiftUp() - </ul> - ] - - SeeAlso [] - - Author [Hyong-Kyoon Shin, In-Ho Moon] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Procedures for dynamic variable ordering of ZDDs. + + @author Hyong-Kyoon Shin, In-Ho Moon + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -69,20 +38,20 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" +#include "mtrInt.h" #include "cuddInt.h" -#include "ucbqsort.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ /*---------------------------------------------------------------------------*/ #define DD_MAX_SUBTABLE_SPARSITY 8 -#define DD_SHRINK_FACTOR 2 /*---------------------------------------------------------------------------*/ /* Stucture declarations */ @@ -98,23 +67,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddZddReord.c,v 1.49 2012/02/05 01:07:19 fabio Exp $"; -#endif - -int *zdd_entry; - -int zddTotalNumberSwapping; - -static DdNode *empty; - /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -131,7 +89,7 @@ static int zddShuffle (DdManager *table, int *permutation); static int zddSiftUp (DdManager *table, int x, int xLow); static void zddFixTree (DdManager *table, MtrNode *treenode); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -139,11 +97,10 @@ static void zddFixTree (DdManager *table, MtrNode *treenode); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Main dynamic reordering routine for ZDDs. - Synopsis [Main dynamic reordering routine for ZDDs.] - - Description [Main dynamic reordering routine for ZDDs. + @details@parblock Calls one of the possible reordering procedures: <ul> <li>Swapping @@ -152,23 +109,25 @@ static void zddFixTree (DdManager *table, MtrNode *treenode); </ul> For sifting and symmetric sifting it is possible to request reordering - to convergence.<p> + to convergence. The core of all methods is the reordering procedure cuddZddSwapInPlace() which swaps two adjacent variables. - Returns 1 in case of success; 0 otherwise. In the case of symmetric + @endparblock + + @return 1 in case of success; 0 otherwise. In the case of symmetric sifting (with and without convergence) returns 1 plus the number of - symmetric variables, in case of success.] + symmetric variables, in case of success. - SideEffects [Changes the variable order for all ZDDs and clears - the cache.] + @sideeffect Changes the variable order for all ZDDs and clears + the cache. -******************************************************************************/ +*/ int Cudd_zddReduceHeap( - DdManager * table /* DD manager */, - Cudd_ReorderingType heuristic /* method used for reordering */, - int minsize /* bound below which no reordering occurs */) + DdManager * table /**< DD manager */, + Cudd_ReorderingType heuristic /**< method used for reordering */, + int minsize /**< bound below which no reordering occurs */) { DdHook *hook; int result; @@ -194,7 +153,6 @@ Cudd_zddReduceHeap( ** we count it. */ table->reorderings++; - empty = table->zero; localTime = util_cpu_time(); @@ -208,7 +166,7 @@ Cudd_zddReduceHeap( /* Clear the cache and collect garbage. */ zddReorderPreprocess(table); - zddTotalNumberSwapping = 0; + table->zddTotalNumberSwapping = 0; #ifdef DD_STATS initialSize = table->keysZ; @@ -244,7 +202,7 @@ Cudd_zddReduceHeap( (void) fprintf(table->out,"#:T_REORDER %8g: total time (sec)\n", ((double)(util_cpu_time() - localTime)/1000.0)); (void) fprintf(table->out,"#:N_REORDER %8d: total swaps\n", - zddTotalNumberSwapping); + table->zddTotalNumberSwapping); #endif if (result == 0) @@ -269,7 +227,7 @@ Cudd_zddReduceHeap( /* Run hook functions. */ hook = table->postReorderingHook; while (hook != NULL) { - int res = (hook->f)(table, "ZDD", (void *)localTime); + int res = (hook->f)(table, "ZDD", (void *)(ptruint)localTime); if (res == 0) return(0); hook = hook->next; } @@ -281,31 +239,30 @@ Cudd_zddReduceHeap( } /* end of Cudd_zddReduceHeap */ -/**Function******************************************************************** +/** + @brief Reorders %ZDD variables according to given permutation. - Synopsis [Reorders ZDD variables according to given permutation.] + @details The i-th entry of the permutation array contains the index + of the variable that should be brought to the i-th level. The size + of the array should be equal or greater to the number of variables + currently in use. - Description [Reorders ZDD variables according to given permutation. - The i-th entry of the permutation array contains the index of the variable - that should be brought to the i-th level. The size of the array should be - equal or greater to the number of variables currently in use. - Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [Changes the ZDD variable order for all diagrams and clears - the cache.] + @sideeffect Changes the %ZDD variable order for all diagrams and clears + the cache. - SeeAlso [Cudd_zddReduceHeap] + @see Cudd_zddReduceHeap -******************************************************************************/ +*/ int Cudd_zddShuffleHeap( - DdManager * table /* DD manager */, - int * permutation /* required variable permutation */) + DdManager * table /**< DD manager */, + int * permutation /**< required variable permutation */) { int result; - empty = table->zero; zddReorderPreprocess(table); result = zddShuffle(table,permutation); @@ -322,32 +279,30 @@ Cudd_zddShuffleHeap( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Reorders %ZDD variables according to the order of the %BDD + variables. - Synopsis [Reorders ZDD variables according to the order of the BDD - variables.] + @details This function can be called at the end of %BDD reordering to + insure that the order of the %ZDD variables is consistent with the + order of the %BDD variables. The number of %ZDD variables must be a + multiple of the number of %BDD variables. Let <code>M</code> be the + ratio of the two numbers. cuddZddAlignToBdd then considers the %ZDD + variables from <code>M*i</code> to <code>(M+1)*i-1</code> as + corresponding to %BDD variable <code>i</code>. This function should + be normally called from Cudd_ReduceHeap, which clears the cache. - Description [Reorders ZDD variables according to the order of the - BDD variables. This function can be called at the end of BDD - reordering to insure that the order of the ZDD variables is - consistent with the order of the BDD variables. The number of ZDD - variables must be a multiple of the number of BDD variables. Let - <code>M</code> be the ratio of the two numbers. cuddZddAlignToBdd - then considers the ZDD variables from <code>M*i</code> to - <code>(M+1)*i-1</code> as corresponding to BDD variable - <code>i</code>. This function should be normally called from - Cudd_ReduceHeap, which clears the cache. Returns 1 in case of - success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [Changes the ZDD variable order for all diagrams and performs - garbage collection of the ZDD unique table.] + @sideeffect Changes the %ZDD variable order for all diagrams and performs + garbage collection of the %ZDD unique table. - SeeAlso [Cudd_zddShuffleHeap Cudd_ReduceHeap] + @see Cudd_zddShuffleHeap Cudd_ReduceHeap -******************************************************************************/ +*/ int cuddZddAlignToBdd( - DdManager * table /* DD manager */) + DdManager * table /**< %DD manager */) { int *invpermZ; /* permutation array */ int M; /* ratio of ZDD variables to BDD variables */ @@ -358,7 +313,6 @@ cuddZddAlignToBdd( if (table->sizeZ == 0) return(1); - empty = table->zero; M = table->sizeZ / table->size; /* Check whether the number of ZDD variables is a multiple of the ** number of BDD variables. @@ -394,89 +348,80 @@ cuddZddAlignToBdd( } /* end of cuddZddAlignToBdd */ -/**Function******************************************************************** - - Synopsis [Finds the next subtable with a larger index.] +/** + @brief Finds the next subtable with a larger index. - Description [Finds the next subtable with a larger index. Returns the - index.] + @return the index. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int cuddZddNextHigh( DdManager * table, int x) { + (void) table; /* avoid warning */ return(x + 1); } /* end of cuddZddNextHigh */ -/**Function******************************************************************** - - Synopsis [Finds the next subtable with a smaller index.] +/** + @brief Finds the next subtable with a smaller index. - Description [Finds the next subtable with a smaller index. Returns the - index.] + @return the index. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int cuddZddNextLow( DdManager * table, int x) { + (void) table; /* avoid warning */ return(x - 1); } /* end of cuddZddNextLow */ -/**Function******************************************************************** - - Synopsis [Comparison function used by qsort.] +/** + @brief Comparison function used by qsort. - Description [Comparison function used by qsort to order the - variables according to the number of keys in the subtables. - Returns the difference in number of keys between the two - variables being compared.] + @details Comparison function used by qsort to order the variables + according to the number of keys in the subtables. - SideEffects [None] + @return the difference in number of keys between the two variables + being compared. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int cuddZddUniqueCompare( - int * ptr_x, - int * ptr_y) + void const * ptr_x, + void const * ptr_y) { - return(zdd_entry[*ptr_y] - zdd_entry[*ptr_x]); + IndexKey const * pX = (IndexKey const *) ptr_x; + IndexKey const * pY = (IndexKey const *) ptr_y; + return(pY->keys - pX->keys); } /* end of cuddZddUniqueCompare */ -/**Function******************************************************************** +/** + @brief Swaps two adjacent variables. - Synopsis [Swaps two adjacent variables.] + @details It assumes that no dead nodes are present on entry to this + procedure. The procedure then guarantees that no dead nodes will be + present when it terminates. cuddZddSwapInPlace assumes that x < y. - Description [Swaps two adjacent variables. It assumes that no dead - nodes are present on entry to this procedure. The procedure then - guarantees that no dead nodes will be present when it terminates. - cuddZddSwapInPlace assumes that x < y. Returns the number of keys in - the table if successful; 0 otherwise.] + @return the number of keys in the table if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int cuddZddSwapInPlace( DdManager * table, @@ -492,8 +437,9 @@ cuddZddSwapInPlace( int i; int posn; DdNode *f, *f1, *f0, *f11, *f10, *f01, *f00; - DdNode *newf1, *newf0, *next; + DdNode *newf1 = NULL, *newf0 = NULL, *next; DdNodePtr g, *lastP, *previousP; + DdNode *empty = table->zero; #ifdef DD_DEBUG assert(x < y); @@ -504,7 +450,7 @@ cuddZddSwapInPlace( assert(table->subtableZ[y].dead == 0); #endif - zddTotalNumberSwapping++; + table->zddTotalNumberSwapping++; /* Get parameters of x subtable. */ xindex = table->invpermZ[x]; @@ -719,11 +665,10 @@ zddSwapOutOfMem: } /* end of cuddZddSwapInPlace */ -/**Function******************************************************************** - - Synopsis [Reorders variables by a sequence of (non-adjacent) swaps.] +/** + @brief Reorders variables by a sequence of (non-adjacent) swaps. - Description [Implementation of Plessier's algorithm that reorders + @details Implementation of Plessier's algorithm that reorders variables by a sequence of (non-adjacent) swaps. <ol> <li> Select two variables (RANDOM or HEURISTIC). @@ -732,13 +677,12 @@ zddSwapOutOfMem: <li> Otherwise reconstruct the original heap. <li> Loop. </ol> - Returns 1 in case of success; 0 otherwise.] - SideEffects [None] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int cuddZddSwapping( DdManager * table, @@ -753,7 +697,7 @@ cuddZddSwapping( int iterate; int previousSize; Move *moves, *move; - int pivot; + int pivot = 0; int modulo; int result; @@ -780,7 +724,7 @@ cuddZddSwapping( y = pivot; /* y = nvars-1 */ } else { /* y = random # from {pivot+1 .. nvars-1} */ - y = pivot + 1 + (int) (Cudd_Random() % modulo); + y = pivot + 1 + (int) (Cudd_Random(table) % modulo); } modulo = pivot - lower - 1; @@ -788,15 +732,15 @@ cuddZddSwapping( x = lower; } else { do { /* x = random # from {0 .. pivot-2} */ - x = (int) Cudd_Random() % modulo; + x = (int) Cudd_Random(table) % modulo; } while (x == y); /* Is this condition really needed, since x and y are in regions separated by pivot? */ } } else { - x = (int) (Cudd_Random() % nvars) + lower; + x = (int) (Cudd_Random(table) % nvars) + lower; do { - y = (int) (Cudd_Random() % nvars) + lower; + y = (int) (Cudd_Random(table) % nvars) + lower; } while (x == y); } @@ -839,27 +783,24 @@ cuddZddSwappingOutOfMem: } /* end of cuddZddSwapping */ -/**Function******************************************************************** +/** + @brief Implementation of Rudell's sifting algorithm. - Synopsis [Implementation of Rudell's sifting algorithm.] - - Description [Implementation of Rudell's sifting algorithm. - Assumes that no dead nodes are present. + @details Assumes that no dead nodes are present. <ol> <li> Order all the variables according to the number of entries in each unique table. <li> Sift the variable up and down, remembering each time the - total size of the DD heap. + total size of the %DD heap. <li> Select the best permutation. <li> Repeat 3 and 4 for all variables. </ol> - Returns 1 if successful; 0 otherwise.] - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int cuddZddSifting( DdManager * table, @@ -867,7 +808,7 @@ cuddZddSifting( int upper) { int i; - int *var; + IndexKey *var; int size; int x; int result; @@ -878,13 +819,7 @@ cuddZddSifting( size = table->sizeZ; /* Find order in which to sift variables. */ - var = NULL; - zdd_entry = ALLOC(int, size); - if (zdd_entry == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - goto cuddZddSiftingOutOfMem; - } - var = ALLOC(int, size); + var = ALLOC(IndexKey, size); if (var == NULL) { table->errorCode = CUDD_MEMORY_OUT; goto cuddZddSiftingOutOfMem; @@ -892,21 +827,26 @@ cuddZddSifting( for (i = 0; i < size; i++) { x = table->permZ[i]; - zdd_entry[i] = table->subtableZ[x].keys; - var[i] = i; + var[i].index = i; + var[i].keys = table->subtableZ[x].keys; } - cudd__qsort((void *)var, size, sizeof(int), (DD_QSFP)cuddZddUniqueCompare); + util_qsort(var, size, sizeof(IndexKey), cuddZddUniqueCompare); /* Now sift. */ for (i = 0; i < ddMin(table->siftMaxVar, size); i++) { - if (zddTotalNumberSwapping >= table->siftMaxSwap) + if (table->zddTotalNumberSwapping >= table->siftMaxSwap) break; if (util_cpu_time() - table->startTime > table->timeLimit) { table->autoDynZ = 0; /* prevent further reordering */ break; } - x = table->permZ[var[i]]; + if (table->terminationCallback != NULL && + table->terminationCallback(table->tcbArg)) { + table->autoDynZ = 0; /* prevent further reordering */ + break; + } + x = table->permZ[var[i].index]; if (x < lower || x > upper) continue; #ifdef DD_STATS previousSize = table->keysZ; @@ -919,7 +859,7 @@ cuddZddSifting( (void) fprintf(table->out,"-"); } else if (table->keysZ > (unsigned) previousSize) { (void) fprintf(table->out,"+"); /* should never happen */ - (void) fprintf(table->out,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keysZ , var[i]); + (void) fprintf(table->out,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keysZ , var[i].index); } else { (void) fprintf(table->out,"="); } @@ -928,13 +868,11 @@ cuddZddSifting( } FREE(var); - FREE(zdd_entry); return(1); cuddZddSiftingOutOfMem: - if (zdd_entry != NULL) FREE(zdd_entry); if (var != NULL) FREE(var); return(0); @@ -947,17 +885,14 @@ cuddZddSiftingOutOfMem: /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Swaps any two variables.] - - Description [Swaps any two variables. Returns the set of moves.] +/** + @brief Swaps any two variables. - SideEffects [None] + @return the set of moves. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static Move * zddSwapAny( DdManager * table, @@ -1100,20 +1035,17 @@ zddSwapAnyOutOfMem: } /* end of zddSwapAny */ -/**Function******************************************************************** +/** + @brief Given xLow <= x <= xHigh moves x up and down between the + boundaries. - Synopsis [Given xLow <= x <= xHigh moves x up and down between the - boundaries.] + @details Finds the best position and does the required changes. - Description [Given xLow <= x <= xHigh moves x up and down between the - boundaries. Finds the best position and does the required changes. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int cuddZddSiftingAux( DdManager * table, @@ -1221,19 +1153,17 @@ cuddZddSiftingAuxOutOfMem: } /* end of cuddZddSiftingAux */ -/**Function******************************************************************** - - Synopsis [Sifts a variable up.] +/** + @brief Sifts a variable up. - Description [Sifts a variable up. Moves y up until either it reaches - the bound (x_low) or the size of the ZDD heap increases too much. - Returns the set of moves in case of success; NULL if memory is full.] + @details Moves y up until either it reaches the bound (x_low) or the + size of the %ZDD heap increases too much. - SideEffects [None] + @return the set of moves in case of success; NULL if memory is full. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static Move * cuddZddSiftingUp( DdManager * table, @@ -1283,20 +1213,18 @@ cuddZddSiftingUpOutOfMem: } /* end of cuddZddSiftingUp */ -/**Function******************************************************************** - - Synopsis [Sifts a variable down.] +/** + @brief Sifts a variable down. - Description [Sifts a variable down. Moves x down until either it - reaches the bound (x_high) or the size of the ZDD heap increases too - much. Returns the set of moves in case of success; NULL if memory is - full.] + @details Moves x down until either it reaches the bound (x_high) or + the size of the %ZDD heap increases too much. - SideEffects [None] + @return the set of moves in case of success; NULL if memory is + full. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static Move * cuddZddSiftingDown( DdManager * table, @@ -1346,21 +1274,18 @@ cuddZddSiftingDownOutOfMem: } /* end of cuddZddSiftingDown */ -/**Function******************************************************************** +/** + @brief Given a set of moves, returns the %ZDD heap to the position + giving the minimum size. - Synopsis [Given a set of moves, returns the ZDD heap to the position - giving the minimum size.] + @details In case of ties, returns to the closest position giving the + minimum size. - Description [Given a set of moves, returns the ZDD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int cuddZddSiftingBackward( DdManager * table, @@ -1396,17 +1321,16 @@ cuddZddSiftingBackward( } /* end of cuddZddSiftingBackward */ -/**Function******************************************************************** - - Synopsis [Prepares the ZDD heap for dynamic reordering.] +/** + @brief Prepares the %ZDD heap for dynamic reordering. - Description [Prepares the ZDD heap for dynamic reordering. Does - garbage collection, to guarantee that there are no dead nodes; - and clears the cache, which is invalidated by dynamic reordering.] + @details Does garbage collection, to guarantee that there are no + dead nodes; and clears the cache, which is invalidated by dynamic + reordering. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static void zddReorderPreprocess( DdManager * table) @@ -1423,19 +1347,18 @@ zddReorderPreprocess( } /* end of ddReorderPreprocess */ -/**Function******************************************************************** +/** + @brief Shrinks almost empty %ZDD subtables at the end of reordering + to guarantee that they have a reasonable load factor. - Synopsis [Shrinks almost empty ZDD subtables at the end of reordering - to guarantee that they have a reasonable load factor.] + @details However, if there many nodes are being reclaimed, then no + resizing occurs. - Description [Shrinks almost empty subtables at the end of reordering to - guarantee that they have a reasonable load factor. However, if there many - nodes are being reclaimed, then no resizing occurs. Returns 1 in case of - success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int zddReorderPostprocess( DdManager * table) @@ -1468,7 +1391,7 @@ zddReorderPostprocess( oldnodelist = table->subtableZ[i].nodelist; slots = oldslots >> 1; saveHandler = MMoutOfMemory; - MMoutOfMemory = Cudd_OutOfMem; + MMoutOfMemory = table->outOfMemCallback; nodelist = ALLOC(DdNodePtr, slots); MMoutOfMemory = saveHandler; if (nodelist == NULL) { @@ -1516,21 +1439,19 @@ zddReorderPostprocess( } /* end of zddReorderPostprocess */ -/**Function******************************************************************** +/** + @brief Reorders %ZDD variables according to a given permutation. - Synopsis [Reorders ZDD variables according to a given permutation.] + @details The i-th permutation array contains the index of the + variable that should be brought to the i-th level. zddShuffle + assumes that no dead nodes are present. The reordering is achieved + by a series of upward sifts. - Description [Reorders ZDD variables according to a given permutation. - The i-th permutation array contains the index of the variable that - should be brought to the i-th level. zddShuffle assumes that no - dead nodes are present. The reordering is achieved by a series of - upward sifts. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int zddShuffle( DdManager * table, @@ -1548,7 +1469,7 @@ zddShuffle( int previousSize; #endif - zddTotalNumberSwapping = 0; + table->zddTotalNumberSwapping = 0; #ifdef DD_STATS localTime = util_cpu_time(); initialSize = table->keysZ; @@ -1585,7 +1506,7 @@ zddShuffle( (void) fprintf(table->out,"#:T_SHUFFLE %8g: total time (sec)\n", ((double)(util_cpu_time() - localTime)/1000.0)); (void) fprintf(table->out,"#:N_SHUFFLE %8d: total swaps\n", - zddTotalNumberSwapping); + table->zddTotalNumberSwapping); #endif return(1); @@ -1593,19 +1514,17 @@ zddShuffle( } /* end of zddShuffle */ -/**Function******************************************************************** - - Synopsis [Moves one ZDD variable up.] +/** + @brief Moves one %ZDD variable up. - Description [Takes a ZDD variable from position x and sifts it up to + @details Takes a %ZDD variable from position x and sifts it up to position xLow; xLow should be less than or equal to x. - Returns 1 if successful; 0 otherwise] - SideEffects [None] + @return 1 if successful; 0 otherwise - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int zddSiftUp( DdManager * table, @@ -1629,19 +1548,15 @@ zddSiftUp( } /* end of zddSiftUp */ -/**Function******************************************************************** - - Synopsis [Fixes the ZDD variable group tree after a shuffle.] - - Description [Fixes the ZDD variable group tree after a - shuffle. Assumes that the order of the variables in a terminal node - has not been changed.] +/** + @brief Fixes the %ZDD variable group tree after a shuffle. - SideEffects [Changes the ZDD variable group tree.] + @details Assumes that the order of the variables in a terminal node + has not been changed. - SeeAlso [] + @sideeffect Changes the %ZDD variable group tree. -******************************************************************************/ +*/ static void zddFixTree( DdManager * table, @@ -1649,7 +1564,7 @@ zddFixTree( { if (treenode == NULL) return; treenode->low = ((int) treenode->index < table->sizeZ) ? - table->permZ[treenode->index] : treenode->index; + (MtrHalfWord) table->permZ[treenode->index] : treenode->index; if (treenode->child != NULL) { zddFixTree(table, treenode->child); } diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddSetop.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddSetop.c similarity index 67% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddSetop.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddZddSetop.c index 18cce2c92..18172b80e 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddSetop.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddSetop.c @@ -1,45 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddZddSetop.c] - - PackageName [cudd] - - Synopsis [Set operations on ZDDs.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_zddIte() - <li> Cudd_zddUnion() - <li> Cudd_zddIntersect() - <li> Cudd_zddDiff() - <li> Cudd_zddDiffConst() - <li> Cudd_zddSubset1() - <li> Cudd_zddSubset0() - <li> Cudd_zddChange() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddIte() - <li> cuddZddUnion() - <li> cuddZddIntersect() - <li> cuddZddDiff() - <li> cuddZddChangeAux() - <li> cuddZddSubset1() - <li> cuddZddSubset0() - </ul> - Static procedures included in this module: - <ul> - <li> zdd_subset1_aux() - <li> zdd_subset0_aux() - <li> zddVarToConst() - </ul> - ] - - SeeAlso [] - - Author [Hyong-Kyoon Shin, In-Ho Moon] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Set operations on ZDDs. + + @author Hyong-Kyoon Shin, In-Ho Moon + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -69,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -95,19 +65,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddZddSetop.c,v 1.26 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -#ifdef __cplusplus -extern "C" { -#endif - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -117,29 +80,21 @@ static DdNode * zdd_subset1_aux (DdManager *zdd, DdNode *P, DdNode *zvar); static DdNode * zdd_subset0_aux (DdManager *zdd, DdNode *P, DdNode *zvar); static void zddVarToConst (DdNode *f, DdNode **gp, DdNode **hp, DdNode *base, DdNode *empty); -/**AutomaticEnd***************************************************************/ - -#ifdef __cplusplus -} -#endif +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Computes the ITE of three ZDDs. - Synopsis [Computes the ITE of three ZDDs.] + @return a pointer to the result if successful; NULL otherwise. - Description [Computes the ITE of three ZDDs. Returns a pointer to the - result if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ DdNode * Cudd_zddIte( DdManager * dd, @@ -153,23 +108,22 @@ Cudd_zddIte( dd->reordered = 0; res = cuddZddIte(dd, f, g, h); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddIte */ -/**Function******************************************************************** +/** + @brief Computes the union of two ZDDs. - Synopsis [Computes the union of two ZDDs.] + @return a pointer to the result if successful; NULL otherwise. - Description [Computes the union of two ZDDs. Returns a pointer to the - result if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ DdNode * Cudd_zddUnion( DdManager * dd, @@ -182,23 +136,22 @@ Cudd_zddUnion( dd->reordered = 0; res = cuddZddUnion(dd, P, Q); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddUnion */ -/**Function******************************************************************** +/** + @brief Computes the intersection of two ZDDs. - Synopsis [Computes the intersection of two ZDDs.] + @return a pointer to the result if successful; NULL otherwise. - Description [Computes the intersection of two ZDDs. Returns a pointer to - the result if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ DdNode * Cudd_zddIntersect( DdManager * dd, @@ -211,23 +164,22 @@ Cudd_zddIntersect( dd->reordered = 0; res = cuddZddIntersect(dd, P, Q); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddIntersect */ -/**Function******************************************************************** +/** + @brief Computes the difference of two ZDDs. - Synopsis [Computes the difference of two ZDDs.] + @return a pointer to the result if successful; NULL otherwise. - Description [Computes the difference of two ZDDs. Returns a pointer to the - result if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [Cudd_zddDiffConst] - -******************************************************************************/ +*/ DdNode * Cudd_zddDiff( DdManager * dd, @@ -240,24 +192,27 @@ Cudd_zddDiff( dd->reordered = 0; res = cuddZddDiff(dd, P, Q); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddDiff */ -/**Function******************************************************************** +/** + @brief Performs the inclusion test for ZDDs (P implies Q). - Synopsis [Performs the inclusion test for ZDDs (P implies Q).] + @details No new nodes are generated by this procedure. - Description [Inclusion test for ZDDs (P implies Q). No new nodes are - generated by this procedure. Returns empty if true; - a valid pointer different from empty or DD_NON_CONSTANT otherwise.] + @return empty if true; a valid pointer different from empty or + DD_NON_CONSTANT otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddDiff] + @see Cudd_zddDiff -******************************************************************************/ +*/ DdNode * Cudd_zddDiffConst( DdManager * zdd, @@ -308,20 +263,19 @@ Cudd_zddDiffConst( } /* end of Cudd_zddDiffConst */ -/**Function******************************************************************** +/** + @brief Computes the positive cofactor of a %ZDD w.r.t. a variable. - Synopsis [Computes the positive cofactor of a ZDD w.r.t. a variable.] + @details In terms of combinations, the result is the set of all + combinations in which the variable is asserted. - Description [Computes the positive cofactor of a ZDD w.r.t. a - variable. In terms of combinations, the result is the set of all - combinations in which the variable is asserted. Returns a pointer to - the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddSubset0] + @see Cudd_zddSubset0 -******************************************************************************/ +*/ DdNode * Cudd_zddSubset1( DdManager * dd, @@ -334,26 +288,28 @@ Cudd_zddSubset1( dd->reordered = 0; r = cuddZddSubset1(dd, P, var); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(r); } /* end of Cudd_zddSubset1 */ -/**Function******************************************************************** +/** + @brief Computes the negative cofactor of a %ZDD w.r.t. a variable. - Synopsis [Computes the negative cofactor of a ZDD w.r.t. a variable.] + @details In terms of combinations, the result is the set of all + combinations in which the variable is negated. - Description [Computes the negative cofactor of a ZDD w.r.t. a - variable. In terms of combinations, the result is the set of all - combinations in which the variable is negated. Returns a pointer to - the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddSubset1] + @see Cudd_zddSubset1 -******************************************************************************/ +*/ DdNode * Cudd_zddSubset0( DdManager * dd, @@ -366,24 +322,23 @@ Cudd_zddSubset0( dd->reordered = 0; r = cuddZddSubset0(dd, P, var); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(r); } /* end of Cudd_zddSubset0 */ -/**Function******************************************************************** - - Synopsis [Substitutes a variable with its complement in a ZDD.] +/** + @brief Substitutes a variable with its complement in a %ZDD. - Description [Substitutes a variable with its complement in a ZDD. - returns a pointer to the result if successful; NULL otherwise.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ DdNode * Cudd_zddChange( DdManager * dd, @@ -398,6 +353,9 @@ Cudd_zddChange( dd->reordered = 0; res = cuddZddChange(dd, P, var); } while (dd->reordered == 1); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddChange */ @@ -408,17 +366,12 @@ Cudd_zddChange( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddIte.] +/** + @brief Performs the recursive step of Cudd_zddIte. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ DdNode * cuddZddIte( DdManager * dd, @@ -428,8 +381,8 @@ cuddZddIte( { DdNode *tautology, *empty; DdNode *r,*Gv,*Gvn,*Hv,*Hvn,*t,*e; - unsigned int topf,topg,toph,v,top; - int index; + int topf,topg,toph,v,top; + unsigned int index; statLine(dd); /* Trivial cases. */ @@ -534,17 +487,12 @@ cuddZddIte( } /* end of cuddZddIte */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddUnion.] +/** + @brief Performs the recursive step of Cudd_zddUnion. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ DdNode * cuddZddUnion( DdManager * zdd, @@ -623,17 +571,12 @@ cuddZddUnion( } /* end of cuddZddUnion */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddIntersect.] +/** + @brief Performs the recursive step of Cudd_zddIntersect. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ DdNode * cuddZddIntersect( DdManager * zdd, @@ -698,17 +641,12 @@ cuddZddIntersect( } /* end of cuddZddIntersect */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddDiff.] +/** + @brief Performs the recursive step of Cudd_zddDiff. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ DdNode * cuddZddDiff( DdManager * zdd, @@ -780,17 +718,12 @@ cuddZddDiff( } /* end of cuddZddDiff */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddChange.] +/** + @brief Performs the recursive step of Cudd_zddChange. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ DdNode * cuddZddChangeAux( DdManager * zdd, @@ -849,23 +782,22 @@ cuddZddChangeAux( } /* end of cuddZddChangeAux */ -/**Function******************************************************************** +/** + @brief Computes the positive cofactor of a %ZDD w.r.t. a variable. - Synopsis [Computes the positive cofactor of a ZDD w.r.t. a variable.] + @details In terms of combinations, the result is the set of all + combinations in which the variable is asserted. cuddZddSubset1 + performs the same function as Cudd_zddSubset1, but does not restart + if reordering has taken place. Therefore it can be called from + within a recursive procedure. - Description [Computes the positive cofactor of a ZDD w.r.t. a - variable. In terms of combinations, the result is the set of all - combinations in which the variable is asserted. Returns a pointer to - the result if successful; NULL otherwise. cuddZddSubset1 performs - the same function as Cudd_zddSubset1, but does not restart if - reordering has taken place. Therefore it can be called from within a - recursive procedure.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddZddSubset0 Cudd_zddSubset1] + @see cuddZddSubset0 Cudd_zddSubset1 -******************************************************************************/ +*/ DdNode * cuddZddSubset1( DdManager * dd, @@ -898,23 +830,22 @@ cuddZddSubset1( } /* end of cuddZddSubset1 */ -/**Function******************************************************************** +/** + @brief Computes the negative cofactor of a %ZDD w.r.t. a variable. - Synopsis [Computes the negative cofactor of a ZDD w.r.t. a variable.] + @details In terms of combinations, the result is the set of all + combinations in which the variable is negated. cuddZddSubset0 + performs the same function as Cudd_zddSubset0, but does not restart + if reordering has taken place. Therefore it can be called from + within a recursive procedure. - Description [Computes the negative cofactor of a ZDD w.r.t. a - variable. In terms of combinations, the result is the set of all - combinations in which the variable is negated. Returns a pointer to - the result if successful; NULL otherwise. cuddZddSubset0 performs - the same function as Cudd_zddSubset0, but does not restart if - reordering has taken place. Therefore it can be called from within a - recursive procedure.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [cuddZddSubset1 Cudd_zddSubset0] + @see cuddZddSubset1 Cudd_zddSubset0 -******************************************************************************/ +*/ DdNode * cuddZddSubset0( DdManager * dd, @@ -947,22 +878,20 @@ cuddZddSubset0( } /* end of cuddZddSubset0 */ -/**Function******************************************************************** +/** + @brief Substitutes a variable with its complement in a %ZDD. - Synopsis [Substitutes a variable with its complement in a ZDD.] + @details cuddZddChange performs the same function as Cudd_zddChange, + but does not restart if reordering has taken place. Therefore it can + be called from within a recursive procedure. - Description [Substitutes a variable with its complement in a ZDD. - returns a pointer to the result if successful; NULL - otherwise. cuddZddChange performs the same function as - Cudd_zddChange, but does not restart if reordering has taken - place. Therefore it can be called from within a recursive - procedure.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddChange] + @see Cudd_zddChange -******************************************************************************/ +*/ DdNode * cuddZddChange( DdManager * dd, @@ -993,17 +922,12 @@ cuddZddChange( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddSubset1.] +/** + @brief Performs the recursive step of Cudd_zddSubset1. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static DdNode * zdd_subset1_aux( DdManager * zdd, @@ -1062,17 +986,12 @@ zdd_subset1_aux( } /* end of zdd_subset1_aux */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddSubset0.] +/** + @brief Performs the recursive step of Cudd_zddSubset0. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static DdNode * zdd_subset0_aux( DdManager * zdd, @@ -1131,18 +1050,13 @@ zdd_subset0_aux( } /* end of zdd_subset0_aux */ -/**Function******************************************************************** - - Synopsis [Replaces variables with constants if possible (part of - canonical form).] - - Description [] - - SideEffects [None] +/** + @brief Replaces variables with constants if possible (part of + canonical form). - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static void zddVarToConst( DdNode * f, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddSymm.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddSymm.c similarity index 80% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddSymm.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddZddSymm.c index 93ddd3997..3ebdd0e9d 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddSymm.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddSymm.c @@ -1,39 +1,16 @@ -/**CFile*********************************************************************** - - FileName [cuddZddSymm.c] - - PackageName [cudd] - - Synopsis [Functions for symmetry-based ZDD variable reordering.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_zddSymmProfile() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddSymmCheck() - <li> cuddZddSymmSifting() - <li> cuddZddSymmSiftingConv() - </ul> - Static procedures included in this module: - <ul> - <li> cuddZddUniqueCompare() - <li> cuddZddSymmSiftingAux() - <li> cuddZddSymmSiftingConvAux() - <li> cuddZddSymmSifting_up() - <li> cuddZddSymmSifting_down() - <li> zdd_group_move() - <li> cuddZddSymmSiftingBackward() - <li> zdd_group_move_backward() - </ul> - ] - - SeeAlso [cuddSymmetry.c] - - Author [Hyong-Kyoon Shin, In-Ho Moon] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Functions for symmetry-based %ZDD variable reordering. + + @see cuddSymmetry.c + + @author Hyong-Kyoon Shin, In-Ho Moon + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -63,13 +40,13 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" -#include "ucbqsort.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ @@ -89,22 +66,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddZddSymm.c,v 1.31 2012/02/05 01:07:19 fabio Exp $"; -#endif - -extern int *zdd_entry; - -extern int zddTotalNumberSwapping; - -static DdNode *empty; /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -119,7 +86,7 @@ static int zdd_group_move (DdManager *table, int x, int y, Move **moves); static int zdd_group_move_backward (DdManager *table, int x, int y); static void cuddZddSymmSummary (DdManager *table, int lower, int upper, int *symvars, int *symgroups); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -127,17 +94,12 @@ static void cuddZddSymmSummary (DdManager *table, int lower, int upper, int *sym /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Prints statistics on symmetric ZDD variables.] +/** + @brief Prints statistics on symmetric %ZDD variables. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ void Cudd_zddSymmProfile( DdManager * table, @@ -177,19 +139,16 @@ Cudd_zddSymmProfile( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Checks for symmetry of x and y.] +/** + @brief Checks for symmetry of x and y. - Description [Checks for symmetry of x and y. Ignores projection - functions, unless they are isolated. Returns 1 in case of - symmetry; 0 otherwise.] + @details Ignores projection functions, unless they are isolated. - SideEffects [None] + @return 1 in case of symmetry; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int cuddZddSymmCheck( DdManager * table, @@ -204,8 +163,7 @@ cuddZddSymmCheck( int arccount = 0; int TotalRefCount = 0; int symm_found; - - empty = table->zero; + DdNode *empty = table->zero; yindex = table->invpermZ[y]; for (i = table->subtableZ[x].slots - 1; i >= 0; i--) { @@ -273,28 +231,27 @@ cuddZddSymmCheck( } /* end cuddZddSymmCheck */ -/**Function******************************************************************** - - Synopsis [Symmetric sifting algorithm for ZDDs.] +/** + @brief Symmetric sifting algorithm for ZDDs. - Description [Symmetric sifting algorithm. - Assumes that no dead nodes are present. + @details Assumes that no dead nodes are present. <ol> <li> Order all the variables according to the number of entries in each unique subtable. <li> Sift the variable up and down, remembering each time the total - size of the ZDD heap and grouping variables that are symmetric. + size of the %ZDD heap and grouping variables that are symmetric. <li> Select the best permutation. <li> Repeat 3 and 4 for all variables. </ol> - Returns 1 plus the number of symmetric variables if successful; 0 - otherwise.] - SideEffects [None] + @return 1 plus the number of symmetric variables if successful; 0 + otherwise. - SeeAlso [cuddZddSymmSiftingConv] + @sideeffect None -******************************************************************************/ + @see cuddZddSymmSiftingConv + +*/ int cuddZddSymmSifting( DdManager * table, @@ -302,7 +259,7 @@ cuddZddSymmSifting( int upper) { int i; - int *var; + IndexKey *var; int nvars; int x; int result; @@ -316,13 +273,7 @@ cuddZddSymmSifting( nvars = table->sizeZ; /* Find order in which to sift variables. */ - var = NULL; - zdd_entry = ALLOC(int, nvars); - if (zdd_entry == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - goto cuddZddSymmSiftingOutOfMem; - } - var = ALLOC(int, nvars); + var = ALLOC(IndexKey, nvars); if (var == NULL) { table->errorCode = CUDD_MEMORY_OUT; goto cuddZddSymmSiftingOutOfMem; @@ -330,11 +281,11 @@ cuddZddSymmSifting( for (i = 0; i < nvars; i++) { x = table->permZ[i]; - zdd_entry[i] = table->subtableZ[x].keys; - var[i] = i; + var[i].index = i; + var[i].keys = table->subtableZ[x].keys; } - cudd__qsort((void *)var, nvars, sizeof(int), (DD_QSFP)cuddZddUniqueCompare); + util_qsort(var, nvars, sizeof(IndexKey), cuddZddUniqueCompare); /* Initialize the symmetry of each subtable to itself. */ for (i = lower; i <= upper; i++) @@ -342,13 +293,18 @@ cuddZddSymmSifting( iteration = ddMin(table->siftMaxVar, nvars); for (i = 0; i < iteration; i++) { - if (zddTotalNumberSwapping >= table->siftMaxSwap) + if (table->zddTotalNumberSwapping >= table->siftMaxSwap) break; if (util_cpu_time() - table->startTime > table->timeLimit) { table->autoDynZ = 0; /* prevent further reordering */ break; } - x = table->permZ[var[i]]; + if (table->terminationCallback != NULL && + table->terminationCallback(table->tcbArg)) { + table->autoDynZ = 0; /* prevent further reordering */ + break; + } + x = table->permZ[var[i].index]; #ifdef DD_STATS previousSize = table->keysZ; #endif @@ -363,7 +319,7 @@ cuddZddSymmSifting( } else if (table->keysZ > (unsigned) previousSize) { (void) fprintf(table->out,"+"); #ifdef DD_VERBOSE - (void) fprintf(table->out,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keysZ, var[i]); + (void) fprintf(table->out,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keysZ, var[i].index); #endif } else { (void) fprintf(table->out,"="); @@ -374,7 +330,6 @@ cuddZddSymmSifting( } FREE(var); - FREE(zdd_entry); cuddZddSymmSummary(table, lower, upper, &symvars, &symgroups); @@ -387,8 +342,6 @@ cuddZddSymmSifting( cuddZddSymmSiftingOutOfMem: - if (zdd_entry != NULL) - FREE(zdd_entry); if (var != NULL) FREE(var); @@ -397,29 +350,28 @@ cuddZddSymmSiftingOutOfMem: } /* end of cuddZddSymmSifting */ -/**Function******************************************************************** - - Synopsis [Symmetric sifting to convergence algorithm for ZDDs.] +/** + @brief Symmetric sifting to convergence algorithm for ZDDs. - Description [Symmetric sifting to convergence algorithm for ZDDs. - Assumes that no dead nodes are present. + @details Assumes that no dead nodes are present. <ol> <li> Order all the variables according to the number of entries in each unique subtable. <li> Sift the variable up and down, remembering each time the total - size of the ZDD heap and grouping variables that are symmetric. + size of the %ZDD heap and grouping variables that are symmetric. <li> Select the best permutation. <li> Repeat 3 and 4 for all variables. <li> Repeat 1-4 until no further improvement. </ol> - Returns 1 plus the number of symmetric variables if successful; 0 - otherwise.] - SideEffects [None] + @return 1 plus the number of symmetric variables if successful; 0 + otherwise. - SeeAlso [cuddZddSymmSifting] + @sideeffect None -******************************************************************************/ + @see cuddZddSymmSifting + +*/ int cuddZddSymmSiftingConv( DdManager * table, @@ -427,7 +379,7 @@ cuddZddSymmSiftingConv( int upper) { int i; - int *var; + IndexKey *var; int nvars; int initialSize; int x; @@ -445,13 +397,7 @@ cuddZddSymmSiftingConv( nvars = table->sizeZ; /* Find order in which to sift variables. */ - var = NULL; - zdd_entry = ALLOC(int, nvars); - if (zdd_entry == NULL) { - table->errorCode = CUDD_MEMORY_OUT; - goto cuddZddSymmSiftingConvOutOfMem; - } - var = ALLOC(int, nvars); + var = ALLOC(IndexKey, nvars); if (var == NULL) { table->errorCode = CUDD_MEMORY_OUT; goto cuddZddSymmSiftingConvOutOfMem; @@ -459,11 +405,11 @@ cuddZddSymmSiftingConv( for (i = 0; i < nvars; i++) { x = table->permZ[i]; - zdd_entry[i] = table->subtableZ[x].keys; - var[i] = i; + var[i].index = i; + var[i].keys = table->subtableZ[x].keys; } - cudd__qsort((void *)var, nvars, sizeof(int), (DD_QSFP)cuddZddUniqueCompare); + util_qsort(var, nvars, sizeof(IndexKey), cuddZddUniqueCompare); /* Initialize the symmetry of each subtable to itself ** for first pass of converging symmetric sifting. @@ -473,13 +419,18 @@ cuddZddSymmSiftingConv( iteration = ddMin(table->siftMaxVar, table->sizeZ); for (i = 0; i < iteration; i++) { - if (zddTotalNumberSwapping >= table->siftMaxSwap) + if (table->zddTotalNumberSwapping >= table->siftMaxSwap) break; if (util_cpu_time() - table->startTime > table->timeLimit) { table->autoDynZ = 0; /* prevent further reordering */ break; } - x = table->permZ[var[i]]; + if (table->terminationCallback != NULL && + table->terminationCallback(table->tcbArg)) { + table->autoDynZ = 0; /* prevent further reordering */ + break; + } + x = table->permZ[var[i].index]; if (x < lower || x > upper) continue; /* Only sift if not in symmetry group already. */ if (table->subtableZ[x].next == (unsigned) x) { @@ -495,7 +446,7 @@ cuddZddSymmSiftingConv( } else if (table->keysZ > (unsigned) previousSize) { (void) fprintf(table->out,"+"); #ifdef DD_VERBOSE - (void) fprintf(table->out,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keysZ, var[i]); + (void) fprintf(table->out,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keysZ, var[i].index); #endif } else { (void) fprintf(table->out,"="); @@ -520,22 +471,27 @@ cuddZddSymmSiftingConv( ** Hence, the next increment of x will move it to a new group. */ i = table->invpermZ[x]; - zdd_entry[i] = table->subtableZ[x].keys; - var[classes] = i; + var[classes].index = i; + var[classes].keys = table->subtableZ[x].keys; } - cudd__qsort((void *)var,classes,sizeof(int),(DD_QSFP)cuddZddUniqueCompare); + util_qsort(var,classes,sizeof(IndexKey),cuddZddUniqueCompare); /* Now sift. */ iteration = ddMin(table->siftMaxVar, nvars); for (i = 0; i < iteration; i++) { - if (zddTotalNumberSwapping >= table->siftMaxSwap) + if (table->zddTotalNumberSwapping >= table->siftMaxSwap) break; if (util_cpu_time() - table->startTime > table->timeLimit) { table->autoDynZ = 0; /* prevent further reordering */ break; } - x = table->permZ[var[i]]; + if (table->terminationCallback != NULL && + table->terminationCallback(table->tcbArg)) { + table->autoDynZ = 0; /* prevent further reordering */ + break; + } + x = table->permZ[var[i].index]; if ((unsigned) x >= table->subtableZ[x].next) { #ifdef DD_STATS previousSize = table->keysZ; @@ -549,7 +505,7 @@ cuddZddSymmSiftingConv( } else if (table->keysZ > (unsigned) previousSize) { (void) fprintf(table->out,"+"); #ifdef DD_VERBOSE - (void) fprintf(table->out,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keysZ, var[i]); + (void) fprintf(table->out,"\nSize increased from %d to %d while sifting variable %d\n", previousSize, table->keysZ, var[i].index); #endif } else { (void) fprintf(table->out,"="); @@ -570,14 +526,11 @@ cuddZddSymmSiftingConv( #endif FREE(var); - FREE(zdd_entry); return(1+symvars); cuddZddSymmSiftingConvOutOfMem: - if (zdd_entry != NULL) - FREE(zdd_entry); if (var != NULL) FREE(var); @@ -591,21 +544,18 @@ cuddZddSymmSiftingConvOutOfMem: /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Given x_low <= x <= x_high moves x up and down between the - boundaries.] +/** + @brief Given x_low <= x <= x_high moves x up and down between the + boundaries. - Description [Given x_low <= x <= x_high moves x up and down between the - boundaries. Finds the best position and does the required changes. - Assumes that x is not part of a symmetry group. Returns 1 if - successful; 0 otherwise.] + @details Finds the best position and does the required changes. + Assumes that x is not part of a symmetry group. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int cuddZddSymmSiftingAux( DdManager * table, @@ -930,22 +880,20 @@ cuddZddSymmSiftingAuxOutOfMem: } /* end of cuddZddSymmSiftingAux */ -/**Function******************************************************************** - - Synopsis [Given x_low <= x <= x_high moves x up and down between the - boundaries.] +/** + @brief Given x_low <= x <= x_high moves x up and down between the + boundaries. - Description [Given x_low <= x <= x_high moves x up and down between the - boundaries. Finds the best position and does the required changes. + @details Finds the best position and does the required changes. Assumes that x is either an isolated variable, or it is the bottom of a symmetry group. All symmetries may not have been found, because of - exceeded growth limit. Returns 1 if successful; 0 otherwise.] + exceeded growth limit. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int cuddZddSymmSiftingConvAux( DdManager * table, @@ -1238,23 +1186,21 @@ cuddZddSymmSiftingConvAuxOutOfMem: } /* end of cuddZddSymmSiftingConvAux */ -/**Function******************************************************************** +/** + @brief Moves x up until either it reaches the bound (x_low) or + the size of the %ZDD heap increases too much. - Synopsis [Moves x up until either it reaches the bound (x_low) or - the size of the ZDD heap increases too much.] + @details Assumes that x is the top of a symmetry group. Checks x + for symmetry to the adjacent variables. If symmetry is found, the + symmetry group of x is merged with the symmetry group of the other + variable. - Description [Moves x up until either it reaches the bound (x_low) or - the size of the ZDD heap increases too much. Assumes that x is the top - of a symmetry group. Checks x for symmetry to the adjacent - variables. If symmetry is found, the symmetry group of x is merged - with the symmetry group of the other variable. Returns the set of - moves in case of success; ZDD_MV_OOM if memory is full.] + @return the set of moves in case of success; ZDD_MV_OOM if memory is + full. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static Move * cuddZddSymmSifting_up( DdManager * table, @@ -1326,23 +1272,21 @@ cuddZddSymmSifting_upOutOfMem: } /* end of cuddZddSymmSifting_up */ -/**Function******************************************************************** - - Synopsis [Moves x down until either it reaches the bound (x_high) or - the size of the ZDD heap increases too much.] +/** + @brief Moves x down until either it reaches the bound (x_high) or + the size of the %ZDD heap increases too much. - Description [Moves x down until either it reaches the bound (x_high) - or the size of the ZDD heap increases too much. Assumes that x is the - bottom of a symmetry group. Checks x for symmetry to the adjacent - variables. If symmetry is found, the symmetry group of x is merged - with the symmetry group of the other variable. Returns the set of - moves in case of success; ZDD_MV_OOM if memory is full.] + @details Assumes that x is the bottom of a symmetry group. Checks x + for symmetry to the adjacent variables. If symmetry is found, the + symmetry group of x is merged with the symmetry group of the other + variable. - SideEffects [None] + @return the set of moves in case of success; ZDD_MV_OOM if memory is + full. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static Move * cuddZddSymmSifting_down( DdManager * table, @@ -1391,8 +1335,6 @@ cuddZddSymmSifting_down( return(moves); if (size < limit_size) limit_size = size; - x = y; - y = cuddZddNextHigh(table, x); } else { /* Group move */ size = zdd_group_move(table, x, y, &moves); @@ -1419,21 +1361,18 @@ cuddZddSymmSifting_downOutOfMem: } /* end of cuddZddSymmSifting_down */ -/**Function******************************************************************** +/** + @brief Given a set of moves, returns the %ZDD heap to the position + giving the minimum size. - Synopsis [Given a set of moves, returns the ZDD heap to the position - giving the minimum size.] + @details In case of ties, returns to the closest position giving the + minimum size. - Description [Given a set of moves, returns the ZDD heap to the - position giving the minimum size. In case of ties, returns to the - closest position giving the minimum size. Returns 1 in case of - success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int cuddZddSymmSiftingBackward( DdManager * table, @@ -1472,20 +1411,18 @@ cuddZddSymmSiftingBackward( } /* end of cuddZddSymmSiftingBackward */ -/**Function******************************************************************** - - Synopsis [Swaps two groups.] +/** + @brief Swaps two groups. - Description [Swaps two groups. x is assumed to be the bottom variable - of the first group. y is assumed to be the top variable of the second - group. Updates the list of moves. Returns the number of keys in the - table if successful; 0 otherwise.] + @details x is assumed to be the bottom variable of the first + group. y is assumed to be the top variable of the second group. + Updates the list of moves. - SideEffects [None] + @return the number of keys in the table if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int zdd_group_move( DdManager * table, @@ -1496,7 +1433,7 @@ zdd_group_move( Move *move; int size; int i, temp, gxtop, gxbot, gybot, yprev; - int swapx, swapy; + int swapx = 0, swapy = 0; #ifdef DD_DEBUG assert(x < y); /* we assume that x < y */ @@ -1547,9 +1484,7 @@ zdd_group_move( } /* while y > gxtop */ /* Trying to find the next y. */ - if (table->subtableZ[y].next <= (unsigned) y) { - gybot = y; - } else { + if (table->subtableZ[y].next > (unsigned) y) { y = table->subtableZ[y].next; } @@ -1580,26 +1515,24 @@ zdd_group_moveOutOfMem: } /* end of zdd_group_move */ -/**Function******************************************************************** - - Synopsis [Undoes the swap of two groups.] +/** + @brief Undoes the swap of two groups. - Description [Undoes the swap of two groups. x is assumed to be the - bottom variable of the first group. y is assumed to be the top - variable of the second group. Returns 1 if successful; 0 otherwise.] + @details x is assumed to be the bottom variable of the first + group. y is assumed to be the top variable of the second group. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int zdd_group_move_backward( DdManager * table, int x, int y) { - int size; + int size = table->keysZ; int i, temp, gxtop, gxbot, gybot, yprev; #ifdef DD_DEBUG @@ -1649,9 +1582,7 @@ zdd_group_move_backward( } /* while y > gxtop */ /* Trying to find the next y. */ - if (table->subtableZ[y].next <= (unsigned) y) { - gybot = y; - } else { + if (table->subtableZ[y].next > (unsigned) y) { y = table->subtableZ[y].next; } @@ -1666,16 +1597,12 @@ zdd_group_move_backward( } /* end of zdd_group_move_backward */ -/**Function******************************************************************** - - Synopsis [Counts numbers of symmetric variables and symmetry - groups.] - - Description [] +/** + @brief Counts numbers of symmetric variables and symmetry groups. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static void cuddZddSymmSummary( DdManager * table, diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddUtil.c b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddUtil.c similarity index 70% rename from resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddUtil.c rename to resources/3rdparty/cudd-3.0.0/cudd/cuddZddUtil.c index aecb93ee4..3efb7fe4c 100644 --- a/resources/3rdparty/cudd-2.5.0/src/cudd/cuddZddUtil.c +++ b/resources/3rdparty/cudd-3.0.0/cudd/cuddZddUtil.c @@ -1,41 +1,14 @@ -/**CFile*********************************************************************** - - FileName [cuddZddUtil.c] - - PackageName [cudd] - - Synopsis [Utility functions for ZDDs.] - - Description [External procedures included in this module: - <ul> - <li> Cudd_zddPrintMinterm() - <li> Cudd_zddPrintCover() - <li> Cudd_zddPrintDebug() - <li> Cudd_zddFirstPath() - <li> Cudd_zddNextPath() - <li> Cudd_zddCoverPathToString() - <li> Cudd_zddSupport() - <li> Cudd_zddDumpDot() - </ul> - Internal procedures included in this module: - <ul> - <li> cuddZddP() - </ul> - Static procedures included in this module: - <ul> - <li> zp2() - <li> zdd_print_minterm_aux() - <li> zddPrintCoverAux() - <li> zddSupportStep() - <li> zddClearFlag() - </ul> - ] - - SeeAlso [] - - Author [Hyong-Kyoon Shin, In-Ho Moon, Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado +/** + @file + + @ingroup cudd + + @brief Utility functions for ZDDs. + + @author Hyong-Kyoon Shin, In-Ho Moon, Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -65,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "cuddInt.h" @@ -91,16 +65,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] DD_UNUSED = "$Id: cuddZddUtil.c,v 1.29 2012/02/05 01:07:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ - -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -112,7 +82,7 @@ static void zddPrintCoverAux (DdManager *zdd, DdNode *node, int level, int *list static void zddSupportStep(DdNode * f, int * support); static void zddClearFlag(DdNode * f); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ @@ -120,18 +90,16 @@ static void zddClearFlag(DdNode * f); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Prints a disjoint sum of product form for a ZDD.] +/** + @brief Prints a disjoint sum of product form for a %ZDD. - Description [Prints a disjoint sum of product form for a ZDD. Returns 1 - if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddPrintDebug Cudd_zddPrintCover] + @see Cudd_zddPrintDebug Cudd_zddPrintCover -******************************************************************************/ +*/ int Cudd_zddPrintMinterm( DdManager * zdd, @@ -154,18 +122,16 @@ Cudd_zddPrintMinterm( } /* end of Cudd_zddPrintMinterm */ -/**Function******************************************************************** +/** + @brief Prints a sum of products from a %ZDD representing a cover. - Synopsis [Prints a sum of products from a ZDD representing a cover.] + @return 1 if successful; 0 otherwise. - Description [Prints a sum of products from a ZDD representing a cover. - Returns 1 if successful; 0 otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_zddPrintMinterm - SeeAlso [Cudd_zddPrintMinterm] - -******************************************************************************/ +*/ int Cudd_zddPrintCover( DdManager * zdd, @@ -189,14 +155,12 @@ Cudd_zddPrintCover( } /* end of Cudd_zddPrintCover */ -/**Function******************************************************************** - - Synopsis [Prints to the standard output a ZDD and its statistics.] +/** + @brief Prints to the standard output a %ZDD and its statistics. - Description [Prints to the standard output a DD and its statistics. - The statistics include the number of nodes and the number of minterms. - (The number of minterms is also the number of combinations in the set.) - The statistics are printed if pr > 0. Specifically: + @details The statistics include the number of nodes and the number of + minterms. (The number of minterms is also the number of combinations + in the set.) The statistics are printed if pr > 0. Specifically: <ul> <li> pr = 0 : prints nothing <li> pr = 1 : prints counts of nodes and minterms @@ -204,14 +168,12 @@ Cudd_zddPrintCover( <li> pr = 3 : prints counts + list of nodes <li> pr > 3 : prints counts + disjoint sum of products + list of nodes </ul> - Returns 1 if successful; 0 otherwise. - ] - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Cudd_zddPrintDebug( DdManager * zdd, @@ -251,27 +213,27 @@ Cudd_zddPrintDebug( -/**Function******************************************************************** +/** + @brief Finds the first path of a %ZDD. - Synopsis [Finds the first path of a ZDD.] - - Description [Defines an iterator on the paths of a ZDD - and finds its first path. Returns a generator that contains the - information necessary to continue the enumeration if successful; NULL - otherwise.<p> + @details Defines an iterator on the paths of a %ZDD and finds its first + path.<p> A path is represented as an array of literals, which are integers in {0, 1, 2}; 0 represents an else arc out of a node, 1 represents a then arc out of a node, and 2 stands for the absence of a node. The size of the array equals the number of variables in the manager at the time Cudd_zddFirstCube is called.<p> - The paths that end in the empty terminal are not enumerated.] + The paths that end in the empty terminal are not enumerated. + + @return a generator that contains the information necessary to + continue the enumeration if successful; NULL otherwise. - SideEffects [The first path is returned as a side effect.] + @sideeffect The first path is returned as a side effect. - SeeAlso [Cudd_zddForeachPath Cudd_zddNextPath Cudd_GenFree - Cudd_IsGenEmpty] + @see Cudd_zddForeachPath Cudd_zddNextPath Cudd_GenFree + Cudd_IsGenEmpty -******************************************************************************/ +*/ DdGen * Cudd_zddFirstPath( DdManager * zdd, @@ -369,21 +331,21 @@ done: } /* end of Cudd_zddFirstPath */ -/**Function******************************************************************** +/** + @brief Generates the next path of a %ZDD. - Synopsis [Generates the next path of a ZDD.] + @details Generates the next path of a %ZDD onset, using generator + gen. - Description [Generates the next path of a ZDD onset, - using generator gen. Returns 0 if the enumeration is completed; 1 - otherwise.] + @return 0 if the enumeration is completed; 1 otherwise. - SideEffects [The path is returned as a side effect. The - generator is modified.] + @sideeffect The path is returned as a side effect. The generator is + modified. - SeeAlso [Cudd_zddForeachPath Cudd_zddFirstPath Cudd_GenFree - Cudd_IsGenEmpty] + @see Cudd_zddForeachPath Cudd_zddFirstPath Cudd_GenFree + Cudd_IsGenEmpty -******************************************************************************/ +*/ int Cudd_zddNextPath( DdGen * gen, @@ -456,27 +418,26 @@ done: } /* end of Cudd_zddNextPath */ -/**Function******************************************************************** +/** + @brief Converts a path of a %ZDD representing a cover to a string. - Synopsis [Converts a path of a ZDD representing a cover to a string.] + @details The string represents an implicant of the cover. The path + is typically produced by Cudd_zddForeachPath. If the str input is + NULL, it allocates a new string. The string passed to this function + must have enough room for all variables and for the terminator. - Description [Converts a path of a ZDD representing a cover to a - string. The string represents an implicant of the cover. The path - is typically produced by Cudd_zddForeachPath. Returns a pointer to - the string if successful; NULL otherwise. If the str input is NULL, - it allocates a new string. The string passed to this function must - have enough room for all variables and for the terminator.] + @return a pointer to the string if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddForeachPath] + @see Cudd_zddForeachPath -******************************************************************************/ +*/ char * Cudd_zddCoverPathToString( - DdManager *zdd /* DD manager */, - int *path /* path of ZDD representing a cover */, - char *str /* pointer to string to use if != NULL */ + DdManager *zdd /**< %DD manager */, + int *path /**< path of %ZDD representing a cover */, + char *str /**< pointer to string to use if != NULL */ ) { int nvars = zdd->sizeZ; @@ -519,23 +480,21 @@ Cudd_zddCoverPathToString( } /* end of Cudd_zddCoverPathToString */ -/**Function******************************************************************** +/** + @brief Finds the variables on which a %ZDD depends. - Synopsis [Finds the variables on which a ZDD depends.] + @return a %BDD consisting of the product of the variables if + successful; NULL otherwise. - Description [Finds the variables on which a ZDD depends. - Returns a BDD consisting of the product of the variables if - successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see Cudd_Support - SeeAlso [Cudd_Support] - -******************************************************************************/ +*/ DdNode * Cudd_zddSupport( - DdManager * dd /* manager */, - DdNode * f /* ZDD whose support is sought */) + DdManager * dd /**< manager */, + DdNode * f /**< %ZDD whose support is sought */) { int *support; DdNode *res, *tmp, *var; @@ -587,19 +546,19 @@ Cudd_zddSupport( FREE(support); if (res != NULL) cuddDeref(res); + if (dd->errorCode == CUDD_TIMEOUT_EXPIRED && dd->timeoutHandler) { + dd->timeoutHandler(dd, dd->tohArg); + } return(res); } /* end of Cudd_zddSupport */ -/**Function******************************************************************** +/** + @brief Writes a dot file representing the argument ZDDs. - Synopsis [Writes a dot file representing the argument ZDDs.] - - Description [Writes a file representing the argument ZDDs in a format + @details Writes a file representing the argument ZDDs in a format suitable for the graph drawing program dot. - It returns 1 in case of success; 0 otherwise (e.g., out-of-memory, - file system full). Cudd_zddDumpDot does not close the file: This is the caller responsibility. Cudd_zddDumpDot uses a minimal unique subset of the hexadecimal address of a node as name for it. @@ -612,21 +571,23 @@ Cudd_zddSupport( </ul> The dot options are chosen so that the drawing fits on a letter-size sheet. - ] + + @return 1 in case of success; 0 otherwise (e.g., out-of-memory, file + system full). - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_DumpDot Cudd_zddPrintDebug] + @see Cudd_DumpDot Cudd_zddPrintDebug -******************************************************************************/ +*/ int Cudd_zddDumpDot( - DdManager * dd /* manager */, - int n /* number of output nodes to be dumped */, - DdNode ** f /* array of output nodes to be dumped */, - char ** inames /* array of input names (or NULL) */, - char ** onames /* array of output names (or NULL) */, - FILE * fp /* pointer to the dump file */) + DdManager * dd /**< manager */, + int n /**< number of output nodes to be dumped */, + DdNode ** f /**< array of output nodes to be dumped */, + char const * const * inames /**< array of input names (or NULL) */, + char const * const * onames /**< array of output names (or NULL) */, + FILE * fp /**< pointer to the dump file */) { DdNode *support = NULL; DdNode *scan; @@ -638,7 +599,7 @@ Cudd_zddDumpDot( int i, j; int slots; DdNodePtr *nodelist; - long refAddr, diff, mask; + ptruint refAddr, diff, mask = 0; /* Build a bit array with the support of f. */ sorted = ALLOC(int,nvars); @@ -684,17 +645,17 @@ Cudd_zddDumpDot( */ /* Find the bits that are different. */ - refAddr = (long) f[0]; + refAddr = (ptruint) f[0]; diff = 0; gen = st_init_gen(visited); - while (st_gen(gen, &scan, NULL)) { - diff |= refAddr ^ (long) scan; + while (st_gen(gen, (void **) &scan, NULL)) { + diff |= refAddr ^ (ptruint) scan; } st_free_gen(gen); /* Choose the mask. */ - for (i = 0; (unsigned) i < 8 * sizeof(long); i += 4) { - mask = (1 << i) - 1; + for (i = 0; (unsigned) i < 8 * sizeof(ptruint); i += 4) { + mask = ((ptruint) 1 << i) - 1; if (diff <= mask) break; } @@ -762,9 +723,9 @@ Cudd_zddDumpDot( for (j = 0; j < slots; j++) { scan = nodelist[j]; while (scan != NULL) { - if (st_is_member(visited,(char *) scan)) { - retval = fprintf(fp,"\"%p\";\n", (void *) - ((mask & (ptrint) scan) / + if (st_is_member(visited,scan)) { + retval = fprintf(fp,"\"%#" PRIxPTR "\";\n", + ((mask & (ptruint) scan) / sizeof(DdNode))); if (retval == EOF) goto failure; } @@ -785,9 +746,9 @@ Cudd_zddDumpDot( for (j = 0; j < slots; j++) { scan = nodelist[j]; while (scan != NULL) { - if (st_is_member(visited,(char *) scan)) { - retval = fprintf(fp,"\"%p\";\n", (void *) - ((mask & (ptrint) scan) / sizeof(DdNode))); + if (st_is_member(visited,scan)) { + retval = fprintf(fp,"\"%#" PRIxPTR "\";\n", + ((mask & (ptruint) scan) / sizeof(DdNode))); if (retval == EOF) goto failure; } scan = scan->next; @@ -805,9 +766,8 @@ Cudd_zddDumpDot( retval = fprintf(fp,"\" %s \"", onames[i]); } if (retval == EOF) goto failure; - retval = fprintf(fp," -> \"%p\" [style = solid];\n", - (void *) ((mask & (ptrint) f[i]) / - sizeof(DdNode))); + retval = fprintf(fp," -> \"%#" PRIxPTR "\" [style = solid];\n", + ((mask & (ptruint) f[i]) / sizeof(DdNode))); if (retval == EOF) goto failure; } @@ -819,20 +779,19 @@ Cudd_zddDumpDot( for (j = 0; j < slots; j++) { scan = nodelist[j]; while (scan != NULL) { - if (st_is_member(visited,(char *) scan)) { + if (st_is_member(visited,scan)) { retval = fprintf(fp, - "\"%p\" -> \"%p\";\n", - (void *) ((mask & (ptrint) scan) / sizeof(DdNode)), - (void *) ((mask & (ptrint) cuddT(scan)) / - sizeof(DdNode))); + "\"%#" PRIxPTR "\" -> \"%#" PRIxPTR "\";\n", + ((mask & (ptruint) scan) / sizeof(DdNode)), + ((mask & (ptruint) cuddT(scan)) / sizeof(DdNode))); if (retval == EOF) goto failure; retval = fprintf(fp, - "\"%p\" -> \"%p\" [style = dashed];\n", - (void *) ((mask & (ptrint) scan) - / sizeof(DdNode)), - (void *) ((mask & (ptrint) - cuddE(scan)) / - sizeof(DdNode))); + "\"%#" PRIxPTR "\" -> \"%#" PRIxPTR + "\" [style = dashed];\n", + ((mask & (ptruint) scan) / + sizeof(DdNode)), + ((mask & (ptruint) cuddE(scan)) / + sizeof(DdNode))); if (retval == EOF) goto failure; } scan = scan->next; @@ -847,10 +806,9 @@ Cudd_zddDumpDot( for (j = 0; j < slots; j++) { scan = nodelist[j]; while (scan != NULL) { - if (st_is_member(visited,(char *) scan)) { - retval = fprintf(fp,"\"%p\" [label = \"%g\"];\n", - (void *) ((mask & (ptrint) scan) / - sizeof(DdNode)), + if (st_is_member(visited,scan)) { + retval = fprintf(fp,"\"%#" PRIxPTR "\" [label = \"%g\"];\n", + ((mask & (ptruint) scan) / sizeof(DdNode)), cuddV(scan)); if (retval == EOF) goto failure; } @@ -879,19 +837,17 @@ failure: /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Prints a ZDD to the standard output. One line per node is - printed.] +/** + @brief Prints a %ZDD to the standard output. One line per node is + printed. - Description [Prints a ZDD to the standard output. One line per node is - printed. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Cudd_zddPrintDebug] + @see Cudd_zddPrintDebug -******************************************************************************/ +*/ int cuddZddP( DdManager * zdd, @@ -915,18 +871,14 @@ cuddZddP( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Performs the recursive step of cuddZddP. - Synopsis [Performs the recursive step of cuddZddP.] + @return 1 in case of success; 0 otherwise. - Description [Performs the recursive step of cuddZddP. Returns 1 in - case of success; 0 otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static int zp2( DdManager * zdd, @@ -940,51 +892,36 @@ zp2( if (f == NULL) return(0); - if (Cudd_IsConstant(f)) { + if (Cudd_IsConstantInt(f)) { (void)fprintf(zdd->out, "ID = %d\n", (f == base)); return(1); } - if (st_is_member(t, (char *)f) == 1) + if (st_is_member(t, f) == 1) return(1); - if (st_insert(t, (char *) f, NULL) == ST_OUT_OF_MEM) + if (st_insert(t, f, NULL) == ST_OUT_OF_MEM) return(0); -#if SIZEOF_VOID_P == 8 - (void) fprintf(zdd->out, "ID = 0x%lx\tindex = %u\tr = %u\t", + (void) fprintf(zdd->out, "ID = 0x%" PRIxPTR "\tindex = %u\tr = %u\t", (ptruint)f / (ptruint) sizeof(DdNode), f->index, f->ref); -#else - (void) fprintf(zdd->out, "ID = 0x%x\tindex = %hu\tr = %hu\t", - (ptruint)f / (ptruint) sizeof(DdNode), f->index, f->ref); -#endif n = cuddT(f); - if (Cudd_IsConstant(n)) { + if (Cudd_IsConstantInt(n)) { (void) fprintf(zdd->out, "T = %d\t\t", (n == base)); T = 1; } else { -#if SIZEOF_VOID_P == 8 - (void) fprintf(zdd->out, "T = 0x%lx\t", (ptruint) n / - (ptruint) sizeof(DdNode)); -#else - (void) fprintf(zdd->out, "T = 0x%x\t", (ptruint) n / + (void) fprintf(zdd->out, "T = 0x%" PRIxPTR "\t", (ptruint) n / (ptruint) sizeof(DdNode)); -#endif T = 0; } n = cuddE(f); - if (Cudd_IsConstant(n)) { + if (Cudd_IsConstantInt(n)) { (void) fprintf(zdd->out, "E = %d\n", (n == base)); E = 1; } else { -#if SIZEOF_VOID_P == 8 - (void) fprintf(zdd->out, "E = 0x%lx\n", (ptruint) n / + (void) fprintf(zdd->out, "E = 0x%" PRIxPTR "\n", (ptruint) n / (ptruint) sizeof(DdNode)); -#else - (void) fprintf(zdd->out, "E = 0x%x\n", (ptruint) n / - (ptruint) sizeof(DdNode)); -#endif E = 0; } @@ -997,17 +934,12 @@ zp2( } /* end of zp2 */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddPrintMinterm.] - - Description [] +/** + @brief Performs the recursive step of Cudd_zddPrintMinterm. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static void zdd_print_minterm_aux( DdManager * zdd /* manager */, @@ -1019,7 +951,7 @@ zdd_print_minterm_aux( int i, v; DdNode *base = DD_ONE(zdd); - if (Cudd_IsConstant(node)) { + if (Cudd_IsConstantInt(node)) { if (node == base) { /* Check for missing variable. */ if (level != zdd->sizeZ) { @@ -1069,17 +1001,12 @@ zdd_print_minterm_aux( } /* end of zdd_print_minterm_aux */ -/**Function******************************************************************** - - Synopsis [Performs the recursive step of Cudd_zddPrintCover.] - - Description [] - - SideEffects [None] +/** + @brief Performs the recursive step of Cudd_zddPrintCover. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static void zddPrintCoverAux( DdManager * zdd /* manager */, @@ -1091,7 +1018,7 @@ zddPrintCoverAux( int i, v; DdNode *base = DD_ONE(zdd); - if (Cudd_IsConstant(node)) { + if (Cudd_IsConstantInt(node)) { if (node == base) { /* Check for missing variable. */ if (level != zdd->sizeZ) { @@ -1141,19 +1068,17 @@ zddPrintCoverAux( } /* end of zddPrintCoverAux */ -/**Function******************************************************************** +/** + @brief Performs the recursive step of Cudd_zddSupport. - Synopsis [Performs the recursive step of Cudd_zddSupport.] + @details Performs a DFS from f. The support is accumulated in supp + as a side effect. Uses the LSB of the then pointer as visited flag. - Description [Performs the recursive step of Cudd_zddSupport. Performs a - DFS from f. The support is accumulated in supp as a side effect. Uses - the LSB of the then pointer as visited flag.] + @sideeffect None - SideEffects [None] + @see zddClearFlag - SeeAlso [zddClearFlag] - -******************************************************************************/ +*/ static void zddSupportStep( DdNode * f, @@ -1173,18 +1098,15 @@ zddSupportStep( } /* end of zddSupportStep */ -/**Function******************************************************************** - - Synopsis [Performs a DFS from f, clearing the LSB of the next - pointers.] - - Description [] +/** + @brief Performs a DFS from f, clearing the LSB of the next + pointers. - SideEffects [None] + @sideeffect None - SeeAlso [zddSupportStep] + @see zddSupportStep -******************************************************************************/ +*/ static void zddClearFlag( DdNode * f) diff --git a/resources/3rdparty/cudd-2.5.0/src/cudd/r7x8.1.mat b/resources/3rdparty/cudd-3.0.0/cudd/r7x8.1.mat similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/cudd/r7x8.1.mat rename to resources/3rdparty/cudd-3.0.0/cudd/r7x8.1.mat diff --git a/resources/3rdparty/cudd-3.0.0/cudd/test_cudd.test.in b/resources/3rdparty/cudd-3.0.0/cudd/test_cudd.test.in new file mode 100644 index 000000000..b926f4b85 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cudd/test_cudd.test.in @@ -0,0 +1,64 @@ +#! /bin/sh + +EXE=@EXEEXT@ +srcdir=@srcdir@ +file=r7x8.1 +verbosity=2 + +sed_command='-r:-e:2,3d:-e:/Cache used slots/d:-e:/Average distance/d:-e:/modifiable/,$d:-e:s/[0-9][0-9]*\.?[0-9]* sec//:-e:/so far/d' + +echo TAP version 13 +echo 1..2 +exitstatus=0 +# Create empty file. +: > ./cudd/differences + +cudd/testcudd$EXE -p $verbosity ${srcdir}/cudd/${file}.mat > ./cudd/${file}.tst 2>&1 +failed=`expr $? != 0` +if test x$failed = x0 ; then + echo "# comparing ./cudd/${file}.tst to ${srcdir}/cudd/${file}.out" + mkfifo ./cudd/tst_fifo ./cudd/out_fifo + OIFS=$IFS + IFS=: + `sed ${sed_command} ./cudd/${file}.tst > ./cudd/tst_fifo &\ + sed ${sed_command} ${srcdir}/cudd/${file}.out > ./cudd/out_fifo &\ + diff -b ./cudd/tst_fifo ./cudd/out_fifo >> ./cudd/differences` + failed=`expr $? != 0` + rm ./cudd/tst_fifo ./cudd/out_fifo + IFS=$OIFS +fi +if test x$failed = x0 ; then + echo ok 1 cudd basic +else + echo not ok 1 cudd basic +fi +exitstatus=`expr $exitstatus + $failed` + +cudd/testextra$EXE $verbosity > ./cudd/extra.tst 2>&1 +failed=`expr $? != 0` +if test x$failed = x0 ; then + echo "# comparing ./cudd/extra.tst to ${srcdir}/cudd/extra.out" + mkfifo ./cudd/tst_fifo ./cudd/out_fifo + OIFS=$IFS + IFS=: + `sed ${sed_command} ./cudd/extra.tst > ./cudd/tst_fifo &\ + sed ${sed_command} ${srcdir}/cudd/extra.out > ./cudd/out_fifo &\ + diff -b ./cudd/tst_fifo ./cudd/out_fifo >> ./cudd/differences` + failed=`expr $? != 0` + rm ./cudd/tst_fifo ./cudd/out_fifo + IFS=$OIFS +fi +if test x$failed = x0 ; then + echo ok 2 cudd extra +else + echo not ok 2 cudd extra +fi +exitstatus=`expr $exitstatus + $failed` + +if test x$exitstatus = x0; then + rm -rf ./cudd/differences +else + echo '# Check file "./cudd/differences"' +fi + +exit 0 diff --git a/resources/3rdparty/cudd-3.0.0/cudd/testcudd.c b/resources/3rdparty/cudd-3.0.0/cudd/testcudd.c new file mode 100644 index 000000000..5dabffdc8 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cudd/testcudd.c @@ -0,0 +1,1134 @@ +/** + @file + + @ingroup cudd + + @brief Sanity check tests for some CUDD functions. + + @details testcudd reads a matrix with real coefficients and + transforms it into an %ADD. It then performs various operations on + the %ADD and on the %BDD corresponding to the ADD pattern. Finally, + testcudd tests functions relate to Walsh matrices and matrix + multiplication. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" +#include "cuddInt.h" + + +/*---------------------------------------------------------------------------*/ +/* Constant declarations */ +/*---------------------------------------------------------------------------*/ + +#define TESTCUDD_VERSION "TestCudd Version #1.0, Release date 3/17/01" + +/*---------------------------------------------------------------------------*/ +/* Variable declarations */ +/*---------------------------------------------------------------------------*/ + +static const char *onames[] = { "C", "M" }; /* names of functions to be dumped */ + +/** \cond */ + +/*---------------------------------------------------------------------------*/ +/* Static function prototypes */ +/*---------------------------------------------------------------------------*/ + +static void usage (char * prog); +static FILE *open_file (char *filename, const char *mode); +static int testIterators (DdManager *dd, DdNode *M, DdNode *C, int pr); +static int testXor (DdManager *dd, DdNode *f, int pr, int nvars); +static int testHamming (DdManager *dd, DdNode *f, int pr); +static int testWalsh (DdManager *dd, int N, int cmu, int approach, int pr); +static int testSupport(DdManager *dd, DdNode *f, DdNode *g, int pr); + +/** \endcond */ + + + +/** + @brief Main function for testcudd. + + @sideeffect None + +*/ +int +main(int argc, char * const *argv) +{ + FILE *fp; /* pointer to input file */ + char *file = (char *) ""; /* input file name */ + FILE *dfp = NULL; /* pointer to dump file */ + FILE *savefp = NULL;/* pointer to save current manager's stdout setting */ + char *dfile; /* file for DD dump */ + DdNode *dfunc[2]; /* addresses of the functions to be dumped */ + DdManager *dd; /* pointer to DD manager */ + DdNode *one; /* fast access to constant function */ + DdNode *M; + DdNode **x; /* pointers to variables */ + DdNode **y; /* pointers to variables */ + DdNode **xn; /* complements of row variables */ + DdNode **yn_; /* complements of column variables */ + DdNode **xvars; + DdNode **yvars; + DdNode *C; /* result of converting from ADD to BDD */ + DdNode *ess; /* cube of essential variables */ + DdNode *shortP; /* BDD cube of shortest path */ + DdNode *largest; /* BDD of largest cube */ + DdNode *shortA; /* ADD cube of shortest path */ + DdNode *constN; /* value returned by evaluation of ADD */ + DdNode *ycube; /* cube of the negated y vars for c-proj */ + DdNode *CP; /* C-Projection of C */ + DdNode *CPr; /* C-Selection of C */ + int length; /* length of the shortest path */ + int nx; /* number of variables */ + int ny; + int maxnx; + int maxny; + int m; + int n; + int N; + int cmu; /* use CMU multiplication */ + int pr; /* verbose printout level */ + int harwell; + int multiple; /* read multiple matrices */ + int ok; + int approach; /* reordering approach */ + int autodyn; /* automatic reordering */ + int groupcheck; /* option for group sifting */ + int profile; /* print heap and cache profile if != 0 */ + int keepperm; /* keep track of permutation */ + int clearcache; /* clear the cache after each matrix */ + int blifOrDot; /* dump format: 0 -> dot, 1 -> blif, ... */ + int retval; /* return value */ + int i; /* loop index */ + unsigned long startTime; /* initial time */ + unsigned long lapTime = 0; + int size; + unsigned int cacheSize, maxMemory; + unsigned int nvars,nslots; + int optidx; + + startTime = util_cpu_time(); + + approach = CUDD_REORDER_NONE; + autodyn = 0; + pr = 0; + harwell = 0; + multiple = 0; + profile = 0; + keepperm = 0; + cmu = 0; + N = 4; + nvars = 4; + cacheSize = 2048; + maxMemory = 0; + nslots = CUDD_UNIQUE_SLOTS; + clearcache = 0; + groupcheck = CUDD_GROUP_CHECK7; + dfile = NULL; + blifOrDot = 0; /* dot format */ + + /* Parse command line. */ + for (optidx = 1; optidx < argc; optidx++) { + if (argv[optidx][0] == '-') { + switch(argv[optidx][1]) { + case 'C': + cmu = 1; + break; + case 'D': + autodyn = 1; + break; + case 'H': + harwell = 1; + break; + case 'M': + /* NOOP: retained for backward compatibility. */ + break; + case 'P': + profile = 1; + break; + case 'S': + if (++optidx == argc) usage(argv[0]); + nslots = atoi(argv[optidx]); + break; + case 'X': + if (++optidx == argc) usage(argv[0]); + maxMemory = atoi(argv[optidx]); + break; + case 'a': + if (++optidx == argc) usage(argv[0]); + approach = atoi(argv[optidx]); + break; + case 'b': + blifOrDot = 1; /* blif format */ + break; + case 'c': + clearcache = 1; + break; + case 'd': + if (++optidx == argc) usage(argv[0]); + dfile = argv[optidx]; + break; + case 'g': + if (++optidx == argc) usage(argv[0]); + groupcheck = atoi(argv[optidx]); + break; + case 'k': + keepperm = 1; + break; + case 'm': + multiple = 1; + break; + case 'n': + if (++optidx == argc) usage(argv[0]); + N = atoi(argv[optidx]); + break; + case 'p': + if (++optidx == argc) usage(argv[0]); + pr = atoi(argv[optidx]); + break; + case 'v': + if (++optidx == argc) usage(argv[0]); + nvars = atoi(argv[optidx]); + break; + case 'x': + if (++optidx == argc) usage(argv[0]); + cacheSize = atoi(argv[optidx]); + break; + case 'h': + default: + usage(argv[0]); + break; + } + } else if (argc - optidx == 1) { + file = argv[optidx]; + } else { + usage(argv[0]); + } + } + + if ((approach<0) || (approach>17)) { + (void) fprintf(stderr,"Invalid approach: %d \n",approach); + usage(argv[0]); + } + + if (pr > 0) { + (void) printf("# %s\n", TESTCUDD_VERSION); + /* Echo command line and arguments. */ + (void) printf("#"); + for (i = 0; i < argc; i++) { + (void) printf(" %s", argv[i]); + } + (void) printf("\n"); + (void) fflush(stdout); + } + + /* Initialize manager and provide easy reference to terminals. */ + dd = Cudd_Init(nvars,0,nslots,cacheSize,maxMemory); + one = DD_ONE(dd); + dd->groupcheck = (Cudd_AggregationType) groupcheck; + if (autodyn) Cudd_AutodynEnable(dd,CUDD_REORDER_SAME); + + /* Open input file. */ + fp = open_file(file, "r"); + + /* Open dump file if requested */ + if (dfile != NULL) { + dfp = open_file(dfile, "w"); + } + + x = y = xn = yn_ = NULL; + do { + /* We want to start anew for every matrix. */ + maxnx = maxny = 0; + nx = maxnx; ny = maxny; + if (pr>0) lapTime = util_cpu_time(); + if (harwell) { + if (pr > 0) (void) printf(":name: "); + ok = Cudd_addHarwell(fp, dd, &M, &x, &y, &xn, &yn_, &nx, &ny, + &m, &n, 0, 2, 1, 2, pr); + } else { + ok = Cudd_addRead(fp, dd, &M, &x, &y, &xn, &yn_, &nx, &ny, + &m, &n, 0, 2, 1, 2); + if (pr > 0) + (void) printf(":name: %s: %d rows %d columns\n", file, m, n); + } + if (!ok) { + (void) fprintf(stderr, "Error reading matrix\n"); + return(1); + } + + if (nx > maxnx) maxnx = nx; + if (ny > maxny) maxny = ny; + + /* Build cube of negated y's. */ + ycube = DD_ONE(dd); + Cudd_Ref(ycube); + for (i = maxny - 1; i >= 0; i--) { + DdNode *tmpp; + tmpp = Cudd_bddAnd(dd,Cudd_Not(dd->vars[y[i]->index]),ycube); + if (tmpp == NULL) return(2); + Cudd_Ref(tmpp); + Cudd_RecursiveDeref(dd,ycube); + ycube = tmpp; + } + /* Initialize vectors of BDD variables used by priority func. */ + xvars = ALLOC(DdNode *, nx); + if (xvars == NULL) return(2); + for (i = 0; i < nx; i++) { + xvars[i] = dd->vars[x[i]->index]; + } + yvars = ALLOC(DdNode *, ny); + if (yvars == NULL) return(2); + for (i = 0; i < ny; i++) { + yvars[i] = dd->vars[y[i]->index]; + } + + /* Clean up */ + for (i=0; i < maxnx; i++) { + Cudd_RecursiveDeref(dd, x[i]); + Cudd_RecursiveDeref(dd, xn[i]); + } + FREE(x); + FREE(xn); + for (i=0; i < maxny; i++) { + Cudd_RecursiveDeref(dd, y[i]); + Cudd_RecursiveDeref(dd, yn_[i]); + } + FREE(y); + FREE(yn_); + + if (pr>0) {(void) printf(":1: M"); Cudd_PrintDebug(dd,M,nx+ny,pr);} + + if (pr>0) (void) printf(":2: time to read the matrix = %s\n", + util_print_time(util_cpu_time() - lapTime)); + + C = Cudd_addBddPattern(dd, M); + if (C == 0) return(2); + Cudd_Ref(C); + if (pr>0) {(void) printf(":3: C"); Cudd_PrintDebug(dd,C,nx+ny,pr);} + + /* Test iterators. */ + retval = testIterators(dd,M,C,pr); + if (retval == 0) return(2); + + if (profile != 0 && pr > 0) + cuddCacheProfile(dd,stdout); + + /* Test XOR */ + retval = testXor(dd,C,pr,nx+ny); + if (retval == 0) return(2); + + /* Test Hamming distance functions. */ + retval = testHamming(dd,C,pr); + if (retval == 0) return(2); + + /* Test selection functions. */ + CP = Cudd_CProjection(dd,C,ycube); + if (CP == NULL) return(2); + Cudd_Ref(CP); + if (pr>0) {(void) printf("ycube"); Cudd_PrintDebug(dd,ycube,nx+ny,pr);} + if (pr>0) {(void) printf("CP"); Cudd_PrintDebug(dd,CP,nx+ny,pr);} + + if (nx == ny) { + CPr = Cudd_PrioritySelect(dd,C,xvars,yvars,(DdNode **)NULL, + (DdNode *)NULL,ny,Cudd_Xgty); + if (CPr == NULL) return(2); + Cudd_Ref(CPr); + if (pr>0) {(void) printf(":4: CPr"); Cudd_PrintDebug(dd,CPr,nx+ny,pr);} + if (CP != CPr) { + (void) printf("CP != CPr!\n"); + } + Cudd_RecursiveDeref(dd, CPr); + } + + /* Test inequality generator. */ + { + int Nmin = ddMin(nx,ny); + int q; + DdGen *gen; + int *cube; + DdNode *f = Cudd_Inequality(dd,Nmin,2,xvars,yvars); + if (f == NULL) return(2); + Cudd_Ref(f); + if (pr>0) { + (void) printf(":4: ineq"); + Cudd_PrintDebug(dd,f,nx+ny,pr); + if (pr>1) { + Cudd_ForeachPrime(dd,Cudd_Not(f),Cudd_Not(f),gen,cube) { + for (q = 0; q < dd->size; q++) { + switch (cube[q]) { + case 0: + (void) printf("1"); + break; + case 1: + (void) printf("0"); + break; + case 2: + (void) printf("-"); + break; + default: + (void) printf("?"); + } + } + (void) printf(" 1\n"); + } + (void) printf("\n"); + } + } + Cudd_IterDerefBdd(dd, f); + } + FREE(xvars); FREE(yvars); + + Cudd_RecursiveDeref(dd, CP); + + /* Test functions for essential variables. */ + ess = Cudd_FindEssential(dd,C); + if (ess == NULL) return(2); + Cudd_Ref(ess); + if (pr>0) {(void) printf(":4: ess"); Cudd_PrintDebug(dd,ess,nx+ny,pr);} + Cudd_RecursiveDeref(dd, ess); + + /* Test functions for shortest paths. */ + shortP = Cudd_ShortestPath(dd, M, NULL, NULL, &length); + if (shortP == NULL) return(2); + Cudd_Ref(shortP); + if (pr>0) { + (void) printf(":5: shortP"); Cudd_PrintDebug(dd,shortP,nx+ny,pr); + } + /* Test functions for largest cubes. */ + largest = Cudd_LargestCube(dd, Cudd_Not(C), &length); + if (largest == NULL) return(2); + Cudd_Ref(largest); + if (pr>0) { + (void) printf(":5b: largest"); + Cudd_PrintDebug(dd,largest,nx+ny,pr); + } + Cudd_RecursiveDeref(dd, largest); + + /* Test Cudd_addEvalConst and Cudd_addIteConstant. */ + shortA = Cudd_BddToAdd(dd,shortP); + if (shortA == NULL) return(2); + Cudd_Ref(shortA); + Cudd_RecursiveDeref(dd, shortP); + constN = Cudd_addEvalConst(dd,shortA,M); + if (constN == DD_NON_CONSTANT) return(2); + if (Cudd_addIteConstant(dd,shortA,M,constN) != constN) return(2); + if (pr>0) {(void) printf("The value of M along the chosen shortest path is %g\n", cuddV(constN));} + Cudd_RecursiveDeref(dd, shortA); + + shortP = Cudd_ShortestPath(dd, C, NULL, NULL, &length); + if (shortP == NULL) return(2); + Cudd_Ref(shortP); + if (pr>0) { + (void) printf(":6: shortP"); Cudd_PrintDebug(dd,shortP,nx+ny,pr); + } + + /* Test Cudd_bddIteConstant and Cudd_bddLeq. */ + if (!Cudd_bddLeq(dd,shortP,C)) return(2); + if (Cudd_bddIteConstant(dd,Cudd_Not(shortP),one,C) != one) return(2); + Cudd_RecursiveDeref(dd, shortP); + + /* Experiment with support functions. */ + if (!testSupport(dd,M,ycube,pr)) { + return(2); + } + Cudd_RecursiveDeref(dd, ycube); + + if (profile) { + retval = cuddHeapProfile(dd); + if (retval == 0) { + (void) fprintf(stderr,"Error reported by cuddHeapProfile\n"); + return(2); + } + } + + size = dd->size; + + if (pr>0) { + (void) printf("Average distance: %g\n", Cudd_AverageDistance(dd)); + } + + /* Reorder if so requested. */ + if (approach != CUDD_REORDER_NONE) { +#ifndef DD_STATS + retval = Cudd_EnableReorderingReporting(dd); + if (retval == 0) { + (void) fprintf(stderr,"Error reported by Cudd_EnableReorderingReporting\n"); + return(3); + } +#endif +#ifdef DD_DEBUG + retval = Cudd_DebugCheck(dd); + if (retval != 0) { + (void) fprintf(stderr,"Error reported by Cudd_DebugCheck\n"); + return(3); + } + retval = Cudd_CheckKeys(dd); + if (retval != 0) { + (void) fprintf(stderr,"Error reported by Cudd_CheckKeys\n"); + return(3); + } +#endif + retval = Cudd_ReduceHeap(dd,(Cudd_ReorderingType)approach,5); + if (retval == 0) { + (void) fprintf(stderr,"Error reported by Cudd_ReduceHeap\n"); + return(3); + } +#ifndef DD_STATS + retval = Cudd_DisableReorderingReporting(dd); + if (retval == 0) { + (void) fprintf(stderr,"Error reported by Cudd_DisableReorderingReporting\n"); + return(3); + } +#endif +#ifdef DD_DEBUG + retval = Cudd_DebugCheck(dd); + if (retval != 0) { + (void) fprintf(stderr,"Error reported by Cudd_DebugCheck\n"); + return(3); + } + retval = Cudd_CheckKeys(dd); + if (retval != 0) { + (void) fprintf(stderr,"Error reported by Cudd_CheckKeys\n"); + return(3); + } +#endif + if (approach == CUDD_REORDER_SYMM_SIFT || + approach == CUDD_REORDER_SYMM_SIFT_CONV) { + Cudd_SymmProfile(dd,0,dd->size-1); + } + + if (pr>0) { + (void) printf("Average distance: %g\n", Cudd_AverageDistance(dd)); + } + + if (keepperm) { + /* Print variable permutation. */ + (void) printf("Variable Permutation:"); + for (i=0; i<size; i++) { + if (i%20 == 0) (void) printf("\n"); + (void) printf("%d ", dd->invperm[i]); + } + (void) printf("\n"); + (void) printf("Inverse Permutation:"); + for (i=0; i<size; i++) { + if (i%20 == 0) (void) printf("\n"); + (void) printf("%d ", dd->perm[i]); + } + (void) printf("\n"); + } + + if (pr>0) {(void) printf("M"); Cudd_PrintDebug(dd,M,nx+ny,pr);} + + if (profile) { + retval = cuddHeapProfile(dd); + if (retval == 0) { + (void) fprintf(stderr,"Error reported by cuddHeapProfile\n"); + return(2); + } + } + + } + + /* Dump DDs of C and M if so requested. */ + if (dfile != NULL) { + dfunc[0] = C; + dfunc[1] = M; + if (blifOrDot == 1) { + /* Only dump C because blif cannot handle ADDs */ + retval = Cudd_DumpBlif(dd,1,dfunc,NULL, + (char const * const *)onames,NULL,dfp,0); + } else { + retval = Cudd_DumpDot(dd,2,dfunc,NULL, + (char const * const *)onames,dfp); + } + if (retval != 1) { + (void) fprintf(stderr,"abnormal termination\n"); + return(2); + } + } + + Cudd_RecursiveDeref(dd, C); + Cudd_RecursiveDeref(dd, M); + + if (clearcache) { + if (pr>0) {(void) printf("Clearing the cache... ");} + for (i = dd->cacheSlots - 1; i>=0; i--) { + dd->cache[i].data = NULL; + } + if (pr>0) {(void) printf("done\n");} + } + if (pr>0) { + (void) printf("Number of variables = %6d\t",dd->size); + (void) printf("Number of slots = %6u\n",dd->slots); + (void) printf("Number of keys = %6u\t",dd->keys); + (void) printf("Number of min dead = %6u\n",dd->minDead); + } + + } while (multiple && !feof(fp)); + + fclose(fp); + if (dfile != NULL) { + fclose(dfp); + } + + /* Second phase: experiment with Walsh matrices. */ + if (!testWalsh(dd,N,cmu,approach,pr)) { + return(2); + } + + /* Check variable destruction. */ + assert(cuddDestroySubtables(dd,3)); + if (pr == 0) { + savefp = Cudd_ReadStdout(dd); + Cudd_SetStdout(dd,fopen("/dev/null","a")); + } + assert(Cudd_DebugCheck(dd) == 0); + assert(Cudd_CheckKeys(dd) == 0); + if (pr == 0) { + fclose(Cudd_ReadStdout(dd)); + Cudd_SetStdout(dd,savefp); + } + + retval = Cudd_CheckZeroRef(dd); + ok = retval != 0; /* ok == 0 means O.K. */ + if (retval != 0) { + (void) fprintf(stderr, + "%d non-zero DD reference counts after dereferencing\n", retval); + } + + if (pr > 0) { + (void) Cudd_PrintInfo(dd,stdout); + } + + Cudd_Quit(dd); + + if (pr>0) (void) printf("total time = %s\n", + util_print_time(util_cpu_time() - startTime)); + + if (pr > 0) util_print_cpu_stats(stdout); + return ok; + +} /* end of main */ + + +/*---------------------------------------------------------------------------*/ +/* Definition of static functions */ +/*---------------------------------------------------------------------------*/ + + +/** + @brief Prints usage info for testcudd. + + @sideeffect None + +*/ +static void +usage(char *prog) +{ + (void) fprintf(stderr, "usage: %s [options] [file]\n", prog); + (void) fprintf(stderr, " -C\t\tuse CMU multiplication algorithm\n"); + (void) fprintf(stderr, " -D\t\tenable automatic dynamic reordering\n"); + (void) fprintf(stderr, " -H\t\tread matrix in Harwell format\n"); + (void) fprintf(stderr, " -P\t\tprint BDD heap and cache profile\n"); + (void) fprintf(stderr, " -S n\t\tnumber of slots for each subtable\n"); + (void) fprintf(stderr, " -X n\t\ttarget maximum memory in bytes\n"); + (void) fprintf(stderr, " -a n\t\tchoose reordering approach (0-13)\n"); + (void) fprintf(stderr, " \t\t\t0: same as autoMethod\n"); + (void) fprintf(stderr, " \t\t\t1: no reordering (default)\n"); + (void) fprintf(stderr, " \t\t\t2: random\n"); + (void) fprintf(stderr, " \t\t\t3: pivot\n"); + (void) fprintf(stderr, " \t\t\t4: sifting\n"); + (void) fprintf(stderr, " \t\t\t5: sifting to convergence\n"); + (void) fprintf(stderr, " \t\t\t6: symmetric sifting\n"); + (void) fprintf(stderr, " \t\t\t7: symmetric sifting to convergence\n"); + (void) fprintf(stderr, " \t\t\t8-10: window of size 2-4\n"); + (void) fprintf(stderr, " \t\t\t11-13: window of size 2-4 to conv.\n"); + (void) fprintf(stderr, " \t\t\t14: group sifting\n"); + (void) fprintf(stderr, " \t\t\t15: group sifting to convergence\n"); + (void) fprintf(stderr, " \t\t\t16: simulated annealing\n"); + (void) fprintf(stderr, " \t\t\t17: genetic algorithm\n"); + (void) fprintf(stderr, " -b\t\tuse blif as format for dumps\n"); + (void) fprintf(stderr, " -c\t\tclear the cache after each matrix\n"); + (void) fprintf(stderr, " -d file\tdump DDs to file\n"); + (void) fprintf(stderr, " -g\t\tselect aggregation criterion (0,5,7)\n"); + (void) fprintf(stderr, " -h\t\tprints this message\n"); + (void) fprintf(stderr, " -k\t\tprint the variable permutation\n"); + (void) fprintf(stderr, " -m\t\tread multiple matrices (only with -H)\n"); + (void) fprintf(stderr, " -n n\t\tnumber of variables\n"); + (void) fprintf(stderr, " -p n\t\tcontrol verbosity\n"); + (void) fprintf(stderr, " -v n\t\tinitial variables in the unique table\n"); + (void) fprintf(stderr, " -x n\t\tinitial size of the cache\n"); + exit(2); +} /* end of usage */ + + +/** + @brief Opens a file. + + @details Opens a file, or fails with an error message and exits. + Allows '-' as a synonym for standard input. + + @sideeffect None + +*/ +static FILE * +open_file(char *filename, const char *mode) +{ + FILE *fp; + + if (strcmp(filename, "-") == 0) { + return mode[0] == 'r' ? stdin : stdout; + } else if ((fp = fopen(filename, mode)) == NULL) { + perror(filename); + exit(1); + } + return fp; + +} /* end of open_file */ + + +/** + @brief Tests Walsh matrix multiplication. + + @return 1 if successful; 0 otherwise. + + @sideeffect May create new variables in the manager. + +*/ +static int +testWalsh( + DdManager *dd /* manager */, + int N /* number of variables */, + int cmu /* use CMU approach to matrix multiplication */, + int approach /* reordering approach */, + int pr /* verbosity level */) +{ + DdNode *walsh1, *walsh2, *wtw; + DdNode **x, **v, **z; + int i, retval; + DdNode *one = DD_ONE(dd); + DdNode *zero = DD_ZERO(dd); + + if (N > 3) { + x = ALLOC(DdNode *,N); + v = ALLOC(DdNode *,N); + z = ALLOC(DdNode *,N); + + for (i = N-1; i >= 0; i--) { + Cudd_Ref(x[i]=cuddUniqueInter(dd,3*i,one,zero)); + Cudd_Ref(v[i]=cuddUniqueInter(dd,3*i+1,one,zero)); + Cudd_Ref(z[i]=cuddUniqueInter(dd,3*i+2,one,zero)); + } + Cudd_Ref(walsh1 = Cudd_addWalsh(dd,v,z,N)); + if (pr>0) {(void) printf("walsh1"); Cudd_PrintDebug(dd,walsh1,2*N,pr);} + Cudd_Ref(walsh2 = Cudd_addWalsh(dd,x,v,N)); + if (cmu) { + Cudd_Ref(wtw = Cudd_addTimesPlus(dd,walsh2,walsh1,v,N)); + } else { + Cudd_Ref(wtw = Cudd_addMatrixMultiply(dd,walsh2,walsh1,v,N)); + } + if (pr>0) {(void) printf("wtw"); Cudd_PrintDebug(dd,wtw,2*N,pr);} + + if (approach != CUDD_REORDER_NONE) { +#ifdef DD_DEBUG + retval = Cudd_DebugCheck(dd); + if (retval != 0) { + (void) fprintf(stderr,"Error reported by Cudd_DebugCheck\n"); + return(0); + } +#endif + retval = Cudd_ReduceHeap(dd,(Cudd_ReorderingType)approach,5); + if (retval == 0) { + (void) fprintf(stderr,"Error reported by Cudd_ReduceHeap\n"); + return(0); + } +#ifdef DD_DEBUG + retval = Cudd_DebugCheck(dd); + if (retval != 0) { + (void) fprintf(stderr,"Error reported by Cudd_DebugCheck\n"); + return(0); + } +#endif + if (approach == CUDD_REORDER_SYMM_SIFT || + approach == CUDD_REORDER_SYMM_SIFT_CONV) { + Cudd_SymmProfile(dd,0,dd->size-1); + } + } + /* Clean up. */ + Cudd_RecursiveDeref(dd, wtw); + Cudd_RecursiveDeref(dd, walsh1); + Cudd_RecursiveDeref(dd, walsh2); + for (i=0; i < N; i++) { + Cudd_RecursiveDeref(dd, x[i]); + Cudd_RecursiveDeref(dd, v[i]); + Cudd_RecursiveDeref(dd, z[i]); + } + FREE(x); + FREE(v); + FREE(z); + } + return(1); + +} /* end of testWalsh */ + +/** + @brief Tests iterators on cubes and nodes. + + @sideeffect None + +*/ +static int +testIterators( + DdManager *dd, + DdNode *M, + DdNode *C, + int pr) +{ + int *cube; + CUDD_VALUE_TYPE value; + DdGen *gen; + int q; + + /* Test iterator for cubes. */ + if (pr>1) { + (void) printf("Testing iterator on cubes:\n"); + Cudd_ForeachCube(dd,M,gen,cube,value) { + for (q = 0; q < dd->size; q++) { + switch (cube[q]) { + case 0: + (void) printf("0"); + break; + case 1: + (void) printf("1"); + break; + case 2: + (void) printf("-"); + break; + default: + (void) printf("?"); + } + } + (void) printf(" %g\n",value); + } + (void) printf("\n"); + } + + if (pr>1) { + (void) printf("Testing prime expansion of cubes:\n"); + if (!Cudd_bddPrintCover(dd,C,C)) return(0); + } + + if (pr>1) { + (void) printf("Testing iterator on primes (CNF):\n"); + Cudd_ForeachPrime(dd,Cudd_Not(C),Cudd_Not(C),gen,cube) { + for (q = 0; q < dd->size; q++) { + switch (cube[q]) { + case 0: + (void) printf("1"); + break; + case 1: + (void) printf("0"); + break; + case 2: + (void) printf("-"); + break; + default: + (void) printf("?"); + } + } + (void) printf(" 1\n"); + } + (void) printf("\n"); + } + + /* Test iterator on nodes. */ + if (pr>2) { + DdNode *node; + (void) printf("Testing iterator on nodes:\n"); + Cudd_ForeachNode(dd,M,gen,node) { + if (Cudd_IsConstant(node)) { + (void) printf("ID = 0x%"PRIxPTR"\tvalue = %-9g\n", + (ptruint) node / (ptruint) sizeof(DdNode), + Cudd_V(node)); + } else { + (void) printf("ID = 0x%"PRIxPTR"\tindex = %u\tr = %u\n", + (ptruint) node / (ptruint) sizeof(DdNode), + node->index, node->ref); + } + } + (void) printf("\n"); + } + return(1); + +} /* end of testIterators */ + + +/** + @brief Tests the functions related to the exclusive OR. + + @details Builds the boolean difference of the given function in + three different ways and checks that the results is the same. + + @return 1 if successful; 0 otherwise. + + @sideeffect None + +*/ +static int +testXor(DdManager *dd, DdNode *f, int pr, int nvars) +{ + DdNode *f1, *f0, *res1, *res2; + int x; + + /* Extract cofactors w.r.t. mid variable. */ + x = nvars / 2; + f1 = Cudd_Cofactor(dd,f,dd->vars[x]); + if (f1 == NULL) return(0); + Cudd_Ref(f1); + + f0 = Cudd_Cofactor(dd,f,Cudd_Not(dd->vars[x])); + if (f0 == NULL) { + Cudd_RecursiveDeref(dd,f1); + return(0); + } + Cudd_Ref(f0); + + /* Compute XOR of cofactors with ITE. */ + res1 = Cudd_bddIte(dd,f1,Cudd_Not(f0),f0); + if (res1 == NULL) return(0); + Cudd_Ref(res1); + + if (pr>0) {(void) printf("xor1"); Cudd_PrintDebug(dd,res1,nvars,pr);} + + /* Compute XOR of cofactors with XOR. */ + res2 = Cudd_bddXor(dd,f1,f0); + if (res2 == NULL) { + Cudd_RecursiveDeref(dd,res1); + return(0); + } + Cudd_Ref(res2); + + if (res1 != res2) { + if (pr>0) {(void) printf("xor2"); Cudd_PrintDebug(dd,res2,nvars,pr);} + Cudd_RecursiveDeref(dd,res1); + Cudd_RecursiveDeref(dd,res2); + return(0); + } + Cudd_RecursiveDeref(dd,res1); + Cudd_RecursiveDeref(dd,f1); + Cudd_RecursiveDeref(dd,f0); + + /* Compute boolean difference directly. */ + res1 = Cudd_bddBooleanDiff(dd,f,x); + if (res1 == NULL) { + Cudd_RecursiveDeref(dd,res2); + return(0); + } + Cudd_Ref(res1); + + if (res1 != res2) { + if (pr>0) {(void) printf("xor3"); Cudd_PrintDebug(dd,res1,nvars,pr);} + Cudd_RecursiveDeref(dd,res1); + Cudd_RecursiveDeref(dd,res2); + return(0); + } + Cudd_RecursiveDeref(dd,res1); + Cudd_RecursiveDeref(dd,res2); + return(1); + +} /* end of testXor */ + + +/** + @brief Tests the Hamming distance functions. + + @return 1 if successful; 0 otherwise. + + @sideeffect None + +*/ +static int +testHamming( + DdManager *dd, + DdNode *f, + int pr) +{ + DdNode **vars, *minBdd, *zero, *scan; + int i; + int d; + int *minterm; + int size = Cudd_ReadSize(dd); + + vars = ALLOC(DdNode *, size); + if (vars == NULL) return(0); + for (i = 0; i < size; i++) { + vars[i] = Cudd_bddIthVar(dd,i); + } + + minBdd = Cudd_bddPickOneMinterm(dd,Cudd_Not(f),vars,size); + Cudd_Ref(minBdd); + if (pr > 0) { + (void) printf("Chosen minterm for Hamming distance test: "); + Cudd_PrintDebug(dd,minBdd,size,pr); + } + + minterm = ALLOC(int,size); + if (minterm == NULL) { + FREE(vars); + Cudd_RecursiveDeref(dd,minBdd); + return(0); + } + scan = minBdd; + zero = Cudd_Not(DD_ONE(dd)); + while (!Cudd_IsConstant(scan)) { + DdNode *R = Cudd_Regular(scan); + DdNode *T = Cudd_T(R); + DdNode *E = Cudd_E(R); + if (R != scan) { + T = Cudd_Not(T); + E = Cudd_Not(E); + } + if (T == zero) { + minterm[R->index] = 0; + scan = E; + } else { + minterm[R->index] = 1; + scan = T; + } + } + Cudd_RecursiveDeref(dd,minBdd); + + d = Cudd_MinHammingDist(dd,f,minterm,size); + + if (pr > 0) + (void) printf("Minimum Hamming distance = %d\n", d); + + FREE(vars); + FREE(minterm); + return(1); + +} /* end of testHamming */ + + +/** + @brief Tests the support functions. + + @return 1 if successful; 0 otherwise. + + @sideeffect None + +*/ +static int +testSupport( + DdManager *dd, + DdNode *f, + DdNode *g, + int pr) +{ + DdNode *sb, *common, *onlyF, *onlyG; + DdNode *F[2]; + int *support; + int ret, ssize; + int size = Cudd_ReadSize(dd); + + sb = Cudd_Support(dd, f); + if (sb == NULL) return(0); + Cudd_Ref(sb); + if (pr > 0) { + (void) printf("Support of f: "); + Cudd_PrintDebug(dd,sb,size,pr); + } + Cudd_RecursiveDeref(dd, sb); + + ssize = Cudd_SupportIndices(dd, f, &support); + if (ssize == CUDD_OUT_OF_MEM) return(0); + if (pr > 0) { + (void) printf("Size of the support of f: %d\n", ssize); + } + FREE(support); + + ssize = Cudd_SupportSize(dd, f); + if (pr > 0) { + (void) printf("Size of the support of f: %d\n", ssize); + } + + F[0] = f; + F[1] = g; + sb = Cudd_VectorSupport(dd, F, 2); + if (sb == NULL) return(0); + Cudd_Ref(sb); + if (pr > 0) { + (void) printf("Support of f and g: "); + Cudd_PrintDebug(dd,sb,size,pr); + } + Cudd_RecursiveDeref(dd, sb); + + ssize = Cudd_VectorSupportIndices(dd, F, 2, &support); + if (ssize == CUDD_OUT_OF_MEM) return(0); + if (pr > 0) { + (void) printf("Size of the support of f and g: %d\n", ssize); + } + FREE(support); + + ssize = Cudd_VectorSupportSize(dd, F, 2); + if (pr > 0) { + (void) printf("Size of the support of f and g: %d\n", ssize); + } + + ret = Cudd_ClassifySupport(dd, f, g, &common, &onlyF, &onlyG); + if (ret == 0) return(0); + Cudd_Ref(common); Cudd_Ref(onlyF); Cudd_Ref(onlyG); + if (pr > 0) { + (void) printf("Support common to f and g: "); + Cudd_PrintDebug(dd,common,size,pr); + (void) printf("Support private to f: "); + Cudd_PrintDebug(dd,onlyF,size,pr); + (void) printf("Support private to g: "); + Cudd_PrintDebug(dd,onlyG,size,pr); + } + Cudd_RecursiveDeref(dd, common); + Cudd_RecursiveDeref(dd, onlyF); + Cudd_RecursiveDeref(dd, onlyG); + + return(1); + +} /* end of testSupport */ diff --git a/resources/3rdparty/cudd-3.0.0/cudd/testextra.c b/resources/3rdparty/cudd-3.0.0/cudd/testextra.c new file mode 100644 index 000000000..99fdda981 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/cudd/testextra.c @@ -0,0 +1,578 @@ +/** + @file + + @ingroup cudd + + @brief This program tests selected features of CUDD. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + + */ + +#include "util.h" +#include "epd.h" +#include "cudd.h" +#include <setjmp.h> + +/** \cond */ +static int testBdd(int verbosity); +static int testAdd(int verbosity); +static int testZdd(int verbosity); +static int testApa(int verbosity); +static int testCount(int verbosity); +static int testLdbl(int verbosity); +static int testTimeout(int verbosity); +static void timeoutHandler(DdManager * dd, void * arg); +/** \endcond */ + +/** + * @brief Main program for testextra. + */ +int main(int argc, char const * const * argv) +{ + int verbosity = 0; + if (argc == 2) { + int nread; + int ret = sscanf(argv[1], "%d%n", &verbosity, &nread); + if (ret != 1 || argv[1][nread]) { + fprintf(stderr, "Usage: %s [verbosity]\n", argv[0]); + return -1; + } + } + if (testBdd(verbosity) != 0) + return -1; + if (testAdd(verbosity) != 0) + return -1; + if (testZdd(verbosity) != 0) + return -1; + if (testApa(verbosity) != 0) + return -1; + if (testCount(verbosity) != 0) + return -1; + if (testLdbl(verbosity) != 0) + return -1; + if (testTimeout(verbosity) != 0) + return -1; + return 0; +} + +/** + * @brief Basic BDD test. + * @return 0 if successful; -1 otherwise. + */ +static int +testBdd(int verbosity) +{ + DdManager *dd; + DdNode *f, *var, *tmp; + int i, ret; + + dd = Cudd_Init(0, 0, CUDD_UNIQUE_SLOTS, CUDD_CACHE_SLOTS, 0); + if (!dd) { + if (verbosity) { + printf("initialization failed\n"); + } + return -1; + } + if (verbosity) { + printf("Started CUDD version "); + Cudd_PrintVersion(stdout); + } + f = Cudd_ReadOne(dd); + Cudd_Ref(f); + for (i = 3; i >= 0; i--) { + var = Cudd_bddIthVar(dd, i); + tmp = Cudd_bddAnd(dd, Cudd_Not(var), f); + if (!tmp) { + if (verbosity) { + printf("computation failed\n"); + } + return -1; + } + Cudd_Ref(tmp); + Cudd_RecursiveDeref(dd, f); + f = tmp; + } + if (verbosity) { + Cudd_bddPrintCover(dd, f, f); + } + Cudd_RecursiveDeref(dd, f); + ret = Cudd_CheckZeroRef(dd); + if (ret != 0 && verbosity) { + printf("%d unexpected non-zero references\n", ret); + } + Cudd_Quit(dd); + return 0; +} + +/** + * @brief Basic ADD test. + * @return 0 if successful; -1 otherwise. + */ +static int +testAdd(int verbosity) +{ + DdManager *manager; + DdNode *f, *var, *tmp, *bg; + int i, ret; + CUDD_VALUE_TYPE pinf; + + manager = Cudd_Init(0, 0, CUDD_UNIQUE_SLOTS, CUDD_CACHE_SLOTS, 0); + if (!manager) { + if (verbosity) { + printf("initialization failed\n"); + } + return -1; + } + pinf = Cudd_V(Cudd_ReadPlusInfinity(manager)); + if (verbosity) { + printf("Plus infinity is %g\n", pinf); + } + f = Cudd_addConst(manager,5); + Cudd_Ref(f); + for (i = 3; i >= 0; i--) { + var = Cudd_addIthVar(manager,i); + Cudd_Ref(var); + tmp = Cudd_addApply(manager,Cudd_addTimes,var,f); + Cudd_Ref(tmp); + Cudd_RecursiveDeref(manager,f); + Cudd_RecursiveDeref(manager,var); + f = tmp; + } + if (verbosity) { + Cudd_PrintMinterm(manager, f); + printf("\n"); + } + Cudd_RecursiveDeref(manager, f); + bg = Cudd_ReadBackground(manager); + if (verbosity) { + printf("background (%g) minterms : ", Cudd_V(bg)); + Cudd_ApaPrintMinterm(Cudd_ReadStdout(manager), manager, bg, 0); + } + ret = Cudd_CheckZeroRef(manager); + if (ret != 0 && verbosity) { + printf("%d non-zero ADD reference counts after dereferencing\n", ret); + } + Cudd_Quit(manager); + return ret != 0; +} + +/** + * @brief Basic test of ZDDs. + * @return 0 if successful; -1 otherwise. + */ +static int +testZdd(int verbosity) +{ + DdManager *manager; + DdNode *f, *var, *tmp; + int i, ret; + + manager = Cudd_Init(0,4,CUDD_UNIQUE_SLOTS, CUDD_CACHE_SLOTS,0); + if (!manager) { + if (verbosity) { + printf("initialization failed\n"); + } + return -1; + } + tmp = Cudd_ReadZddOne(manager,0); + Cudd_Ref(tmp); + for (i = 3; i >= 0; i--) { + var = Cudd_zddIthVar(manager,i); + Cudd_Ref(var); + f = Cudd_zddIntersect(manager,var,tmp); + Cudd_Ref(f); + Cudd_RecursiveDerefZdd(manager,tmp); + Cudd_RecursiveDerefZdd(manager,var); + tmp = f; + } + f = Cudd_zddDiff(manager,Cudd_ReadZddOne(manager,0),tmp); + Cudd_Ref(f); + Cudd_RecursiveDerefZdd(manager,tmp); + if (verbosity) { + Cudd_zddPrintMinterm(manager,f); + printf("\n"); + } + Cudd_RecursiveDerefZdd(manager,f); + ret = Cudd_CheckZeroRef(manager); + if (ret != 0 && verbosity) { + printf("%d unexpected non-zero references\n", ret); + } + Cudd_Quit(manager); + return 0; +} + +/** + * @brief Basic test of arbitrary-precision arithmetic. + * @return 0 if successful; -1 otherwise. + */ +static int +testApa(int verbosity) +{ + if (verbosity) { + printf("DD_APA_BITS = %" PRIszt "\n", sizeof(DdApaDigit) * 8); + } + DdApaNumber an = Cudd_NewApaNumber(3); + Cudd_ApaSetToLiteral(3, an, (DdApaDigit) 0x0fa5); + Cudd_ApaAdd(3, an, an, an); + if (verbosity) { + Cudd_ApaPrintHex(stdout, 3, an); + printf("\n"); + } + DdApaDigit numbers[] = {1283805, 1283815, 15983557, 1598354, 15999999}; + size_t i; + for (i = 0; i < sizeof(numbers)/sizeof(DdApaDigit); i++) { + Cudd_ApaSetToLiteral(3, an, numbers[i]); + if (verbosity) { + Cudd_ApaPrintDecimal(stdout, 3, an); + printf(" -> "); + Cudd_ApaPrintExponential(stdout, 3, an, 6); + printf("\n"); + } + } + Cudd_FreeApaNumber(an); + return 0; +} + +/** + * @brief Basic test of Cudd_CountMinterm(). + * @return 0 if successful; -1 otherwise. + */ +static int +testCount(int verbosity) +{ + DdManager *dd; + DdNode *h; + int i, ret; + int const N = 2044; /* number of variables */ + + dd = Cudd_Init(N, 0, CUDD_UNIQUE_SLOTS, CUDD_CACHE_SLOTS, 0); + if (!dd) { + if (verbosity) { + printf("initialization failed\n"); + } + return -1; + } + /* Build a cube with N/2 variables. */ + h = Cudd_ReadOne(dd); + Cudd_Ref(h); + for (i = 0; i < N; i += 2) { + DdNode *var, *tmp; + var = Cudd_bddIthVar(dd, N-i-1); + tmp = Cudd_bddAnd(dd, h, var); + if (!tmp) { + Cudd_Quit(dd); + return -1; + } + Cudd_Ref(tmp); + Cudd_RecursiveDeref(dd, h); + h = tmp; + } + if (verbosity) { + printf("h (dbl) "); + Cudd_PrintDebug(dd, h, N, 1); + printf("h (apa) "); + Cudd_PrintSummary(dd, h, N, 1); + } + Cudd_RecursiveDeref(dd, h); + if (verbosity) { + printf("one[%d] (dbl) ", N); + Cudd_PrintDebug(dd, Cudd_ReadOne(dd), N, 1); + printf("one[%d] (apa) ", N); + Cudd_PrintSummary(dd, Cudd_ReadOne(dd), N, 1); + ret = Cudd_CheckZeroRef(dd); + printf("one[%d] (dbl) ", N+1); + Cudd_PrintDebug(dd, Cudd_ReadOne(dd), N+1, 1); + printf("one[%d] (apa) ", N+1); + Cudd_PrintSummary(dd, Cudd_ReadOne(dd), N+1, 1); + ret = Cudd_CheckZeroRef(dd); + } + if (verbosity && ret != 0) { + printf("%d non-zero references\n", ret); + } + Cudd_Quit(dd); + return 0; +} + +/** + * @brief Basic test of long double and EPD minterm computation. + * @return 0 if successful; -1 otherwise. + */ +static int +testLdbl(int verbosity) +{ + DdManager *dd; + DdNode *f, *g; + int i, ret; + int const N = 12; /* half the number of variables */ + long double cnt; + + dd = Cudd_Init(2*N, 0, CUDD_UNIQUE_SLOTS, CUDD_CACHE_SLOTS, 0); + if (!dd) { + if (verbosity) { + printf("initialization failed\n"); + } + return -1; + } + f = g = Cudd_ReadOne(dd); + Cudd_Ref(f); + Cudd_Ref(g); + for (i = 0; i < N; i++) { + DdNode *var1, *var2, *clause, *tmp; + var1 = Cudd_bddIthVar(dd, i); + var2 = Cudd_bddIthVar(dd, i+N); + clause = Cudd_bddOr(dd, var1, var2); + if (!clause) { + Cudd_Quit(dd); + return -1; + } + Cudd_Ref(clause); + tmp = Cudd_bddAnd(dd, f, clause); + if (!tmp) { + Cudd_Quit(dd); + return -1; + } + Cudd_Ref(tmp); + Cudd_RecursiveDeref(dd, clause); + Cudd_RecursiveDeref(dd, f); + f = tmp; + clause = Cudd_bddOr(dd, Cudd_Not(var1), Cudd_Not(var2)); + if (!clause) { + Cudd_Quit(dd); + return -1; + } + Cudd_Ref(clause); + tmp = Cudd_bddAnd(dd, g, clause); + if (!tmp) { + Cudd_Quit(dd); + return -1; + } + Cudd_Ref(tmp); + Cudd_RecursiveDeref(dd, clause); + Cudd_RecursiveDeref(dd, g); + g = tmp; + } + if (verbosity) { + printf("f"); + Cudd_PrintSummary(dd, f, 2*N, 0); + } + cnt = Cudd_LdblCountMinterm(dd, f, 2*N); + if (verbosity) { + printf("f has %Lg minterms\n", cnt); + } + if (verbosity) { + printf("EPD count for f = "); + ret = Cudd_EpdPrintMinterm(dd, f, 2*N); + printf("\n"); + if (!ret) { + printf("problem with EPD\n"); + } + } + Cudd_RecursiveDeref(dd, f); + if (verbosity) { + printf("g"); + Cudd_PrintSummary(dd, g, 2*N, 0); + } + cnt = Cudd_LdblCountMinterm(dd, g, 2*N); + if (verbosity) { + printf("g has %Lg minterms\n", cnt); + } + if (verbosity) { + printf("EPD count for g = "); + ret = Cudd_EpdPrintMinterm(dd, g, 2*N); + printf("\n"); + if (!ret) { + printf("problem with EPD\n"); + } + } + Cudd_RecursiveDeref(dd, g); + ret = Cudd_CheckZeroRef(dd); + if (verbosity && ret != 0) { + printf("%d non-zero references\n", ret); + } + Cudd_Quit(dd); + return 0; +} + + +/** + * @brief Basic test of timeout handler. + * + * @details Sets a short timeout and then tries to build a function + * with a large BDD. Strives to avoid leaking nodes. + * + * @return 0 if successful; -1 otherwise. + */ +static int +testTimeout(int verbosity) +{ + DdManager *dd; + /* Declare these "volatile" to prevent clobbering by longjmp. */ + DdNode * volatile f; + DdNode * volatile clause = NULL; + DdNode * var1, * var2; + int i, ret, count; + int const N = 20; /* half the number of variables in f */ + unsigned long timeout = 100UL; /* in milliseconds */ + jmp_buf timeoutEnv; + + dd = Cudd_Init(0, 0, CUDD_UNIQUE_SLOTS, CUDD_CACHE_SLOTS, 0); + if (!dd) { + if (verbosity) { + printf("initialization failed\n"); + } + return -1; + } + + /* Set up timeout handling. */ + if (setjmp(timeoutEnv) > 0) { + if (verbosity) { + printf("caught timeout\n"); + } + /* The nodes of clause may be leaked if the timeout was + * detected while conjoining the clause to f. We set + * clause to NULL when it's not in use to be able to + * detect this case. + */ + if (clause) + Cudd_RecursiveDeref(dd, clause); + goto finally; + } + (void) Cudd_RegisterTimeoutHandler(dd, timeoutHandler, (void *) &timeoutEnv); + (void) Cudd_SetTimeLimit(dd, timeout); + + /* Try to build function. This is expected to run out of time. */ + f = Cudd_ReadOne(dd); + Cudd_Ref(f); + for (i = 0; i < N; i++) { + DdNode * tmp; + var1 = Cudd_bddIthVar(dd, i); + if (!var1) { + if (verbosity) { + printf("computation failed\n"); + return -1; + } + } + var2 = Cudd_bddIthVar(dd, i+N); + if (!var2) { + if (verbosity) { + printf("computation failed\n"); + return -1; + } + } + clause = Cudd_bddOr(dd, var1, var2); + if (!clause) { + if (verbosity) { + printf("computation failed\n"); + } + return -1; + } + Cudd_Ref(clause); + tmp = Cudd_bddAnd(dd, f, clause); + if (!tmp) { + if (verbosity) { + printf("computation failed\n"); + } + return -1; + } + Cudd_Ref(tmp); + Cudd_RecursiveDeref(dd, clause); + clause = NULL; + Cudd_RecursiveDeref(dd, f); + f = tmp; + } + if (verbosity > 1) { + Cudd_bddPrintCover(dd, f, f); + } + + finally: + if (verbosity) { + printf("so far"); + Cudd_PrintSummary(dd, f, 2*N, 0); + } + count = 0; + for (i = 0; i < N-1; i += 2) { + var1 = Cudd_bddIthVar(dd, i); + if (!var1) { + printf("computation failed\n"); + return -1; + } + var2 = Cudd_bddIthVar(dd, i+1); + if (!var2) { + printf("computation failed\n"); + return -1; + } + clause = Cudd_bddOr(dd, var1, var2); + if (!clause) { + printf("computation failed\n"); + return -1; + } + Cudd_Ref(clause); + if (Cudd_bddLeq(dd, f, clause)) { + count++; + } + Cudd_RecursiveDeref(dd, clause); + } + if (verbosity) { + printf("f implies %d clauses\n", count); + } + Cudd_RecursiveDeref(dd, f); + ret = Cudd_CheckZeroRef(dd); + if (verbosity) { + Cudd_PrintInfo(dd, stdout); + if (ret != 0) { + printf("%d non-zero references\n", ret); + } + } + Cudd_Quit(dd); + return 0; +} + +/** + * @brief Timeout handler. + */ +static void +timeoutHandler(DdManager * dd, void * arg) +{ + jmp_buf * timeoutEnv = (jmp_buf *) arg; + /* Reset manager. */ + Cudd_ClearErrorCode(dd); + Cudd_UnsetTimeLimit(dd); + Cudd_RegisterTimeoutHandler(dd, NULL, NULL); + + longjmp(*timeoutEnv, 1); +} diff --git a/resources/3rdparty/cudd-3.0.0/dddmp/Included.am b/resources/3rdparty/cudd-3.0.0/dddmp/Included.am new file mode 100644 index 000000000..da035e7ba --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/dddmp/Included.am @@ -0,0 +1,51 @@ +dddmp_sources = dddmp/dddmp.h dddmp/dddmpInt.h \ + dddmp/dddmpBinary.c dddmp/dddmpConvert.c dddmp/dddmpDbg.c \ + dddmp/dddmpLoad.c dddmp/dddmpLoadCnf.c dddmp/dddmpNodeAdd.c \ + dddmp/dddmpNodeBdd.c dddmp/dddmpNodeCnf.c dddmp/dddmpStoreAdd.c \ + dddmp/dddmpStoreBdd.c dddmp/dddmpStoreCnf.c dddmp/dddmpStoreMisc.c \ + dddmp/dddmpUtil.c + +if DDDMP +cudd_libcudd_la_SOURCES += $(dddmp_sources) +else +noinst_LTLIBRARIES += dddmp/libdddmp.la +dddmp_libdddmp_la_SOURCES = $(dddmp_sources) +dddmp_libdddmp_la_CPPFLAGS = -I$(top_srcdir)/util -I$(top_srcdir)/mtr \ + -I$(top_srcdir)/epd -I$(top_srcdir)/cudd -I$(top_srcdir)/st +endif !DDDMP + +check_PROGRAMS += dddmp/testdddmp +dddmp_testdddmp_SOURCES = dddmp/testdddmp.c +if DDDMP +dddmp_testdddmp_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +dddmp_testdddmp_LDADD = +else +dddmp_testdddmp_CPPFLAGS = $(dddmp_libdddmp_la_CPPFLAGS) +dddmp_testdddmp_LDADD = dddmp/libdddmp.la +endif !DDDMP +dddmp_testdddmp_LDADD += cudd/libcudd.la + +check_SCRIPTS += dddmp/test_dddmp.test +if !CROSS_COMPILING +TESTS += dddmp/test_dddmp.test +endif !CROSS_COMPILING +EXTRA_DIST += dddmp/README.dddmp dddmp/README.testdddmp dddmp/RELEASE_NOTES \ + dddmp/doc dddmp/test_dddmp.test.in dddmp/exp/test1.sh.in \ + dddmp/exp/test2.sh.in dddmp/exp/test3.sh.in dddmp/exp/test4.sh.in \ + dddmp/exp/test5.sh.in dddmp/exp/test6.sh.in dddmp/exp/test7.sh.in \ + dddmp/exp/0.add dddmp/exp/0.bdd dddmp/exp/0or1.bdd dddmp/exp/1.add \ + dddmp/exp/1.bdd dddmp/exp/2and3.bdd dddmp/exp/2.bdd dddmp/exp/3.bdd \ + dddmp/exp/4.bdd dddmp/exp/4.bdd.bis1 dddmp/exp/4.bdd.bis2 \ + dddmp/exp/4.bdd.bis3 dddmp/exp/4.bdd.bis4 dddmp/exp/4bis.bdd dddmp/exp/4.cnf \ + dddmp/exp/4.cnf.bis dddmp/exp/4.max1 dddmp/exp/4.max2 dddmp/exp/4xor5.bdd \ + dddmp/exp/5.bdd dddmp/exp/composeids.txt dddmp/exp/one.bdd \ + dddmp/exp/s27deltaDddmp1.bdd dddmp/exp/s27deltaDddmp1.bdd.bis \ + dddmp/exp/s27deltaDddmp2.bdd dddmp/exp/s27RP1.bdd dddmp/exp/varauxids.ord \ + dddmp/exp/varnames.ord dddmp/exp/zero.bdd + +dddmp/test_dddmp.test: dddmp/test_dddmp.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ + +CLEANFILES += dddmp/exp/test1.sh dddmp/exp/test2.sh dddmp/exp/test3.sh \ + dddmp/exp/test4.sh dddmp/exp/test5.sh dddmp/exp/test6.sh dddmp/exp/test7.sh diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/README.dddmp b/resources/3rdparty/cudd-3.0.0/dddmp/README.dddmp similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/README.dddmp rename to resources/3rdparty/cudd-3.0.0/dddmp/README.dddmp diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/README.testdddmp b/resources/3rdparty/cudd-3.0.0/dddmp/README.testdddmp similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/README.testdddmp rename to resources/3rdparty/cudd-3.0.0/dddmp/README.testdddmp diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/RELEASE_NOTES b/resources/3rdparty/cudd-3.0.0/dddmp/RELEASE_NOTES similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/RELEASE_NOTES rename to resources/3rdparty/cudd-3.0.0/dddmp/RELEASE_NOTES diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmp.h b/resources/3rdparty/cudd-3.0.0/dddmp/dddmp.h similarity index 99% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmp.h rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmp.h index 7228fe7ff..4792d6f79 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmp.h +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmp.h @@ -58,8 +58,8 @@ extern "C" { * Returned values (for theorically ALL the function of the package) */ -#define DDDMP_FAILURE ((int) 0) -#define DDDMP_SUCCESS ((int) 1) +#define DDDMP_FAILURE 0 +#define DDDMP_SUCCESS 1 /* * Format modes for DD (BDD and ADD) files diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpBinary.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpBinary.c similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpBinary.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpBinary.c diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpConvert.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpConvert.c similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpConvert.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpConvert.c diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpDbg.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpDbg.c similarity index 98% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpDbg.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpDbg.c index 88304f5af..e37916650 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpDbg.c +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpDbg.c @@ -83,6 +83,7 @@ Dddmp_cuddBddDisplayBinary( struct binary_dd_code code; char buf[1000]; int nnodes, i; + char *retval; fp = fopen (fileIn, "rb"); if (fp == 0) { @@ -141,8 +142,8 @@ Dddmp_cuddBddDisplayBinary( } - fgets(buf, 999,fp); - if (strncmp(buf, ".end", 4) != 0) { + retval = fgets(buf, 999,fp); + if (!retval || strncmp(buf, ".end", 4) != 0) { return (0); } diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpInt.h b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpInt.h similarity index 99% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpInt.h rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpInt.h index 1ebab9a3c..7d0f54dfc 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpInt.h +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpInt.h @@ -190,7 +190,7 @@ extern int DddmpNumberDdNodesCnf(DdManager *ddMgr, DdNode **f, int rootN, int *c extern int DddmpDdNodesCountEdgesAndNumber(DdManager *ddMgr, DdNode **f, int rootN, int edgeInTh, int pathLengthTh, int *cnfIds, int id); extern void DddmpUnnumberDdNodesCnf(DdManager *ddMgr, DdNode **f, int rootN); extern int DddmpPrintBddAndNext(DdManager *ddMgr, DdNode **f, int rootN); -extern int DddmpWriteNodeIndexCnfBis(DdNode *f, int id); +extern int DddmpWriteNodeIndexCnf(DdNode *f, int id); extern int DddmpVisitedCnf(DdNode *f); extern void DddmpSetVisitedCnf(DdNode *f); extern int DddmpReadNodeIndexCnf(DdNode *f); diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpLoad.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpLoad.c similarity index 98% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpLoad.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpLoad.c index 92db616c8..d00502e2c 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpLoad.c +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpLoad.c @@ -37,9 +37,6 @@ ******************************************************************************/ #include "dddmpInt.h" -#include "ucbqsort.h" - -#include <stdlib.h> /*---------------------------------------------------------------------------*/ /* Stucture declarations */ @@ -637,6 +634,7 @@ DddmpCuddDdArrayLoad ( unsigned short *pvars2byte = NULL; DdNode **proots = NULL; int fileToClose = 0; + char *retval; *pproots = NULL; @@ -710,7 +708,7 @@ DddmpCuddDdArrayLoad ( sortedvarnames[i] = Hdr->suppVarNames[i]; } - cudd__qsort ((void *) sortedvarnames, Hdr->nsuppvars, + qsort ((void *) sortedvarnames, Hdr->nsuppvars, sizeof(char *), QsortStrcmp); } @@ -1112,7 +1110,8 @@ DddmpCuddDdArrayLoad ( /*------------------------ Deal With the File Tail -----------------------*/ - fgets (buf, DDDMP_MAXSTRLEN-1,fp); + retval = fgets (buf, DDDMP_MAXSTRLEN-1,fp); + Dddmp_CheckAndGotoLabel (!retval, "Error on reading file tail.", failure); Dddmp_CheckAndGotoLabel (!matchkeywd(buf, ".end"), "Error .end not found.", failure); @@ -1237,6 +1236,7 @@ DddmpBddReadHeader ( Dddmp_Hdr_t *Hdr = NULL; char buf[DDDMP_MAXSTRLEN]; int retValue, fileToClose = 0; + char *retval; if (fp == NULL) { fp = fopen (file, "r"); @@ -1276,7 +1276,8 @@ DddmpBddReadHeader ( /* comment */ if (buf[0] == '#') { - fgets(buf,DDDMP_MAXSTRLEN,fp); + retval = fgets(buf,DDDMP_MAXSTRLEN,fp); + Dddmp_CheckAndGotoLabel (!retval, "Error on reading comment.", failure); continue; } @@ -1371,7 +1372,7 @@ DddmpBddReadHeader ( } if (matchkeywd(buf, ".suppvarnames") || - ((strcmp (Hdr->ver, "DDDMP-1.0") == 0) && + (Hdr->ver != NULL && (strcmp (Hdr->ver, "DDDMP-1.0") == 0) && matchkeywd (buf, ".varnames"))) { Hdr->suppVarNames = DddmpStrArrayRead (fp, Hdr->nsuppvars); Dddmp_CheckAndGotoLabel (Hdr->suppVarNames==NULL, @@ -1429,7 +1430,8 @@ DddmpBddReadHeader ( } if (matchkeywd(buf, ".nodes")) { - fgets(buf,DDDMP_MAXSTRLEN,fp); + retval = fgets(buf,DDDMP_MAXSTRLEN,fp); + Dddmp_CheckAndGotoLabel (!retval, "Error on reading nodes.", failure); break; } diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpLoadCnf.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpLoadCnf.c similarity index 97% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpLoadCnf.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpLoadCnf.c index 35bec273b..3642b8c69 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpLoadCnf.c +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpLoadCnf.c @@ -420,6 +420,12 @@ DddmpCuddDdArrayLoadCnf ( int **cnfTable = NULL; int fileToClose = 0; int retValue, i; + (void) rootmatchmode; /* avoid warning */ + (void) rootmatchnames; /* avoid warning */ + (void) varmatchmode; /* avoid warning */ + (void) varmatchnames; /* avoid warning */ + (void) varmatchauxids; /* avoid warning */ + (void) varcomposeids; /* avoid warning */ fileToClose = 0; *rootsPtrPtr = NULL; @@ -515,6 +521,7 @@ DddmpBddReadHeaderCnf ( Dddmp_Hdr_t *Hdr = NULL; char buf[DDDMP_MAXSTRLEN]; int nv, nc, retValue, fileToClose = 0; + char *fgetsRet; if (fp == NULL) { fp = fopen (file, "r"); @@ -554,7 +561,9 @@ DddmpBddReadHeaderCnf ( /* Init Problem Line */ if (buf[0] == 'p') { - fscanf (fp, "%*s %d %d", &nv, &nc); + retValue = fscanf (fp, "%*s %d %d", &nv, &nc); + Dddmp_CheckAndGotoLabel (retValue!=2, "Error reading problem line.", + failure); Hdr->nVarsCnf = nv; Hdr->nClausesCnf = nc; break; @@ -569,7 +578,8 @@ DddmpBddReadHeaderCnf ( /* Skip Comment? */ if (buf[0] != '.') { - fgets (buf, DDDMP_MAXSTRLEN, fp); + fgetsRet = fgets (buf, DDDMP_MAXSTRLEN, fp); + Dddmp_CheckAndGotoLabel (!fgetsRet, "Error reading comment.", failure); continue; } @@ -786,6 +796,7 @@ DddmpReadCnfClauses ( int i, j, var; int **cnfTableLocal = NULL; int *clause = NULL; + char *fgetsRet; cnfTableLocal = DDDMP_ALLOC (int *, Hdr->nClausesCnf); clause = DDDMP_ALLOC (int, 2*Hdr->nVarsCnf+1); @@ -811,7 +822,8 @@ DddmpReadCnfClauses ( /* Check for Comment */ if (word[0] == 'c') { /* Comment Found: Skip line */ - fgets (word, DDDMP_MAX_CNF_ROW_LENGTH-1, fp); + fgetsRet = fgets (word, DDDMP_MAX_CNF_ROW_LENGTH-1, fp); + if (!fgetsRet) return (DDDMP_FAILURE); break; } diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpNodeAdd.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpNodeAdd.c similarity index 99% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpNodeAdd.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpNodeAdd.c index 6fca772f1..5185c572c 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpNodeAdd.c +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpNodeAdd.c @@ -155,7 +155,7 @@ DddmpWriteNodeIndexAdd ( ) { if (1 || !Cudd_IsConstant (f)) { - f->next = (struct DdNode *)((ptruint)((id)<<1)); + f->next = (struct DdNode *)((ptruint)id<<1); } return; diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpNodeBdd.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpNodeBdd.c similarity index 99% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpNodeBdd.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpNodeBdd.c index 17f7fe39a..8699a91e9 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpNodeBdd.c +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpNodeBdd.c @@ -155,7 +155,7 @@ DddmpWriteNodeIndexBdd ( ) { if (!Cudd_IsConstant (f)) { - f->next = (struct DdNode *)((ptruint)((id)<<1)); + f->next = (struct DdNode *)((ptruint)id<<1); } return; diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpNodeCnf.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpNodeCnf.c similarity index 95% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpNodeCnf.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpNodeCnf.c index fa61ace69..1aacadce4 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpNodeCnf.c +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpNodeCnf.c @@ -55,7 +55,9 @@ /*---------------------------------------------------------------------------*/ static int DddmpWriteNodeIndexCnfWithTerminalCheck(DdNode *f, int *cnfIds, int id); +#if 0 static int DddmpClearVisitedCnfRecur(DdNode *f); +#endif static void DddmpClearVisitedCnf(DdNode *f); static int NumberNodeRecurCnf(DdNode *f, int *cnfIds, int id); static void DddmpDdNodesCheckIncomingAndScanPath(DdNode *f, int pathLengthCurrent, int edgeInTh, int pathLengthTh); @@ -142,7 +144,7 @@ DddmpDdNodesCountEdgesAndNumber ( int id /* OUT: Number of Temporary Variables Introduced */ ) { - int retValue, i; + int i; /*-------------------------- Remove From Unique ---------------------------*/ @@ -153,7 +155,7 @@ DddmpDdNodesCountEdgesAndNumber ( /*-------------------- Reset Counter and Reset Visited --------------------*/ for (i=0; i<rootN; i++) { - retValue = DddmpDdNodesResetCountRecur (f[i]); + (void) DddmpDdNodesResetCountRecur (f[i]); } /* Here we must have: @@ -170,7 +172,7 @@ DddmpDdNodesCountEdgesAndNumber ( /*----------------------- Count Incoming Edges ----------------------------*/ for (i=0; i<rootN; i++) { - retValue = DddmpDdNodesCountEdgesRecur (f[i]); + (void) DddmpDdNodesCountEdgesRecur (f[i]); } /* Here we must have: @@ -307,7 +309,7 @@ DddmpWriteNodeIndexCnf ( ) { if (!Cudd_IsConstant (f)) { - f->next = (struct DdNode *)((ptruint)((id)<<1)); + f->next = (struct DdNode *)((ptruint)id<<1); } return (DDDMP_SUCCESS); @@ -418,9 +420,9 @@ DddmpWriteNodeIndexCnfWithTerminalCheck ( if (!Cudd_IsConstant (f)) { if (Cudd_IsConstant (cuddT (f)) && Cudd_IsConstant (cuddE (f))) { /* If Variable SET ID as Variable ID */ - f->next = (struct DdNode *)((ptruint)((cnfIds[f->index])<<1)); + f->next = (struct DdNode *)((ptruint)cnfIds[f->index]<<1); } else { - f->next = (struct DdNode *)((ptruint)((id)<<1)); + f->next = (struct DdNode *)((ptruint)id<<1); id++; } } @@ -428,6 +430,7 @@ DddmpWriteNodeIndexCnfWithTerminalCheck ( return(id); } +#if 0 /**Function******************************************************************** Synopsis [Mark ALL nodes as not visited] @@ -445,8 +448,6 @@ DddmpClearVisitedCnfRecur ( DdNode *f /* IN: root of the BDD to be marked */ ) { - int retValue; - f = Cudd_Regular(f); if (cuddIsConstant (f)) { @@ -457,13 +458,14 @@ DddmpClearVisitedCnfRecur ( return (DDDMP_SUCCESS); } - retValue = DddmpClearVisitedCnfRecur (cuddT (f)); - retValue = DddmpClearVisitedCnfRecur (cuddE (f)); + (void) DddmpClearVisitedCnfRecur (cuddT (f)); + (void) DddmpClearVisitedCnfRecur (cuddE (f)); DddmpClearVisitedCnf (f); return (DDDMP_SUCCESS); } +#endif /**Function******************************************************************** @@ -660,8 +662,6 @@ DddmpDdNodesResetCountRecur ( DdNode *f /* IN: root of the BDD whose counters are reset */ ) { - int retValue; - f = Cudd_Regular (f); if (!DddmpVisitedCnf (f)) { @@ -669,8 +669,8 @@ DddmpDdNodesResetCountRecur ( } if (!cuddIsConstant (f)) { - retValue = DddmpDdNodesResetCountRecur (cuddT (f)); - retValue = DddmpDdNodesResetCountRecur (cuddE (f)); + (void) DddmpDdNodesResetCountRecur (cuddT (f)); + (void) DddmpDdNodesResetCountRecur (cuddE (f)); } DddmpWriteNodeIndexCnf (f, 0); @@ -698,7 +698,7 @@ DddmpDdNodesCountEdgesRecur ( DdNode *f /* IN: root of the BDD */ ) { - int indexValue, retValue; + int indexValue; f = Cudd_Regular (f); @@ -714,8 +714,8 @@ DddmpDdNodesCountEdgesRecur ( /* IF (first time) THEN recur */ if (indexValue == 0) { - retValue = DddmpDdNodesCountEdgesRecur (cuddT (f)); - retValue = DddmpDdNodesCountEdgesRecur (cuddE (f)); + (void) DddmpDdNodesCountEdgesRecur (cuddT (f)); + (void) DddmpDdNodesCountEdgesRecur (cuddE (f)); } /* Increment Incoming-Edge Count Flag */ @@ -893,26 +893,25 @@ DddmpPrintBddAndNextRecur ( DdNode *f /* IN: root of the BDD to be displayed */ ) { - int retValue; DdNode *fPtr, *tPtr, *ePtr; - + fPtr = Cudd_Regular (f); - + if (Cudd_IsComplement (f)) { - fprintf (stdout, "sign=- ptr=%ld ", ((long int) fPtr)); + fprintf (stdout, "sign=- ptr=%" PRIiPTR " ", ((ptrint) fPtr)); } else { - fprintf (stdout, "sign=+ ptr=%ld ", ((long int) fPtr)); + fprintf (stdout, "sign=+ ptr=%" PRIiPTR " ", ((ptrint) fPtr)); } - + if (cuddIsConstant (fPtr)) { fprintf (stdout, "one\n"); fflush (stdout); return (DDDMP_SUCCESS); } - fprintf (stdout, - "thenPtr=%ld elsePtr=%ld BddId=%d CnfId=%d Visited=%d\n", - ((long int) cuddT (fPtr)), ((long int) cuddE (fPtr)), + fprintf (stdout, + "thenPtr=%" PRIiPTR " elsePtr=%" PRIiPTR " BddId=%d CnfId=%d Visited=%d\n", + ((ptrint) cuddT (fPtr)), ((ptrint) cuddE (fPtr)), fPtr->index, DddmpReadNodeIndexCnf (fPtr), DddmpVisitedCnf (fPtr)); @@ -923,8 +922,8 @@ DddmpPrintBddAndNextRecur ( ePtr = Cudd_Not (ePtr); } - retValue = DddmpPrintBddAndNextRecur (ddMgr, tPtr); - retValue = DddmpPrintBddAndNextRecur (ddMgr, ePtr); + (void) DddmpPrintBddAndNextRecur (ddMgr, tPtr); + (void) DddmpPrintBddAndNextRecur (ddMgr, ePtr); return (DDDMP_SUCCESS); } diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreAdd.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreAdd.c similarity index 99% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreAdd.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreAdd.c index a86e39ada..b304a8869 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreAdd.c +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreAdd.c @@ -746,12 +746,8 @@ NodeStoreRecurAdd ( int idT = (-1); int idE = (-1); int vf = (-1); - int vT = (-1); - int vE = (-1); int retValue; - int nVars; - nVars = ddMgr->size; T = E = NULL; idf = idT = idE = (-1); @@ -814,18 +810,8 @@ NodeStoreRecurAdd ( vf = f->index; idT = DddmpReadNodeIndexAdd (T); - if (Cudd_IsConstant(T)) { - vT = nVars; - } else { - vT = T->index; - } idE = DddmpReadNodeIndexAdd (E); - if (Cudd_IsConstant(E)) { - vE = nVars; - } else { - vE = E->index; - } } retValue = NodeTextStoreAdd (ddMgr, f, mode, supportids, varnames, @@ -864,6 +850,7 @@ NodeTextStoreAdd ( ) { int retValue; + (void) mode; /* avoid warning */ /* * Check for Constant diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreBdd.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreBdd.c similarity index 99% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreBdd.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreBdd.c index cdc796843..aa9ee4452 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreBdd.c +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreBdd.c @@ -881,6 +881,7 @@ NodeTextStoreBdd ( ) { int retValue = EOF; + (void) mode; /* avoid warning */ /* * Check for Constant @@ -1005,7 +1006,9 @@ NodeBinaryStoreBdd ( { int retValue, diff, var; struct binary_dd_code code; - + (void) mode; /* avoid warning */ + (void) varnames; /* avoid warning */ + (void) outids; /* avoid warning */ /* * Check for Constant */ diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreCnf.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreCnf.c similarity index 99% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreCnf.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreCnf.c index 35b9b6978..0806da077 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreCnf.c +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreCnf.c @@ -316,10 +316,8 @@ DddmpCuddBddArrayStoreCnf ( int *bddIdsInSupport = NULL; int *permIdsInSupport = NULL; int *rootStartLine = NULL; - int nVar, nVarInSupport, retValue, i, fileToClose; - int varMax, clauseN, flagVar; - size_t intStringLength; - size_t j; + int nVar, nVarInSupport, retValue, i, j, fileToClose; + int varMax, clauseN, flagVar, intStringLength; int bddIdsToFree = 0; int bddAuxIdsToFree = 0; int cnfIdsToFree = 0; @@ -1108,6 +1106,7 @@ StoreCnfMaxtermByMaxterm ( ) { int i, j, *list; + (void) idInitial; /* avoid warning */ list = DDDMP_ALLOC (int, ddMgr->size); if (list == NULL) { @@ -1173,6 +1172,7 @@ StoreCnfBest ( ) { int i, j, *list; + (void) idInitial; /* avoid warning */ list = DDDMP_ALLOC (int, ddMgr->size); if (list == NULL) { @@ -1340,10 +1340,7 @@ StoreCnfBestNotSharedRecur ( { DdNode *N, *Nv, *Nnv; int index, retValue; - DdNode *one; - one = ddMgr->one; - N = Cudd_Regular (node); /* @@ -1461,10 +1458,7 @@ StoreCnfBestSharedRecur ( ) { DdNode *nodeThen, *nodeElse; - int i, idf, index; - DdNode *one; - - one = ddMgr->one; + int i, idf; Dddmp_Assert (node==Cudd_Regular(node), "Inverted Edge during Shared Printing."); @@ -1486,7 +1480,7 @@ StoreCnfBestSharedRecur ( idf = DddmpReadNodeIndexCnf (node); if (idf > 0) { /* Cheat the Recur Function about the Index of the Current Node */ - DddmpWriteNodeIndexCnfBis (node, 0); + DddmpWriteNodeIndexCnf (node, 0); #if DDDMP_DEBUG_CNF fprintf (fp, "Else of XNOR\n"); @@ -1507,7 +1501,7 @@ StoreCnfBestSharedRecur ( fp, list, clauseN, varMax); /* Set Back Index of Current Node */ - DddmpWriteNodeIndexCnfBis (node, idf); + DddmpWriteNodeIndexCnf (node, idf); } /* Mark node as visited. */ @@ -1519,7 +1513,6 @@ StoreCnfBestSharedRecur ( nodeThen = cuddT (node); nodeElse = cuddE (node); - index = node->index; StoreCnfBestSharedRecur (ddMgr, Cudd_Regular (nodeThen), bddIds, cnfIds, fp, list, clauseN, varMax); diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreMisc.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreMisc.c similarity index 87% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreMisc.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreMisc.c index 2dc18f046..c8c2195f0 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpStoreMisc.c +++ b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpStoreMisc.c @@ -100,6 +100,7 @@ Dddmp_cuddBddStorePrefix ( { int retValue; DdNode *tmpArray[1]; + (void) nRoots; /* avoid warning */ tmpArray[0] = f; @@ -226,6 +227,7 @@ Dddmp_cuddBddStoreBlif ( { int retValue; DdNode *tmpArray[1]; + (void) nRoots; /* avoid warning */ tmpArray[0] = f; @@ -352,6 +354,7 @@ Dddmp_cuddBddStoreSmv ( { int retValue; DdNode *tmpArray[1]; + (void) nRoots; /* avoid warning */ tmpArray[0] = f; @@ -662,21 +665,11 @@ DddmpCuddDdArrayStorePrefixBody ( "Error during file store.", failure); if (Cudd_IsComplement(f[i])) { -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, "(NOT node%lx))\n", - (unsigned long) f[i] / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, "(NOT node%x))\n", - (unsigned) f[i] / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "(NOT node%" PRIxPTR "))\n", + (ptruint) f[i] / sizeof(DdNode)); } else { -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, "node%lx)\n", - (unsigned long) f[i] / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, "node%x)\n", - (unsigned) f[i] / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "node%" PRIxPTR ")\n", + (ptruint) f[i] / sizeof(DdNode)); } Dddmp_CheckAndGotoLabel (retValue==EOF, "Error during file store.", failure); @@ -751,15 +744,8 @@ DddmpCuddDdArrayStorePrefixStep ( /* Check for special case: If constant node, generate constant 1. */ if (f == DD_ONE (ddMgr)) { -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, - "(OR node%lx vss vdd)\n", - (unsigned long) f / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, - "(OR node%x vss vdd)\n", - (unsigned) f / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "(OR node%" PRIxPTR " vss vdd)\n", + (ptruint) f / sizeof(DdNode)); if (retValue == EOF) { return(0); } else { @@ -773,15 +759,8 @@ DddmpCuddDdArrayStorePrefixStep ( */ if (f == DD_ZERO(ddMgr)) { -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, - "(AND node%lx vss vdd)\n", - (unsigned long) f / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, - "(AND node%x vss vdd)\n", - (unsigned) f / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "(AND node%" PRIxPTR " vss vdd)\n", + (ptruint) f / sizeof(DdNode)); if (retValue == EOF) { return(0); } else { @@ -806,13 +785,8 @@ DddmpCuddDdArrayStorePrefixStep ( } /* Write multiplexer taking complement arc into account. */ -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, "(OR node%lx (AND ", - (unsigned long) f / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, "(OR node%x (AND ", - (unsigned) f / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "(OR node%" PRIxPTR " (AND ", + (ptruint) f / sizeof(DdNode)); if (retValue == EOF) { return(0); } @@ -826,13 +800,8 @@ DddmpCuddDdArrayStorePrefixStep ( return(0); } -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, "node%lx) (AND (NOT ", - (unsigned long) T / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, "node%x) (AND (NOT ", - (unsigned) T / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "node%" PRIxPTR ") (AND (NOT ", + (ptruint) T / sizeof(DdNode)); if (retValue == EOF) { return(0); } @@ -846,23 +815,13 @@ DddmpCuddDdArrayStorePrefixStep ( return(0); } -#if SIZEOF_VOID_P == 8 - if (Cudd_IsComplement(cuddE(f))) { - retValue = fprintf (fp, ") (NOT node%lx)))\n", - (unsigned long) E / (unsigned long) sizeof(DdNode)); - } else { - retValue = fprintf (fp, ") node%lx))\n", - (unsigned long) E / (unsigned long) sizeof(DdNode)); - } -#else if (Cudd_IsComplement(cuddE(f))) { - retValue = fprintf (fp, ") (NOT node%x)))\n", - (unsigned) E / (unsigned) sizeof(DdNode)); + retValue = fprintf (fp, ") (NOT node%" PRIxPTR ")))\n", + (ptruint) E / sizeof(DdNode)); } else { - retValue = fprintf (fp, ") node%x))\n", - (unsigned) E / (unsigned) sizeof(DdNode)); + retValue = fprintf (fp, ") node%" PRIxPTR "))\n", + (ptruint) E / sizeof(DdNode)); } -#endif if (retValue == EOF) { return(0); @@ -1063,23 +1022,11 @@ DddmpCuddDdArrayStoreBlifBody ( for (i = 0; i < n; i++) { if (outputNames == NULL) { - retValue = fprintf(fp, -#if SIZEOF_VOID_P == 8 - ".names node%lx outNode%d\n", - (unsigned long) f[i] / (unsigned long) sizeof(DdNode), i); -#else - ".names node%x outNode%d\n", - (unsigned) f[i] / (unsigned) sizeof(DdNode), i); -#endif + retValue = fprintf(fp, ".names node%" PRIxPTR " outNode%d\n", + (ptruint) f[i] / sizeof(DdNode), i); } else { - retValue = fprintf(fp, -#if SIZEOF_VOID_P == 8 - ".names node%lx %s\n", - (unsigned long) f[i] / (unsigned long) sizeof(DdNode), outputNames[i]); -#else - ".names node%x %s\n", - (unsigned) f[i] / (unsigned) sizeof(DdNode), outputNames[i]); -#endif + retValue = fprintf(fp, ".names node%" PRIxPTR " %s\n", + (ptruint) f[i] / sizeof(DdNode), outputNames[i]); } Dddmp_CheckAndGotoLabel (retValue==EOF, "Error during file store.", failure); @@ -1152,13 +1099,8 @@ DddmpCuddDdArrayStoreBlifStep ( /* Check for special case: If constant node, generate constant 1. */ if (f == DD_ONE(ddMgr)) { -#if SIZEOF_VOID_P == 8 - retValue = fprintf(fp, ".names node%lx\n1\n", - (unsigned long) f / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf(fp, ".names node%x\n1\n", - (unsigned) f / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf(fp, ".names node%" PRIxPTR "\n1\n", + (ptruint) f / sizeof(DdNode)); if (retValue == EOF) { return(0); } else { @@ -1170,13 +1112,8 @@ DddmpCuddDdArrayStoreBlifStep ( ** with the general case. */ if (f == DD_ZERO(ddMgr)) { -#if SIZEOF_VOID_P == 8 - retValue = fprintf(fp, ".names node%lx\n", - (unsigned long) f / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf(fp, ".names node%x\n", - (unsigned) f / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf(fp, ".names node%" PRIxPTR "\n", + (ptruint) f / sizeof(DdNode)); if (retValue == EOF) { return(0); } else { @@ -1205,31 +1142,19 @@ DddmpCuddDdArrayStoreBlifStep ( return(0); } -#if SIZEOF_VOID_P == 8 if (Cudd_IsComplement(cuddE(f))) { - retValue = fprintf(fp," node%lx node%lx node%lx\n11- 1\n0-0 1\n", - (unsigned long) T / (unsigned long) sizeof(DdNode), - (unsigned long) E / (unsigned long) sizeof(DdNode), - (unsigned long) f / (unsigned long) sizeof(DdNode)); + retValue = fprintf(fp, + " node%" PRIxPTR " node%" PRIxPTR " node%" PRIxPTR "\n11- 1\n0-0 1\n", + (ptruint) T / sizeof(DdNode), + (ptruint) E / sizeof(DdNode), + (ptruint) f / sizeof(DdNode)); } else { - retValue = fprintf(fp," node%lx node%lx node%lx\n11- 1\n0-1 1\n", - (unsigned long) T / (unsigned long) sizeof(DdNode), - (unsigned long) E / (unsigned long) sizeof(DdNode), - (unsigned long) f / (unsigned long) sizeof(DdNode)); + retValue = fprintf(fp, + " node%" PRIxPTR " node%" PRIxPTR " node%" PRIxPTR "\n11- 1\n0-1 1\n", + (ptruint) T / sizeof(DdNode), + (ptruint) E / sizeof(DdNode), + (ptruint) f / sizeof(DdNode)); } -#else - if (Cudd_IsComplement(cuddE(f))) { - retValue = fprintf(fp," node%x node%x node%x\n11- 1\n0-0 1\n", - (unsigned) T / (unsigned) sizeof(DdNode), - (unsigned) E / (unsigned) sizeof(DdNode), - (unsigned) f / (unsigned) sizeof(DdNode)); - } else { - retValue = fprintf(fp," node%x node%x node%x\n11- 1\n0-1 1\n", - (unsigned) T / (unsigned) sizeof(DdNode), - (unsigned) E / (unsigned) sizeof(DdNode), - (unsigned) f / (unsigned) sizeof(DdNode)); - } -#endif if (retValue == EOF) { return(0); } else { @@ -1430,21 +1355,11 @@ DddmpCuddDdArrayStoreSmvBody ( "Error during file store.", failure); if (Cudd_IsComplement(f[i])) { -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, "!node%lx\n", - (unsigned long) f[i] / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, "!node%x\n", - (unsigned) f[i] / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "!node%" PRIxPTR "\n", + (ptruint) f[i] / sizeof(DdNode)); } else { -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, "node%lx\n", - (unsigned long) f[i] / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, "node%x\n", - (unsigned) f[i] / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "node%" PRIxPTR "\n", + (ptruint) f[i] / sizeof(DdNode)); } Dddmp_CheckAndGotoLabel (retValue==EOF, "Error during file store.", failure); @@ -1519,15 +1434,8 @@ DddmpCuddDdArrayStoreSmvStep ( /* Check for special case: If constant node, generate constant 1. */ if (f == DD_ONE (ddMgr)) { -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, - "node%lx := 1;\n", - (unsigned long) f / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, - "node%x := 1;\n", - (unsigned) f / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "node%" PRIxPTR " := 1;\n", + (ptruint) f / sizeof(DdNode)); if (retValue == EOF) { return(0); } else { @@ -1541,15 +1449,8 @@ DddmpCuddDdArrayStoreSmvStep ( */ if (f == DD_ZERO(ddMgr)) { -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, - "node%lx := 0;\n", - (unsigned long) f / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, - "node%x := 0;\n", - (unsigned) f / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "node%" PRIxPTR " := 0;\n", + (ptruint) f / sizeof(DdNode)); if (retValue == EOF) { return(0); } else { @@ -1574,13 +1475,8 @@ DddmpCuddDdArrayStoreSmvStep ( } /* Write multiplexer taking complement arc into account. */ -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, "node%lx := ", - (unsigned long) f / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, "node%x := ", - (unsigned) f / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "node%" PRIxPTR " := ", + (ptruint) f / sizeof(DdNode)); if (retValue == EOF) { return(0); } @@ -1594,13 +1490,8 @@ DddmpCuddDdArrayStoreSmvStep ( return(0); } -#if SIZEOF_VOID_P == 8 - retValue = fprintf (fp, "& node%lx | ", - (unsigned long) T / (unsigned long) sizeof(DdNode)); -#else - retValue = fprintf (fp, "& node%x | ", - (unsigned) T / (unsigned) sizeof(DdNode)); -#endif + retValue = fprintf (fp, "& node%" PRIxPTR " | ", + (ptruint) T / sizeof(DdNode)); if (retValue == EOF) { return(0); } @@ -1614,23 +1505,13 @@ DddmpCuddDdArrayStoreSmvStep ( return(0); } -#if SIZEOF_VOID_P == 8 if (Cudd_IsComplement(cuddE(f))) { - retValue = fprintf (fp, "& !node%lx\n", - (unsigned long) E / (unsigned long) sizeof(DdNode)); + retValue = fprintf (fp, "& !node%" PRIxPTR "\n", + (ptruint) E / sizeof(DdNode)); } else { - retValue = fprintf (fp, "& node%lx\n", - (unsigned long) E / (unsigned long) sizeof(DdNode)); + retValue = fprintf (fp, "& node%" PRIxPTR "\n", + (ptruint) E / sizeof(DdNode)); } -#else - if (Cudd_IsComplement(cuddE(f))) { - retValue = fprintf (fp, "& !node%x\n", - (unsigned) E / (unsigned) sizeof(DdNode)); - } else { - retValue = fprintf (fp, "& node%x\n", - (unsigned) E / (unsigned) sizeof(DdNode)); - } -#endif if (retValue == EOF) { return(0); diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpUtil.c b/resources/3rdparty/cudd-3.0.0/dddmp/dddmpUtil.c similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/dddmpUtil.c rename to resources/3rdparty/cudd-3.0.0/dddmp/dddmpUtil.c diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/cmdIndex.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/cmdIndex.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/cmdIndex.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/cmdIndex.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/commands.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/commands.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/commands.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/commands.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/credit.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/credit.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/credit.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/credit.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmp-2.0-A4.ps b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmp-2.0-A4.ps similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmp-2.0-A4.ps rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmp-2.0-A4.ps diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmp-2.0-Letter.ps b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmp-2.0-Letter.ps similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmp-2.0-Letter.ps rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmp-2.0-Letter.ps diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpAllAbs.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpAllAbs.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpAllAbs.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpAllAbs.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpAllByFile.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpAllByFile.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpAllByFile.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpAllByFile.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpAllByFunc.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpAllByFunc.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpAllByFunc.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpAllByFunc.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpAllDet.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpAllDet.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpAllDet.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpAllDet.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpAllFile.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpAllFile.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpAllFile.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpAllFile.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpDesc.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpDesc.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpDesc.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpDesc.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpDoc.txt b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpDoc.txt similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpDoc.txt rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpDoc.txt diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpExt.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpExt.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpExt.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpExt.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpExtAbs.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpExtAbs.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpExtAbs.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpExtAbs.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpExtDet.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpExtDet.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpExtDet.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpExtDet.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpTitle.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpTitle.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/dddmpTitle.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/dddmpTitle.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/packages.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/packages.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/packages.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/packages.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/doc/pkgIndex.html b/resources/3rdparty/cudd-3.0.0/dddmp/doc/pkgIndex.html similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/doc/pkgIndex.html rename to resources/3rdparty/cudd-3.0.0/dddmp/doc/pkgIndex.html diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/0.add b/resources/3rdparty/cudd-3.0.0/dddmp/exp/0.add similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/0.add rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/0.add diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/0.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/0.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/0.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/0.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/0or1.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/0or1.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/0or1.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/0or1.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/1.add b/resources/3rdparty/cudd-3.0.0/dddmp/exp/1.add similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/1.add rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/1.add diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/1.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/1.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/1.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/1.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/2.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/2.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/2.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/2.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/2and3.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/2and3.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/2and3.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/2and3.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/3.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/3.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/3.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/3.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/4.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/4.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.bdd.bis1 b/resources/3rdparty/cudd-3.0.0/dddmp/exp/4.bdd.bis1 similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.bdd.bis1 rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/4.bdd.bis1 diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.bdd.bis2 b/resources/3rdparty/cudd-3.0.0/dddmp/exp/4.bdd.bis2 similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.bdd.bis2 rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/4.bdd.bis2 diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.bdd.bis3 b/resources/3rdparty/cudd-3.0.0/dddmp/exp/4.bdd.bis3 similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.bdd.bis3 rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/4.bdd.bis3 diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.bdd.bis4 b/resources/3rdparty/cudd-3.0.0/dddmp/exp/4.bdd.bis4 similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.bdd.bis4 rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/4.bdd.bis4 diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.cnf b/resources/3rdparty/cudd-3.0.0/dddmp/exp/4.cnf similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.cnf rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/4.cnf diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.cnf.bis b/resources/3rdparty/cudd-3.0.0/dddmp/exp/4.cnf.bis similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.cnf.bis rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/4.cnf.bis diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.max1 b/resources/3rdparty/cudd-3.0.0/dddmp/exp/4.max1 similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.max1 rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/4.max1 diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.max2 b/resources/3rdparty/cudd-3.0.0/dddmp/exp/4.max2 similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4.max2 rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/4.max2 diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4bis.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/4bis.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4bis.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/4bis.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4xor5.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/4xor5.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/4xor5.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/4xor5.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/5.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/5.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/5.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/5.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/composeids.txt b/resources/3rdparty/cudd-3.0.0/dddmp/exp/composeids.txt similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/composeids.txt rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/composeids.txt diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/one.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/one.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/one.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/one.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/s27RP1.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/s27RP1.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/s27RP1.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/s27RP1.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/s27deltaDddmp1.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/s27deltaDddmp1.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/s27deltaDddmp1.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/s27deltaDddmp1.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/s27deltaDddmp1.bdd.bis b/resources/3rdparty/cudd-3.0.0/dddmp/exp/s27deltaDddmp1.bdd.bis similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/s27deltaDddmp1.bdd.bis rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/s27deltaDddmp1.bdd.bis diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/s27deltaDddmp2.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/s27deltaDddmp2.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/s27deltaDddmp2.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/s27deltaDddmp2.bdd diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test1.script b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test1.sh.in similarity index 71% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test1.script rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/test1.sh.in index 843e3650c..956400cff 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test1.script +++ b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test1.sh.in @@ -1,26 +1,33 @@ -# !/bin/sh +#! /bin/sh # # Check Header Load/Store for BDD/ADD/CNFs: # Load Header # Write Information on Standard Output # -rm -f *.*.tmp + +EXE=@EXEEXT@ +srcdir=@top_srcdir@ +where=${srcdir}/dddmp/exp +exitval=0 + echo "---------------------------------------------------------------------------" echo "--------------------- TESTING Load and Write Header -----------------------" echo "---------------------------------------------------------------------------" -./../testdddmp << END +../testdddmp$EXE << END mi 50 hlb -4.bdd +${where}/4.bdd hw hlb -0.add +${where}/0.add hw hlc -4.cnf +${where}/4.cnf hw mq quit END +test $? != 1 && exitval=1 echo "-------------------------------- ... END ----------------------------------" +exit $exitval diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test2.script b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test2.sh.in similarity index 57% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test2.script rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/test2.sh.in index f719ed2bb..b1fcd4235 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test2.script +++ b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test2.sh.in @@ -1,30 +1,39 @@ -# !/bin/sh +#! /bin/sh # # Check BDDs from DDDMP-1.0: # Load an Array of BDDs from DDDMP-1.0 # Store them # -rm -f *.*.tmp + +EXE=@EXEEXT@ +srcdir=@top_srcdir@ +where=${srcdir}/dddmp/exp +dest=. +exitval=0 + echo "---------------------------------------------------------------------------" echo "-------------------- TESTING Load BDD from DDDMP-1.0 ----------------------" echo "---------------------------------------------------------------------------" -./../testdddmp << END +../testdddmp$EXE << END mi 10 hlb -s27deltaDddmp1.bdd +${where}/s27deltaDddmp1.bdd hw bal -s27deltaDddmp1.bdd +${where}/s27deltaDddmp1.bdd 0 bas -s27deltaDddmp1.bdd.tmp +${dest}/s27deltaDddmp1.bdd.tmp 0 mq quit END +test $? != 1 && exitval=1 echo "----------------------------- ... RESULTS ... -----------------------------" -diff --brief s27deltaDddmp1.bdd.tmp s27deltaDddmp1.bdd.bis +diff --strip-trailing-cr --brief ${dest}/s27deltaDddmp1.bdd.tmp \ + ${where}/s27deltaDddmp1.bdd.bis +test $? != 0 && exitval=1 echo "-------------------------------- ... END ----------------------------------" -rm -f *.*.tmp - +rm -f ${dest}/s27deltaDddmp1.bdd.tmp +exit $exitval diff --git a/resources/3rdparty/cudd-3.0.0/dddmp/exp/test3.sh.in b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test3.sh.in new file mode 100644 index 000000000..94575cfad --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test3.sh.in @@ -0,0 +1,80 @@ +#! /bin/sh +# +# BDD check: +# Load BDDs +# Make some operations +# Store BDDs +# + +EXE=@EXEEXT@ +srcdir=@top_srcdir@ +where=${srcdir}/dddmp/exp +dest=. +exitval=0 + +echo "---------------------------------------------------------------------------" +echo "----------------------- TESTING basic Load/Store ... ----------------------" +echo "---------------------------------------------------------------------------" +../testdddmp$EXE << END +mi +50 +hlb +${where}/0or1.bdd +bl +${where}/0.bdd +0 +bl +${where}/1.bdd +1 +op +or +0 +1 +2 +bs +${dest}/0or1.bdd.tmp +2 +bl +${where}/2.bdd +2 +bl +${where}/3.bdd +3 +op +and +2 +3 +4 +bs +${dest}/2and3.bdd.tmp +4 +hlb +${where}/4xor5.bdd +bl +${where}/4.bdd +4 +bl +${where}/5.bdd +5 +op +xor +4 +5 +6 +bs +${dest}/4xor5.bdd.tmp +6 +mq +quit +END +test $? != 1 && exitval=1 +echo "----------------------------- ... RESULTS ... -----------------------------" +diff --strip-trailing-cr --brief ${where}/0or1.bdd ${dest}/0or1.bdd.tmp +test $? != 0 && exitval=1 +diff --strip-trailing-cr --brief ${where}/2and3.bdd ${dest}/2and3.bdd.tmp +test $? != 0 && exitval=1 +diff --strip-trailing-cr --brief ${where}/4xor5.bdd ${dest}/4xor5.bdd.tmp +test $? != 0 && exitval=1 +echo "-------------------------------- ... END ----------------------------------" +rm -f ${dest}/0or1.bdd.tmp ${dest}/2and3.bdd.tmp ${dest}/4xor5.bdd.tmp +exit $exitval diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test4.script b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test4.sh.in similarity index 52% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test4.script rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/test4.sh.in index 2c50992b1..4407ceefe 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test4.script +++ b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test4.sh.in @@ -1,56 +1,67 @@ -# !/bin/sh +#! /bin/sh # # BDD Check: # Load BDDs # Make some operations (with reordering) # Store BDDs # -rm -f *.*/tmp + +EXE=@EXEEXT@ +srcdir=@top_srcdir@ +where=${srcdir}/dddmp/exp +dest=. +exitval=0 + echo "---------------------------------------------------------------------------" echo "---------- TESTING Load/Store with sifting, varnames & varauxids ----------" echo "---------------------------------------------------------------------------" -./../testdddmp << END1 +../testdddmp$EXE << END1 mi 50 onl -varnames.ord +${where}/varnames.ord bl -4.bdd +${where}/4.bdd 4 oil -varauxids.ord +${where}/varauxids.ord bs -4a.bdd.tmp +${dest}/4a.bdd.tmp 4 dr 4 bs -4b.bdd.tmp +${dest}/4b.bdd.tmp 4 mq quit END1 +test $? != 1 && exitval=1 echo "------------------------- ... END PHASE 1 ... -----------------------------" -./../testdddmp << END2 +../testdddmp$EXE << END2 mi 50 onl -varnames.ord +${where}/varnames.ord slm 3 bl -4b.bdd.tmp +${dest}/4b.bdd.tmp 4 oil -varauxids.ord +${where}/varauxids.ord bs -4c.bdd.tmp +${dest}/4c.bdd.tmp 4 mq quit END2 +test $? != 1 && exitval=1 echo "----------------------------- ... RESULTS ... -----------------------------" -diff --brief 4.bdd 4a.bdd.tmp -diff --brief 4a.bdd.tmp 4c.bdd.tmp +diff --strip-trailing-cr --brief ${where}/4.bdd ${dest}/4a.bdd.tmp +test $? != 0 && exitval=1 +diff --strip-trailing-cr --brief ${dest}/4a.bdd.tmp ${dest}/4c.bdd.tmp +test $? != 0 && exitval=1 echo "-------------------------------- ... END ----------------------------------" -rm -f *.*.tmp +rm -f ${dest}/4a.bdd.tmp ${dest}/4c.bdd.tmp +exit $exitval diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test5.script b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test5.sh.in similarity index 56% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test5.script rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/test5.sh.in index 9676c944e..aecbb2095 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test5.script +++ b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test5.sh.in @@ -1,4 +1,4 @@ -# !/bin/sh +#! /bin/sh # # Check ADD: # Load an ADD @@ -6,37 +6,47 @@ # Compare the two # (done twice on a small - 0.add - and a medium - 1.add - ADD). # -rm -f *.tmp* + +EXE=@EXEEXT@ +srcdir=@top_srcdir@ +where=${srcdir}/dddmp/exp +dest=. +exitval=0 + echo "---------------------------------------------------------------------------" echo "--------------------- TESTING Load ADD and Store ADD ----------------------" echo "---------------------------------------------------------------------------" -./../testdddmp << END1 +../testdddmp$EXE << END1 mi 3 hlb -0.add +${where}/0.add al -0.add +${where}/0.add 0 as -0.add.tmp +${dest}/0.add.tmp 0 mq mi 50 hlb -1.add +${where}/1.add al -1.add +${where}/1.add 1 as -1.add.tmp +${dest}/1.add.tmp 1 mq quit END1 +test $? != 1 && exitval=1 echo "----------------------------- ... RESULTS ... -----------------------------" -diff --brief 0.add 0.add.tmp -diff --brief 1.add 1.add.tmp +diff --strip-trailing-cr --brief ${where}/0.add ${dest}/0.add.tmp +test $? != 0 && exitval=1 +diff --strip-trailing-cr --brief ${where}/1.add ${dest}/1.add.tmp +test $? != 0 && exitval=1 echo "-------------------------------- ... END ----------------------------------" -rm -f *.*.tmp +rm -f ${dest}/0.add.tmp ${dest}/1.add.tmp +exit $exitval diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test6.script b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test6.sh.in similarity index 58% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test6.script rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/test6.sh.in index 0b4295e29..f858c6ad0 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test6.script +++ b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test6.sh.in @@ -1,4 +1,4 @@ -# !/bin/sh +#! /bin/sh # # Check CNF (short check - only NodeByNode method involved): # Load BDDs @@ -7,44 +7,55 @@ # Store corresponding BDD # Compare original and final BDDs # -rm -f *.tmp* + +EXE=@EXEEXT@ +srcdir=@top_srcdir@ +where=${srcdir}/dddmp/exp +dest=. +exitval=0 + echo "---------------------------------------------------------------------------" echo "--------------------- TESTING Load BDD and Store CNF ----------------------" echo "---------------------------------------------------------------------------" -./../testdddmp << END1 +../testdddmp$EXE << END1 mi 150 hlc -4.cnf.bis +${where}/4.cnf.bis bl -4.bdd +${where}/4.bdd 0 cs -4.cnf.tmp +${dest}/4.cnf.tmp 0 N 100 mq quit END1 +test $? != 1 && exitval=1 echo "--------------------- TESTING Load CNF and Store BDD ----------------------" -./../testdddmp << END2 +../testdddmp$EXE << END2 mi 150 hlc -4.cnf.bis +${where}/4.cnf.bis cl -4.cnf.tmp +${dest}/4.cnf.tmp 0 hw bs -4.bdd.tmp +${dest}/4.bdd.tmp 0 mq quit END2 +test $? != 1 && exitval=1 echo "----------------------------- ... RESULTS ... -----------------------------" -diff --brief 4.cnf.bis 4.cnf.tmp -diff --brief 4.bdd.bis1 4.bdd.tmp +diff --strip-trailing-cr --brief ${where}/4.cnf.bis ${dest}/4.cnf.tmp +test $? != 0 && exitval=1 +diff --strip-trailing-cr --brief ${where}/4.bdd.bis1 ${dest}/4.bdd.tmp +test $? != 0 && exitval=1 echo "-------------------------------- ... END ----------------------------------" -rm -f *.*.tmp +rm -f ${dest}/4.cnf.tmp ${dest}/4.bdd.tmp +exit $exitval diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test7.script b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test7.sh.in similarity index 50% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test7.script rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/test7.sh.in index dcef83f49..d711e33a0 100644 --- a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/test7.script +++ b/resources/3rdparty/cudd-3.0.0/dddmp/exp/test7.sh.in @@ -1,4 +1,4 @@ -# !/bin/sh +#! /bin/sh # # Check CNF (long check - all methods involved): # Load BDDs @@ -16,58 +16,64 @@ # Store corresponding BDD # Compare original and final BDDs # -rm -f *.tmp* + +EXE=@EXEEXT@ +srcdir=@top_srcdir@ +where=${srcdir}/dddmp/exp +dest=. +exitval=0 + echo "---------------------------------------------------------------------------" echo "--------------------- TESTING Load BDD and Store CNF ----------------------" echo "---------------------------------------------------------------------------" -./../testdddmp << END1 +../testdddmp$EXE << END1 mi 150 hlc -4.cnf.bis +${where}/4.cnf.bis bl -4.bdd +${where}/4.bdd 0 cs -4.node1.tmp +${dest}/4.node1.tmp 0 N 100 cs -4.max1.tmp +${dest}/4.max1.tmp 0 M 100 cs -4.node2.tmp +${dest}/4.node2.tmp 0 B -1 0 100 cs -4.node3.tmp +${dest}/4.node3.tmp 0 B 0 -1 100 cs -4.max2.tmp +${dest}/4.max2.tmp 0 B -1 -1 100 cs -4.best1.tmp +${dest}/4.best1.tmp 0 B 1 -1 100 cs -4.best2.tmp +${dest}/4.best2.tmp 0 B 1 @@ -76,75 +82,90 @@ B mq quit END1 +test $? != 1 && exitval=1 echo "---------------------------------------------------------------------------" echo "--------------------- TESTING Load CNF and Store BDD ----------------------" echo "---------------------------------------------------------------------------" -./../testdddmp << END2 +../testdddmp$EXE << END2 mi 150 hlc -4.node2.tmp +${dest}/4.node2.tmp cl -4.node2.tmp +${dest}/4.node2.tmp 0 hw bs -4.node2.bdd.tmp +${dest}/4.node2.bdd.tmp 0 mq quit END2 -./../testdddmp << END3 +test $? != 1 && exitval=1 +../testdddmp$EXE << END3 mi 150 hlc -4.node3.tmp +${dest}/4.node3.tmp cl -4.node3.tmp +${dest}/4.node3.tmp 0 hw bs -4.node3.bdd.tmp +${dest}/4.node3.bdd.tmp 0 mq quit END3 -./../testdddmp << END4 +test $? != 1 && exitval=1 +../testdddmp$EXE << END4 mi 150 hlc -4.best1.tmp +${dest}/4.best1.tmp cl -4.best1.tmp +${dest}/4.best1.tmp 0 hw bs -4.best1.bdd.tmp +${dest}/4.best1.bdd.tmp 0 mq quit END4 -./../testdddmp << END5 +test $? != 1 && exitval=1 +../testdddmp$EXE << END5 mi 150 hlc -4.best2.tmp +${dest}/4.best2.tmp cl -4.best2.tmp +${dest}/4.best2.tmp 0 hw bs -4.best2.bdd.tmp +${dest}/4.best2.bdd.tmp 0 mq quit END5 +test $? != 1 && exitval=1 echo "----------------------------- ... RESULTS ... -----------------------------" -diff --brief 4.max1 4.max1.tmp -diff --brief 4.max2 4.max2.tmp -diff --brief 4.bdd.bis1 4.node2.bdd.tmp -diff --brief 4.bdd.bis2 4.node3.bdd.tmp -diff --brief 4.bdd.bis3 4.best1.bdd.tmp -diff --brief 4.bdd.bis4 4.best2.bdd.tmp +diff --strip-trailing-cr --brief ${where}/4.max1 ${dest}/4.max1.tmp +test $? != 0 && exitval=1 +diff --strip-trailing-cr --brief ${where}/4.max2 ${dest}/4.max2.tmp +test $? != 0 && exitval=1 +diff --strip-trailing-cr --brief ${where}/4.bdd.bis1 ${dest}/4.node2.bdd.tmp +test $? != 0 && exitval=1 +diff --strip-trailing-cr --brief ${where}/4.bdd.bis2 ${dest}/4.node3.bdd.tmp +test $? != 0 && exitval=1 +diff --strip-trailing-cr --brief ${where}/4.bdd.bis3 ${dest}/4.best1.bdd.tmp +test $? != 0 && exitval=1 +diff --strip-trailing-cr --brief ${where}/4.bdd.bis4 ${dest}/4.best2.bdd.tmp +test $? != 0 && exitval=1 echo "-------------------------------- ... END ----------------------------------" -rm -f *.tmp* +rm -f ${dest}/4.max1.tmp ${dest}/4.max2.tmp ${dest}/4.node2.bdd.tmp \ + ${dest}/4.node3.bdd.tmp ${dest}/4.best1.bdd.tmp ${dest}/4.best2.bdd.tmp \ + ${dest}/4b.bdd.tmp ${dest}/4.best1.tmp ${dest}/4.best2.tmp \ + ${dest}/4.node1.tmp ${dest}/4.node2.tmp ${dest}/4.node3.tmp +exit $exitval diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/varauxids.ord b/resources/3rdparty/cudd-3.0.0/dddmp/exp/varauxids.ord similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/varauxids.ord rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/varauxids.ord diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/varnames.ord b/resources/3rdparty/cudd-3.0.0/dddmp/exp/varnames.ord similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/varnames.ord rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/varnames.ord diff --git a/resources/3rdparty/cudd-2.5.0/src/dddmp/exp/zero.bdd b/resources/3rdparty/cudd-3.0.0/dddmp/exp/zero.bdd similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/dddmp/exp/zero.bdd rename to resources/3rdparty/cudd-3.0.0/dddmp/exp/zero.bdd diff --git a/resources/3rdparty/cudd-3.0.0/dddmp/test_dddmp.test.in b/resources/3rdparty/cudd-3.0.0/dddmp/test_dddmp.test.in new file mode 100644 index 000000000..3702e7e25 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/dddmp/test_dddmp.test.in @@ -0,0 +1,17 @@ +#! /bin/sh +# +# Run All Test Files +# +echo TAP version 13 +echo 1..7 +cd dddmp/exp +for n in 1 2 3 4 5 6 7 +do + ./test${n}.sh > /dev/null 2>&1 + if test $? = 0 ; then + echo "ok ${n}" + else + echo "not ok ${n}" + fi +done +exit 0 diff --git a/resources/3rdparty/cudd-3.0.0/dddmp/testdddmp.c b/resources/3rdparty/cudd-3.0.0/dddmp/testdddmp.c new file mode 100644 index 000000000..1b99f06c3 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/dddmp/testdddmp.c @@ -0,0 +1,2291 @@ +/**CFile********************************************************************** + + FileName [testdddmp.c] + + PackageName [dddmp] + + Synopsis [A simple test function for Dddmp package] + + Description [This program constitutes a simple test program + for the dddmp library (version 2.0). + A simple interactive command selection allow the users to perform the + main operation on BDDs, ADDs, and CNF, such as loading and storing. + It can work also as a BDD calculators. + ] + + Author [Gianpiero Cabodi and Stefano Quer] + + Copyright [ + Copyright (c) 2004 by Politecnico di Torino. + All Rights Reserved. This software is for educational purposes only. + Permission is given to academic institutions to use, copy, and modify + this software and its documentation provided that this introductory + message is not removed, that this software and its documentation is + used for the institutions' internal research and educational purposes, + and that no monies are exchanged. No guarantee is expressed or implied + by the distribution of this code. + Send bug-reports and/or questions to: + {gianpiero.cabodi,stefano.quer}@polito.it. + ] + +******************************************************************************/ + +#include <string.h> +#include <stdio.h> +#include "dddmpInt.h" + +/*---------------------------------------------------------------------------*/ +/* Constant declarations */ +/*---------------------------------------------------------------------------*/ + +#define DDDMPTEST_MAX_FILENAME_LENGTH 256 +#define DDDMPTEST_MAX_STRING_LENGTH 80 +#define DDDMPTEST_MAX_OPERAND 20 +#define DDDMPTEST_MAX_VARIABLE 50 +#define DDDMP_MAX_BDDARRAY_LEN 1000 + +/**Enum************************************************************************ + + Synopsis [Message type for output messages] + + Description [Type supported by the output function to print-out + the proper message. + ] + +******************************************************************************/ + +typedef enum { + /* Int Messages */ + DDDMP_MESSAGE_MANAGER_VAR, + DDDMP_MESSAGE_BDD, + DDDMP_MESSAGE_BDD_ARRAY, + DDDMP_MESSAGE_SOURCE1, + DDDMP_MESSAGE_SOURCE2, + DDDMP_MESSAGE_DESTINATION, + DDDMP_MESSAGE_CUBE, + DDDMP_MESSAGE_INDEX, + DDDMP_MESSAGE_I_ID, + DDDMP_MESSAGE_EDGE_MAX, + DDDMP_MESSAGE_LENGHT_MAX, + DDDMP_MESSAGE_REORDERING, + /* String Messages */ + DDDMP_MESSAGE_PROMPT, + DDDMP_MESSAGE_FILE, + DDDMP_MESSAGE_OP, + DDDMP_MESSAGE_FORMAT +} Dddmp_MessageType; + +#if !defined(RAND_MAX) && defined(sun) && defined(sparc) +#define RAND_MAX 2147483647 +#endif + +/*---------------------------------------------------------------------------*/ +/* Stucture declarations */ +/*---------------------------------------------------------------------------*/ + +typedef struct dddmpVarInfo { + /* + * Local Information + */ + + int nDdVars; /* Local Manager Number of Variables */ + char **rootNames; /* Root Names */ + + /* + * Header File Information + */ + + Dddmp_DecompType ddType; + + int nVars; /* File Manager Number of Variables */ + int nSuppVars; /* File Structure Number of Variables */ + + int varNamesFlagUpdate; /* 0 to NOT Update */ + char **suppVarNames; + char **orderedVarNames; + + int varIdsFlagUpdate; /* 0 to NOT Update */ + int *varIds; /* File ids - nSuppVars size */ + int *varIdsAll; /* ALL ids - nVars size */ + + int varComposeIdsFlagUpdate; /* 0 to NOT Update */ + int *varComposeIds; /* File permids - nSuppVars size */ + int *varComposeIdsAll; /* ALL permids - nVars size */ + + int varAuxIdsFlagUpdate; /* 0 to NOT Update */ + int *varAuxIds; /* File auxids - nSuppVars size */ + int *varAuxIdsAll; /* ALL auxids - nVars size */ + + int nRoots; +} dddmpVarInfo_t; + +/*---------------------------------------------------------------------------*/ +/* Type declarations */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Variable declarations */ +/*---------------------------------------------------------------------------*/ + +Dddmp_RootMatchType rootmatchmode; +Dddmp_VarMatchType varmatchmode; +Dddmp_VarInfoType varoutinfo; +char varname[DDDMPTEST_MAX_STRING_LENGTH]; + +/*---------------------------------------------------------------------------*/ +/* Macro declarations */ +/*---------------------------------------------------------------------------*/ + +/**AutomaticStart*************************************************************/ + +/*---------------------------------------------------------------------------*/ +/* Static function prototypes */ +/*---------------------------------------------------------------------------*/ + +static DdManager *ManagerInit (dddmpVarInfo_t *varInfo); +static void ManagerQuit (DdManager **ddMgr, dddmpVarInfo_t *varInfo); +static int OneCreate(DdManager *ddMgr, DdNode **operandBdd); +static int BddZeroCreate(DdManager *ddMgr, DdNode **operandBdd); +static int LeafCreate(DdManager *ddMgr, DdNode **operandBdd); +static int BddCreate(DdManager *ddMgr, DdNode **operandBdd); +static int A2B(void); +static int B2A(void); +static int HeaderLoadBdd(dddmpVarInfo_t *varInfo); +static int HeaderLoadCnf(dddmpVarInfo_t *varInfo); +static int HeaderWrite(dddmpVarInfo_t *varInfo); +static int Help(void); +static int OrderNamesLoad(dddmpVarInfo_t *varInfo); +static int IntArrayLoad(dddmpVarInfo_t *varInfo, const char *mode); +static int BddLoad(DdManager *ddMgr, DdNode **operandBdd, dddmpVarInfo_t *varInfo); +static int BddArrayLoad(DdManager *ddMgr, DdNode ***operandBddArray, int *operandBddArraySize, dddmpVarInfo_t *varInfo); +static int AddLoad(DdManager *ddMgr, DdNode **operandBdd, dddmpVarInfo_t *varInfo); +static int AddArrayLoad(DdManager *ddMgr, DdNode ***operandBddArray, int *operandBddArraySize, dddmpVarInfo_t *varInfo); +static int BddLoadCnf(DdManager *ddMgr, DdNode **operandBdd, dddmpVarInfo_t *varInfo); +static int BddArrayLoadCnf(DdManager *ddMgr, DdNode ***operandBddArray, int *operandBddArraySize, dddmpVarInfo_t *varInfo); +static int Operation(DdManager *ddMgr, DdNode **operandBdd); +static int BddStore(DdManager *ddMgr, DdNode **operandBdd, dddmpVarInfo_t *varInfo); +static int BddArrayStore(DdManager *ddMgr, DdNode ***operandBddArray, int *operandBddArraySize, dddmpVarInfo_t *varInfo); +static int AddStore(DdManager *ddMgr, DdNode **operandBdd, dddmpVarInfo_t *varInfo); +static int AddArrayStore(DdManager *ddMgr, DdNode ***operandBddArray, int *operandBddArraySize, dddmpVarInfo_t *varInfo); +static int BddStoreCnf(DdManager *ddMgr, DdNode **operandBdd, dddmpVarInfo_t *varInfo); +static int BddArrayStoreCnf(DdManager *ddMgr, DdNode ***operandBddArray, int *operandBddArraySize, dddmpVarInfo_t *varInfo); +static int DynamicReordering(DdManager *ddMgr); +static int SetLoadMatchmode(); +static int CompleteInfoStruct(Dddmp_DecompType ddType, int nVars, int nSuppVars, char **suppVarNames, char **orderedVarNames, int *varIds, int *varComposeIds, int *varAuxIds, int nRoots, dddmpVarInfo_t *varInfo); +static void ReadInt(Dddmp_MessageType message, int *i); +static void ReadString(Dddmp_MessageType message, char string[]); + +/**AutomaticEnd***************************************************************/ + +int +main( + int argc, + char **argv + ) +{ + DdManager *ddMgr = NULL; + DdNode **operandBdd = NULL; + DdNode ***operandBddArray = NULL; + int *operandBddArraySize = NULL; + char *row = NULL; + dddmpVarInfo_t varInfo; + int i; + + /*--------------------- Echo command line and arguments -------------------*/ + + fprintf (stdout, "#"); + for (i=0; i<argc; i++) { + fprintf (stdout, "%s Version 2.0.2 (use command help)", argv[i]); + } + fprintf (stdout, "\n"); + if (argc>1) { + Help(); + } + + /*-------------------------- Init Array of BDDs ---------------------------*/ + + rootmatchmode = DDDMP_ROOT_MATCHLIST; +#if 1 + varmatchmode = DDDMP_VAR_MATCHIDS; +#else + varmatchmode = DDDMP_VAR_MATCHNAMES; +#endif + varoutinfo = DDDMP_VARIDS; + + row = DDDMP_ALLOC (char, DDDMPTEST_MAX_STRING_LENGTH); + Dddmp_CheckAndReturn (row==NULL, "Allocation error."); + + operandBdd = DDDMP_ALLOC (DdNode *, DDDMPTEST_MAX_OPERAND); + Dddmp_CheckAndReturn (operandBdd==NULL, "Allocation error."); + + operandBddArray = DDDMP_ALLOC (DdNode **, DDDMPTEST_MAX_OPERAND); + Dddmp_CheckAndReturn (operandBddArray==NULL, "Allocation error."); + + operandBddArraySize = DDDMP_ALLOC (int, DDDMPTEST_MAX_OPERAND); + Dddmp_CheckAndReturn (operandBddArraySize==NULL, "Allocation error."); + + for (i=0; i<DDDMPTEST_MAX_OPERAND; i++) { + operandBdd[i] = NULL; + operandBddArray[i] = NULL; + operandBddArraySize[i] = 0; + } + + /*--------------------- Manage command line parameters --------------------*/ + + while (1) { + ReadString (DDDMP_MESSAGE_PROMPT, row); + if (row[0]=='\n') { + continue; + } + if (strncmp (row, "help", 4)==0) { + Help(); + } else if (strncmp (row, "mi", 2)==0) { + ddMgr = ManagerInit (&varInfo); + } else if (strncmp (row, "mq", 2)==0) { + ManagerQuit (&ddMgr, &varInfo); + } else if (strncmp (row, "onl", 3)==0) { + OrderNamesLoad (&varInfo); + } else if (strncmp (row, "oil", 3)==0) { + IntArrayLoad (&varInfo, "oil"); + } else if (strncmp (row, "cil", 3)==0) { + IntArrayLoad (&varInfo, "cil"); + } else if (strncmp (row, "slm", 3)==0) { + SetLoadMatchmode (); + } else if (strncmp (row, "op", 2)==0) { + Operation (ddMgr, operandBdd); + } else if (strncmp (row, "oc", 2)==0) { + OneCreate (ddMgr, operandBdd); + } else if (strncmp (row, "zc", 2)==0) { + BddZeroCreate (ddMgr, operandBdd); + } else if (strncmp (row, "lc", 2)==0) { + LeafCreate (ddMgr, operandBdd); + } else if (strncmp (row, "bc", 2)==0) { + BddCreate (ddMgr, operandBdd); + } else if (strncmp (row, "a2b", 3)==0) { + A2B (); + } else if (strncmp (row, "b2a", 3)==0) { + B2A (); + } else if (strncmp (row, "hlb", 3)==0) { + HeaderLoadBdd (&varInfo); + } else if (strncmp (row, "hlc", 3)==0) { + HeaderLoadCnf (&varInfo); + } else if (strncmp (row, "bl", 3)==0) { + BddLoad (ddMgr, operandBdd, &varInfo); + } else if (strncmp (row, "bal", 3)==0) { + BddArrayLoad (ddMgr, operandBddArray, operandBddArraySize, &varInfo); + } else if (strncmp (row, "al", 2)==0) { + AddLoad (ddMgr, operandBdd, &varInfo); + } else if (strncmp (row, "aal", 3)==0) { + AddArrayLoad (ddMgr, operandBddArray, operandBddArraySize, &varInfo); + } else if (strncmp (row, "cl", 2)==0) { + BddLoadCnf (ddMgr, operandBdd, &varInfo); + } else if (strncmp (row, "cal", 3)==0) { + BddArrayLoadCnf (ddMgr, operandBddArray, operandBddArraySize, &varInfo); + } else if (strncmp (row, "hw", 2)==0) { + HeaderWrite (&varInfo); + } else if (strncmp (row, "bs", 2)==0) { + BddStore (ddMgr, operandBdd, &varInfo); + } else if (strncmp (row, "bas", 3)==0) { + BddArrayStore (ddMgr, operandBddArray, operandBddArraySize, &varInfo); + } else if (strncmp (row, "as", 2)==0) { + AddStore (ddMgr, operandBdd, &varInfo); + } else if (strncmp (row, "aas", 2)==0) { + AddArrayStore (ddMgr, operandBddArray, operandBddArraySize, &varInfo); + } else if (strncmp (row, "cs", 2)==0) { + BddStoreCnf (ddMgr, operandBdd, &varInfo); + } else if (strncmp (row, "cas", 2)==0) { + BddArrayStoreCnf (ddMgr, operandBddArray, operandBddArraySize, &varInfo); + } else if (strncmp (row, "dr", 2)==0) { + DynamicReordering (ddMgr); + } else if (strncmp (row, "quit", 4)==0) { + break; + } else { + fprintf (stderr, "Command not found: %s\n", row); + } + } + + /*-------------------------------- Free Memory ----------------------------*/ + + ManagerQuit (&ddMgr, &varInfo); + + DDDMP_FREE (row); + DDDMP_FREE (operandBdd); + for (i=0; i<DDDMPTEST_MAX_OPERAND; i++) { + if (operandBddArray[i] != NULL) { + DDDMP_FREE (operandBddArray[i]); + } + } + DDDMP_FREE (operandBddArray); + DDDMP_FREE (operandBddArraySize); + + fprintf (stdout, "End of test.\n"); + + return (DDDMP_SUCCESS); +} + + +/*---------------------------------------------------------------------------*/ +/* Definition of internal functions */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Definition of static functions */ +/*---------------------------------------------------------------------------*/ + +/**Function******************************************************************** + + Synopsis [Create a CUDD Manager with nVars variables.] + + Description [Create a CUDD Manager with nVars variables.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static DdManager * +ManagerInit ( + dddmpVarInfo_t *varInfo + ) +{ + DdManager *ddMgr = NULL; + int nVars; + + ReadInt (DDDMP_MESSAGE_MANAGER_VAR, &nVars); + + /*----------------------- Init Var Information Structure ------------------*/ + + varInfo->nDdVars = nVars; + + varInfo->rootNames = NULL; + varInfo->ddType = DDDMP_NONE; + varInfo->nVars = (-1); + varInfo->nSuppVars = (-1); + varInfo->varNamesFlagUpdate = 1; + varInfo->suppVarNames = NULL; + varInfo->orderedVarNames = NULL; + varInfo->varIdsFlagUpdate = 1; + varInfo->varIds = NULL; + varInfo->varIdsAll = NULL; + varInfo->varComposeIdsFlagUpdate = 1; + varInfo->varComposeIds = NULL; + varInfo->varComposeIdsAll = NULL; + varInfo->varAuxIdsFlagUpdate = 1; + varInfo->varAuxIds = NULL; + varInfo->varAuxIdsAll = NULL; + varInfo->nRoots = (-1); + + /*------------------------------ Init DD Manager --------------------------*/ + + ddMgr = Cudd_Init (nVars, 0, CUDD_UNIQUE_SLOTS, + CUDD_CACHE_SLOTS, 0); + + Dddmp_CheckAndReturn (ddMgr==NULL, "DdManager NOT inizializated."); + + return (ddMgr); +} + +/**Function******************************************************************** + + Synopsis [Quit a CUDD Manager.] + + Description [Quit a CUDD Manager.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static void +ManagerQuit ( + DdManager **ddMgrPtr /* IN: CUDD Manager */, + dddmpVarInfo_t *varInfo /* IN: Internal Manager */ + ) +{ + if (*ddMgrPtr == NULL) { + return; + } + + fprintf (stdout, "Quitting CUDD Manager.\n"); + Cudd_Quit (*ddMgrPtr); + *ddMgrPtr = NULL; + + DddmpStrArrayFree (varInfo->rootNames, varInfo->nRoots); + DddmpStrArrayFree (varInfo->suppVarNames, varInfo->nSuppVars); + DddmpStrArrayFree (varInfo->orderedVarNames, varInfo->nVars); + DDDMP_FREE (varInfo->varIds); + DDDMP_FREE (varInfo->varIdsAll); + DDDMP_FREE (varInfo->varComposeIds); + DDDMP_FREE (varInfo->varComposeIdsAll); + DDDMP_FREE (varInfo->varAuxIds); + DDDMP_FREE (varInfo->varAuxIdsAll); + + varInfo->nDdVars = (-1); + varInfo->rootNames = NULL; + varInfo->ddType = DDDMP_NONE; + varInfo->nVars = (-1); + varInfo->nSuppVars = (-1); + varInfo->varNamesFlagUpdate = 1; + varInfo->suppVarNames = NULL; + varInfo->orderedVarNames = NULL; + varInfo->varIdsFlagUpdate = 1; + varInfo->varIds = NULL; + varInfo->varIdsAll = NULL; + varInfo->varComposeIdsFlagUpdate = 1; + varInfo->varComposeIds = NULL; + varInfo->varComposeIdsAll = NULL; + varInfo->varAuxIdsFlagUpdate = 1; + varInfo->varAuxIds = NULL; + varInfo->varAuxIdsAll = NULL; + varInfo->nRoots = (-1); + + return; +} + +/**Function******************************************************************** + + Synopsis [Create a One-BDD Leaf.] + + Description [Create a One-BDD Leaf.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +OneCreate( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode **operandBdd /* In/OUT: Array of operand */ + ) +{ + int i; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadInt (DDDMP_MESSAGE_BDD, &i); + + operandBdd[i] = Cudd_ReadOne (ddMgr); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Create a Zero-BDD Leaf.] + + Description [Create a Zero-BDD Leaf.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +BddZeroCreate( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode **operandBdd /* IN/OUT: array of operand */ + ) +{ + int i; + DdNode *one = NULL; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadInt (DDDMP_MESSAGE_BDD, &i); + + one = Cudd_ReadOne(ddMgr); + operandBdd[i] = Cudd_Not(one); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Create a One-Node BDD.] + + Description [Create a One-Node BDD.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +LeafCreate( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode **operandBdd /* IN/OUT: Array of operandBdd */ + ) +{ + int i, j; + DdNode *f = NULL; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadInt (DDDMP_MESSAGE_BDD, &i); + ReadInt (DDDMP_MESSAGE_INDEX, &j); + + f = Cudd_bddIthVar (ddMgr, j); + Cudd_Ref(f); + operandBdd[i] = f; + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Create a BDD.] + + Description [Create a BDD: Variable index and number of cubes selection.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +BddCreate ( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode **operandBdd /* array of operandBdd */ + ) +{ + DdNode **vet, *f, *g, *h; + int nb, nv, vi0, vi1, nc, i, j; + char row[DDDMPTEST_MAX_FILENAME_LENGTH]; + char *retval; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadInt (DDDMP_MESSAGE_BDD, &nb); + + fprintf (stdout, "Variables Index [n-m] (m-n = number of variables): "); + retval = fgets (row, DDDMPTEST_MAX_STRING_LENGTH, stdin); + if (!retval) + return (DDDMP_FAILURE); + sscanf (row, "%d-%d", &vi0, &vi1); + nv = vi1-vi0+1; + + ReadInt (DDDMP_MESSAGE_CUBE, &nc); + + /* Leaf Creation */ + vet = DDDMP_ALLOC (DdNode *, nv); + for (i=0; i<nv; i++) { + vet[i] = Cudd_bddIthVar (ddMgr, vi0+i); + } + + /* Cubes and BDD creation */ + f = Cudd_Not (Cudd_ReadOne (ddMgr)); + for (i=0; i<nc; i++) + { + g = Cudd_ReadOne (ddMgr); + for (j=0; j<nv; j++) + { + if ( ((float) rand())/((float) RAND_MAX) > 0.5 ) { + h = Cudd_bddAnd (ddMgr, g, vet[j]); + } else { + h = Cudd_bddAnd (ddMgr, g, Cudd_Not (vet[j])); + } + Cudd_Ref (h); + Cudd_RecursiveDeref (ddMgr, g); + g = h; + } + h = Cudd_bddOr (ddMgr, f, g); + Cudd_Ref (h); + Cudd_RecursiveDeref (ddMgr, f); + Cudd_RecursiveDeref (ddMgr, g); + f = h; + } + + operandBdd[nb] = f; + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Transform a BDD from the ASCII to the Binary format].] + + Description [Input and Output file selection.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +A2B( + void +) +{ + fprintf (stderr, "Not yet Implemented!!!\n"); + + return (DDDMP_FAILURE); +} + +/**Function******************************************************************** + + Synopsis [Transform a BDD from the Binary to the ASCII format].] + + Description [Input and Output file selection.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +B2A( + void +) +{ + fprintf (stderr, "Not yet Implemented!!!\n"); + + return (DDDMP_FAILURE); +} + +/**Function******************************************************************** + + Synopsis [Read the Header of a file containing a BDD.] + + Description [File name Selection.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +HeaderLoadBdd ( + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + Dddmp_DecompType ddType; + int retValue, nRoots, nVars, nSuppVars; + int *tmpVarIds = NULL; + int *tmpVarAuxIds = NULL; + int *tmpVarComposeIds = NULL; + char **tmpOrderedVarNames = NULL; + char **tmpSuppVarNames = NULL; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + + retValue = Dddmp_cuddHeaderLoad (&ddType, &nVars, &nSuppVars, + &tmpSuppVarNames, &tmpOrderedVarNames, &tmpVarIds, &tmpVarComposeIds, + &tmpVarAuxIds, &nRoots, fileName, NULL); + + if (retValue == DDDMP_FAILURE) { + return (DDDMP_FAILURE); + } + + /*---------------------------- Tail Operations ----------------------------*/ + + CompleteInfoStruct (ddType, nVars, nSuppVars, + tmpSuppVarNames, tmpOrderedVarNames, tmpVarIds, tmpVarComposeIds, + tmpVarAuxIds, nRoots, varInfo); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Read the Header of a file containing a CNF formula.] + + Description [File name Selection.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +HeaderLoadCnf ( + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + int retValue, nRoots, nVars, nSuppVars; + int *tmpVarIds = NULL; + int *tmpVarComposeIds = NULL; + int *tmpVarAuxIds = NULL; + char **tmpOrderedVarNames = NULL; + char **tmpSuppVarNames = NULL; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + + retValue = Dddmp_cuddHeaderLoadCnf (&nVars, &nSuppVars, + &tmpSuppVarNames, &tmpOrderedVarNames, &tmpVarIds, &tmpVarComposeIds, + &tmpVarAuxIds, &nRoots, fileName, NULL); + + if (retValue == DDDMP_FAILURE) { + return (DDDMP_FAILURE); + } + + /*---------------------------- Tail Operations ----------------------------*/ + + CompleteInfoStruct (DDDMP_CNF, nVars, nSuppVars, + tmpSuppVarNames, tmpOrderedVarNames, tmpVarIds, tmpVarComposeIds, + tmpVarAuxIds, nRoots, varInfo); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Read the Header of a filke containing a BDD.] + + Description [File name Selection.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +HeaderWrite( + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + int i; + + switch (varInfo->ddType) { + case DDDMP_BDD: + fprintf (stdout, "DD TYPE: DDDMP_BDD\n"); + break; + case DDDMP_ADD: + fprintf (stdout, "DD TYPE: DDDMP_ADD\n"); + break; + case DDDMP_CNF: + fprintf (stdout, "DD TYPE: DDDMP_CNF\n"); + break; + case DDDMP_NONE: + fprintf (stdout, "DD TYPE: NONE - Error\n"); + break; + } + + fprintf (stdout, "Number of variables: %d\n", varInfo->nVars); + fprintf (stdout, "Number of support variables: %d\n", varInfo->nSuppVars); + + if (varInfo->suppVarNames != NULL) { + fprintf (stdout, "suppVarNames: "); + for (i=0; i<varInfo->nSuppVars; i++) { + if (varInfo->suppVarNames[i] != NULL) { + fprintf (stdout, "%s ", varInfo->suppVarNames[i]); + } + } + fprintf (stdout, "\n"); + } + + if (varInfo->orderedVarNames != NULL) { + fprintf (stdout, "orderedVarNames: "); + for (i=0; i<varInfo->nVars; i++) { + if (varInfo->orderedVarNames[i] != NULL) { + fprintf (stdout, "%s ", varInfo->orderedVarNames[i]); + } + } + fprintf (stdout, "\n"); + } + + if (varInfo->varIds != NULL) { + fprintf (stdout, "varIds: "); + for (i=0; i<varInfo->nSuppVars; i++) { + fprintf (stdout, "%d ", varInfo->varIds[i]); + } + fprintf (stdout, "\n"); + } + + if (varInfo->varIdsAll != NULL) { + fprintf (stdout, "varIds for ALL Manager Variables: "); + for (i=0; i<varInfo->nVars; i++) { + fprintf (stdout, "%d ", varInfo->varIdsAll[i]); + } + fprintf (stdout, "\n"); + } + + if (varInfo->varComposeIds != NULL) { + fprintf (stdout, "varComposeIds: "); + for (i=0; i<varInfo->nSuppVars; i++) { + fprintf (stdout, "%d ", varInfo->varComposeIds[i]); + } + fprintf (stdout, "\n"); + } + + if (varInfo->varComposeIdsAll != NULL) { + fprintf (stdout, "varComposeIds for ALL Manager Variables: "); + for (i=0; i<varInfo->nVars; i++) { + fprintf (stdout, "%d ", varInfo->varComposeIdsAll[i]); + } + fprintf (stdout, "\n"); + } + + if (varInfo->varAuxIds != NULL) { + fprintf (stdout, "varAuxIds: "); + for (i=0; i<varInfo->nSuppVars; i++) { + fprintf (stdout, "%d ", varInfo->varAuxIds[i]); + } + fprintf (stdout, "\n"); + } + + if (varInfo->varAuxIdsAll != NULL) { + fprintf (stdout, "varAuxIds for ALL Manager Variables: "); + for (i=0; i<varInfo->nVars; i++) { + fprintf (stdout, "%d ", varInfo->varAuxIdsAll[i]); + } + fprintf (stdout, "\n"); + } + + fprintf (stdout, "Number of roots: %d\n", varInfo->nRoots); + + fflush (stdout); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Print the Help messages.] + + Description [Print the Help messages.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +Help( + void + ) +{ + fprintf (stdout, "Commands:\n"); + fprintf (stdout, "MAIN\n"); + + fprintf (stdout, "\thelp : Print this set of messages.\n"); + fprintf (stdout, "\tquit : Quit the test program.\n"); + + fprintf (stdout, "MANAGER OPERATIONs\n"); + + fprintf (stdout, + "\thmi : Manager Init (To do BEFORE any BDD/ADD operation).\n"); + fprintf (stdout, "\thmq : Manager Quit.\n"); + + fprintf (stdout, "LOAD\n"); + + fprintf (stdout, "\thlb : Load the header from a BDD/ADD file.\n"); + fprintf (stdout, "\thlc : Load the header from a CNF file.\n"); + fprintf (stdout, "\tbl : Load a BDD from a file.\n"); + fprintf (stdout, "\tbal : Load an Array-BDD from a file.\n"); + fprintf (stdout, "\tal : Load an ADD from a file.\n"); + fprintf (stdout, "\taal : Load an Array-ADD from a file.\n"); + fprintf (stdout, "\tcl : Load a CNF Formula from a file.\n"); + fprintf (stdout, "\tcal : Load an Array of CNF Formulas from a file.\n"); + + fprintf (stdout, "STORE\n"); + + fprintf (stdout, + "\thw : (Header) Write variable information on stdout.\n"); + fprintf (stdout, "\tbs : Store a BDD into a file.\n"); + fprintf (stdout, "\tbas : Store an Array-BDD from a file.\n"); + fprintf (stdout, "\tas : Store an ADD into a file.\n"); + fprintf (stdout, "\taas : Store an Array-ADD into a file.\n"); + fprintf (stdout, "\tcs : Store BDD as a CNF formula.\n"); + fprintf (stdout, "\tcas : Store and Array of BDDs as a CNF formula.\n"); + + fprintf (stdout, "MISC\n"); + + fprintf (stdout, "\tdr : Activate Dynamic Reordering.\n"); + fprintf (stdout, "\tonl : Load the order from a file (varNames).\n"); + fprintf (stdout, "\toil : Load the order from a file (varAuxIds).\n"); + fprintf (stdout, "\tcil : Load compose IDs from a file.\n"); + fprintf (stdout, "\tslm : Set Load matchmode for variables.\n"); + fprintf (stdout, + "\top : Operation (or, and, xor, not, =) between BDDs.\n"); + fprintf (stdout, "\toc : Create a terminal-one BDD.\n"); + fprintf (stdout, "\tzc : Create a terminal-zero BDD.\n"); + fprintf (stdout, "\tlc : Create a single variable BDD (1 node).\n"); + fprintf (stdout, "\tbc : Create a random BDD.\n"); + + fprintf (stdout, "NOT YET IMPLEMENTED\n"); + + fprintf (stdout, + "\ta2b : Convert a file from the ASCII format to the binary one.\n"); + fprintf (stdout, + "\tb2a : Convert a file from the binary format to the ASCII one.\n"); + + fprintf (stdout, "HINT\n"); + + fprintf (stdout, + " Command 'mi' has to be the first instruction to build:\n"); + fprintf (stdout, " a) The CUDD manager.\n"); + fprintf (stdout, + " b) The internal manager (containing name and variable IDs).\n"); + fprintf (stdout, + " After that load an header file with 'hlb' or 'hlc' to have proper\n"); + fprintf (stdout, + " names and ids for each subsequent load/store operation.\n"); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Load the BDD order from a file (varNames).] + + Description [Load the BDD order from a file (varNames). + Force the orderedVarNames field of the varInfo structure, + i.e., the local manager, to be stucked to this array of values. + ] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +OrderNamesLoad( + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + FILE *fp = NULL; + int i; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + char tmpBuf[DDDMPTEST_MAX_STRING_LENGTH]; + char tmpName[DDDMPTEST_MAX_STRING_LENGTH]; + char **tmpOrderedVarNames = NULL; + + /*------------------------- Red New Var Names Array ----------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + + fp = fopen (fileName, "r"); + Dddmp_CheckAndReturn (fp==NULL, "Cannot open file."); + + varoutinfo = DDDMP_VARNAMES; + tmpOrderedVarNames = DDDMP_ALLOC (char *, varInfo->nDdVars); + + i=0; + while (fgets (tmpBuf, DDDMPTEST_MAX_STRING_LENGTH, fp)!=NULL) { + if (tmpBuf[0]=='#') { + continue; + } + + if (i>=varInfo->nDdVars) { + fprintf (stdout, + "Number of variables in files higher than DD manager vars (%d)\n", + varInfo->nDdVars); + fprintf (stdout, "Exceeding variables ignored\n"); + fprintf (stdout, + "You might increase the DDDMPTEST_MAX_VARIABLE constant\n"); + break; + } + + sscanf (tmpBuf, "%s", tmpName); + tmpOrderedVarNames[i] = DDDMP_ALLOC (char, (strlen (tmpName) + 1)); + if (tmpOrderedVarNames[i]==NULL) { + fprintf (stdout, "Error allocating memory\n"); + } else { + strcpy (tmpOrderedVarNames[i], tmpName); + } + i++; + } + + for ( ;i<varInfo->nDdVars; i++) { + tmpOrderedVarNames[i] = NULL; + } + + fclose(fp); + + /*----------------------- Free and Set Var Names Array --------------------*/ + + DddmpStrArrayFree (varInfo->orderedVarNames, varInfo->nVars); + varInfo->orderedVarNames = tmpOrderedVarNames; + varInfo->nVars = varInfo->nDdVars; + + /* DO NOT ALLOW FURTHER UPDATES */ + varInfo->varNamesFlagUpdate = 0; + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Load the BDD order from a file (varauxids).] + + Description [Load the BDD order from a file (varauxids). + Force the + varAuxIds and varAuxIdsAll + or the + varComposeIds and varComposeIdsAll + fields of the varInfo structure, i.e., the local manager, to be + stucked to this array of values. + ] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +IntArrayLoad ( + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */, + const char *mode + ) +{ + FILE *fp = NULL; + int i; + int *tmpArray1 = NULL; + int *tmpArray2 = NULL; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + char buf[DDDMPTEST_MAX_STRING_LENGTH]; + + ReadString (DDDMP_MESSAGE_FILE, fileName); + + fp = fopen(fileName, "r"); + Dddmp_CheckAndReturn (fp==NULL, "Cannot open file."); + + tmpArray1 = DDDMP_ALLOC (int, varInfo->nDdVars); + tmpArray2 = DDDMP_ALLOC (int, varInfo->nDdVars); + Dddmp_CheckAndReturn (tmpArray1==NULL, "Error allocating memory."); + Dddmp_CheckAndReturn (tmpArray2==NULL, "Error allocating memory."); + + i=0; + while (fgets(buf, DDDMPTEST_MAX_STRING_LENGTH, fp)!=NULL) { + if (buf[0]=='#') { + continue; + } + if (i>=varInfo->nDdVars) { + fprintf (stdout, + "Number of variables in files higher than DD manager vars (%d)\n", + varInfo->nDdVars); + fprintf (stdout, "Exceeding variables ignored.\n"); + fprintf (stdout, "(Increase the DDDMPTEST_MAX_VARIABLE constant.)\n"); + break; + } + sscanf(buf, "%d", &tmpArray1[i]); + sscanf(buf, "%d", &tmpArray2[i++]); + } + + for (;i<varInfo->nDdVars;i++) { + tmpArray1[i]= -1; + tmpArray2[i]= -1; + } + + fclose(fp); + + if (strcmp (mode, "oil") == 0) { + varInfo->varAuxIds = tmpArray1; + varInfo->varAuxIdsAll = tmpArray2; + + /* DO NOT ALLOW FURTHER UPDATES */ + varInfo->varAuxIdsFlagUpdate = 0; + } else { + if (strcmp (mode, "cil") == 0) { + varInfo->varComposeIds = tmpArray1; + varInfo->varComposeIdsAll = tmpArray2; + + /* DO NOT ALLOW FURTHER UPDATES */ + varInfo->varComposeIdsFlagUpdate = 0; + } + } + + varInfo->nVars = varInfo->nDdVars; + varInfo->nSuppVars = varInfo->nDdVars; + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Load a BDD from a file.] + + Description [Load a BDD from a file.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +BddLoad ( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode **operandBdd /* IN: Operand BDD */, + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + DdNode *f = NULL; + int i; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD, &i); + + /*-------------------------------- Load BDD -------------------------------*/ + + fprintf (stdout, "Loading %s ...\n", fileName); + + f = Dddmp_cuddBddLoad (ddMgr, varmatchmode, varInfo->orderedVarNames, + varInfo->varIdsAll, varInfo->varComposeIdsAll, DDDMP_MODE_DEFAULT, + fileName, NULL); + + if (f==NULL) { + fprintf (stderr, "Dddmp Test Error : %s is not loaded from file\n", + fileName); + } else { + operandBdd[i] = f; + } + + /*---------------------------- Tail Operations ----------------------------*/ + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Load an array of BDDs from a file.] + + Description [Load an array of BDDs from a file.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +BddArrayLoad( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode ***operandBddArray /* IN: Array of operand BDD */, + int *operandBddArraySize /* IN: Number of ADD in the Array */, + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + DdNode **bddArray = NULL; + int i, j, nRoots; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD_ARRAY, &i); + + /*---------------------------- Load BDDs ----------------------------------*/ + + nRoots = Dddmp_cuddBddArrayLoad (ddMgr, rootmatchmode, + varInfo->rootNames, varmatchmode, + varInfo->orderedVarNames, varInfo->varIdsAll, varInfo->varComposeIdsAll, + DDDMP_MODE_DEFAULT, fileName, NULL, &bddArray); + + Dddmp_CheckAndReturn (nRoots>DDDMP_MAX_BDDARRAY_LEN, + "DDDMP_MAX_BDDARRAY_LEN exceeded by BDD array len (increase it)."); + + if (nRoots<=0) { + return (DDDMP_FAILURE); + } + + varInfo->nRoots = nRoots; + operandBddArray[i] = DDDMP_ALLOC (DdNode *, nRoots); + Dddmp_CheckAndReturn (operandBddArray[i]==NULL, "Allocation error."); + + for (j=0; j<nRoots; j++) { + operandBddArray[i][j] = bddArray[j]; + } + operandBddArraySize[i] = nRoots; + + /*---------------------------- Tail Operations ----------------------------*/ + + /* free array */ + DDDMP_FREE (bddArray); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Load an ADD from a file.] + + Description [Load an ADD from a file.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +AddLoad( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode **operandBdd /* IN: Operand BDD */, + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + DdNode *f = NULL; + int i; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD, &i); + + /*-------------------------------- Load ADD -------------------------------*/ + + fprintf (stdout, "Loading %s ...\n", fileName); + + f = Dddmp_cuddAddLoad (ddMgr, varmatchmode, varInfo->orderedVarNames, + varInfo->varIdsAll, varInfo->varComposeIdsAll, DDDMP_MODE_DEFAULT, + fileName, NULL); + + if (f==NULL) { + fprintf (stderr, "Dddmp Test Error : %s is not loaded from file\n", + fileName); + } else { + operandBdd[i] = f; + } + + /*---------------------------- Tail Operations ----------------------------*/ + + fprintf (stdout, "Load:\n"); + Cudd_PrintMinterm (ddMgr, f); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Load an array of ADDs from a file.] + + Description [Load an array of ADDs from a file.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +AddArrayLoad( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode ***operandBddArray /* IN: Array of operand BDD */, + int *operandBddArraySize /* IN: Number of ADD in the Array */, + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + int i, j, nRoots; + DdNode **bddArray = NULL; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD_ARRAY, &i); + + /*------------------------------- Load ADDs -------------------------------*/ + + nRoots = Dddmp_cuddAddArrayLoad (ddMgr, rootmatchmode, + varInfo->rootNames, varmatchmode, + varInfo->orderedVarNames, varInfo->varIdsAll, varInfo->varComposeIdsAll, + DDDMP_MODE_DEFAULT, fileName, NULL, &bddArray); + + Dddmp_CheckAndReturn (nRoots>DDDMP_MAX_BDDARRAY_LEN, + "DDDMP_MAX_BDDARRAY_LEN exceeded by BDD array len (increase it)."); + + if (nRoots<=0) { + return (DDDMP_FAILURE); + } + + varInfo->nRoots = nRoots; + operandBddArray[i] = DDDMP_ALLOC (DdNode *, nRoots); + Dddmp_CheckAndReturn (operandBddArray[i]==NULL, "Allocation error."); + + for (j=0; j<nRoots; j++) { + operandBddArray[i][j] = bddArray[j]; + } + operandBddArraySize[i] = nRoots; + + /*---------------------------- Tail Operations ----------------------------*/ + + /* Free array */ + DDDMP_FREE (bddArray); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Load a CNF formula from a file, and create a BDD.] + + Description [Load a CNF formula from a file, and create a BDD.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +BddLoadCnf ( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode **operandBdd /* IN: Operand BDD */, + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + DdNode **rootsPtr = NULL; + Dddmp_DecompCnfLoadType loadingMode = DDDMP_CNF_MODE_CONJ_QUANT; + int i, retValue, nRoots; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD, &i); + + /*------------------------------- Load BDDs -------------------------------*/ + + fprintf (stdout, "Loading %s ...\n", fileName); + + retValue = Dddmp_cuddBddLoadCnf (ddMgr, varmatchmode, + varInfo->orderedVarNames, varInfo->varAuxIdsAll, varInfo->varComposeIdsAll, + loadingMode, fileName, NULL, &rootsPtr, &nRoots); + + Dddmp_CheckAndGotoLabel (retValue==DDDMP_FAILURE, + "Dddmp Test: Load From File Error.\n", failure); + + operandBdd[i] = rootsPtr[0]; + + /*---------------------------- Tail Operations ----------------------------*/ + + /* Free array */ + DDDMP_FREE (rootsPtr); + + return (DDDMP_SUCCESS); + + failure: + return(DDDMP_FAILURE); +} + +/**Function******************************************************************** + + Synopsis [Load a CNF formula from a file, and create an array of + BDDs. + ] + + Description [Load a CNF formula from a file, and create an array of + BDDs. + ] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +BddArrayLoadCnf ( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode ***operandBddArray /* IN: Array of operand BDD */, + int *operandBddArraySize /* IN: Number of ADD in the Array */, + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + DdNode **rootsPtr = NULL; + Dddmp_DecompCnfLoadType loadingMode = DDDMP_CNF_MODE_CONJ_QUANT; + int i, j, nRoots; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD_ARRAY, &i); + + /*--------------------------- Loading BDDs --------------------------------*/ + + (void) Dddmp_cuddBddArrayLoadCnf (ddMgr, rootmatchmode, + varInfo->rootNames, varmatchmode, + varInfo->orderedVarNames, varInfo->varIdsAll, varInfo->varComposeIdsAll, + loadingMode, fileName, NULL, &rootsPtr, &nRoots); + + Dddmp_CheckAndReturn (nRoots>DDDMP_MAX_BDDARRAY_LEN, + "DDDMP_MAX_BDDARRAY_LEN exceeded by BDD array len (increase it)."); + + if (nRoots<=0) { + return (DDDMP_FAILURE); + } + + varInfo->nRoots = nRoots; + operandBddArray[i] = DDDMP_ALLOC (DdNode *, nRoots); + Dddmp_CheckAndReturn (operandBddArray[i]==NULL, "Allocation error."); + + for (j=0; j<nRoots; j++) { + operandBddArray[i][j] = rootsPtr[j]; + } + operandBddArraySize[i] = nRoots; + + /*---------------------------- Tail Operations ----------------------------*/ + + /* Free array */ + DDDMP_FREE (rootsPtr); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Perform an Operation among BDDs.] + + Description [Perform an Operation among BDDs.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +Operation( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode **operandBdd /* IN: Array of operandBdd */ + ) +{ + DdNode *f, *g, *h; + char buf[DDDMPTEST_MAX_STRING_LENGTH]; + int i; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_OP, buf); + ReadInt (DDDMP_MESSAGE_SOURCE1, &i); + + f = operandBdd[i]; + + /*-------------------------- Compute Operation ----------------------------*/ + + if ((strcmp(buf, "or")==0)|| (strcmp(buf, "OR")==0)) { + ReadInt (DDDMP_MESSAGE_SOURCE2, &i); + g = operandBdd[i]; + h = Cudd_bddOr(ddMgr, f, g); + Cudd_RecursiveDeref(ddMgr, f); + Cudd_Ref(h); + Cudd_RecursiveDeref(ddMgr, g); + } else if ((strcmp(buf, "and")==0) || (strcmp(buf, "AND")==0)) { + ReadInt (DDDMP_MESSAGE_SOURCE2, &i); + g = operandBdd[i]; + h = Cudd_bddAnd(ddMgr, f, g); + Cudd_Ref(h); + Cudd_RecursiveDeref(ddMgr, f); + Cudd_RecursiveDeref(ddMgr, g); + } else if ((strcmp(buf, "xor")==0) || (strcmp(buf, "XOR")==0)) { + ReadInt (DDDMP_MESSAGE_SOURCE2, &i); + g = operandBdd[i]; + h = Cudd_bddXor(ddMgr, f, g); + Cudd_Ref(h); + Cudd_RecursiveDeref(ddMgr, f); + Cudd_RecursiveDeref(ddMgr, g); + } else if (strcmp(buf, "!")==0) { + h = Cudd_Not(f); + Cudd_Ref(h); + Cudd_RecursiveDeref(ddMgr, f); + } else if ((strcmp(buf, "buf")==0)|| (strcmp(buf, "BUF")==0)) { + h = f; + } else { + fprintf (stderr, "Dddmp Test Error : Operation %s unknown\n", buf); + h = NULL; + } + + ReadInt (DDDMP_MESSAGE_DESTINATION, &i); + + operandBdd[i] = h; + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Store a BDD in a file.] + + Description [Store a BDD in a file.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +BddStore ( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode **operandBdd /* IN: Operand BDD */, + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + DdNode *f = NULL; + int i, retValue; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD, &i); + + fprintf (stdout, "Storing %s ...\n", fileName); + fflush (stdout); + f = operandBdd[i]; + + /*----------------------------- Store BDDs -------------------------------*/ + + retValue = Dddmp_cuddBddStore(ddMgr, NULL, f, varInfo->orderedVarNames, + varInfo->varAuxIdsAll, DDDMP_MODE_TEXT, varoutinfo, fileName, NULL); + + Dddmp_CheckAndGotoLabel (retValue!=DDDMP_SUCCESS, "BDD NOT stored.", + failure); + + return (DDDMP_SUCCESS); + + failure: + return(DDDMP_FAILURE); +} + +/**Function******************************************************************** + + Synopsis [Store an Array of BDD in a file.] + + Description [Store an Array of BDD in a file.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +BddArrayStore ( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode ***operandBddArray /* IN: Array of operand BDD */, + int *operandBddArraySize /* IN: Number of ADD in the Array */, + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + int i, retValue, nRoots; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD_ARRAY, &i); + + nRoots = operandBddArraySize[i]; + + /*----------------------------- Store BDDs -------------------------------*/ + + fprintf (stdout, "Storing Array of BDDs in file %s ...\n", fileName); + fflush (stdout); + + retValue = Dddmp_cuddBddArrayStore (ddMgr, NULL, nRoots, operandBddArray[i], + NULL, varInfo->orderedVarNames, varInfo->varAuxIdsAll, DDDMP_MODE_TEXT, + DDDMP_VARIDS, fileName, NULL); + + Dddmp_CheckAndGotoLabel (retValue!=DDDMP_SUCCESS, "BDD NOT stored.", + failure); + fprintf (stdout, "done.\n"); + + return (DDDMP_SUCCESS); + + failure: + return(DDDMP_FAILURE); +} + +/**Function******************************************************************** + + Synopsis [Store an ADD in a file.] + + Description [Store an ADD in a file.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +AddStore( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode **operandBdd /* IN: operand Bdd */, + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + DdNode *f; + int i, retValue; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD, &i); + + fprintf (stdout, "Storing %s ...\n", fileName); + fflush (stdout); + f = operandBdd[i]; + +#if 0 + /* StQ Patch - CREATE temporary ADD to Store */ + f = Cudd_addResidue (ddMgr, 4, 3, 1, 1); + fprintf (stderr, "Store:\n"); + Cudd_PrintMinterm (ddMgr, f); + /* end ... StQ Patch */ +#endif + + retValue = Dddmp_cuddAddStore (ddMgr, NULL, f, varInfo->orderedVarNames, + varInfo->varAuxIdsAll, DDDMP_MODE_TEXT, varoutinfo, fileName, NULL); + + Dddmp_CheckAndReturn (retValue!=DDDMP_SUCCESS, "BDD NOT stored."); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Store a BDD in a file.] + + Description [Store a BDD in a file.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +AddArrayStore ( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode ***operandBddArray /* IN: Array of operand ADD */, + int *operandBddArraySize /* IN: Number of ADD in the Array */, + dddmpVarInfo_t *varInfo + ) +{ + int i, retValue, nRoots; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD_ARRAY, &i); + + nRoots = operandBddArraySize[i]; + + fprintf (stdout, "Storing Array of BDDs in file %s ...\n", fileName); + fflush (stdout); + + retValue = Dddmp_cuddAddArrayStore (ddMgr, NULL, nRoots, operandBddArray[i], + NULL, varInfo->orderedVarNames, varInfo->varAuxIdsAll, DDDMP_MODE_TEXT, + DDDMP_VARIDS, fileName, NULL); + + Dddmp_CheckAndReturn (retValue!=DDDMP_SUCCESS, "BDD NOT stored."); + + fprintf (stdout, "done.\n"); + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Store a BDD as CNF format in a file.] + + Description [Store a BDD as CNF format in a file.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +BddStoreCnf( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode **operandBdd /* IN: Array of operand ADD */, + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + DdNode *f = NULL; + Dddmp_DecompCnfStoreType storingMode = DDDMP_CNF_MODE_BEST; + int noHeader = 0; + int i, nVars, retValue, idInitial, varNewN, clauseNewN; + int edgeInTh = (-1); + int pathLengthTh = (-1); + int *tmpBddIds = NULL; + int *tmpCnfIds = NULL; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + char row[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD, &i); + ReadString (DDDMP_MESSAGE_FORMAT, row); + + switch (row[0]) { + case 'N': + storingMode = DDDMP_CNF_MODE_NODE; + break; + case 'M': + storingMode = DDDMP_CNF_MODE_MAXTERM; + break; + case 'B': + storingMode = DDDMP_CNF_MODE_BEST; + ReadInt (DDDMP_MESSAGE_EDGE_MAX, &edgeInTh); + ReadInt (DDDMP_MESSAGE_LENGHT_MAX, &pathLengthTh); + break; + } + ReadInt (DDDMP_MESSAGE_I_ID, &idInitial); + + fprintf (stdout, "Storing %s ...\n", fileName); + fflush (stdout); + + f = operandBdd[i]; + + nVars = varInfo->nDdVars; + + /*------------ From BDD and CNF ids to Proper Array of ids ----------------*/ + + tmpBddIds = DDDMP_ALLOC (int, nVars); + Dddmp_CheckAndGotoLabel (tmpBddIds==NULL, "Error allocating memory.", + failure); + tmpCnfIds = DDDMP_ALLOC (int, nVars); + Dddmp_CheckAndGotoLabel (tmpBddIds==NULL, "Error allocating memory.", + failure); + + for (i=0; i<nVars; i++) { + tmpBddIds[i] = i; + tmpCnfIds[i] = i+1; + } + + retValue = Dddmp_cuddBddStoreCnf (ddMgr, f, storingMode, noHeader, + varInfo->orderedVarNames, tmpBddIds, NULL, tmpCnfIds, idInitial, + edgeInTh, pathLengthTh, fileName, NULL, &clauseNewN, &varNewN); + + Dddmp_CheckAndGotoLabel (retValue!=DDDMP_SUCCESS, "BDD NOT stored.", + failure); + + fprintf (stdout, "Number of Clauses Stored = %d\n", clauseNewN); + fprintf (stdout, "Number of New Variable Created Storing = %d\n", + varNewN); + fflush (stdout); + + DDDMP_FREE (tmpBddIds); + DDDMP_FREE (tmpCnfIds); + + return (DDDMP_SUCCESS); + + failure: + DDDMP_FREE (tmpBddIds); + DDDMP_FREE (tmpCnfIds); + + return(DDDMP_FAILURE); +} + +/**Function******************************************************************** + + Synopsis [Store a BDD as CNF format in a file.] + + Description [Store a BDD as CNF format in a file.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +BddArrayStoreCnf( + DdManager *ddMgr /* IN: CUDD Manager */, + DdNode ***operandBddArray /* IN: Array of operand ADD */, + int *operandBddArraySize /* IN: Number of ADD in the Array */, + dddmpVarInfo_t *varInfo /* IN/OUT: Variable Information */ + ) +{ + Dddmp_DecompCnfStoreType storingMode = DDDMP_CNF_MODE_BEST; + int noHeader = 0; + int i, nVars, bddN, retValue, idInitial, varNewN, clauseNewN; + int edgeInTh = (-1); + int pathLengthTh = (-1); + int *tmpBddIds = NULL; + int *tmpCnfIds = NULL; + char fileName[DDDMPTEST_MAX_FILENAME_LENGTH]; + char row[DDDMPTEST_MAX_FILENAME_LENGTH]; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadString (DDDMP_MESSAGE_FILE, fileName); + ReadInt (DDDMP_MESSAGE_BDD_ARRAY, &bddN); + ReadString (DDDMP_MESSAGE_FORMAT, row); + switch (row[0]) { + case 'N': + storingMode = DDDMP_CNF_MODE_NODE; + break; + case 'M': + storingMode = DDDMP_CNF_MODE_MAXTERM; + break; + case 'B': + storingMode = DDDMP_CNF_MODE_BEST; + ReadInt (DDDMP_MESSAGE_EDGE_MAX, &edgeInTh); + ReadInt (DDDMP_MESSAGE_LENGHT_MAX, &pathLengthTh); + break; + } + ReadInt (DDDMP_MESSAGE_I_ID, &idInitial); + + nVars = varInfo->nDdVars; + + /*------------ From BDD and CNF ids to Proper Array of ids ----------------*/ + + tmpBddIds = DDDMP_ALLOC (int, nVars); + Dddmp_CheckAndReturn (tmpBddIds==NULL, "Allocation error."); + tmpCnfIds = DDDMP_ALLOC (int, nVars); + Dddmp_CheckAndReturn (tmpCnfIds==NULL, "Allocation error."); + + for (i=0; i<nVars; i++) { + tmpBddIds[i] = i; + tmpCnfIds[i] = i*10+1; + } + + fprintf (stdout, "Storing %s ...\n", fileName); + fflush (stdout); + + retValue = Dddmp_cuddBddArrayStoreCnf (ddMgr, operandBddArray[bddN], + operandBddArraySize[bddN], storingMode, noHeader, varInfo->orderedVarNames, + tmpBddIds, NULL, tmpCnfIds, idInitial, edgeInTh, pathLengthTh, fileName, + NULL, &varNewN, &clauseNewN); + + Dddmp_CheckAndGotoLabel (retValue!=DDDMP_SUCCESS, "BDD NOT stored.", + failure); + + fprintf (stdout, "Number of Clauses Stored = %d\n", clauseNewN); + fprintf (stdout, "Number of New Variable Created Storing = %d\n", + varNewN); + fflush (stdout); + + DDDMP_FREE (tmpBddIds); + DDDMP_FREE (tmpCnfIds); + + return (DDDMP_SUCCESS); + + failure: + DDDMP_FREE (tmpBddIds); + DDDMP_FREE (tmpCnfIds); + + return(DDDMP_FAILURE); +} + +/**Function******************************************************************** + + Synopsis [Dynamic Reordering BDDs.] + + Description [Dynamic Reordering BDDs using one of the allowed CUDD + methods.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +DynamicReordering ( + DdManager *ddMgr /* IN: CUDD Manager */ + ) +{ + Cudd_ReorderingType approach = CUDD_REORDER_SIFT; + int method; + + /*------------------------ Read Operation Operands ------------------------*/ + + ReadInt (DDDMP_MESSAGE_REORDERING, &method); + approach = (Cudd_ReorderingType) method; + + Cudd_ReduceHeap (ddMgr, approach, 5); + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Selects variable matching mode.] + + Description [Selects variable matching mode.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +SetLoadMatchmode ( + ) +{ + int sel; + char row[DDDMPTEST_MAX_FILENAME_LENGTH]; + char *retval; + + fprintf (stdout, "Variable matchmode:\n"); + fprintf (stdout, "Match IDs (1)\n"); + fprintf (stdout, "Match permIDs (2)\n"); + fprintf (stdout, "Match names (must have been loaded) (3)\n"); + fprintf (stdout, "Match auxids (must have been loaded) (4)\n"); + fprintf (stdout, "Match composeids (must have been loaded) (5)\n"); + fprintf (stdout, "Your choice: "); + fflush (stdout); + + retval = fgets (row, DDDMPTEST_MAX_STRING_LENGTH, stdin); + if (!retval) + return (DDDMP_FAILURE); + sscanf (row, "%d", &sel); + + switch (sel) { + case 1: + varmatchmode = DDDMP_VAR_MATCHIDS; + break; + case 2: + varmatchmode = DDDMP_VAR_MATCHPERMIDS; + break; + case 3: + varmatchmode = DDDMP_VAR_MATCHNAMES; + break; + case 4: + varmatchmode = DDDMP_VAR_MATCHAUXIDS; + break; + case 5: + varmatchmode = DDDMP_VAR_COMPOSEIDS; + break; + default: + fprintf (stderr, "Wrong choice!\n"); + break; + } + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Complete the internal manager structure for subsequent + BDD/ADD/CNF operations. + ] + + Description [Complete the internal manager structure for subsequent + BDD/ADD/CNF operations. + The phylosophy is simple: to have proper names and ids it is necessary + to load an header before each actual load/store operation. + An header load should initialize variable names, variable ids, + variable compose ids, and variable auxiliary ids for all variables + stored in the file. + This information has to be extended for all variables in the + *current* CUDD manager (before any store operation). + CompleteInfoStruct does this job. + Arrays varIds, varComposeIds, and varAuxIds contain information for + all the variable in the BDD/ADD/CNF while arrays varIdsAll, + varComposeIdsAll, and varAuxIdsAll contain information for *all* + variable in the current CUDD manager. + ] + + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static int +CompleteInfoStruct ( + Dddmp_DecompType ddType /* IN: selects the proper decomp type */, + int nVars /* IN: number of DD variables */, + int nSuppVars /* IN: number of support variables */, + char **suppVarNames /* IN: array of support variable names */, + char **orderedVarNames /* IN: array of variable names */, + int *varIds /* IN: array of variable ids */, + int *varComposeIds /* IN: array of permids ids */, + int *varAuxIds /* IN: array of variable aux ids */, + int nRoots /* IN: number of root in the file */, + dddmpVarInfo_t *varInfo /* IN: Variable Information */ + ) +{ + int i; + char tmpString[DDDMPTEST_MAX_STRING_LENGTH]; + + /*------------------------- Updates Variable Names ------------------------*/ + + DddmpStrArrayFree (varInfo->suppVarNames, varInfo->nSuppVars); + varInfo->suppVarNames = suppVarNames; + + if (varInfo->varNamesFlagUpdate == 1) { + + DddmpStrArrayFree (varInfo->orderedVarNames, varInfo->nVars); + + if (orderedVarNames != NULL) { + varInfo->orderedVarNames = orderedVarNames; + } else { + varInfo->orderedVarNames = DDDMP_ALLOC (char *, nVars); + Dddmp_CheckAndReturn (varInfo->orderedVarNames==NULL, + "Allocation error."); + + for (i=0; i<nVars; i++) { + varInfo->orderedVarNames[i] = NULL; + } + + if (varInfo->suppVarNames != NULL) { + for (i=0; i<nSuppVars; i++) { + varInfo->orderedVarNames[i] = DDDMP_ALLOC (char, + (strlen (varInfo->suppVarNames[i]) + 1)); + strcpy (varInfo->orderedVarNames[i], varInfo->suppVarNames[i]); + } + } + + for (i=0; i<nVars; i++) { + if (varInfo->orderedVarNames[i] == NULL) { + sprintf (tmpString, "DUMMY%d", i); + varInfo->orderedVarNames[i] = DDDMP_ALLOC (char, + (strlen (tmpString) + 1)); + strcpy (varInfo->orderedVarNames[i], tmpString); + } + } + } + } + + /*------------------------------ Updates IDs ------------------------------*/ + + DDDMP_FREE (varInfo->varIds); + varInfo->varIds = varIds; + + if (varInfo->varIdsFlagUpdate == 1) { + + /* Free Previously Allocated Memory */ + DDDMP_FREE (varInfo->varIdsAll); + + /* Allocate New Memory and Check */ + varInfo->varIdsAll = DDDMP_ALLOC (int, nVars); + Dddmp_CheckAndReturn (varInfo->varIdsAll==NULL, "Allocation error."); + + /* Set New Values */ + for (i=0; i<nVars; i++) { + varInfo->varIdsAll[i] = (-1); + } + + if (varInfo->varIds != NULL) { + for (i=0; i<nSuppVars; i++) { + varInfo->varIdsAll[varInfo->varIds[i]] = varInfo->varIds[i]; + } + } + } + + + /*-------------------------- Updates Compose IDs --------------------------*/ + + DDDMP_FREE (varInfo->varComposeIds); + varInfo->varComposeIds = varComposeIds; + + if (varInfo->varComposeIdsFlagUpdate == 1) { + + /* Free Previously Allocated Memory */ + DDDMP_FREE (varInfo->varComposeIdsAll); + + /* Allocate New Memory and Check */ + varInfo->varComposeIdsAll = DDDMP_ALLOC (int, nVars); + Dddmp_CheckAndReturn (varInfo->varComposeIdsAll==NULL, + "Allocation error."); + + /* Set New Values */ + for (i=0; i<nVars; i++) { + varInfo->varComposeIdsAll[i] = (-1); + } + + if (varInfo->varComposeIds != NULL) { + for (i=0; i<nSuppVars; i++) { + varInfo->varComposeIdsAll[varInfo->varIds[i]] = + varInfo->varComposeIds[i]; + } + } + } + + /*------------------------- Updates Auxiliary IDs -------------------------*/ + + DDDMP_FREE (varInfo->varAuxIds); + varInfo->varAuxIds = varAuxIds; + + if (varInfo->varAuxIdsFlagUpdate == 1) { + + /* Free Previously Allocated Memory */ + DDDMP_FREE (varInfo->varAuxIdsAll); + + /* Allocate New Memory and Check */ + varInfo->varAuxIdsAll = DDDMP_ALLOC (int, nVars); + Dddmp_CheckAndReturn (varInfo->varAuxIdsAll==NULL, "Allocation error."); + + /* Set New Values */ + for (i=0; i<nVars; i++) { + varInfo->varAuxIdsAll[i] = (-1); + } + + if (varInfo->varAuxIds != NULL) { + for (i=0; i<nSuppVars; i++) { + varInfo->varAuxIdsAll[varInfo->varIds[i]] = varInfo->varAuxIds[i]; + } + } + } + + /*----------------------------- Updates Sizes -----------------------------*/ + + varInfo->ddType = ddType; + varInfo->nVars = nVars; + varInfo->nSuppVars = nSuppVars; + Dddmp_CheckAndReturn (varInfo->nDdVars<varInfo->nVars, + "Local Manager with Not Enough Variables."); + varInfo->nRoots = nRoots; + + return (DDDMP_SUCCESS); +} + +/**Function******************************************************************** + + Synopsis [Reads an integer value from standard input.] + + Description [Reads an integer value from standard input.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static void +ReadInt ( + Dddmp_MessageType message, + int *i + ) +{ + char row[DDDMPTEST_MAX_FILENAME_LENGTH]; + char *retval; + + switch (message) { + case DDDMP_MESSAGE_MANAGER_VAR: + fprintf (stdout, "Number of Variables: "); + break; + case DDDMP_MESSAGE_BDD: + fprintf (stdout, "Which BDDs [0..%d]: ", + DDDMPTEST_MAX_OPERAND-1); + break; + case DDDMP_MESSAGE_BDD_ARRAY: + fprintf (stdout, "Which Array of BDDs [0..%d]: ", + DDDMPTEST_MAX_OPERAND-1); + break; + case DDDMP_MESSAGE_CUBE: + fprintf (stdout, "How many cubes [1..]: "); + break; + case DDDMP_MESSAGE_INDEX: + fprintf (stdout, "Index: "); + break; + case DDDMP_MESSAGE_SOURCE1: + fprintf (stdout, "Source1 [0..%d]: ", DDDMPTEST_MAX_OPERAND-1); + break; + case DDDMP_MESSAGE_SOURCE2: + fprintf (stdout, "Source2 [0..%d]: ", DDDMPTEST_MAX_OPERAND-1); + break; + case DDDMP_MESSAGE_DESTINATION: + fprintf (stdout, "Destination [0..%d]: ", DDDMPTEST_MAX_OPERAND-1); + break; + case DDDMP_MESSAGE_I_ID: + fprintf (stdout, "Initial ID : "); + break; + case DDDMP_MESSAGE_EDGE_MAX: + fprintf (stdout, + "Max Number of Edges (Insert cut-point from there on) : "); + break; + case DDDMP_MESSAGE_LENGHT_MAX: + fprintf (stdout, + "Max BDD-Path Length (Insert cut-point from there on) : "); + break; + case DDDMP_MESSAGE_REORDERING: + fprintf (stdout, "Reordering Approach (1..17): "); + break; + default: + fprintf (stdout, "Input Generic Integer: "); + break; + } + fflush (stdout); + + retval = fgets (row, DDDMPTEST_MAX_STRING_LENGTH, stdin); + if (!retval) + return; + sscanf (row, "%d", i); + + return; +} + + +/**Function******************************************************************** + + Synopsis [Reads a string from standard input.] + + Description [Reads a string from standard input.] + + SideEffects [] + + SeeAlso [] + +******************************************************************************/ + +static void +ReadString ( + Dddmp_MessageType message, + char string[] + ) +{ + char localString[DDDMPTEST_MAX_STRING_LENGTH]; + char *retval; + + switch (message) { + case DDDMP_MESSAGE_PROMPT: + fprintf (stdout, "TestDddmp> "); + break; + case DDDMP_MESSAGE_FILE: + fprintf (stdout, "File : "); + break; + case DDDMP_MESSAGE_OP: + fprintf (stdout, "Operation [or,and,xor,!,buf(=)] : "); + break; + case DDDMP_MESSAGE_FORMAT: + fprintf (stdout, "Format (Node=N, Maxterm=M, Best=B) : "); + break; + default: + fprintf (stdout, "Input Generic String : "); + break; + } + fflush (stdout); + + string[0] = '\n'; + retval = fgets (localString, DDDMPTEST_MAX_STRING_LENGTH, stdin); + if (!retval) + return; + sscanf (localString, "%s", string); + + return; +} + + + + diff --git a/resources/3rdparty/cudd-3.0.0/doc/Included.am b/resources/3rdparty/cudd-3.0.0/doc/Included.am new file mode 100644 index 000000000..0f745797f --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/doc/Included.am @@ -0,0 +1,19 @@ +EXTRA_DIST += doc/phase.pdf + +if HAVE_PDFLATEX + +doc/cudd.pdf: doc/cudd.tex $(top_srcdir)/doc/phase.pdf + @if $(AM_V_P); then dest='2>&1'; else dest='> /dev/null 2>&1'; fi; \ + cd doc && eval "$(PDFLATEX) cudd $${dest}" && \ + eval "$(MAKEINDEX) cudd $${dest}" && \ + eval "$(PDFLATEX) cudd $${dest}" && \ + eval "$(PDFLATEX) cudd $${dest}" + +CLEANFILES += doc/cudd.pdf doc/cudd.aux doc/cudd.idx doc/cudd.ilg doc/cudd.ind \ + doc/cudd.log doc/cudd.out doc/cudd.toc + +else + +doc/cudd.pdf: + +endif diff --git a/resources/3rdparty/cudd-3.0.0/doc/cudd.tex.in b/resources/3rdparty/cudd-3.0.0/doc/cudd.tex.in new file mode 100644 index 000000000..39cf6a166 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/doc/cudd.tex.in @@ -0,0 +1,2090 @@ +% +% Copyright (c) 1995-2015, Regents of the University of Colorado +% +% All rights reserved. +% +\documentclass[11pt]{article} +\usepackage{makeidx} +\usepackage{graphicx,color} +%\usepackage[pdfpagelabels=false,pageanchor,hyperindex,breaklinks,plainpages=false]{hyperref} +\usepackage[pdfpagelabels=false,pageanchor,hyperindex,plainpages=false]{hyperref} +\newcommand{\eidx}[1]{\index{#1@\emph{#1}}} +\newcommand{\vnumber}{2.7.0} +\title{CUDD: CU Decision Diagram Package\\Release \vnumber} +\author{Fabio Somenzi\\ +Department of Electrical, Computer, and Energy Engineering\\ +University of Colorado at Boulder\\ +$<$Fabio@Colorado.EDU$>$} +\makeindex +\begin{document} +\bibliographystyle{plain} +\maketitle + +\tableofcontents +\clearpage + +%---------------------------------------- +\section{Introduction} +\label{sec:intro} + +The CUDD package provides functions to manipulate Binary Decision +Diagrams\index{BDD} (BDDs) \cite{BDD,BBR}, +Algebraic Decision Diagrams\index{ADD} (ADDs) +\cite{Bahar93}, and Zero-suppressed Binary Decision +Diagrams\index{ZDD} (ZDDs) +\cite{Minato93}. BDDs are used to represent +switching\index{function!switching} functions; ADDs are used to +represent functions from $\{0,1\}^n$ to an arbitrary set. ZDDs +represent switching\index{function!switching} functions like BDDs; +however, they are much more efficient than BDDs when the functions to +be represented are characteristic\index{function!characteristic} +functions of cube\index{cube sets} sets, or in general, when the +ON-set\index{function!ON-set} of the function to be represented is +very sparse. They are inferior to BDDs in other cases. + +The package provides a large set of operations on BDDs, ADDs, and +ZDDs, functions to convert BDDs into ADDs or ZDDs and vice versa, and +a large assortment of variable reordering\index{reordering} methods. + +The CUDD package can be used in three ways: +\begin{itemize} +\item As a black box\index{box!black}. In this case, the application + program that needs to manipulate decision diagrams only uses the + exported functions of the package. The rich set of functions + included in the CUDD package allows many applications to be written + in this way. Section~\ref{sec:user} describes how to use the + exported functions of the package. An application written in terms + of the exported functions of the package needs not concern itself + with the details of variable reordering\index{reordering}, which may + take place behind the scenes. +\item As a clear box\index{box!clear}. When writing a sophisticated + application based on decision diagrams, efficiency often dictates + that some functions be implemented as direct recursive manipulation + of the diagrams, instead of being written in terms of existing + primitive functions. Section~\ref{sec:prog} explains how to add new + functions to the CUDD package. It also details how to write a + recursive function that may be interrupted by + dynamic\index{reordering!dynamic} variable reordering. +\item Through an interface. Object-oriented languages like C++ and + Perl5 can free the programmer from the burden of memory management. + A C++ interface is included in the distribution of CUDD. It + automatically frees decision diagrams that are no longer used by the + application and overloads operators. Almost all the functionality + provided by the CUDD exported functions is available through the C++ + interface, which is especially recommended for fast prototyping. + Section~\ref{sec:cpp} explains how to use the interface. A Perl5 + interface also exists and is ditributed separately. (See + Section~\ref{sec:getFriends}.) +\end{itemize} +In the following, the reader is supposed to be familiar with the basic +ideas about decision diagrams, as found, for instance, in \cite{BBR}. + +%---------------------------------------- +\section{How to Get CUDD} +\label{sec:getting} + +\subsection{The CUDD Package} +\label{sec:getCUDD} + +The CUDD package is available via anonymous FTP\index{FTP} from +vlsi.Colorado.EDU\@. A compressed tar file named +\texttt{cudd-\vnumber.tar.gz} can be found in directory \texttt{pub}. +Once you have this file, +\begin{quote} + \tt gzip\index{gzip} -dc cudd-\vnumber.tar.gz | tar xvf - +\end{quote} +will create directory \texttt{cudd-\vnumber} and its subdirectories. +These directories contain the decision diagram package, a few support +libraries\index{libraries}, and a test application based on the +decision diagram package. There is a README\index{README file} file +with instructions on configuration\index{configuration} and +installation\index{installation} in \texttt{cudd-\vnumber}. In short, +CUDD uses the GNU Autotools for its build. + +Once you have made the libraries and program, you can type +\texttt{make check} to perform a sanity check. Among other things, +\texttt{make check} executes commands like +\begin{quote} + \tt cd nanotrav\index{nanotrav} \\ + nanotrav -p 1 -autodyn -reordering sifting -trav mult32a.blif +\end{quote} +This command runs a simple-minded FSM traversal program on a simple +model. (On a reasonable machine, it takes less than 0.5 s.) The output +produced by the program is checked against +\texttt{cudd-\vnumber/nanotrav/mult32a.out}. More information on the +\texttt{nanotrav\index{nanotrav}} test program can be found in the file +\texttt{cudd-\vnumber/nanotrav/README\index{README file}}. + +If you want to be notified of new releases of the CUDD package, send a +message to \texttt{Fabio@Colorado.EDU}. + +\subsection{CUDD Friends} +\label{sec:getFriends} + +Two CUDD extensions are available via anonymous FTP\index{FTP} from +vlsi.Colorado.EDU\@. +\begin{itemize} +\item \emph{PerlDD} is an object-oriented Perl5 interface to CUDD. It + is organized as a standard Perl extension module. The Perl interface + is at a somewhat higher level than the C++ interface, but it is not + as complete. +\item \emph{DDcal} is a graphic BDD calculator based on CUDD, Perl-Tk, + and dot. (See Section~\ref{sec:dump} for information on \emph{dot}.) + +\end{itemize} +%---------------------------------------- +\section{User's Manual} +\label{sec:user} + +This section describes the use of the CUDD package as a black box. + +\subsection{Compiling and Linking} +\label{sec:compileExt}\index{compiling} + +To build an application that uses the CUDD package, you should add +\begin{verbatim} +#include "cudd.h" +\end{verbatim} +\index{cudd.h} +to your source files, and should link +\verb|libcudd.a|\index{libraries!cudd} to your executable. + +Keep in mind that whatever flags affect the size of data +structures---for instance the flags used to use 64-bit pointers where +available---must be specified when compiling both CUDD and the files +that include its header files. + +\subsection{Basic Data Structures} +\label{sec:struct} + +\subsubsection{Nodes} +\label{sec:nodes} + +BDDs, ADDs, and ZDDs are made of DdNode's. A DdNode\index{DdNode} +(node\index{node} for short) is a structure with several fields. Those +that are of interest to the application that uses the CUDD package as +a black box are the variable index\index{node!variable index}, the +reference\index{node!reference count} count, and the value. The +remaining fields are pointers that connect nodes among themselves and +that are used to implement the unique\index{table!unique} table. (See +Section~\ref{sec:manager}.) + +The \emph{index} field holds the name of the variable that labels the +node. The index of a variable is a permanent attribute that reflects +the order\index{variable!order} of creation. Index 0 corresponds to +the variable created first. On a machine with 32-bit pointers, the +maximum number of variables is the largest value that can be stored in +an unsigned short integer minus 1. The largest index is reserved for +the constant\index{node!constant} nodes. When 64-bit pointers are +used, the maximum number of variables is the largest value that can be +stored in an unsigned integer minus 1. + +When variables are reordered to reduce the size of the decision +diagrams, the variables may shift in the order, but they retain their +indices. The package keeps track of the variable +permutation\index{variable!permutation} (and its inverse). The +application is not affected by variable reordering\index{reordering}, +except in the following cases. +\begin{itemize} +\item If the application uses generators\index{generator} + (\emph{Cudd\_ForeachCube} \eidx{Cudd\_ForeachCube} and + \emph{Cudd\_ForeachNode}\eidx{Cudd\_ForeachNode}) and reordering is + enabled, then it must take care not to call any operation that may + create new nodes (and hence possibly trigger reordering). This is + because the cubes (i.e., paths) and nodes of a diagram change as a + result of reordering. +\item If the application uses + \emph{Cudd\_bddConstrain}\eidx{Cudd\_bddConstrain} and reordering + takes place, then the property of \emph{Cudd\_bddConstrain} of + being an image restrictor is lost. +\end{itemize} + +The CUDD package relies on garbage\index{garbage collection} +collection to reclaim the memory used by diagrams that are no longer +in use. The scheme employed for garbage collection is based on keeping +a reference\index{node!reference count} count for each node. The +references that are counted are both the internal references +(references from other nodes) and external references (typically +references from the calling environment). When an application creates +a new BDD\index{BDD}, ADD\index{ADD}, or ZDD\index{ZDD}, it must +increase its reference count explicitly, through a call to +\emph{Cudd\_Ref}\eidx{Cudd\_Ref}. Similarly, when a diagram is no +longer needed, the application must call +\emph{Cudd\_RecursiveDeref}\eidx{Cudd\_RecursiveDeref} (for BDDs and +ADDs) or \emph{Cudd\_RecursiveDerefZdd}\eidx{Cudd\_RecursiveDerefZdd} +(for ZDDs) to ``recycle\index{node!recycling}'' the nodes of the +diagram. + +Terminal\index{node!constant!value} nodes carry a value. This is especially +important for ADDs. By default, the value is a double% +\index{floating point!double (C type)}. +To change to something different (e.g., an integer), the +package must be modified and recompiled. Support for this process is +very rudimentary. + +\subsubsection{The Manager} +\index{manager}\label{sec:manager} + +All nodes used in BDDs, ADDs, and ZDDs are kept in special +hash\index{table!hash} tables called the +\emph{unique\index{table!unique} tables}. Specifically, BDDs and ADDs +share the same unique table, whereas ZDDs have their own table. As +the name implies, the main purpose of the unique table is to guarantee +that each node is unique; that is, there is no other node labeled by +the same variable and with the same children. This uniqueness +property makes decision diagrams canonical\index{canonical}. The +unique\index{table!unique} tables and some auxiliary data structures +make up the DdManager\index{DdManager} (manager\index{manager} for +short). Though the application that uses only the exported functions +needs not be concerned with most details of the manager, it has to +deal with the manager in the following sense. The application must +initialize the manager by calling an appropriate function. (See +Section~\ref{sec:init}.) Subsequently, it must pass a pointer to the +manager to all the functions that operate on decision diagrams. + +% With the exception of a few statistical counters\index{statistical +% counters}, there are no global\index{global variables} variables in +% the CUDD package. Therefore, it is possible to have multiple +% managers simultaneously active in the same application.\footnote{The +% global statistical counters are used locally; hence they are +% compatible with the use of multiple managers.} It is the pointers to +% the managers that tell the functions on what data they should operate. + +\subsubsection{Cache} +\index{cache}\label{sec:memoize} + +Efficient recursive manipulation of decision diagrams requires the use +of a table to store computed results. This table\index{table!computed} +is called here the \emph{cache\index{cache}} because it is +effectively handled like a cache of variable but limited capacity. The +CUDD package starts by default with a small cache, and increases its +size until either no further benefit is achieved, or a limit size is +reached. The user can influence this policy by choosing initial and +limit values for the cache size. + +Too small a cache will cause frequent overwriting of useful results. +Too large a cache will cause overhead, because the whole cache is +scanned every time garbage\index{garbage collection} collection takes +place. The optimal parameters depend on the specific application. The +default parameters work reasonably well for a large spectrum of +applications. + +The cache\index{cache} of the CUDD package is used by most recursive +functions of the package, and can be used by user-supplied functions +as well. (See Section~\ref{sec:cache}.) + +\subsection{Initializing and Shutting Down a DdManager} +\index{DdManager}\label{sec:init} + +To use the functions in the CUDD package, one has first to initialize +the package itself by calling \emph{Cudd\_Init}\eidx{Cudd\_Init}. +This function takes four parameters: +\begin{itemize} +\item numVars\index{numVars}: It is the initial number of variables + for BDDs and ADDs. If the total number of variables needed by the + application is known, then it is slightly more efficient to create a + manager with that number of variables. If the number is unknown, it + can be set to 0, or to any other lower bound on the number of + variables. Requesting more variables than are actually needed is + not incorrect, but is not efficient. +\item numVarsZ\index{numVarsZ}: It is the initial number of variables + for ZDDs. See Sections~\ref{sec:basicZDD} and~\ref{sec:convertZ} for + a discussion of the value of this argument. +\item numSlots\index{numSlots}: Determines the initial size of each + subtable\index{subtable} of the unique\index{table!unique} table. + There is a subtable for each variable. The size of each subtable is + dynamically adjusted to reflect the number of nodes. It is normally + O.K. to use the default value for this parameter, which is + CUDD\_UNIQUE\_SLOTS\index{CUDD\_UNIQUE\_SLOTS}. +\item cacheSize\index{cacheSize}: It is the initial size (number of + entries) of the cache\index{cache}. Its default value is + CUDD\_CACHE\_SLOTS\index{CUDD\_CACHE\_SLOTS}. +\item maxMemory\index{maxMemory}: It is the target value for the + maximum memory occupation (in bytes). The package uses this value to + decide two parameters. + \begin{itemize} + \item the maximum size to which the cache will grow, regardless of + the hit rate or the size of the unique\index{table!unique} table. + \item the maximum size to which growth of the unique table will be + preferred to garbage collection. + \end{itemize} + If maxMemory is set to 0, CUDD tries to guess a good value based on + the available memory. +\end{itemize} +A typical call to \emph{Cudd\_Init}\eidx{Cudd\_Init} may look +like this: +\begin{verbatim} + manager = Cudd_Init(0,0,CUDD_UNIQUE_SLOTS,CUDD_CACHE_SLOTS,0); +\end{verbatim} +To reclaim all the memory associated with a manager, an application +must call \emph{Cudd\_Quit}\eidx{Cudd\_Quit}. This is normally +done before exiting. + + +\subsection{Setting Parameters} +\label{sec:params} + +The package provides several functions to set the parameters that +control various functions. For instance, the package has an automatic +way of determining whether a larger unique\index{table!unique} table +would make the application run faster. In that case, the package +enters a ``fast growth\index{table!growth}'' mode in which resizing of +the unique subtables is favored over garbage\index{garbage collection} +collection. When the unique table reaches a given size, however, the +package returns to the normal ``slow growth'' mode, even though the +conditions that caused the transition to fast growth still prevail. +The limit size for fast growth\index{growth} can be read by +\emph{Cudd\_ReadLooseUpTo}\eidx{Cudd\_ReadLooseUpto} and changed by +\emph{Cudd\_SetLooseUpTo}\eidx{Cudd\_SetLooseUpTo}. Similar pairs of +functions exist for several other parameters. See also +Section~\ref{sec:stats}. + +\subsection{Constant Functions} +\index{node!constant}\label{sec:const} + +The CUDD Package defines several constant functions. These functions +are created when the manager\index{manager} is initialized, and are accessible +through the manager itself. + +\subsubsection{One, Logic Zero, and Arithmetic Zero} +\index{zero!logical}\index{zero!arithmetic}\label{sec:zero} + +The constant\index{node!constant} 1 (returned by +\emph{Cudd\_ReadOne}\eidx{Cudd\_ReadOne}) is common to BDDs, ADDs, and +ZDDs. However, its meaning is different for ADDs and BDDs, on the one +hand, and ZDDs, on the other hand. The diagram consisting of the +constant 1 node only represents the constant 1 function for ADDs and +BDDs. For ZDDs, its meaning depends on the number of variables: It is +the conjunction of the complements of all variables. Conversely, the +representation of the constant 1 function depends on the number of +variables. The constant 1 function of $n$ variables is returned by +\emph{Cudd\_ReadZddOne}\eidx{Cudd\_ReadZddOne}. + +The constant 0 is common to ADDs and ZDDs, but not to BDDs. The +BDD\index{BDD} logic 0 is {\bf not} associated with the constant 0 +function: It is obtained by complementation +(\emph{Cudd\_Not}\eidx{Cudd\_Not}) of the constant 1. (It is also +returned by \emph{Cudd\_ReadLogicZero}\eidx{Cudd\_ReadLogicZero}.) +All other constants are specific to ADDs. + +\subsubsection{Predefined Constants} +\label{sec:predef-const} + +Besides 0 (returned by \emph{Cudd\_ReadZero}\eidx{Cudd\_ReadZero}) +and 1, the following constant\index{node!constant} functions are +created at initialization time. +\begin{enumerate} +\item PlusInfinity\index{PlusInfinity} and + MinusInfinity\index{MinusInfinity}: On computers implementing the + IEEE\index{floating point!IEEE Standard 754} standard 754 for + floating-point\index{floating point} arithmetic, these two constants + are set to the signed infinities\index{infinities}. The values of + these constants are returned by + \emph{Cudd\_ReadPlusInfinity}\eidx{Cudd\_ReadPlusInfinity} and + \emph{Cudd\_ReadMinusInfinity}\eidx{Cudd\_ReadMinusInfinity}. +\item Epsilon\index{Epsilon}: This constant, initially set to + $10^{-12}$, is used in comparing floating point values for equality. + Its value is returned by the function + \emph{Cudd\_ReadEpsilon}\eidx{Cudd\_ReadEpsilon}, and it can be + modified by calling \emph{Cudd\_SetEpsilon}\eidx{Cudd\_SetEpsilon}. + Unlike the other constants, it does not correspond to a node. +\end{enumerate} + +\subsubsection{Background} +\index{background value}\label{sec:background} + +The background value is a constant\index{node!constant} typically used +to represent non-existing arcs in graphs. Consider a shortest path +problem. Two nodes that are not connected by an arc can be regarded as +being joined by an arc\index{graph!arc length} of infinite length. In +shortest path problems, it is therefore convenient to set the +background value to PlusInfinity\index{PlusInfinity}. In network flow +problems, on the other hand, two nodes not connected by an arc can be +regarded as joined by an arc\index{graph!arc capacity} of 0 capacity. +For these problems, therefore, it is more convenient to set the +background value to 0. In general, when representing +sparse\index{matrix!sparse} matrices, the background value is the value that +is assumed implicitly. + +At initialization, the background value is set to 0. It can be read +with \emph{Cudd\_ReadBackground}\eidx{Cudd\_ReadBackground}, and +modified with \emph{Cudd\_SetBackground}. The background value +affects procedures that read sparse matrices and graphs +(like \emph{Cudd\_addRead}\eidx{Cudd\_addRead} and +\emph{Cudd\_addHarwell}\eidx{Cudd\_addHarwell}), procedures that print +out sum-of-product\index{function!sum of products} expressions for +ADDs (\emph{Cudd\_PrintMinterm}\eidx{Cudd\_PrintMinterm}), generators +of cubes (\emph{Cudd\_ForeachCube}\eidx{Cudd\_ForeachCube}), and +procedures that count minterms\index{function!minterms} +(\emph{Cudd\_CountMinterm}\eidx{Cudd\_CountMinterm}). + +\subsubsection{New Constants} +\label{sec:newconst} + +New constant\index{node!constant} can be created by calling +\emph{Cudd\_addConst}\eidx{Cudd\_addConst}. This function will +retrieve the ADD\index{ADD} for the desired constant, if it already +exist, or it will create a new one. Obviously, new constants should +only be used when manipulating ADDs. + +\subsection{Creating Variables} +\label{sec:newvar} + +Decision diagrams are typically created by combining simpler decision +diagrams. The simplest decision diagrams, of course, cannot be +created in that way. Constant functions have been discussed in +Section~\ref{sec:const}. In this section we discuss the simple +variable functions, also known as \emph{projection\index{projection + functions} functions}. + +\subsubsection{New BDD and ADD Variables} +\label{sec:BDDADDvar} + +The projection\index{projection functions} functions are distinct for +BDDs and ADDs. A projection function for BDDs consists of an internal +node with both outgoing arcs pointing to the constant 1. The +\emph{else} arc\index{arc!complement} is complemented. + +An ADD projection function, on the other hand, has the \emph{else} +pointer directed to the arithmetic\index{zero!arithmetic} zero +function. One should never mix the two types of variables. BDD +variables should be used when manipulating BDDs, and ADD variables +should be used when manipulating ADDs. Three functions are provided +to create BDD variables: +\begin{itemize} +\item \emph{Cudd\_bddIthVar}\eidx{Cudd\_bddIthVar}: Returns + the projection\index{projection functions} function with index $i$. + If the function does not exist, it is created. +\item \emph{Cudd\_bddNewVar}\eidx{Cudd\_bddNewVar}: Returns a + new projection\index{projection functions} function, whose index is + the largest index in use at the time of the call, plus 1. +\item \emph{Cudd\_bddNewVarAtLevel}\eidx{Cudd\_bddNewVarAtLevel}: + Similar to \emph{Cudd\_bddNewVar}\eidx{Cudd\_bddNewVar}. In + addition it allows to specify the position in the variable + order\index{variable!order} at which the new variable should be + inserted. In contrast, \emph{Cudd\_bddNewVar}\eidx{Cudd\_bddNewVar} + adds the new variable at the end of the order. +\end{itemize} +The analogous functions for ADDs are +\emph{Cudd\_addIthVar}\eidx{Cudd\_addIthVar}, +\emph{Cudd\_addNewVar}\eidx{Cudd\_addNewVar}, and +\emph{Cudd\_addNewVarAtLevel}\eidx{Cudd\_addNewVarAtLevel}. + +\subsubsection{New ZDD Variables} +\index{ZDD}\label{sec:ZDDvars} + +Unlike the projection functions of BDDs and ADDs, the +projection\index{projection functions} functions of ZDDs have diagrams +with $n+1$ nodes, where $n$ is the number of variables. Therefore the +ZDDs of the projection functions change when new variables are added. +This will be discussed in Section~\ref{sec:basicZDD}. Here we assume +that the number of variables is fixed. The ZDD of the $i$-th +projection function is returned by +\emph{Cudd\_zddIthVar}\eidx{Cudd\_zddIthVar}. + +\subsection{Basic BDD Manipulation} +\index{BDD}\label{sec:basicBDD} + +Common manipulations of BDDs can be accomplished by calling +\emph{Cudd\_bddIte}. This function takes three BDDs, $f$, $g$, and +$h$, as arguments and computes $f\cdot g + f'\cdot h$. Like all the +functions that create new BDDs or ADDs, \emph{Cudd\_bddIte}\eidx{Cudd\_bddIte} returns a result that must be +explicitly referenced by the caller. \emph{Cudd\_bddIte} can be used +to implement all two-argument Boolean functions. However, the package +also provides \emph{Cudd\_bddAnd}\eidx{Cudd\_bddAnd} as well as the +other two-operand Boolean functions, which are slightly more efficient +when a two-operand function is called for. The following fragment of +code illustrates how to build the BDD for the function $f = +x_0'x_1'x_2'x_3'$. +\begin{verbatim} + DdManager *manager; + DdNode *f, *var, *tmp; + int i; + + ... + + f = Cudd_ReadOne(manager); + Cudd_Ref(f); + for (i = 3; i >= 0; i--) { + var = Cudd_bddIthVar(manager,i); + tmp = Cudd_bddAnd(manager,Cudd_Not(var),f); + Cudd_Ref(tmp); + Cudd_RecursiveDeref(manager,f); + f = tmp; + } +\end{verbatim} +This example illustrates the following points: +\begin{itemize} +\item Intermediate results must be ``referenced'' and + ``dereferenced.'' However, \texttt{var} is a + projection\index{projection functions} function, and its + reference\index{node!reference count} count is always greater than + 0. Therefore, there is no call to \emph{Cudd\_Ref}\eidx{Cudd\_Ref}. +\item The new \texttt{f} must be assigned to a temporary variable + (\texttt{tmp} in this example). If the result of + \emph{Cudd\_bddAnd}\eidx{Cudd\_bddAnd} were assigned directly to + \texttt{f}, the old \texttt{f} would be lost, and there would be no + way to free its nodes. +\item The statement \texttt{f = tmp} has the same effect as: +\begin{verbatim} + f = tmp; + Cudd_Ref(f); + Cudd_RecursiveDeref(manager,tmp); +\end{verbatim} + but is more efficient. The reference\index{node!reference count} is + ``passed'' from \texttt{tmp} to \texttt{f}, and \texttt{tmp} is now + ready to be reutilized. +\item It is normally more efficient to build BDDs ``bottom-up.'' This + is why the loop goes from 3 to 0. Notice, however, that after + variable reordering, higher index does not necessarily mean ``closer + to the bottom.'' Of course, in this simple example, efficiency is + not a concern. +\item Had we wanted to conjoin the variables in a bottom-up fashion + even after reordering, we should have used + \emph{Cudd\_ReadInvPerm}\eidx{Cudd\_ReadInvPerm}. One has to be + careful, though, to fix the order of conjunction before entering the + loop. Otherwise, if reordering takes place, it is possible to use + one variable twice and skip another variable. +\end{itemize} + +\subsection{Basic ADD Manipulation} +\index{ADD}\label{sec:basicADD} + +The most common way to manipulate ADDs is via +\emph{Cudd\_addApply}\eidx{Cudd\_addApply}. This function can apply a +wide variety of operators to a pair of ADDs. Among the available +operators are addition, multiplication, division, minimum, maximum, +and Boolean operators that work on ADDs whose leaves are restricted to +0 and 1 (0-1 ADDs). + +The following fragment of code illustrates how to build the ADD for +the function $f = 5x_0x_1x_2x_3$. +\begin{verbatim} + DdManager *manager; + DdNode *f, *var, *tmp; + int i; + + ... + + f = Cudd_addConst(manager,5); + Cudd_Ref(f); + for (i = 3; i >= 0; i--) { + var = Cudd_addIthVar(manager,i); + Cudd_Ref(var); + tmp = Cudd_addApply(manager,Cudd_addTimes,var,f); + Cudd_Ref(tmp); + Cudd_RecursiveDeref(manager,f); + Cudd_RecursiveDeref(manager,var); + f = tmp; + } +\end{verbatim} +This example, contrasted to the example of BDD manipulation, +illustrates the following points: +\begin{itemize} +\item The ADD projection\index{projection functions} function are not + maintained by the manager. It is therefore necessary to + reference\index{node!reference} and + dereference\index{node!dereference} them. +\item The product of two ADDs is computed by calling + \emph{Cudd\_addApply}\eidx{Cudd\_addApply} with + \emph{Cudd\_addTimes}\eidx{Cudd\_addTimes} as parameter. There is + no ``apply'' function for BDDs, because + \emph{Cudd\_bddAnd}\eidx{Cudd\_bddAnd} and + \emph{Cudd\_bddXor}\eidx{Cudd\_bddXor} plus complementation are + sufficient to implement all two-argument Boolean functions. +\end{itemize} + +\subsection{Basic ZDD Manipulation} +\index{ZDD}\label{sec:basicZDD} + +ZDDs are often generated by converting\index{conversion!of BDDs to ZDDs} +existing BDDs. (See Section~\ref{sec:convertZ}.) However, it is also +possible to build ZDDs by applying Boolean operators to other ZDDs, +starting from constants and projection\index{projection functions} +functions. The following fragment of code illustrates how to build +the ZDD for the function $f = x_0'+x_1'+x_2'+x_3'$. We assume that the +four variables already exist in the manager when the ZDD for $f$ is +built. Note the use of De Morgan's law. +\begin{verbatim} + DdManager *manager; + DdNode *f, *var, *tmp; + int i; + + manager = Cudd_Init(0,4,CUDD_UNIQUE_SLOTS, + CUDD_CACHE_SLOTS,0); + ... + + tmp = Cudd_ReadZddOne(manager,0); + Cudd_Ref(tmp); + for (i = 3; i >= 0; i--) { + var = Cudd_zddIthVar(manager,i); + Cudd_Ref(var); + f = Cudd_zddIntersect(manager,var,tmp); + Cudd_Ref(f); + Cudd_RecursiveDerefZdd(manager,tmp); + Cudd_RecursiveDerefZdd(manager,var); + tmp = f; + } + f = Cudd_zddDiff(manager,Cudd_ReadZddOne(manager,0),tmp); + Cudd_Ref(f); + Cudd_RecursiveDerefZdd(manager,tmp); +\end{verbatim} +This example illustrates the following points: +\begin{itemize} +\item The projection\index{projection functions} functions are + referenced, because they are not maintained by the manager. +\item Complementation is obtained by subtracting from the constant 1 + function. +\item The result of \emph{Cudd\_ReadZddOne}\eidx{Cudd\_ReadZddOne} + does not require referencing. +\end{itemize} +CUDD provides functions for the manipulation of +covers\index{function!cover} represented by ZDDs. For instance, +\emph{Cudd\_zddIsop}\eidx{Cudd\_zddIsop} builds a ZDD representing an +irredundant\index{function!cover!irredundant} sum of products for the +incompletely specified function defined by the two BDDs $L$ and $U$. +\emph{Cudd\_zddWeakDiv}\eidx{Cudd\_zddWeakDiv} performs the weak +division of two covers given as ZDDs. These functions expect the two +ZDD variables corresponding to the two literals of the function +variable to be adjacent. One has to create variable groups (see +Section~\ref{sec:reordZ}) for reordering\index{reordering!of ZDDs} of +the ZDD variables to work. BDD automatic reordering is safe even +without groups: If realignment of ZDD and ADD/BDD variables is +requested (see Section~\ref{sec:consist}) groups will be kept +adjacent. + +\subsection{Converting ADDs to BDDs and Vice Versa} +\index{conversion!of ADDs to BDDs} +\index{conversion!of BDDs to ADDs}\label{sec:convert} + +Several procedures are provided to convert ADDs to BDDs, according to +different criteria. +(\emph{Cudd\_addBddPattern}\eidx{Cudd\_addBddPattern}, +\emph{Cudd\_addBddInterval}\eidx{Cudd\_addBddInterval}, and +\emph{Cudd\_addBddThreshold}\eidx{Cudd\_addBddThreshold}.) The +conversion from BDDs to ADDs +(\emph{Cudd\_BddToAdd}\eidx{Cudd\_BddToAdd}) is based on the simple +principle of mapping the logical 0\index{zero!logical} and 1 on the +arithmetic\index{zero!arithmetic} 0 and 1. It is also possible to +convert an ADD with integer values (more precisely, floating point +numbers with 0 fractional part) to an array of BDDs by repeatedly +calling \emph{Cudd\_addIthBit}\eidx{Cudd\_addIthBit}. + +\subsection{Converting BDDs to ZDDs and Vice Versa} +\index{conversion!of ZDDs to BDDs} +\index{conversion!of BDDs to ZDDs}\label{sec:convertZ} + +Many applications first build a set of BDDs and then derive ZDDs from +the BDDs. These applications should create the manager with 0 +ZDD\index{ZDD} variables and create the BDDs. Then they should call +\emph{Cudd\_zddVarsFromBddVars}\eidx{Cudd\_zddVarsFromBddVars} to +create the necessary ZDD variables---whose number is likely to be +known once the BDDs are available. This approach eliminates the +difficulties that arise when the number of ZDD variables changes while +ZDDs are being built. + +The simplest conversion from BDDs to ZDDs is a simple change of +representation, which preserves the functions. Simply put, given a BDD +for $f$, a ZDD for $f$ is requested. In this case the correspondence +between the BDD variables and ZDD variables is one-to-one. Hence, +\emph{Cudd\_zddVarsFromBddVars} should be called with the +\emph{multiplicity} parameter equal to 1. The conversion proper can +then be performed by calling +\emph{Cudd\_zddPortFromBdd}\eidx{Cudd\_zddPortFromBdd}. The inverse +transformation is performed by +\emph{Cudd\_zddPortToBdd}\eidx{Cudd\_zddPortToBdd}. + +ZDDs are quite often used for the representation of +\emph{covers}\index{function!cover}. This is normally done by +associating two ZDD variables to each variable of the function. (And +hence, typically, to each BDD variable.) One ZDD variable is +associated with the positive literal of the BDD variable, while the +other ZDD variable is associated with the negative literal. A call to +\emph{Cudd\_zddVarsFromBddVars}\eidx{Cudd\_zddVarsFromBddVars} with +\emph{multiplicity} equal to 2 will associate to BDD variable $i$ the +two ZDD variables $2i$ and $2i+1$. + +If a BDD variable group tree exists when +\emph{Cudd\_zddVarsFromBddVars} is called (see +Section~\ref{sec:group}) the function generates a ZDD variable group +tree consistent to it. In any case, all the ZDD variables derived +from the same BDD variable are clustered into a group. + +If the ZDD for $f$ is created and later a new ZDD variable is added to +the manager, the function represented by the existing ZDD changes. +Suppose, for instance, that two variables are initially created, and +that the ZDD for $f = x_0 + x_1$ is built. If a third variable is +added, say $x_2$, then the ZDD represents $g = (x_0 + x_1) x_2'$ +instead. This change in function obviously applies regardless of what +use is made of the ZDD\@. However, if the ZDD is used to represent a +cover\index{function!cover}, the cover itself is not changed by the +addition of new variable. (What changes is the +characteristic\index{function!characteristic} function of the cover.) + +\subsection{Variable Reordering for BDDs and ADDs} +\index{reordering!of BDDs and ADDs}\label{sec:reorder} + +The CUDD package provides a rich set of +dynamic\index{reordering!dynamic} reordering algorithms. Some of them +are slight variations of existing techniques +\cite{Rudell93,Drechs95,Bollig95,Ishiur91,Plessi93,Jeong93}; some +others have been developed specifically for this package +\cite{Panda94,Panda95b}. + +Reordering affects a unique\index{table!unique} table. This means that +BDDs and ADDs, which share the same unique table are simultaneously +reordered. ZDDs, on the other hand, are reordered separately. In the +following we discuss the reordering of BDDs and ADDs. Reordering for +ZDDs is the subject of Section~\ref{sec:reordZ}. + +Reordering of the variables can be invoked directly by the application +by calling \emph{Cudd\_ReduceHeap}\eidx{Cudd\_ReduceHeap}. Or it can +be automatically triggered by the package when the number of nodes has +reached a given threshold\index{reordering!threshold}. (The threshold +is initialized and automatically adjusted after each reordering by the +package.) To enable automatic dynamic reordering (also called +\emph{asynchronous\index{reordering!asynchronous}} dynamic reordering +in this document) the application must call +\emph{Cudd\_AutodynEnable}\eidx{Cudd\_AutodynEnable}. Automatic +dynamic reordering can subsequently be disabled by calling +\emph{Cudd\_AutodynDisable}\eidx{Cudd\_AutodynDisable}. + +All reordering methods are available in both the case of direct call +to \emph{Cudd\_ReduceHeap}\eidx{Cudd\_ReduceHeap} and the case of +automatic invocation. For many methods, the reordering procedure is +iterated until no further improvement is obtained. We call these +methods the \emph{converging\index{reordering!converging}} methods. +When constraints are imposed on the relative position of variables +(see Section~\ref{sec:group}) the reordering methods apply inside the +groups. The groups\index{reordering!group} themselves are reordered +by sifting\index{reordering!sifting}. Each method is identified by a +constant of the enumerated type +\emph{Cudd\_ReorderingType\index{reordering!Cudd\_ReorderingType}} +defined in \emph{cudd.h\index{cudd.h}} (the external +header\index{header files} file of the CUDD package): + +\begin{description} +\item[CUDD\_REORDER\_NONE\index{CUDD\_REORDER\_NONE}:] This method + causes no reordering. +\item[CUDD\_REORDER\_SAME\index{CUDD\_REORDER\_SAME}:] If passed to + \emph{Cudd\_AutodynEnable}\eidx{Cudd\_AutodynEnable}, this + method leaves the current method for automatic reordering unchanged. + If passed to \emph{Cudd\_ReduceHeap}\eidx{Cudd\_ReduceHeap}, + this method causes the current method for automatic reordering to be + used. +\item[CUDD\_REORDER\_RANDOM\index{CUDD\_REORDER\_RANDOM}:] Pairs of + variables are randomly chosen, and swapped in the order. The swap is + performed by a series of swaps of adjacent variables. The best order + among those obtained by the series of swaps is retained. The number + of pairs chosen for swapping\index{reordering!random} equals the + number of variables in the diagram. +\item[CUDD\_REORDER\_RANDOM\_PIVOT\index{CUDD\_REORDER\_RANDOM\_PIVOT}:] + Same as CUDD\_REORDER\_RANDOM, but the two variables are chosen so + that the first is above the variable with the largest number of + nodes, and the second is below that variable. In case there are + several variables tied for the maximum number of nodes, the one + closest to the root is used. +\item[CUDD\_REORDER\_SIFT\index{CUDD\_REORDER\_SIFT}:] This method is + an implementation of Rudell's sifting\index{reordering!sifting} + algorithm \cite{Rudell93}. A simplified description of sifting is as + follows: Each variable is considered in turn. A variable is moved up + and down in the order so that it takes all possible positions. The + best position is identified and the variable is returned to that + position. + + In reality, things are a bit more complicated. For instance, there + is a limit on the number of variables that will be sifted. This + limit can be read with + \emph{Cudd\_ReadSiftMaxVar}\eidx{Cudd\_ReadSiftMaxVar} and set with + \emph{Cudd\_SetSiftMaxVar}\eidx{Cudd\_SetSiftMaxVar}. In addition, + if the diagram grows too much while moving a variable up or down, + that movement is terminated before the variable has reached one end + of the order. The maximum ratio by which the diagram is allowed to + grow while a variable is being sifted can be read with + \emph{Cudd\_ReadMaxGrowth}\eidx{Cudd\_ReadMaxGrowth} and set with + \emph{Cudd\_SetMaxGrowth}\eidx{Cudd\_SetMaxGrowth}. +\item[CUDD\_REORDER\_SIFT\_CONVERGE\index{CUDD\_REORDER\_SIFT\_CONVERGE}:] + This is the converging\index{reordering!converging} variant of + CUDD\-\_REORDER\_SIFT. +\item[CUDD\_REORDER\_SYMM\_SIFT\index{CUDD\_REORDER\_SYMM\_SIFT}:] + This method is an implementation of + symmetric\index{reordering!symmetric} sifting \cite{Panda94}. It is + similar to sifting, with one addition: Variables that become + adjacent during sifting are tested for symmetry\index{symmetry}. If + they are symmetric, they are linked in a group. Sifting then + continues with a group being moved, instead of a single variable. + After symmetric sifting has been run, + \emph{Cudd\_SymmProfile}\eidx{Cudd\_SymmProfile} can be called to + report on the symmetry groups found. (Both positive and negative + symmetries are reported.) +\item[CUDD\_REORDER\_SYMM\_SIFT\_CONV\index{CUDD\_REORDER\_SYMM\_SIFT\_CONV}:] + This is the converging\index{reordering!converging} variant of + CUDD\-\_REORDER\_SYMM\_SIFT. +\item[CUDD\_REORDER\_GROUP\_SIFT\index{CUDD\_REORDER\_GROUP\_SIFT}:] + This method is an implementation of group\index{reordering!group} + sifting \cite{Panda95b}. It is similar to symmetric sifting, but + aggregation\index{aggregation} is not restricted to symmetric + variables. +\item[CUDD\_REORDER\_GROUP\_SIFT\_CONV\index{CUDD\_REORDER\_GROUP\_SIFT\_CONV}:] + This method repeats until convergence the combination of + CUDD\_REORDER\_GROUP\_SIFT and CUDD\-\_REORDER\_WINDOW4. +\item[CUDD\_REORDER\_WINDOW2\index{CUDD\_REORDER\_WINDOW2}:] This + method implements the window\index{reordering!window} permutation + approach of Fujita \cite{Fujita91b} and Ishiura \cite{Ishiur91}. + The size of the window is 2. +\item[CUDD\_REORDER\_WINDOW3\index{CUDD\_REORDER\_WINDOW3}:] Similar + to CUDD\_REORDER\_WINDOW2, but with a window of size 3. +\item[CUDD\_REORDER\_WINDOW4\index{CUDD\_REORDER\_WINDOW4}:] Similar + to CUDD\_REORDER\_WINDOW2, but with a window of size 4. +\item[CUDD\_REORDER\_WINDOW2\_CONV\index{CUDD\_REORDER\_WINDOW2\_CONV}:] + This is the converging\index{reordering!converging} variant of + CUDD\-\_REORDER\_WINDOW2. +\item[CUDD\_REORDER\_WINDOW3\_CONV\index{CUDD\_REORDER\_WINDOW3\_CONV}:] + This is the converging variant of CUDD\-\_REORDER\_WINDOW3. +\item[CUDD\_REORDER\_WINDOW4\_CONV\index{CUDD\_REORDER\_WINDOW4\_CONV}:] + This is the converging variant of CUDD\-\_REORDER\_WINDOW4. +\item[CUDD\_REORDER\_ANNEALING\index{CUDD\_REORDER\_ANNEALING}:] This + method is an implementation of simulated + annealing\index{reordering!simulated annealing} for variable + ordering, vaguely resemblant of the algorithm of \cite{Bollig95}. + This method is potentially very slow. +\item[CUDD\_REORDER\_GENETIC:\index{CUDD\_REORDER\_GENETIC}] This + method is an implementation of a genetic\index{reordering!genetic} + algorithm for variable ordering, inspired by the work of Drechsler + \cite{Drechs95}. This method is potentially very slow. +\item[CUDD\_REORDER\_EXACT\index{CUDD\_REORDER\_EXACT}:] This method + implements a dynamic programming approach to + exact\index{reordering!exact} reordering + \cite{Held62,Friedman90,Ishiur91}, with improvements described in + \cite{Jeong93}. It only stores one BDD at the time. Therefore, it is + relatively efficient in terms of memory. Compared to other + reordering strategies, it is very slow, and is not recommended for + more than 16 variables. +\end{description} +So far we have described methods whereby the package selects an order +automatically. A given order of the variables can also be imposed by +calling \emph{Cudd\_ShuffleHeap}\eidx{Cudd\_ShuffleHeap}. + +\subsection{Grouping Variables} +\index{variable!groups}\label{sec:group} + +CUDD allows the application to specify constraints on the positions of +group of variables. It is possible to request that a group of +contiguous variables be kept contiguous by the reordering procedures. +It is also possible to request that the relative order of some groups +of variables be left unchanged. The constraints on the order are +specified by means of a tree\index{variable!tree}, which is created in +one of two ways: +\begin{itemize} +\item By calling \emph{Cudd\_MakeTreeNode}\eidx{Cudd\_MakeTreeNode}. +\item By calling the functions of the MTR\index{libraries!mtr} library + (part of the distribution), and by registering the result with the + manager using \emph{Cudd\_SetTree}\eidx{Cudd\_SetTree}. The current + tree registered with the manager can be read with + \emph{Cudd\_ReadTree}\eidx{Cudd\_ReadTree}. +\end{itemize} + +Each node in the tree represents a range of variables. The lower bound +of the range is given by the \emph{low} field of the node, and the +size of the group is given by the \emph{size} field of the +node.\footnote{When the variables in a group are reordered, the + association between the \emph{low} field and the index of the first + variable in the group is lost. The package updates the tree to keep + track of the changes. However, the application cannot rely on + \emph{low} to determine the position of variables.} The variables +in each range are kept contiguous. Furthermore, if a node is marked +with the MTR\_FIXED\index{MTR\_FIXED} flag, then the relative order of +the variable ranges associated to its children is not changed. As an +example, suppose the initial variable order is: +\begin{verbatim} + x0, y0, z0, x1, y1, z1, ... , x9, y9, z9. +\end{verbatim} +Suppose we want to keep each group of three variables with the same +index (e.g., \verb|x3, y3, z3|) contiguous, while allowing the package +to change the order of the groups. We can accomplish this with the +following code: +\begin{verbatim} + for (i = 0; i < 10; i++) { + (void) Cudd_MakeTreeNode(manager,i*3,3,MTR_DEFAULT); + } +\end{verbatim} +If we want to keep the order within each group of variables +fixed (i.e., \verb|x| before \verb|y| before \verb|z|) we need to +change MTR\_DEFAULT\index{MTR\_DEFAULT} into MTR\_FIXED. + +The \emph{low} parameter passed to +\emph{Cudd\_MakeTreeNode}\eidx{Cudd\_MakeTreeNode} is the index of a +variable (as opposed to its level or position in the order). The +group tree\index{variable!tree} can be created at any time. The +result obviously depends on the variable order in effect at creation +time. + +It is possible to create a variable group tree also before the +variables themselves are created. The package assumes in this case +that the index of the variables not yet in existence will equal their +position in the order when they are created. Therefore, applications +that rely on +\emph{Cudd\_bddNewVarAtLevel}\eidx{Cudd\_bddNewVarAtLevel} or +\emph{Cudd\_addNewVarAtLevel}\eidx{Cudd\_addNewVarAtLevel} to create +new variables have to create the variables before they group them. + +The reordering procedure will skip all groups whose variables are not +yet in existence. For groups that are only partially in existence, the +reordering procedure will try to reorder the variables already +instantiated, without violating the adjacency constraints. + + +\subsection{Variable Reordering for ZDDs} +\index{reordering!of ZDDs}\label{sec:reordZ} + +Reordering of ZDDs is done in much the same way as the reordering of +BDDs and ADDs. The functions corresponding to \emph{Cudd\_ReduceHeap} +and \emph{Cudd\_ShuffleHeap} are +\emph{Cudd\_zddReduceHeap}\eidx{Cudd\_zddReduceHeap} and +\emph{Cudd\_zddShuffleHeap}\eidx{Cudd\_zddShuffleHeap}. To enable +dynamic\index{reordering!dynamic} reordering, the application must +call \emph{Cudd\_AutodynEnableZdd}\eidx{Cudd\_AutodynEnableZdd}, and +to disable dynamic reordering, it must call +\emph{Cudd\_AutodynDisableZdd}\eidx{Cudd\_AutodynDisableZdd}. In the +current implementation, however, the choice of reordering methods for +ZDDs is more limited. Specifically, these methods are available: + +\begin{description} +\item[CUDD\_REORDER\_NONE\index{CUDD\_REORDER\_NONE};] +\item[CUDD\_REORDER\_SAME\index{CUDD\_REORDER\_SAME};] +\item[CUDD\_REORDER\_RANDOM\index{CUDD\_REORDER\_RANDOM};] +\item[CUDD\_REORDER\_RANDOM\_PIVOT\index{CUDD\_REORDER\_RANDOM\_PIVOT};] +\item[CUDD\_REORDER\_SIFT\index{CUDD\_REORDER\_SIFT};] +\item[CUDD\_REORDER\_SIFT\_CONVERGE\index{CUDD\_REORDER\_SIFT\_CONVERGE};] +\item[CUDD\_REORDER\_SYMM\_SIFT\index{CUDD\_REORDER\_SYMM\_SIFT};] +\item[CUDD\_REORDER\_SYMM\_SIFT\_CONV\index{CUDD\_REORDER\_SYMM\_SIFT\_CONV}.] +\end{description} + +To create ZDD variable groups, the application calls +\emph{Cudd\_MakeZddTreeNode}\eidx{Cudd\_MakeZddTreeNode}. + +\subsection{Keeping Consistent Variable Orders for BDDs and ZDDs} +\label{sec:consist} + +Several applications that manipulate both BDDs and ZDDs benefit from +keeping a fixed correspondence between the order of the BDD variables +and the order of the ZDD variables. If each BDD variable corresponds +to a group of ZDD variables, then it is often desirable that the +groups of ZDD variables be in the same order as the corresponding BDD +variables. CUDD allows the ZDD order to track the BDD order and vice +versa. To have the ZDD order track the BDD order, the application +calls \emph{Cudd\_zddRealignEnable}\eidx{Cudd\_zddRealignEnable}. The +effect of this call can be reversed by calling +\emph{Cudd\_zddRealignDisable}\eidx{Cudd\_zddRealignDisable}. When +ZDD realignment is in effect, automatic reordering of ZDDs should be +disabled. + +\subsection{Hooks} +\index{hook}\label{sec:hooks} + +Hooks in CUDD are lists of application-specified functions to be run on +certain occasions. Each hook is identified by a constant of the +enumerated type \emph{Cudd\_HookType}\eidx{Cudd\_HookType}. In Version +\vnumber\ hooks are defined for these occasions: +\begin{itemize} +\item before garbage collection (CUDD\_PRE\_GC\_HOOK); +\item after garbage collection (CUDD\_POST\_GC\_HOOK); +\item before variable reordering (CUDD\_PRE\_REORDERING\_HOOK); +\item after variable reordering (CUDD\_POST\_REORDERING\_HOOK). +\end{itemize} +A function added to a hook receives a pointer to the manager, a +pointer to a constant string, and a pointer to void as arguments; it +must return 1 if successful; 0 otherwise. The second argument is one +of ``DD,'' ``BDD,'' and ``ZDD.'' This allows the hook functions to +tell the type of diagram for which reordering or garbage collection +takes place. The third argument varies depending on the hook. The hook +functions called before or after garbage collection\index{garbage + collection!hooks} do not use it. The hook functions called before +reordering\index{reordering!hooks} are passed, in addition to the +pointer to the manager, also the method used for reordering. The hook +functions called after reordering are passed the start time. To add a +function to a hook, one uses \emph{Cudd\_AddHook}\eidx{Cudd\_AddHook}. +The function of a given hook are called in the order in which they +were added to the hook. For sample hook functions, one may look at +\emph{Cudd\_StdPreReordHook}\eidx{Cudd\_StdPreReordHook} and +\emph{Cudd\_StdPostReordHook}\eidx{Cudd\_StdPostReordHook}. + +\subsection{Timeouts and Limits} +\index{timeout}\label{sec:timeouts} + +It is possible to set a time limit for a manager with +\emph{Cudd\_SetTimeLimit}\eidx{Cudd\_SetTimeLimit}. Once set, the +time available to the manager can be inspected and modified through +other API functions. +(\emph{Cudd\_TimeLimited}\eidx{Cudd\_TimeLimited}, +\emph{Cudd\_ReadTimeLimit}\eidx{Cudd\_ReadTimeLimit}, +\emph{Cudd\_UnsetTimeLimit}\eidx{Cudd\_UnsetTimeLimit}, +\emph{Cudd\_UpdateTimeLimit}\eidx{Cudd\_UpdateTimeLimit}, +\emph{Cudd\_IncreaseTimeLimit}\eidx{Cudd\_IncreaseTimeLimit}.) CUDD +checks for expiration from time to time. When deadline has +expired, it returns NULL from the call in progress, but it leaves the +manager in a consistent state. The invoking application must be +designed to handle the NULL values returned. + +When reordering, if a timout is approaching, CUDD will quit reordering +to give the application a chance to finish some computation. + +It is also possible to invoke some functions that return NULL if they +cannot complete without creating more than a set number of nodes. +See, for instance, \emph{Cudd\_bddAndLimit}\eidx{Cudd\_bddAndLimit}. +Only functions that are documented to check for the number of +generated nodes do so. (Their names end in ``limit.'') These +functions set the error code to +\emph{CUDD\_TOO\_MANY\_NODES}\eidx{CUDD\_TOO\_MANY\_NODES} when they +return NULL because of too many nodes. The error code can be +inspected with \emph{Cudd\_ReadErrorCode}\eidx{Cudd\_ReadErrorCode} +and cleared with +\emph{Cudd\_ClearErrorCode}\eidx{Cudd\_ClearErrorCode}. + +\subsection{Writing Decision Diagrams to a File} +\label{sec:dump} + +The CUDD package provides several functions to write decision diagrams +to a file. \emph{Cudd\_DumpBlif}\eidx{Cudd\_DumpBlif} writes a +file in \emph{blif} format. It is restricted to BDDs. The diagrams +are written as a network of multiplexers, one multiplexer for each +internal node of the BDD. + +\emph{Cudd\_DumpDot}\eidx{Cudd\_DumpDot} produces input suitable to +the graph-drawing\index{graph!drawing} program +\href{http://www.graphviz.org}{\emph{dot}} written by Eleftherios +Koutsofios and Stephen C. North. An example of drawing produced by +dot from the output of \emph{Cudd\_DumpDot} is shown in +Figure~\ref{fi:phase}. \emph{Cudd\_DumpDot} is restricted to BDDs and +ADDs; \emph{Cudd\_zddDumpDot} may be used to draw ZDDs. +\begin{figure} + \centerline{\includegraphics[height=15.5cm]{@top_srcdir@/doc/phase.pdf}} +\caption{A BDD representing a phase constraint for the optimization of + fixed-polarity Reed-Muller forms. The label of each node is the + unique part of the node address. All nodes on the same level + correspond to the same variable, whose name is shown at the left of + the diagram. Dotted lines indicate complement\index{arc!complement} + arcs. Dashed lines indicate regular\index{arc!regular} ``else'' + arcs.\label{fi:phase}} +\end{figure} +\emph{Cudd\_zddDumpDot}\eidx{Cudd\_zddDumpDot} is the analog of +\emph{Cudd\_DumpDot} for ZDDs. + +\emph{Cudd\_DumpDaVinci}\eidx{Cudd\_DumpDaVinci} produces input +suitable to the graph-drawing\index{graph!drawing} program +\href{ftp://ftp.uni-bremen.de/pub/graphics/daVinci}{\emph{daVinci}} +developed at the University of Bremen. It is restricted to BDDs and +ADDs. + +Functions are also available to produce the input format of +\emph{DDcal} (see Section~\ref{sec:getFriends}) and factored forms. + + +\subsection{Saving and Restoring BDDs} +\label{sec:save-restore} + +The \href{ftp://ftp.polito.it/pub/research/dddmp/}{\emph{dddmp}} +library\index{libraries!dddmp} by Gianpiero Cabodi and Stefano Quer +allows a CUDD application to save BDDs to disk in compact form for +later retrieval. See the library's own documentation for the details. + +%---------------------------------------- +\section{Programmer's Manual} +\label{sec:prog} + +This section provides additional detail on the workings of the CUDD +package and on the programming conventions followed in its writing. +The additional detail should help those who want to write procedures +that directly manipulate the CUDD data structures. + +\subsection{Compiling and Linking} +\index{compiling}\label{sec:compileInt} + +If you plan to use the CUDD package as a clear box\index{box!clear} +(for instance, you want to write a procedure that traverses a decision +diagram) you need to add +\begin{verbatim} +#include "cuddInt.h" +\end{verbatim} +to your source files. In addition, you should link \verb|libcudd.a| to +your executable. Some platforms require specific compiler and linker +flags. Refer to the \texttt{Makefile} in the top level directory of +the distribution. + +\subsection{Reference Counts} +\index{node!reference count}\label{sec:ref} + +Garbage\index{garbage collection} collection in the CUDD package is +based on reference counts. Each node stores the sum of the external +references and internal references. An internal BDD or ADD node is +created by a call to \emph{cuddUniqueInter}\eidx{cuddUniqueInter}, an +internal ZDD node is created by a call to +\emph{cuddUniqueInterZdd}\eidx{cuddUniqueInterZdd}, and a +terminal\index{node!constant} node is created by a call to +\emph{cuddUniqueConst}\eidx{cuddUniqueConst}. If the node returned by +these functions is new, its reference count is zero. The function +that calls \emph{cuddUniqueInter}\eidx{cuddUniqueInter}, +\emph{cuddUniqueInterZdd}\eidx{cuddUniqueInterZdd}, or +\emph{cuddUniqueConst}\eidx{cuddUniqueConst} is responsible for +increasing the reference count of the node. This is accomplished by +calling \emph{Cudd\_Ref}\eidx{Cudd\_Ref}. + +When a function is no longer needed by an application, the memory used +by its diagram can be recycled by calling +\emph{Cudd\_RecursiveDeref}\eidx{Cudd\_RecursiveDeref} (BDDs and ADDs) +or \emph{Cudd\_RecursiveDerefZdd}\eidx{Cudd\_RecursiveDerefZdd} +(ZDDs). These functions decrease the reference \index{node!reference + count} count of the node passed to them. If the reference count +becomes 0, then two things happen: +\begin{enumerate} +\item The node is declared ``dead\index{node!dead};'' this entails + increasing the counters\index{statistical counters} of the dead + nodes. (One counter for the subtable\index{subtable} to which the + node belongs, and one global counter for the + unique\index{table!unique} table to which the node belongs.) The + node itself is not affected. +\item The function is recursively called on the two children of the + node. +\end{enumerate} +For instance, if the diagram of a function does not share any nodes +with other diagrams, then calling +\emph{Cudd\_RecursiveDeref}\eidx{Cudd\_RecursiveDeref} or +\emph{Cudd\_RecursiveDerefZdd}\eidx{Cudd\_RecursiveDerefZdd} on its +root will cause all the nodes of the diagram to become dead. + +When the number of dead nodes reaches a given level (dynamically +determined by the package) garbage collection takes place. During +garbage\index{garbage collection} collection dead nodes are returned +to the node free list\index{free list}. + +When a new node is created, it is important to increase its +reference\index{node!reference count} count before one of the two +following events occurs: +\begin{enumerate} +\item A call to \emph{cuddUniqueInter}\eidx{cuddUniqueInter}, + to \emph{cuddUniqueInterZdd}\eidx{cuddUniqueInterZdd}, to + \emph{cuddUniqueConst}\eidx{cuddUniqueConst}, or to a + function that may eventually cause a call to them. +\item A call to + \emph{Cudd\_RecursiveDeref}\eidx{Cudd\_RecursiveDeref}, to + \emph{Cudd\_RecursiveDerefZdd}\eidx{Cudd\_RecursiveDerefZdd}, or to + a function that may eventually cause a call to them. +\end{enumerate} +In practice, it is recommended to increase the reference count as soon +as the returned pointer has been tested for not being NULL. + +\subsubsection{NULL Return Values} +\label{sec:null} + +The interface to the memory management functions (e.g., malloc) used +by CUDD intercepts NULL return values and calls a handler. The +default handler exits with an error message. If the application does +not install another handler, therefore, a NULL return value from an +exported function of CUDD signals an internal error. + +If the aplication, however, installs another handler that lets +execution continue, a NULL pointer returned by an exported function +typically indicates that the process has run out of memory. +\emph{Cudd\_ReadErrorCode}\eidx{Cudd\_ReadErrorCode} can be used to +ascertain the nature of the problem. + +An application that tests for the result being NULL can try some +remedial action, if it runs out of memory. For instance, it may free +some memory that is not strictly necessary, or try a slower algorithm +that takes less space. As an example, CUDD overrides the default +handler when trying to enlarge the cache or increase the number of +slots of the unique table. If the allocation fails, the package prints +out a message and continues without resizing the cache. + +\subsubsection{\emph{Cudd\_RecursiveDeref} vs.\ \emph{Cudd\_Deref}} +\label{sec:deref} + +It is often the case that a recursive procedure has to protect the +result it is going to return, while it disposes of intermediate +results. (See the previous discussion on when to increase reference +counts.) Once the intermediate results have been properly disposed +of, the final result must be returned to its pristine state, in which +the root node may have a reference count of 0. One cannot use +\emph{Cudd\_RecursiveDeref}\eidx{Cudd\_RecursiveDeref} (or +\emph{Cudd\_RecursiveDerefZdd}) for this purpose, because it may +erroneously make some nodes dead. Therefore, the package provides a +different function: \emph{Cudd\_Deref}\eidx{Cudd\_Deref}. This +function is not recursive, and does not change the dead node counts. +Its use is almost exclusively the one just described: Decreasing the +reference count of the root of the final result before returning from +a recursive procedure. + +\subsubsection{When Increasing the Reference Count is Unnecessary} +\index{node!reference count}\label{sec:noref} + +When a copy of a predefined constant\index{node!constant} or of a +simple BDD variable is needed for comparison purposes, then calling +\emph{Cudd\_Ref}\eidx{Cudd\_Ref} is not necessary, because these +simple functions are guaranteed to have reference counts greater than +0 at all times. If no call to \emph{Cudd\_Ref} is made, then no +attempt to free the diagram by calling +\emph{Cudd\_RecursiveDeref}\eidx{Cudd\_RecursiveDeref} or +\emph{Cudd\_RecursiveDerefZdd}\eidx{Cudd\_RecursiveDerefZdd} should be +made. + +\subsubsection{Saturating Increments and Decrements} +\index{saturating!increments}\index{saturating!decrements}\label{sec:satur} + +On 32-bit machines, the CUDD package stores the +reference\index{node!reference count} counts in unsigned short int's. +For large diagrams, it is possible for some reference counts to exceed +the capacity of an unsigned short int. Therefore, increments and +decrements of reference counts are \emph{saturating}. This means that +once a reference count has reached the maximum possible value, it is +no longer changed by calls to \emph{Cudd\_Ref}, +\emph{Cudd\_RecursiveDeref}\eidx{Cudd\_RecursiveDeref}, +\emph{Cudd\_RecursiveDerefZdd}\eidx{Cudd\_RecursiveDerefZdd}, or +\emph{Cudd\_Deref}\eidx{Cudd\_Deref}. As a consequence, some nodes +that have no references may not be declared dead. This may result in a +small waste of memory, which is normally more than offset by the +reduction in size of the node structure. + +When using 64-bit pointers, there is normally no memory advantage from +using short int's instead of int's in a DdNode. Therefore, increments +and decrements are not saturating in that case. What option is in +effect depends on two macros, SIZEOF\_VOID\_P\index{SIZEOF\_VOID\_P} +and SIZEOF\_INT\index{SIZEOF\_INT}, defined in the configuration +header\index{header files} file (\emph{config.h}\index{config.h}). +The increments and decrements of the reference counts are performed +using two macros: \emph{cuddSatInc}\eidx{cuddSatInc} and +\emph{cuddSatDec}\eidx{cuddSatDec}, whose definitions depend on +SIZEOF\_VOID\_P\index{SIZEOF\_VOID\_P} and +SIZEOF\_INT\index{SIZEOF\_INT}. + +\subsection{Complement Arcs} +\index{arc!complement}\label{sec:compl} + +If ADDs are restricted to use only the constants 0 and 1, they behave +like BDDs without complement arcs. It is normally easier to write code +that manipulates 0-1 ADDs, than to write code for BDDs. However, +complementation is trivial with complement arcs, and is not trivial +without. As a consequence, with complement arcs it is possible to +check for more terminal cases and it is possible to apply De Morgan's +laws to reduce problems that are essentially identical to a standard +form. This in turn increases the utilization of the cache\index{cache}. + +The complement attribute is stored in the least significant bit of the +``else'' pointer of each node. An external pointer to a function can +also be complemented. The ``then'' pointer to a node, on the other +hand, is always \emph{regular\index{arc!regular}}. It is a mistake to +use a complement\index{arc!complement} pointer as it is to address +memory. Instead, it is always necessary to obtain a regular version +of it. This is normally done by calling +\emph{Cudd\_Regular}\eidx{Cudd\_Regular}. It is also a mistake to +call \emph{cuddUniqueInter}\eidx{cuddUniqueInter} with a complemented +``then'' child as argument. The calling procedure must apply De +Morgan's laws by complementing both pointers passed to +\emph{cuddUniqueInter}\eidx{cuddUniqueInter} and then taking the +complement of the result. + +\subsection{The Cache} +\index{cache}\label{sec:cache} + +Each entry of the cache consists of five fields: The operator, three +pointers to operands and a pointer to the result. The operator and the +three pointers to the operands are combined to form three words. The +combination relies on two facts: +\begin{itemize} +\item Most operations have one or two operands. A few bits are + sufficient to discriminate all three-operands operations. +\item All nodes are aligned to 16-byte boundaries. (32-byte boundaries + if 64-bit pointers are used.) Hence, there are a few bits available + to distinguish the three-operand operations from te others and to + assign unique codes to them. +\end{itemize} + +The cache does not contribute to the reference +\index{node!reference count} +counts of the nodes. The fact that the cache contains a +pointer to a node does not imply that the node is alive. Instead, when +garbage\index{garbage collection} collection takes place, all entries +of the cache pointing to dead\index{node!dead} nodes are cleared. + +The cache is also cleared (of all entries) when dynamic +reordering\index{reordering} takes place. In both cases, the entries +removed from the cache are about to become invalid. + +All operands and results in a cache entry must be pointers to +DdNodes\index{DdNode}. If a function produces more than one result, +or uses more than three arguments, there are currently two solutions: +\begin{itemize} +\item Build a separate, local, cache\index{cache!local}. (Using, for + instance, the \emph{st} library\index{libraries!st}.) +\item Combine multiple results, or multiple operands, into a single + diagram, by building a ``multiplexing structure'' with reserved + variables. +\end{itemize} +Support of the former solution is under development. (See +\texttt{cuddLCache.c}..) Support for the latter solution may be +provided in future versions of the package. + +There are three sets of interface\index{interface!cache} functions to +the cache. The first set is for functions with three operands: +\emph{cuddCacheInsert}\eidx{cuddCacheInsert} and +\emph{cuddCacheLookup}\eidx{cuddCacheLookup}. The second set is for +functions with two operands: +\emph{cuddCacheInsert2}\eidx{cuddCacheInsert2} and +\emph{cuddCacheLookup2}\eidx{cuddCacheLookup2}. The second set is for +functions with one operand: +\emph{cuddCacheInsert1}\eidx{cuddCacheInsert1} and +\emph{cuddCacheLookup1}\eidx{cuddCacheLookup1}. The second set is +slightly faster than the first, and the third set is slightly faster +than the second. + +\subsubsection{Cache Sizing} +\index{cache!sizing}\label{sec:cache-sizing} + +The size of the cache can increase during the execution of an +application. (There is currently no way to decrease the size of the +cache, though it would not be difficult to do it.) When a cache miss +occurs, the package uses the following criteria to decide whether to +resize the cache: +\begin{enumerate} +\item If the cache already exceeds the limit given by the + \texttt{maxCache\index{maxCache}} field of the manager, no resizing + takes place. The limit is the minimum of two values: a value set at + initialization time and possibly modified by the application, which + constitutes the hard limit beyond which the cache will never grow; + and a number that depends on the current total number of slots in + the unique\index{table!unique} table. +\item If the cache is not too large already, resizing is decided based + on the hit rate. The policy adopted by the CUDD package is + ``reward-based\index{cache!reward-based resizing}.'' If the cache hit + rate is high, then it is worthwhile to increase the size of the + cache. +\end{enumerate} +When resizing takes place, the statistical counters \index{statistical + counters} used to compute the hit rate are reinitialized so as to +prevent immediate resizing. The number of entries is doubled. + +The rationale for the ``reward-based\index{cache!reward-based resizing}'' +policy is as follows. In many BDD/ADD applications the hit rate is +not very sensitive to the size of the cache: It is primarily a +function of the problem instance at hand. If a large hit rate is +observed, chances are that by using a large cache, the results of +large problems (those that would take longer to solve) will survive in +the cache without being overwritten long enough to cause a valuable +cache hit. Notice that when a large problem is solved more than once, +so are its recursively generated subproblems. If the hit rate is +low, the probability of large problems being solved more than once is +low. + +The other observation about the cache sizing policy is that there is +little point in keeping a cache which is much larger than the unique +table. Every time the unique table ``fills up,'' garbage collection is +invoked and the cache is cleared of all dead entries. A cache that is +much larger than the unique\index{table!unique} table is therefore +less than fully utilized. + +\subsubsection{Local Caches} +\index{cache!local}\label{sec:local-caches} + +Sometimes it may be necessary or convenient to use a local cache. A +local cache can be lossless\index{cache!lossless} (no results are ever +overwritten), or it may store objects for which +canonical\index{canonical} representations are not available. One +important fact to keep in mind when using a local cache is that local +caches are not cleared during garbage\index{garbage collection} +collection or before reordering. Therefore, it is necessary to +increment the reference\index{node!reference count} count of all nodes +pointed by a local cache. (Unless their reference counts are +guaranteed positive in some other way. One such way is by including +all partial results in the global result.) Before disposing of the +local cache, all elements stored in it must be passed to +\emph{Cudd\_RecursiveDeref}\eidx{Cudd\_RecursiveDeref}. As consequence +of the fact that all results in a local cache are referenced, it is +generally convenient to store in the local cache also the result of +trivial problems, which are not usually stored in the global cache. +Otherwise, after a recursive call, it is difficult to tell whether the +result is in the cache, and therefore referenced, or not in the cache, +and therefore not referenced. + +An alternative approach to referencing the results in the local caches +is to install hook functions (see Section~\ref{sec:hooks}) to be +executed before garbage collection. + +\subsection{The Unique Table} +\index{table!unique}\label{sec:unique} + +A recursive procedure typically splits the operands by expanding with +respect to the topmost variable. Topmost in this context refers to the +variable that is closest to the roots in the current variable order. +The nodes, on the other hand, hold the index, which is invariant with +reordering. Therefore, when splitting, one must use the +permutation\index{variable!permutation} array maintained by the +package to get the right level. Access to the permutation array is +provided by the macro \emph{cuddI}\eidx{cuddI} for BDDs and ADDs, +and by the macro \emph{cuddIZ}\eidx{cuddIZ} for ZDDs. + +The unique table consists of as many hash\index{table!hash} tables as +there are variables in use. These has tables are called \emph{unique + subtables}. The sizes of the unique subtables are determined by two +criteria: +\begin{enumerate} +\item The collision\index{cache!collision list} lists should be short + to keep access time down. +\item There should be enough room for dead\index{node!dead} nodes, to + prevent too frequent garbage\index{garbage collection} collections. +\end{enumerate} +While the first criterion is fairly straightforward to implement, the +second leaves more room to creativity. The CUDD package tries to +figure out whether more dead node should be allowed to increase +performance. (See also Section~\ref{sec:params}.) There are two +reasons for not doing garbage collection too often. The obvious one is +that it is expensive. The second is that dead nodes may be +reclaimed\index{node!reclaimed}, if they are the result of a +successful cache lookup. Hence dead nodes may provide a substantial +speed-up if they are kept around long enough. The usefulness of +keeping many dead nodes around varies from application to application, +and from problem instance to problem instance. As in the sizing of the +cache, the CUDD package adopts a +``reward-based\index{table!unique!reward-based resizing}'' policy to +decide how much room should be used for the unique table. If the +number of dead nodes reclaimed is large compared to the number of +nodes directly requested from the memory manager, then the CUDD +package assumes that it will be beneficial to allow more room for the +subtables, thereby reducing the frequency of garbage collection. The +package does so by switching between two modes of operation: +\begin{enumerate} +\item Fast growth\index{table!unique!fast growth}: In this mode, the + ratio of dead nodes to total nodes required for garbage collection + is higher than in the slow growth mode to favor resizing + of the subtables. +\item Slow growth\index{table!unique!slow growth}: In this + mode keeping many dead nodes around is not as important as + keeping memory requirements low. +\end{enumerate} +Switching from one mode to the other is based on the following +criteria: +\begin{enumerate} +\item If the unique table is already large, only slow growth is + possible. +\item If the table is small and many dead nodes are being reclaimed, + then fast growth is selected. +\end{enumerate} +This policy is especially effective when the diagrams being +manipulated have lots of recombination. Notice the interplay of the +cache sizing and unique sizing: Fast growth normally occurs when the +cache hit rate is large. The cache and the unique table then grow in +concert, preserving a healthy balance between their sizes. + +\subsection{Allowing Asynchronous Reordering} +\index{reordering!asynchronous}\label{sec:async} + +Asynchronous reordering is the reordering that is triggered +automatically by the increase of the number of nodes. Asynchronous +reordering takes place when a new internal node must be created, and +the number of nodes has reached a given +threshold\index{reordering!threshold}. (The threshold is adjusted by +the package every time reordering takes place.) + +Those procedures that do not create new nodes (e.g., procedures that +count the number of nodes or minterms\index{function!minterms}) need +not worry about asynchronous reordering: No special precaution is +necessary in writing them. + +Procedures that only manipulate decision diagrams through the exported +functions of the CUDD package also need not concern themselves with +asynchronous reordering. (See Section~\ref{sec:nodes} for the +exceptions.) + +The remaining class of procedures is composed of functions that visit +the diagrams and may create new nodes. All such procedures in the CUDD +package are written so that they can be interrupted by dynamic +reordering. The general approach followed goes under the name of +``abort and retry\index{reordering!abort and retry}.'' As the name +implies, a computation that is interrupted by dynamic reordering is +aborted and tried again. + +A recursive procedure that can be interrupted by dynamic reordering +(an interruptible\index{reordering!interruptible procedure} procedure +from now on) is composed of two functions. One is responsible for the +real computation. The other is a simple +wrapper\index{reordering!function wrapper}, which tests whether +reordering occurred and restarts the computation if it did. + +Asynchronous reordering of BDDs and ADDs can only be triggered inside +\emph{cuddUniqueInter}\eidx{cuddUniqueInter}, when a new node is about +to be created. Likewise, asynchronous reordering of ZDDs can only be +triggered inside \emph{cuddUniqueInterZdd}\eidx{cuddUniqueInterZdd}. +When reordering is triggered, three things happen: +\begin{enumerate} +\item \emph{cuddUniqueInter}\eidx{cuddUniqueInter} returns a NULL + value; +\item The flag \emph{reordered} of the manager is set to 1. (0 means + no reordering, while 2 indicates an error occurred during + reordering.) +\item The counter \emph{reorderings} of the manager is incremented. + The counter is initialized to 0 when the manager is started and can + be accessed by calling + \emph{Cudd\_ReadReorderings}\eidx{Cudd\_ReadReorderings}. By taking + two readings of the counter, an application can determine if + variable reordering has taken place between the first and the second + reading. The package itself, however, does not make use of the + counter: It is mentioned here for completeness. +\end{enumerate} + +The recursive procedure that receives a NULL value from +\emph{cuddUniqueInter}\eidx{cuddUniqueInter} must free all +intermediate results that it may have computed before, and return NULL +in its turn. + +The wrapper\index{reordering!function wrapper} function does not +decide whether reordering occurred based on the NULL return value, +because the NULL value may be the result of lack of memory. Instead, +it checks the \emph{reordered} flag. + +When a recursive procedure calls another recursive procedure that may +cause reordering, it should bypass the wrapper and call the recursive +procedure directly. Otherwise, the calling procedure will not know +whether reordering occurred, and will not be able to restart. This is +the main reason why most recursive procedures are internal, rather +than static. (The wrappers, on the other hand, are mostly exported.) + +\subsection{Debugging} +\index{debugging}\label{sec:debug} + +By defining the symbol DD\_DEBUG\index{DD\_DEBUG} during compilation, +numerous checks are added to the code. In addition, the procedures +\emph{Cudd\_DebugCheck}\eidx{Cudd\_DebugCheck}, +\emph{Cudd\_CheckKeys}\eidx{Cudd\_CheckKeys}, and +\emph{cuddHeapProfile}\eidx{cuddHeapProfile} can be called at any +point to verify the consistency of the data structure. +(\emph{cuddHeapProfile} is an internal procedure. It is declared in +\emph{cuddInt.h}\index{cuddInt.h}.) Procedures +\emph{Cudd\_DebugCheck} and \emph{Cudd\_CheckKeys} are especially +useful when CUDD reports that during garbage collection the number of +nodes actually deleted from the unique table is different from the +count of dead nodes kept by the manager. The error causing the +discrepancy may have occurred much earlier than it is discovered. A +few strategicaly placed calls to the debugging procedures can +considerably narrow down the search for the source of the problem. +(For instance, a call to \emph{Cudd\_RecursiveDeref} where one to +\emph{Cudd\_Deref} was required may be identified in this way.) + +One of the most common problems encountered in debugging code based on +the CUDD package is a missing call to +\emph{Cudd\_RecursiveDeref}\eidx{Cudd\_RecursiveDeref}. To help +identify this type of problems, the package provides a function called +\emph{Cudd\_CheckZeroRef}\eidx{Cudd\_CheckZeroRef}. This function +should be called immediately before shutting down the manager. +\emph{Cudd\_CheckZeroRef} checks that the only nodes left with +non-zero reference\index{node!reference count} counts are the +predefined constants, the BDD projection\index{projection functions} +functions, and nodes whose reference counts are +saturated\index{node!reference count!saturated}. + +For this function to be effective the application must explicitly +dispose of all diagrams to which it has pointers before calling it. + +\subsection{Gathering and Interpreting Statistics} +\index{statistics}\label{sec:stats} + +Function \emph{Cudd\_PrintInfo}\eidx{Cudd\_PrintInfo} can be called to +print out the values of parameters and statistics for a manager. The +output of \emph{Cudd\_PrintInfo} is divided in two sections. The +first reports the values of parameters that are under the application +control. The second reports the values of statistical counters and +other non-modifiable parameters. A quick guide to the interpretation +of all these quantities follows. For ease of exposition, we reverse +the order and describe the non-modifiable parameters first. We'll use +a sample run as example. There is nothing special about this run. + +\subsubsection{Non Modifiable Parameters} +\label{sec:nonModPar} + +The list of non-modifiable parameters starts with: +\begin{verbatim} + **** CUDD non-modifiable parameters **** + Memory in use: 32544220 +\end{verbatim} +This is the memory used by CUDD for three things mainly: Unique table +(including all DD nodes in use), node free list, and computed table. +This number almost never decreases in the lifetime of a CUDD manager, +because CUDD does not release memory when it frees nodes. Rather, it +puts the nodes on its own free list. This number is in bytes. It does +not represent the peak memory occupation, because it does not include +the size of data structures created temporarily by some functions (e.g., +local look-up tables). + +\begin{verbatim} + Peak number of nodes: 837018 +\end{verbatim} +This number is the number of nodes that the manager has allocated. +This is not the largest size of the BDDs, because the manager will +normally have some dead nodes and some nodes on the free list. + +\begin{verbatim} + Peak number of live nodes: 836894 +\end{verbatim} +This is the largest number of live nodes that the manager has held +since its creation. + +\begin{verbatim} + Number of BDD variables: 198 + Number of ZDD variables: 0 +\end{verbatim} +These numbers tell us this run was not using ZDDs. + +\begin{verbatim} + Number of cache entries: 1048576 +\end{verbatim} +Current number of slots of the computed table. If one has a +performance problem, this is one of the numbers to look at. The cache +size is always a power of 2. + +\begin{verbatim} + Number of cache look-ups: 2996536 + Number of cache hits: 1187087 +\end{verbatim} +These numbers give an indication of the hit rate in the computed +table. It is not unlikely for model checking runs to get +hit rates even higher than this one (39.62\%). + +\begin{verbatim} + Number of cache insertions: 1809473 + Number of cache collisions: 961208 + Number of cache deletions: 0 +\end{verbatim} +A collision\index{cache!collision} occurs when a cache entry is +overwritten. A deletion\index{cache!deletion} +occurs when a cache entry is invalidated (e.g., during garbage +collection). If the number of deletions is high compared to the +number of collisions, it means that garbage collection occurs too +often. In this case there were no garbage collections; hence, no +deletions. + +\begin{verbatim} + Cache used slots = 80.90% (expected 82.19%) +\end{verbatim} +Percentage of cache slots that contain a valid entry. If this +number is small, it may signal one of three conditions: +\begin{enumerate} +\item The cache may have been recently resized and it is still filling + up. +\item The cache is too large for the BDDs. This should not happen if + the size of the cache is determined by CUDD. +\item The hash function is not working properly. This is accompanied + by a degradation in performance. Conversely, a degradation in + performance may be due to bad hash function behavior. +\end{enumerate} +The expected value is computed assuming a uniformly random +distribution of the accesses. If the difference between the measured +value and the expected value is large (unlike this case), the cache is +not working properly. + +\begin{verbatim} + Soft limit for cache size: 1318912 +\end{verbatim} +This number says how large the cache can grow. This limit is based on +the size of the unique table. CUDD uses a reward-based policy for +growing the cache. (See Section~\ref{sec:cache-sizing}.) The default +hit rate for resizing is 30\% and the value in effect is reported +among the modifiable parameters. + +\begin{verbatim} + Number of buckets in unique table: 329728 +\end{verbatim} +This number is exactly one quarter of the one above. This is indeed +how the soft limit is determined currently, unless the computed table +hits the specified hard limit. (See below.) + +\begin{verbatim} + Used buckets in unique table: 87.96% (expected 87.93%) +\end{verbatim} +Percentage of unique table buckets that contain at least one +node. Remarks analogous to those made about the used cache slots apply. + +\begin{verbatim} + Number of BDD and ADD nodes: 836894 + Number of ZDD nodes: 0 +\end{verbatim} +How many nodes are currently in the unique table, either alive or dead. + +\begin{verbatim} + Number of dead BDD and ADD nodes: 0 + Number of dead ZDD nodes: 0 +\end{verbatim} +Subtract these numbers from those above to get the number of live +nodes. In this case there are no dead nodes because the application +uses delayed dereferencing +\emph{Cudd\_DelayedDerefBdd}\eidx{Cudd\_DelayedDerefBdd}. + +\begin{verbatim} + Total number of nodes allocated: 836894 +\end{verbatim} +This is the total number of nodes that were requested and obtained +from the free list. It never decreases, and is not an indication of +memory occupation after the first garbage collection. Rather, it is a +measure of the package activity. + +\begin{verbatim} + Total number of nodes reclaimed: 0 +\end{verbatim} +These are the nodes that were resuscitated from the dead. If they are +many more than the allocated nodes, and the total +number of slots is low relative to the number of nodes, then one may +want to increase the limit for fast unique table growth. In this case, +the number is 0 because of delayed dereferencing. + +\begin{verbatim} + Garbage collections so far: 0 + Time for garbage collections: 0.00 sec + Reorderings so far: 0 + Time for reordering: 0.00 sec +\end{verbatim} +There is a GC for each reordering. Hence the first count will always be +at least as large as the second. + +\begin{verbatim} + Node swaps in reordering: 0 +\end{verbatim} +This is the number of elementary reordering steps. Each step consists +of the re-expression of one node while swapping two adjacent +variables. This number is a good measure of the amount of work done in +reordering. + +\subsubsection{Modifiable Parameters} +\label{sec:modPar} + +Let us now consider the modifiable parameters, that is, those settings on +which the application or the user has control. + +\begin{verbatim} + **** CUDD modifiable parameters **** + Hard limit for cache size: 8388608 +\end{verbatim} +This number counts entries. Each entry is 16 bytes if CUDD is compiled +to use 32-bit pointers. Two important observations are in order: +\begin{enumerate} +\item If the datasize limit is set, CUDD will use it to determine this + number automatically. On a Unix system, one can type ``limit'' or + ``ulimit'' to verify if this value is set. If the datasize limit is + not set, CUDD uses a default which is rather small. If you have + enough memory (say 64MB or more) you should seriously consider + \emph{not} using the default. So, either set the datasize limit, or + override the default with + \emph{Cudd\_SetMaxCacheHard}\eidx{Cudd\_SetMaxCacheHard}. +\item If a process seems to be going nowhere, a small value for + this parameter may be the culprit. One cannot overemphasize the + importance of the computed table in BDD algorithms. +\end{enumerate} +In this case the limit was automatically set for a target maximum +memory occupation of 104 MB. + +\begin{verbatim} + Cache hit threshold for resizing: 15% +\end{verbatim} +This number can be changed if one suspects performance is hindered by +the small size of the cache, and the cache is not growing towards the +soft limit sufficiently fast. In such a case one can change the +default 30\% to 15\% (as in this case) or even 1\%. + +\begin{verbatim} + Garbage collection enabled: yes +\end{verbatim} +One can disable it, but there are few good reasons for doing +so. It is normally preferable to raise the limit for fast unique table +growth. (See below.) + +\begin{verbatim} + Limit for fast unique table growth: 1363148 +\end{verbatim} +See Section~\ref{sec:unique} and the comments above about reclaimed +nodes and hard limit for the cache size. This value was chosen +automatically by CUDD for a datasize limit of 1 GB. + +\begin{verbatim} + Maximum number of variables sifted per reordering: 1000 + Maximum number of variable swaps per reordering: 2000000 + Maximum growth while sifting a variable: 1.2 +\end{verbatim} +Lowering these numbers will cause reordering to be less accurate and +faster. Results are somewhat unpredictable, because larger BDDs after one +reordering do not necessarily mean the process will go faster or slower. + +\begin{verbatim} + Dynamic reordering of BDDs enabled: yes + Default BDD reordering method: 4 + Dynamic reordering of ZDDs enabled: no + Default ZDD reordering method: 4 +\end{verbatim} +These lines tell whether automatic reordering can take place and what +method would be used. The mapping from numbers to methods is in +\texttt{cudd.h}. One may want to try different BDD reordering +methods. If variable groups are used, however, one should not expect +to see big differences, because CUDD uses the reported method only to +reorder each leaf variable group (typically corresponding present and +next state variables). For the relative order of the groups, it +always uses the same algorithm, which is effectively sifting. + +As for enabling dynamic reordering or not, a sensible recommendation is the +following: Unless the circuit is rather small or one has a pretty good +idea of what the order should be, reordering should be enabled. + +\begin{verbatim} + Realignment of ZDDs to BDDs enabled: no + Realignment of BDDs to ZDDs enabled: no + Dead nodes counted in triggering reordering: no + Group checking criterion: 7 + Recombination threshold: 0 + Symmetry violation threshold: 0 + Arc violation threshold: 0 + GA population size: 0 + Number of crossovers for GA: 0 +\end{verbatim} +Parameters for reordering. See the documentation of the functions used +to control these parameters for the details. + +\begin{verbatim} + Next reordering threshold: 100000 +\end{verbatim} +When the number of nodes crosses this threshold, reordering will be +triggered. (If enabled; in this case it is not.) This parameter is +updated by the package whenever reordering takes place. The +application can change it, for instance at start-up. Another +possibility is to use a hook function (see Section~\ref{sec:hooks}) to +override the default updating policy. + +\subsubsection{Extended Statistics and Reporting} +\label{sec:extendedStats} + +The following symbols can be defined during compilation to increase +the amount of statistics gathered and the number of messages produced +by the package: +\begin{itemize} +\item DD\_STATS\index{DD\_STATS}; +\item DD\_CACHE\_PROFILE\index{DD\_CACHE\_PROFILE}; +\item DD\_UNIQUE\_PROFILE\index{DD\_UNIQUE\_PROFILE}. +\item DD\_VERBOSE\index{DD\_VERBOSE}; +\end{itemize} +Defining DD\_CACHE\_PROFILE causes each entry of the cache to include +an access counter, which is used to compute simple statistics on the +distribution of the keys. + +\subsection{Guidelines for Documentation} +\label{sec:doc}\index{documentation} + +The documentation of the CUDD functions is extracted automatically +from the sources by \texttt{doxygen}\index{doxygen} +\href{http://www.doxygen.org}{\texttt{www.doxygen.org}}.) +The following guidelines are adhered to in CUDD to insure consistent and +effective use of automatic extraction. It is recommended that +extensions to CUDD follow the same documentation guidelines. +\begin{itemize} +\item The documentation of an exported procedure should be sufficient + to allow one to use it without reading the code. It is not necessary + to explain how the procedure works; only what it does. +\item The \emph{see}\index{documentation!SeeAlso@\emph{see}} + fields should be space-separated lists of function names. The + \emph{see} field of an exported procedure should only reference + other exported procedures. The \emph{see} field of an internal + procedure may reference other internal procedures as well as + exported procedures, but no static procedures. +\item The return values are detailed in the + \emph{return}\index{documentation!Description@\emph{return}} + field, not in the + \emph{brief}\index{documentation!Synopsis@\emph{brief}} field. +\item The parameters are documented alongside their declarations. + Further comments may appear in the \emph{details} field. +\item The \emph{brief} field should be about one line long. +\end{itemize} + +%---------------------------------------- + +\section{The C++ Interface} +\label{sec:cpp} + + +\subsection{Compiling and Linking} +\label{sec:compileCpp} + +To build an application that uses the CUDD C++ interface, you should +add +\begin{verbatim} +#include "cuddObj.hh" +\end{verbatim} +to your source files. In addition to the normal CUDD libraries (see +Section~\ref{sec:compileExt}) you should link +\verb|libobj.a|\index{libraries!obj} to your executable. Refer to the +installation notes in the top level directory of the distribution for +further details. + +\subsection{Basic Manipulation} +\label{sec:basicCpp} + +The following fragment of code illustrates some simple operations on +BDDs using the C++ interface. +\begin{verbatim} + Cudd mgr(0,0); + BDD x = mgr.bddVar(); + BDD y = mgr.bddVar(); + BDD f = x * y; + BDD g = y + !x; + cout << "f is" << (f <= g ? "" : " not") + << " less than or equal to g\n"; +\end{verbatim} +This code creates a manager called \verb|mgr| and two variables in it. +It then defines two functions \verb|f| and \verb|g| in terms of the +variables. Finally, it prints a message based on the comparison of the +two functions. No explicit referencing or dereferencing is required. +The operators are overloaded in the intuitive way. BDDs are freed when +execution leaves the scope in which they are defined or when the +variables referring to them are overwritten. + +%---------------------------------------- +\section{Acknowledgments} +\label{sec:ack} + +The contributors: Iris Bahar, Hyunwoo Cho, Erica Frohm, Charlie Gaona, +Cheng Hua, Jae-Young Jang, Seh-Woong Jeong, Balakrishna Kumthekar, +Enrico Macii, Bobbie Manne, In-Ho Moon, Curt Musfeldt, Shipra Panda, +Abelardo Pardo, Bernard Plessier, Kavita Ravi, Hyongkyoon Shin, Alan +Shuler, Arun Sivakumaran, Jorgen Sivesind. + +\noindent +The early adopters: Gianpiero Cabodi, Jordi Cortadella, Mario Escobar, +Gayani Gamage, Gary Hachtel, Mariano Hermida, Woohyuk Lee, Enric +Pastor, Massimo Poncino, Ellen Sentovich, the students of ECEN5139. + +I am also particularly indebted to the following people for in-depth +discussions on BDDs: Armin Biere, Olivier Coudert, Hubert Garavel, +Arie Gurfinkel, Geert Janssen, Don Knuth, David Long, Jean Christophe +Madre, Ken McMillan, Shin-Ichi Minato, Jaehong Park, Rajeev Ranjan, +Rick Rudell, Ellen Sentovich, Tom Shiple, Christian Stangier, and +Bwolen Yang. + +Special thanks to Norris Ip for guiding my faltering steps +in the design of the C++ interface. +Gianpiero Cabodi and Stefano Quer have graciously agreed to let me +distribute their dddmp library with CUDD. + +Masahiro Fujita, Gary Hachtel, and Carl Pixley have provided +encouragement and advice. + +The National Science Foundation and the Semiconductor Research +Corporation have supported in part the development of this package. + +\phantomsection +\addcontentsline{toc}{section}{\numberline{}References} +%\bibliography{comb-synthesis,references,ref2} + +\begin{thebibliography}{10} + +\bibitem{Bahar93} +R.~I. Bahar, E.~A. Frohm, C.~M. Gaona, G.~D. Hachtel, E.~Macii, A.~Pardo, and + F.~Somenzi. +\newblock Algebraic decision diagrams and their applications. +\newblock In {\em Proceedings of the International Conference on Computer-Aided + Design}, pages 188--191, Santa Clara, CA, November 1993. + +\bibitem{Bollig95} +B.~Bollig, M.~L\"obbing, and I.~Wegener. +\newblock Simulated annealing to improve variable orderings for {OBDDs}. +\newblock Presented at the International Workshop on Logic Synthesis, + Granlibakken, CA, May 1995. + +\bibitem{BBR} +K.~S. Brace, R.~L. Rudell, and R.~E. Bryant. +\newblock Efficient implementation of a {BDD} package. +\newblock In {\em Proceedings of the 27th Design Automation Conference}, pages + 40--45, Orlando, FL, June 1990. + +\bibitem{BDD} +R.~E. Bryant. +\newblock Graph-based algorithms for {Boolean} function manipulation. +\newblock {\em IEEE Transactions on Computers}, C-35(8):677--691, August 1986. + +\bibitem{Drechs95} +R.~Drechsler, B.~Becker, and N.~G\"ockel. +\newblock A genetic algorithm for variable ordering of {OBDDs}. +\newblock Presented at the International Workshop on Logic Synthesis, + Granlibakken, CA, May 1995. + +\bibitem{Friedman90} +S.~J. Friedman and K.~J. Supowit. +\newblock Finding the optimal variable ordering for binary decision diagrams. +\newblock {\em IEEE Transactions on Computers}, 39(5):710--713, May 1990. + +\bibitem{Fujita91b} +M.~Fujita, Y.~Matsunaga, and T.~Kakuda. +\newblock On variable ordering of binary decision diagrams for the application + of multi-level logic synthesis. +\newblock In {\em Proceedings of the European Conference on Design Automation}, + pages 50--54, Amsterdam, February 1991. + +\bibitem{Held62} +M.~Held and R.~M. Karp. +\newblock A dynamic programming approach to sequencing problems. +\newblock {\em J. SIAM}, 10(1):196--210, 1962. + +\bibitem{Ishiur91} +N.~Ishiura, H.~Sawada, and S.~Yajima. +\newblock Minimization of binary decision diagrams based on exchanges of + variables. +\newblock In {\em Proceedings of the International Conference on Computer-Aided + Design}, pages 472--475, Santa Clara, CA, November 1991. + +\bibitem{Jeong93} +S.-W. Jeong, T.-S. Kim, and F.~Somenzi. +\newblock An efficient method for optimal {BDD} ordering computation. +\newblock In {\em International Conference on VLSI and CAD (ICVC'93)}, Taejon, + Korea, November 1993. + +\bibitem{Minato93} +S.-I. Minato. +\newblock Zero-suppressed {BDD}s for set manipulation in combinatorial + problems. +\newblock In {\em Proceedings of the Design Automation Conference}, pages + 272--277, Dallas, TX, June 1993. + +\bibitem{Panda95b} +S.~Panda and F.~Somenzi. +\newblock Who are the variables in your neighborhood. +\newblock In {\em Proceedings of the International Conference on Computer-Aided + Design}, pages 74--77, San Jose, CA, November 1995. + +\bibitem{Panda94} +S.~Panda, F.~Somenzi, and B.~F. Plessier. +\newblock Symmetry detection and dynamic variable ordering of decision + diagrams. +\newblock In {\em Proceedings of the International Conference on Computer-Aided + Design}, pages 628--631, San Jose, CA, November 1994. + +\bibitem{Plessi93} +B.~F. Plessier. +\newblock {\em A General Framework for Verification of Sequential Circuits}. +\newblock PhD thesis, University of Colorado at Boulder, Dept.\ of Electrical + and Computer Engineering, 1993. + +\bibitem{Rudell93} +R.~Rudell. +\newblock Dynamic variable ordering for ordered binary decision diagrams. +\newblock In {\em Proceedings of the International Conference on Computer-Aided + Design}, pages 42--47, Santa Clara, CA, November 1993. + +\end{thebibliography} + + +% Index cross-references. +\index{Algebraic Decision Diagram|see{ADD}} +\index{Binary Decision Diagram|see{BDD}} +\index{Zero-suppressed Binary Decision Diagram|see{ZDD}} +\index{dot|see{graph, drawing}} +\index{extdoc|see{documentation}} +\index{node!terminal|see{node, constant}} +\phantomsection +\addcontentsline{toc}{section}{\numberline{}Index} +\printindex +\end{document} + +%%% Local Variables: +%%% mode: latex +%%% TeX-master: t +%%% TeX-PDF-mode: t +%%% End: diff --git a/resources/3rdparty/cudd-3.0.0/doc/phase.pdf b/resources/3rdparty/cudd-3.0.0/doc/phase.pdf new file mode 100644 index 000000000..6d75873cc Binary files /dev/null and b/resources/3rdparty/cudd-3.0.0/doc/phase.pdf differ diff --git a/resources/3rdparty/cudd-3.0.0/epd/Included.am b/resources/3rdparty/cudd-3.0.0/epd/Included.am new file mode 100644 index 000000000..a8f418b5b --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/epd/Included.am @@ -0,0 +1 @@ +cudd_libcudd_la_SOURCES += epd/epd.c epd/epdInt.h epd/epd.h diff --git a/resources/3rdparty/cudd-2.5.0/src/epd/epd.c b/resources/3rdparty/cudd-3.0.0/epd/epd.c similarity index 59% rename from resources/3rdparty/cudd-2.5.0/src/epd/epd.c rename to resources/3rdparty/cudd-3.0.0/epd/epd.c index 14f314fab..7bfa9078c 100644 --- a/resources/3rdparty/cudd-2.5.0/src/epd/epd.c +++ b/resources/3rdparty/cudd-3.0.0/epd/epd.c @@ -1,18 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [epd.c] + @ingroup epd - PackageName [epd] + @brief Arithmetic functions with extended double precision. - Synopsis [Arithmetic functions with extended double precision.] + @author In-Ho Moon - Description [] - - SeeAlso [] - - Author [In-Ho Moon] - - Copyright [Copyright (c) 1995-2004, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,31 +38,19 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] - - Revision [$Id: epd.c,v 1.10 2004/08/13 18:20:30 fabio Exp $] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ -#include <stdio.h> -#include <stdlib.h> -#include <string.h> #include <math.h> #include "util.h" -#include "epd.h" - - -/**Function******************************************************************** - - Synopsis [Allocates an EpDouble struct.] +#include "epdInt.h" - Description [Allocates an EpDouble struct.] - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Allocates an EpDouble struct. +*/ EpDouble * EpdAlloc(void) { @@ -77,22 +61,16 @@ EpdAlloc(void) } -/**Function******************************************************************** - - Synopsis [Compares two EpDouble struct.] - - Description [Compares two EpDouble struct.] - - SideEffects [] - - SeeAlso [] +/** + @brief Compares two EpDouble struct. -******************************************************************************/ + @return 0 if the two structures hold the same value; 1 otherwise. +*/ int -EpdCmp(const char *key1, const char *key2) +EpdCmp(const void *key1, const void *key2) { - EpDouble *epd1 = (EpDouble *) key1; - EpDouble *epd2 = (EpDouble *) key2; + EpDouble const *epd1 = (EpDouble const *) key1; + EpDouble const *epd2 = (EpDouble const *) key2; if (epd1->type.value != epd2->type.value || epd1->exponent != epd2->exponent) { return(1); @@ -101,17 +79,9 @@ EpdCmp(const char *key1, const char *key2) } -/**Function******************************************************************** - - Synopsis [Frees an EpDouble struct.] - - Description [Frees an EpDouble struct.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Frees an EpDouble struct. +*/ void EpdFree(EpDouble *epd) { @@ -119,32 +89,28 @@ EpdFree(EpDouble *epd) } -/**Function******************************************************************** - - Synopsis [Converts an arbitrary precision double value to a string.] +/** + @brief Converts an extended precision double value to a string. - Description [Converts an arbitrary precision double value to a string.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ + @sideeffect The string is written at the address passed in `str`. +*/ void -EpdGetString(EpDouble *epd, char *str) +EpdGetString(EpDouble const *epd, char *str) { double value; int exponent; char *pos; + if (!str) return; + if (IsNanDouble(epd->type.value)) { sprintf(str, "NaN"); return; } else if (IsInfDouble(epd->type.value)) { if (epd->type.bits.sign == 1) - sprintf(str, "-Inf"); + sprintf(str, "-inf"); else - sprintf(str, "Inf"); + sprintf(str, "inf"); return; } @@ -169,17 +135,9 @@ EpdGetString(EpDouble *epd, char *str) } -/**Function******************************************************************** - - Synopsis [Converts double to EpDouble struct.] - - Description [Converts double to EpDouble struct.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Converts double to EpDouble struct. +*/ void EpdConvert(double value, EpDouble *epd) { @@ -189,17 +147,9 @@ EpdConvert(double value, EpDouble *epd) } -/**Function******************************************************************** - - Synopsis [Multiplies two arbitrary precision double values.] - - Description [Multiplies two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Multiplies an extended precision double by a double. +*/ void EpdMultiply(EpDouble *epd1, double value) { @@ -230,19 +180,11 @@ EpdMultiply(EpDouble *epd1, double value) } -/**Function******************************************************************** - - Synopsis [Multiplies two arbitrary precision double values.] - - Description [Multiplies two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Multiplies an extended precision double by another. +*/ void -EpdMultiply2(EpDouble *epd1, EpDouble *epd2) +EpdMultiply2(EpDouble *epd1, EpDouble const *epd2) { double value; int exponent; @@ -269,19 +211,11 @@ EpdMultiply2(EpDouble *epd1, EpDouble *epd2) } -/**Function******************************************************************** - - Synopsis [Multiplies two arbitrary precision double values.] - - Description [Multiplies two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Multiplies two extended precision double values. +*/ void -EpdMultiply2Decimal(EpDouble *epd1, EpDouble *epd2) +EpdMultiply2Decimal(EpDouble *epd1, EpDouble const *epd2) { double value; int exponent; @@ -305,22 +239,16 @@ EpdMultiply2Decimal(EpDouble *epd1, EpDouble *epd2) } -/**Function******************************************************************** +/** + @brief Multiplies two extended precision double values. - Synopsis [Multiplies two arbitrary precision double values.] - - Description [Multiplies two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ + @details The result goes in the third operand. +*/ void -EpdMultiply3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3) +EpdMultiply3(EpDouble const *epd1, EpDouble const *epd2, EpDouble *epd3) { if (EpdIsNan(epd1) || EpdIsNan(epd2)) { - EpdMakeNan(epd1); + EpdMakeNan(epd3); return; } else if (EpdIsInf(epd1) || EpdIsInf(epd2)) { int sign; @@ -339,22 +267,14 @@ EpdMultiply3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3) } -/**Function******************************************************************** - - Synopsis [Multiplies two arbitrary precision double values.] - - Description [Multiplies two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Multiplies two extended precision double values. +*/ void -EpdMultiply3Decimal(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3) +EpdMultiply3Decimal(EpDouble const *epd1, EpDouble const *epd2, EpDouble *epd3) { if (EpdIsNan(epd1) || EpdIsNan(epd2)) { - EpdMakeNan(epd1); + EpdMakeNan(epd3); return; } else if (EpdIsInf(epd1) || EpdIsInf(epd2)) { int sign; @@ -370,17 +290,9 @@ EpdMultiply3Decimal(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3) } -/**Function******************************************************************** - - Synopsis [Divides two arbitrary precision double values.] - - Description [Divides two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Divides an extended precision double by a double. +*/ void EpdDivide(EpDouble *epd1, double value) { @@ -423,19 +335,11 @@ EpdDivide(EpDouble *epd1, double value) } -/**Function******************************************************************** - - Synopsis [Divides two arbitrary precision double values.] - - Description [Divides two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Divides an extended precision double by another. +*/ void -EpdDivide2(EpDouble *epd1, EpDouble *epd2) +EpdDivide2(EpDouble *epd1, EpDouble const *epd2) { double value; int exponent; @@ -474,19 +378,11 @@ EpdDivide2(EpDouble *epd1, EpDouble *epd2) } -/**Function******************************************************************** - - Synopsis [Divides two arbitrary precision double values.] - - Description [Divides two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Divides two extended precision double values. +*/ void -EpdDivide3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3) +EpdDivide3(EpDouble const *epd1, EpDouble const *epd2, EpDouble *epd3) { if (EpdIsNan(epd1) || EpdIsNan(epd2)) { EpdMakeNan(epd3); @@ -520,17 +416,9 @@ EpdDivide3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3) } -/**Function******************************************************************** - - Synopsis [Adds two arbitrary precision double values.] - - Description [Adds two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Adds a double to an extended precision double. +*/ void EpdAdd(EpDouble *epd1, double value) { @@ -582,19 +470,13 @@ EpdAdd(EpDouble *epd1, double value) } -/**Function******************************************************************** - - Synopsis [Adds two arbitrary precision double values.] - - Description [Adds two arbitrary precision double values.] - - SideEffects [] +/** + @brief Adds an extended precision double to another. - SeeAlso [] - -******************************************************************************/ + @details The sum goes in the first argument. +*/ void -EpdAdd2(EpDouble *epd1, EpDouble *epd2) +EpdAdd2(EpDouble *epd1, EpDouble const *epd2) { double value; int exponent, diff; @@ -644,19 +526,11 @@ EpdAdd2(EpDouble *epd1, EpDouble *epd2) } -/**Function******************************************************************** - - Synopsis [Adds two arbitrary precision double values.] - - Description [Adds two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Adds two extended precision double values. +*/ void -EpdAdd3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3) +EpdAdd3(EpDouble const *epd1, EpDouble const *epd2, EpDouble *epd3) { double value; int exponent, diff; @@ -710,17 +584,9 @@ EpdAdd3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3) } -/**Function******************************************************************** - - Synopsis [Subtracts two arbitrary precision double values.] - - Description [Subtracts two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Subtracts a double from an extended precision double. +*/ void EpdSubtract(EpDouble *epd1, double value) { @@ -772,19 +638,11 @@ EpdSubtract(EpDouble *epd1, double value) } -/**Function******************************************************************** - - Synopsis [Subtracts two arbitrary precision double values.] - - Description [Subtracts two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Subtracts an extended precision double from another. +*/ void -EpdSubtract2(EpDouble *epd1, EpDouble *epd2) +EpdSubtract2(EpDouble *epd1, EpDouble const *epd2) { double value; int exponent, diff; @@ -834,19 +692,11 @@ EpdSubtract2(EpDouble *epd1, EpDouble *epd2) } -/**Function******************************************************************** - - Synopsis [Subtracts two arbitrary precision double values.] - - Description [Subtracts two arbitrary precision double values.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Subtracts two extended precision double values. +*/ void -EpdSubtract3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3) +EpdSubtract3(EpDouble const *epd1, EpDouble const *epd2, EpDouble *epd3) { double value; int exponent, diff; @@ -864,7 +714,7 @@ EpdSubtract3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3) else EpdMakeNan(epd3); } else if (EpdIsInf(epd1)) { - EpdCopy(epd1, epd1); + EpdCopy(epd1, epd3); } else { sign = epd2->type.bits.sign ^ 0x1; EpdMakeInf(epd3, sign); @@ -901,17 +751,9 @@ EpdSubtract3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3) } -/**Function******************************************************************** - - Synopsis [Computes arbitrary precision pow of base 2.] - - Description [Computes arbitrary precision pow of base 2.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Computes extended precision pow of base 2. +*/ void EpdPow2(int n, EpDouble *epd) { @@ -930,17 +772,9 @@ EpdPow2(int n, EpDouble *epd) } -/**Function******************************************************************** - - Synopsis [Computes arbitrary precision pow of base 2.] - - Description [Computes arbitrary precision pow of base 2.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Computes extended precision pow of base 2. +*/ void EpdPow2Decimal(int n, EpDouble *epd) { @@ -961,17 +795,9 @@ EpdPow2Decimal(int n, EpDouble *epd) } -/**Function******************************************************************** - - Synopsis [Normalize an arbitrary precision double value.] - - Description [Normalize an arbitrary precision double value.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Normalize an extended precision double value. +*/ void EpdNormalize(EpDouble *epd) { @@ -991,17 +817,9 @@ EpdNormalize(EpDouble *epd) } -/**Function******************************************************************** - - Synopsis [Normalize an arbitrary precision double value.] - - Description [Normalize an arbitrary precision double value.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Normalize an extended precision double value. +*/ void EpdNormalizeDecimal(EpDouble *epd) { @@ -1018,24 +836,19 @@ EpdNormalizeDecimal(EpDouble *epd) } -/**Function******************************************************************** - - Synopsis [Returns value and decimal exponent of EpDouble.] - - Description [Returns value and decimal exponent of EpDouble.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Returns value and decimal exponent of EpDouble. +*/ void -EpdGetValueAndDecimalExponent(EpDouble *epd, double *value, int *exponent) +EpdGetValueAndDecimalExponent(EpDouble const *epd, double *value, int *exponent) { EpDouble epd1, epd2; - if (EpdIsNanOrInf(epd)) + if (EpdIsNanOrInf(epd)) { + *exponent = EPD_EXP_INF; + *value = 0.0; return; + } if (EpdIsZero(epd)) { *value = 0.0; @@ -1052,17 +865,9 @@ EpdGetValueAndDecimalExponent(EpDouble *epd, double *value, int *exponent) *exponent = epd1.exponent; } -/**Function******************************************************************** - - Synopsis [Returns the exponent value of a double.] - - Description [Returns the exponent value of a double.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Returns the exponent value of a double. +*/ int EpdGetExponent(double value) { @@ -1075,17 +880,9 @@ EpdGetExponent(double value) } -/**Function******************************************************************** - - Synopsis [Returns the decimal exponent value of a double.] - - Description [Returns the decimal exponent value of a double.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Returns the decimal exponent value of a double. +*/ int EpdGetExponentDecimal(double value) { @@ -1099,17 +896,9 @@ EpdGetExponentDecimal(double value) } -/**Function******************************************************************** - - Synopsis [Makes EpDouble Inf.] - - Description [Makes EpDouble Inf.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Makes EpDouble Inf. +*/ void EpdMakeInf(EpDouble *epd, int sign) { @@ -1121,17 +910,9 @@ EpdMakeInf(EpDouble *epd, int sign) } -/**Function******************************************************************** - - Synopsis [Makes EpDouble Zero.] - - Description [Makes EpDouble Zero.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Makes EpDouble Zero. +*/ void EpdMakeZero(EpDouble *epd, int sign) { @@ -1143,17 +924,9 @@ EpdMakeZero(EpDouble *epd, int sign) } -/**Function******************************************************************** - - Synopsis [Makes EpDouble NaN.] - - Description [Makes EpDouble NaN.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Makes EpDouble NaN. +*/ void EpdMakeNan(EpDouble *epd) { @@ -1166,56 +939,32 @@ EpdMakeNan(EpDouble *epd) } -/**Function******************************************************************** - - Synopsis [Copies a EpDouble struct.] - - Description [Copies a EpDouble struct.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Copies an EpDouble struct. +*/ void -EpdCopy(EpDouble *from, EpDouble *to) +EpdCopy(EpDouble const *from, EpDouble *to) { to->type.value = from->type.value; to->exponent = from->exponent; } -/**Function******************************************************************** - - Synopsis [Checks whether the value is Inf.] - - Description [Checks whether the value is Inf.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Checks whether the value is Inf. +*/ int -EpdIsInf(EpDouble *epd) +EpdIsInf(EpDouble const *epd) { return(IsInfDouble(epd->type.value)); } -/**Function******************************************************************** - - Synopsis [Checks whether the value is Zero.] - - Description [Checks whether the value is Zero.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Checks whether the value is Zero. +*/ int -EpdIsZero(EpDouble *epd) +EpdIsZero(EpDouble const *epd) { if (epd->type.value == 0.0) return(1); @@ -1224,53 +973,29 @@ EpdIsZero(EpDouble *epd) } -/**Function******************************************************************** - - Synopsis [Checks whether the value is NaN.] - - Description [Checks whether the value is NaN.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Checks whether the value is NaN. +*/ int -EpdIsNan(EpDouble *epd) +EpdIsNan(EpDouble const *epd) { return(IsNanDouble(epd->type.value)); } -/**Function******************************************************************** - - Synopsis [Checks whether the value is NaN or Inf.] - - Description [Checks whether the value is NaN or Inf.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Checks whether the value is NaN or Inf. +*/ int -EpdIsNanOrInf(EpDouble *epd) +EpdIsNanOrInf(EpDouble const *epd) { return(IsNanOrInfDouble(epd->type.value)); } -/**Function******************************************************************** - - Synopsis [Checks whether the value is Inf.] - - Description [Checks whether the value is Inf.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Checks whether the value is Inf. +*/ int IsInfDouble(double value) { @@ -1289,17 +1014,9 @@ IsInfDouble(double value) } -/**Function******************************************************************** - - Synopsis [Checks whether the value is NaN.] - - Description [Checks whether the value is NaN.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Checks whether the value is NaN. +*/ int IsNanDouble(double value) { @@ -1317,17 +1034,9 @@ IsNanDouble(double value) } -/**Function******************************************************************** - - Synopsis [Checks whether the value is NaN or Inf.] - - Description [Checks whether the value is NaN or Inf.] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Checks whether the value is NaN or Inf. +*/ int IsNanOrInfDouble(double value) { diff --git a/resources/3rdparty/cudd-3.0.0/epd/epd.h b/resources/3rdparty/cudd-3.0.0/epd/epd.h new file mode 100644 index 000000000..1e52eaf83 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/epd/epd.h @@ -0,0 +1,112 @@ +/** + @file + + @ingroup epd + + @brief The University of Colorado extended double precision package. + + @details Arithmetic functions with extended double precision. The floating + point numbers manipulated by this package use an int to hold the exponent. + The significand has the same precision as a standard double. + + @author In-Ho Moon + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#ifndef EPD_H_ +#define EPD_H_ + +#ifdef __cplusplus +extern "C" { +#endif + +/*---------------------------------------------------------------------------*/ +/* Type declarations */ +/*---------------------------------------------------------------------------*/ + +/** + @brief The type of extended precision floating-point numbers. +*/ +typedef struct EpDoubleStruct EpDouble; + +/*---------------------------------------------------------------------------*/ +/* Function prototypes */ +/*---------------------------------------------------------------------------*/ + +extern EpDouble *EpdAlloc(void); +extern int EpdCmp(const void *key1, const void *key2); +extern void EpdFree(EpDouble *epd); +extern void EpdGetString(EpDouble const *epd, char *str); +extern void EpdConvert(double value, EpDouble *epd); +extern void EpdMultiply(EpDouble *epd1, double value); +extern void EpdMultiply2(EpDouble *epd1, EpDouble const *epd2); +extern void EpdMultiply2Decimal(EpDouble *epd1, EpDouble const *epd2); +extern void EpdMultiply3(EpDouble const *epd1, EpDouble const *epd2, EpDouble *epd3); +extern void EpdMultiply3Decimal(EpDouble const *epd1, EpDouble const *epd2, EpDouble *epd3); +extern void EpdDivide(EpDouble *epd1, double value); +extern void EpdDivide2(EpDouble *epd1, EpDouble const *epd2); +extern void EpdDivide3(EpDouble const *epd1, EpDouble const *epd2, EpDouble *epd3); +extern void EpdAdd(EpDouble *epd1, double value); +extern void EpdAdd2(EpDouble *epd1, EpDouble const *epd2); +extern void EpdAdd3(EpDouble const *epd1, EpDouble const *epd2, EpDouble *epd3); +extern void EpdSubtract(EpDouble *epd1, double value); +extern void EpdSubtract2(EpDouble *epd1, EpDouble const *epd2); +extern void EpdSubtract3(EpDouble const *epd1, EpDouble const *epd2, EpDouble *epd3); +extern void EpdPow2(int n, EpDouble *epd); +extern void EpdPow2Decimal(int n, EpDouble *epd); +extern void EpdNormalize(EpDouble *epd); +extern void EpdNormalizeDecimal(EpDouble *epd); +extern void EpdGetValueAndDecimalExponent(EpDouble const *epd, double *value, int *exponent); +extern int EpdGetExponent(double value); +extern int EpdGetExponentDecimal(double value); +extern void EpdMakeInf(EpDouble *epd, int sign); +extern void EpdMakeZero(EpDouble *epd, int sign); +extern void EpdMakeNan(EpDouble *epd); +extern void EpdCopy(EpDouble const *from, EpDouble *to); +extern int EpdIsInf(EpDouble const *epd); +extern int EpdIsZero(EpDouble const *epd); +extern int EpdIsNan(EpDouble const *epd); +extern int EpdIsNanOrInf(EpDouble const *epd); +extern int IsInfDouble(double value); +extern int IsNanDouble(double value); +extern int IsNanOrInfDouble(double value); + +#ifdef __cplusplus +} +#endif + +#endif /* EPD_H_ */ diff --git a/resources/3rdparty/cudd-2.5.0/src/epd/epd.h b/resources/3rdparty/cudd-3.0.0/epd/epdInt.h similarity index 50% rename from resources/3rdparty/cudd-2.5.0/src/epd/epd.h rename to resources/3rdparty/cudd-3.0.0/epd/epdInt.h index 4b538c016..4d3ddb461 100644 --- a/resources/3rdparty/cudd-2.5.0/src/epd/epd.h +++ b/resources/3rdparty/cudd-3.0.0/epd/epdInt.h @@ -1,18 +1,15 @@ -/**CHeaderFile***************************************************************** +/** + @file - FileName [epd.h] + @ingroup epd - PackageName [epd] + @brief Internal header for the University of Colorado extended + double precision package. - Synopsis [The University of Colorado extended double precision package.] + @author In-Ho Moon - Description [arithmetic functions with extended double precision.] - - SeeAlso [] - - Author [In-Ho Moon] - - Copyright [Copyright (c) 1995-2004, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,17 +39,19 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock - Revision [$Id: epd.h,v 1.9 2004/08/13 18:20:30 fabio Exp $] +*/ -******************************************************************************/ +#ifndef EPD_INT_H_ +#define EPD_INT_H_ -#ifndef _EPD -#define _EPD +#include "config.h" +#include "epd.h" -#ifdef __cplusplus -extern "C" { +#if WORDS_BIGENDIAN == 1 +#define EPD_BIG_ENDIAN #endif /*---------------------------------------------------------------------------*/ @@ -64,18 +63,20 @@ extern "C" { #define EPD_EXP_INF 0x7ff /*---------------------------------------------------------------------------*/ -/* Structure declarations */ +/* Type declarations */ /*---------------------------------------------------------------------------*/ -/**Struct********************************************************************** - - Synopsis [IEEE double struct.] - - Description [IEEE double struct.] +typedef struct IeeeDoubleStruct IeeeDouble; +typedef struct IeeeNanStruct IeeeNan; +typedef union EpTypeUnion EpType; - SeeAlso [] +/*---------------------------------------------------------------------------*/ +/* Structure declarations */ +/*---------------------------------------------------------------------------*/ -******************************************************************************/ +/** + @brief IEEE double struct. +*/ #ifdef EPD_BIG_ENDIAN struct IeeeDoubleStruct { /* BIG_ENDIAN */ unsigned int sign: 1; @@ -92,15 +93,9 @@ struct IeeeDoubleStruct { /* LITTLE_ENDIAN */ }; #endif -/**Struct********************************************************************** - - Synopsis [IEEE double NaN struct.] - - Description [IEEE double NaN struct.] - - SeeAlso [] - -******************************************************************************/ +/** + @brief IEEE double NaN struct. +*/ #ifdef EPD_BIG_ENDIAN struct IeeeNanStruct { /* BIG_ENDIAN */ unsigned int sign: 1; @@ -119,82 +114,33 @@ struct IeeeNanStruct { /* LITTLE_ENDIAN */ }; #endif -/**Struct********************************************************************** - - Synopsis [Extended precision double to keep very large value.] - - Description [Extended precision double to keep very large value.] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Different views of a double. +*/ union EpTypeUnion { double value; struct IeeeDoubleStruct bits; struct IeeeNanStruct nan; }; +/** + @brief Extended precision double to keep very large value. +*/ struct EpDoubleStruct { union EpTypeUnion type; int exponent; }; -/*---------------------------------------------------------------------------*/ -/* Type declarations */ -/*---------------------------------------------------------------------------*/ -typedef struct EpDoubleStruct EpDouble; -typedef struct IeeeDoubleStruct IeeeDouble; -typedef struct IeeeNanStruct IeeeNan; -typedef union EpTypeUnion EpType; - -/**AutomaticStart*************************************************************/ - /*---------------------------------------------------------------------------*/ /* Function prototypes */ /*---------------------------------------------------------------------------*/ -extern EpDouble *EpdAlloc(void); -extern int EpdCmp(const char *key1, const char *key2); -extern void EpdFree(EpDouble *epd); -extern void EpdGetString(EpDouble *epd, char *str); -extern void EpdConvert(double value, EpDouble *epd); -extern void EpdMultiply(EpDouble *epd1, double value); -extern void EpdMultiply2(EpDouble *epd1, EpDouble *epd2); -extern void EpdMultiply2Decimal(EpDouble *epd1, EpDouble *epd2); -extern void EpdMultiply3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3); -extern void EpdMultiply3Decimal(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3); -extern void EpdDivide(EpDouble *epd1, double value); -extern void EpdDivide2(EpDouble *epd1, EpDouble *epd2); -extern void EpdDivide3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3); -extern void EpdAdd(EpDouble *epd1, double value); -extern void EpdAdd2(EpDouble *epd1, EpDouble *epd2); -extern void EpdAdd3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3); -extern void EpdSubtract(EpDouble *epd1, double value); -extern void EpdSubtract2(EpDouble *epd1, EpDouble *epd2); -extern void EpdSubtract3(EpDouble *epd1, EpDouble *epd2, EpDouble *epd3); -extern void EpdPow2(int n, EpDouble *epd); -extern void EpdPow2Decimal(int n, EpDouble *epd); -extern void EpdNormalize(EpDouble *epd); -extern void EpdNormalizeDecimal(EpDouble *epd); -extern void EpdGetValueAndDecimalExponent(EpDouble *epd, double *value, int *exponent); -extern int EpdGetExponent(double value); -extern int EpdGetExponentDecimal(double value); -extern void EpdMakeInf(EpDouble *epd, int sign); -extern void EpdMakeZero(EpDouble *epd, int sign); -extern void EpdMakeNan(EpDouble *epd); -extern void EpdCopy(EpDouble *from, EpDouble *to); -extern int EpdIsInf(EpDouble *epd); -extern int EpdIsZero(EpDouble *epd); -extern int EpdIsNan(EpDouble *epd); -extern int EpdIsNanOrInf(EpDouble *epd); -extern int IsInfDouble(double value); -extern int IsNanDouble(double value); -extern int IsNanOrInfDouble(double value); - -/**AutomaticEnd***************************************************************/ +#ifdef __cplusplus +extern "C" { +#endif #ifdef __cplusplus } #endif -#endif /* _EPD */ +#endif /* EPD_H_ */ diff --git a/resources/3rdparty/cudd-3.0.0/groups.dox b/resources/3rdparty/cudd-3.0.0/groups.dox new file mode 100644 index 000000000..8597dbb8b --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/groups.dox @@ -0,0 +1,33 @@ +/** + * @mainpage CUDD Documentation + * + * @brief The CUDD package manipulates Binary Decision Diagrams (BDDs), + * Algebraic Decision Diagrams (ADDs), and Zero-suppressed binary Decision + * Diagrams (ZDDs). + */ + +/** + * @defgroup cudd cudd + * @brief The University of Colorado Decision Diagram package. + * + * @defgroup mtr mtr + * @brief Multiway-branching Trees. + * + * @defgroup epd epd + * @brief Extended double precision package. + * + * @defgroup st st + * @brief Symbol Table package. + * + * @defgroup util util + * @brief Low-level utilities. + * + * @defgroup cstringstream cstringstream + * @brief (Simple) stringstreams in C. + * + * @defgroup cplusplus cplusplus + * @brief C++ CUDD wrapper. + * + * @defgroup nanotrav nanotrav + * @brief CUDD test application. + */ diff --git a/resources/3rdparty/cudd-3.0.0/m4/libtool.m4 b/resources/3rdparty/cudd-3.0.0/m4/libtool.m4 new file mode 100644 index 000000000..d7c043f4f --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/m4/libtool.m4 @@ -0,0 +1,7997 @@ +# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- +# +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, +# 2006, 2007, 2008, 2009, 2010, 2011 Free Software +# Foundation, Inc. +# Written by Gordon Matzigkeit, 1996 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +m4_define([_LT_COPYING], [dnl +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, +# 2006, 2007, 2008, 2009, 2010, 2011 Free Software +# Foundation, Inc. +# Written by Gordon Matzigkeit, 1996 +# +# This file is part of GNU Libtool. +# +# GNU Libtool 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 of +# the License, or (at your option) any later version. +# +# As a special exception to the GNU General Public License, +# if you distribute this file as part of a program or library that +# is built using GNU Libtool, you may include this file under the +# same distribution terms that you use for the rest of that program. +# +# GNU Libtool 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. +# +# You should have received a copy of the GNU General Public License +# along with GNU Libtool; see the file COPYING. If not, a copy +# can be downloaded from http://www.gnu.org/licenses/gpl.html, or +# obtained by writing to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +]) + +# serial 57 LT_INIT + + +# LT_PREREQ(VERSION) +# ------------------ +# Complain and exit if this libtool version is less that VERSION. +m4_defun([LT_PREREQ], +[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, + [m4_default([$3], + [m4_fatal([Libtool version $1 or higher is required], + 63)])], + [$2])]) + + +# _LT_CHECK_BUILDDIR +# ------------------ +# Complain if the absolute build directory name contains unusual characters +m4_defun([_LT_CHECK_BUILDDIR], +[case `pwd` in + *\ * | *\ *) + AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; +esac +]) + + +# LT_INIT([OPTIONS]) +# ------------------ +AC_DEFUN([LT_INIT], +[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT +AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl +AC_BEFORE([$0], [LT_LANG])dnl +AC_BEFORE([$0], [LT_OUTPUT])dnl +AC_BEFORE([$0], [LTDL_INIT])dnl +m4_require([_LT_CHECK_BUILDDIR])dnl + +dnl Autoconf doesn't catch unexpanded LT_ macros by default: +m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl +m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl +dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 +dnl unless we require an AC_DEFUNed macro: +AC_REQUIRE([LTOPTIONS_VERSION])dnl +AC_REQUIRE([LTSUGAR_VERSION])dnl +AC_REQUIRE([LTVERSION_VERSION])dnl +AC_REQUIRE([LTOBSOLETE_VERSION])dnl +m4_require([_LT_PROG_LTMAIN])dnl + +_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) + +dnl Parse OPTIONS +_LT_SET_OPTIONS([$0], [$1]) + +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS="$ltmain" + +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' +AC_SUBST(LIBTOOL)dnl + +_LT_SETUP + +# Only expand once: +m4_define([LT_INIT]) +])# LT_INIT + +# Old names: +AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) +AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_PROG_LIBTOOL], []) +dnl AC_DEFUN([AM_PROG_LIBTOOL], []) + + +# _LT_CC_BASENAME(CC) +# ------------------- +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +m4_defun([_LT_CC_BASENAME], +[for cc_temp in $1""; do + case $cc_temp in + compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; + distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +]) + + +# _LT_FILEUTILS_DEFAULTS +# ---------------------- +# It is okay to use these file commands and assume they have been set +# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. +m4_defun([_LT_FILEUTILS_DEFAULTS], +[: ${CP="cp -f"} +: ${MV="mv -f"} +: ${RM="rm -f"} +])# _LT_FILEUTILS_DEFAULTS + + +# _LT_SETUP +# --------- +m4_defun([_LT_SETUP], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl + +_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl +dnl +_LT_DECL([], [host_alias], [0], [The host system])dnl +_LT_DECL([], [host], [0])dnl +_LT_DECL([], [host_os], [0])dnl +dnl +_LT_DECL([], [build_alias], [0], [The build system])dnl +_LT_DECL([], [build], [0])dnl +_LT_DECL([], [build_os], [0])dnl +dnl +AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([LT_PATH_LD])dnl +AC_REQUIRE([LT_PATH_NM])dnl +dnl +AC_REQUIRE([AC_PROG_LN_S])dnl +test -z "$LN_S" && LN_S="ln -s" +_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl +dnl +AC_REQUIRE([LT_CMD_MAX_LEN])dnl +_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl +_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl +dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_CHECK_SHELL_FEATURES])dnl +m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl +m4_require([_LT_CMD_RELOAD])dnl +m4_require([_LT_CHECK_MAGIC_METHOD])dnl +m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl +m4_require([_LT_CMD_OLD_ARCHIVE])dnl +m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl +m4_require([_LT_WITH_SYSROOT])dnl + +_LT_CONFIG_LIBTOOL_INIT([ +# See if we are running on zsh, and set the options which allow our +# commands through without removal of \ escapes INIT. +if test -n "\${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi +]) +if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi + +_LT_CHECK_OBJDIR + +m4_require([_LT_TAG_COMPILER])dnl + +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac + +# Global variables: +ofile=libtool +can_build_shared=yes + +# All known linkers require a `.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a + +with_gnu_ld="$lt_cv_prog_gnu_ld" + +old_CC="$CC" +old_CFLAGS="$CFLAGS" + +# Set sane defaults for various variables +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$LD" && LD=ld +test -z "$ac_objext" && ac_objext=o + +_LT_CC_BASENAME([$compiler]) + +# Only perform the check for file, if the check method requires it +test -z "$MAGIC_CMD" && MAGIC_CMD=file +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + _LT_PATH_MAGIC + fi + ;; +esac + +# Use C for the default configuration in the libtool script +LT_SUPPORTED_TAG([CC]) +_LT_LANG_C_CONFIG +_LT_LANG_DEFAULT_CONFIG +_LT_CONFIG_COMMANDS +])# _LT_SETUP + + +# _LT_PREPARE_SED_QUOTE_VARS +# -------------------------- +# Define a few sed substitution that help us do robust quoting. +m4_defun([_LT_PREPARE_SED_QUOTE_VARS], +[# Backslashify metacharacters that are still active within +# double-quoted strings. +sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' + +# Same as above, but do not quote variable references. +double_quote_subst='s/\([["`\\]]\)/\\\1/g' + +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' + +# Sed substitution to delay expansion of an escaped single quote. +delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' + +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' +]) + +# _LT_PROG_LTMAIN +# --------------- +# Note that this code is called both from `configure', and `config.status' +# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, +# `config.status' has no value for ac_aux_dir unless we are using Automake, +# so we pass a copy along to make sure it has a sensible value anyway. +m4_defun([_LT_PROG_LTMAIN], +[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl +_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) +ltmain="$ac_aux_dir/ltmain.sh" +])# _LT_PROG_LTMAIN + + +## ------------------------------------- ## +## Accumulate code for creating libtool. ## +## ------------------------------------- ## + +# So that we can recreate a full libtool script including additional +# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS +# in macros and then make a single call at the end using the `libtool' +# label. + + +# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) +# ---------------------------------------- +# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. +m4_define([_LT_CONFIG_LIBTOOL_INIT], +[m4_ifval([$1], + [m4_append([_LT_OUTPUT_LIBTOOL_INIT], + [$1 +])])]) + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_INIT]) + + +# _LT_CONFIG_LIBTOOL([COMMANDS]) +# ------------------------------ +# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. +m4_define([_LT_CONFIG_LIBTOOL], +[m4_ifval([$1], + [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], + [$1 +])])]) + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) + + +# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) +# ----------------------------------------------------- +m4_defun([_LT_CONFIG_SAVE_COMMANDS], +[_LT_CONFIG_LIBTOOL([$1]) +_LT_CONFIG_LIBTOOL_INIT([$2]) +]) + + +# _LT_FORMAT_COMMENT([COMMENT]) +# ----------------------------- +# Add leading comment marks to the start of each line, and a trailing +# full-stop to the whole comment if one is not present already. +m4_define([_LT_FORMAT_COMMENT], +[m4_ifval([$1], [ +m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], + [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) +)]) + + + +## ------------------------ ## +## FIXME: Eliminate VARNAME ## +## ------------------------ ## + + +# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) +# ------------------------------------------------------------------- +# CONFIGNAME is the name given to the value in the libtool script. +# VARNAME is the (base) name used in the configure script. +# VALUE may be 0, 1 or 2 for a computed quote escaped value based on +# VARNAME. Any other value will be used directly. +m4_define([_LT_DECL], +[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], + [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], + [m4_ifval([$1], [$1], [$2])]) + lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) + m4_ifval([$4], + [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) + lt_dict_add_subkey([lt_decl_dict], [$2], + [tagged?], [m4_ifval([$5], [yes], [no])])]) +]) + + +# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) +# -------------------------------------------------------- +m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) + + +# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) +# ------------------------------------------------ +m4_define([lt_decl_tag_varnames], +[_lt_decl_filter([tagged?], [yes], $@)]) + + +# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) +# --------------------------------------------------------- +m4_define([_lt_decl_filter], +[m4_case([$#], + [0], [m4_fatal([$0: too few arguments: $#])], + [1], [m4_fatal([$0: too few arguments: $#: $1])], + [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], + [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], + [lt_dict_filter([lt_decl_dict], $@)])[]dnl +]) + + +# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) +# -------------------------------------------------- +m4_define([lt_decl_quote_varnames], +[_lt_decl_filter([value], [1], $@)]) + + +# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) +# --------------------------------------------------- +m4_define([lt_decl_dquote_varnames], +[_lt_decl_filter([value], [2], $@)]) + + +# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) +# --------------------------------------------------- +m4_define([lt_decl_varnames_tagged], +[m4_assert([$# <= 2])dnl +_$0(m4_quote(m4_default([$1], [[, ]])), + m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), + m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) +m4_define([_lt_decl_varnames_tagged], +[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) + + +# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) +# ------------------------------------------------ +m4_define([lt_decl_all_varnames], +[_$0(m4_quote(m4_default([$1], [[, ]])), + m4_if([$2], [], + m4_quote(lt_decl_varnames), + m4_quote(m4_shift($@))))[]dnl +]) +m4_define([_lt_decl_all_varnames], +[lt_join($@, lt_decl_varnames_tagged([$1], + lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl +]) + + +# _LT_CONFIG_STATUS_DECLARE([VARNAME]) +# ------------------------------------ +# Quote a variable value, and forward it to `config.status' so that its +# declaration there will have the same value as in `configure'. VARNAME +# must have a single quote delimited value for this to work. +m4_define([_LT_CONFIG_STATUS_DECLARE], +[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) + + +# _LT_CONFIG_STATUS_DECLARATIONS +# ------------------------------ +# We delimit libtool config variables with single quotes, so when +# we write them to config.status, we have to be sure to quote all +# embedded single quotes properly. In configure, this macro expands +# each variable declared with _LT_DECL (and _LT_TAGDECL) into: +# +# <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`' +m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], +[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), + [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) + + +# _LT_LIBTOOL_TAGS +# ---------------- +# Output comment and list of tags supported by the script +m4_defun([_LT_LIBTOOL_TAGS], +[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl +available_tags="_LT_TAGS"dnl +]) + + +# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) +# ----------------------------------- +# Extract the dictionary values for VARNAME (optionally with TAG) and +# expand to a commented shell variable setting: +# +# # Some comment about what VAR is for. +# visible_name=$lt_internal_name +m4_define([_LT_LIBTOOL_DECLARE], +[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], + [description])))[]dnl +m4_pushdef([_libtool_name], + m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl +m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), + [0], [_libtool_name=[$]$1], + [1], [_libtool_name=$lt_[]$1], + [2], [_libtool_name=$lt_[]$1], + [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl +m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl +]) + + +# _LT_LIBTOOL_CONFIG_VARS +# ----------------------- +# Produce commented declarations of non-tagged libtool config variables +# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' +# script. Tagged libtool config variables (even for the LIBTOOL CONFIG +# section) are produced by _LT_LIBTOOL_TAG_VARS. +m4_defun([_LT_LIBTOOL_CONFIG_VARS], +[m4_foreach([_lt_var], + m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), + [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) + + +# _LT_LIBTOOL_TAG_VARS(TAG) +# ------------------------- +m4_define([_LT_LIBTOOL_TAG_VARS], +[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), + [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) + + +# _LT_TAGVAR(VARNAME, [TAGNAME]) +# ------------------------------ +m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) + + +# _LT_CONFIG_COMMANDS +# ------------------- +# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of +# variables for single and double quote escaping we saved from calls +# to _LT_DECL, we can put quote escaped variables declarations +# into `config.status', and then the shell code to quote escape them in +# for loops in `config.status'. Finally, any additional code accumulated +# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. +m4_defun([_LT_CONFIG_COMMANDS], +[AC_PROVIDE_IFELSE([LT_OUTPUT], + dnl If the libtool generation code has been placed in $CONFIG_LT, + dnl instead of duplicating it all over again into config.status, + dnl then we will have config.status run $CONFIG_LT later, so it + dnl needs to know what name is stored there: + [AC_CONFIG_COMMANDS([libtool], + [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], + dnl If the libtool generation code is destined for config.status, + dnl expand the accumulated commands and init code now: + [AC_CONFIG_COMMANDS([libtool], + [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) +])#_LT_CONFIG_COMMANDS + + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], +[ + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +sed_quote_subst='$sed_quote_subst' +double_quote_subst='$double_quote_subst' +delay_variable_subst='$delay_variable_subst' +_LT_CONFIG_STATUS_DECLARATIONS +LTCC='$LTCC' +LTCFLAGS='$LTCFLAGS' +compiler='$compiler_DEFAULT' + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$[]1 +_LTECHO_EOF' +} + +# Quote evaled strings. +for var in lt_decl_all_varnames([[ \ +]], lt_decl_quote_varnames); do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[[\\\\\\\`\\"\\\$]]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +# Double-quote double-evaled strings. +for var in lt_decl_all_varnames([[ \ +]], lt_decl_dquote_varnames); do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[[\\\\\\\`\\"\\\$]]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +_LT_OUTPUT_LIBTOOL_INIT +]) + +# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) +# ------------------------------------ +# Generate a child script FILE with all initialization necessary to +# reuse the environment learned by the parent script, and make the +# file executable. If COMMENT is supplied, it is inserted after the +# `#!' sequence but before initialization text begins. After this +# macro, additional text can be appended to FILE to form the body of +# the child script. The macro ends with non-zero status if the +# file could not be fully written (such as if the disk is full). +m4_ifdef([AS_INIT_GENERATED], +[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], +[m4_defun([_LT_GENERATED_FILE_INIT], +[m4_require([AS_PREPARE])]dnl +[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl +[lt_write_fail=0 +cat >$1 <<_ASEOF || lt_write_fail=1 +#! $SHELL +# Generated by $as_me. +$2 +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$1 <<\_ASEOF || lt_write_fail=1 +AS_SHELL_SANITIZE +_AS_PREPARE +exec AS_MESSAGE_FD>&1 +_ASEOF +test $lt_write_fail = 0 && chmod +x $1[]dnl +m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT + +# LT_OUTPUT +# --------- +# This macro allows early generation of the libtool script (before +# AC_OUTPUT is called), incase it is used in configure for compilation +# tests. +AC_DEFUN([LT_OUTPUT], +[: ${CONFIG_LT=./config.lt} +AC_MSG_NOTICE([creating $CONFIG_LT]) +_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], +[# Run this file to recreate a libtool stub with the current configuration.]) + +cat >>"$CONFIG_LT" <<\_LTEOF +lt_cl_silent=false +exec AS_MESSAGE_LOG_FD>>config.log +{ + echo + AS_BOX([Running $as_me.]) +} >&AS_MESSAGE_LOG_FD + +lt_cl_help="\ +\`$as_me' creates a local libtool stub from the current configuration, +for use in further configure time tests before the real libtool is +generated. + +Usage: $[0] [[OPTIONS]] + + -h, --help print this help, then exit + -V, --version print version number, then exit + -q, --quiet do not print progress messages + -d, --debug don't remove temporary files + +Report bugs to <bug-libtool@gnu.org>." + +lt_cl_version="\ +m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl +m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) +configured by $[0], generated by m4_PACKAGE_STRING. + +Copyright (C) 2011 Free Software Foundation, Inc. +This config.lt script is free software; the Free Software Foundation +gives unlimited permision to copy, distribute and modify it." + +while test $[#] != 0 +do + case $[1] in + --version | --v* | -V ) + echo "$lt_cl_version"; exit 0 ;; + --help | --h* | -h ) + echo "$lt_cl_help"; exit 0 ;; + --debug | --d* | -d ) + debug=: ;; + --quiet | --q* | --silent | --s* | -q ) + lt_cl_silent=: ;; + + -*) AC_MSG_ERROR([unrecognized option: $[1] +Try \`$[0] --help' for more information.]) ;; + + *) AC_MSG_ERROR([unrecognized argument: $[1] +Try \`$[0] --help' for more information.]) ;; + esac + shift +done + +if $lt_cl_silent; then + exec AS_MESSAGE_FD>/dev/null +fi +_LTEOF + +cat >>"$CONFIG_LT" <<_LTEOF +_LT_OUTPUT_LIBTOOL_COMMANDS_INIT +_LTEOF + +cat >>"$CONFIG_LT" <<\_LTEOF +AC_MSG_NOTICE([creating $ofile]) +_LT_OUTPUT_LIBTOOL_COMMANDS +AS_EXIT(0) +_LTEOF +chmod +x "$CONFIG_LT" + +# configure is writing to config.log, but config.lt does its own redirection, +# appending to config.log, which fails on DOS, as config.log is still kept +# open by configure. Here we exec the FD to /dev/null, effectively closing +# config.log, so it can be properly (re)opened and appended to by config.lt. +lt_cl_success=: +test "$silent" = yes && + lt_config_lt_args="$lt_config_lt_args --quiet" +exec AS_MESSAGE_LOG_FD>/dev/null +$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false +exec AS_MESSAGE_LOG_FD>>config.log +$lt_cl_success || AS_EXIT(1) +])# LT_OUTPUT + + +# _LT_CONFIG(TAG) +# --------------- +# If TAG is the built-in tag, create an initial libtool script with a +# default configuration from the untagged config vars. Otherwise add code +# to config.status for appending the configuration named by TAG from the +# matching tagged config vars. +m4_defun([_LT_CONFIG], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +_LT_CONFIG_SAVE_COMMANDS([ + m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl + m4_if(_LT_TAG, [C], [ + # See if we are running on zsh, and set the options which allow our + # commands through without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + + cfgfile="${ofile}T" + trap "$RM \"$cfgfile\"; exit 1" 1 2 15 + $RM "$cfgfile" + + cat <<_LT_EOF >> "$cfgfile" +#! $SHELL + +# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. +# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# NOTE: Changes made to this file will be lost: look at ltmain.sh. +# +_LT_COPYING +_LT_LIBTOOL_TAGS + +# ### BEGIN LIBTOOL CONFIG +_LT_LIBTOOL_CONFIG_VARS +_LT_LIBTOOL_TAG_VARS +# ### END LIBTOOL CONFIG + +_LT_EOF + + case $host_os in + aix3*) + cat <<\_LT_EOF >> "$cfgfile" +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +_LT_EOF + ;; + esac + + _LT_PROG_LTMAIN + + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) + + _LT_PROG_REPLACE_SHELLFNS + + mv -f "$cfgfile" "$ofile" || + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" +], +[cat <<_LT_EOF >> "$ofile" + +dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded +dnl in a comment (ie after a #). +# ### BEGIN LIBTOOL TAG CONFIG: $1 +_LT_LIBTOOL_TAG_VARS(_LT_TAG) +# ### END LIBTOOL TAG CONFIG: $1 +_LT_EOF +])dnl /m4_if +], +[m4_if([$1], [], [ + PACKAGE='$PACKAGE' + VERSION='$VERSION' + TIMESTAMP='$TIMESTAMP' + RM='$RM' + ofile='$ofile'], []) +])dnl /_LT_CONFIG_SAVE_COMMANDS +])# _LT_CONFIG + + +# LT_SUPPORTED_TAG(TAG) +# --------------------- +# Trace this macro to discover what tags are supported by the libtool +# --tag option, using: +# autoconf --trace 'LT_SUPPORTED_TAG:$1' +AC_DEFUN([LT_SUPPORTED_TAG], []) + + +# C support is built-in for now +m4_define([_LT_LANG_C_enabled], []) +m4_define([_LT_TAGS], []) + + +# LT_LANG(LANG) +# ------------- +# Enable libtool support for the given language if not already enabled. +AC_DEFUN([LT_LANG], +[AC_BEFORE([$0], [LT_OUTPUT])dnl +m4_case([$1], + [C], [_LT_LANG(C)], + [C++], [_LT_LANG(CXX)], + [Go], [_LT_LANG(GO)], + [Java], [_LT_LANG(GCJ)], + [Fortran 77], [_LT_LANG(F77)], + [Fortran], [_LT_LANG(FC)], + [Windows Resource], [_LT_LANG(RC)], + [m4_ifdef([_LT_LANG_]$1[_CONFIG], + [_LT_LANG($1)], + [m4_fatal([$0: unsupported language: "$1"])])])dnl +])# LT_LANG + + +# _LT_LANG(LANGNAME) +# ------------------ +m4_defun([_LT_LANG], +[m4_ifdef([_LT_LANG_]$1[_enabled], [], + [LT_SUPPORTED_TAG([$1])dnl + m4_append([_LT_TAGS], [$1 ])dnl + m4_define([_LT_LANG_]$1[_enabled], [])dnl + _LT_LANG_$1_CONFIG($1)])dnl +])# _LT_LANG + + +m4_ifndef([AC_PROG_GO], [ +############################################################ +# NOTE: This macro has been submitted for inclusion into # +# GNU Autoconf as AC_PROG_GO. When it is available in # +# a released version of Autoconf we should remove this # +# macro and use it instead. # +############################################################ +m4_defun([AC_PROG_GO], +[AC_LANG_PUSH(Go)dnl +AC_ARG_VAR([GOC], [Go compiler command])dnl +AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl +_AC_ARG_VAR_LDFLAGS()dnl +AC_CHECK_TOOL(GOC, gccgo) +if test -z "$GOC"; then + if test -n "$ac_tool_prefix"; then + AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) + fi +fi +if test -z "$GOC"; then + AC_CHECK_PROG(GOC, gccgo, gccgo, false) +fi +])#m4_defun +])#m4_ifndef + + +# _LT_LANG_DEFAULT_CONFIG +# ----------------------- +m4_defun([_LT_LANG_DEFAULT_CONFIG], +[AC_PROVIDE_IFELSE([AC_PROG_CXX], + [LT_LANG(CXX)], + [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) + +AC_PROVIDE_IFELSE([AC_PROG_F77], + [LT_LANG(F77)], + [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) + +AC_PROVIDE_IFELSE([AC_PROG_FC], + [LT_LANG(FC)], + [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) + +dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal +dnl pulling things in needlessly. +AC_PROVIDE_IFELSE([AC_PROG_GCJ], + [LT_LANG(GCJ)], + [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], + [LT_LANG(GCJ)], + [AC_PROVIDE_IFELSE([LT_PROG_GCJ], + [LT_LANG(GCJ)], + [m4_ifdef([AC_PROG_GCJ], + [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) + m4_ifdef([A][M_PROG_GCJ], + [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) + m4_ifdef([LT_PROG_GCJ], + [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) + +AC_PROVIDE_IFELSE([AC_PROG_GO], + [LT_LANG(GO)], + [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) + +AC_PROVIDE_IFELSE([LT_PROG_RC], + [LT_LANG(RC)], + [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) +])# _LT_LANG_DEFAULT_CONFIG + +# Obsolete macros: +AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) +AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) +AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) +AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) +AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_CXX], []) +dnl AC_DEFUN([AC_LIBTOOL_F77], []) +dnl AC_DEFUN([AC_LIBTOOL_FC], []) +dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) +dnl AC_DEFUN([AC_LIBTOOL_RC], []) + + +# _LT_TAG_COMPILER +# ---------------- +m4_defun([_LT_TAG_COMPILER], +[AC_REQUIRE([AC_PROG_CC])dnl + +_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl +_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl +_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl +_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC +])# _LT_TAG_COMPILER + + +# _LT_COMPILER_BOILERPLATE +# ------------------------ +# Check for compiler boilerplate output or warnings with +# the simple compiler test code. +m4_defun([_LT_COMPILER_BOILERPLATE], +[m4_require([_LT_DECL_SED])dnl +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* +])# _LT_COMPILER_BOILERPLATE + + +# _LT_LINKER_BOILERPLATE +# ---------------------- +# Check for linker boilerplate output or warnings with +# the simple link test code. +m4_defun([_LT_LINKER_BOILERPLATE], +[m4_require([_LT_DECL_SED])dnl +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* +])# _LT_LINKER_BOILERPLATE + +# _LT_REQUIRED_DARWIN_CHECKS +# ------------------------- +m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ + case $host_os in + rhapsody* | darwin*) + AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) + AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) + AC_CHECK_TOOL([LIPO], [lipo], [:]) + AC_CHECK_TOOL([OTOOL], [otool], [:]) + AC_CHECK_TOOL([OTOOL64], [otool64], [:]) + _LT_DECL([], [DSYMUTIL], [1], + [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) + _LT_DECL([], [NMEDIT], [1], + [Tool to change global to local symbols on Mac OS X]) + _LT_DECL([], [LIPO], [1], + [Tool to manipulate fat objects and archives on Mac OS X]) + _LT_DECL([], [OTOOL], [1], + [ldd/readelf like tool for Mach-O binaries on Mac OS X]) + _LT_DECL([], [OTOOL64], [1], + [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) + + AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], + [lt_cv_apple_cc_single_mod=no + if test -z "${LT_MULTI_MODULE}"; then + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + rm -rf libconftest.dylib* + echo "int foo(void){return 1;}" > conftest.c + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ +-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err + _lt_result=$? + # If there is a non-empty error log, and "single_module" + # appears in it, assume the flag caused a linker warning + if test -s conftest.err && $GREP single_module conftest.err; then + cat conftest.err >&AS_MESSAGE_LOG_FD + # Otherwise, if the output was created with a 0 exit code from + # the compiler, it worked. + elif test -f libconftest.dylib && test $_lt_result -eq 0; then + lt_cv_apple_cc_single_mod=yes + else + cat conftest.err >&AS_MESSAGE_LOG_FD + fi + rm -rf libconftest.dylib* + rm -f conftest.* + fi]) + + AC_CACHE_CHECK([for -exported_symbols_list linker flag], + [lt_cv_ld_exported_symbols_list], + [lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], + [lt_cv_ld_exported_symbols_list=yes], + [lt_cv_ld_exported_symbols_list=no]) + LDFLAGS="$save_LDFLAGS" + ]) + + AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], + [lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD + echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD + $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD + echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD + $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -s conftest.err && $GREP force_load conftest.err; then + cat conftest.err >&AS_MESSAGE_LOG_FD + elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&AS_MESSAGE_LOG_FD + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + ]) + case $host_os in + rhapsody* | darwin1.[[012]]) + _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; + darwin1.*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + darwin*) # darwin 5.x on + # if running on 10.5 or later, the deployment target defaults + # to the OS version, if on x86, and 10.4, the deployment + # target defaults to 10.4. Don't you love it? + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + 10.[[012]]*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + esac + ;; + esac + if test "$lt_cv_apple_cc_single_mod" = "yes"; then + _lt_dar_single_mod='$single_module' + fi + if test "$lt_cv_ld_exported_symbols_list" = "yes"; then + _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' + else + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' + fi + if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then + _lt_dsymutil='~$DSYMUTIL $lib || :' + else + _lt_dsymutil= + fi + ;; + esac +]) + + +# _LT_DARWIN_LINKER_FEATURES([TAG]) +# --------------------------------- +# Checks for linker and compiler features on darwin +m4_defun([_LT_DARWIN_LINKER_FEATURES], +[ + m4_require([_LT_REQUIRED_DARWIN_CHECKS]) + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_automatic, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported + if test "$lt_cv_ld_force_load" = "yes"; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], + [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) + else + _LT_TAGVAR(whole_archive_flag_spec, $1)='' + fi + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" + case $cc_basename in + ifort*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test "$_lt_dar_can_shared" = "yes"; then + output_verbose_link_cmd=func_echo_all + _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + m4_if([$1], [CXX], +[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then + _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" + fi +],[]) + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi +]) + +# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) +# ---------------------------------- +# Links a minimal program and checks the executable +# for the system default hardcoded library path. In most cases, +# this is /usr/lib:/lib, but when the MPI compilers are used +# the location of the communication and MPI libs are included too. +# If we don't find anything, use the default library path according +# to the aix ld manual. +# Store the results from the different compilers for each TAGNAME. +# Allow to override them for all tags through lt_cv_aix_libpath. +m4_defun([_LT_SYS_MODULE_PATH_AIX], +[m4_require([_LT_DECL_SED])dnl +if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], + [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ + lt_aix_libpath_sed='[ + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }]' + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi],[]) + if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib" + fi + ]) + aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) +fi +])# _LT_SYS_MODULE_PATH_AIX + + +# _LT_SHELL_INIT(ARG) +# ------------------- +m4_define([_LT_SHELL_INIT], +[m4_divert_text([M4SH-INIT], [$1 +])])# _LT_SHELL_INIT + + + +# _LT_PROG_ECHO_BACKSLASH +# ----------------------- +# Find how we can fake an echo command that does not interpret backslash. +# In particular, with Autoconf 2.60 or later we add some code to the start +# of the generated configure script which will find a shell with a builtin +# printf (which we can use as an echo command). +m4_defun([_LT_PROG_ECHO_BACKSLASH], +[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + +AC_MSG_CHECKING([how to print strings]) +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' +else + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$[]1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' +fi + +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "$*" +} + +case "$ECHO" in + printf*) AC_MSG_RESULT([printf]) ;; + print*) AC_MSG_RESULT([print -r]) ;; + *) AC_MSG_RESULT([cat]) ;; +esac + +m4_ifdef([_AS_DETECT_SUGGESTED], +[_AS_DETECT_SUGGESTED([ + test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO + ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test "X`printf %s $ECHO`" = "X$ECHO" \ + || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) + +_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) +_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) +])# _LT_PROG_ECHO_BACKSLASH + + +# _LT_WITH_SYSROOT +# ---------------- +AC_DEFUN([_LT_WITH_SYSROOT], +[AC_MSG_CHECKING([for sysroot]) +AC_ARG_WITH([sysroot], +[ --with-sysroot[=DIR] Search for dependent libraries within DIR + (or the compiler's sysroot if not specified).], +[], [with_sysroot=no]) + +dnl lt_sysroot will always be passed unquoted. We quote it here +dnl in case the user passed a directory name. +lt_sysroot= +case ${with_sysroot} in #( + yes) + if test "$GCC" = yes; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` + fi + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + AC_MSG_RESULT([${with_sysroot}]) + AC_MSG_ERROR([The sysroot must be an absolute path.]) + ;; +esac + + AC_MSG_RESULT([${lt_sysroot:-no}]) +_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl +[dependent libraries, and in which our libraries should be installed.])]) + +# _LT_ENABLE_LOCK +# --------------- +m4_defun([_LT_ENABLE_LOCK], +[AC_ARG_ENABLE([libtool-lock], + [AS_HELP_STRING([--disable-libtool-lock], + [avoid locking (might break parallel builds)])]) +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes + +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE="32" + ;; + *ELF-64*) + HPUX_IA64_MODE="64" + ;; + esac + fi + rm -rf conftest* + ;; +*-*-irix6*) + # Find out which ABI we are using. + echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + if test "$lt_cv_prog_gnu_ld" = yes; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ +s390*-*linux*|s390*-*tpf*|sparc*-*linux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + case `/usr/bin/file conftest.o` in + *x86-64*) + LD="${LD-ld} -m elf32_x86_64" + ;; + *) + LD="${LD-ld} -m elf_i386" + ;; + esac + ;; + powerpc64le-*) + LD="${LD-ld} -m elf32lppclinux" + ;; + powerpc64-*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + powerpcle-*) + LD="${LD-ld} -m elf64lppc" + ;; + powerpc-*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*|s390*-*tpf*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; + +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -belf" + AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, + [AC_LANG_PUSH(C) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) + AC_LANG_POP]) + if test x"$lt_cv_cc_needs_belf" != x"yes"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS="$SAVE_CFLAGS" + fi + ;; +*-*solaris*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) + case $host in + i?86-*-solaris*) + LD="${LD-ld} -m elf_x86_64" + ;; + sparc*-*-solaris*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + # GNU ld 2.21 introduced _sol2 emulations. Use them if available. + if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then + LD="${LD-ld}_sol2" + fi + ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; +esac + +need_locks="$enable_libtool_lock" +])# _LT_ENABLE_LOCK + + +# _LT_PROG_AR +# ----------- +m4_defun([_LT_PROG_AR], +[AC_CHECK_TOOLS(AR, [ar], false) +: ${AR=ar} +: ${AR_FLAGS=cru} +_LT_DECL([], [AR], [1], [The archiver]) +_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) + +AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], + [lt_cv_ar_at_file=no + AC_COMPILE_IFELSE([AC_LANG_PROGRAM], + [echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' + AC_TRY_EVAL([lt_ar_try]) + if test "$ac_status" -eq 0; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + AC_TRY_EVAL([lt_ar_try]) + if test "$ac_status" -ne 0; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a + ]) + ]) + +if test "x$lt_cv_ar_at_file" = xno; then + archiver_list_spec= +else + archiver_list_spec=$lt_cv_ar_at_file +fi +_LT_DECL([], [archiver_list_spec], [1], + [How to feed a file listing to the archiver]) +])# _LT_PROG_AR + + +# _LT_CMD_OLD_ARCHIVE +# ------------------- +m4_defun([_LT_CMD_OLD_ARCHIVE], +[_LT_PROG_AR + +AC_CHECK_TOOL(STRIP, strip, :) +test -z "$STRIP" && STRIP=: +_LT_DECL([], [STRIP], [1], [A symbol stripping program]) + +AC_CHECK_TOOL(RANLIB, ranlib, :) +test -z "$RANLIB" && RANLIB=: +_LT_DECL([], [RANLIB], [1], + [Commands used to install an old-style archive]) + +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= + +if test -n "$RANLIB"; then + case $host_os in + openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" + ;; + *) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" +fi + +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac +_LT_DECL([], [old_postinstall_cmds], [2]) +_LT_DECL([], [old_postuninstall_cmds], [2]) +_LT_TAGDECL([], [old_archive_cmds], [2], + [Commands used to build an old-style archive]) +_LT_DECL([], [lock_old_archive_extraction], [0], + [Whether to use a lock for old archive extraction]) +])# _LT_CMD_OLD_ARCHIVE + + +# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, +# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) +# ---------------------------------------------------------------- +# Check whether the given compiler option works +AC_DEFUN([_LT_COMPILER_OPTION], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_SED])dnl +AC_CACHE_CHECK([$1], [$2], + [$2=no + m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$3" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&AS_MESSAGE_LOG_FD + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + $2=yes + fi + fi + $RM conftest* +]) + +if test x"[$]$2" = xyes; then + m4_if([$5], , :, [$5]) +else + m4_if([$6], , :, [$6]) +fi +])# _LT_COMPILER_OPTION + +# Old name: +AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) + + +# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, +# [ACTION-SUCCESS], [ACTION-FAILURE]) +# ---------------------------------------------------- +# Check whether the given linker option works +AC_DEFUN([_LT_LINKER_OPTION], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_SED])dnl +AC_CACHE_CHECK([$1], [$2], + [$2=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $3" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&AS_MESSAGE_LOG_FD + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + $2=yes + fi + else + $2=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" +]) + +if test x"[$]$2" = xyes; then + m4_if([$4], , :, [$4]) +else + m4_if([$5], , :, [$5]) +fi +])# _LT_LINKER_OPTION + +# Old name: +AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) + + +# LT_CMD_MAX_LEN +#--------------- +AC_DEFUN([LT_CMD_MAX_LEN], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +# find the maximum length of command line arguments +AC_MSG_CHECKING([the maximum length of command line arguments]) +AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl + i=0 + teststring="ABCD" + + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; + + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; + + cygwin* | mingw* | cegcc*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; + + mint*) + # On MiNT this can take a long time and run out of memory. + lt_cv_sys_max_cmd_len=8192; + ;; + + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; + + netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + + os2*) + # The test takes a long time on OS/2. + lt_cv_sys_max_cmd_len=8192 + ;; + + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi + ;; + *) + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len" && \ + test undefined != "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + # Make teststring a little bigger before we do anything with it. + # a 1K string should be a reasonable start. + for i in 1 2 3 4 5 6 7 8 ; do + teststring=$teststring$teststring + done + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + # If test is not a shell built-in, we'll probably end up computing a + # maximum length that is only half of the actual maximum length, but + # we can't tell. + while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \ + = "X$teststring$teststring"; } >/dev/null 2>&1 && + test $i != 17 # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + # Only check the string length outside the loop. + lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` + teststring= + # Add a significant safety factor because C++ compilers can tack on + # massive amounts of additional arguments before passing them to the + # linker. It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi + ;; + esac +]) +if test -n $lt_cv_sys_max_cmd_len ; then + AC_MSG_RESULT($lt_cv_sys_max_cmd_len) +else + AC_MSG_RESULT(none) +fi +max_cmd_len=$lt_cv_sys_max_cmd_len +_LT_DECL([], [max_cmd_len], [0], + [What is the maximum length of a command?]) +])# LT_CMD_MAX_LEN + +# Old name: +AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) + + +# _LT_HEADER_DLFCN +# ---------------- +m4_defun([_LT_HEADER_DLFCN], +[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl +])# _LT_HEADER_DLFCN + + +# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, +# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) +# ---------------------------------------------------------------- +m4_defun([_LT_TRY_DLOPEN_SELF], +[m4_require([_LT_HEADER_DLFCN])dnl +if test "$cross_compiling" = yes; then : + [$4] +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +[#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include <dlfcn.h> +#endif + +#include <stdio.h> + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +}] +_LT_EOF + if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) $1 ;; + x$lt_dlneed_uscore) $2 ;; + x$lt_dlunknown|x*) $3 ;; + esac + else : + # compilation failed + $3 + fi +fi +rm -fr conftest* +])# _LT_TRY_DLOPEN_SELF + + +# LT_SYS_DLOPEN_SELF +# ------------------ +AC_DEFUN([LT_SYS_DLOPEN_SELF], +[m4_require([_LT_HEADER_DLFCN])dnl +if test "x$enable_dlopen" != xyes; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen="load_add_on" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32* | cegcc*) + lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen="dlopen" + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + AC_CHECK_LIB([dl], [dlopen], + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ + lt_cv_dlopen="dyld" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ]) + ;; + + *) + AC_CHECK_FUNC([shl_load], + [lt_cv_dlopen="shl_load"], + [AC_CHECK_LIB([dld], [shl_load], + [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], + [AC_CHECK_FUNC([dlopen], + [lt_cv_dlopen="dlopen"], + [AC_CHECK_LIB([dl], [dlopen], + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], + [AC_CHECK_LIB([svld], [dlopen], + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], + [AC_CHECK_LIB([dld], [dld_link], + [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) + ]) + ]) + ]) + ]) + ]) + ;; + esac + + if test "x$lt_cv_dlopen" != xno; then + enable_dlopen=yes + else + enable_dlopen=no + fi + + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS="$CPPFLAGS" + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + + save_LDFLAGS="$LDFLAGS" + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + + save_LIBS="$LIBS" + LIBS="$lt_cv_dlopen_libs $LIBS" + + AC_CACHE_CHECK([whether a program can dlopen itself], + lt_cv_dlopen_self, [dnl + _LT_TRY_DLOPEN_SELF( + lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, + lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) + ]) + + if test "x$lt_cv_dlopen_self" = xyes; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + AC_CACHE_CHECK([whether a statically linked program can dlopen itself], + lt_cv_dlopen_self_static, [dnl + _LT_TRY_DLOPEN_SELF( + lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, + lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) + ]) + fi + + CPPFLAGS="$save_CPPFLAGS" + LDFLAGS="$save_LDFLAGS" + LIBS="$save_LIBS" + ;; + esac + + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi +_LT_DECL([dlopen_support], [enable_dlopen], [0], + [Whether dlopen is supported]) +_LT_DECL([dlopen_self], [enable_dlopen_self], [0], + [Whether dlopen of programs is supported]) +_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], + [Whether dlopen of statically linked programs is supported]) +])# LT_SYS_DLOPEN_SELF + +# Old name: +AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) + + +# _LT_COMPILER_C_O([TAGNAME]) +# --------------------------- +# Check to see if options -c and -o are simultaneously supported by compiler. +# This macro does not hard code the compiler like AC_PROG_CC_C_O. +m4_defun([_LT_COMPILER_C_O], +[m4_require([_LT_DECL_SED])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_TAG_COMPILER])dnl +AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], + [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], + [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&AS_MESSAGE_LOG_FD + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes + fi + fi + chmod u+w . 2>&AS_MESSAGE_LOG_FD + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* +]) +_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], + [Does compiler simultaneously support -c and -o options?]) +])# _LT_COMPILER_C_O + + +# _LT_COMPILER_FILE_LOCKS([TAGNAME]) +# ---------------------------------- +# Check to see if we can do hard links to lock some files if needed +m4_defun([_LT_COMPILER_FILE_LOCKS], +[m4_require([_LT_ENABLE_LOCK])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +_LT_COMPILER_C_O([$1]) + +hard_links="nottested" +if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + AC_MSG_CHECKING([if we can lock with hard links]) + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + AC_MSG_RESULT([$hard_links]) + if test "$hard_links" = no; then + AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) + need_locks=warn + fi +else + need_locks=no +fi +_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) +])# _LT_COMPILER_FILE_LOCKS + + +# _LT_CHECK_OBJDIR +# ---------------- +m4_defun([_LT_CHECK_OBJDIR], +[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], +[rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null]) +objdir=$lt_cv_objdir +_LT_DECL([], [objdir], [0], + [The name of the directory that contains temporary libtool files])dnl +m4_pattern_allow([LT_OBJDIR])dnl +AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", + [Define to the sub-directory in which libtool stores uninstalled libraries.]) +])# _LT_CHECK_OBJDIR + + +# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) +# -------------------------------------- +# Check hardcoding attributes. +m4_defun([_LT_LINKER_HARDCODE_LIBPATH], +[AC_MSG_CHECKING([how to hardcode library paths into programs]) +_LT_TAGVAR(hardcode_action, $1)= +if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || + test -n "$_LT_TAGVAR(runpath_var, $1)" || + test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then + + # We can hardcode non-existent directories. + if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && + test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then + # Linking always hardcodes the temporary library directory. + _LT_TAGVAR(hardcode_action, $1)=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + _LT_TAGVAR(hardcode_action, $1)=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + _LT_TAGVAR(hardcode_action, $1)=unsupported +fi +AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) + +if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || + test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi +_LT_TAGDECL([], [hardcode_action], [0], + [How to hardcode a shared library path into an executable]) +])# _LT_LINKER_HARDCODE_LIBPATH + + +# _LT_CMD_STRIPLIB +# ---------------- +m4_defun([_LT_CMD_STRIPLIB], +[m4_require([_LT_DECL_EGREP]) +striplib= +old_striplib= +AC_MSG_CHECKING([whether stripping libraries is possible]) +if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + AC_MSG_RESULT([yes]) +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP" ; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + fi + ;; + *) + AC_MSG_RESULT([no]) + ;; + esac +fi +_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) +_LT_DECL([], [striplib], [1]) +])# _LT_CMD_STRIPLIB + + +# _LT_SYS_DYNAMIC_LINKER([TAG]) +# ----------------------------- +# PORTME Fill in your ld.so characteristics +m4_defun([_LT_SYS_DYNAMIC_LINKER], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_OBJDUMP])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_CHECK_SHELL_FEATURES])dnl +AC_MSG_CHECKING([dynamic linker characteristics]) +m4_if([$1], + [], [ +if test "$GCC" = yes; then + case $host_os in + darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; + *) lt_awk_arg="/^libraries:/" ;; + esac + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;; + *) lt_sed_strip_eq="s,=/,/,g" ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary. + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path/$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" + else + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' +BEGIN {RS=" "; FS="/|\n";} { + lt_foo=""; + lt_count=0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo="/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[[lt_foo]]++; } + if (lt_freq[[lt_foo]] == 1) { print lt_foo; } +}'` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's,/\([[A-Za-z]]:\),\1,g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi]) +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +case $host_os in +aix3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; + +aix[[4-9]]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[[01]] | aix4.[[01]].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib<name>.so + # instead of lib<name>.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; + esac + ;; + +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[[45]]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' +m4_if([$1], [],[ + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + library_names_spec='${libname}.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec="$LIB" + if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' +m4_if([$1], [],[ + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[[23]].*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2.*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[[01]]* | freebsdelf3.[[01]]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ + freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +haiku*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=yes + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[[3-9]]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux # correct to gnu/linux during the next big refactor + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], + [lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ + LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" + AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], + [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], + [lt_cv_shlibpath_overrides_runpath=yes])]) + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + ]) + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[[89]] | openbsd2.[[89]].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; + +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +AC_MSG_RESULT([$dynamic_linker]) +test "$dynamic_linker" = no && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +fi +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +fi + +_LT_DECL([], [variables_saved_for_relink], [1], + [Variables whose values should be saved in libtool wrapper scripts and + restored at link time]) +_LT_DECL([], [need_lib_prefix], [0], + [Do we need the "lib" prefix for modules?]) +_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) +_LT_DECL([], [version_type], [0], [Library versioning type]) +_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) +_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) +_LT_DECL([], [shlibpath_overrides_runpath], [0], + [Is shlibpath searched before the hard-coded library search path?]) +_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) +_LT_DECL([], [library_names_spec], [1], + [[List of archive names. First name is the real one, the rest are links. + The last name is the one that the linker finds with -lNAME]]) +_LT_DECL([], [soname_spec], [1], + [[The coded name of the library, if different from the real name]]) +_LT_DECL([], [install_override_mode], [1], + [Permission mode override for installation of shared libraries]) +_LT_DECL([], [postinstall_cmds], [2], + [Command to use after installation of a shared archive]) +_LT_DECL([], [postuninstall_cmds], [2], + [Command to use after uninstallation of a shared archive]) +_LT_DECL([], [finish_cmds], [2], + [Commands used to finish a libtool library installation in a directory]) +_LT_DECL([], [finish_eval], [1], + [[As "finish_cmds", except a single script fragment to be evaled but + not shown]]) +_LT_DECL([], [hardcode_into_libs], [0], + [Whether we should hardcode library paths into libraries]) +_LT_DECL([], [sys_lib_search_path_spec], [2], + [Compile-time system search path for libraries]) +_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], + [Run-time system search path for libraries]) +])# _LT_SYS_DYNAMIC_LINKER + + +# _LT_PATH_TOOL_PREFIX(TOOL) +# -------------------------- +# find a file program which can recognize shared library +AC_DEFUN([_LT_PATH_TOOL_PREFIX], +[m4_require([_LT_DECL_EGREP])dnl +AC_MSG_CHECKING([for $1]) +AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, +[case $MAGIC_CMD in +[[\\/*] | ?:[\\/]*]) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR +dnl $ac_dummy forces splitting on constant user-supplied paths. +dnl POSIX.2 word splitting is done only on the output of word expansions, +dnl not every word. This closes a longstanding sh security hole. + ac_dummy="m4_if([$2], , $PATH, [$2])" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$1; then + lt_cv_path_MAGIC_CMD="$ac_dir/$1" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac]) +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + AC_MSG_RESULT($MAGIC_CMD) +else + AC_MSG_RESULT(no) +fi +_LT_DECL([], [MAGIC_CMD], [0], + [Used to examine libraries when file_magic_cmd begins with "file"])dnl +])# _LT_PATH_TOOL_PREFIX + +# Old name: +AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) + + +# _LT_PATH_MAGIC +# -------------- +# find a file program which can recognize a shared library +m4_defun([_LT_PATH_MAGIC], +[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) + else + MAGIC_CMD=: + fi +fi +])# _LT_PATH_MAGIC + + +# LT_PATH_LD +# ---------- +# find the pathname to the GNU or non-GNU linker +AC_DEFUN([LT_PATH_LD], +[AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_PROG_ECHO_BACKSLASH])dnl + +AC_ARG_WITH([gnu-ld], + [AS_HELP_STRING([--with-gnu-ld], + [assume the C compiler uses GNU ld @<:@default=no@:>@])], + [test "$withval" = no || with_gnu_ld=yes], + [with_gnu_ld=no])dnl + +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + AC_MSG_CHECKING([for ld used by $CC]) + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [[\\/]]* | ?:[[\\/]]*) + re_direlt='/[[^/]][[^/]]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + AC_MSG_CHECKING([for GNU ld]) +else + AC_MSG_CHECKING([for non-GNU ld]) +fi +AC_CACHE_VAL(lt_cv_path_LD, +[if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in + *GNU* | *'with BFD'*) + test "$with_gnu_ld" != no && break + ;; + *) + test "$with_gnu_ld" != yes && break + ;; + esac + fi + done + IFS="$lt_save_ifs" +else + lt_cv_path_LD="$LD" # Let the user override the test with a path. +fi]) +LD="$lt_cv_path_LD" +if test -n "$LD"; then + AC_MSG_RESULT($LD) +else + AC_MSG_RESULT(no) +fi +test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) +_LT_PATH_LD_GNU +AC_SUBST([LD]) + +_LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) +])# LT_PATH_LD + +# Old names: +AU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) +AU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_PROG_LD], []) +dnl AC_DEFUN([AC_PROG_LD], []) + + +# _LT_PATH_LD_GNU +#- -------------- +m4_defun([_LT_PATH_LD_GNU], +[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, +[# I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 </dev/null` in +*GNU* | *'with BFD'*) + lt_cv_prog_gnu_ld=yes + ;; +*) + lt_cv_prog_gnu_ld=no + ;; +esac]) +with_gnu_ld=$lt_cv_prog_gnu_ld +])# _LT_PATH_LD_GNU + + +# _LT_CMD_RELOAD +# -------------- +# find reload flag for linker +# -- PORTME Some linkers may need a different reload flag. +m4_defun([_LT_CMD_RELOAD], +[AC_CACHE_CHECK([for $LD option to reload object files], + lt_cv_ld_reload_flag, + [lt_cv_ld_reload_flag='-r']) +reload_flag=$lt_cv_ld_reload_flag +case $reload_flag in +"" | " "*) ;; +*) reload_flag=" $reload_flag" ;; +esac +reload_cmds='$LD$reload_flag -o $output$reload_objs' +case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + if test "$GCC" != yes; then + reload_cmds=false + fi + ;; + darwin*) + if test "$GCC" = yes; then + reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' + else + reload_cmds='$LD$reload_flag -o $output$reload_objs' + fi + ;; +esac +_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl +_LT_TAGDECL([], [reload_cmds], [2])dnl +])# _LT_CMD_RELOAD + + +# _LT_CHECK_MAGIC_METHOD +# ---------------------- +# how to check for library dependencies +# -- PORTME fill in with the dynamic library characteristics +m4_defun([_LT_CHECK_MAGIC_METHOD], +[m4_require([_LT_DECL_EGREP]) +m4_require([_LT_DECL_OBJDUMP]) +AC_CACHE_CHECK([how to recognize dependent libraries], +lt_cv_deplibs_check_method, +[lt_cv_file_magic_cmd='$MAGIC_CMD' +lt_cv_file_magic_test_file= +lt_cv_deplibs_check_method='unknown' +# Need to set the preceding variable on all platforms that support +# interlibrary dependencies. +# 'none' -- dependencies not supported. +# `unknown' -- same as none, but documents that we really don't know. +# 'pass_all' -- all dependencies passed with no checks. +# 'test_compile' -- check by making test program. +# 'file_magic [[regex]]' -- check by looking for files in library path +# which responds to the $file_magic_cmd with a given extended regex. +# If you have `file' or equivalent on your system and you're not sure +# whether `pass_all' will *always* work, you probably want this one. + +case $host_os in +aix[[4-9]]*) + lt_cv_deplibs_check_method=pass_all + ;; + +beos*) + lt_cv_deplibs_check_method=pass_all + ;; + +bsdi[[45]]*) + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' + lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_test_file=/shlib/libc.so + ;; + +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; + +mingw* | pw32*) + # Base MSYS/MinGW do not provide the 'file' command needed by + # func_win32_libid shell function, so use a weaker test based on 'objdump', + # unless we find 'file', for example because we are cross-compiling. + # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. + if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + else + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_file_magic_cmd='$OBJDUMP -f' + fi + ;; + +cegcc*) + # use the weaker test based on 'objdump'. See mingw*. + lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + ;; + +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; + +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; + esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; + +haiku*) + lt_cv_deplibs_check_method=pass_all + ;; + +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; + +interix[[3-9]]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' + ;; + +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + lt_cv_deplibs_check_method=pass_all + ;; + +netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' + fi + ;; + +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; + +*nto* | *qnx*) + lt_cv_deplibs_check_method=pass_all + ;; + +openbsd*) + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' + fi + ;; + +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; + +rdos*) + lt_cv_deplibs_check_method=pass_all + ;; + +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv4 | sysv4.3*) + case $host_vendor in + motorola) + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` + ;; + ncr) + lt_cv_deplibs_check_method=pass_all + ;; + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' + ;; + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so + ;; + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + pc) + lt_cv_deplibs_check_method=pass_all + ;; + esac + ;; + +tpf*) + lt_cv_deplibs_check_method=pass_all + ;; +esac +]) + +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` + fi + ;; + esac +fi + +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown + +_LT_DECL([], [deplibs_check_method], [1], + [Method to check whether dependent libraries are shared objects]) +_LT_DECL([], [file_magic_cmd], [1], + [Command to use when deplibs_check_method = "file_magic"]) +_LT_DECL([], [file_magic_glob], [1], + [How to find potential files when deplibs_check_method = "file_magic"]) +_LT_DECL([], [want_nocaseglob], [1], + [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) +])# _LT_CHECK_MAGIC_METHOD + + +# LT_PATH_NM +# ---------- +# find the pathname to a BSD- or MS-compatible name lister +AC_DEFUN([LT_PATH_NM], +[AC_REQUIRE([AC_PROG_CC])dnl +AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, +[if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM="$NM" +else + lt_nm_to_check="${ac_tool_prefix}nm" + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + tmp_nm="$ac_dir/$lt_tmp_nm" + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the `sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in + */dev/null* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break + ;; + *) + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac + ;; + esac + fi + done + IFS="$lt_save_ifs" + done + : ${lt_cv_path_NM=no} +fi]) +if test "$lt_cv_path_NM" != "no"; then + NM="$lt_cv_path_NM" +else + # Didn't find any BSD compatible name lister, look for dumpbin. + if test -n "$DUMPBIN"; then : + # Let the user override the test. + else + AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) + case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols" + ;; + *) + DUMPBIN=: + ;; + esac + fi + AC_SUBST([DUMPBIN]) + if test "$DUMPBIN" != ":"; then + NM="$DUMPBIN" + fi +fi +test -z "$NM" && NM=nm +AC_SUBST([NM]) +_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl + +AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], + [lt_cv_nm_interface="BSD nm" + echo "int some_variable = 0;" > conftest.$ac_ext + (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&AS_MESSAGE_LOG_FD + (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&AS_MESSAGE_LOG_FD + (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) + cat conftest.out >&AS_MESSAGE_LOG_FD + if $GREP 'External.*some_variable' conftest.out > /dev/null; then + lt_cv_nm_interface="MS dumpbin" + fi + rm -f conftest*]) +])# LT_PATH_NM + +# Old names: +AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) +AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_PROG_NM], []) +dnl AC_DEFUN([AC_PROG_NM], []) + +# _LT_CHECK_SHAREDLIB_FROM_LINKLIB +# -------------------------------- +# how to determine the name of the shared library +# associated with a specific link library. +# -- PORTME fill in with the dynamic library characteristics +m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], +[m4_require([_LT_DECL_EGREP]) +m4_require([_LT_DECL_OBJDUMP]) +m4_require([_LT_DECL_DLLTOOL]) +AC_CACHE_CHECK([how to associate runtime and link libraries], +lt_cv_sharedlib_from_linklib_cmd, +[lt_cv_sharedlib_from_linklib_cmd='unknown' + +case $host_os in +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh + # decide which to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib + ;; + *) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback + ;; + esac + ;; +*) + # fallback: assume linklib IS sharedlib + lt_cv_sharedlib_from_linklib_cmd="$ECHO" + ;; +esac +]) +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO + +_LT_DECL([], [sharedlib_from_linklib_cmd], [1], + [Command to associate shared and link libraries]) +])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB + + +# _LT_PATH_MANIFEST_TOOL +# ---------------------- +# locate the manifest tool +m4_defun([_LT_PATH_MANIFEST_TOOL], +[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], + [lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&AS_MESSAGE_LOG_FD + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest*]) +if test "x$lt_cv_path_mainfest_tool" != xyes; then + MANIFEST_TOOL=: +fi +_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl +])# _LT_PATH_MANIFEST_TOOL + + +# LT_LIB_M +# -------- +# check for math library +AC_DEFUN([LT_LIB_M], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +LIBM= +case $host in +*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) + # These system don't have libm, or don't need it + ;; +*-ncr-sysv4.3*) + AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") + AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") + ;; +*) + AC_CHECK_LIB(m, cos, LIBM="-lm") + ;; +esac +AC_SUBST([LIBM]) +])# LT_LIB_M + +# Old name: +AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_CHECK_LIBM], []) + + +# _LT_COMPILER_NO_RTTI([TAGNAME]) +# ------------------------------- +m4_defun([_LT_COMPILER_NO_RTTI], +[m4_require([_LT_TAG_COMPILER])dnl + +_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= + +if test "$GCC" = yes; then + case $cc_basename in + nvcc*) + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; + *) + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; + esac + + _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], + lt_cv_prog_compiler_rtti_exceptions, + [-fno-rtti -fno-exceptions], [], + [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) +fi +_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], + [Compiler flag to turn off builtin functions]) +])# _LT_COMPILER_NO_RTTI + + +# _LT_CMD_GLOBAL_SYMBOLS +# ---------------------- +m4_defun([_LT_CMD_GLOBAL_SYMBOLS], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([AC_PROG_AWK])dnl +AC_REQUIRE([LT_PATH_NM])dnl +AC_REQUIRE([LT_PATH_LD])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_TAG_COMPILER])dnl + +# Check for command to grab the raw symbol name followed by C symbol from nm. +AC_MSG_CHECKING([command to parse $NM output from $compiler object]) +AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], +[ +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] + +# Character class describing NM global symbol codes. +symcode='[[BCDEGRST]]' + +# Regexp to match symbols that can be accessed directly from C. +sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' + +# Define system-specific variables. +case $host_os in +aix*) + symcode='[[BCDT]]' + ;; +cygwin* | mingw* | pw32* | cegcc*) + symcode='[[ABCDGISTW]]' + ;; +hpux*) + if test "$host_cpu" = ia64; then + symcode='[[ABCDEGRST]]' + fi + ;; +irix* | nonstopux*) + symcode='[[BCDEGRST]]' + ;; +osf*) + symcode='[[BCDEGQRST]]' + ;; +solaris*) + symcode='[[BDRT]]' + ;; +sco3.2v5*) + symcode='[[DT]]' + ;; +sysv4.2uw2*) + symcode='[[DT]]' + ;; +sysv5* | sco5v6* | unixware* | OpenUNIX*) + symcode='[[ABDT]]' + ;; +sysv4) + symcode='[[DFNSTU]]' + ;; +esac + +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[[ABCDGIRSTW]]' ;; +esac + +# Transform an extracted symbol line into a proper C declaration. +# Some systems (esp. on ia64) link data and code symbols differently, +# so use this general approach. +lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" + +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'" + +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac + +# Try without a prefix underscore, then with it. +for ac_symprfx in "" "_"; do + + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" + + # Write the raw and C identifiers. + if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Fake it for dumpbin and say T for any non-static function + # and D for any global variable. + # Also find C++ and __fastcall symbols from MSVC++, + # which start with @ or ?. + lt_cv_sys_global_symbol_pipe="$AWK ['"\ +" {last_section=section; section=\$ 3};"\ +" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ +" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" \$ 0!~/External *\|/{next};"\ +" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ +" {if(hide[section]) next};"\ +" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ +" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ +" s[1]~/^[@?]/{print s[1], s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ +" ' prfx=^$ac_symprfx]" + else + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + + # Check to see that the pipe works correctly. + pipe_works=no + + rm -f conftest* + cat > conftest.$ac_ext <<_LT_EOF +#ifdef __cplusplus +extern "C" { +#endif +char nm_test_var; +void nm_test_func(void); +void nm_test_func(void){} +#ifdef __cplusplus +} +#endif +int main(){nm_test_var='a';nm_test_func();return(0);} +_LT_EOF + + if AC_TRY_EVAL(ac_compile); then + # Now try to grab the symbols. + nlist=conftest.nm + if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi + + # Make sure that we snagged all the symbols we need. + if $GREP ' nm_test_var$' "$nlist" >/dev/null; then + if $GREP ' nm_test_func$' "$nlist" >/dev/null; then + cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT@&t@_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT@&t@_DLSYM_CONST +#else +# define LT@&t@_DLSYM_CONST const +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +_LT_EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' + + cat <<_LT_EOF >> conftest.$ac_ext + +/* The mapping between symbol names and symbols. */ +LT@&t@_DLSYM_CONST struct { + const char *name; + void *address; +} +lt__PROGRAM__LTX_preloaded_symbols[[]] = +{ + { "@PROGRAM@", (void *) 0 }, +_LT_EOF + $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + cat <<\_LT_EOF >> conftest.$ac_ext + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt__PROGRAM__LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif +_LT_EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_globsym_save_LIBS=$LIBS + lt_globsym_save_CFLAGS=$CFLAGS + LIBS="conftstm.$ac_objext" + CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" + if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then + pipe_works=yes + fi + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS + else + echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD + fi + else + echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD + fi + else + echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD + cat conftest.$ac_ext >&5 + fi + rm -rf conftest* conftst* + + # Do not use the global_symbol_pipe unless it works. + if test "$pipe_works" = yes; then + break + else + lt_cv_sys_global_symbol_pipe= + fi +done +]) +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + AC_MSG_RESULT(failed) +else + AC_MSG_RESULT(ok) +fi + +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then + nm_file_list_spec='@' +fi + +_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], + [Take the output of nm and produce a listing of raw symbols and C names]) +_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], + [Transform the output of nm in a proper C declaration]) +_LT_DECL([global_symbol_to_c_name_address], + [lt_cv_sys_global_symbol_to_c_name_address], [1], + [Transform the output of nm in a C name address pair]) +_LT_DECL([global_symbol_to_c_name_address_lib_prefix], + [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], + [Transform the output of nm in a C name address pair when lib prefix is needed]) +_LT_DECL([], [nm_file_list_spec], [1], + [Specify filename containing input files for $NM]) +]) # _LT_CMD_GLOBAL_SYMBOLS + + +# _LT_COMPILER_PIC([TAGNAME]) +# --------------------------- +m4_defun([_LT_COMPILER_PIC], +[m4_require([_LT_TAG_COMPILER])dnl +_LT_TAGVAR(lt_prog_compiler_wl, $1)= +_LT_TAGVAR(lt_prog_compiler_pic, $1)= +_LT_TAGVAR(lt_prog_compiler_static, $1)= + +m4_if([$1], [CXX], [ + # C++ specific cases for pic, static, wl, etc. + if test "$GXX" = yes; then + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + ;; + *djgpp*) + # DJGPP does not support shared libraries at all + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + _LT_TAGVAR(lt_prog_compiler_static, $1)= + ;; + interix[[3-9]]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + else + case $host_os in + aix[[4-9]]*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + else + _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' + fi + ;; + chorus*) + case $cc_basename in + cxch68*) + # Green Hills C++ Compiler + # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" + ;; + esac + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; + dgux*) + case $cc_basename in + ec++*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + ;; + ghcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + *) + ;; + esac + ;; + freebsd* | dragonfly*) + # FreeBSD uses GNU C++ + ;; + hpux9* | hpux10* | hpux11*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + if test "$host_cpu" != ia64; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + fi + ;; + aCC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + ;; + esac + ;; + *) + ;; + esac + ;; + interix*) + # This is c89, which is MS Visual C++ (no shared libs) + # Anyone wants to do a port? + ;; + irix5* | irix6* | nonstopux*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + # CC pic flag -KPIC is the default. + ;; + *) + ;; + esac + ;; + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # KAI C++ Compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + ecpc* ) + # old Intel C++ for x86_64 which still supported -KPIC. + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + icpc* ) + # Intel C++, used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + cxx*) + # Compaq C++ + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) + # IBM XL 8.0, 9.0 on PPC and BlueGene + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + esac + ;; + esac + ;; + lynxos*) + ;; + m88k*) + ;; + mvs*) + case $cc_basename in + cxx*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' + ;; + *) + ;; + esac + ;; + netbsd* | netbsdelf*-gnu) + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' + ;; + RCC*) + # Rational C++ 2.4.1 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + cxx*) + # Digital/Compaq C++ + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + *) + ;; + esac + ;; + psos*) + ;; + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + gcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + ;; + *) + ;; + esac + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + lcc*) + # Lucid + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + *) + ;; + esac + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + ;; + *) + ;; + esac + ;; + vxworks*) + ;; + *) + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + esac + fi +], +[ + if test "$GCC" = yes; then + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + ;; + + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + _LT_TAGVAR(lt_prog_compiler_static, $1)= + ;; + + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + ;; + + interix[[3-9]]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + enable_shared=no + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic + fi + ;; + + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' + if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" + fi + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + else + _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' + fi + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; + + hpux9* | hpux10* | hpux11*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + ;; + + irix5* | irix6* | nonstopux*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # PIC (with -KPIC) is the default. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + # old Intel for x86_64 which still supported -KPIC. + ecc*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + # icc used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + icc* | ifort*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + # Lahey Fortran 8.1. + lf95*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' + _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' + ;; + nagfor*) + # NAG Fortran compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + ccc*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # All Alpha code is PIC. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='' + ;; + *Sun\ F* | *Sun*Fortran*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + *Sun\ C*) + # Sun C 5.9 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + ;; + *Intel*\ [[CF]]*Compiler*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + *Portland\ Group*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + esac + ;; + + newsos6) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + + osf3* | osf4* | osf5*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # All OSF/1 code is PIC. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + rdos*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + solaris*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + case $cc_basename in + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; + *) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; + esac + ;; + + sunos4*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + sysv4 | sysv4.2uw2* | sysv4.3*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + sysv4*MP*) + if test -d /usr/nec ;then + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + ;; + + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + unicos*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + + uts4*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + *) + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + esac + fi +]) +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" + ;; +esac + +AC_CACHE_CHECK([for $compiler option to produce PIC], + [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], + [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) +_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then + _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], + [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], + [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], + [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in + "" | " "*) ;; + *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; + esac], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) +fi +_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], + [Additional compiler flags for building library objects]) + +_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], + [How to pass a linker flag through the compiler]) +# +# Check to make sure the static flag actually works. +# +wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" +_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], + _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), + $lt_tmp_static_flag, + [], + [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) +_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], + [Compiler flag to prevent dynamic linking]) +])# _LT_COMPILER_PIC + + +# _LT_LINKER_SHLIBS([TAGNAME]) +# ---------------------------- +# See if the linker supports building shared libraries. +m4_defun([_LT_LINKER_SHLIBS], +[AC_REQUIRE([LT_PATH_LD])dnl +AC_REQUIRE([LT_PATH_NM])dnl +m4_require([_LT_PATH_MANIFEST_TOOL])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl +m4_require([_LT_TAG_COMPILER])dnl +AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) +m4_if([$1], [CXX], [ + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] + case $host_os in + aix[[4-9]]*) + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + # Also, AIX nm treats weak defined symbols like other global defined + # symbols, whereas GNU nm marks them as "W". + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + else + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + fi + ;; + pw32*) + _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" + ;; + cygwin* | mingw* | cegcc*) + case $cc_basename in + cl*) + _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + ;; + *) + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] + ;; + esac + ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; + *) + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + ;; + esac +], [ + runpath_var= + _LT_TAGVAR(allow_undefined_flag, $1)= + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(archive_cmds, $1)= + _LT_TAGVAR(archive_expsym_cmds, $1)= + _LT_TAGVAR(compiler_needs_object, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + _LT_TAGVAR(export_dynamic_flag_spec, $1)= + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(hardcode_automatic, $1)=no + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= + _LT_TAGVAR(hardcode_libdir_separator, $1)= + _LT_TAGVAR(hardcode_minus_L, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported + _LT_TAGVAR(inherit_rpath, $1)=no + _LT_TAGVAR(link_all_deplibs, $1)=unknown + _LT_TAGVAR(module_cmds, $1)= + _LT_TAGVAR(module_expsym_cmds, $1)= + _LT_TAGVAR(old_archive_from_new_cmds, $1)= + _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= + _LT_TAGVAR(thread_safe_flag_spec, $1)= + _LT_TAGVAR(whole_archive_flag_spec, $1)= + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + _LT_TAGVAR(include_expsyms, $1)= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. +dnl Note also adjust exclude_expsyms for C++ above. + extract_expsyms_cmds= + + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd*) + with_gnu_ld=no + ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; + esac + + _LT_TAGVAR(ld_shlibs, $1)=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no + if test "$with_gnu_ld" = yes; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; + *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test "$lt_use_gnu_ld_interface" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' + + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then + _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + supports_anon_versioning=no + case `$LD -v 2>&1` in + *GNU\ gold*) supports_anon_versioning=yes ;; + *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + + # See if GNU ld supports shared libraries. + case $host_os in + aix[[3-9]]*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: the GNU linker, at least up to release 2.19, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. + +_LT_EOF + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='' + ;; + m68k) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Joseph Beckenbach <jrb3@best.com> says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, + # as there is no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + haiku*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + interix[[3-9]]*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) + tmp_diet=no + if test "$host_os" = linux-dietlibc; then + case $cc_basename in + diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) + esac + fi + if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ + && test "$tmp_diet" = no + then + tmp_addflag=' $pic_flag' + tmp_sharedflag='-shared' + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group f77 and f90 compilers + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + lf95*) # Lahey Fortran 8.1 + _LT_TAGVAR(whole_archive_flag_spec, $1)= + tmp_sharedflag='--shared' ;; + xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) + tmp_sharedflag='-qmkshrobj' + tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + esac + _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + + if test "x$supports_anon_versioning" = xyes; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + + case $cc_basename in + xlf* | bgf* | bgxlf* | mpixlf*) + # IBM XL Fortran 10.1 on PPC cannot create shared libs itself + _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' + if test "x$supports_anon_versioning" = xyes; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + fi + ;; + esac + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + + solaris*) + if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + ;; + *) + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + sunos4*) + _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + + if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then + runpath_var= + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= + _LT_TAGVAR(export_dynamic_flag_spec, $1)= + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + _LT_TAGVAR(hardcode_direct, $1)=unsupported + fi + ;; + + aix[[4-9]]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + # Also, AIX nm treats weak defined symbols like other global + # defined symbols, whereas GNU nm marks them as "W". + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + else + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + _LT_TAGVAR(archive_cmds, $1)='' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' + + if test "$GCC" = yes; then + case $host_os in aix4.[[012]]|aix4.[[012]].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + _LT_TAGVAR(hardcode_direct, $1)=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)= + fi + ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + _LT_TAGVAR(link_all_deplibs, $1)=no + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + _LT_TAGVAR(always_export_symbols, $1)=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(allow_undefined_flag, $1)='-berok' + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' + _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + # This is similar to how AIX traditionally builds its shared libraries. + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='' + ;; + m68k) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + ;; + + bsdi[[45]]*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + case $cc_basename in + cl*) + # Native MSVC + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' + # Don't use ranlib + _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' + _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + # FIXME: Should let the user specify the lib program. + _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + esac + ;; + + darwin* | rhapsody*) + _LT_DARWIN_LINKER_FEATURES($1) + ;; + + dgux*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2.*) + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + hpux9*) + if test "$GCC" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_direct, $1)=yes + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + ;; + + hpux10*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test "$with_gnu_ld" = no; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + fi + ;; + + hpux11*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + m4_if($1, [], [ + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + _LT_LINKER_OPTION([if $CC understands -b], + _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], + [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], + [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], + [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) + ;; + esac + fi + if test "$with_gnu_ld" = no; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + case $host_cpu in + hppa*64*|ia64*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + *) + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + fi + ;; + + irix5* | irix6* | nonstopux*) + if test "$GCC" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + # Try to use the -exported_symbol ld option, if it does not + # work, assume that -exports_file does not work either and + # implicitly export all symbols. + # This should be the same for all languages, so no per-tag cache variable. + AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], + [lt_cv_irix_exported_symbol], + [save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" + AC_LINK_IFELSE( + [AC_LANG_SOURCE( + [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], + [C++], [[int foo (void) { return 0; }]], + [Fortran 77], [[ + subroutine foo + end]], + [Fortran], [[ + subroutine foo + end]])])], + [lt_cv_irix_exported_symbol=yes], + [lt_cv_irix_exported_symbol=no]) + LDFLAGS="$save_LDFLAGS"]) + if test "$lt_cv_irix_exported_symbol" = yes; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' + fi + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(inherit_rpath, $1)=yes + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + newsos6) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *nto* | *qnx*) + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + else + case $host_os in + openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + ;; + esac + fi + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + ;; + + osf3*) + if test "$GCC" = yes; then + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + ;; + + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + else + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ + $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' + + # Both c and cxx compiler support -rpath directly + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + ;; + + solaris*) + _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' + if test "$GCC" = yes; then + wlarc='${wl}' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + else + case `$CC -V 2>&1` in + *"Compilers 5.0"*) + wlarc='' + _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + ;; + *) + wlarc='${wl}' + _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + ;; + esac + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. GCC discards it without `$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test "$GCC" = yes; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' + fi + ;; + esac + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + sunos4*) + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + sysv4) + case $host_vendor in + sni) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' + _LT_TAGVAR(hardcode_direct, $1)=no + ;; + motorola) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + sysv4.3*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + _LT_TAGVAR(ld_shlibs, $1)=yes + fi + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) + _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + uts4*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *) + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + + if test x$host_vendor = xsni; then + case $host in + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' + ;; + esac + fi + fi +]) +AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) +test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no + +_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld + +_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl +_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl +_LT_DECL([], [extract_expsyms_cmds], [2], + [The commands to extract the exported symbol list from a shared archive]) + +# +# Do we need to explicitly link libc? +# +case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in +x|xyes) + # Assume -lc should be added + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $_LT_TAGVAR(archive_cmds, $1) in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + AC_CACHE_CHECK([whether -lc should be explicitly linked in], + [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), + [$RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if AC_TRY_EVAL(ac_compile) 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) + pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) + _LT_TAGVAR(allow_undefined_flag, $1)= + if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) + then + lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no + else + lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes + fi + _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + ]) + _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) + ;; + esac + fi + ;; +esac + +_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], + [Whether or not to add -lc for building shared libraries]) +_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], + [enable_shared_with_static_runtimes], [0], + [Whether or not to disallow shared libs when runtime libs are static]) +_LT_TAGDECL([], [export_dynamic_flag_spec], [1], + [Compiler flag to allow reflexive dlopens]) +_LT_TAGDECL([], [whole_archive_flag_spec], [1], + [Compiler flag to generate shared objects directly from archives]) +_LT_TAGDECL([], [compiler_needs_object], [1], + [Whether the compiler copes with passing no objects directly]) +_LT_TAGDECL([], [old_archive_from_new_cmds], [2], + [Create an old-style archive from a shared archive]) +_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], + [Create a temporary old-style archive to link instead of a shared archive]) +_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) +_LT_TAGDECL([], [archive_expsym_cmds], [2]) +_LT_TAGDECL([], [module_cmds], [2], + [Commands used to build a loadable module if different from building + a shared archive.]) +_LT_TAGDECL([], [module_expsym_cmds], [2]) +_LT_TAGDECL([], [with_gnu_ld], [1], + [Whether we are building with GNU ld or not]) +_LT_TAGDECL([], [allow_undefined_flag], [1], + [Flag that allows shared libraries with undefined symbols to be built]) +_LT_TAGDECL([], [no_undefined_flag], [1], + [Flag that enforces no undefined symbols]) +_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], + [Flag to hardcode $libdir into a binary during linking. + This must work even if $libdir does not exist]) +_LT_TAGDECL([], [hardcode_libdir_separator], [1], + [Whether we need a single "-rpath" flag with a separated argument]) +_LT_TAGDECL([], [hardcode_direct], [0], + [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes + DIR into the resulting binary]) +_LT_TAGDECL([], [hardcode_direct_absolute], [0], + [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes + DIR into the resulting binary and the resulting library dependency is + "absolute", i.e impossible to change by setting ${shlibpath_var} if the + library is relocated]) +_LT_TAGDECL([], [hardcode_minus_L], [0], + [Set to "yes" if using the -LDIR flag during linking hardcodes DIR + into the resulting binary]) +_LT_TAGDECL([], [hardcode_shlibpath_var], [0], + [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR + into the resulting binary]) +_LT_TAGDECL([], [hardcode_automatic], [0], + [Set to "yes" if building a shared library automatically hardcodes DIR + into the library and all subsequent libraries and executables linked + against it]) +_LT_TAGDECL([], [inherit_rpath], [0], + [Set to yes if linker adds runtime paths of dependent libraries + to runtime path list]) +_LT_TAGDECL([], [link_all_deplibs], [0], + [Whether libtool must link a program against all its dependency libraries]) +_LT_TAGDECL([], [always_export_symbols], [0], + [Set to "yes" if exported symbols are required]) +_LT_TAGDECL([], [export_symbols_cmds], [2], + [The commands to list exported symbols]) +_LT_TAGDECL([], [exclude_expsyms], [1], + [Symbols that should not be listed in the preloaded symbols]) +_LT_TAGDECL([], [include_expsyms], [1], + [Symbols that must always be exported]) +_LT_TAGDECL([], [prelink_cmds], [2], + [Commands necessary for linking programs (against libraries) with templates]) +_LT_TAGDECL([], [postlink_cmds], [2], + [Commands necessary for finishing linking programs]) +_LT_TAGDECL([], [file_list_spec], [1], + [Specify filename containing input files]) +dnl FIXME: Not yet implemented +dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], +dnl [Compiler flag to generate thread safe objects]) +])# _LT_LINKER_SHLIBS + + +# _LT_LANG_C_CONFIG([TAG]) +# ------------------------ +# Ensure that the configuration variables for a C compiler are suitably +# defined. These variables are subsequently used by _LT_CONFIG to write +# the compiler configuration to `libtool'. +m4_defun([_LT_LANG_C_CONFIG], +[m4_require([_LT_DECL_EGREP])dnl +lt_save_CC="$CC" +AC_LANG_PUSH(C) + +# Source file extension for C test sources. +ac_ext=c + +# Object file extension for compiled C test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' + +_LT_TAG_COMPILER +# Save the default compiler, since it gets overwritten when the other +# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. +compiler_DEFAULT=$CC + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + LT_SYS_DLOPEN_SELF + _LT_CMD_STRIPLIB + + # Report which library types will actually be built + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test "$can_build_shared" = "no" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + + aix[[4-9]]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test "$enable_shared" = yes || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_CONFIG($1) +fi +AC_LANG_POP +CC="$lt_save_CC" +])# _LT_LANG_C_CONFIG + + +# _LT_LANG_CXX_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for a C++ compiler are suitably +# defined. These variables are subsequently used by _LT_CONFIG to write +# the compiler configuration to `libtool'. +m4_defun([_LT_LANG_CXX_CONFIG], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_PATH_MANIFEST_TOOL])dnl +if test -n "$CXX" && ( test "X$CXX" != "Xno" && + ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || + (test "X$CXX" != "Xg++"))) ; then + AC_PROG_CXXCPP +else + _lt_caught_CXX_error=yes +fi + +AC_LANG_PUSH(C++) +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(compiler_needs_object, $1)=no +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for C++ test sources. +ac_ext=cpp + +# Object file extension for compiled C++ test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the CXX compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test "$_lt_caught_CXX_error" != yes; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="int some_variable = 0;" + + # Code to be used in simple link tests + lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_CFLAGS=$CFLAGS + lt_save_LD=$LD + lt_save_GCC=$GCC + GCC=$GXX + lt_save_with_gnu_ld=$with_gnu_ld + lt_save_path_LD=$lt_cv_path_LD + if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then + lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx + else + $as_unset lt_cv_prog_gnu_ld + fi + if test -n "${lt_cv_path_LDCXX+set}"; then + lt_cv_path_LD=$lt_cv_path_LDCXX + else + $as_unset lt_cv_path_LD + fi + test -z "${LDCXX+set}" || LD=$LDCXX + CC=${CXX-"c++"} + CFLAGS=$CXXFLAGS + compiler=$CC + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + + if test -n "$compiler"; then + # We don't want -fno-exception when compiling C++ code, so set the + # no_builtin_flag separately + if test "$GXX" = yes; then + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' + else + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= + fi + + if test "$GXX" = yes; then + # Set up default GNU C++ configuration + + LT_PATH_LD + + # Check if GNU C++ uses GNU ld as the underlying linker, since the + # archiving commands below assume that GNU ld is being used. + if test "$with_gnu_ld" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + + # If archive_cmds runs LD, not CC, wlarc should be empty + # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to + # investigate it a little bit more. (MM) + wlarc='${wl}' + + # ancient GNU ld didn't support --whole-archive et. al. + if eval "`$CC -print-prog-name=ld` --help 2>&1" | + $GREP 'no-whole-archive' > /dev/null; then + _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + else + with_gnu_ld=no + wlarc= + + # A generic and very simple default shared library creation + # command for GNU C++ for the case where it uses the native + # linker, instead of GNU ld. If possible, this setting should + # overridden to take advantage of the native linker features on + # the platform it is being used on. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + fi + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + GXX=no + with_gnu_ld=no + wlarc= + fi + + # PORTME: fill in a description of your system's C++ link characteristics + AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) + _LT_TAGVAR(ld_shlibs, $1)=yes + case $host_os in + aix3*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aix[[4-9]]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) + for ld_flag in $LDFLAGS; do + case $ld_flag in + *-brtl*) + aix_use_runtimelinking=yes + break + ;; + esac + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + _LT_TAGVAR(archive_cmds, $1)='' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' + + if test "$GXX" = yes; then + case $host_os in aix4.[[012]]|aix4.[[012]].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + _LT_TAGVAR(hardcode_direct, $1)=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)= + fi + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to + # export. + _LT_TAGVAR(always_export_symbols, $1)=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(allow_undefined_flag, $1)='-berok' + # Determine the default libpath from the value encoded in an empty + # executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' + _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + # This is similar to how AIX traditionally builds its shared + # libraries. + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Joseph Beckenbach <jrb3@best.com> says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + chorus*) + case $cc_basename in + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + cygwin* | mingw* | pw32* | cegcc*) + case $GXX,$cc_basename in + ,cl* | no,cl*) + # Native MSVC + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + # Don't use ranlib + _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' + _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # g++ + # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, + # as there is no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + darwin* | rhapsody*) + _LT_DARWIN_LINKER_FEATURES($1) + ;; + + dgux*) + case $cc_basename in + ec++*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + ghcx*) + # Green Hills C++ Compiler + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + freebsd2.*) + # C++ shared libraries reported to be fairly broken before + # switch to ELF + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + freebsd-elf*) + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + ;; + + freebsd* | dragonfly*) + # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF + # conventions + _LT_TAGVAR(ld_shlibs, $1)=yes + ;; + + haiku*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + hpux9*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, + # but as the default + # location of the library. + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aCC*) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + hpux10*|hpux11*) + if test $with_gnu_ld = no; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + case $host_cpu in + hppa*64*|ia64*) + ;; + *) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + ;; + esac + fi + case $host_cpu in + hppa*64*|ia64*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + *) + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, + # but as the default + # location of the library. + ;; + esac + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aCC*) + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes; then + if test $with_gnu_ld = no; then + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + fi + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + interix[[3-9]]*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + irix5* | irix6*) + case $cc_basename in + CC*) + # SGI C++ + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + + # Archives containing C++ object files must be created using + # "CC -ar", where "CC" is the IRIX C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' + ;; + *) + if test "$GXX" = yes; then + if test "$with_gnu_ld" = no; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' + fi + fi + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + esac + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(inherit_rpath, $1)=yes + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' + ;; + icpc* | ecpc* ) + # Intel C++ + with_gnu_ld=yes + # version 8.0 and above of icpc choke on multiply defined symbols + # if we add $predep_objects and $postdep_objects, however 7.1 and + # earlier do not add the objects themselves. + case `$CC -V 2>&1` in + *"Version 7."*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 8.0 or newer + tmp_idyn= + case $host_cpu in + ia64*) tmp_idyn=' -i_dynamic';; + esac + _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + case `$CC -V` in + *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) + _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ + compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' + _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ + $RANLIB $oldlib' + _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + ;; + *) # Version 6 and above use weak symbols + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + ;; + cxx*) + # Compaq C++ + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' + + runpath_var=LD_RUN_PATH + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' + ;; + xl* | mpixl* | bgxl*) + # IBM XL 8.0 on PPC, with GNU ld + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + if test "x$supports_anon_versioning" = xyes; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' + _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + + # Not sure whether something based on + # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 + # would be better. + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' + ;; + esac + ;; + esac + ;; + + lynxos*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + m88k*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + mvs*) + case $cc_basename in + cxx*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' + wlarc= + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + fi + # Workaround some broken pre-1.5 toolchains + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + ;; + + *nto* | *qnx*) + _LT_TAGVAR(ld_shlibs, $1)=yes + ;; + + openbsd2*) + # C++ shared libraries are fairly broken + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + fi + output_verbose_link_cmd=func_echo_all + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Archives containing C++ object files must be created using + # the KAI C++ compiler. + case $host in + osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; + *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; + esac + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + cxx*) + case $host in + osf3*) + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + ;; + *) + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~ + $RM $lib.exp' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + case $host in + osf3*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + psos*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + lcc*) + # Lucid + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + _LT_TAGVAR(archive_cmds_need_lc,$1)=yes + _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' + _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. + # Supported since Solaris 2.6 (maybe 2.5.1?) + _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' + ;; + esac + _LT_TAGVAR(link_all_deplibs, $1)=yes + + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' + ;; + gcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + + # The C++ compiler must be used to create the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' + ;; + *) + # GNU C++ compiler with Solaris linker + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' + if $CC --version | $GREP -v '^2\.7' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + else + # g++ 2.7 appears to require `-G' NOT `-shared' on this + # platform. + _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + fi + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + ;; + esac + fi + ;; + esac + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) + _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ + '"$_LT_TAGVAR(old_archive_cmds, $1)" + _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ + '"$_LT_TAGVAR(reload_cmds, $1)" + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + vxworks*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + + AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) + test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no + + _LT_TAGVAR(GCC, $1)="$GXX" + _LT_TAGVAR(LD, $1)="$LD" + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_SYS_HIDDEN_LIBDEPS($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS + LDCXX=$LD + LD=$lt_save_LD + GCC=$lt_save_GCC + with_gnu_ld=$lt_save_with_gnu_ld + lt_cv_path_LDCXX=$lt_cv_path_LD + lt_cv_path_LD=$lt_save_path_LD + lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld + lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld +fi # test "$_lt_caught_CXX_error" != yes + +AC_LANG_POP +])# _LT_LANG_CXX_CONFIG + + +# _LT_FUNC_STRIPNAME_CNF +# ---------------------- +# func_stripname_cnf prefix suffix name +# strip PREFIX and SUFFIX off of NAME. +# PREFIX and SUFFIX must not contain globbing or regex special +# characters, hashes, percent signs, but SUFFIX may contain a leading +# dot (in which case that matches only a dot). +# +# This function is identical to the (non-XSI) version of func_stripname, +# except this one can be used by m4 code that may be executed by configure, +# rather than the libtool script. +m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl +AC_REQUIRE([_LT_DECL_SED]) +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) +func_stripname_cnf () +{ + case ${2} in + .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; + *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; + esac +} # func_stripname_cnf +])# _LT_FUNC_STRIPNAME_CNF + +# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) +# --------------------------------- +# Figure out "hidden" library dependencies from verbose +# compiler output when linking a shared library. +# Parse the compiler output and extract the necessary +# objects, libraries and library flags. +m4_defun([_LT_SYS_HIDDEN_LIBDEPS], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl +# Dependencies to place before and after the object being linked: +_LT_TAGVAR(predep_objects, $1)= +_LT_TAGVAR(postdep_objects, $1)= +_LT_TAGVAR(predeps, $1)= +_LT_TAGVAR(postdeps, $1)= +_LT_TAGVAR(compiler_lib_search_path, $1)= + +dnl we can't use the lt_simple_compile_test_code here, +dnl because it contains code intended for an executable, +dnl not a library. It's possible we should let each +dnl tag define a new lt_????_link_test_code variable, +dnl but it's only used here... +m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF +int a; +void foo (void) { a = 0; } +_LT_EOF +], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF +class Foo +{ +public: + Foo (void) { a = 0; } +private: + int a; +}; +_LT_EOF +], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF + subroutine foo + implicit none + integer*4 a + a=0 + return + end +_LT_EOF +], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF + subroutine foo + implicit none + integer a + a=0 + return + end +_LT_EOF +], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF +public class foo { + private int a; + public void bar (void) { + a = 0; + } +}; +_LT_EOF +], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF +package foo +func foo() { +} +_LT_EOF +]) + +_lt_libdeps_save_CFLAGS=$CFLAGS +case "$CC $CFLAGS " in #( +*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; +*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; +*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; +esac + +dnl Parse the compiler output and extract the necessary +dnl objects, libraries and library flags. +if AC_TRY_EVAL(ac_compile); then + # Parse the compiler output and extract the necessary + # objects, libraries and library flags. + + # Sentinel used to keep track of whether or not we are before + # the conftest object file. + pre_test_object_deps_done=no + + for p in `eval "$output_verbose_link_cmd"`; do + case ${prev}${p} in + + -L* | -R* | -l*) + # Some compilers place space between "-{L,R}" and the path. + # Remove the space. + if test $p = "-L" || + test $p = "-R"; then + prev=$p + continue + fi + + # Expand the sysroot to ease extracting the directories later. + if test -z "$prev"; then + case $p in + -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; + -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; + -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; + esac + fi + case $p in + =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; + esac + if test "$pre_test_object_deps_done" = no; then + case ${prev} in + -L | -R) + # Internal compiler library paths should come after those + # provided the user. The postdeps already come after the + # user supplied libs so there is no need to process them. + if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then + _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" + else + _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" + fi + ;; + # The "-l" case would never come before the object being + # linked, so don't bother handling this case. + esac + else + if test -z "$_LT_TAGVAR(postdeps, $1)"; then + _LT_TAGVAR(postdeps, $1)="${prev}${p}" + else + _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" + fi + fi + prev= + ;; + + *.lto.$objext) ;; # Ignore GCC LTO objects + *.$objext) + # This assumes that the test object file only shows up + # once in the compiler output. + if test "$p" = "conftest.$objext"; then + pre_test_object_deps_done=yes + continue + fi + + if test "$pre_test_object_deps_done" = no; then + if test -z "$_LT_TAGVAR(predep_objects, $1)"; then + _LT_TAGVAR(predep_objects, $1)="$p" + else + _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" + fi + else + if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then + _LT_TAGVAR(postdep_objects, $1)="$p" + else + _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" + fi + fi + ;; + + *) ;; # Ignore the rest. + + esac + done + + # Clean up. + rm -f a.out a.exe +else + echo "libtool.m4: error: problem compiling $1 test program" +fi + +$RM -f confest.$objext +CFLAGS=$_lt_libdeps_save_CFLAGS + +# PORTME: override above test on systems where it is broken +m4_if([$1], [CXX], +[case $host_os in +interix[[3-9]]*) + # Interix 3.5 installs completely hosed .la files for C++, so rather than + # hack all around it, let's just trust "g++" to DTRT. + _LT_TAGVAR(predep_objects,$1)= + _LT_TAGVAR(postdep_objects,$1)= + _LT_TAGVAR(postdeps,$1)= + ;; + +linux*) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + + if test "$solaris_use_stlport4" != yes; then + _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' + fi + ;; + esac + ;; + +solaris*) + case $cc_basename in + CC* | sunCC*) + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + + # Adding this requires a known-good setup of shared libraries for + # Sun compiler versions before 5.6, else PIC objects from an old + # archive will be linked into the output, leading to subtle bugs. + if test "$solaris_use_stlport4" != yes; then + _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' + fi + ;; + esac + ;; +esac +]) + +case " $_LT_TAGVAR(postdeps, $1) " in +*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; +esac + _LT_TAGVAR(compiler_lib_search_dirs, $1)= +if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then + _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` +fi +_LT_TAGDECL([], [compiler_lib_search_dirs], [1], + [The directories searched by this compiler when creating a shared library]) +_LT_TAGDECL([], [predep_objects], [1], + [Dependencies to place before and after the objects being linked to + create a shared library]) +_LT_TAGDECL([], [postdep_objects], [1]) +_LT_TAGDECL([], [predeps], [1]) +_LT_TAGDECL([], [postdeps], [1]) +_LT_TAGDECL([], [compiler_lib_search_path], [1], + [The library search path used internally by the compiler when linking + a shared library]) +])# _LT_SYS_HIDDEN_LIBDEPS + + +# _LT_LANG_F77_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for a Fortran 77 compiler are +# suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to `libtool'. +m4_defun([_LT_LANG_F77_CONFIG], +[AC_LANG_PUSH(Fortran 77) +if test -z "$F77" || test "X$F77" = "Xno"; then + _lt_disable_F77=yes +fi + +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for f77 test sources. +ac_ext=f + +# Object file extension for compiled f77 test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the F77 compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test "$_lt_disable_F77" != yes; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="\ + subroutine t + return + end +" + + # Code to be used in simple link tests + lt_simple_link_test_code="\ + program t + end +" + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC="$CC" + lt_save_GCC=$GCC + lt_save_CFLAGS=$CFLAGS + CC=${F77-"f77"} + CFLAGS=$FFLAGS + compiler=$CC + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + GCC=$G77 + if test -n "$compiler"; then + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test "$can_build_shared" = "no" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + aix[[4-9]]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test "$enable_shared" = yes || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_TAGVAR(GCC, $1)="$G77" + _LT_TAGVAR(LD, $1)="$LD" + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + GCC=$lt_save_GCC + CC="$lt_save_CC" + CFLAGS="$lt_save_CFLAGS" +fi # test "$_lt_disable_F77" != yes + +AC_LANG_POP +])# _LT_LANG_F77_CONFIG + + +# _LT_LANG_FC_CONFIG([TAG]) +# ------------------------- +# Ensure that the configuration variables for a Fortran compiler are +# suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to `libtool'. +m4_defun([_LT_LANG_FC_CONFIG], +[AC_LANG_PUSH(Fortran) + +if test -z "$FC" || test "X$FC" = "Xno"; then + _lt_disable_FC=yes +fi + +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for fc test sources. +ac_ext=${ac_fc_srcext-f} + +# Object file extension for compiled fc test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the FC compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test "$_lt_disable_FC" != yes; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="\ + subroutine t + return + end +" + + # Code to be used in simple link tests + lt_simple_link_test_code="\ + program t + end +" + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC="$CC" + lt_save_GCC=$GCC + lt_save_CFLAGS=$CFLAGS + CC=${FC-"f95"} + CFLAGS=$FCFLAGS + compiler=$CC + GCC=$ac_cv_fc_compiler_gnu + + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + + if test -n "$compiler"; then + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test "$can_build_shared" = "no" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + aix[[4-9]]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test "$enable_shared" = yes || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" + _LT_TAGVAR(LD, $1)="$LD" + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_SYS_HIDDEN_LIBDEPS($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + GCC=$lt_save_GCC + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS +fi # test "$_lt_disable_FC" != yes + +AC_LANG_POP +])# _LT_LANG_FC_CONFIG + + +# _LT_LANG_GCJ_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for the GNU Java Compiler compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to `libtool'. +m4_defun([_LT_LANG_GCJ_CONFIG], +[AC_REQUIRE([LT_PROG_GCJ])dnl +AC_LANG_SAVE + +# Source file extension for Java test sources. +ac_ext=java + +# Object file extension for compiled Java test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="class foo {}" + +# Code to be used in simple link tests +lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +lt_save_CC=$CC +lt_save_CFLAGS=$CFLAGS +lt_save_GCC=$GCC +GCC=yes +CC=${GCJ-"gcj"} +CFLAGS=$GCJFLAGS +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_TAGVAR(LD, $1)="$LD" +_LT_CC_BASENAME([$compiler]) + +# GCJ did not exist at the time GCC didn't implicitly link libc in. +_LT_TAGVAR(archive_cmds_need_lc, $1)=no + +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) +fi + +AC_LANG_RESTORE + +GCC=$lt_save_GCC +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS +])# _LT_LANG_GCJ_CONFIG + + +# _LT_LANG_GO_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for the GNU Go compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to `libtool'. +m4_defun([_LT_LANG_GO_CONFIG], +[AC_REQUIRE([LT_PROG_GO])dnl +AC_LANG_SAVE + +# Source file extension for Go test sources. +ac_ext=go + +# Object file extension for compiled Go test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="package main; func main() { }" + +# Code to be used in simple link tests +lt_simple_link_test_code='package main; func main() { }' + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +lt_save_CC=$CC +lt_save_CFLAGS=$CFLAGS +lt_save_GCC=$GCC +GCC=yes +CC=${GOC-"gccgo"} +CFLAGS=$GOFLAGS +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_TAGVAR(LD, $1)="$LD" +_LT_CC_BASENAME([$compiler]) + +# Go did not exist at the time GCC didn't implicitly link libc in. +_LT_TAGVAR(archive_cmds_need_lc, $1)=no + +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) +fi + +AC_LANG_RESTORE + +GCC=$lt_save_GCC +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS +])# _LT_LANG_GO_CONFIG + + +# _LT_LANG_RC_CONFIG([TAG]) +# ------------------------- +# Ensure that the configuration variables for the Windows resource compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to `libtool'. +m4_defun([_LT_LANG_RC_CONFIG], +[AC_REQUIRE([LT_PROG_RC])dnl +AC_LANG_SAVE + +# Source file extension for RC test sources. +ac_ext=rc + +# Object file extension for compiled RC test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' + +# Code to be used in simple link tests +lt_simple_link_test_code="$lt_simple_compile_test_code" + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +lt_save_CC="$CC" +lt_save_CFLAGS=$CFLAGS +lt_save_GCC=$GCC +GCC= +CC=${RC-"windres"} +CFLAGS= +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_CC_BASENAME([$compiler]) +_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes + +if test -n "$compiler"; then + : + _LT_CONFIG($1) +fi + +GCC=$lt_save_GCC +AC_LANG_RESTORE +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS +])# _LT_LANG_RC_CONFIG + + +# LT_PROG_GCJ +# ----------- +AC_DEFUN([LT_PROG_GCJ], +[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], + [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], + [AC_CHECK_TOOL(GCJ, gcj,) + test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" + AC_SUBST(GCJFLAGS)])])[]dnl +]) + +# Old name: +AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_GCJ], []) + + +# LT_PROG_GO +# ---------- +AC_DEFUN([LT_PROG_GO], +[AC_CHECK_TOOL(GOC, gccgo,) +]) + + +# LT_PROG_RC +# ---------- +AC_DEFUN([LT_PROG_RC], +[AC_CHECK_TOOL(RC, windres,) +]) + +# Old name: +AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_RC], []) + + +# _LT_DECL_EGREP +# -------------- +# If we don't have a new enough Autoconf to choose the best grep +# available, choose the one first in the user's PATH. +m4_defun([_LT_DECL_EGREP], +[AC_REQUIRE([AC_PROG_EGREP])dnl +AC_REQUIRE([AC_PROG_FGREP])dnl +test -z "$GREP" && GREP=grep +_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) +_LT_DECL([], [EGREP], [1], [An ERE matcher]) +_LT_DECL([], [FGREP], [1], [A literal string matcher]) +dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too +AC_SUBST([GREP]) +]) + + +# _LT_DECL_OBJDUMP +# -------------- +# If we don't have a new enough Autoconf to choose the best objdump +# available, choose the one first in the user's PATH. +m4_defun([_LT_DECL_OBJDUMP], +[AC_CHECK_TOOL(OBJDUMP, objdump, false) +test -z "$OBJDUMP" && OBJDUMP=objdump +_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) +AC_SUBST([OBJDUMP]) +]) + +# _LT_DECL_DLLTOOL +# ---------------- +# Ensure DLLTOOL variable is set. +m4_defun([_LT_DECL_DLLTOOL], +[AC_CHECK_TOOL(DLLTOOL, dlltool, false) +test -z "$DLLTOOL" && DLLTOOL=dlltool +_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) +AC_SUBST([DLLTOOL]) +]) + +# _LT_DECL_SED +# ------------ +# Check for a fully-functional sed program, that truncates +# as few characters as possible. Prefer GNU sed if found. +m4_defun([_LT_DECL_SED], +[AC_PROG_SED +test -z "$SED" && SED=sed +Xsed="$SED -e 1s/^X//" +_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) +_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], + [Sed that helps us avoid accidentally triggering echo(1) options like -n]) +])# _LT_DECL_SED + +m4_ifndef([AC_PROG_SED], [ +############################################################ +# NOTE: This macro has been submitted for inclusion into # +# GNU Autoconf as AC_PROG_SED. When it is available in # +# a released version of Autoconf we should remove this # +# macro and use it instead. # +############################################################ + +m4_defun([AC_PROG_SED], +[AC_MSG_CHECKING([for a sed that does not truncate output]) +AC_CACHE_VAL(lt_cv_path_SED, +[# Loop through the user's path and test for sed and gsed. +# Then use that list of sed's as ones to test for truncation. +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for lt_ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then + lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" + fi + done + done +done +IFS=$as_save_IFS +lt_ac_max=0 +lt_ac_count=0 +# Add /usr/xpg4/bin/sed as it is typically found on Solaris +# along with /bin/sed that truncates output. +for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do + test ! -f $lt_ac_sed && continue + cat /dev/null > conftest.in + lt_ac_count=0 + echo $ECHO_N "0123456789$ECHO_C" >conftest.in + # Check for GNU sed and select it if it is found. + if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then + lt_cv_path_SED=$lt_ac_sed + break + fi + while true; do + cat conftest.in conftest.in >conftest.tmp + mv conftest.tmp conftest.in + cp conftest.in conftest.nl + echo >>conftest.nl + $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break + cmp -s conftest.out conftest.nl || break + # 10000 chars as input seems more than enough + test $lt_ac_count -gt 10 && break + lt_ac_count=`expr $lt_ac_count + 1` + if test $lt_ac_count -gt $lt_ac_max; then + lt_ac_max=$lt_ac_count + lt_cv_path_SED=$lt_ac_sed + fi + done +done +]) +SED=$lt_cv_path_SED +AC_SUBST([SED]) +AC_MSG_RESULT([$SED]) +])#AC_PROG_SED +])#m4_ifndef + +# Old name: +AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_SED], []) + + +# _LT_CHECK_SHELL_FEATURES +# ------------------------ +# Find out whether the shell is Bourne or XSI compatible, +# or has some other useful features. +m4_defun([_LT_CHECK_SHELL_FEATURES], +[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) +# Try some XSI features +xsi_shell=no +( _lt_dummy="a/b/c" + test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ + = c,a/b,b/c, \ + && eval 'test $(( 1 + 1 )) -eq 2 \ + && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ + && xsi_shell=yes +AC_MSG_RESULT([$xsi_shell]) +_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) + +AC_MSG_CHECKING([whether the shell understands "+="]) +lt_shell_append=no +( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ + >/dev/null 2>&1 \ + && lt_shell_append=yes +AC_MSG_RESULT([$lt_shell_append]) +_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) + +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + lt_unset=unset +else + lt_unset=false +fi +_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl + +# test EBCDIC or ASCII +case `echo X|tr X '\101'` in + A) # ASCII based system + # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr + lt_SP2NL='tr \040 \012' + lt_NL2SP='tr \015\012 \040\040' + ;; + *) # EBCDIC based system + lt_SP2NL='tr \100 \n' + lt_NL2SP='tr \r\n \100\100' + ;; +esac +_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl +_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl +])# _LT_CHECK_SHELL_FEATURES + + +# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY) +# ------------------------------------------------------ +# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and +# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY. +m4_defun([_LT_PROG_FUNCTION_REPLACE], +[dnl { +sed -e '/^$1 ()$/,/^} # $1 /c\ +$1 ()\ +{\ +m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1]) +} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: +]) + + +# _LT_PROG_REPLACE_SHELLFNS +# ------------------------- +# Replace existing portable implementations of several shell functions with +# equivalent extended shell implementations where those features are available.. +m4_defun([_LT_PROG_REPLACE_SHELLFNS], +[if test x"$xsi_shell" = xyes; then + _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl + case ${1} in + */*) func_dirname_result="${1%/*}${2}" ;; + * ) func_dirname_result="${3}" ;; + esac]) + + _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl + func_basename_result="${1##*/}"]) + + _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl + case ${1} in + */*) func_dirname_result="${1%/*}${2}" ;; + * ) func_dirname_result="${3}" ;; + esac + func_basename_result="${1##*/}"]) + + _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl + # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are + # positional parameters, so assign one to ordinary parameter first. + func_stripname_result=${3} + func_stripname_result=${func_stripname_result#"${1}"} + func_stripname_result=${func_stripname_result%"${2}"}]) + + _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl + func_split_long_opt_name=${1%%=*} + func_split_long_opt_arg=${1#*=}]) + + _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl + func_split_short_opt_arg=${1#??} + func_split_short_opt_name=${1%"$func_split_short_opt_arg"}]) + + _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl + case ${1} in + *.lo) func_lo2o_result=${1%.lo}.${objext} ;; + *) func_lo2o_result=${1} ;; + esac]) + + _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo]) + + _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))]) + + _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}]) +fi + +if test x"$lt_shell_append" = xyes; then + _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"]) + + _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl + func_quote_for_eval "${2}" +dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \ + eval "${1}+=\\\\ \\$func_quote_for_eval_result"]) + + # Save a `func_append' function call where possible by direct use of '+=' + sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +else + # Save a `func_append' function call even when '+=' is not available + sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +fi + +if test x"$_lt_function_replace_fail" = x":"; then + AC_MSG_WARN([Unable to substitute extended shell functions in $ofile]) +fi +]) + +# _LT_PATH_CONVERSION_FUNCTIONS +# ----------------------------- +# Determine which file name conversion functions should be used by +# func_to_host_file (and, implicitly, by func_to_host_path). These are needed +# for certain cross-compile configurations and native mingw. +m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +AC_MSG_CHECKING([how to convert $build file names to $host format]) +AC_CACHE_VAL(lt_cv_to_host_file_cmd, +[case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; + esac + ;; + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; + esac + ;; + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; +esac +]) +to_host_file_cmd=$lt_cv_to_host_file_cmd +AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) +_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], + [0], [convert $build file names to $host format])dnl + +AC_MSG_CHECKING([how to convert $build file names to toolchain format]) +AC_CACHE_VAL(lt_cv_to_tool_file_cmd, +[#assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 + ;; + esac + ;; +esac +]) +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) +_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], + [0], [convert $build files to toolchain format])dnl +])# _LT_PATH_CONVERSION_FUNCTIONS diff --git a/resources/3rdparty/cudd-3.0.0/m4/ltoptions.m4 b/resources/3rdparty/cudd-3.0.0/m4/ltoptions.m4 new file mode 100644 index 000000000..5d9acd8e2 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/m4/ltoptions.m4 @@ -0,0 +1,384 @@ +# Helper functions for option handling. -*- Autoconf -*- +# +# Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation, +# Inc. +# Written by Gary V. Vaughan, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 7 ltoptions.m4 + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) + + +# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) +# ------------------------------------------ +m4_define([_LT_MANGLE_OPTION], +[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) + + +# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) +# --------------------------------------- +# Set option OPTION-NAME for macro MACRO-NAME, and if there is a +# matching handler defined, dispatch to it. Other OPTION-NAMEs are +# saved as a flag. +m4_define([_LT_SET_OPTION], +[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl +m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), + _LT_MANGLE_DEFUN([$1], [$2]), + [m4_warning([Unknown $1 option `$2'])])[]dnl +]) + + +# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) +# ------------------------------------------------------------ +# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. +m4_define([_LT_IF_OPTION], +[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) + + +# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) +# ------------------------------------------------------- +# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME +# are set. +m4_define([_LT_UNLESS_OPTIONS], +[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), + [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), + [m4_define([$0_found])])])[]dnl +m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 +])[]dnl +]) + + +# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) +# ---------------------------------------- +# OPTION-LIST is a space-separated list of Libtool options associated +# with MACRO-NAME. If any OPTION has a matching handler declared with +# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about +# the unknown option and exit. +m4_defun([_LT_SET_OPTIONS], +[# Set options +m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), + [_LT_SET_OPTION([$1], _LT_Option)]) + +m4_if([$1],[LT_INIT],[ + dnl + dnl Simply set some default values (i.e off) if boolean options were not + dnl specified: + _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no + ]) + _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no + ]) + dnl + dnl If no reference was made to various pairs of opposing options, then + dnl we run the default mode handler for the pair. For example, if neither + dnl `shared' nor `disable-shared' was passed, we enable building of shared + dnl archives by default: + _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) + _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) + _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) + _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], + [_LT_ENABLE_FAST_INSTALL]) + ]) +])# _LT_SET_OPTIONS + + +## --------------------------------- ## +## Macros to handle LT_INIT options. ## +## --------------------------------- ## + +# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) +# ----------------------------------------- +m4_define([_LT_MANGLE_DEFUN], +[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) + + +# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) +# ----------------------------------------------- +m4_define([LT_OPTION_DEFINE], +[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl +])# LT_OPTION_DEFINE + + +# dlopen +# ------ +LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes +]) + +AU_DEFUN([AC_LIBTOOL_DLOPEN], +[_LT_SET_OPTION([LT_INIT], [dlopen]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the `dlopen' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) + + +# win32-dll +# --------- +# Declare package support for building win32 dll's. +LT_OPTION_DEFINE([LT_INIT], [win32-dll], +[enable_win32_dll=yes + +case $host in +*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) + AC_CHECK_TOOL(AS, as, false) + AC_CHECK_TOOL(DLLTOOL, dlltool, false) + AC_CHECK_TOOL(OBJDUMP, objdump, false) + ;; +esac + +test -z "$AS" && AS=as +_LT_DECL([], [AS], [1], [Assembler program])dnl + +test -z "$DLLTOOL" && DLLTOOL=dlltool +_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl + +test -z "$OBJDUMP" && OBJDUMP=objdump +_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl +])# win32-dll + +AU_DEFUN([AC_LIBTOOL_WIN32_DLL], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +_LT_SET_OPTION([LT_INIT], [win32-dll]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the `win32-dll' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) + + +# _LT_ENABLE_SHARED([DEFAULT]) +# ---------------------------- +# implement the --enable-shared flag, and supports the `shared' and +# `disable-shared' LT_INIT options. +# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +m4_define([_LT_ENABLE_SHARED], +[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([shared], + [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], + [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac], + [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) + + _LT_DECL([build_libtool_libs], [enable_shared], [0], + [Whether or not to build shared libraries]) +])# _LT_ENABLE_SHARED + +LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) + +# Old names: +AC_DEFUN([AC_ENABLE_SHARED], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) +]) + +AC_DEFUN([AC_DISABLE_SHARED], +[_LT_SET_OPTION([LT_INIT], [disable-shared]) +]) + +AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) +AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_ENABLE_SHARED], []) +dnl AC_DEFUN([AM_DISABLE_SHARED], []) + + + +# _LT_ENABLE_STATIC([DEFAULT]) +# ---------------------------- +# implement the --enable-static flag, and support the `static' and +# `disable-static' LT_INIT options. +# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +m4_define([_LT_ENABLE_STATIC], +[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([static], + [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], + [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac], + [enable_static=]_LT_ENABLE_STATIC_DEFAULT) + + _LT_DECL([build_old_libs], [enable_static], [0], + [Whether or not to build static libraries]) +])# _LT_ENABLE_STATIC + +LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) + +# Old names: +AC_DEFUN([AC_ENABLE_STATIC], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) +]) + +AC_DEFUN([AC_DISABLE_STATIC], +[_LT_SET_OPTION([LT_INIT], [disable-static]) +]) + +AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) +AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_ENABLE_STATIC], []) +dnl AC_DEFUN([AM_DISABLE_STATIC], []) + + + +# _LT_ENABLE_FAST_INSTALL([DEFAULT]) +# ---------------------------------- +# implement the --enable-fast-install flag, and support the `fast-install' +# and `disable-fast-install' LT_INIT options. +# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +m4_define([_LT_ENABLE_FAST_INSTALL], +[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([fast-install], + [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], + [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac], + [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) + +_LT_DECL([fast_install], [enable_fast_install], [0], + [Whether or not to optimize for fast installation])dnl +])# _LT_ENABLE_FAST_INSTALL + +LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) + +# Old names: +AU_DEFUN([AC_ENABLE_FAST_INSTALL], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you put +the `fast-install' option into LT_INIT's first parameter.]) +]) + +AU_DEFUN([AC_DISABLE_FAST_INSTALL], +[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you put +the `disable-fast-install' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) +dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) + + +# _LT_WITH_PIC([MODE]) +# -------------------- +# implement the --with-pic flag, and support the `pic-only' and `no-pic' +# LT_INIT options. +# MODE is either `yes' or `no'. If omitted, it defaults to `both'. +m4_define([_LT_WITH_PIC], +[AC_ARG_WITH([pic], + [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], + [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], + [lt_p=${PACKAGE-default} + case $withval in + yes|no) pic_mode=$withval ;; + *) + pic_mode=default + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for lt_pkg in $withval; do + IFS="$lt_save_ifs" + if test "X$lt_pkg" = "X$lt_p"; then + pic_mode=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac], + [pic_mode=default]) + +test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) + +_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl +])# _LT_WITH_PIC + +LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) +LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) + +# Old name: +AU_DEFUN([AC_LIBTOOL_PICMODE], +[_LT_SET_OPTION([LT_INIT], [pic-only]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the `pic-only' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) + +## ----------------- ## +## LTDL_INIT Options ## +## ----------------- ## + +m4_define([_LTDL_MODE], []) +LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], + [m4_define([_LTDL_MODE], [nonrecursive])]) +LT_OPTION_DEFINE([LTDL_INIT], [recursive], + [m4_define([_LTDL_MODE], [recursive])]) +LT_OPTION_DEFINE([LTDL_INIT], [subproject], + [m4_define([_LTDL_MODE], [subproject])]) + +m4_define([_LTDL_TYPE], []) +LT_OPTION_DEFINE([LTDL_INIT], [installable], + [m4_define([_LTDL_TYPE], [installable])]) +LT_OPTION_DEFINE([LTDL_INIT], [convenience], + [m4_define([_LTDL_TYPE], [convenience])]) diff --git a/resources/3rdparty/cudd-3.0.0/m4/ltsugar.m4 b/resources/3rdparty/cudd-3.0.0/m4/ltsugar.m4 new file mode 100644 index 000000000..9000a057d --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/m4/ltsugar.m4 @@ -0,0 +1,123 @@ +# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- +# +# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. +# Written by Gary V. Vaughan, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 6 ltsugar.m4 + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) + + +# lt_join(SEP, ARG1, [ARG2...]) +# ----------------------------- +# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their +# associated separator. +# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier +# versions in m4sugar had bugs. +m4_define([lt_join], +[m4_if([$#], [1], [], + [$#], [2], [[$2]], + [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) +m4_define([_lt_join], +[m4_if([$#$2], [2], [], + [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) + + +# lt_car(LIST) +# lt_cdr(LIST) +# ------------ +# Manipulate m4 lists. +# These macros are necessary as long as will still need to support +# Autoconf-2.59 which quotes differently. +m4_define([lt_car], [[$1]]) +m4_define([lt_cdr], +[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], + [$#], 1, [], + [m4_dquote(m4_shift($@))])]) +m4_define([lt_unquote], $1) + + +# lt_append(MACRO-NAME, STRING, [SEPARATOR]) +# ------------------------------------------ +# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'. +# Note that neither SEPARATOR nor STRING are expanded; they are appended +# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). +# No SEPARATOR is output if MACRO-NAME was previously undefined (different +# than defined and empty). +# +# This macro is needed until we can rely on Autoconf 2.62, since earlier +# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. +m4_define([lt_append], +[m4_define([$1], + m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) + + + +# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) +# ---------------------------------------------------------- +# Produce a SEP delimited list of all paired combinations of elements of +# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list +# has the form PREFIXmINFIXSUFFIXn. +# Needed until we can rely on m4_combine added in Autoconf 2.62. +m4_define([lt_combine], +[m4_if(m4_eval([$# > 3]), [1], + [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl +[[m4_foreach([_Lt_prefix], [$2], + [m4_foreach([_Lt_suffix], + ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, + [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) + + +# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) +# ----------------------------------------------------------------------- +# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited +# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. +m4_define([lt_if_append_uniq], +[m4_ifdef([$1], + [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], + [lt_append([$1], [$2], [$3])$4], + [$5])], + [lt_append([$1], [$2], [$3])$4])]) + + +# lt_dict_add(DICT, KEY, VALUE) +# ----------------------------- +m4_define([lt_dict_add], +[m4_define([$1($2)], [$3])]) + + +# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) +# -------------------------------------------- +m4_define([lt_dict_add_subkey], +[m4_define([$1($2:$3)], [$4])]) + + +# lt_dict_fetch(DICT, KEY, [SUBKEY]) +# ---------------------------------- +m4_define([lt_dict_fetch], +[m4_ifval([$3], + m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), + m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) + + +# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) +# ----------------------------------------------------------------- +m4_define([lt_if_dict_fetch], +[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], + [$5], + [$6])]) + + +# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) +# -------------------------------------------------------------- +m4_define([lt_dict_filter], +[m4_if([$5], [], [], + [lt_join(m4_quote(m4_default([$4], [[, ]])), + lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), + [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl +]) diff --git a/resources/3rdparty/cudd-3.0.0/m4/ltversion.m4 b/resources/3rdparty/cudd-3.0.0/m4/ltversion.m4 new file mode 100644 index 000000000..07a8602d4 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/m4/ltversion.m4 @@ -0,0 +1,23 @@ +# ltversion.m4 -- version numbers -*- Autoconf -*- +# +# Copyright (C) 2004 Free Software Foundation, Inc. +# Written by Scott James Remnant, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# @configure_input@ + +# serial 3337 ltversion.m4 +# This file is part of GNU Libtool + +m4_define([LT_PACKAGE_VERSION], [2.4.2]) +m4_define([LT_PACKAGE_REVISION], [1.3337]) + +AC_DEFUN([LTVERSION_VERSION], +[macro_version='2.4.2' +macro_revision='1.3337' +_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) +_LT_DECL(, macro_revision, 0) +]) diff --git a/resources/3rdparty/cudd-3.0.0/m4/lt~obsolete.m4 b/resources/3rdparty/cudd-3.0.0/m4/lt~obsolete.m4 new file mode 100644 index 000000000..c573da90c --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/m4/lt~obsolete.m4 @@ -0,0 +1,98 @@ +# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- +# +# Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc. +# Written by Scott James Remnant, 2004. +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 5 lt~obsolete.m4 + +# These exist entirely to fool aclocal when bootstrapping libtool. +# +# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN) +# which have later been changed to m4_define as they aren't part of the +# exported API, or moved to Autoconf or Automake where they belong. +# +# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN +# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us +# using a macro with the same name in our local m4/libtool.m4 it'll +# pull the old libtool.m4 in (it doesn't see our shiny new m4_define +# and doesn't know about Autoconf macros at all.) +# +# So we provide this file, which has a silly filename so it's always +# included after everything else. This provides aclocal with the +# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything +# because those macros already exist, or will be overwritten later. +# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. +# +# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. +# Yes, that means every name once taken will need to remain here until +# we give up compatibility with versions before 1.7, at which point +# we need to keep only those names which we still refer to. + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) + +m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) +m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) +m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) +m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) +m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) +m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) +m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) +m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) +m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) +m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) +m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) +m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) +m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) +m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) +m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) +m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) +m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) +m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) +m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) +m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) +m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) +m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) +m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) +m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) +m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) +m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) +m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) +m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) +m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) +m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) +m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) +m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) +m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) +m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) +m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) +m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) +m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) +m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) +m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) +m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) +m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) +m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) +m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) +m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) +m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) +m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) +m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) +m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) +m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) +m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) +m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) +m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) +m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) +m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) +m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) +m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) +m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) diff --git a/resources/3rdparty/cudd-3.0.0/m4/modern_cxx.m4 b/resources/3rdparty/cudd-3.0.0/m4/modern_cxx.m4 new file mode 100644 index 000000000..3b4e08cdd --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/m4/modern_cxx.m4 @@ -0,0 +1,15 @@ +# MODERN_CXX +# ---------- +# Check whether the C++ compiler supports enough of C++11. +AC_DEFUN([MODERN_CXX], +[AC_CACHE_CHECK([whether enough of C++11 is supported], +[ac_cv_have_modern_cxx], +[AC_LANG_PUSH([C++]) + AC_COMPILE_IFELSE([AC_LANG_SOURCE([[ +class Myclass { explicit operator bool() const { return true; } }; +int main() { + void *p = nullptr; +}]])], [ac_cv_have_modern_cxx=yes], [ac_cv_have_modern_cxx=no]) + AC_LANG_POP([C++])])dnl +])# MODERN_CXX + diff --git a/resources/3rdparty/cudd-3.0.0/m4/w32.m4 b/resources/3rdparty/cudd-3.0.0/m4/w32.m4 new file mode 100644 index 000000000..f164e93a4 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/m4/w32.m4 @@ -0,0 +1,12 @@ +# MINGW_AC_WIN32_NATIVE_HOST +# -------------------------- +# Check whether the runtime platform is a native Win32 host. +# +AC_DEFUN([MINGW_AC_WIN32_NATIVE_HOST], +[AC_CACHE_CHECK([whether we are building for a Win32 host], +[mingw_cv_win32_host], + AC_COMPILE_IFELSE([AC_LANG_SOURCE([[ +#ifdef _WIN32 + choke me +#endif]])], [mingw_cv_win32_host=no], [mingw_cv_win32_host=yes]))dnl +])# MINGW_AC_WIN32_NATIVE_HOST diff --git a/resources/3rdparty/cudd-3.0.0/mtr/Included.am b/resources/3rdparty/cudd-3.0.0/mtr/Included.am new file mode 100644 index 000000000..d50489d95 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/mtr/Included.am @@ -0,0 +1,19 @@ +cudd_libcudd_la_SOURCES += mtr/mtr.h mtr/mtrInt.h mtr/mtrBasic.c mtr/mtrGroup.c + +check_PROGRAMS += mtr/testmtr +mtr_testmtr_SOURCES = mtr/testmtr.c +mtr_testmtr_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +mtr_testmtr_LDADD = cudd/libcudd.la + +check_SCRIPTS += mtr/test_mtr.test +dist_check_DATA += mtr/test.groups mtr/test.out +EXTRA_DIST += mtr/test_mtr.test.in +if !CROSS_COMPILING +TESTS += mtr/test_mtr.test +endif !CROSS_COMPILING + +mtr/test_mtr.test: mtr/test_mtr.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ + +CLEANFILES += mtr/test.tst diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/mtr.h b/resources/3rdparty/cudd-3.0.0/mtr/mtr.h similarity index 53% rename from resources/3rdparty/cudd-2.5.0/src/mtr/mtr.h rename to resources/3rdparty/cudd-3.0.0/mtr/mtr.h index 9cbb2d3a4..12590f7e3 100644 --- a/resources/3rdparty/cudd-2.5.0/src/mtr/mtr.h +++ b/resources/3rdparty/cudd-3.0.0/mtr/mtr.h @@ -1,26 +1,26 @@ -/**CHeaderFile***************************************************************** +/** + @file - FileName [mtr.h] + @ingroup mtr - PackageName [mtr] + @brief Multiway-branch tree manipulation - Synopsis [Multiway-branch tree manipulation] - - Description [This package provides two layers of functions. Functions + @details This package provides two layers of functions. Functions of the lower level manipulate multiway-branch trees, implemented according to the classical scheme whereby each node points to its first child and its previous and next siblings. These functions are collected in mtrBasic.c.<p> Functions of the upper layer deal with group trees, that is the trees used by group sifting to represent the grouping of variables. These - functions are collected in mtrGroup.c.] + functions are collected in mtrGroup.c. - SeeAlso [The CUDD package documentation; specifically on group - sifting.] + @see The CUDD package documentation; specifically on group + sifting. - Author [Fabio Somenzi] + @author Fabio Somenzi - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -50,19 +50,20 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] - - Revision [$Id: mtr.h,v 1.17 2012/02/05 01:06:19 fabio Exp $] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ -#ifndef __MTR -#define __MTR +#ifndef MTR_H_ +#define MTR_H_ /*---------------------------------------------------------------------------*/ /* Nested includes */ /*---------------------------------------------------------------------------*/ +#include <stdio.h> + #ifdef __cplusplus extern "C" { #endif @@ -71,25 +72,6 @@ extern "C" { /* Constant declarations */ /*---------------------------------------------------------------------------*/ -#ifndef SIZEOF_VOID_P -#define SIZEOF_VOID_P 4 -#endif -#ifndef SIZEOF_INT -#define SIZEOF_INT 4 -#endif - -#if defined(__GNUC__) -#define MTR_INLINE __inline__ -# if (__GNUC__ >2 || __GNUC_MINOR__ >=7) -# define MTR_UNUSED __attribute__ ((unused)) -# else -# define MTR_UNUSED -# endif -#else -#define MTR_INLINE -#define MTR_UNUSED -#endif - /* Flag definitions */ #define MTR_DEFAULT 0x00000000 #define MTR_TERMINAL 0x00000001 @@ -97,17 +79,6 @@ extern "C" { #define MTR_FIXED 0x00000004 #define MTR_NEWNODE 0x00000008 -/* MTR_MAXHIGH is defined in such a way that on 32-bit and 64-bit -** machines one can cast a value to (int) without generating a negative -** number. -*/ -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 -#define MTR_MAXHIGH (((MtrHalfWord) ~0) >> 1) -#else -#define MTR_MAXHIGH ((MtrHalfWord) ~0) -#endif - - /*---------------------------------------------------------------------------*/ /* Stucture declarations */ /*---------------------------------------------------------------------------*/ @@ -117,23 +88,10 @@ extern "C" { /* Type declarations */ /*---------------------------------------------------------------------------*/ -#if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 -typedef unsigned int MtrHalfWord; -#else -typedef unsigned short MtrHalfWord; -#endif - -typedef struct MtrNode { - MtrHalfWord flags; - MtrHalfWord low; - MtrHalfWord size; - MtrHalfWord index; - struct MtrNode *parent; - struct MtrNode *child; - struct MtrNode *elder; - struct MtrNode *younger; -} MtrNode; - +/** + * @brief multi-way tree node. + */ +typedef struct MtrNode_ MtrNode; /*---------------------------------------------------------------------------*/ /* Variable declarations */ @@ -144,44 +102,33 @@ typedef struct MtrNode { /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/* Flag manipulation macros */ -#define MTR_SET(node, flag) (node->flags |= (flag)) -#define MTR_RESET(node, flag) (node->flags &= ~ (flag)) -#define MTR_TEST(node, flag) (node->flags & (flag)) - - -/**AutomaticStart*************************************************************/ - /*---------------------------------------------------------------------------*/ /* Function prototypes */ /*---------------------------------------------------------------------------*/ -extern MtrNode * Mtr_AllocNode (void); -extern void Mtr_DeallocNode (MtrNode *node); -extern MtrNode * Mtr_InitTree (void); -extern void Mtr_FreeTree (MtrNode *node); -extern MtrNode * Mtr_CopyTree (MtrNode *node, int expansion); -extern void Mtr_MakeFirstChild (MtrNode *parent, MtrNode *child); -extern void Mtr_MakeLastChild (MtrNode *parent, MtrNode *child); -extern MtrNode * Mtr_CreateFirstChild (MtrNode *parent); -extern MtrNode * Mtr_CreateLastChild (MtrNode *parent); -extern void Mtr_MakeNextSibling (MtrNode *first, MtrNode *second); -extern void Mtr_PrintTree (MtrNode *node); -extern MtrNode * Mtr_InitGroupTree (int lower, int size); -extern MtrNode * Mtr_MakeGroup (MtrNode *root, unsigned int low, unsigned int high, unsigned int flags); -extern MtrNode * Mtr_DissolveGroup (MtrNode *group); -extern MtrNode * Mtr_FindGroup (MtrNode *root, unsigned int low, unsigned int high); -extern int Mtr_SwapGroups (MtrNode *first, MtrNode *second); -extern void Mtr_ReorderGroups(MtrNode *treenode, int *permutation); - -extern void Mtr_PrintGroups (MtrNode *root, int silent); - extern int Mtr_PrintGroupedOrder(MtrNode * root, int *invperm, FILE *fp); -extern MtrNode * Mtr_ReadGroups (FILE *fp, int nleaves); - -/**AutomaticEnd***************************************************************/ +MtrNode * Mtr_AllocNode(void); +void Mtr_DeallocNode(MtrNode *node); +MtrNode * Mtr_InitTree(void); +void Mtr_FreeTree(MtrNode *node); +MtrNode * Mtr_CopyTree(MtrNode const *node, int expansion); +void Mtr_MakeFirstChild(MtrNode *parent, MtrNode *child); +void Mtr_MakeLastChild(MtrNode *parent, MtrNode *child); +MtrNode * Mtr_CreateFirstChild(MtrNode *parent); +MtrNode * Mtr_CreateLastChild(MtrNode *parent); +void Mtr_MakeNextSibling(MtrNode *first, MtrNode *second); +void Mtr_PrintTree(MtrNode const *node); +MtrNode * Mtr_InitGroupTree(int lower, int size); +MtrNode * Mtr_MakeGroup(MtrNode *root, unsigned int low, unsigned int high, unsigned int flags); +MtrNode * Mtr_DissolveGroup(MtrNode *group); +MtrNode * Mtr_FindGroup(MtrNode *root, unsigned int low, unsigned int high); +int Mtr_SwapGroups(MtrNode *first, MtrNode *second); +void Mtr_ReorderGroups(MtrNode *treenode, int *permutation); +void Mtr_PrintGroups(MtrNode const *root, int silent); +int Mtr_PrintGroupedOrder(MtrNode const * root, int const *invperm, FILE *fp); +MtrNode * Mtr_ReadGroups(FILE *fp, int nleaves); #ifdef __cplusplus } #endif -#endif /* __MTR */ +#endif /* MTR_H_ */ diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/mtrBasic.c b/resources/3rdparty/cudd-3.0.0/mtr/mtrBasic.c similarity index 56% rename from resources/3rdparty/cudd-2.5.0/src/mtr/mtrBasic.c rename to resources/3rdparty/cudd-3.0.0/mtr/mtrBasic.c index f91c63430..fd98894f8 100644 --- a/resources/3rdparty/cudd-2.5.0/src/mtr/mtrBasic.c +++ b/resources/3rdparty/cudd-3.0.0/mtr/mtrBasic.c @@ -1,32 +1,16 @@ -/**CFile*********************************************************************** +/** + @file - FileName [mtrBasic.c] + @ingroup mtr - PackageName [mtr] + @brief Basic manipulation of multiway branching trees. - Synopsis [Basic manipulation of multiway branching trees.] + @see cudd package - Description [External procedures included in this module: - <ul> - <li> Mtr_AllocNode() - <li> Mtr_DeallocNode() - <li> Mtr_InitTree() - <li> Mtr_FreeTree() - <li> Mtr_CopyTree() - <li> Mtr_MakeFirstChild() - <li> Mtr_MakeLastChild() - <li> Mtr_CreateFirstChild() - <li> Mtr_CreateLastChild() - <li> Mtr_MakeNextSibling() - <li> Mtr_PrintTree() - </ul> - ] + @author Fabio Somenzi - SeeAlso [cudd package] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -56,9 +40,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "mtrInt.h" @@ -80,64 +65,57 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] MTR_UNUSED = "$Id: mtrBasic.c,v 1.15 2012/02/05 01:06:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ - -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Allocates new tree node.] +/** + @brief Allocates new tree node. - Description [Allocates new tree node. Returns pointer to node.] + @return pointer to node. - SideEffects [None] + @sideeffect None - SeeAlso [Mtr_DeallocNode] + @see Mtr_DeallocNode -******************************************************************************/ +*/ MtrNode * Mtr_AllocNode(void) { MtrNode *node; node = ALLOC(MtrNode,1); + node->flags = node->low = node->size = node->index = 0; return node; } /* Mtr_AllocNode */ -/**Function******************************************************************** - - Synopsis [Deallocates tree node.] +/** + @brief Deallocates tree node. - Description [] + @sideeffect None - SideEffects [None] + @see Mtr_AllocNode - SeeAlso [Mtr_AllocNode] - -******************************************************************************/ +*/ void Mtr_DeallocNode( - MtrNode * node /* node to be deallocated */) + MtrNode * node /**< node to be deallocated */) { FREE(node); return; @@ -145,17 +123,16 @@ Mtr_DeallocNode( } /* end of Mtr_DeallocNode */ -/**Function******************************************************************** - - Synopsis [Initializes tree with one node.] +/** + @brief Initializes tree with one node. - Description [Initializes tree with one node. Returns pointer to node.] + @return pointer to node. - SideEffects [None] + @sideeffect None - SeeAlso [Mtr_FreeTree Mtr_InitGroupTree] + @see Mtr_FreeTree Mtr_InitGroupTree -******************************************************************************/ +*/ MtrNode * Mtr_InitTree(void) { @@ -165,24 +142,20 @@ Mtr_InitTree(void) if (node == NULL) return(NULL); node->parent = node->child = node->elder = node->younger = NULL; - node->flags = 0; return(node); } /* end of Mtr_InitTree */ -/**Function******************************************************************** - - Synopsis [Disposes of tree rooted at node.] +/** + @brief Disposes of tree rooted at node. - Description [] + @sideeffect None - SideEffects [None] + @see Mtr_InitTree - SeeAlso [Mtr_InitTree] - -******************************************************************************/ +*/ void Mtr_FreeTree( MtrNode * node) @@ -196,23 +169,23 @@ Mtr_FreeTree( } /* end of Mtr_FreeTree */ -/**Function******************************************************************** +/** + @brief Makes a copy of tree. - Synopsis [Makes a copy of tree.] + @details If parameter expansion is greater than 1, it will expand + the tree by that factor. It is an error for expansion to be less + than 1. - Description [Makes a copy of tree. If parameter expansion is greater - than 1, it will expand the tree by that factor. It is an error for - expansion to be less than 1. Returns a pointer to the copy if - successful; NULL otherwise.] + @return a pointer to the copy if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Mtr_InitTree] + @see Mtr_InitTree -******************************************************************************/ +*/ MtrNode * Mtr_CopyTree( - MtrNode * node, + MtrNode const * node, int expansion) { MtrNode *copy; @@ -253,17 +226,14 @@ Mtr_CopyTree( } /* end of Mtr_CopyTree */ -/**Function******************************************************************** - - Synopsis [Makes child the first child of parent.] +/** + @brief Makes child the first child of parent. - Description [] + @sideeffect None - SideEffects [None] + @see Mtr_MakeLastChild Mtr_CreateFirstChild - SeeAlso [Mtr_MakeLastChild Mtr_CreateFirstChild] - -******************************************************************************/ +*/ void Mtr_MakeFirstChild( MtrNode * parent, @@ -284,17 +254,14 @@ Mtr_MakeFirstChild( } /* end of Mtr_MakeFirstChild */ -/**Function******************************************************************** - - Synopsis [Makes child the last child of parent.] - - Description [] +/** + @brief Makes child the last child of parent. - SideEffects [None] + @sideeffect None - SeeAlso [Mtr_MakeFirstChild Mtr_CreateLastChild] + @see Mtr_MakeFirstChild Mtr_CreateLastChild -******************************************************************************/ +*/ void Mtr_MakeLastChild( MtrNode * parent, @@ -320,18 +287,16 @@ Mtr_MakeLastChild( } /* end of Mtr_MakeLastChild */ -/**Function******************************************************************** +/** + @brief Creates a new node and makes it the first child of parent. - Synopsis [Creates a new node and makes it the first child of parent.] + @return pointer to new child. - Description [Creates a new node and makes it the first child of - parent. Returns pointer to new child.] + @sideeffect None - SideEffects [None] + @see Mtr_MakeFirstChild Mtr_CreateLastChild - SeeAlso [Mtr_MakeFirstChild Mtr_CreateLastChild] - -******************************************************************************/ +*/ MtrNode * Mtr_CreateFirstChild( MtrNode * parent) @@ -342,25 +307,22 @@ Mtr_CreateFirstChild( if (child == NULL) return(NULL); child->child = NULL; - child->flags = 0; Mtr_MakeFirstChild(parent,child); return(child); } /* end of Mtr_CreateFirstChild */ -/**Function******************************************************************** - - Synopsis [Creates a new node and makes it the last child of parent.] +/** + @brief Creates a new node and makes it the last child of parent. - Description [Creates a new node and makes it the last child of parent. - Returns pointer to new child.] + @return pointer to new child. - SideEffects [None] + @sideeffect None - SeeAlso [Mtr_MakeLastChild Mtr_CreateFirstChild] + @see Mtr_MakeLastChild Mtr_CreateFirstChild -******************************************************************************/ +*/ MtrNode * Mtr_CreateLastChild( MtrNode * parent) @@ -371,25 +333,20 @@ Mtr_CreateLastChild( if (child == NULL) return(NULL); child->child = NULL; - child->flags = 0; Mtr_MakeLastChild(parent,child); return(child); } /* end of Mtr_CreateLastChild */ -/**Function******************************************************************** - - Synopsis [Makes second the next sibling of first.] +/** + @brief Makes second the next sibling of first. - Description [Makes second the next sibling of first. Second becomes a - child of the parent of first.] + @details Second becomes a child of the parent of first. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ void Mtr_MakeNextSibling( MtrNode * first, @@ -407,34 +364,25 @@ Mtr_MakeNextSibling( } /* end of Mtr_MakeNextSibling */ -/**Function******************************************************************** - - Synopsis [Prints a tree, one node per line.] - - Description [] +/** + @brief Prints a tree, one node per line. - SideEffects [None] + @sideeffect None - SeeAlso [Mtr_PrintGroups] + @see Mtr_PrintGroups -******************************************************************************/ +*/ void Mtr_PrintTree( - MtrNode * node) + MtrNode const * node) { if (node == NULL) return; (void) fprintf(stdout, -#if SIZEOF_VOID_P == 8 - "N=0x%-8lx C=0x%-8lx Y=0x%-8lx E=0x%-8lx P=0x%-8lx F=%x L=%u S=%u\n", - (unsigned long) node, (unsigned long) node->child, - (unsigned long) node->younger, (unsigned long) node->elder, - (unsigned long) node->parent, node->flags, node->low, node->size); -#else - "N=0x%-8x C=0x%-8x Y=0x%-8x E=0x%-8x P=0x%-8x F=%x L=%hu S=%hu\n", - (unsigned) node, (unsigned) node->child, - (unsigned) node->younger, (unsigned) node->elder, - (unsigned) node->parent, node->flags, node->low, node->size); -#endif + "N=0x%-8" PRIxPTR " C=0x%-8" PRIxPTR " Y=0x%-8" PRIxPTR + " E=0x%-8" PRIxPTR " P=0x%-8" PRIxPTR " F=%x L=%u S=%u\n", + (uintptr_t) node, (uintptr_t) node->child, + (uintptr_t) node->younger, (uintptr_t) node->elder, + (uintptr_t) node->parent, node->flags, node->low, node->size); if (!MTR_TEST(node,MTR_TERMINAL)) Mtr_PrintTree(node->child); Mtr_PrintTree(node->younger); return; diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/mtrGroup.c b/resources/3rdparty/cudd-3.0.0/mtr/mtrGroup.c similarity index 73% rename from resources/3rdparty/cudd-2.5.0/src/mtr/mtrGroup.c rename to resources/3rdparty/cudd-3.0.0/mtr/mtrGroup.c index 4269cf848..899a0d458 100644 --- a/resources/3rdparty/cudd-2.5.0/src/mtr/mtrGroup.c +++ b/resources/3rdparty/cudd-3.0.0/mtr/mtrGroup.c @@ -1,33 +1,16 @@ -/**CFile*********************************************************************** +/** + @file - FileName [mtrGroup.c] + @ingroup mtr - PackageName [mtr] + @brief Functions to support group specification for reordering. - Synopsis [Functions to support group specification for reordering.] + @see cudd package - Description [External procedures included in this module: - <ul> - <li> Mtr_InitGroupTree() - <li> Mtr_MakeGroup() - <li> Mtr_DissolveGroup() - <li> Mtr_FindGroup() - <li> Mtr_SwapGroups() - <li> Mtr_ReorderGroups() - <li> Mtr_PrintGroups() - <li> Mtr_ReadGroups() - </ul> - Static procedures included in this module: - <ul> - <li> mtrShiftHL - </ul> - ] + @author Fabio Somenzi - SeeAlso [cudd package] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -57,9 +40,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "util.h" #include "mtrInt.h" @@ -80,15 +64,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] MTR_UNUSED = "$Id: mtrGroup.c,v 1.21 2012/02/05 01:06:19 fabio Exp $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -96,26 +77,26 @@ static char rcsid[] MTR_UNUSED = "$Id: mtrGroup.c,v 1.21 2012/02/05 01:06:19 fab static int mtrShiftHL (MtrNode *node, int shift); -/**AutomaticEnd***************************************************************/ +/** \endcond */ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Allocate new tree. - Synopsis [Allocate new tree.] - - Description [Allocate new tree with one node, whose low and size + @details Allocate new tree with one node, whose low and size fields are specified by the lower and size parameters. - Returns pointer to tree root.] - SideEffects [None] + @return pointer to tree root. + + @sideeffect None - SeeAlso [Mtr_InitTree Mtr_FreeTree] + @see Mtr_InitTree Mtr_FreeTree -******************************************************************************/ +*/ MtrNode * Mtr_InitGroupTree( int lower, @@ -133,31 +114,31 @@ Mtr_InitGroupTree( } /* end of Mtr_InitGroupTree */ -/**Function******************************************************************** +/** + @brief Makes a new group with size leaves starting at low. - Synopsis [Makes a new group with size leaves starting at low.] - - Description [Makes a new group with size leaves starting at low. - If the new group intersects an existing group, it must + @details If the new group intersects an existing group, it must either contain it or be contained by it. This procedure relies on the low and size fields of each node. It also assumes that the children of each node are sorted in order of increasing low. In case of a valid request, the flags of the new group are set to the - value passed in `flags.' Returns the pointer to the root of the new - group upon successful termination; NULL otherwise. If the group - already exists, the pointer to its root is returned.] + value passed in `flags.' + + @return the pointer to the root of the new group upon successful + termination; NULL otherwise. If the group already exists, the + pointer to its root is returned. - SideEffects [None] + @sideeffect None - SeeAlso [Mtr_DissolveGroup Mtr_ReadGroups Mtr_FindGroup] + @see Mtr_DissolveGroup Mtr_ReadGroups Mtr_FindGroup -******************************************************************************/ +*/ MtrNode * Mtr_MakeGroup( - MtrNode * root /* root of the group tree */, - unsigned int low /* lower bound of the group */, - unsigned int size /* size of the group */, - unsigned int flags /* flags for the new group */) + MtrNode * root /**< root of the group tree */, + unsigned int low /**< lower bound of the group */, + unsigned int size /**< size of the group */, + unsigned int flags /**< flags for the new group */) { MtrNode *node, *first, @@ -257,9 +238,9 @@ Mtr_MakeGroup( /* First holds the pointer to the first child contained in the new ** group. Here low <= first->low and low + size >= first->low + ** first->size. One of the two inequalities is strict. */ - last = first->younger; - while (last != NULL && - (unsigned int) (last->low + last->size) < low + size) { + last = first; + while (last->younger != NULL && + (unsigned int) (last->younger->low + last->younger->size) <= low + size) { last = last->younger; } if (last == NULL) { @@ -329,25 +310,24 @@ Mtr_MakeGroup( } /* end of Mtr_MakeGroup */ -/**Function******************************************************************** +/** + @brief Merges the children of `group' with the children of its + parent. - Synopsis [Merges the children of `group' with the children of its - parent.] + @details Disposes of the node pointed by group. If group is the root + of the group tree, this procedure leaves the tree unchanged. - Description [Merges the children of `group' with the children of its - parent. Disposes of the node pointed by group. If group is the - root of the group tree, this procedure leaves the tree unchanged. - Returns the pointer to the parent of `group' upon successful - termination; NULL otherwise.] + @return the pointer to the parent of `group' upon successful + termination; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Mtr_MakeGroup] + @see Mtr_MakeGroup -******************************************************************************/ +*/ MtrNode * Mtr_DissolveGroup( - MtrNode * group /* group to be dissolved */) + MtrNode * group /**< group to be dissolved */) { MtrNode *parent; MtrNode *last; @@ -382,26 +362,24 @@ Mtr_DissolveGroup( } /* end of Mtr_DissolveGroup */ -/**Function******************************************************************** +/** + @brief Finds a group with size leaves starting at low, if it exists. - Synopsis [Finds a group with size leaves starting at low, if it exists.] - - Description [Finds a group with size leaves starting at low, if it - exists. This procedure relies on the low and size fields of each + @details This procedure relies on the low and size fields of each node. It also assumes that the children of each node are sorted in - order of increasing low. Returns the pointer to the root of the - group upon successful termination; NULL otherwise.] + order of increasing low. - SideEffects [None] + @return the pointer to the root of the group upon successful + termination; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ MtrNode * Mtr_FindGroup( - MtrNode * root /* root of the group tree */, - unsigned int low /* lower bound of the group */, - unsigned int size /* upper bound of the group */) + MtrNode * root /**< root of the group tree */, + unsigned int low /**< lower bound of the group */, + unsigned int size /**< upper bound of the group */) { MtrNode *node; @@ -444,24 +422,22 @@ Mtr_FindGroup( } /* end of Mtr_FindGroup */ -/**Function******************************************************************** - - Synopsis [Swaps two children of a tree node.] +/** + @brief Swaps two children of a tree node. - Description [Swaps two children of a tree node. Adjusts the high and - low fields of the two nodes and their descendants. The two children - must be adjacent. However, first may be the younger sibling of second. - Returns 1 in case of success; 0 otherwise.] + @details Adjusts the high and low fields of the two nodes and their + descendants. The two children must be adjacent. However, first may + be the younger sibling of second. - SideEffects [None] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Mtr_SwapGroups( - MtrNode * first /* first node to be swapped */, - MtrNode * second /* second node to be swapped */) + MtrNode * first /**< first node to be swapped */, + MtrNode * second /**< second node to be swapped */) { MtrNode *node; MtrNode *parent; @@ -504,22 +480,19 @@ Mtr_SwapGroups( } /* end of Mtr_SwapGroups */ -/**Function******************************************************************** +/** + @brief Fix variable tree at the end of tree sifting. - Synopsis [Fix variable tree at the end of tree sifting.] - - Description [Fix the levels in the variable tree sorting siblings + @details Fix the levels in the variable tree sorting siblings according to them. It should be called on a non-NULL tree. It then maintains this invariant. It applies insertion sorting to the list of siblings The order is determined by permutation, which is used to find the new level of the node index. Index must refer to the first variable - in the group.] - - SideEffects [The tree is modified.] + in the group. - SeeAlso [] + @sideeffect The tree is modified. -******************************************************************************/ +*/ void Mtr_ReorderGroups( MtrNode *treenode, @@ -570,13 +543,11 @@ Mtr_ReorderGroups( } /* end of Mtr_ReorderGroups */ -/**Function******************************************************************** +/** + @brief Prints the groups as a parenthesized list. - Synopsis [Prints the groups as a parenthesized list.] - - Description [Prints the groups as a parenthesized list. After each - group, the group's flag are printed, preceded by a `|'. For each - flag (except MTR_TERMINAL) a character is printed. + @details After each group, the group's flag are printed, preceded by a `|'. + For each flag (except MTR_TERMINAL) a character is printed. <ul> <li>F: MTR_FIXED <li>N: MTR_NEWNODE @@ -584,17 +555,16 @@ Mtr_ReorderGroups( </ul> The second argument, silent, if different from 0, causes Mtr_PrintGroups to only check the syntax of the group tree. - ] - SideEffects [None] + @sideeffect None - SeeAlso [Mtr_PrintTree] + @see Mtr_PrintTree -******************************************************************************/ +*/ void Mtr_PrintGroups( - MtrNode * root /* root of the group tree */, - int silent /* flag to check tree syntax only */) + MtrNode const * root /**< root of the group tree */, + int silent /**< flag to check tree syntax only */) { MtrNode *node; @@ -619,9 +589,9 @@ Mtr_PrintGroups( } if (!silent) { #if SIZEOF_VOID_P == 8 - (void) printf("%u", root->low + root->size - 1); + (void) printf("%u", (MtrHalfWord) (root->low + root->size - 1)); #else - (void) printf("%hu", root->low + root->size - 1); + (void) printf("%hu", (MtrHalfWord) (root->low + root->size - 1)); #endif if (root->flags != MTR_DEFAULT) { (void) printf("|"); @@ -638,31 +608,30 @@ Mtr_PrintGroups( } /* end of Mtr_PrintGroups */ -/**Function******************************************************************** - - Synopsis [Prints the variable order as a parenthesized list.] +/** + @brief Prints the variable order as a parenthesized list. - Description [Prints the variable order as a parenthesized list. After each - group, the group's flag are printed, preceded by a `|'. For each - flag (except MTR_TERMINAL) a character is printed. + @details After each group, the group's flag are printed, preceded by a `|'. + For each flag (except MTR_TERMINAL) a character is printed. <ul> <li>F: MTR_FIXED <li>N: MTR_NEWNODE <li>S: MTR_SOFT </ul> The second argument, gives the map from levels to variable indices. - ] - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [Mtr_PrintGroups] + @sideeffect None -******************************************************************************/ + @see Mtr_PrintGroups + +*/ int Mtr_PrintGroupedOrder( - MtrNode * root /* root of the group tree */, - int *invperm /* map from levels to indices */, - FILE *fp /* output file */) + MtrNode const * root /**< root of the group tree */, + int const *invperm /**< map from levels to indices */, + FILE *fp /**< output file */) { MtrNode *child; MtrHalfWord level; @@ -725,15 +694,13 @@ Mtr_PrintGroupedOrder( } /* end of Mtr_PrintGroupedOrder */ -/**Function******************************************************************** +/** + @brief Reads groups from a file and creates a group tree. - Synopsis [Reads groups from a file and creates a group tree.] + @details Each group is specified by three fields: - Description [Reads groups from a file and creates a group tree. - Each group is specified by three fields: - <xmp> low size flags. - </xmp> + Low and size are (short) integers. Flags is a string composed of the following characters (with associated translation): <ul> @@ -745,17 +712,18 @@ Mtr_PrintGroupedOrder( </ul> Normally, the only flags that are needed are D and F. Groups and fields are separated by white space (spaces, tabs, and newlines). - Returns a pointer to the group tree if successful; NULL otherwise.] - SideEffects [None] + @return a pointer to the group tree if successful; NULL otherwise. - SeeAlso [Mtr_InitGroupTree Mtr_MakeGroup] + @sideeffect None -******************************************************************************/ + @see Mtr_InitGroupTree Mtr_MakeGroup + +*/ MtrNode * Mtr_ReadGroups( - FILE * fp /* file pointer */, - int nleaves /* number of leaves of the new tree */) + FILE * fp /**< file pointer */, + int nleaves /**< number of leaves of the new tree */) { int low; int size; @@ -833,24 +801,21 @@ Mtr_ReadGroups( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Adjusts the low fields of a node and its descendants.] +/** + @brief Adjusts the low fields of a node and its descendants. - Description [Adjusts the low fields of a node and its - descendants. Adds shift to low of each node. Checks that no - out-of-bounds values result. Returns 1 in case of success; 0 - otherwise.] + @details Adds shift to low of each node. Checks that no + out-of-bounds values result. - SideEffects [None] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int mtrShiftHL( - MtrNode * node /* group tree node */, - int shift /* amount by which low should be changed */) + MtrNode * node /**< group tree node */, + int shift /**< amount by which low should be changed */) { MtrNode *auxnode; int low; diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/mtrInt.h b/resources/3rdparty/cudd-3.0.0/mtr/mtrInt.h similarity index 67% rename from resources/3rdparty/cudd-2.5.0/src/mtr/mtrInt.h rename to resources/3rdparty/cudd-3.0.0/mtr/mtrInt.h index 00b2e9969..09aaac91d 100644 --- a/resources/3rdparty/cudd-2.5.0/src/mtr/mtrInt.h +++ b/resources/3rdparty/cudd-3.0.0/mtr/mtrInt.h @@ -1,18 +1,14 @@ -/**CHeaderFile***************************************************************** +/** + @file - FileName [mtrInt.h] + @ingroup mtr - PackageName [mtr] + @brief Internal data structures of the mtr package - Synopsis [Internal data structures of the mtr package] + @author Fabio Somenzi - Description [In this package all definitions are external.] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,35 +38,85 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] - - Revision [$Id: mtrInt.h,v 1.3 2012/02/05 01:06:19 fabio Exp $] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ -#ifndef _MTRINT -#define _MTRINT - -#include "mtr.h" +#ifndef MTRINT_H_ +#define MTRINT_H_ /*---------------------------------------------------------------------------*/ /* Nested includes */ /*---------------------------------------------------------------------------*/ +#include "config.h" +#include "mtr.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ /*---------------------------------------------------------------------------*/ +#ifndef SIZEOF_VOID_P +#define SIZEOF_VOID_P 4 +#endif +#ifndef SIZEOF_INT +#define SIZEOF_INT 4 +#endif + +#if defined(__GNUC__) +#define MTR_INLINE __inline__ +# if (__GNUC__ >2 || __GNUC_MINOR__ >=7) +# define MTR_UNUSED __attribute__ ((unused)) +# else +# define MTR_UNUSED +# endif +#else +#define MTR_INLINE +#define MTR_UNUSED +#endif + +/* MTR_MAXHIGH is defined in such a way that on 32-bit and 64-bit +** machines one can cast a value to (int) without generating a negative +** number. +*/ +#if SIZEOF_VOID_P == 8 +#define MTR_MAXHIGH (((MtrHalfWord) ~0) >> 1) +#else +#define MTR_MAXHIGH ((MtrHalfWord) ~0) +#endif + /*---------------------------------------------------------------------------*/ -/* Stucture declarations */ +/* Type declarations */ /*---------------------------------------------------------------------------*/ +/** + * @brief unsigned integer half the size of a pointer. + */ +#if SIZEOF_VOID_P == 8 +typedef uint32_t MtrHalfWord; +#else +typedef uint16_t MtrHalfWord; +#endif /*---------------------------------------------------------------------------*/ -/* Type declarations */ +/* Stucture declarations */ /*---------------------------------------------------------------------------*/ +/** + * @brief multi-way tree node. + */ +struct MtrNode_ { + MtrHalfWord flags; + MtrHalfWord low; + MtrHalfWord size; + MtrHalfWord index; + struct MtrNode_ *parent; + struct MtrNode_ *child; + struct MtrNode_ *elder; + struct MtrNode_ *younger; +}; + /*---------------------------------------------------------------------------*/ /* Variable declarations */ /*---------------------------------------------------------------------------*/ @@ -80,13 +126,19 @@ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/* Flag manipulation macros */ +#define MTR_SET(node, flag) (node->flags |= (flag)) +#define MTR_RESET(node, flag) (node->flags &= ~ (flag)) +#define MTR_TEST(node, flag) (node->flags & (flag)) + + +/** \cond */ /*---------------------------------------------------------------------------*/ /* Function prototypes */ /*---------------------------------------------------------------------------*/ +/** \endcond */ -/**AutomaticEnd***************************************************************/ -#endif /* _MTRINT */ +#endif /* MTRINT_H_ */ diff --git a/resources/3rdparty/cudd-2.5.0/src/mtr/test.groups b/resources/3rdparty/cudd-3.0.0/mtr/test.groups similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/mtr/test.groups rename to resources/3rdparty/cudd-3.0.0/mtr/test.groups diff --git a/resources/3rdparty/cudd-3.0.0/mtr/test_mtr.test.in b/resources/3rdparty/cudd-3.0.0/mtr/test_mtr.test.in new file mode 100644 index 000000000..04f6eb371 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/mtr/test_mtr.test.in @@ -0,0 +1,36 @@ +#! /bin/sh + +EXE=@EXEEXT@ +srcdir=@srcdir@ + +file=test +verbosity=2 + +sed_command='-r:-e:2d:-e:s/0x[0-9a-f][0-9a-f]*//g:-e:/modifiable/,$d' + +echo TAP version 13 +echo 1..1 + +mtr/testmtr$EXE -p $verbosity ${srcdir}/mtr/${file}.groups > ./mtr/${file}.tst +failed=`expr $? != 0` +if test x$failed = x0; then + echo "# comparing ./mtr/${file}.tst to ${srcdir}/mtr/${file}.out" + mkfifo ./mtr/tst_fifo ./mtr/out_fifo + OIFS=$IFS + IFS=: + `sed ${sed_command} ./mtr/${file}.tst > ./mtr/tst_fifo &\ + sed ${sed_command} ${srcdir}/mtr/${file}.out > ./mtr/out_fifo &\ + diff -b ./mtr/tst_fifo ./mtr/out_fifo > ./mtr/differences` + failed=`expr $? != 0` + rm ./mtr/tst_fifo ./mtr/out_fifo + IFS=$OIFS +fi +if test x$failed = x0; then + rm -rf ./mtr/differences + echo ok 1 +else + echo not ok 1 + echo '# Check file "./mtr/differences"' +fi + +exit 0 diff --git a/resources/3rdparty/cudd-3.0.0/mtr/testmtr.c b/resources/3rdparty/cudd-3.0.0/mtr/testmtr.c new file mode 100644 index 000000000..fb58aeeb0 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/mtr/testmtr.c @@ -0,0 +1,287 @@ +/** + @file + + @ingroup mtr + + @brief Test program for the mtr package. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" +#include "mtrInt.h" + +/*---------------------------------------------------------------------------*/ +/* Variable declarations */ +/*---------------------------------------------------------------------------*/ + +#ifndef lint +static char rcsid[] MTR_UNUSED = "$Id: testmtr.c,v 1.8 2015/07/01 20:43:45 fabio Exp $"; +#endif + +/*---------------------------------------------------------------------------*/ +/* Constant declarations */ +/*---------------------------------------------------------------------------*/ + +#define TESTMTR_VERSION\ + "TestMtr Version #0.6, Release date 2/6/12" + +/** \cond */ + + +/*---------------------------------------------------------------------------*/ +/* Static function prototypes */ +/*---------------------------------------------------------------------------*/ + +static void usage (char *prog); +static FILE * open_file (const char *filename, const char *mode); +static void printHeader(int argc, char **argv); + +/** \endcond */ + + +/*---------------------------------------------------------------------------*/ +/* Definition of exported functions */ +/*---------------------------------------------------------------------------*/ + +/** + @brief Main program for testmtr. + + @details Performs initialization. Reads command line options and + network(s). Builds some simple trees and prints them out. + + @sideeffect None + +*/ +int +main( + int argc, + char ** argv) +{ + MtrNode *root, + *node; + int i, + pr = 0; + FILE *fp; + const char *file = NULL; + + for (i = 1; i < argc; i++) { + if (strcmp("-M", argv[i]) == 0) { + continue; + } else if (strcmp("-p", argv[i]) == 0) { + pr = atoi(argv[++i]); + } else if (strcmp("-h", argv[i]) == 0) { + printHeader(argc, argv); + usage(argv[0]); + } else if (i == argc - 1) { + file = argv[i]; + } else { + printHeader(argc, argv); + usage(argv[0]); + } + } + if (file == NULL) { + file = "-"; + } + if (pr > 0) + printHeader(argc, argv); + + /* Create and print a simple tree. */ + root = Mtr_InitTree(); + root->flags = 0; + node = Mtr_CreateFirstChild(root); + node->flags = 1; + node = Mtr_CreateLastChild(root); + node->flags = 2; + node = Mtr_CreateFirstChild(root); + node->flags = 3; + node = Mtr_AllocNode(); + node->child = NULL; + node->flags = 4; + Mtr_MakeNextSibling(root->child,node); + if (pr > 0) { + Mtr_PrintTree(root); + (void) printf("#------------------------\n"); + } + Mtr_FreeTree(root); + + /* Create an initial tree in which all variables belong to one group. */ + root = Mtr_InitGroupTree(0,12); + if (pr > 0) { + Mtr_PrintTree(root); (void) printf("# "); + Mtr_PrintGroups(root,pr == 0); (void) printf("\n"); + } + (void) Mtr_MakeGroup(root,0,6,MTR_DEFAULT); + (void) Mtr_MakeGroup(root,6,6,MTR_DEFAULT); + if (pr > 0) { + Mtr_PrintTree(root); (void) printf("# "); + Mtr_PrintGroups(root,pr == 0); (void) printf("\n"); + } + for (i = 0; i < 6; i+=2) { + (void) Mtr_MakeGroup(root,(unsigned) i,(unsigned) 2,MTR_DEFAULT); + } + (void) Mtr_MakeGroup(root,0,12,MTR_FIXED); + if (pr > 0) { + Mtr_PrintTree(root); (void) printf("# "); + Mtr_PrintGroups(root,pr == 0); (void) printf("\n"); + /* Print a partial tree. */ + (void) printf("# "); + Mtr_PrintGroups(root->child,pr == 0); (void) printf("\n"); + } + node = Mtr_FindGroup(root,0,6); + (void) Mtr_DissolveGroup(node); + if (pr > 0) { + Mtr_PrintTree(root); (void) printf("# "); + Mtr_PrintGroups(root,pr == 0); (void) printf("\n"); + } + node = Mtr_FindGroup(root,4,2); + if (!Mtr_SwapGroups(node,node->younger)) { + (void) printf("error in Mtr_SwapGroups\n"); + return 3; + } + if (pr > 0) { + Mtr_PrintTree(root); (void) printf("# "); + Mtr_PrintGroups(root,pr == 0); + (void) printf("#------------------------\n"); + } + Mtr_FreeTree(root); + + /* Create a group tree with fixed subgroups. */ + root = Mtr_InitGroupTree(0,4); + if (pr > 0) { + Mtr_PrintTree(root); (void) printf("# "); + Mtr_PrintGroups(root,pr == 0); (void) printf("\n"); + } + (void) Mtr_MakeGroup(root,0,2,MTR_FIXED); + (void) Mtr_MakeGroup(root,2,2,MTR_FIXED); + if (pr > 0) { + Mtr_PrintTree(root); (void) printf("# "); + Mtr_PrintGroups(root,pr == 0); (void) printf("\n"); + } + Mtr_FreeTree(root); + if (pr > 0) { + (void) printf("#------------------------\n"); + } + + /* Open input file. */ + fp = open_file(file, "r"); + root = Mtr_ReadGroups(fp,12); + fclose(fp); + if (pr > 0) { + if (root) { + Mtr_PrintTree(root); (void) printf("# "); + Mtr_PrintGroups(root,pr == 0); (void) printf("\n"); + } else { + (void) printf("error in group file\n"); + } + } + Mtr_FreeTree(root); + + return 0; + +} /* end of main */ + + +/** + @brief Prints usage message and exits. + + @sideeffect none + +*/ +static void +usage( + char * prog) +{ + (void) fprintf(stderr, "usage: %s [options] [file]\n", prog); + (void) fprintf(stderr, " -M\t\tturns off memory allocation recording\n"); + (void) fprintf(stderr, " -h\t\tprints this message\n"); + (void) fprintf(stderr, " -p n\t\tcontrols verbosity\n"); + exit(2); + +} /* end of usage */ + + +/** + @brief Opens a file. + + @details Opens a file, or fails with an error message and exits. + Allows '-' as a synonym for standard input. + + @sideeffect None + +*/ +static FILE * +open_file( + const char * filename, + const char * mode) +{ + FILE *fp; + + if (strcmp(filename, "-") == 0) { + return mode[0] == 'r' ? stdin : stdout; + } else if ((fp = fopen(filename, mode)) == NULL) { + perror(filename); + exit(1); + } + return(fp); + +} /* end of open_file */ + + +/** + @brief Prints the header of the program output. + + @sideeffect None + +*/ +static void +printHeader( + int argc, + char **argv) +{ + int i; + + (void) printf("# %s\n", TESTMTR_VERSION); + /* Echo command line and arguments. */ + (void) printf("#"); + for(i = 0; i < argc; i++) { + (void) printf(" %s", argv[i]); + } + (void) printf("\n"); + (void) fflush(stdout); +} diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/C17.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/C17.blif similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/C17.blif rename to resources/3rdparty/cudd-3.0.0/nanotrav/C17.blif diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/C880.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/C880.blif similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/C880.blif rename to resources/3rdparty/cudd-3.0.0/nanotrav/C880.blif diff --git a/resources/3rdparty/cudd-3.0.0/nanotrav/Included.am b/resources/3rdparty/cudd-3.0.0/nanotrav/Included.am new file mode 100644 index 000000000..ca6ea5613 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/Included.am @@ -0,0 +1,37 @@ +check_PROGRAMS += nanotrav/nanotrav +nanotrav_nanotrav_SOURCES = nanotrav/bnet.h nanotrav/ntr.h \ + nanotrav/bnet.c nanotrav/chkMterm.c nanotrav/main.c nanotrav/ntrBddTest.c \ + nanotrav/ntr.c nanotrav/ntrHeap.c nanotrav/ntrMflow.c nanotrav/ntrShort.c \ + nanotrav/ntrZddTest.c +nanotrav_nanotrav_CPPFLAGS = -I$(top_srcdir)/cudd -I$(top_srcdir)/mtr \ + -I$(top_srcdir)/epd -I$(top_srcdir)/st -I$(top_srcdir)/dddmp \ + -I$(top_srcdir)/util +if DDDMP +nanotrav_nanotrav_LDADD = +else +nanotrav_nanotrav_LDADD = dddmp/libdddmp.la +endif +nanotrav_nanotrav_LDADD += cudd/libcudd.la + +check_SCRIPTS += nanotrav/test_ntrv.test +dist_check_DATA += nanotrav/adj49.blif nanotrav/adj49.out nanotrav/C17.blif \ + nanotrav/C17.out nanotrav/C880.blif nanotrav/C880.out nanotrav/closest.blif \ + nanotrav/closest.out nanotrav/ham01.blif nanotrav/ham01.out \ + nanotrav/mult32a.blif nanotrav/mult32a.out nanotrav/rcn25.blif \ + nanotrav/rcn25.out nanotrav/s27.blif nanotrav/s27.out nanotrav/s27b.blif \ + nanotrav/s27b.out nanotrav/s27c.blif nanotrav/s27c.out nanotrav/s382.blif \ + nanotrav/s382.out nanotrav/s641.blif nanotrav/s641.out \ + nanotrav/miniFirst.blif nanotrav/miniSecond.blif nanotrav/miniFirst.out +if !CROSS_COMPILING +TESTS += nanotrav/test_ntrv.test +endif !CROSS_COMPILING +EXTRA_DIST += nanotrav/README nanotrav/nanotrav.1 nanotrav/test_ntrv.test.in + +nanotrav/test_ntrv.test: nanotrav/test_ntrv.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ + +CLEANFILES += nanotrav/adj49.tst nanotrav/C17.tst nanotrav/C880.tst \ + nanotrav/closest.tst nanotrav/ham01.tst nanotrav/mult32a.tst \ + nanotrav/rcn25.tst nanotrav/s27.tst nanotrav/s27b.tst nanotrav/s27c.tst \ + nanotrav/s382.tst nanotrav/s641.tst nanotrav/miniFirst.tst diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/README b/resources/3rdparty/cudd-3.0.0/nanotrav/README similarity index 59% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/README rename to resources/3rdparty/cudd-3.0.0/nanotrav/README index cf09d9c12..bade55bd1 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/README +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/README @@ -18,7 +18,7 @@ characteristic function of the transition relation of the graph. It then builds a BDD for the initial state(s), and performs reachability analysis. Reachability analysys is performed with either the method known as "monolithic transition relation method," whose main virtue is -simplicity, or with a unsophisticated partitioned transition relation +simplicity, or with an unsophisticated partitioned transition relation method. Once it has completed reachability analysis, nanotrav prints results and @@ -30,18 +30,7 @@ the user of nanotrav to select among different reordering options. TEST CIRCUITS ============= -Five test circuits are contained in this directory: C17.blif, -C880.blif, s27.blif, mult32a.blif, and rcn25.blif. The first two are -combinational, while the last three are sequential. The results or -running - - nanotrav -p 1 -cover C17.blif > C17.out - nanotrav -p 1 -ordering dfs -autodyn -automethod sifting -reordering sifting -drop C880.blif > C880.out - nanotrav -p 1 -trav s27.blif > s27.out - nanotrav -p 1 -autodyn -reordering sifting -trav mult32a.blif > mult32a.out - nanotrav -p 1 -envelope rcn25.blif > rcn25.out - -are also included. They have been obtained on a 200 MHz P6-based -machine with 128MB of memory. These tests can be run with the shell -script tst.sh. Notice that rcn25 requires approximately 500 sec. All -other tests run in a few seconds. +Twelve test circuits are contained in this directory. The results or running +nanotrav on them with various options are also included. These tests are run +as part of "make check." Notice that rcn25 requires approximately 30 s. All +other tests take much less. diff --git a/resources/3rdparty/cudd-3.0.0/nanotrav/adj49.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/adj49.blif new file mode 100644 index 000000000..b48ed6a7e --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/adj49.blif @@ -0,0 +1,286 @@ +.model adj49 +.inputs CA +.inputs WA +.inputs OR +.inputs NV +.inputs ID +.inputs UT +.inputs AZ +.inputs MT +.inputs WY +.inputs CO +.inputs NM +.inputs ND +.inputs SD +.inputs NE +.inputs KS +.inputs OK +.inputs TX +.inputs MN +.inputs IA +.inputs MO +.inputs AR +.inputs LA +.inputs WI +.inputs IL +.inputs MS +.inputs MI +.inputs IN +.inputs KY +.inputs TN +.inputs AL +.inputs OH +.inputs WV +.inputs VA +.inputs GA +.inputs FL +.inputs PA +.inputs MD +.inputs DC +.inputs NC +.inputs SC +.inputs VT +.inputs NY +.inputs NJ +.inputs DE +.inputs NH +.inputs MA +.inputs CT +.inputs ME +.inputs RI +.outputs indep +.names CA OR caor +11 0 +.names CA NV canv +11 0 +.names CA AZ caaz +11 0 +.names WA OR waor +11 0 +.names WA ID waid +11 0 +.names OR ID orid +11 0 +.names OR NV ornv +11 0 +.names NV ID nvid +11 0 +.names NV UT nvut +11 0 +.names NV AZ nvaz +11 0 +.names ID MT idmt +11 0 +.names ID WY idwy +11 0 +.names ID UT idut +11 0 +.names UT WY utwy +11 0 +.names UT CO utco +11 0 +.names UT AZ utaz +11 0 +.names AZ NM aznm +11 0 +.names MT ND mtnd +11 0 +.names MT SD mtsd +11 0 +.names MT WY mtwy +11 0 +.names WY SD wysd +11 0 +.names WY NE wyne +11 0 +.names WY CO wyco +11 0 +.names CO NE cone +11 0 +.names CO KS coks +11 0 +.names CO OK cook +11 0 +.names CO NM conm +11 0 +.names NM OK nmok +11 0 +.names NM TX nmtx +11 0 +.names ND MN ndmn +11 0 +.names ND SD ndsd +11 0 +.names SD MN sdmn +11 0 +.names SD IA sdia +11 0 +.names SD NE sdne +11 0 +.names NE IA neia +11 0 +.names NE MO nemo +11 0 +.names NE KS neks +11 0 +.names KS MO ksmo +11 0 +.names KS OK ksok +11 0 +.names OK MO okmo +11 0 +.names OK AR okar +11 0 +.names OK TX oktx +11 0 +.names TX AR txar +11 0 +.names TX LA txla +11 0 +.names MN WI mnwi +11 0 +.names MN IA mnia +11 0 +.names IA WI iawi +11 0 +.names IA IL iail +11 0 +.names IA MO iamo +11 0 +.names MO IL moil +11 0 +.names MO KY moky +11 0 +.names MO TN motn +11 0 +.names MO AR moar +11 0 +.names AR TN artn +11 0 +.names AR MS arms +11 0 +.names AR LA arla +11 0 +.names LA MS lams +11 0 +.names WI MI wimi +11 0 +.names WI IL wiil +11 0 +.names IL IN ilin +11 0 +.names IL KY ilky +11 0 +.names MS TN mstn +11 0 +.names MS AL msal +11 0 +.names MI OH mioh +11 0 +.names MI IN miin +11 0 +.names IN OH inoh +11 0 +.names IN KY inky +11 0 +.names KY OH kyoh +11 0 +.names KY WV kywv +11 0 +.names KY VA kyva +11 0 +.names KY TN kytn +11 0 +.names TN VA tnva +11 0 +.names TN NC tnnc +11 0 +.names TN GA tnga +11 0 +.names TN AL tnal +11 0 +.names AL GA alga +11 0 +.names AL FL alfl +11 0 +.names OH PA ohpa +11 0 +.names OH WV ohwv +11 0 +.names WV PA wvpa +11 0 +.names WV MD wvmd +11 0 +.names WV VA wvva +11 0 +.names VA MD vamd +11 0 +.names VA DC vadc +11 0 +.names VA NC vanc +11 0 +.names GA NC ganc +11 0 +.names GA SC gasc +11 0 +.names GA FL gafl +11 0 +.names PA NY pany +11 0 +.names PA NJ panj +11 0 +.names PA DE pade +11 0 +.names PA MD pamd +11 0 +.names MD DE mdde +11 0 +.names MD DC mddc +11 0 +.names NC SC ncsc +11 0 +.names VT NH vtnh +11 0 +.names VT MA vtma +11 0 +.names VT NY vtny +11 0 +.names NY MA nyma +11 0 +.names NY CT nyct +11 0 +.names NY NJ nynj +11 0 +.names NJ DE njde +11 0 +.names NH ME nhme +11 0 +.names NH MA nhma +11 0 +.names MA RI mari +11 0 +.names MA CT mact +11 0 +.names CT RI ctri +11 0 +.names caor canv caaz waor waid orid ornv nvid nvut nvaz idmt idwy w0 +111111111111 1 +.names idut utwy utco utaz aznm mtnd mtsd mtwy wysd wyne wyco cone w1 +111111111111 1 +.names coks cook conm nmok nmtx ndmn ndsd sdmn sdia sdne neia nemo w2 +111111111111 1 +.names neks ksmo ksok okmo okar oktx txar txla mnwi mnia iawi iail w3 +111111111111 1 +.names iamo moil moky motn moar artn arms arla lams wimi wiil ilin ilky w4 +1111111111111 1 +.names mstn msal mioh miin inoh inky kyoh kywv kyva kytn tnva tnnc w5 +111111111111 1 +.names tnga tnal alga alfl ohpa ohwv wvpa wvmd wvva vamd vadc vanc w6 +111111111111 1 +.names ganc gasc gafl pany panj pade pamd mdde mddc ncsc vtnh vtma vtny w7 +1111111111111 1 +.names nyma nyct nynj njde nhme nhma mari mact ctri w8 +1111111111 1 +.names w0 w1 w2 w3 w4 w5 w6 w7 w8 indep +111111111 1 +.end diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/bnet.c b/resources/3rdparty/cudd-3.0.0/nanotrav/bnet.c similarity index 74% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/bnet.c rename to resources/3rdparty/cudd-3.0.0/nanotrav/bnet.c index 287b56f58..644d8bc6d 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/bnet.c +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/bnet.c @@ -1,18 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [bnet.c] + @ingroup nanotrav - PackageName [bnet] + @brief Functions to read in a boolean network. - Synopsis [Functions to read in a boolean network.] + @author Fabio Somenzi - Description [] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,12 +38,13 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ +#include "cuddInt.h" #include "bnet.h" -#include "ucbqsort.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ @@ -67,10 +64,6 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] UTIL_UNUSED = "$Id: bnet.c,v 1.26 2012/02/05 01:53:01 fabio Exp fabio $"; -#endif - static char BuffLine[MAXLENGTH]; static char *CurPos; static int newNameNumber = 0; @@ -79,7 +72,7 @@ static int newNameNumber = 0; /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -103,19 +96,18 @@ static BnetNode ** bnetOrderRoots (BnetNetwork *net, int *nroots); static int bnetLevelCompare (BnetNode **x, BnetNode **y); static int bnetDfsOrder (DdManager *dd, BnetNetwork *net, BnetNode *node); -/**AutomaticEnd***************************************************************/ +/** \endcond */ + /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Reads boolean network from blif file.] +/** + @brief Reads boolean network from blif file. - Description [Reads a boolean network from a blif file. A very restricted - subset of blif is supported. Specifically: + @details A very restricted subset of blif is supported. Specifically: <ul> <li> The only directives recognized are: <ul> @@ -135,19 +127,19 @@ static int bnetDfsOrder (DdManager *dd, BnetNetwork *net, BnetNode *node); </ul> Caveat emptor: There may be other limitations as well. One should check the syntax of the blif file with some other tool before relying - on this parser. Bnet_ReadNetwork returns a pointer to the network if - successful; NULL otherwise. - ] + on this parser. - SideEffects [None] + @return a pointer to the network if successful; NULL otherwise. + + @sideeffect None - SeeAlso [Bnet_PrintNetwork Bnet_FreeNetwork] + @see Bnet_PrintNetwork Bnet_FreeNetwork -******************************************************************************/ +*/ BnetNetwork * Bnet_ReadNetwork( - FILE * fp /* pointer to the blif file */, - int pr /* verbosity level */) + FILE * fp /**< pointer to the blif file */, + int pr /**< verbosity level */) { char *savestring; char **list; @@ -167,7 +159,7 @@ Bnet_ReadNetwork( net = ALLOC(BnetNetwork,1); if (net == NULL) goto failure; memset((char *) net, 0, sizeof(BnetNetwork)); - net->hash = st_init_table(strcmp,st_strhash); + net->hash = st_init_table((st_compare_t) strcmp, st_strhash); if (net->hash == NULL) goto failure; savestring = readString(fp); @@ -186,7 +178,13 @@ Bnet_ReadNetwork( /* Read network name. */ savestring = readString(fp); if (savestring == NULL) goto failure; - net->name = savestring; + if (savestring[0] == '.') { + net->name = ALLOC(char, 1); + if (net->name == NULL) goto failure; + net->name[0] = '\0'; + } else { + net->name = savestring; + } } else if (strcmp(savestring, ".inputs") == 0) { /* Read .inputs directive. */ FREE(savestring); @@ -441,7 +439,7 @@ Bnet_ReadNetwork( strcpy(savestring, latches[i][0]); net->outputs[net->noutputs + count] = savestring; count++; - if (st_lookup(net->hash, savestring, &node)) { + if (st_lookup(net->hash, savestring, (void **) &node)) { if (node->type == BNET_INTERNAL_NODE) { node->type = BNET_OUTPUT_NODE; } @@ -467,7 +465,7 @@ Bnet_ReadNetwork( while (newnode != NULL) { BnetNode *auxnd; for (i = 0; i < newnode->ninp; i++) { - if (!st_lookup(net->hash,newnode->inputs[i],&auxnd)) { + if (!st_lookup(net->hash,newnode->inputs[i],(void **)&auxnd)) { (void) fprintf(stdout,"%s not driven\n", newnode->inputs[i]); goto failure; } @@ -488,22 +486,20 @@ failure: } /* end of Bnet_ReadNetwork */ -/**Function******************************************************************** - - Synopsis [Prints a boolean network created by readNetwork.] +/** + @brief Prints to stdout a boolean network created by Bnet_ReadNetwork. - Description [Prints to the standard output a boolean network created - by Bnet_ReadNetwork. Uses the blif format; this way, one can verify the - equivalence of the input and the output with, say, sis.] + @details Uses the blif format; this way, one can verify the + equivalence of the input and the output with, say, sis. - SideEffects [None] + @sideeffect None - SeeAlso [Bnet_ReadNetwork] + @see Bnet_ReadNetwork -******************************************************************************/ +*/ void Bnet_PrintNetwork( - BnetNetwork * net /* boolean network */) + BnetNetwork * net /**< boolean network */) { BnetNode *nd; BnetTabline *tl; @@ -546,17 +542,14 @@ Bnet_PrintNetwork( } /* end of Bnet_PrintNetwork */ -/**Function******************************************************************** +/** + @brief Frees a boolean network created by Bnet_ReadNetwork. - Synopsis [Frees a boolean network created by Bnet_ReadNetwork.] + @sideeffect None - Description [] + @see Bnet_ReadNetwork - SideEffects [None] - - SeeAlso [Bnet_ReadNetwork] - -******************************************************************************/ +*/ void Bnet_FreeNetwork( BnetNetwork * net) @@ -616,34 +609,32 @@ Bnet_FreeNetwork( } /* end of Bnet_FreeNetwork */ -/**Function******************************************************************** - - Synopsis [Builds the BDD for the function of a node.] +/** + @brief Builds the %BDD for the function of a node. - Description [Builds the BDD for the function of a node and stores a + @details Builds the %BDD for the function of a node and stores a pointer to it in the dd field of the node itself. The reference count - of the BDD is incremented. If params is BNET_LOCAL_DD, then the BDD is + of the %BDD is incremented. If params is BNET_LOCAL_DD, then the %BDD is built in terms of the local inputs to the node; otherwise, if params - is BNET_GLOBAL_DD, the BDD is built in terms of the network primary - inputs. To build the global BDD of a node, the BDDs for its local + is BNET_GLOBAL_DD, the %BDD is built in terms of the network primary + inputs. To build the global %BDD of a node, the BDDs for its local inputs must exist. If that is not the case, Bnet_BuildNodeBDD - recursively builds them. Likewise, to create the local BDD for a node, + recursively builds them. Likewise, to create the local %BDD for a node, the local inputs must have variables assigned to them. If that is not the case, Bnet_BuildNodeBDD recursively assigns variables to nodes. - Bnet_BuildNodeBDD returns 1 in case of success; 0 otherwise.] - SideEffects [Sets the dd field of the node.] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect Sets the dd field of the node. -******************************************************************************/ +*/ int Bnet_BuildNodeBDD( - DdManager * dd /* DD manager */, - BnetNode * nd /* node of the boolean network */, - st_table * hash /* symbol table of the boolean network */, - int params /* type of DD to be built */, - int nodrop /* retain the intermediate node DDs until the end */) + DdManager * dd /**< %DD manager */, + BnetNode * nd /**< node of the boolean network */, + st_table * hash /**< symbol table of the boolean network */, + int params /**< type of %DD to be built */, + int nodrop /**< retain the intermediate node DDs until the end */) { DdNode *func; BnetNode *auxnd; @@ -696,7 +687,7 @@ Bnet_BuildNodeBDD( /* Scan the table line. */ for (i = 0; i < nd->ninp; i++) { if (line->values[i] == '-') continue; - if (!st_lookup(hash,nd->inputs[i],&auxnd)) { + if (!st_lookup(hash,nd->inputs[i],(void **)&auxnd)) { goto failure; } if (params == BNET_LOCAL_DD) { @@ -764,7 +755,7 @@ Bnet_BuildNodeBDD( ** When count reaches 0, the DD is freed. */ for (i = 0; i < nd->ninp; i++) { - if (!st_lookup(hash,nd->inputs[i],&auxnd)) { + if (!st_lookup(hash,nd->inputs[i],(void **)&auxnd)) { goto failure; } auxnd->count--; @@ -784,18 +775,14 @@ failure: } /* end of Bnet_BuildNodeBDD */ -/**Function******************************************************************** - - Synopsis [Orders the BDD variables by DFS.] - - Description [Orders the BDD variables by DFS. Returns 1 in case of - success; 0 otherwise.] +/** + @brief Orders the %BDD variables by DFS. - SideEffects [Uses the visited flags of the nodes.] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect Uses the visited flags of the nodes. -******************************************************************************/ +*/ int Bnet_DfsVariableOrder( DdManager * dd, @@ -826,27 +813,25 @@ Bnet_DfsVariableOrder( } /* end of Bnet_DfsVariableOrder */ -/**Function******************************************************************** +/** + @brief Writes the network BDDs to a file in dot, blif, or daVinci + format. - Synopsis [Writes the network BDDs to a file in dot, blif, or daVinci - format.] + @details If "-" is passed as file name, the BDDs are dumped to the + standard output. - Description [Writes the network BDDs to a file in dot, blif, or daVinci - format. If "-" is passed as file name, the BDDs are dumped to the - standard output. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int Bnet_bddDump( - DdManager * dd /* DD manager */, - BnetNetwork * network /* network whose BDDs should be dumped */, - char * dfile /* file name */, - int dumpFmt /* 0 -> dot */, - int reencoded /* whether variables have been reencoded */) + DdManager * dd /**< %DD manager */, + BnetNetwork * network /**< network whose BDDs should be dumped */, + char * dfile /**< file name */, + int dumpFmt /**< 0 -> dot */, + int reencoded /**< whether variables have been reencoded */) { int noutputs; FILE *dfp = NULL; @@ -878,14 +863,14 @@ Bnet_bddDump( /* Find outputs and their names. */ for (i = 0; i < network->nlatches; i++) { onames[i] = network->latches[i][0]; - if (!st_lookup(network->hash,network->latches[i][0],&node)) { + if (!st_lookup(network->hash,network->latches[i][0],(void **)&node)) { goto endgame; } outputs[i] = node->dd; } for (i = 0; i < network->npos; i++) { onames[i + network->nlatches] = network->outputs[i]; - if (!st_lookup(network->hash,network->outputs[i],&node)) { + if (!st_lookup(network->hash,network->outputs[i],(void **)&node)) { goto endgame; } outputs[i + network->nlatches] = node->dd; @@ -893,13 +878,13 @@ Bnet_bddDump( /* Find the input names. */ for (i = 0; i < network->ninputs; i++) { - if (!st_lookup(network->hash,network->inputs[i],&node)) { + if (!st_lookup(network->hash,network->inputs[i],(void **)&node)) { goto endgame; } inames[node->var] = network->inputs[i]; } for (i = 0; i < network->nlatches; i++) { - if (!st_lookup(network->hash,network->latches[i][1],&node)) { + if (!st_lookup(network->hash,network->latches[i][1],(void **)&node)) { goto endgame; } inames[node->var] = network->latches[i][1]; @@ -922,19 +907,31 @@ Bnet_bddDump( /* Dump the BDDs. */ if (dumpFmt == 1) { - retval = Cudd_DumpBlif(dd,noutputs,outputs,inames,onames, - network->name,dfp,0); + retval = Cudd_DumpBlif(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames, + network->name,dfp,0); } else if (dumpFmt == 2) { - retval = Cudd_DumpDaVinci(dd,noutputs,outputs,inames,onames,dfp); + retval = Cudd_DumpDaVinci(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames,dfp); } else if (dumpFmt == 3) { - retval = Cudd_DumpDDcal(dd,noutputs,outputs,inames,onames,dfp); + retval = Cudd_DumpDDcal(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames,dfp); } else if (dumpFmt == 4) { - retval = Cudd_DumpFactoredForm(dd,noutputs,outputs,inames,onames,dfp); + retval = Cudd_DumpFactoredForm(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames,dfp); } else if (dumpFmt == 5) { - retval = Cudd_DumpBlif(dd,noutputs,outputs,inames,onames, - network->name,dfp,1); + retval = Cudd_DumpBlif(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames, + network->name,dfp,1); } else { - retval = Cudd_DumpDot(dd,noutputs,outputs,inames,onames,dfp); + retval = Cudd_DumpDot(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames,dfp); } endgame: @@ -950,31 +947,37 @@ endgame: } /* end of Bnet_bddDump */ -/**Function******************************************************************** - - Synopsis [Writes an array of BDDs to a file in dot, blif, DDcal, - factored-form, daVinci, or blif-MV format.] +/** + @brief Writes an array of BDDs to a file in dot, blif, DDcal, + factored-form, daVinci, or blif-MV format. - Description [Writes an array of BDDs to a file in dot, blif, DDcal, - factored-form, daVinci, or blif-MV format. The BDDs and their names - are passed as arguments. The inputs and their names are taken from - the network. If "-" is passed as file name, the BDDs are dumped to - the standard output. Returns 1 in case of success; 0 otherwise.] + @details The BDDs and their names are passed as arguments. The + inputs and their names are taken from the network. If "-" is passed + as file name, the BDDs are dumped to the standard output. The encoding + of the format is: + <ul> + <li>0: dot + <li>1: blif + <li>2: da Vinci + <li>3: ddcal + <li>4: factored form + <li>5: blif-MV + </ul> - SideEffects [None] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Bnet_bddArrayDump( - DdManager * dd /* DD manager */, - BnetNetwork * network /* network whose BDDs should be dumped */, - char * dfile /* file name */, - DdNode ** outputs /* BDDs to be dumped */, - char ** onames /* names of the BDDs to be dumped */, - int noutputs /* number of BDDs to be dumped */, - int dumpFmt /* 0 -> dot */) + DdManager * dd /**< %DD manager */, + BnetNetwork * network /**< network whose BDDs should be dumped */, + char * dfile /**< file name */, + DdNode ** outputs /**< BDDs to be dumped */, + char ** onames /**< names of the BDDs to be dumped */, + int noutputs /**< number of BDDs to be dumped */, + int dumpFmt /**< 0 -> dot */) { FILE *dfp = NULL; char **inames = NULL; @@ -999,13 +1002,13 @@ Bnet_bddArrayDump( /* Find the input names. */ for (i = 0; i < network->ninputs; i++) { - if (!st_lookup(network->hash,network->inputs[i],&node)) { + if (!st_lookup(network->hash,network->inputs[i],(void **)&node)) { goto endgame; } inames[node->var] = network->inputs[i]; } for (i = 0; i < network->nlatches; i++) { - if (!st_lookup(network->hash,network->latches[i][1],&node)) { + if (!st_lookup(network->hash,network->latches[i][1],(void **)&node)) { goto endgame; } inames[node->var] = network->latches[i][1]; @@ -1013,19 +1016,31 @@ Bnet_bddArrayDump( /* Dump the BDDs. */ if (dumpFmt == 1) { - retval = Cudd_DumpBlif(dd,noutputs,outputs,inames,onames, - network->name,dfp,0); + retval = Cudd_DumpBlif(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames, + network->name,dfp,0); } else if (dumpFmt == 2) { - retval = Cudd_DumpDaVinci(dd,noutputs,outputs,inames,onames,dfp); + retval = Cudd_DumpDaVinci(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames,dfp); } else if (dumpFmt == 3) { - retval = Cudd_DumpDDcal(dd,noutputs,outputs,inames,onames,dfp); + retval = Cudd_DumpDDcal(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames,dfp); } else if (dumpFmt == 4) { - retval = Cudd_DumpFactoredForm(dd,noutputs,outputs,inames,onames,dfp); + retval = Cudd_DumpFactoredForm(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames,dfp); } else if (dumpFmt == 5) { - retval = Cudd_DumpBlif(dd,noutputs,outputs,inames,onames, - network->name,dfp,1); + retval = Cudd_DumpBlif(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames, + network->name,dfp,1); } else { - retval = Cudd_DumpDot(dd,noutputs,outputs,inames,onames,dfp); + retval = Cudd_DumpDot(dd,noutputs,outputs, + (char const * const *) inames, + (char const * const *) onames,dfp); } endgame: @@ -1039,19 +1054,15 @@ endgame: } /* end of Bnet_bddArrayDump */ -/**Function******************************************************************** - - Synopsis [Reads the variable order from a file.] +/** + @brief Reads the variable order from a file. - Description [Reads the variable order from a file. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [The BDDs for the primary inputs and present state variables - are built.] + @sideeffect The BDDs for the primary inputs and present state variables + are built. - SeeAlso [] - -*****************************************************************************/ +*/ int Bnet_ReadOrder( DdManager * dd, @@ -1070,7 +1081,7 @@ Bnet_ReadOrder( return(0); } - dict = st_init_table(strcmp,st_strhash); + dict = st_init_table((st_compare_t) strcmp,st_strhash); if (dict == NULL) { return(0); } @@ -1093,7 +1104,7 @@ Bnet_ReadOrder( return(0); } /* There should be a node named "name" in the network. */ - if (!st_lookup(net->hash,name,&node)) { + if (!st_lookup(net->hash,name,(void **)&node)) { (void) fprintf(stderr,"Unknown name in order file (%s)\n", name); st_free_table(dict); return(0); @@ -1150,19 +1161,16 @@ Bnet_ReadOrder( } /* end of Bnet_ReadOrder */ -/**Function******************************************************************** - - Synopsis [Prints the order of the DD variables of a network.] +/** + @brief Prints the order of the %DD variables of a network. - Description [Prints the order of the DD variables of a network. - Only primary inputs and present states are printed. - Returns 1 if successful; 0 otherwise.] + @details Only primary inputs and present states are printed. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -*****************************************************************************/ +*/ int Bnet_PrintOrder( BnetNetwork * net, @@ -1182,7 +1190,7 @@ Bnet_PrintOrder( names[i] = NULL; } for (i = 0; i < net->npis; i++) { - if (!st_lookup(net->hash,net->inputs[i],&node)) { + if (!st_lookup(net->hash,net->inputs[i],(void **)&node)) { FREE(names); return(0); } @@ -1194,7 +1202,7 @@ Bnet_PrintOrder( names[level] = node->name; } for (i = 0; i < net->nlatches; i++) { - if (!st_lookup(net->hash,net->latches[i][1],&node)) { + if (!st_lookup(net->hash,net->latches[i][1],(void **)&node)) { FREE(names); return(0); } @@ -1240,26 +1248,26 @@ Bnet_PrintOrder( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Reads a string from a file. - Synopsis [Reads a string from a file.] + @details The string can be MAXLENGTH-1 characters at + most. readString allocates memory to hold the string. - Description [Reads a string from a file. The string can be MAXLENGTH-1 - characters at most. readString allocates memory to hold the string and - returns a pointer to the result if successful. It returns NULL - otherwise.] + @return a pointer to the result string if successful. It returns + NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [readList] + @see readList -******************************************************************************/ +*/ static char * readString( - FILE * fp /* pointer to the file from which the string is read */) + FILE * fp /**< pointer to the file from which the string is read */) { char *savestring; - size_t length; + int length; while (!CurPos) { if (!fgets(BuffLine, MAXLENGTH, fp)) @@ -1279,34 +1287,34 @@ readString( } /* end of readString */ -/**Function******************************************************************** +/** + @brief Reads a list of strings from a line of a file. - Synopsis [Reads a list of strings from a file.] + @details The strings are sequences of characters separated by spaces + or tabs. The total length of the list, white space included, must + not exceed MAXLENGTH-1 characters. readList allocates memory for + the strings and creates an array of pointers to the individual + lists. Only two pieces of memory are allocated by readList: One to + hold all the strings, and one to hold the pointers to + them. Therefore, when freeing the memory allocated by readList, only + the pointer to the list of pointers, and the pointer to the + beginning of the first string should be freed. - Description [Reads a list of strings from a line of a file. - The strings are sequences of characters separated by spaces or tabs. - The total length of the list, white space included, must not exceed - MAXLENGTH-1 characters. readList allocates memory for the strings and - creates an array of pointers to the individual lists. Only two pieces - of memory are allocated by readList: One to hold all the strings, - and one to hold the pointers to them. Therefore, when freeing the - memory allocated by readList, only the pointer to the list of - pointers, and the pointer to the beginning of the first string should - be freed. readList returns the pointer to the list of pointers if - successful; NULL otherwise.] + @return the pointer to the list of pointers if successful; NULL + otherwise. - SideEffects [n is set to the number of strings in the list.] + @sideeffect n is set to the number of strings in the list. - SeeAlso [readString printList] + @see readString printList -******************************************************************************/ +*/ static char ** readList( - FILE * fp /* pointer to the file from which the list is read */, - int * n /* on return, number of strings in the list */) + FILE * fp /**< pointer to the file from which the list is read */, + int * n /**< on return, number of strings in the list */) { char *savestring; - size_t length; + int length; char *stack[8192]; char **list; int i, count = 0; @@ -1337,22 +1345,20 @@ readList( } /* end of readList */ -/**Function******************************************************************** - - Synopsis [Prints a list of strings to the standard output.] +/** + @brief Prints a list of strings to the standard output. - Description [Prints a list of strings to the standard output. The list - is in the format created by readList.] + @details The list is in the format created by readList. - SideEffects [None] + @sideeffect None - SeeAlso [readList Bnet_PrintNetwork] + @see readList Bnet_PrintNetwork -******************************************************************************/ +*/ static void printList( - char ** list /* list of pointers to strings */, - int n /* length of the list */) + char ** list /**< list of pointers to strings */, + int n /**< length of the list */) { int i; @@ -1364,22 +1370,21 @@ printList( } /* end of printList */ -/**Function******************************************************************** +/** + @brief Generates n names not currently in a symbol table. - Synopsis [Generates names not currently in a symbol table.] + @details The pointer to the symbol table may be NULL, in which case + no test is made. The names generated by the procedure are + unique. So, if there is no possibility of conflict with pre-existing + names, NULL can be passed for the hash table. - Description [Generates n names not currently in the symbol table hash. - The pointer to the symbol table may be NULL, in which case no test is - made. The names generated by the procedure are unique. So, if there is - no possibility of conflict with pre-existing names, NULL can be passed - for the hash table. Returns an array of names if succesful; NULL - otherwise.] + @return an array of names if succesful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] + @see -******************************************************************************/ +*/ static char ** bnetGenerateNewNames( st_table * hash /* table of existing names (or NULL) */, @@ -1406,27 +1411,22 @@ bnetGenerateNewNames( } /* bnetGenerateNewNames */ -/**Function******************************************************************** - - Synopsis [Writes blif for the reencoding logic.] - - Description [] +/** + @brief Writes blif for the reencoding logic. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int bnetDumpReencodingLogic( - DdManager * dd /* DD manager */, - char * mname /* model name */, - int noutputs /* number of outputs */, - DdNode ** outputs /* array of network outputs */, - char ** inames /* array of network input names */, - char ** altnames /* array of names of reencoded inputs */, - char ** onames /* array of network output names */, - FILE * fp /* file pointer */) + DdManager * dd /**< %DD manager */, + char * mname /**< model name */, + int noutputs /**< number of outputs */, + DdNode ** outputs /**< array of network outputs */, + char ** inames /**< array of network input names */, + char ** altnames /**< array of names of reencoded inputs */, + char ** onames /**< array of network output names */, + FILE * fp /**< file pointer */) { int i; int retval; @@ -1531,23 +1531,19 @@ failure: } /* end of bnetDumpReencodingLogic */ -/**Function******************************************************************** - - Synopsis [Writes blif for the truth table of an n-input xnor.] - - Description [Writes blif for the truth table of an n-input - xnor. Returns 1 if successful; 0 otherwise.] +/** + @brief Writes blif for the truth table of an n-input xnor. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ #if 0 static int bnetBlifXnorTable( - FILE * fp /* file pointer */, - int n /* number of inputs */) + FILE * fp /**< file pointer */, + int n /**< number of inputs */) { int power; /* 2 to the power n */ int i,j,k; @@ -1586,19 +1582,17 @@ bnetBlifXnorTable( #endif -/**Function******************************************************************** +/** + @brief Writes blif for the reencoding logic. - Synopsis [Writes blif for the reencoding logic.] + @details Exclusive NORs with more than two inputs are decomposed + into cascaded two-input gates. - Description [Writes blif for the reencoding logic. Exclusive NORs - with more than two inputs are decomposed into cascaded two-input - gates. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int bnetBlifWriteReencode( DdManager * dd, @@ -1701,17 +1695,12 @@ failure: } /* end of bnetBlifWriteReencode */ -/**Function******************************************************************** - - Synopsis [Finds the support of a list of DDs.] +/** + @brief Finds the support of a list of DDs. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static int * bnetFindVectorSupport( DdManager * dd, @@ -1752,18 +1741,17 @@ bnetFindVectorSupport( } /* end of bnetFindVectorSupport */ -/**Function******************************************************************** - - Synopsis [Builds BDD for a XOR function.] +/** + @brief Builds %BDD for a XOR function. - Description [Checks whether a function is a XOR with 2 or 3 inputs. If so, - it builds the BDD. Returns 1 if the BDD has been built; 0 otherwise.] + @details Checks whether a function is a XOR with 2 or 3 inputs. If so, + it builds the %BDD. - SideEffects [None] + @return 1 if the %BDD has been built; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static int buildExorBDD( DdManager * dd, @@ -1809,7 +1797,7 @@ buildExorBDD( /* Scan the inputs. */ for (i = 0; i < nd->ninp; i++) { - if (!st_lookup(hash, nd->inputs[i], &auxnd)) { + if (!st_lookup(hash, nd->inputs[i], (void **) &auxnd)) { goto failure; } if (params == BNET_LOCAL_DD) { @@ -1860,18 +1848,17 @@ failure: } /* end of buildExorBDD */ -/**Function******************************************************************** +/** + @brief Builds %BDD for a multiplexer. - Synopsis [Builds BDD for a multiplexer.] + @details Checks whether a function is a 2-to-1 multiplexer. If so, + it builds the %BDD. - Description [Checks whether a function is a 2-to-1 multiplexer. If so, - it builds the BDD. Returns 1 if the BDD has been built; 0 otherwise.] + @return 1 if the %BDD has been built; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int buildMuxBDD( DdManager * dd, @@ -1882,8 +1869,8 @@ buildMuxBDD( { BnetTabline *line; char *values[2]; - int mux[2]; - int phase[2]; + int mux[2] = {0, 0}; + int phase[2] = {0, 0}; int j; int nlines = 0; int controlC = -1; @@ -1891,7 +1878,7 @@ buildMuxBDD( DdNode *func, *f, *g, *h; BnetNode *auxnd; - if (nd->ninp != 3) return(0); + if (nd->ninp != 3 || nd->f == NULL) return(0); for (line = nd->f; line != NULL; line = line->next) { int dc = 0; @@ -1906,6 +1893,7 @@ buildMuxBDD( if (!dc) return(0); nlines++; } + if (nlines != 2) return(0); /* At this point we know we have: ** 3 inputs ** 2 lines @@ -1943,7 +1931,7 @@ buildMuxBDD( } /* Get the inputs. */ - if (!st_lookup(hash, nd->inputs[controlC], &auxnd)) { + if (!st_lookup(hash, nd->inputs[controlC], (void **) &auxnd)) { goto failure; } if (params == BNET_LOCAL_DD) { @@ -1963,7 +1951,7 @@ buildMuxBDD( } f = auxnd->dd; } - if (!st_lookup(hash, nd->inputs[mux[0]], &auxnd)) { + if (!st_lookup(hash, nd->inputs[mux[0]], (void **) &auxnd)) { goto failure; } if (params == BNET_LOCAL_DD) { @@ -1984,7 +1972,7 @@ buildMuxBDD( g = auxnd->dd; } g = Cudd_NotCond(g,phase[0]); - if (!st_lookup(hash, nd->inputs[mux[1]], &auxnd)) { + if (!st_lookup(hash, nd->inputs[mux[1]], (void **) &auxnd)) { goto failure; } if (params == BNET_LOCAL_DD) { @@ -2035,19 +2023,17 @@ failure: } /* end of buildExorBDD */ -/**Function******************************************************************** - - Synopsis [Sets the level of each node.] +/** + @brief Sets the level of each node. - Description [Sets the level of each node. Returns 1 if successful; 0 - otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [Changes the level and visited fields of the nodes it - visits.] + @sideeffect Changes the level and visited fields of the nodes it + visits. - SeeAlso [bnetLevelDFS] + @see bnetLevelDFS -******************************************************************************/ +*/ static int bnetSetLevel( BnetNetwork * net) @@ -2075,19 +2061,17 @@ bnetSetLevel( } /* end of bnetSetLevel */ -/**Function******************************************************************** +/** + @brief Does a DFS from a node setting the level field. - Synopsis [Does a DFS from a node setting the level field.] + @return 1 if successful; 0 otherwise. - Description [Does a DFS from a node setting the level field. Returns - 1 if successful; 0 otherwise.] + @sideeffect Changes the level and visited fields of the nodes it + visits. - SideEffects [Changes the level and visited fields of the nodes it - visits.] + @see bnetSetLevel - SeeAlso [bnetSetLevel] - -******************************************************************************/ +*/ static int bnetLevelDFS( BnetNetwork * net, @@ -2107,7 +2091,7 @@ bnetLevelDFS( ** increase the level. */ node->level = 0; for (i = 0; i < node->ninp; i++) { - if (!st_lookup(net->hash, node->inputs[i], &auxnd)) { + if (!st_lookup(net->hash, node->inputs[i], (void **) &auxnd)) { return(0); } if (!bnetLevelDFS(net,auxnd)) { @@ -2120,19 +2104,15 @@ bnetLevelDFS( } /* end of bnetLevelDFS */ -/**Function******************************************************************** - - Synopsis [Orders network roots for variable ordering.] +/** + @brief Orders network roots for variable ordering. - Description [Orders network roots for variable ordering. Returns - an array with the ordered outputs and next state variables if - successful; NULL otherwise.] + @return an array with the ordered outputs and next state variables + if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static BnetNode ** bnetOrderRoots( BnetNetwork * net, @@ -2149,14 +2129,14 @@ bnetOrderRoots( /* Find output names and levels. */ for (i = 0; i < net->noutputs; i++) { - if (!st_lookup(net->hash,net->outputs[i],&node)) { + if (!st_lookup(net->hash,net->outputs[i],(void **)&node)) { goto endgame; } nodes[i] = node; } - cudd__qsort((void *)nodes, noutputs, sizeof(BnetNode *), - (DD_QSFP)bnetLevelCompare); + util_qsort(nodes, noutputs, sizeof(BnetNode *), + (DD_QSFP)bnetLevelCompare); *nroots = noutputs; return(nodes); @@ -2167,18 +2147,18 @@ endgame: } /* end of bnetOrderRoots */ -/**Function******************************************************************** +/** + @brief Comparison function used by qsort. - Synopsis [Comparison function used by qsort.] + @details Used to order the variables according to the number of keys + in the subtables. - Description [Comparison function used by qsort to order the - variables according to the number of keys in the subtables. - Returns the difference in number of keys between the two - variables being compared.] + @return the difference in number of keys between the two variables + being compared. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int bnetLevelCompare( BnetNode ** x, @@ -2189,18 +2169,16 @@ bnetLevelCompare( } /* end of bnetLevelCompare */ -/**Function******************************************************************** - - Synopsis [Does a DFS from a node ordering the inputs.] +/** + @brief Does a DFS from a node ordering the inputs. - Description [Does a DFS from a node ordering the inputs. Returns - 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [Changes visited fields of the nodes it visits.] + @sideeffect Changes visited fields of the nodes it visits. - SeeAlso [Bnet_DfsVariableOrder] + @see Bnet_DfsVariableOrder -******************************************************************************/ +*/ static int bnetDfsOrder( DdManager * dd, @@ -2230,15 +2208,15 @@ bnetDfsOrder( if (fanins == NULL) return(0); for (i = 0; i < node->ninp; i++) { - if (!st_lookup(net->hash, node->inputs[i], &auxnd)) { + if (!st_lookup(net->hash, node->inputs[i], (void **) &auxnd)) { FREE(fanins); return(0); } fanins[i] = auxnd; } - cudd__qsort((void *)fanins, node->ninp, sizeof(BnetNode *), - (DD_QSFP)bnetLevelCompare); + util_qsort(fanins, node->ninp, sizeof(BnetNode *), + (DD_QSFP)bnetLevelCompare); for (i = 0; i < node->ninp; i++) { /* for (i = node->ninp - 1; i >= 0; i--) { */ int res = bnetDfsOrder(dd,net,fanins[i]); diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/bnet.h b/resources/3rdparty/cudd-3.0.0/nanotrav/bnet.h similarity index 60% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/bnet.h rename to resources/3rdparty/cudd-3.0.0/nanotrav/bnet.h index ec468abce..26b731bfc 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/bnet.h +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/bnet.h @@ -1,18 +1,14 @@ -/**CHeaderFile***************************************************************** +/** + @file - FileName [bnet.h] + @ingroup nanotrav - PackageName [bnet] + @brief Simple-minded package to read a blif file. - Synopsis [Simple-minded package to read a blif file.] + @author Fabio Somenzi - Description [] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,11 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] - - Revision [$Id: bnet.h,v 1.13 2012/02/05 01:53:01 fabio Exp fabio $] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #ifndef _BNET #define _BNET @@ -94,57 +89,65 @@ extern "C" { ** circuit. */ -/* Type to store a line of the truth table of a node. The entire truth table -** implemented as a linked list of objects of this type. -*/ +/** + ** @brief Type to store a line of the truth table of a node. + ** + ** @details The entire truth table implemented as a linked list of + ** objects of this type. + */ typedef struct BnetTabline { - char *values; /* string of 1, 0, and - */ - struct BnetTabline *next; /* pointer to next table line */ + char *values; /**< string of 1, 0, and - */ + struct BnetTabline *next; /**< pointer to next table line */ } BnetTabline; -/* Node of the boolean network. There is one node in the network for each -** primary input and for each .names directive. This structure -** has a field to point to the DD of the node function. The function may -** be either in terms of primary inputs, or it may be in terms of the local -** inputs. The latter implies that each node has a variable index -** associated to it at some point in time. The field "var" stores that -** variable index, and "active" says if the association is currently valid. -** (It is indeed possible for an index to be associated to different nodes -** at different times.) -*/ +/** + ** @brief Node of the boolean network. + ** + ** @details There is one node in the network for each primary input + ** and for each .names directive. This structure has a field to point + ** to the DD of the node function. The function may be either in + ** terms of primary inputs, or it may be in terms of the local + ** inputs. The latter implies that each node has a variable index + ** associated to it at some point in time. The field "var" stores + ** that variable index, and "active" says if the association is + ** currently valid. (It is indeed possible for an index to be + ** associated to different nodes at different times.) + */ typedef struct BnetNode { - char *name; /* name of the output signal */ - int type; /* input, internal, constant, ... */ - int ninp; /* number of inputs to the node */ - int nfo; /* number of fanout nodes for this node */ - char **inputs; /* input names */ - BnetTabline *f; /* truth table for this node */ - int polarity; /* f is the onset (0) or the offset (1) */ - int active; /* node has variable associated to it (1) or not (0) */ - int var; /* DD variable index associated to this node */ - DdNode *dd; /* decision diagram for the function of this node */ - int exdc_flag; /* whether an exdc node or not */ - struct BnetNode *exdc; /* pointer to exdc of dd node */ - int count; /* auxiliary field for DD dropping */ - int level; /* maximum distance from the inputs */ - int visited; /* flag for search */ - struct BnetNode *next; /* pointer to implement the linked list of nodes */ + char *name; /**< name of the output signal */ + int type; /**< input, internal, constant, ... */ + int ninp; /**< number of inputs to the node */ + int nfo; /**< number of fanout nodes for this node */ + char **inputs; /**< input names */ + BnetTabline *f; /**< truth table for this node */ + int polarity; /**< f is the onset (0) or the offset (1) */ + int active; /**< node has variable associated to it (1) or not (0) */ + int var; /**< %DD variable index associated to this node */ + DdNode *dd; /**< decision diagram for the function of this node */ + int exdc_flag; /**< whether an exdc node or not */ + struct BnetNode *exdc; /**< pointer to exdc of dd node */ + int count; /**< auxiliary field for %DD dropping */ + int level; /**< maximum distance from the inputs */ + int visited; /**< flag for search */ + struct BnetNode *next; /**< pointer to implement the linked list of nodes */ } BnetNode; -/* Very simple boolean network data structure. */ +/** + ** @brief Very simple boolean network data structure. + */ typedef struct BnetNetwork { - char *name; /* network name: from the .model directive */ - int npis; /* number of primary inputs */ - int ninputs; /* number of inputs */ - char **inputs; /* primary input names: from the .inputs directive */ - int npos; /* number of primary outputs */ - int noutputs; /* number of outputs */ - char **outputs; /* primary output names: from the .outputs directive */ - int nlatches; /* number of latches */ - char ***latches; /* next state names: from the .latch directives */ - BnetNode *nodes; /* linked list of the nodes */ - st_table *hash; /* symbol table to access nodes by name */ - char *slope; /* wire_load_slope */ + char *name; /**< network name: from the .model directive */ + int npis; /**< number of primary inputs */ + int ninputs; /**< number of inputs */ + char **inputs; /**< primary input names: from the .inputs directive */ + int npos; /**< number of primary outputs */ + int noutputs; /**< number of outputs */ + char **outputs; /**< primary output names: from the .outputs directive */ + int nlatches; /**< number of latches */ + char ***latches; /**< next state names: from the .latch directives */ + BnetNode *nodes; /**< linked list of the nodes */ + st_table *hash; /**< symbol table to access nodes by name */ + char *slope; /**< wire_load_slope */ } BnetNetwork; /*---------------------------------------------------------------------------*/ @@ -162,7 +165,7 @@ typedef struct BnetNetwork { # define FALSE 0 #endif -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Function prototypes */ @@ -178,7 +181,8 @@ extern int Bnet_bddArrayDump (DdManager *dd, BnetNetwork *network, char *dfile, extern int Bnet_ReadOrder (DdManager *dd, char *ordFile, BnetNetwork *net, int locGlob, int nodrop); extern int Bnet_PrintOrder (BnetNetwork * net, DdManager *dd); -/**AutomaticEnd***************************************************************/ +/** \endcond */ + #ifdef __cplusplus } /* end of extern "C" */ diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/chkMterm.c b/resources/3rdparty/cudd-3.0.0/nanotrav/chkMterm.c similarity index 73% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/chkMterm.c rename to resources/3rdparty/cudd-3.0.0/nanotrav/chkMterm.c index a5ef2f36e..e7bc74eaa 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/chkMterm.c +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/chkMterm.c @@ -1,28 +1,15 @@ -/**CFile*********************************************************************** +/** + @file - FileName [chkMterm.c] + @ingroup nanotrav - PackageName [ntr] + @brief Functions to check that the minterm counts have not changed + during reordering. - Synopsis [Functions to check that the minterm counts have not - changed.] + @author Fabio Somenzi - Description [Functions to check that the minterm counts have not - changed during reordering.<p> - Internal procedures included in this module: - <ul> - <li> check_minterms() - </ul> - Static procedures included in this module: - <ul> - <li> stFree() - </ul>] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -52,9 +39,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "ntr.h" @@ -74,23 +62,21 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] UTIL_UNUSED = "$Id: chkMterm.c,v 1.9 2012/02/05 01:53:01 fabio Exp fabio $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ /*---------------------------------------------------------------------------*/ -static enum st_retval stFree (char *key, char *value, char *arg); +static enum st_retval stFree (void *key, void *value, void *arg); + +/** \endcond */ -/**AutomaticEnd***************************************************************/ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ @@ -101,29 +87,27 @@ static enum st_retval stFree (char *key, char *value, char *arg); /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Check that minterm counts have not changed. - Synopsis [Check that minterm counts have not changed.] - - Description [Counts the minterms in the global functions of the + @details Counts the minterms in the global functions of the primary outputs of the network passed as argument. When it is calld with the second argument set to NULL, it allocates a symbol table and stores, for each output, the minterm count. If - an output does not have a BDD, it stores a NULL pointer for it. + an output does not have a %BDD, it stores a NULL pointer for it. If it is called with a non-null second argument, it assumes that the symbol table contains the minterm counts measured previously and it compares the new counts to the old ones. Finally, it frees the symbol table. check_minterms is designed so that it can be called twice: once before reordering, and once after reordering. - Returns a pointer to the symbol table on the first invocation and NULL - on the second invocation.] - SideEffects [None] + @return a pointer to the symbol table on the first invocation and + NULL on the second invocation. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ st_table * checkMinterms( BnetNetwork * net, @@ -139,20 +123,20 @@ checkMinterms( numPi = net->ninputs; if (previous == NULL) { - previous = st_init_table(strcmp,st_strhash); + previous = st_init_table((st_compare_t) strcmp, st_strhash); if (previous == NULL) { (void) printf("checkMinterms out-of-memory\n"); return(NULL); } for (i = 0; i < net->noutputs; i++) { - if (!st_lookup(net->hash,net->outputs[i],&po)) { + if (!st_lookup(net->hash,net->outputs[i],(void **)&po)) { exit(2); } name = net->outputs[i]; if (po->dd != NULL) { count = ALLOC(double,1); *count = Cudd_CountMinterm(dd,po->dd,numPi); - err = st_insert(previous, name, (char *) count); + err = st_insert(previous, name, (void *) count); } else { err = st_insert(previous, name, NULL); } @@ -170,11 +154,11 @@ checkMinterms( flag = 1; } for (i = 0; i < net->noutputs; i++) { - if (!st_lookup(net->hash,net->outputs[i],&po)) { + if (!st_lookup(net->hash,net->outputs[i],(void **)&po)) { exit(2); } name = net->outputs[i]; - if (st_lookup(previous,name,&oldcount)) { + if (st_lookup(previous,name,(void **)&oldcount)) { if (po->dd != NULL) { newcount = Cudd_CountMinterm(dd,po->dd,numPi); if (newcount != *oldcount) { @@ -193,7 +177,7 @@ checkMinterms( } } /*st_foreach(previous,(enum st_retval)stFree,NULL);*/ - st_foreach(previous,(ST_PFSR)stFree,NULL); + st_foreach(previous,stFree,NULL); st_free_table(previous); if (flag) { return((st_table *) 1); @@ -210,23 +194,20 @@ checkMinterms( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Frees the data of the symbol table.] - - Description [] - - SideEffects [None] +/** + @brief Frees the data of the symbol table. - SeeAlso [] + @sideeffect None -*****************************************************************************/ +*/ static enum st_retval stFree( - char *key, - char *value, - char *arg) + void *key, + void *value, + void *arg) { + (void) key; /* avoid warning */ + (void) arg; /* avoid warning */ if (value != NULL) { FREE(value); } diff --git a/resources/3rdparty/cudd-3.0.0/nanotrav/closest.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/closest.blif new file mode 100644 index 000000000..d718a89fd --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/closest.blif @@ -0,0 +1,11 @@ +.model closest +.inputs a b c +.outputs f g h +.names a b c f +1-1 1 +-11 1 +.names a b c g +000 1 +.names a b c h +111 1 +.end diff --git a/resources/3rdparty/cudd-3.0.0/nanotrav/ham01.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/ham01.blif new file mode 100644 index 000000000..4b80e1bb7 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/ham01.blif @@ -0,0 +1,42 @@ +# Checks whether the Hamming distance between X and Y is 0 or 1. +.model ham01.blif +.inputs x2 y2 x1 y1 x0 y0 +.outputs H01 +.names one +1 +.names y0 one one a +11- 1 +0-0 1 +.names x0 a a b +11- 1 +0-0 1 +.names y1 one b c +11- 1 +0-1 1 +.names y1 b one d +11- 1 +0-1 1 +.names y1 b one e +11- 1 +0-0 1 +.names y1 one b f +11- 1 +0-0 1 +.names x1 c d g +11- 1 +0-1 1 +.names x1 e f h +11- 1 +0-0 1 +.names y2 g h i +11- 1 +0-1 1 +.names y2 h g j +11- 1 +0-1 1 +.names x2 i j k +11- 1 +0-1 1 +.names k H01 +1 1 +.end diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/main.c b/resources/3rdparty/cudd-3.0.0/nanotrav/main.c similarity index 87% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/main.c rename to resources/3rdparty/cudd-3.0.0/nanotrav/main.c index f0a37d660..03898b369 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/main.c +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/main.c @@ -1,18 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [main.c] + @ingroup nanotrav - PackageName [ntr] + @brief Main program for the nanotrav program. - Synopsis [Main program for the nanotrav program.] + @author Fabio Somenzi - Description [] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,19 +38,19 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ -#include "ntr.h" #include "cuddInt.h" +#include "ntr.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ /*---------------------------------------------------------------------------*/ -#define NTR_VERSION\ - "Nanotrav Version #0.12, Release date 2003/12/31" +#define NTR_VERSION "Nanotrav Version #0.13, Release date 2015/7/15" #define BUFLENGTH 8192 @@ -70,10 +66,6 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] UTIL_UNUSED = "$Id: main.c,v 1.41 2012/02/05 01:53:01 fabio Exp fabio $"; -#endif - static char buffer[BUFLENGTH]; #ifdef DD_DEBUG extern st_table *checkMinterms (BnetNetwork *net, DdManager *dd, st_table *previous); @@ -83,7 +75,7 @@ extern st_table *checkMinterms (BnetNetwork *net, DdManager *dd, st_table *prev /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -99,25 +91,23 @@ static void freeOption (NtrOptions *option); static DdManager * startCudd (NtrOptions *option, int nvars); static int ntrReadTree (DdManager *dd, char *treefile, int nvars); -/**AutomaticEnd***************************************************************/ +/** \endcond */ + /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Main program for ntr.] +/** + @brief Main program for ntr. - Description [Main program for ntr. Performs initialization. Reads command - line options and network(s). Builds BDDs with reordering, and optionally - does reachability analysis. Prints stats.] + @details Performs initialization. Reads command line options and + network(s). Builds BDDs with reordering, and optionally does + reachability analysis. Prints stats. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int main( int argc, @@ -140,6 +130,9 @@ main( int reencoded; /* linear transformations attempted */ /* Initialize. */ +#if defined(_WIN32) && defined(_TWO_DIGIT_EXPONENT) + (void) _set_output_format(_TWO_DIGIT_EXPONENT); +#endif option = mainInit(); ntrReadOptions(argc,argv,option); pr = option->verb; @@ -237,17 +230,17 @@ main( /* Print the re-encoded inputs. */ if (pr >= 1 && reencoded == 1) { for (i = 0; i < net1->npis; i++) { - if (!st_lookup(net1->hash,net1->inputs[i],&node)) { + if (!st_lookup(net1->hash,net1->inputs[i],(void **)&node)) { exit(2); } - (void) fprintf(stdout,"%s:",node->name); + (void) fprintf(stdout,"%s ",node->name); Cudd_PrintDebug(dd,node->dd,Cudd_ReadSize(dd),pr); } for (i = 0; i < net1->nlatches; i++) { - if (!st_lookup(net1->hash,net1->latches[i][1],&node)) { + if (!st_lookup(net1->hash,net1->latches[i][1],(void **)&node)) { exit(2); } - (void) fprintf(stdout,"%s:",node->name); + (void) fprintf(stdout,"%s ",node->name); Cudd_PrintDebug(dd,node->dd,Cudd_ReadSize(dd),pr); } if (pr >= 3) { @@ -283,6 +276,7 @@ main( NtrPartTR *T; T = Ntr_buildTR(dd,net1,option,option->image); result = Ntr_Envelope(dd,T,NULL,option); + if (result == 0) exit(2); Ntr_freeTR(dd,T); } @@ -387,7 +381,7 @@ main( if (option->signatures) { (void) printf("Positive cofactor measures\n"); for (i = 0; i < net1->noutputs; i++) { - if (!st_lookup(net1->hash,net1->outputs[i],&node)) { + if (!st_lookup(net1->hash,net1->outputs[i],(void **)&node)) { exit(2); } signatures = Cudd_CofMinterm(dd, node->dd); @@ -412,7 +406,7 @@ main( option->scc == FALSE) { (void) printf("Dumping BDDs to %s\n", option->dumpfile); if (option->node != NULL) { - if (!st_lookup(net1->hash,option->node,&node)) { + if (!st_lookup(net1->hash,option->node,(void **)&node)) { exit(2); } result = Bnet_bddArrayDump(dd,net1,option->dumpfile,&(node->dd), @@ -447,6 +441,7 @@ main( node->type != BNET_INPUT_NODE && node->type != BNET_PRESENT_STATE_NODE) { Cudd_IterDerefBdd(dd,node->dd); + node->dd = NULL; } node = node->next; } @@ -455,12 +450,16 @@ main( /* Do the same cleanup for the second network if it was created. */ if (option->verify == TRUE || option->second == TRUE || option->clip > 0.0 || option->dontcares == TRUE) { + /* Since option->second is TRUE and reading the second network + * didn't result in a failure, we know net2 is not NULL. */ + assert(net2 != NULL); node = net2->nodes; while (node != NULL) { if (node->dd != NULL && node->type != BNET_INPUT_NODE && node->type != BNET_PRESENT_STATE_NODE) { Cudd_IterDerefBdd(dd,node->dd); + node->dd = NULL; } node = node->next; } @@ -470,12 +469,16 @@ main( /* Check reference counts: At this point we should have dereferenced ** everything we had, except in the case of re-encoding. */ - exitval = Cudd_CheckZeroRef(dd); - ok = exitval != 0; /* ok == 0 means O.K. */ - if (exitval != 0) { - (void) fflush(stdout); - (void) fprintf(stderr, - "%d non-zero DD reference counts after dereferencing\n", exitval); + if (reencoded == CUDD_FALSE) { + exitval = Cudd_CheckZeroRef(dd); + ok = exitval != 0; /* ok == 0 means O.K. */ + if (exitval != 0) { + (void) fflush(stdout); + (void) fprintf(stderr, + "%d non-zero DD reference counts after dereferencing\n", exitval); + } + } else { + ok = 0; } #ifdef DD_DEBUG @@ -489,12 +492,7 @@ main( freeOption(option); if (pr >= 0) util_print_cpu_stats(stdout); -#ifdef MNEMOSYNE - mnem_writestats(); -#endif - exit(ok); - /* NOTREACHED */ } /* end of main */ @@ -508,17 +506,14 @@ main( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Allocates the option structure and initializes it.] - - Description [] +/** + @brief Allocates the option structure and initializes it. - SideEffects [none] + @sideeffect none - SeeAlso [ntrReadOptions] + @see ntrReadOptions -******************************************************************************/ +*/ static NtrOptions * mainInit( ) @@ -568,7 +563,7 @@ mainInit( option->cacheSize = 32768; option->maxMemory = 0; /* set automatically */ option->maxMemHard = 0; /* don't set */ - option->maxLive = ~0; /* very large number */ + option->maxLive = ~0U; /* very large number */ option->slots = CUDD_UNIQUE_SLOTS; option->ordering = PI_PS_FROM_FILE; option->orderPiPs = NULL; @@ -596,27 +591,27 @@ mainInit( option->storefile = NULL; option->load = FALSE; option->loadfile = NULL; + option->seed = 1; return(option); } /* end of mainInit */ -/**Function******************************************************************** +/** + @brief Reads the command line options. - Synopsis [Reads the command line options.] + @details Scans the command line one argument at a time and performs + a switch on each arguement it hits. Some arguemnts also read in the + following arg from the list (i.e., -f also gets the filename which + should folow.) Gives a usage message and exits if any unrecognized + args are found. - Description [Reads the command line options. Scans the command line - one argument at a time and performs a switch on each arguement it - hits. Some arguemnts also read in the following arg from the list - (i.e., -f also gets the filename which should folow.) - Gives a usage message and exits if any unrecognized args are found.] + @sideeffect May initialize the random number generator. - SideEffects [May initialize the random number generator.] + @see mainInit ntrReadOptionsFile - SeeAlso [mainInit ntrReadOptionsFile] - -******************************************************************************/ +*/ static void ntrReadOptions( int argc, @@ -973,7 +968,7 @@ ntrReadOptions( option->numberXovers = (int) atoi(argv[i]); } else if (STRING_EQUAL(argv[i],"-seed")) { i++; - Cudd_Srandom((long)atoi(argv[i])); + option->seed = (int32_t) atoi(argv[i]); } else if (STRING_EQUAL(argv[i],"-dumpfile")) { i++; option->bdddump = TRUE; @@ -1038,24 +1033,20 @@ usage: /* convenient goto */ } /* end of ntrReadOptions */ -/**Function******************************************************************** - - Synopsis [Reads the program options from a file.] - - Description [Reads the program options from a file. Opens file. Reads - the command line from the otpions file using the read_line func. Scans - the line looking for spaces, each space is a searator and demarks a - new option. When a space is found, it is changed to a \0 to terminate - that string; then the next value of slot points to the next non-space - character. There is a limit of 1024 options. - Should produce an error (presently doesn't) on overrun of options, but - this is very unlikely to happen.] +/** + @brief Reads the program options from a file. - SideEffects [none] + @details Opens file. Reads the command line from the otpions file + using the read_line func. Scans the line looking for spaces, each + space is a searator and demarks a new option. When a space is + found, it is changed to a \0 to terminate that string; then the next + value of slot points to the next non-space character. There is a + limit of 1024 options. Should produce an error (presently doesn't) + on overrun of options, but this is very unlikely to happen. - SeeAlso [] + @sideeffect none -******************************************************************************/ +*/ static void ntrReadOptionsFile( char * name, @@ -1100,17 +1091,12 @@ ntrReadOptionsFile( } /* end of ntrReadOptionsFile */ -/**Function******************************************************************** - - Synopsis [Reads a line from the option file.] - - Description [] +/** + @brief Reads a line from the option file. - SideEffects [none] + @sideeffect none - SeeAlso [] - -******************************************************************************/ +*/ static char* readLine( FILE * fp) @@ -1153,18 +1139,15 @@ readLine( } /* end of readLine */ -/**Function******************************************************************** - - Synopsis [Opens a file.] +/** + @brief Opens a file. - Description [Opens a file, or fails with an error message and exits. - Allows '-' as a synonym for standard input.] + @details Opens a file, or fails with an error message and exits. + Allows '-' as a synonym for standard input. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static FILE * open_file( char * filename, @@ -1183,22 +1166,18 @@ open_file( } /* end of open_file */ -/**Function******************************************************************** - - Synopsis [Applies reordering to the DDs.] +/** + @brief Explicitly applies reordering to the DDs. - Description [Explicitly applies reordering to the DDs. Returns 1 if - successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -*****************************************************************************/ +*/ static int reorder( BnetNetwork * net, - DdManager * dd /* DD Manager */, + DdManager * dd, NtrOptions * option) { #ifdef DD_DEBUG @@ -1241,6 +1220,10 @@ reorder( return(0); } mintermTable = checkMinterms(net,dd,mintermTable); + if (mintermTable != NULL) { + (void) fprintf(stderr,"Error in checkMinterms\n"); + return(0); + } #endif /* Print symmetry stats if pertinent */ @@ -1263,17 +1246,12 @@ reorder( } /* end of reorder */ -/**Function******************************************************************** - - Synopsis [Frees the option structure and its appendages.] - - Description [] - - SideEffects [None] +/** + @brief Frees the option structure and its appendages. - SeeAlso [] + @sideeffect None -*****************************************************************************/ +*/ static void freeOption( NtrOptions * option) @@ -1292,19 +1270,15 @@ freeOption( } /* end of freeOption */ -/**Function******************************************************************** +/** + @brief Starts the CUDD manager with the desired options. - Synopsis [Starts the CUDD manager with the desired options.] + @details Starts with 0 variables, because Ntr_buildDDs will create + new variables rather than using whatever already exists. - Description [Starts the CUDD manager with the desired options. - We start with 0 variables, because Ntr_buildDDs will create new - variables rather than using whatever already exists.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -*****************************************************************************/ +*/ static DdManager * startCudd( NtrOptions * option, @@ -1316,6 +1290,7 @@ startCudd( dd = Cudd_Init(0, 0, option->slots, option->cacheSize, option->maxMemory); if (dd == NULL) return(NULL); + Cudd_Srandom(dd, option->seed); if (option->maxMemHard != 0) { Cudd_SetMaxMemory(dd,option->maxMemHard); } @@ -1352,18 +1327,14 @@ startCudd( } /* end of startCudd */ -/**Function******************************************************************** - - Synopsis [Reads the variable group tree from a file.] - - Description [Reads the variable group tree from a file. - Returns 1 if successful; 0 otherwise.] +/** + @brief Reads the variable group tree from a file. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -*****************************************************************************/ +*/ static int ntrReadTree( DdManager * dd, diff --git a/resources/3rdparty/cudd-3.0.0/nanotrav/miniFirst.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/miniFirst.blif new file mode 100644 index 000000000..13f2a60b2 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/miniFirst.blif @@ -0,0 +1,10 @@ +.model first +.inputs a b c d +.outputs A +.names a b c d A +--01 0 +-0-0 0 +-011 0 +1-00 0 +01-0 0 +.end diff --git a/resources/3rdparty/cudd-3.0.0/nanotrav/miniSecond.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/miniSecond.blif new file mode 100644 index 000000000..2c3621970 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/miniSecond.blif @@ -0,0 +1,8 @@ +.model second +.inputs a b c +.outputs B +.names a b c B +000 1 +-11 1 +101 1 +.end diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/mult32a.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/mult32a.blif similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/mult32a.blif rename to resources/3rdparty/cudd-3.0.0/nanotrav/mult32a.blif diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/nanotrav.1 b/resources/3rdparty/cudd-3.0.0/nanotrav/nanotrav.1 similarity index 99% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/nanotrav.1 rename to resources/3rdparty/cudd-3.0.0/nanotrav/nanotrav.1 index ba50f469b..8effada07 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/nanotrav.1 +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/nanotrav.1 @@ -284,13 +284,13 @@ variable. The default value is 20. use \fImethod\fR for dynamic reordering of the BDDs. \fImethod\fR can be one of none, random, pivot, sifting, converge, symm, cosymm, group, cogroup, win2, win3, win4, win2conv, win3conv, win4conv, annealing, -genetic, exact. The default method is sifting. +genetic, linear, linconv, exact. The default method is sifting. .TP 10 .B \-reordering \fImethod\fB use \fImethod\fR for the final reordering of the BDDs. \fImethod\fR can be one of none, random, pivot, sifting, converge, symm, cosymm, group, cogroup, win2, win3, win4, win2conv, win3conv, win4conv, annealing, -genetic, exact. The default method is none. +genetic, linear, linconv, exact. The default method is none. .TP 10 .B \-genetic run the genetic algorithm after the final reordering (which in this case diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntr.c b/resources/3rdparty/cudd-3.0.0/nanotrav/ntr.c similarity index 80% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/ntr.c rename to resources/3rdparty/cudd-3.0.0/nanotrav/ntr.c index 24b4aa705..d9c901762 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntr.c +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/ntr.c @@ -1,18 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [ntr.c] + @ingroup nanotrav - PackageName [ntr] + @brief A very simple reachability analysis program. - Synopsis [A very simple reachability analysis program.] + @author Fabio Somenzi - Description [] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,12 +38,13 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ +#include "cuddInt.h" #include "ntr.h" -#include "ucbqsort.h" /*---------------------------------------------------------------------------*/ /* Constant declarations */ @@ -67,22 +64,18 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] UTIL_UNUSED = "$Id: ntr.c,v 1.28 2012/02/05 01:53:01 fabio Exp fabio $"; -#endif - -static const char *onames[] = { "T", "R" }; /* names of functions to be dumped */ -static double *signatures; /* signatures for all variables */ -static BnetNetwork *staticNet; /* pointer to network used by qsort - ** comparison function */ -static DdNode **staticPart; /* pointer to parts used by qsort - ** comparison function */ +static char const *onames[] = {"T", "R"}; /**< names of functions to be dumped */ +static double *signatures; /**< signatures for all variables */ +static BnetNetwork *staticNet; /**< pointer to network used by qsort + ** comparison function */ +static DdNode **staticPart; /**< pointer to parts used by qsort + ** comparison function */ /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -104,37 +97,37 @@ static int ntrPartCompare (int * ptrX, int * ptrY); static char ** ntrAllocMatrix (int nrows, int ncols); static void ntrFreeMatrix (char **matrix); static void ntrPermuteParts (DdNode **a, DdNode **b, int *comesFrom, int *goesTo, int size); +static void ntrIncreaseRef(void * e, void * arg); +static void ntrDecreaseRef(void * e, void * arg); + +/** \endcond */ -/**AutomaticEnd***************************************************************/ /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Builds DDs for a network outputs and next state functions. - Synopsis [Builds DDs for a network outputs and next state - functions.] + @details The method is really brain-dead, but it is very simple. + Some inputs to the network may be shared with another network whose + DDs have already been built. In this case we want to share the DDs + as well. - Description [Builds DDs for a network outputs and next state - functions. The method is really brain-dead, but it is very simple. - Returns 1 in case of success; 0 otherwise. Some inputs to the network - may be shared with another network whose DDs have already been built. - In this case we want to share the DDs as well.] + @return 1 in case of success; 0 otherwise. - SideEffects [the dd fields of the network nodes are modified. Uses the - count fields of the nodes.] + @sideeffect the dd fields of the network nodes are modified. Uses the + count fields of the nodes. - SeeAlso [] - -******************************************************************************/ +*/ int Ntr_buildDDs( - BnetNetwork * net /* network for which DDs are to be built */, - DdManager * dd /* DD manager */, - NtrOptions * option /* option structure */, - BnetNetwork * net2 /* companion network with which inputs may be shared */) + BnetNetwork * net /**< network for which DDs are to be built */, + DdManager * dd /**< %DD manager */, + NtrOptions * option /**< option structure */, + BnetNetwork * net2 /**< companion network with which inputs may be shared */) { int pr = option->verb; int result; @@ -146,10 +139,10 @@ Ntr_buildDDs( */ if (net2 != NULL) { for (i = 0; i < net->npis; i++) { - if (!st_lookup(net->hash,net->inputs[i],&node)) { + if (!st_lookup(net->hash,net->inputs[i],(void **)&node)) { return(0); } - if (!st_lookup(net2->hash,net->inputs[i],&node2)) { + if (!st_lookup(net2->hash,net->inputs[i],(void **)&node2)) { /* This input is not shared. */ result = Bnet_BuildNodeBDD(dd,node,net->hash, option->locGlob,option->nodrop); @@ -163,10 +156,10 @@ Ntr_buildDDs( } } for (i = 0; i < net->nlatches; i++) { - if (!st_lookup(net->hash,net->latches[i][1],&node)) { + if (!st_lookup(net->hash,net->latches[i][1],(void **)&node)) { return(0); } - if (!st_lookup(net2->hash,net->latches[i][1],&node2)) { + if (!st_lookup(net2->hash,net->latches[i][1],(void **)&node2)) { /* This present state variable is not shared. */ result = Bnet_BuildNodeBDD(dd,node,net->hash, option->locGlob,option->nodrop); @@ -188,7 +181,7 @@ Ntr_buildDDs( ** and then present state variables. */ for (i = 0; i < net->npis; i++) { - if (!st_lookup(net->hash,net->inputs[i],&node)) { + if (!st_lookup(net->hash,net->inputs[i],(void **)&node)) { return(0); } result = Bnet_BuildNodeBDD(dd,node,net->hash, @@ -196,7 +189,7 @@ Ntr_buildDDs( if (result == 0) return(0); } for (i = 0; i < net->nlatches; i++) { - if (!st_lookup(net->hash,net->latches[i][1],&node)) { + if (!st_lookup(net->hash,net->latches[i][1],(void **)&node)) { return(0); } result = Bnet_BuildNodeBDD(dd,node,net->hash, @@ -242,7 +235,7 @@ Ntr_buildDDs( if (option->node != NULL && option->closestCube == FALSE && option->dontcares == FALSE) { - if (!st_lookup(net->hash,option->node,&node)) { + if (!st_lookup(net->hash,option->node,(void **)&node)) { return(0); } result = Bnet_BuildNodeBDD(dd,node,net->hash,BNET_GLOBAL_DD, @@ -251,7 +244,7 @@ Ntr_buildDDs( } else { if (option->stateOnly == FALSE) { for (i = 0; i < net->npos; i++) { - if (!st_lookup(net->hash,net->outputs[i],&node)) { + if (!st_lookup(net->hash,net->outputs[i],(void **)&node)) { continue; } result = Bnet_BuildNodeBDD(dd,node,net->hash, @@ -266,7 +259,7 @@ Ntr_buildDDs( } } for (i = 0; i < net->nlatches; i++) { - if (!st_lookup(net->hash,net->latches[i][0],&node)) { + if (!st_lookup(net->hash,net->latches[i][0],(void **)&node)) { continue; } result = Bnet_BuildNodeBDD(dd,node,net->hash,BNET_GLOBAL_DD, @@ -284,7 +277,7 @@ Ntr_buildDDs( ** the nodes that are not reachable from the outputs. */ for (i = 0; i < net->npis; i++) { - if (!st_lookup(net->hash,net->inputs[i],&node)) { + if (!st_lookup(net->hash,net->inputs[i],(void **)&node)) { return(0); } result = Bnet_BuildNodeBDD(dd,node,net->hash,BNET_GLOBAL_DD, @@ -293,7 +286,7 @@ Ntr_buildDDs( if (node->count == -1) Cudd_RecursiveDeref(dd,node->dd); } for (i = 0; i < net->nlatches; i++) { - if (!st_lookup(net->hash,net->latches[i][1],&node)) { + if (!st_lookup(net->hash,net->latches[i][1],(void **)&node)) { return(0); } result = Bnet_BuildNodeBDD(dd,node,net->hash,BNET_GLOBAL_DD, @@ -320,28 +313,24 @@ Ntr_buildDDs( return(1); -} /* end of buildDD */ - +} /* end of Ntr_buildDDs */ -/**Function******************************************************************** - Synopsis [Builds the transition relation for a network.] +/** + @brief Builds the transition relation for a network. - Description [Builds the transition relation for a network. Returns a - pointer to the transition relation structure if successful; NULL - otherwise.] + @return a pointer to the transition relation structure if + successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ NtrPartTR * Ntr_buildTR( - DdManager * dd /* manager */, - BnetNetwork * net /* network */, - NtrOptions * option /* options */, - int image /* image type: monolithic ... */) + DdManager * dd /**< manager */, + BnetNetwork * net /**< network */, + NtrOptions * option /**< options */, + int image /**< image type: monolithic ... */) { NtrPartTR *TR; DdNode *T, *delta, *support, *scan, *tmp, *preiabs, *prepabs; @@ -395,7 +384,7 @@ Ntr_buildTR( TR->xw = Cudd_ReadOne(dd); Cudd_Ref(TR->xw); for (i = 0; i < net->nlatches; i++) { - if (!st_lookup(net->hash,net->latches[i][1],&node)) { + if (!st_lookup(net->hash,net->latches[i][1],(void **)&node)) { goto endgame; } x[i] = node->dd; @@ -420,7 +409,7 @@ Ntr_buildTR( goto endgame; } /* Get next state function and create transition relation part. */ - if (!st_lookup(net->hash,net->latches[i][0],&node)) { + if (!st_lookup(net->hash,net->latches[i][0],(void **)&node)) { goto endgame; } delta = node->dd; @@ -448,7 +437,7 @@ Ntr_buildTR( /* Collect primary inputs. */ for (i = 0; i < net->npis; i++) { - if (!st_lookup(net->hash,net->inputs[i],&node)) { + if (!st_lookup(net->hash,net->inputs[i],(void **)&node)) { goto endgame; } pi[i] = node->dd; @@ -626,17 +615,12 @@ endgame: } /* end of Ntr_buildTR */ -/**Function******************************************************************** - - Synopsis [Frees the transition relation for a network.] - - Description [] - - SideEffects [None] +/** + @brief Frees the transition relation for a network. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ void Ntr_freeTR( DdManager * dd, @@ -662,9 +646,7 @@ Ntr_freeTR( Cudd_RecursiveDeref(dd,TR->preiabs); Cudd_RecursiveDeref(dd,TR->prepabs); Cudd_RecursiveDeref(dd,TR->xw); - for (i = 0; i < TR->factors->nslots; i++) { - Cudd_RecursiveDeref(dd, (DdNode *) TR->factors->slots[i].item); - } + Ntr_HeapForeach(TR->factors, ntrDecreaseRef, dd); Ntr_FreeHeap(TR->factors); FREE(TR); @@ -673,18 +655,16 @@ Ntr_freeTR( } /* end of Ntr_freeTR */ -/**Function******************************************************************** - - Synopsis [Makes a copy of a transition relation.] +/** + @brief Makes a copy of a transition relation. - Description [Makes a copy of a transition relation. Returns a pointer - to the copy if successful; NULL otherwise.] + @return a pointer to the copy if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_buildTR Ntr_freeTR] + @see Ntr_buildTR Ntr_freeTR -******************************************************************************/ +*/ NtrPartTR * Ntr_cloneTR( NtrPartTR *TR) @@ -752,9 +732,7 @@ Ntr_cloneTR( FREE(T); return(NULL); } - for (i = 0; i < T->factors->nslots; i++) { - Cudd_Ref((DdNode *) T->factors->slots[i].item); - } + Ntr_HeapForeach(T->factors, ntrIncreaseRef, NULL); for (i = 0; i < nparts; i++) { T->part[i] = TR->part[i]; Cudd_Ref(T->part[i]); @@ -783,23 +761,23 @@ Ntr_cloneTR( } /* end of Ntr_cloneTR */ -/**Function******************************************************************** +/** + @brief Poor man's traversal procedure. - Synopsis [Poor man's traversal procedure.] + @details Based on the monolithic transition relation. - Description [Poor man's traversal procedure. based on the monolithic - transition relation. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_ClosureTrav] + @see Ntr_ClosureTrav -******************************************************************************/ +*/ int Ntr_Trav( - DdManager * dd /* DD manager */, - BnetNetwork * net /* network */, - NtrOptions * option /* options */) + DdManager * dd /**< %DD manager */, + BnetNetwork * net /**< network */, + NtrOptions * option /**< options */) { NtrPartTR *TR; /* Transition relation */ DdNode *init; /* initial state(s) */ @@ -811,8 +789,7 @@ Ntr_Trav( int depth; int retval; int pr = option->verb; - unsigned int initReord; - initReord = Cudd_ReadReorderings(dd); + unsigned int initReord = Cudd_ReadReorderings(dd); if (option->traverse == FALSE || net->nlatches == 0) return(1); (void) printf("Building transition relation. Time = %s\n", @@ -824,6 +801,7 @@ Ntr_Trav( TR = Ntr_buildTR(dd,net,option,option->image); if (TR == NULL) return(0); retval = Cudd_SetVarMap(dd,TR->x,TR->y,TR->nlatches); + if (retval == 0) return(0); (void) printf("Transition relation: %d parts %d latches %d nodes\n", TR->nparts, TR->nlatches, Cudd_SharingSize(TR->part, TR->nparts)); @@ -939,24 +917,24 @@ Ntr_Trav( } /* end of Ntr_Trav */ -/**Function******************************************************************** +/** + @brief Computes the SCCs of the STG. - Synopsis [Computes the SCCs of the STG.] + @details Computes the strongly connected components of the state + transition graph. Only the first 10 SCCs are computed. - Description [Computes the strongly connected components of the state - transition graph. Only the first 10 SCCs are computed. Returns 1 in - case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_Trav] + @see Ntr_Trav -******************************************************************************/ +*/ int Ntr_SCC( - DdManager * dd /* DD manager */, - BnetNetwork * net /* network */, - NtrOptions * option /* options */) + DdManager * dd /**< %DD manager */, + BnetNetwork * net /**< network */, + NtrOptions * option /**< options */) { NtrPartTR *TR; /* Transition relation */ DdNode *init; /* initial state(s) */ @@ -966,7 +944,7 @@ Ntr_SCC( DdNode *neW; DdNode *one, *zero; DdNode *states, *scc; - DdNode *tmp; + DdNode *tmp = NULL; DdNode *SCCs[10]; int depth; int nscc = 0; @@ -984,6 +962,7 @@ Ntr_SCC( TR = Ntr_buildTR(dd,net,option,option->image); if (TR == NULL) return(0); retval = Cudd_SetVarMap(dd,TR->x,TR->y,TR->nlatches); + if (retval == 0) return(0); (void) printf("Transition relation: %d parts %d latches %d nodes\n", TR->nparts, TR->nlatches, Cudd_SharingSize(TR->part, TR->nparts)); @@ -1184,23 +1163,24 @@ Ntr_SCC( } /* end of Ntr_SCC */ -/**Function******************************************************************** +/** + @brief Transitive closure traversal procedure. - Synopsis [Transitive closure traversal procedure.] + @details Traversal procedure based on the transitive closure of the + transition relation. - Description [Traversal procedure. based on the transitive closure of the - transition relation. Returns 1 in case of success; 0 otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_Trav] + @see Ntr_Trav -******************************************************************************/ +*/ int Ntr_ClosureTrav( - DdManager * dd /* DD manager */, - BnetNetwork * net /* network */, - NtrOptions * option /* options */) + DdManager * dd /**< %DD manager */, + BnetNetwork * net /**< network */, + NtrOptions * option /**< options */) { DdNode *init; DdNode *T; @@ -1272,19 +1252,16 @@ Ntr_ClosureTrav( } /* end of Ntr_ClosureTrav */ -/**Function******************************************************************** - - Synopsis [Builds the transitive closure of a transition relation.] +/** + @brief Builds the transitive closure of a transition relation. - Description [Builds the transitive closure of a transition relation. - Returns a BDD if successful; NULL otherwise. Uses a simple squaring - algorithm.] + @details Uses a simple squaring algorithm. - SideEffects [None] + @return a %BDD if successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * Ntr_TransitiveClosure( DdManager * dd, @@ -1377,18 +1354,14 @@ Ntr_TransitiveClosure( } /* end of Ntr_TransitiveClosure */ -/**Function******************************************************************** - - Synopsis [Builds the BDD of the initial state(s).] - - Description [Builds the BDD of the initial state(s). Returns a BDD - if successful; NULL otherwise.] +/** + @brief Builds the %BDD of the initial state(s). - SideEffects [None] + @return a %BDD if successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ DdNode * Ntr_initState( DdManager * dd, @@ -1409,7 +1382,7 @@ Ntr_initState( if (net->nlatches == 0) return(res); for (i = 0; i < net->nlatches; i++) { - if (!st_lookup(net->hash,net->latches[i][1],&node)) { + if (!st_lookup(net->hash,net->latches[i][1],(void **)&node)) { goto endgame; } x = node->dd; @@ -1443,19 +1416,15 @@ endgame: } /* end of Ntr_initState */ -/**Function******************************************************************** +/** + @brief Reads a state cube from a file or creates a random one. - Synopsis [Reads a state cube from a file or creates a random one.] + @return a pointer to the %BDD of the sink nodes if successful; NULL + otherwise. - Description [Reads a state cube from a file or create a random one. - Returns a pointer to the BDD of the sink nodes if successful; NULL - otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -*****************************************************************************/ +*/ DdNode * Ntr_getStateCube( DdManager * dd, @@ -1487,7 +1456,7 @@ Ntr_getStateCube( if (filename == NULL) { /* Pick one random minterm. */ for (i = 0; i < net->nlatches; i++) { - state[i] = (char) ((Cudd_Random() & 0x2000) ? '1' : '0'); + state[i] = (char) ((Cudd_Random(dd) & 0x2000) ? '1' : '0'); } } else { if ((fp = fopen(filename,"r")) == NULL) { @@ -1518,7 +1487,7 @@ Ntr_getStateCube( Cudd_Ref(cube); for (i = 0; i < net->nlatches; i++) { - if (!st_lookup(net->hash,net->latches[i][1],&node)) { + if (!st_lookup(net->hash,net->latches[i][1],(void **)&node)) { Cudd_RecursiveDeref(dd,cube); FREE(state); return(NULL); @@ -1552,25 +1521,22 @@ Ntr_getStateCube( } /* end of Ntr_getStateCube */ -/**Function******************************************************************** +/** + @brief Poor man's outer envelope computation. - Synopsis [Poor man's outer envelope computation.] + @details Based on the monolithic transition relation. - Description [ Poor man's outer envelope computation based on the - monolithic transition relation. Returns 1 in case of success; 0 - otherwise.] + @return 1 in case of success; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int Ntr_Envelope( - DdManager * dd /* DD manager */, - NtrPartTR * TR /* transition relation */, - FILE * dfp /* pointer to file for DD dump */, - NtrOptions * option /* program options */) + DdManager * dd /**< %DD manager */, + NtrPartTR * TR /**< transition relation */, + FILE * dfp /**< pointer to file for %DD dump */, + NtrOptions * option /**< program options */) { DdNode **x; /* array of x variables */ DdNode **y; /* array of y variables */ @@ -1589,6 +1555,7 @@ Ntr_Envelope( one = Cudd_ReadOne(dd); retval = Cudd_SetVarMap(dd,x,y,ns); + if (retval == 0) return(0); /* Initialize From. */ envelope = one; @@ -1612,8 +1579,9 @@ Ntr_Envelope( /* Prepare for new iteration. */ Cudd_RecursiveDeref(dd,oldEnvelope); (void) fprintf(stdout,"Envelope[%d]%s",depth+1,(pr>0)? "" : "\n"); - Cudd_PrintDebug(dd,envelope,ns,pr); - + if (pr > 0 ) { + Cudd_PrintSummary(dd, envelope, ns, 1 /* exponential format */); + } } /* Clean up. */ Cudd_RecursiveDeref(dd,oldEnvelope); @@ -1627,18 +1595,22 @@ Ntr_Envelope( dfunc[0] = TR->part[0]; dfunc[1] = envelope; if (dumpFmt == 1) { - retval = Cudd_DumpBlif(dd,2,dfunc,NULL,(char **)onames,NULL,dfp,0); + retval = Cudd_DumpBlif(dd,2,dfunc,NULL,(char const * const *)onames,NULL,dfp,0); } else if (dumpFmt == 2) { - retval = Cudd_DumpDaVinci(dd,2,dfunc,NULL,(char **)onames,dfp); + retval = Cudd_DumpDaVinci(dd,2,dfunc,NULL, + (char const * const *)onames,dfp); } else if (dumpFmt == 3) { - retval = Cudd_DumpDDcal(dd,2,dfunc,NULL,(char **)onames,dfp); + retval = Cudd_DumpDDcal(dd,2,dfunc,NULL, + (char const * const *)onames,dfp); } else if (dumpFmt == 4) { retval = Cudd_DumpFactoredForm(dd,2,dfunc,NULL, - (char **)onames,dfp); + (char const * const *)onames,dfp); } else if (dumpFmt == 5) { - retval = Cudd_DumpBlif(dd,2,dfunc,NULL,(char **)onames,NULL,dfp,1); + retval = Cudd_DumpBlif(dd,2,dfunc,NULL, + (char const * const *)onames,NULL,dfp,1); } else { - retval = Cudd_DumpDot(dd,2,dfunc,NULL,(char **)onames,dfp); + retval = Cudd_DumpDot(dd,2,dfunc,NULL, + (char const * const *)onames,dfp); } if (retval != 1) { (void) fprintf(stderr,"abnormal termination\n"); @@ -1655,18 +1627,14 @@ Ntr_Envelope( } /* end of Ntr_Envelope */ -/**Function******************************************************************** +/** + @brief Maximum 0-1 flow between source and sink states. - Synopsis [Maximum 0-1 flow between source and sink states.] + @return 1 in case of success; 0 otherwise. - Description [Maximum 0-1 flow between source and sink - states. Returns 1 in case of success; 0 otherwise.] + @sideeffect Creates two new sets of variables. - SideEffects [Creates two new sets of variables.] - - SeeAlso [] - -******************************************************************************/ +*/ int Ntr_maxflow( DdManager * dd, @@ -1757,18 +1725,14 @@ endgame: /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Builds a positive cube of all the variables in x.] - - Description [Builds a positive cube of all the variables in x. Returns - a BDD for the cube if successful; NULL otherwise.] +/** + @brief Builds a positive cube of all the variables in x. - SideEffects [None] + @return a %BDD for the cube if successful; NULL otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static DdNode * makecube( DdManager * dd, @@ -1797,26 +1761,23 @@ makecube( } /* end of makecube */ -/**Function******************************************************************** +/** + @brief Initializes the count fields used to drop DDs. - Synopsis [Initializes the count fields used to drop DDs.] + @details Before actually building the BDDs, we perform a DFS from + the outputs to initialize the count fields of the nodes. The + initial value of the count field will normally coincide with the + fanout of the node. However, if there are nodes with no path to any + primary output or next state variable, then the initial value of + count for some nodes will be less than the fanout. For primary + outputs and next state functions we add 1, so that we will never try + to free their DDs. The count fields of the nodes that are not + reachable from the outputs are set to -1. - Description [Initializes the count fields used to drop DDs. - Before actually building the BDDs, we perform a DFS from the outputs - to initialize the count fields of the nodes. The initial value of the - count field will normally coincide with the fanout of the node. - However, if there are nodes with no path to any primary output or next - state variable, then the initial value of count for some nodes will be - less than the fanout. For primary outputs and next state functions we - add 1, so that we will never try to free their DDs. The count fields - of the nodes that are not reachable from the outputs are set to -1.] + @sideeffect Changes the count fields of the network nodes. Uses the + visited fields. - SideEffects [Changes the count fields of the network nodes. Uses the - visited fields.] - - SeeAlso [] - -******************************************************************************/ +*/ static void ntrInitializeCount( BnetNetwork * net, @@ -1827,7 +1788,7 @@ ntrInitializeCount( if (option->node != NULL && option->closestCube == FALSE && option->dontcares == FALSE) { - if (!st_lookup(net->hash,option->node,&node)) { + if (!st_lookup(net->hash,option->node,(void **)&node)) { (void) fprintf(stdout, "Warning: node %s not found!\n", option->node); } else { @@ -1837,7 +1798,7 @@ ntrInitializeCount( } else { if (option->stateOnly == FALSE) { for (i = 0; i < net->npos; i++) { - if (!st_lookup(net->hash,net->outputs[i],&node)) { + if (!st_lookup(net->hash,net->outputs[i],(void **)&node)) { (void) fprintf(stdout, "Warning: output %s is not driven!\n", net->outputs[i]); @@ -1848,7 +1809,7 @@ ntrInitializeCount( } } for (i = 0; i < net->nlatches; i++) { - if (!st_lookup(net->hash,net->latches[i][0],&node)) { + if (!st_lookup(net->hash,net->latches[i][0],(void **)&node)) { (void) fprintf(stdout, "Warning: latch input %s is not driven!\n", net->outputs[i]); @@ -1873,18 +1834,15 @@ ntrInitializeCount( } /* end of ntrInitializeCount */ -/**Function******************************************************************** - - Synopsis [Does a DFS from a node setting the count field.] +/** + @brief Does a DFS from a node setting the count field. - Description [] + @sideeffect Changes the count and visited fields of the nodes it + visits. - SideEffects [Changes the count and visited fields of the nodes it - visits.] + @see ntrLevelDFS - SeeAlso [ntrLevelDFS] - -******************************************************************************/ +*/ static void ntrCountDFS( BnetNetwork * net, @@ -1902,7 +1860,7 @@ ntrCountDFS( node->visited = 1; for (i = 0; i < node->ninp; i++) { - if (!st_lookup(net->hash, node->inputs[i], &auxnd)) { + if (!st_lookup(net->hash, node->inputs[i], (void **)&auxnd)) { exit(2); } ntrCountDFS(net,auxnd); @@ -1911,20 +1869,19 @@ ntrCountDFS( } /* end of ntrCountDFS */ -/**Function******************************************************************** +/** + @brief Computes the image of a set given a transition relation. - Synopsis [Computes the image of a set given a transition relation.] + @details The image is returned in terms of the present state + variables; its reference count is already increased. - Description [Computes the image of a set given a transition relation. - Returns a pointer to the result if successful; NULL otherwise. The image is - returned in terms of the present state variables; its reference count is - already increased.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_Trav] + @see Ntr_Trav -******************************************************************************/ +*/ static DdNode * ntrImage( DdManager * dd, @@ -2045,20 +2002,19 @@ ntrImage( } /* end of ntrImage */ -/**Function******************************************************************** +/** + @brief Computes the preimage of a set given a transition relation. - Synopsis [Computes the preimage of a set given a transition relation.] + @details The preimage is returned in terms of the next state + variables; its reference count is already increased. - Description [Computes the preimage of a set given a transition relation. - Returns a pointer to the result if successful; NULL otherwise. The preimage - is returned in terms of the next state variables; its reference count is - already increased.] + @return a pointer to the result if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [ntrImage Ntr_SCC] + @see ntrImage Ntr_SCC -******************************************************************************/ +*/ static DdNode * ntrPreimage( DdManager * dd, @@ -2099,19 +2055,18 @@ ntrPreimage( } /* end of ntrPreimage */ -/**Function******************************************************************** +/** + @brief Chooses the initial states for a BFS step. - Synopsis [Chooses the initial states for a BFS step.] + @details The reference count of the result is already incremented. - Description [Chooses the initial states for a BFS step. Returns a - pointer to the chose set if successful; NULL otherwise. The - reference count of the result is already incremented.] + @return a pointer to the chose set if successful; NULL otherwise. - SideEffects [none] + @sideeffect none - SeeAlso [Ntr_Trav] + @see Ntr_Trav -******************************************************************************/ +*/ static DdNode * ntrChooseFrom( DdManager * dd, @@ -2179,24 +2134,24 @@ ntrChooseFrom( } /* end of ntrChooseFrom */ -/**Function******************************************************************** +/** + @brief Updates the reached states after a traversal step. - Synopsis [Updates the reached states after a traversal step.] + @details The reference count of the result is already incremented. - Description [Updates the reached states after a traversal - step. Returns a pointer to the new reached set if successful; NULL - otherwise. The reference count of the result is already incremented.] + @return a pointer to the new reached set if successful; NULL + otherwise. - SideEffects [The old reached set is dereferenced.] + @sideeffect The old reached set is dereferenced. - SeeAlso [Ntr_Trav] + @see Ntr_Trav -******************************************************************************/ +*/ static DdNode * ntrUpdateReached( - DdManager * dd /* manager */, - DdNode * oldreached /* old reached state set */, - DdNode * to /* result of last image computation */) + DdManager * dd /**< manager */, + DdNode * oldreached /**< old reached state set */, + DdNode * to /**< result of last image computation */) { DdNode *reached; @@ -2212,22 +2167,20 @@ ntrUpdateReached( } /* end of ntrUpdateReached */ -/**Function******************************************************************** - - Synopsis [Analyzes the reached states after traversal to find - dependent latches.] +/** + @brief Analyzes the reached states after traversal to find + dependent latches. - Description [Analyzes the reached states after traversal to find - dependent latches. Returns the number of latches that can be - eliminated because they are stuck at a constant value or are - dependent on others if successful; -1 otherwise. The algorithm is - greedy and determines a local optimum, not a global one.] + @details The algorithm is greedy and determines a local optimum, not + a global one. - SideEffects [] + @return the number of latches that can be eliminated because they + are stuck at a constant value or are dependent on others if + successful; -1 otherwise. - SeeAlso [Ntr_Trav] + @see Ntr_Trav -******************************************************************************/ +*/ static int ntrLatchDependencies( DdManager *dd, @@ -2275,7 +2228,7 @@ ntrLatchDependencies( (void) printf("Raw signatures (minStates = %g)\n", minStates); for (i = 0; i < net->nlatches; i++) { int j = candidates[i]; - if (!st_lookup(net->hash,net->latches[j][1],(char **) &node)) { + if (!st_lookup(net->hash,net->latches[j][1],(void **)&node)) { return(-1); } (void) printf("%s -> %g\n", node->name, signatures[node->dd->index]); @@ -2286,13 +2239,13 @@ ntrLatchDependencies( signatures[i] = (z >= 0.0) ? z : -z; /* make positive */ } staticNet = net; - cudd__qsort((void *)candidates,net->nlatches,sizeof(int), - (DD_QSFP)ntrSignatureCompare2); + util_qsort(candidates,net->nlatches,sizeof(int), + (DD_QSFP)ntrSignatureCompare2); #if 0 (void) printf("Cooked signatures\n"); for (i = 0; i < net->nlatches; i++) { int j = candidates[i]; - if (!st_lookup(net->hash,net->latches[j][1],(char **) &node)) { + if (!st_lookup(net->hash,net->latches[j][1],(void **)&node)) { return(-1); } (void) printf("%s -> %g\n", node->name, signatures[node->dd->index]); @@ -2303,7 +2256,7 @@ ntrLatchDependencies( /* Extract simple dependencies. */ for (i = 0; i < net->nlatches; i++) { int j = candidates[i]; - if (!st_lookup(net->hash,net->latches[j][1],&node)) { + if (!st_lookup(net->hash,net->latches[j][1],(void **)&node)) { return(-1); } var = node->dd; @@ -2343,7 +2296,7 @@ ntrLatchDependencies( for (i = 0; i < net->nlatches; i++) { int j = candidates[i]; if (j == -1) continue; - if (!st_lookup(net->hash,net->latches[j][1],&node)) { + if (!st_lookup(net->hash,net->latches[j][1],(void **)&node)) { return(-1); } var = node->dd; @@ -2364,7 +2317,7 @@ ntrLatchDependencies( } } FREE(candidates); - if (howManySmall > 0) { + if (howManySmall > 0 && option->verb > 1) { if (!Bnet_bddArrayDump(dd,net,(char *)"-",roots,onames,howManySmall,1)) return(-1); } @@ -2392,19 +2345,17 @@ ntrLatchDependencies( } /* end of ntrLatchDependencies */ -/**Function******************************************************************** +/** + @brief Eliminates dependent variables from a transition relation. - Synopsis [Eliminates dependent variables from a transition relation.] + @return a simplified copy of the given transition relation if + successful; NULL otherwise. - Description [Eliminates dependent variables from a transition - relation. Returns a simplified copy of the given transition - relation if successful; NULL otherwise.] + @sideeffect The modified set of states is returned as a side effect. - SideEffects [The modified set of states is returned as a side effect.] + @see ntrImage - SeeAlso [ntrImage] - -******************************************************************************/ +*/ static NtrPartTR * ntrEliminateDependencies( DdManager *dd, @@ -2427,12 +2378,13 @@ ntrEliminateDependencies( /* Initialize the new transition relation by copying the old one. */ T = Ntr_cloneTR(TR); if (T == NULL) return(NULL); - newstates = *states; - Cudd_Ref(newstates); /* Find and rank the candidate variables. */ + newstates = *states; + Cudd_Ref(newstates); support = Cudd_Support(dd,newstates); if (support == NULL) { + Cudd_RecursiveDeref(dd,newstates); Ntr_freeTR(dd,T); return(NULL); } @@ -2441,6 +2393,7 @@ ntrEliminateDependencies( candidates = ALLOC(int,nvars); if (candidates == NULL) { Cudd_RecursiveDeref(dd,support); + Cudd_RecursiveDeref(dd,newstates); Ntr_freeTR(dd,T); return(NULL); } @@ -2456,6 +2409,7 @@ ntrEliminateDependencies( signatures = Cudd_CofMinterm(dd,newstates); if (signatures == NULL) { FREE(candidates); + Cudd_RecursiveDeref(dd,newstates); Ntr_freeTR(dd,T); return(NULL); } @@ -2468,8 +2422,7 @@ ntrEliminateDependencies( signatures[i] = (z < 0.0) ? -z : z; /* make positive */ } /* Sort candidates in decreasing order of signature. */ - cudd__qsort((void *)candidates,nvars,sizeof(int), - (DD_QSFP)ntrSignatureCompare); + util_qsort(candidates,nvars,sizeof(int), (DD_QSFP)ntrSignatureCompare); FREE(signatures); /* Now process the candidates in the given order. */ @@ -2518,25 +2471,27 @@ ntrEliminateDependencies( /* Quantify out of states variables that no longer appear in any part. */ Cudd_RecursiveDeref(dd,*states); *states = Cudd_bddExistAbstract(dd,newstates,T->preiabs); - if (*states == NULL) return(NULL); Cudd_Ref(*states); + if (*states == NULL) { + Cudd_RecursiveDeref(dd,newstates); + return(NULL); + } + Cudd_Ref(*states); Cudd_RecursiveDeref(dd,newstates); return(T); } /* end of ntrEliminateDependencies */ -/**Function******************************************************************** +/** + @brief Updates the quantification schedule of a transition relation. - Synopsis [Updates the quantification schedule of a transition relation.] + @return 1 if successful; 0 otherwise. - Description [Updates the quantification schedule of a transition relation. - Returns 1 if successful; 0 otherwise.] + @sideeffect None - SideEffects [None] + @see ntrEliminateDependencies - SeeAlso [ntrEliminateDependencies] - -******************************************************************************/ +*/ static int ntrUpdateQuantificationSchedule( DdManager *dd, @@ -2577,7 +2532,7 @@ ntrUpdateQuantificationSchedule( /* Sort parts so that parts that differ only ** in the index of the next state variable are contiguous. */ staticPart = T->part; - cudd__qsort((void *)position,nparts,sizeof(int), (DD_QSFP)ntrPartCompare); + util_qsort(position,nparts,sizeof(int), (DD_QSFP)ntrPartCompare); /* Extract repeated parts. */ extracted = 0; for (i = 0; i < nparts - 1; i += j) { @@ -2600,6 +2555,7 @@ ntrUpdateQuantificationSchedule( eq = tmp; Cudd_RecursiveDeref(dd,T->part[pij]); Cudd_RecursiveDeref(dd,T->icube[pij]); + Cudd_RecursiveDeref(dd,T->pcube[pij]); Cudd_RecursiveDeref(dd,T->nscube[pij]); T->part[pij] = NULL; j++; @@ -2619,6 +2575,7 @@ ntrUpdateQuantificationSchedule( if (T->part[i] != NULL) { T->part[j] = T->part[i]; T->icube[j] = T->icube[i]; + T->pcube[j] = T->pcube[i]; T->nscube[j] = T->nscube[i]; j++; } @@ -2697,7 +2654,7 @@ ntrUpdateQuantificationSchedule( if (schedule[k] == row[j]) { cost++; } else { - flags[k] &= matrix[row[j]][k] == 0; + flags[k] &= (matrix[row[j]][k] == 0); cost -= flags[k]; } } @@ -2715,7 +2672,7 @@ ntrUpdateQuantificationSchedule( for (j = posn + 1; j < nparts; j++) { for (k = 0; k < nvars; k++) { if (schedule[k] == row[j]) { - flags[k] |= matrix[i][k] == 1; + flags[k] |= (matrix[i][k] == 1); cost -= flags[k] == 0; } else { cost += flags[k]; @@ -2816,16 +2773,14 @@ ntrUpdateQuantificationSchedule( } /* end of ntrUpdateQuantificationSchedule */ -/**Function******************************************************************** - - Synopsis [Comparison function used by qsort.] +/** + @brief Comparison function used by qsort. - Description [Comparison function used by qsort to order the - variables according to their signatures.] + @details Used to order the variables according to their signatures. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ntrSignatureCompare( int * ptrX, @@ -2838,16 +2793,14 @@ ntrSignatureCompare( } /* end of ntrSignatureCompare */ -/**Function******************************************************************** +/** + @brief Comparison function used by qsort. - Synopsis [Comparison function used by qsort.] + @details Used to order the variables according to their signatures. - Description [Comparison function used by qsort to order the - variables according to their signatures.] + @sideeffect None - SideEffects [None] - -******************************************************************************/ +*/ static int ntrSignatureCompare2( int * ptrX, @@ -2855,11 +2808,11 @@ ntrSignatureCompare2( { BnetNode *node; int x,y; - if (!st_lookup(staticNet->hash,staticNet->latches[*ptrX][1],&node)) { + if (!st_lookup(staticNet->hash,staticNet->latches[*ptrX][1],(void**)&node)) { return(0); } x = node->dd->index; - if (!st_lookup(staticNet->hash,staticNet->latches[*ptrY][1],&node)) { + if (!st_lookup(staticNet->hash,staticNet->latches[*ptrY][1],(void**)&node)) { return(0); } y = node->dd->index; @@ -2870,16 +2823,14 @@ ntrSignatureCompare2( } /* end of ntrSignatureCompare2 */ -/**Function******************************************************************** - - Synopsis [Comparison function used by qsort.] +/** + @brief Comparison function used by qsort. - Description [Comparison function used by qsort to order the - parts according to the BDD addresses.] + @details Used to order the parts according to their %BDD addresses. - SideEffects [None] + @sideeffect None -******************************************************************************/ +*/ static int ntrPartCompare( int * ptrX, @@ -2892,18 +2843,14 @@ ntrPartCompare( } /* end of ntrPartCompare */ -/**Function******************************************************************** +/** + @brief Allocates a matrix of char's. - Synopsis [Allocates a matrix.] + @return a pointer to the matrix if successful; NULL otherwise. - Description [Allocates a matrix of char's. Returns a pointer to the matrix - if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static char ** ntrAllocMatrix( int nrows, @@ -2930,17 +2877,12 @@ ntrAllocMatrix( } /* end of ntrAllocMatrix */ -/**Function******************************************************************** - - Synopsis [Frees a matrix of char's.] +/** + @brief Frees a matrix of char's. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static void ntrFreeMatrix( char **matrix) @@ -2952,18 +2894,13 @@ ntrFreeMatrix( } /* end of ntrFreeMatrix */ -/**Function******************************************************************** - - Synopsis [Sorts parts according to given permutation.] - - Description [] +/** + @brief Sorts parts according to given permutation. - SideEffects [The permutation arrays are turned into the identity - permutations.] + @sideeffect The permutation arrays are turned into the identity + permutations. - SeeAlso [] - -******************************************************************************/ +*/ static void ntrPermuteParts( DdNode **a, @@ -2988,3 +2925,33 @@ ntrPermuteParts( return; } /* end of ntrPermuteParts */ + + +/** + @brief Calls Cudd_Ref on its first argument. +*/ +static void +ntrIncreaseRef( + void * e, + void * arg) +{ + DdNode * node = (DdNode *) e; + (void) arg; /* avoid warning */ + Cudd_Ref(node); + +} /* end of ntrIncreaseRef */ + + +/** + @brief Calls Cudd_RecursiveDeref on its first argument. +*/ +static void +ntrDecreaseRef( + void * e, + void * arg) +{ + DdNode * node = (DdNode *) e; + DdManager * dd = (DdManager *) arg; + Cudd_RecursiveDeref(dd, node); + +} /* end of ntrIncreaseRef */ diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntr.h b/resources/3rdparty/cudd-3.0.0/nanotrav/ntr.h similarity index 54% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/ntr.h rename to resources/3rdparty/cudd-3.0.0/nanotrav/ntr.h index e70b42100..5e6025e96 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntr.h +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/ntr.h @@ -1,18 +1,14 @@ -/**CHeaderFile***************************************************************** +/** + @file - FileName [ntr.h] + @ingroup nanotrav - PackageName [ntr] + @brief Simple-minded package to do traversal. - Synopsis [Simple-minded package to do traversal.] + @author Fabio Somenzi - Description [] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,11 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] - - Revision [$Id: ntr.h,v 1.28 2012/02/05 01:53:01 fabio Exp fabio $] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #ifndef _NTR #define _NTR @@ -103,106 +98,112 @@ extern "C" { /* Type declarations */ /*---------------------------------------------------------------------------*/ +/** + @brief Options for nanotrav. +*/ typedef struct NtrOptions { - long initialTime; /* this is here for convenience */ - int verify; /* read two networks and compare them */ - char *file1; /* first network file name */ - char *file2; /* second network file name */ - int second; /* a second network is given */ - int traverse; /* do reachability analysis */ - int depend; /* do latch dependence analysis */ - int image; /* monolithic, partitioned, or clip */ - double imageClip; /* clipping depth in image computation */ - int approx; /* under or over approximation */ - int threshold; /* approximation threshold */ - int from; /* method to compute from states */ - int groupnsps; /* group present state and next state vars */ - int closure; /* use transitive closure */ - double closureClip; /* clipping depth in closure computation */ - int envelope; /* compute outer envelope */ - int scc; /* compute strongly connected components */ - int zddtest; /* do zdd test */ - int printcover; /* print ISOP covers when testing ZDDs */ - int maxflow; /* compute maximum flow in network */ - int shortPath; /* compute shortest paths in network */ - int selectiveTrace; /* use selective trace in shortest paths */ - char *sinkfile; /* file for externally provided sink node */ - int partition; /* test McMillan conjunctive partitioning */ - int char2vect; /* test char-to-vect decomposition */ - int density; /* test density-related functions */ - double quality; /* quality parameter for density functions */ - int decomp; /* test decomposition functions */ - int cofest; /* test cofactor estimation */ - double clip; /* test clipping functions */ - int dontcares; /* test equivalence and containment with DCs */ - int closestCube; /* test Cudd_bddClosestCube */ - int clauses; /* test extraction of two-literal clauses */ - int noBuild; /* do not build BDDs; just echo order */ - int stateOnly; /* ignore primary outputs */ - char *node; /* only node for which to build BDD */ - int locGlob; /* build global or local BDDs */ - int progress; /* report output names while building BDDs */ - int cacheSize; /* computed table initial size */ - unsigned long maxMemory; /* target maximum memory */ - unsigned long maxMemHard; /* maximum allowed memory */ - unsigned int maxLive; /* maximum number of nodes */ - int slots; /* unique subtable initial slots */ - int ordering; /* FANIN DFS ... */ - char *orderPiPs; /* file for externally provided order */ - Cudd_ReorderingType reordering; /* NONE RANDOM PIVOT SIFTING ... */ - int autoDyn; /* ON OFF */ - Cudd_ReorderingType autoMethod; /* RANDOM PIVOT SIFTING CONVERGE ... */ - char *treefile; /* file name for variable tree */ - int firstReorder; /* when to do first reordering */ - int countDead; /* count dead nodes toward triggering - reordering */ - int maxGrowth; /* maximum growth during reordering (%) */ - Cudd_AggregationType groupcheck; /* grouping function */ - int arcviolation; /* percent violation of arcs in - extended symmetry check */ - int symmviolation; /* percent symm violation in - extended symmetry check */ - int recomb; /* recombination parameter for grouping */ - int nodrop; /* don't drop intermediate BDDs ASAP */ - int signatures; /* computation of signatures */ - int gaOnOff; /* whether to run GA at the end */ - int populationSize; /* population size for GA */ - int numberXovers; /* number of crossovers for GA */ - int bdddump; /* ON OFF */ - int dumpFmt; /* 0 -> dot 1 -> blif 2 ->daVinci 3 -> DDcal - ** 4 -> factored form */ - char *dumpfile; /* filename for dump */ - int store; /* iteration at which to store Reached */ - char *storefile; /* filename for storing Reached */ - int load; /* load initial states from file */ - char *loadfile; /* filename for loading states */ - int verb; /* level of verbosity */ + long initialTime; /**< this is here for convenience */ + int verify; /**< read two networks and compare them */ + char *file1; /**< first network file name */ + char *file2; /**< second network file name */ + int second; /**< a second network is given */ + int traverse; /**< do reachability analysis */ + int depend; /**< do latch dependence analysis */ + int image; /**< monolithic, partitioned, or clip */ + double imageClip; /**< clipping depth in image computation */ + int approx; /**< under or over approximation */ + int threshold; /**< approximation threshold */ + int from; /**< method to compute from states */ + int groupnsps; /**< group present state and next state vars */ + int closure; /**< use transitive closure */ + double closureClip; /**< clipping depth in closure computation */ + int envelope; /**< compute outer envelope */ + int scc; /**< compute strongly connected components */ + int zddtest; /**< do zdd test */ + int printcover; /**< print ISOP covers when testing ZDDs */ + int maxflow; /**< compute maximum flow in network */ + int shortPath; /**< compute shortest paths in network */ + int selectiveTrace; /**< use selective trace in shortest paths */ + char *sinkfile; /**< file for externally provided sink node */ + int partition; /**< test McMillan conjunctive partitioning */ + int char2vect; /**< test char-to-vect decomposition */ + int density; /**< test density-related functions */ + double quality; /**< quality parameter for density functions */ + int decomp; /**< test decomposition functions */ + int cofest; /**< test cofactor estimation */ + double clip; /**< test clipping functions */ + int dontcares; /**< test equivalence and containment with DCs */ + int closestCube; /**< test Cudd_bddClosestCube */ + int clauses; /**< test extraction of two-literal clauses */ + int noBuild; /**< do not build BDDs; just echo order */ + int stateOnly; /**< ignore primary outputs */ + char *node; /**< only node for which to build %BDD */ + int locGlob; /**< build global or local BDDs */ + int progress; /**< report output names while building BDDs */ + int cacheSize; /**< computed table initial size */ + size_t maxMemory; /**< target maximum memory */ + size_t maxMemHard; /**< maximum allowed memory */ + unsigned int maxLive; /**< maximum number of nodes */ + int slots; /**< unique subtable initial slots */ + int ordering; /**< FANIN DFS ... */ + char *orderPiPs; /**< file for externally provided order */ + Cudd_ReorderingType reordering; /**< NONE RANDOM PIVOT SIFTING ... */ + int autoDyn; /**< ON OFF */ + Cudd_ReorderingType autoMethod; /**< RANDOM PIVOT SIFTING CONVERGE ... */ + char *treefile; /**< file name for variable tree */ + int firstReorder; /**< when to do first reordering */ + int countDead; /**< count dead nodes toward triggering + reordering */ + int maxGrowth; /**< maximum growth during reordering (%) */ + Cudd_AggregationType groupcheck; /**< grouping function */ + int arcviolation; /**< percent violation of arcs in + extended symmetry check */ + int symmviolation; /**< percent symm violation in + extended symmetry check */ + int recomb; /**< recombination parameter for grouping */ + int nodrop; /**< don't drop intermediate BDDs ASAP */ + int signatures; /**< computation of signatures */ + int gaOnOff; /**< whether to run GA at the end */ + int populationSize; /**< population size for GA */ + int numberXovers; /**< number of crossovers for GA */ + int bdddump; /**< ON OFF */ + int dumpFmt; /**< 0 -> dot 1 -> blif 2 ->daVinci 3 -> DDcal + ** 4 -> factored form */ + char *dumpfile; /**< filename for dump */ + int store; /**< iteration at which to store Reached */ + char *storefile; /**< filename for storing Reached */ + int load; /**< load initial states from file */ + char *loadfile; /**< filename for loading states */ + int verb; /**< level of verbosity */ + int32_t seed; /**< seed for random number generator */ } NtrOptions; -typedef struct NtrHeapSlot { - void *item; - int key; -} NtrHeapSlot; +/** + @brief Type of entry of NtrHeap. +*/ +typedef struct NtrHeapSlot NtrHeapSlot; -typedef struct NtrHeap { - int size; - int nslots; - NtrHeapSlot *slots; -} NtrHeap; +/** + @brief Type of heap-based priority queue. +*/ +typedef struct NtrHeap NtrHeap; +/** + @brief Data structure for partitioned transition relation. +*/ typedef struct NtrPartTR { - int nparts; /* number of parts */ - DdNode **part; /* array of parts */ - DdNode **icube; /* quantification cubes for image */ - DdNode **pcube; /* quantification cubes for preimage */ - DdNode **nscube; /* next state variables in each part */ - DdNode *preiabs; /* present state vars and inputs in no part */ - DdNode *prepabs; /* inputs in no part */ - DdNode *xw; /* cube of all present states and PIs */ - NtrHeap *factors; /* factors extracted from the image */ - int nlatches; /* number of latches */ - DdNode **x; /* array of present state variables */ - DdNode **y; /* array of next state variables */ + int nparts; /**< number of parts */ + DdNode **part; /**< array of parts */ + DdNode **icube; /**< quantification cubes for image */ + DdNode **pcube; /**< quantification cubes for preimage */ + DdNode **nscube; /**< next state variables in each part */ + DdNode *preiabs; /**< present state vars and inputs in no part */ + DdNode *prepabs; /**< inputs in no part */ + DdNode *xw; /**< cube of all present states and PIs */ + NtrHeap *factors; /**< factors extracted from the image */ + int nlatches; /**< number of latches */ + DdNode **x; /**< array of present state variables */ + DdNode **y; /**< array of next state variables */ } NtrPartTR; /*---------------------------------------------------------------------------*/ @@ -220,21 +221,16 @@ typedef struct NtrPartTR { # define FALSE 0 #endif -/**Macro*********************************************************************** +/** + @brief Returns 1 if the two arguments are identical strings. - Synopsis [Returns 1 if the two arguments are identical strings.] + @sideeffect none - Description [] - - SideEffects [none] - - SeeAlso [] - -******************************************************************************/ +*/ #define STRING_EQUAL(s1,s2) (strcmp((s1),(s2)) == 0) -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Function prototypes */ @@ -271,10 +267,12 @@ extern int Ntr_HeapInsert (NtrHeap *heap, void *item, int key); extern int Ntr_HeapExtractMin (NtrHeap *heap, void *item, int *key); extern int Ntr_HeapCount (NtrHeap *heap); extern NtrHeap * Ntr_HeapClone (NtrHeap *source); +extern void Ntr_HeapForeach (NtrHeap *heap, void (*f)(void *e, void *arg), void *arg); extern int Ntr_TestHeap (NtrHeap *heap, int i); extern int Ntr_ShortestPaths (DdManager *dd, BnetNetwork *net, NtrOptions *option); -/**AutomaticEnd***************************************************************/ +/** \endcond */ + #ifdef __cplusplus } diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrBddTest.c b/resources/3rdparty/cudd-3.0.0/nanotrav/ntrBddTest.c similarity index 84% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrBddTest.c rename to resources/3rdparty/cudd-3.0.0/nanotrav/ntrBddTest.c index a5e1ae190..69c239d87 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrBddTest.c +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/ntrBddTest.c @@ -1,18 +1,14 @@ -/**CFile*********************************************************************** +/** + @file - FileName [ntrBddTest.c] + @ingroup nanotrav - PackageName [ntr] + @brief %BDD test functions for the nanotrav program. - Synopsis [BDD test functions for the nanotrav program.] + @author Fabio Somenzi - Description [] - - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "ntr.h" #include "cuddInt.h" @@ -65,15 +62,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] UTIL_UNUSED = "$Id: ntrBddTest.c,v 1.22 2012/02/05 01:53:01 fabio Exp fabio $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -93,31 +87,31 @@ static DdNode * ntrCompress1 (DdManager *dd, DdNode *f, int nvars, int threshold static DdNode * ntrCompress2 (DdManager *dd, DdNode *f, int nvars, int threshold); static BnetNode * ntrNodeIsBuffer (BnetNode *nd, st_table *hash); -/**AutomaticEnd***************************************************************/ +/** \endcond */ + /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Tests %BDD minimization functions. - Synopsis [Tests BDD minimization functions.] - - Description [Tests BDD minimization functions, including + @details Tests %BDD minimization functions, including leaf-identifying compaction, squeezing, and restrict. This function uses as constraint the first output of net2 and computes positive and negative cofactors of all the outputs of net1. For each cofactor, it checks whether compaction was safe (cofactor not larger than original function) and that the expansion based on each minimization function (used as a generalized cofactor) equals the - original function. Returns 1 if successful; 0 otherwise.] + original function. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Ntr_TestMinimization( DdManager * dd, @@ -139,7 +133,7 @@ Ntr_TestMinimization( /* Use largest output of second network as constraint. */ csize = -1; for (i = 0; i < net2->noutputs; i++) { - if (!st_lookup(net2->hash,net2->outputs[i],&node)) { + if (!st_lookup(net2->hash,net2->outputs[i],(void **)&node)) { return(0); } nsize = Cudd_DagSize(node->dd); @@ -155,7 +149,7 @@ Ntr_TestMinimization( if (option->node == NULL) { for (i = 0; i < net1->noutputs; i++) { - if (!st_lookup(net1->hash,net1->outputs[i],&node)) { + if (!st_lookup(net1->hash,net1->outputs[i],(void **)&node)) { return(0); } f = node->dd; @@ -165,7 +159,7 @@ Ntr_TestMinimization( if (result == 0) return(0); } } else { - if (!st_lookup(net1->hash,option->node,&node)) { + if (!st_lookup(net1->hash,option->node,(void **)&node)) { return(0); } f = node->dd; @@ -179,18 +173,14 @@ Ntr_TestMinimization( } /* end of Ntr_TestMinimization */ -/**Function******************************************************************** - - Synopsis [Tests BDD density-related functions.] +/** + @brief Tests %BDD density-related functions. - Description [Tests BDD density-related functions. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int Ntr_TestDensity( DdManager * dd, @@ -207,7 +197,7 @@ Ntr_TestDensity( (void) printf("Testing BDD density-related algorithms\n"); if (option->node == NULL) { for (i = 0; i < net1->noutputs; i++) { - if (!st_lookup(net1->hash,net1->outputs[i],&node)) { + if (!st_lookup(net1->hash,net1->outputs[i],(void **)&node)) { return(0); } f = node->dd; @@ -216,7 +206,7 @@ Ntr_TestDensity( if (result == 0) return(0); } } else { - if (!st_lookup(net1->hash,option->node,&node)) { + if (!st_lookup(net1->hash,option->node,(void **)&node)) { return(0); } f = node->dd; @@ -230,18 +220,14 @@ Ntr_TestDensity( } /* end of Ntr_TestDensity */ -/**Function******************************************************************** - - Synopsis [Tests BDD decomposition functions.] +/** + @brief Tests %BDD decomposition functions. - Description [Tests BDD decomposition functions. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int Ntr_TestDecomp( DdManager * dd, @@ -258,7 +244,7 @@ Ntr_TestDecomp( (void) printf("Testing BDD decomposition algorithms\n"); if (option->node == NULL) { for (i = 0; i < net1->noutputs; i++) { - if (!st_lookup(net1->hash,net1->outputs[i],&node)) { + if (!st_lookup(net1->hash,net1->outputs[i],(void **)&node)) { return(0); } f = node->dd; @@ -267,7 +253,7 @@ Ntr_TestDecomp( if (result == 0) return(0); } } else { - if (!st_lookup(net1->hash,option->node,&node)) { + if (!st_lookup(net1->hash,option->node,(void **)&node)) { return(0); } f = node->dd; @@ -281,23 +267,20 @@ Ntr_TestDecomp( } /* end of ntrTestDecomp */ -/**Function******************************************************************** +/** + @brief Verify equivalence of combinational networks. - Synopsis [Verify equivalence of combinational networks.] + @details The two networks are supposed to have the same names for + inputs and outputs. The only exception is that the second network + may miss output buffers that are present in the first network. This + function tries to match both the output and the input of the buffer. - Description [Verify equivalence of combinational networks. - Returns 1 if successful and if the networks are equivalent; -1 if + @return 1 if successful and if the networks are equivalent; -1 if successful, but the networks are not equivalent; 0 otherwise. - The two networks are supposed to have the same names for inputs and - outputs. The only exception is that the second network may miss - output buffers that are present in the first network. This function tries - to match both the output and the input of the buffer.] - - SideEffects [None] - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Ntr_VerifyEquivalence( DdManager * dd, @@ -328,16 +311,16 @@ Ntr_VerifyEquivalence( pr = option->verb; for (i = 0; i < net1->noutputs; i++) { oname = net1->outputs[i]; - if (!st_lookup(net1->hash,oname,&node)) { + if (!st_lookup(net1->hash,oname,(void **)&node)) { return(0); } odd1 = node->dd; (void) printf("%s", oname); Cudd_PrintDebug(dd, node->dd, Cudd_ReadSize(dd), pr); - if (!st_lookup(net2->hash,oname,&node)) { + if (!st_lookup(net2->hash,oname,(void **)&node)) { BnetNode *inpnd; if ((inpnd = ntrNodeIsBuffer(node,net1->hash)) == NULL || - !st_lookup(net2->hash,inpnd->name,&node)) { + !st_lookup(net2->hash,inpnd->name,(void **)&node)) { (void) printf("Output %s missing from network %s\n", oname, net2->name); return(-1); @@ -357,18 +340,14 @@ Ntr_VerifyEquivalence( } /* end of Ntr_VerifyEquivalence */ -/**Function******************************************************************** - - Synopsis [Tests BDD cofactor estimate functions.] - - Description [Tests BDD cofactor estimate functions. - Returns 1 if successful; 0 otherwise.] +/** + @brief Tests %BDD cofactor estimate functions. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Ntr_TestCofactorEstimate( DdManager * dd, @@ -385,7 +364,7 @@ Ntr_TestCofactorEstimate( (void) printf("Testing BDD cofactor estimation algorithms\n"); if (option->node == NULL) { for (i = 0; i < net->noutputs; i++) { - if (!st_lookup(net->hash,net->outputs[i],&node)) { + if (!st_lookup(net->hash,net->outputs[i],(void **)&node)) { return(0); } f = node->dd; @@ -394,7 +373,7 @@ Ntr_TestCofactorEstimate( if (result == 0) return(0); } } else { - if (!st_lookup(net->hash,option->node,&node)) { + if (!st_lookup(net->hash,option->node,(void **)&node)) { return(0); } f = node->dd; @@ -408,18 +387,14 @@ Ntr_TestCofactorEstimate( } /* end of Ntr_TestCofactorEstimate */ -/**Function******************************************************************** +/** + @brief Tests %BDD clipping functions. - Synopsis [Tests BDD clipping functions.] + @return 1 if successful; 0 otherwise. - Description [Tests BDD clipping functions. - Returns 1 if successful; 0 otherwise.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ int Ntr_TestClipping( DdManager * dd, @@ -441,7 +416,7 @@ Ntr_TestClipping( /* Use largest output of second network as second operand. */ gsize = -1; for (i = 0; i < net2->noutputs; i++) { - if (!st_lookup(net2->hash,net2->outputs[i],&node)) { + if (!st_lookup(net2->hash,net2->outputs[i],(void **)&node)) { return(0); } nsize = Cudd_DagSize(node->dd); @@ -457,7 +432,7 @@ Ntr_TestClipping( if (option->node == NULL) { for (i = 0; i < net1->noutputs; i++) { - if (!st_lookup(net1->hash,net1->outputs[i],&node)) { + if (!st_lookup(net1->hash,net1->outputs[i],(void **)&node)) { return(0); } f = node->dd; @@ -466,7 +441,7 @@ Ntr_TestClipping( if (result == 0) return(0); } } else { - if (!st_lookup(net1->hash,option->node,&node)) { + if (!st_lookup(net1->hash,option->node,(void **)&node)) { return(0); } f = node->dd; @@ -480,21 +455,19 @@ Ntr_TestClipping( } /* end of Ntr_TestClipping */ -/**Function******************************************************************** +/** + @brief Tests %BDD equivalence and containment with don't cares. - Synopsis [Tests BDD equivalence and containment with don't cares.] - - Description [Tests functions for BDD equivalence and containment + @details Tests functions for %BDD equivalence and containment with don't cares, including Cudd_EquivDC and Cudd_bddLeqUnless. This function uses as care set the first output of net2 and checkes equivalence and containment for of all the output pairs of net1. - Returns 1 if successful; 0 otherwise.] - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Ntr_TestEquivAndContain( DdManager *dd, @@ -516,7 +489,7 @@ Ntr_TestEquivAndContain( /* Use largest output of second network as constraint. */ dsize = -1; for (i = 0; i < net2->noutputs; i++) { - if (!st_lookup(net2->hash,net2->outputs[i],&node1)) { + if (!st_lookup(net2->hash,net2->outputs[i],(void **)&node1)) { return(0); } nsize = Cudd_DagSize(node1->dd); @@ -532,13 +505,13 @@ Ntr_TestEquivAndContain( if (option->node == NULL) { for (i = 0; i < net1->noutputs; i++) { - if (!st_lookup(net1->hash,net1->outputs[i],&node1)) { + if (!st_lookup(net1->hash,net1->outputs[i],(void **)&node1)) { return(0); } f = node1->dd; if (f == NULL) return(0); for (j = 0; j < net1->noutputs; j++) { - if (!st_lookup(net1->hash,net1->outputs[j],&node2)) { + if (!st_lookup(net1->hash,net1->outputs[j],(void **)&node2)) { return(0); } g = node2->dd; @@ -549,13 +522,13 @@ Ntr_TestEquivAndContain( } } } else { - if (!st_lookup(net1->hash,option->node,&node1)) { + if (!st_lookup(net1->hash,option->node,(void **)&node1)) { return(0); } f = node1->dd; if (f == NULL) return(0); for (j = 0; j < net1->noutputs; j++) { - if (!st_lookup(net1->hash,net1->outputs[j],&node2)) { + if (!st_lookup(net1->hash,net1->outputs[j],(void **)&node2)) { return(0); } g = node2->dd; @@ -571,18 +544,14 @@ Ntr_TestEquivAndContain( } /* end of Ntr_TestEquivAndContain */ -/**Function******************************************************************** - - Synopsis [Tests the Cudd_bddClosestCube function.] +/** + @brief Tests the Cudd_bddClosestCube function. - Description [Tests the Cudd_bddClosestCube function. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int Ntr_TestClosestCube( DdManager * dd, @@ -608,7 +577,7 @@ Ntr_TestClosestCube( calls = Cudd_ReadRecursiveCalls(dd); if (option->node == NULL) { for (i = 0; i < net->noutputs; i++) { - if (!st_lookup(net->hash,net->outputs[i],&node1)) { + if (!st_lookup(net->hash,net->outputs[i],(void **)&node1)) { FREE(vars); return(0); } @@ -618,7 +587,7 @@ Ntr_TestClosestCube( return(0); } for (j = 0; j < net->noutputs; j++) { - if (!st_lookup(net->hash,net->outputs[j],&node2)) { + if (!st_lookup(net->hash,net->outputs[j],(void **)&node2)) { FREE(vars); return(0); } @@ -636,7 +605,7 @@ Ntr_TestClosestCube( } } } else { - if (!st_lookup(net->hash,option->node,&node1)) { + if (!st_lookup(net->hash,option->node,(void **)&node1)) { FREE(vars); return(0); } @@ -646,7 +615,7 @@ Ntr_TestClosestCube( return(0); } for (j = 0; j < net->noutputs; j++) { - if (!st_lookup(net->hash,net->outputs[j],&node2)) { + if (!st_lookup(net->hash,net->outputs[j],(void **)&node2)) { FREE(vars); return(0); } @@ -671,18 +640,14 @@ Ntr_TestClosestCube( } /* end of Ntr_TestClosestCube */ -/**Function******************************************************************** - - Synopsis [Tests extraction of two-literal clauses.] - - Description [Tests extraction of two-literal clauses. - Returns 1 if successful; 0 otherwise.] +/** + @brief Tests extraction of two-literal clauses. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Ntr_TestTwoLiteralClauses( DdManager * dd, @@ -706,14 +671,14 @@ Ntr_TestTwoLiteralClauses( /* Find the input names. */ for (i = 0; i < net1->ninputs; i++) { - if (!st_lookup(net1->hash,net1->inputs[i],&node)) { + if (!st_lookup(net1->hash,net1->inputs[i],(void **)&node)) { FREE(inames); return(0); } inames[node->var] = net1->inputs[i]; } for (i = 0; i < net1->nlatches; i++) { - if (!st_lookup(net1->hash,net1->latches[i][1],&node)) { + if (!st_lookup(net1->hash,net1->latches[i][1],(void **)&node)) { FREE(inames); return(0); } @@ -723,7 +688,7 @@ Ntr_TestTwoLiteralClauses( (void) printf("Testing extraction of two literal clauses\n"); if (option->node == NULL) { for (i = 0; i < net1->noutputs; i++) { - if (!st_lookup(net1->hash,net1->outputs[i],&node)) { + if (!st_lookup(net1->hash,net1->outputs[i],(void **)&node)) { return(0); } f = node->dd; @@ -739,7 +704,7 @@ Ntr_TestTwoLiteralClauses( } } } else { - if (!st_lookup(net1->hash,option->node,&node)) { + if (!st_lookup(net1->hash,option->node,(void **)&node)) { return(0); } f = node->dd; @@ -761,18 +726,14 @@ Ntr_TestTwoLiteralClauses( } /* end of Ntr_TestTwoLiteralClauses */ -/**Function******************************************************************** - - Synopsis [Test char-to-vect conversion.] - - Description [Test char-to-vect conversion. Returns 1 if successful; - 0 otherwise.] +/** + @brief Test char-to-vect conversion. - SideEffects [None] + @return 1 if successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Ntr_TestCharToVect( DdManager * dd, @@ -795,7 +756,7 @@ Ntr_TestCharToVect( } else if (option->node == NULL) { result = 1; for (i = 0; i < net1->noutputs; i++) { - if (!st_lookup(net1->hash,net1->outputs[i],&node)) { + if (!st_lookup(net1->hash,net1->outputs[i],(void **)&node)) { return(0); } f = node->dd; @@ -805,7 +766,7 @@ Ntr_TestCharToVect( if (result == 0) return(0); } } else { - if (!st_lookup(net1->hash,option->node,&node)) { + if (!st_lookup(net1->hash,option->node,(void **)&node)) { return(0); } f = node->dd; @@ -826,18 +787,16 @@ Ntr_TestCharToVect( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Processes one %BDD for Ntr_TestMinimization. - Synopsis [Processes one BDD for Ntr_TestMinimization.] + @return 1 if successful; 0 otherwise. - Description [Processes one BDD for Ntr_TestMinimization. - Returns 1 if successful; 0 otherwise.] + @sideeffect None - SideEffects [None] + @see Ntr_TestMinimization - SeeAlso [Ntr_TestMinimization] - -******************************************************************************/ +*/ static int ntrTestMinimizationAux( DdManager * dd, @@ -1180,18 +1139,16 @@ ntrTestMinimizationAux( } /* end of ntrTestMinimizationAux */ -/**Function******************************************************************** - - Synopsis [Processes one BDD for Ntr_TestDensity.] +/** + @brief Processes one %BDD for Ntr_TestDensity. - Description [Processes one BDD for Ntr_TestDensity. Returns 1 if - successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_TestDensity ntrCompress1] + @see Ntr_TestDensity ntrCompress1 -******************************************************************************/ +*/ static int ntrTestDensityAux( DdManager * dd, @@ -1391,18 +1348,16 @@ ntrTestDensityAux( } /* end of ntrTestDensityAux */ -/**Function******************************************************************** +/** + @brief Processes one %BDD for Ntr_TestDecomp. - Synopsis [Processes one BDD for Ntr_TestDecomp.] + @return 1 if successful; 0 otherwise. - Description [Processes one BDD for Ntr_TestDecomp. Returns 1 if - successful; 0 otherwise.] + @sideeffect None - SideEffects [None] + @see Ntr_TestDecomp - SeeAlso [Ntr_TestDecomp] - -******************************************************************************/ +*/ static int ntrTestDecompAux( DdManager * dd, @@ -1583,18 +1538,14 @@ ntrTestDecompAux( } /* end of ntrTestDecompAux */ -/**Function******************************************************************** - - Synopsis [Processes one BDD for Ntr_TestCofactorEstimate.] +/** + @brief Processes one %BDD for Ntr_TestCofactorEstimate. - Description [Processes one BDD for Ntr_TestCofactorEstimate. Returns 1 if - successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ static int ntrTestCofEstAux( DdManager * dd, @@ -1673,18 +1624,18 @@ ntrTestCofEstAux( } /* end of ntrTestCofEstAux */ -/**Function******************************************************************** +/** + @brief Processes one %BDD for Ntr_TestClipping. - Synopsis [Processes one BDD for Ntr_TestClipping.] + @details It checks whether clipping was correct. - Description [Processes one BDD for Ntr_TestClipping. It checks whether - clipping was correct. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_TestClipping] + @see Ntr_TestClipping -******************************************************************************/ +*/ static int ntrTestClippingAux( DdManager * dd, @@ -1844,18 +1795,16 @@ ntrTestClippingAux( -/**Function******************************************************************** - - Synopsis [Processes one triplet of BDDs for Ntr_TestEquivAndContain.] +/** + @brief Processes one triplet of BDDs for Ntr_TestEquivAndContain. - Description [Processes one triplet of BDDs for Ntr_TestEquivAndContain. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_TestEquivAndContain] + @see Ntr_TestEquivAndContain -******************************************************************************/ +*/ static int ntrTestEquivAndContainAux( DdManager *dd, @@ -2000,18 +1949,16 @@ ntrTestEquivAndContainAux( } /* end of ntrTestEquivAndContainAux */ -/**Function******************************************************************** +/** + @brief Processes one pair of BDDs for Ntr_TestClosestCube. - Synopsis [Processes one pair of BDDs for Ntr_TestClosestCube.] + @return 1 if successful; 0 otherwise. - Description [Processes one pair of BDDs for Ntr_TestClosestCube. - Returns 1 if successful; 0 otherwise.] + @sideeffect None - SideEffects [None] + @see Ntr_TestClosestCube - SeeAlso [Ntr_TestClosestCube] - -******************************************************************************/ +*/ static int ntrTestClosestCubeAux( DdManager *dd, @@ -2129,18 +2076,16 @@ ntrTestClosestCubeAux( } /* end of ntrTestClosestCubeAux */ -/**Function******************************************************************** - - Synopsis [Processes one BDDs for Ntr_TestCharToVect.] +/** + @brief Processes one BDDs for Ntr_TestCharToVect. - Description [Processes one BDD for Ntr_TestCharToVect. - Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_TestCharToVect] + @see Ntr_TestCharToVect -******************************************************************************/ +*/ static int ntrTestCharToVect( DdManager * dd, @@ -2187,18 +2132,16 @@ ntrTestCharToVect( #if 0 -/**Function******************************************************************** +/** + @brief Try hard to squeeze a %BDD. - Synopsis [Try hard to squeeze a BDD.] + @return a pointer to the squeezed %BDD if successful; NULL otherwise. - Description [Try hard to squeeze a BDD. - Returns a pointer to the squeezed BDD if successful; NULL otherwise.] + @sideeffect None - SideEffects [None] + @see ntrTestDensityAux Cudd_SubsetCompress - SeeAlso [ntrTestDensityAux Cudd_SubsetCompress] - -******************************************************************************/ +*/ static DdNode * ntrCompress1( DdManager * dd, @@ -2234,18 +2177,16 @@ ntrCompress1( #endif -/**Function******************************************************************** - - Synopsis [Try hard to squeeze a BDD.] +/** + @brief Try hard to squeeze a %BDD. - Description [Try hard to squeeze a BDD. - Returns a pointer to the squeezed BDD if successful; NULL otherwise.] + @return a pointer to the squeezed %BDD if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [ntrTestDensityAux Cudd_SubsetCompress] + @see ntrTestDensityAux Cudd_SubsetCompress -******************************************************************************/ +*/ static DdNode * ntrCompress2( DdManager * dd, @@ -2288,18 +2229,15 @@ ntrCompress2( } /* end of ntrCompress2 */ -/**Function******************************************************************** - - Synopsis [Checks whether node is a buffer.] - - Description [Checks whether node is a buffer. Returns a pointer to the - input node if nd is a buffer; NULL otherwise.] +/** + @brief Checks whether node is a buffer. - SideEffects [None] + @return a pointer to the input node if nd is a buffer; NULL + otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static BnetNode * ntrNodeIsBuffer( BnetNode *nd, @@ -2308,7 +2246,7 @@ ntrNodeIsBuffer( BnetNode *inpnd; if (nd->ninp != 1) return(0); - if (!st_lookup(hash, nd->inputs[0], &inpnd)) return(0); + if (!st_lookup(hash, nd->inputs[0], (void **) &inpnd)) return(0); return(nd->dd == inpnd->dd ? inpnd : NULL); diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrHeap.c b/resources/3rdparty/cudd-3.0.0/nanotrav/ntrHeap.c similarity index 63% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrHeap.c rename to resources/3rdparty/cudd-3.0.0/nanotrav/ntrHeap.c index 801b3f8d6..ebd15a4dc 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrHeap.c +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/ntrHeap.c @@ -1,20 +1,20 @@ -/**CFile*********************************************************************** +/** + @file - FileName [ntrHeap.c] + @ingroup nanotrav - PackageName [ntr] + @brief Functions for heap-based priority queues. - Synopsis [Functions for heap-based priority queue.] + @details The functions in this file manage a priority queue + implemented as a heap. The first element of the heap is the one with + the smallest key. The queue stores generic pointers, but the key + must be an int. Refer to Chapter 7 of Cormen, Leiserson, and Rivest + for the theory. - Description [The functions in this file manage a priority queue implemented - as a heap. The first element of the heap is the one with the smallest key. - Refer to Chapter 7 of Cormen, Leiserson, and Rivest for the theory.] + @author Fabio Somenzi - SeeAlso [] - - Author [Fabio Somenzi] - - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -44,9 +44,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "ntr.h" @@ -59,6 +60,23 @@ /* Stucture declarations */ /*---------------------------------------------------------------------------*/ +/** + @brief Entry of NtrHeap. +*/ +struct NtrHeapSlot { + void *item; + int key; +}; + +/** + @brief Heap-based priority queue. +*/ +struct NtrHeap { + int size; + int nslots; + NtrHeapSlot *slots; +}; + /*---------------------------------------------------------------------------*/ /* Type declarations */ /*---------------------------------------------------------------------------*/ @@ -67,9 +85,6 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] UTIL_UNUSED = "$Id: ntrHeap.c,v 1.6 2012/02/05 01:53:01 fabio Exp fabio $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ @@ -81,7 +96,7 @@ static char rcsid[] UTIL_UNUSED = "$Id: ntrHeap.c,v 1.6 2012/02/05 01:53:01 fabi #define ITEM(p,i) ((p)[i].item) #define KEY(p,i) ((p)[i].key) -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -90,25 +105,24 @@ static char rcsid[] UTIL_UNUSED = "$Id: ntrHeap.c,v 1.6 2012/02/05 01:53:01 fabi static void ntrHeapify (NtrHeap *heap, int i); static int ntrHeapResize (NtrHeap *heap); -/**AutomaticEnd***************************************************************/ +/** \endcond */ + /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Initializes a priority queue.] +/** + @brief Initializes a priority queue. - Description [Initializes a priority queue. Returns a pointer to the heap - if successful; NULL otherwise.] + @return a pointer to the heap if successful; NULL otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_FreeHeap] + @see Ntr_FreeHeap -******************************************************************************/ +*/ NtrHeap * Ntr_InitHeap( int size) @@ -129,17 +143,14 @@ Ntr_InitHeap( } /* end of Ntr_InitHeap */ -/**Function******************************************************************** +/** + @brief Frees a priority queue. - Synopsis [Frees a priority queue.] + @sideeffect None - Description [] + @see Ntr_InitHeap - SideEffects [None] - - SeeAlso [Ntr_InitHeap] - -******************************************************************************/ +*/ void Ntr_FreeHeap( NtrHeap *heap) @@ -151,18 +162,16 @@ Ntr_FreeHeap( } /* end of Ntr_FreeHeap */ -/**Function******************************************************************** - - Synopsis [Inserts an item in a priority queue.] +/** + @brief Inserts an item in a priority queue. - Description [Inserts an item in a priority queue. Returns 1 if successful; - 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_HeapExtractMin] + @see Ntr_HeapExtractMin -******************************************************************************/ +*/ int Ntr_HeapInsert( NtrHeap *heap, @@ -187,20 +196,18 @@ Ntr_HeapInsert( } /* end of Ntr_HeapInsert */ -/**Function******************************************************************** +/** + @brief Extracts the element with the minimum key from a priority + queue. - Synopsis [Extracts the element with the minimum key from a priority - queue.] + @return 1 if successful; 0 otherwise. - Description [Extracts the element with the minimum key from a priority - queue. Returns 1 if successful; 0 otherwise.] + @sideeffect The minimum key and the associated item are returned as + side effects. - SideEffects [The minimum key and the associated item are returned as - side effects.] + @see Ntr_HeapInsert - SeeAlso [Ntr_HeapInsert] - -******************************************************************************/ +*/ int Ntr_HeapExtractMin( NtrHeap *heap, @@ -222,17 +229,12 @@ Ntr_HeapExtractMin( } /* end of Ntr_HeapExtractMin */ -/**Function******************************************************************** - - Synopsis [Returns the number of items in a priority queue.] - - Description [] +/** + @brief Returns the number of items in a priority queue. - SideEffects [None] + @sideeffect None - SeeAlso [] - -******************************************************************************/ +*/ int Ntr_HeapCount( NtrHeap *heap) @@ -242,17 +244,14 @@ Ntr_HeapCount( } /* end of Ntr_HeapCount */ -/**Function******************************************************************** - - Synopsis [Clones a priority queue.] - - Description [] +/** + @brief Clones a priority queue. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_InitHeap] + @see Ntr_InitHeap -******************************************************************************/ +*/ NtrHeap * Ntr_HeapClone( NtrHeap *source) @@ -276,18 +275,32 @@ Ntr_HeapClone( } /* end of Ntr_HeapClone */ -/**Function******************************************************************** +/** + @brief Calls a function on all items in a heap. +*/ +void +Ntr_HeapForeach( + NtrHeap *heap, + void (*f)(void * e, void * arg), + void * arg) +{ + int i; + + for (i = 0; i < heap->nslots; i++) { + f(heap->slots[i].item, arg); + } + +} /* end of Ntr_HeapForeach */ - Synopsis [Tests the heap property of a priority queue.] - Description [Tests the heap property of a priority queue. Returns 1 if - Successful; 0 otherwise.] +/** + @brief Tests the heap property of a priority queue. - SideEffects [None] + @return 1 if Successful; 0 otherwise. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ int Ntr_TestHeap( NtrHeap *heap, @@ -316,17 +329,14 @@ Ntr_TestHeap( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Maintains the heap property of a priority queue.] - - Description [] +/** + @brief Maintains the heap property of a priority queue. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_HeapExtractMin] + @see Ntr_HeapExtractMin -******************************************************************************/ +*/ static void ntrHeapify( NtrHeap *heap, @@ -361,18 +371,19 @@ ntrHeapify( } /* end of ntrHeapify */ -/**Function******************************************************************** +/** + @brief Resizes a priority queue. - Synopsis [Resizes a priority queue.] + @details Resizes a priority queue by doubling the number of + available slots. - Description [Resizes a priority queue by doubling the number of - available slots. Returns 1 if successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [Ntr_HeapInsert] + @see Ntr_HeapInsert -******************************************************************************/ +*/ static int ntrHeapResize( NtrHeap *heap) diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrMflow.c b/resources/3rdparty/cudd-3.0.0/nanotrav/ntrMflow.c similarity index 84% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrMflow.c rename to resources/3rdparty/cudd-3.0.0/nanotrav/ntrMflow.c index a8893c927..803b14835 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrMflow.c +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/ntrMflow.c @@ -1,21 +1,21 @@ -/**CFile*********************************************************************** +/** + @file - FileName [ntrMflow.c] + @ingroup nanotrav - PackageName [ntr] + @brief Symbolic maxflow algorithm. - Synopsis [Symbolic maxflow algorithm.] - - Description [This file contains the functions that implement the + @details This file contains the functions that implement the symbolic version of Dinits's maxflow algorithm described in the ICCAD93 paper. The present implementation differs from the algorithm described in the paper in that more than one matching techniques is used. The technique of the paper is the one applied to - hourglass-type bilayers here.] + hourglass-type bilayers here. - Author [Fabio Somenzi, Gary Hachtel] + @author Fabio Somenzi, Gary Hachtel - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -45,9 +45,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "ntr.h" @@ -70,29 +71,28 @@ /* Type declarations */ /*---------------------------------------------------------------------------*/ +/** + @brief Structure to hold statistics. +*/ typedef struct flowStatsStruct { - int pr; /* level of verbosity */ - long start_time; /* cpu time when the covering started */ - int phases; /* number of phases */ - int layers; /* number of layers */ - int fpit; /* number of fixed point iterations */ + int pr; /**< level of verbosity */ + long start_time; /**< cpu time when the covering started */ + int phases; /**< number of phases */ + int layers; /**< number of layers */ + int fpit; /**< number of fixed point iterations */ } flowStats; /*---------------------------------------------------------------------------*/ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] UTIL_UNUSED = "$Id: ntrMflow.c,v 1.8 2012/02/05 01:53:01 fabio Exp fabio $"; -#endif - static DdNode *xcube, *ycube, *zcube; /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -108,18 +108,19 @@ static void trellisPush (DdManager *bdd, int m, DdNode **U, DdNode **x, DdNode * static void rhombusPush (DdManager *bdd, int m, DdNode **U, DdNode **x, DdNode **y, DdNode **z, int n, DdNode *pryz, DdNode *prxz, flowStats *stats); static void hourglassPush (DdManager *bdd, int m, DdNode **U, DdNode **x, DdNode **y, DdNode **z, int n, DdNode *pryz, DdNode *prxz, flowStats *stats); -/**AutomaticEnd***************************************************************/ +/** \endcond */ + /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [] +/** + @brief Symbolic Dinit's algorithm. - Description [This function implements Dinits's algorithm for (0-1) + @details@parblock + This function implements Dinits's algorithm for (0-1) max flow, using BDDs and a symbolic technique to trace multiple edge-disjoint augmenting paths to complete a phase. The outer forever loop is over phases, and the inner forever loop is to @@ -136,7 +137,7 @@ static void hourglassPush (DdManager *bdd, int m, DdNode **U, DdNode **x, DdNode edge (u,v) in the given digraph. <li> z Another set of variables. <li> E(x,y) The edge relation. - <li> F(x,y) BDD representation of the current flow, initialized to 0 + <li> F(x,y) %BDD representation of the current flow, initialized to 0 for each arc, and updated by +1, -1, or 0 at the end of each phase. <li> Ms Mt The maximum flow, that is, the cardinality of a minimum cut, @@ -146,27 +147,26 @@ static void hourglassPush (DdManager *bdd, int m, DdNode **U, DdNode **x, DdNode <li> fos fanout of the source node s. <li> fit fanin of the sink node t. </ul> - ] - - SideEffects [The flow realtion F and the cutset relation cut are returned - as side effects.] + + @endparblock - SeeAlso [] + @sideeffect The flow realtion F and the cutset relation cut are returned + as side effects. -******************************************************************************/ +*/ double Ntr_maximum01Flow( - DdManager * bdd /* manager */, - DdNode * sx /* source node */, - DdNode * ty /* sink node */, - DdNode * E /* edge relation */, - DdNode ** F /* flow relation */, - DdNode ** cut /* cutset relation */, - DdNode ** x /* array of row variables */, - DdNode ** y /* array of column variables */, - DdNode ** z /* arrays of auxiliary variables */, - int n /* number of variables in each array */, - int pr /* verbosity level */) + DdManager * bdd /**< manager */, + DdNode * sx /**< source node */, + DdNode * ty /**< sink node */, + DdNode * E /**< edge relation */, + DdNode ** F /**< flow relation */, + DdNode ** cut /**< cutset relation */, + DdNode ** x /**< array of row variables */, + DdNode ** y /**< array of column variables */, + DdNode ** z /**< arrays of auxiliary variables */, + int n /**< number of variables in each array */, + int pr /**< verbosity level */) { flowStats stats; DdNode *one, *zero, @@ -412,41 +412,39 @@ endPhases: /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Selects set of edge-disjoint paths from layered network. - Synopsis [Selects set of edge-disjoint paths from layered network.] - - Description [Selects set of edge-disjoint paths from layered - network. maximal_pull is called when the BFS constructing the + @details maximal_pull is called when the BFS constructing the layered graph reaches a sink. At this point the new sets of the BFS have been formed, and we know every vertex in these sets is reachable from the source vertex (or vertices) s. The new sets are used to compute the set of useful edges exiting each layer to the right. In each layer, propagate_maximal_flow is called to select a maximal subset of these useful edges. This subset is then used to - prune new and U.] + prune new and U. - SideEffects [None] + @sideeffect None - SeeAlso [maximal_push] + @see maximal_push -******************************************************************************/ +*/ static void maximal_pull( - DdManager * bdd /* manager */, - int l /* depth of layered network for current phase */, - DdNode * ty /* sink node */, - DdNode ** neW /* array of BFS layers */, - DdNode ** U /* array of useful edges */, - DdNode * E /* edge relation */, - DdNode ** F /* flow relation */, - DdNode ** x, - DdNode ** y, - DdNode ** z /* arrays of variables for rows and columns */, - int n /* number of x variables */, - DdNode * pryz, - DdNode * prxz /* priority functions */, - flowStats * stats) + DdManager * bdd /**< manager */, + int l /**< depth of layered network for current phase */, + DdNode * ty /**< sink node */, + DdNode ** neW /**< array of BFS layers */, + DdNode ** U /**< array of useful edges */, + DdNode * E /**< edge relation */, + DdNode ** F /**< flow relation */, + DdNode ** x /**< array of variables for rows and columns */, + DdNode ** y /**< array of variables for rows and columns */, + DdNode ** z /**< array of variables for rows and columns */, + int n /**< number of x variables */, + DdNode * pryz /**< priority function */, + DdNode * prxz /**< priority function */, + flowStats * stats /**< statistics */) { DdNode *p, *q, *r, *UF, *UB; @@ -517,12 +515,11 @@ maximal_pull( } /* end of maximal_pull */ -/**Function******************************************************************** - - Synopsis [Pulls flow though a layer.] +/** + @brief Pulls flow though a layer. - Description [Pulls flow though a layer. propagate_maximal_flow only - affects U[m-1] and new[m-1]. At the end of this function, the edges + @details propagate_maximal_flow only + affects U[m-1 and new[m-1]. At the end of this function, the edges in U[m] are guaranteed to drain all the flow supplied by the edges in U[m-1]. This effect is obtained by pruning U[m-1]. After the pruned U[m-1] is computed, new[m-1] is updated to keep track of what @@ -537,24 +534,24 @@ maximal_pull( end-point or if they have distinct middle points. What condition to enforce depends on the "shape" of the layers.] - SideEffects [Changes U[m-1] and new[m-1]] + @sideeffect Changes U[m-1 and new[m-1]] - SeeAlso [trellis rhombus hourglass] + @see trellis rhombus hourglass -******************************************************************************/ +*/ static void propagate_maximal_flow( - DdManager * bdd, - int m /* center of current bilayer */, - DdNode ** neW /* array of reachable or useful nodes */, - DdNode ** U /* array of usable or useful edges */, - DdNode ** x, - DdNode ** y, - DdNode ** z /* arrays of variables for rows and columns */, - int n /* number of x variables */, - DdNode * pryz, - DdNode * prxz /* priority functions */, - flowStats * stats) + DdManager * bdd /**< %DD manager */, + int m /**< center of current bilayer */, + DdNode ** neW /**< array of reachable or useful nodes */, + DdNode ** U /**< array of usable or useful edges */, + DdNode ** x /**< array of variables for rows and columns */, + DdNode ** y /**< array of variables for rows and columns */, + DdNode ** z /**< array of variables for rows and columns */, + int n /**< number of x variables */, + DdNode * pryz /**< priority function */, + DdNode * prxz /**< priority function */, + flowStats * stats /**< statistics */) { DdNode *rN; double mtl, mtc, mtr; /* minterms for left, center, right levels */ @@ -590,33 +587,31 @@ propagate_maximal_flow( } /* end of propagate_maximal_flow */ -/**Function******************************************************************** - - Synopsis [Selects edges from a trellis-type bilayer.] +/** + @brief Selects edges from a trellis-type bilayer. - Description [Selects edges from a trellis-type bilayer. Used to pull flow. - First a matching is found in the left layer. Then the paths are extended - (if possible) through the right layer. This process is repeated until a - maximal flow is found.] + @details Used to pull flow. First a matching is found in the left + layer. Then the paths are extended (if possible) through the right + layer. This process is repeated until a maximal flow is found. - SideEffects [None] + @sideeffect None - SeeAlso [rhombus hourglass trellisPush] + @see rhombus hourglass trellisPush -******************************************************************************/ +*/ static void trellis( - DdManager * bdd, - int m /* center level of current bilayer */, - DdNode ** neW /* array of node levels */, - DdNode ** U /* array of edge layers */, - DdNode ** x, - DdNode ** y, - DdNode ** z /* arrays of variables for rows and columns */, - int n /* number of x variables */, - DdNode * pryz, - DdNode * prxz /* priority functions */, - flowStats * stats) + DdManager * bdd /**< %DD manager */, + int m /**< center level of current bilayer */, + DdNode ** neW /**< array of node levels */, + DdNode ** U /**< array of edge layers */, + DdNode ** x /**< array of variables for rows and columns */, + DdNode ** y /**< array of variables for rows and columns */, + DdNode ** z /**< array of variables for rows and columns */, + int n /**< number of x variables */, + DdNode * pryz /**< priority function */, + DdNode * prxz /**< priority function */, + flowStats * stats /**< statistics */) { DdNode *one, *zero, *p, *q, *r, @@ -731,33 +726,32 @@ trellis( } /* end of trellis */ -/**Function******************************************************************** +/** + @brief Selects edges from a rhombus-type bilayer. - Synopsis [Selects edges from a rhombus-type bilayer.] + @details Used to pull flow. Makes the left layer left-unique and + the right layer right-unique. Prunes and repeats until convergence + to a maximal flow. It makes sure that all intermediate points of the + two-arc paths are disjoint at each iteration. - Description [Selects edges from a rhombus-type bilayer. Used to pull flow. - Makes the left layer left-unique and the right layer right-unique. Prunes - and repeats until convergence to a maximal flow. It makes sure that all - intermediate points of the two-arc paths are disjoint at each iteration.] + @sideeffect None - SideEffects [None] + @see trellis hourglass rhombusPush - SeeAlso [trellis hourglass rhombusPush] - -******************************************************************************/ +*/ static void rhombus( - DdManager * bdd, - int m /* center of current bilayer */, - DdNode ** neW, - DdNode ** U /* arrays for flow propagation */, - DdNode ** x, - DdNode ** y, - DdNode ** z /* arrays of variables for rows and columns */, - int n /* number of x variables */, - DdNode * pryz, - DdNode * prxz /* priority functions */, - flowStats * stats) + DdManager * bdd /**< %DD manager */, + int m /**< center of current bilayer */, + DdNode ** neW /**< array for flow propagation */, + DdNode ** U /**< array for flow propagation */, + DdNode ** x /**< array of variables for rows and columns */, + DdNode ** y /**< array of variables for rows and columns */, + DdNode ** z /**< array of variables for rows and columns */, + int n /**< number of x variables */, + DdNode * pryz /**< priority function */, + DdNode * prxz /**< priority function */, + flowStats * stats /**< statistics */) { DdNode *one, *zero, *p, *q, *r, @@ -865,32 +859,30 @@ rhombus( } /* end of rhombus */ -/**Function******************************************************************** - - Synopsis [Selects edges from a hourglass-type bilayer.] +/** + @brief Selects edges from a hourglass-type bilayer. - Description [Selects edges from a hourglass-type bilayer. Used to - pull flow. Method described in paper. More general, but more - expensive than the others.] + @details Used to pull flow. Method described in paper. More + general, but more expensive than the others. - SideEffects [None] + @sideeffect None - SeeAlso [trellis rhombus hourglassPush] + @see trellis rhombus hourglassPush -******************************************************************************/ +*/ static void hourglass( - DdManager * bdd, - int m /* center level of current bilayer */, - DdNode ** neW, - DdNode ** U /* arrays for flow propagation */, - DdNode ** x, - DdNode ** y, - DdNode ** z /* arrays of variables for rows and columns */, - int n /* number of x variables */, - DdNode * pryz, - DdNode * prxz /* priority functions */, - flowStats * stats) + DdManager * bdd /**< %DD manager */, + int m /**< center level of current bilayer */, + DdNode ** neW /**< array for flow propagation */, + DdNode ** U /**< array for flow propagation */, + DdNode ** x /**< array of variables for rows and columns */, + DdNode ** y /**< array of variables for rows and columns */, + DdNode ** z /**< array of variables for rows and columns */, + int n /**< number of x variables */, + DdNode * pryz /**< priority function */, + DdNode * prxz /**< priority function */, + flowStats * stats /**< statistics */) { DdNode *one, *zero, *przy, @@ -1029,31 +1021,28 @@ hourglass( } /* end of hourglass */ -/**Function******************************************************************** +/** + @brief Pushes flow through useful edges. - Synopsis [Pushes flow through useful edges.] + @details Pushes flow from the source(s) to the sink(s) through + useful edges. - Description [Pushes flow from the source(s) to the sink(s) through - useful edges.] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static void maximal_push( - DdManager * bdd, - int l /* Depth of layered network for current phase */, - DdNode ** U /* array of edge sets for flow propagation */, - DdNode ** F /* edge and flow relations */, - DdNode ** x, - DdNode ** y, - DdNode ** z /* arrays of variables for rows and columns */, - int n /* number of x variables */, - DdNode * pryz, - DdNode * prxz /* priority functions */, - flowStats * stats) + DdManager * bdd /**< %DD manager */, + int l /**< Depth of layered network for current phase */, + DdNode ** U /**< array of edge sets for flow propagation */, + DdNode ** F /**< edge and flow relations */, + DdNode ** x /**< array of variables for rows and columns */, + DdNode ** y /**< array of variables for rows and columns */, + DdNode ** z /**< array of variables for rows and columns */, + int n /**< number of x variables */, + DdNode * pryz /**< priority function */, + DdNode * prxz /**< priority function */, + flowStats * stats /**< statistics */) { DdNode *p, *q, *r, *UT, @@ -1176,29 +1165,24 @@ maximal_push( } /* end of maximal_push */ -/**Function******************************************************************** - - Synopsis [] +/** + @brief Pushes flow through a trellis. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static void trellisPush( - DdManager * bdd, - int m /* Current layer */, - DdNode ** U /* Array of edge sets for flow propagation */, - DdNode ** x, - DdNode ** y, - DdNode ** z /* Arrays of variables for rows and columns */, - int n /* Number of x variables */, - DdNode * pryz, - DdNode * prxz /* Priority functions */, - flowStats * stats) + DdManager * bdd /**< %DD manager */, + int m /**< Current layer */, + DdNode ** U /**< Array of edge sets for flow propagation */, + DdNode ** x /**< Array of variables for rows and columns */, + DdNode ** y /**< Array of variables for rows and columns */, + DdNode ** z /**< Array of variables for rows and columns */, + int n /**< Number of x variables */, + DdNode * pryz /**< Priority function */, + DdNode * prxz /**< Priority function */, + flowStats * stats /**< statistics */) { DdNode *one, *zero, *p, *r, @@ -1295,29 +1279,24 @@ trellisPush( } /* end of trellisPush */ -/**Function******************************************************************** - - Synopsis [] +/** + @brief Pushes flow through a rhombus. - Description [] + @sideeffect None - SideEffects [None] - - SeeAlso [] - -******************************************************************************/ +*/ static void rhombusPush( - DdManager * bdd, - int m /* Current layer */, - DdNode ** U /* Array of edge sets for flow propagation */, - DdNode ** x, - DdNode ** y, - DdNode ** z /* Arrays of variables for rows and columns */, - int n /* Number of x variables */, - DdNode * pryz, - DdNode * prxz /* Priority functions */, - flowStats * stats) + DdManager * bdd /**< %DD manager */, + int m /**< Current layer */, + DdNode ** U /**< Array of edge sets for flow propagation */, + DdNode ** x /**< Array of variables for rows and columns */, + DdNode ** y /**< Array of variables for rows and columns */, + DdNode ** z /**< Array of variables for rows and columns */, + int n /**< Number of x variables */, + DdNode * pryz /**< Priority function */, + DdNode * prxz /**< Priority function */, + flowStats * stats /**< statistics */) { DdNode *one, *zero, *p, *r, @@ -1416,29 +1395,24 @@ rhombusPush( } /* end of rhombusPush */ -/**Function******************************************************************** - - Synopsis [] - - Description [] - - SideEffects [None] +/** + @brief Pushes flow through an hourglass. - SeeAlso [] + @sideeffect None -******************************************************************************/ +*/ static void hourglassPush( - DdManager * bdd, - int m /* Current layer */, - DdNode ** U /* Array of edge sets for flow propagation */, - DdNode ** x, - DdNode ** y, - DdNode ** z /* Arrays of variables for rows and columns */, - int n /* Number of x variables */, - DdNode * pryz, - DdNode * prxz /* Priority functions */, - flowStats * stats) + DdManager * bdd /**< %DD manager */, + int m /**< Current layer */, + DdNode ** U /**< Array of edge sets for flow propagation */, + DdNode ** x /**< Array of variables for rows and columns */, + DdNode ** y /**< Array of variables for rows and columns */, + DdNode ** z /**< Array of variables for rows and columns */, + int n /**< Number of x variables */, + DdNode * pryz /**< Priority function */, + DdNode * prxz /**< Priority function */, + flowStats * stats /**< statistics */) { DdNode *one, *zero, *przy, diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrShort.c b/resources/3rdparty/cudd-3.0.0/nanotrav/ntrShort.c similarity index 85% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrShort.c rename to resources/3rdparty/cudd-3.0.0/nanotrav/ntrShort.c index 61ed980d3..9efe59708 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrShort.c +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/ntrShort.c @@ -1,18 +1,18 @@ -/**CFile*********************************************************************** +/** + @file - FileName [ntrShort.c] + @ingroup nanotrav - PackageName [ntr] + @brief Symbolic shortest paths algorithms. - Synopsis [Symbolic shortest paths algorithms.] - - Description [This file contains the functions that implement the + @details This file contains the functions that implement the symbolic version of several shortest path algorithms described in the - JFM paper on ADDs.] + JFM paper on ADDs. - Author [Fabio Somenzi, Iris Bahar] + @author Fabio Somenzi, Iris Bahar - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,9 +42,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "ntr.h" #include "cuddInt.h" @@ -65,15 +66,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] UTIL_UNUSED = "$Id: ntrShort.c,v 1.5 2012/02/05 01:53:01 fabio Exp fabio $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -83,17 +81,17 @@ static DdNode * ntrBellman (DdManager *dd, DdNode *D, DdNode *source, DdNode **x static DdNode * ntrWarshall (DdManager *dd, DdNode *D, DdNode **x, DdNode **y, int vars, int pr); static DdNode * ntrSquare (DdManager *dd, DdNode *D, DdNode **x, DdNode **y, DdNode **z, int vars, int pr, int st); -/**AutomaticEnd***************************************************************/ +/** \endcond */ + /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** - - Synopsis [Computes shortest paths in a state graph.] +/** + @brief Computes shortest paths in a state graph. - Description [Computes shortest paths in the state transition graph of + @details Computes shortest paths in the state transition graph of a network. Three methods are availabe: <ul> <li> Bellman-Ford algorithm for single-source shortest paths; the @@ -102,14 +100,12 @@ static DdNode * ntrSquare (DdManager *dd, DdNode *D, DdNode **x, DdNode **y, DdN <li> Floyd-Warshall algorithm for all-pair shortest paths. <li> Repeated squaring algorithm for all-pair shortest paths. </ul> - The function returns 1 in case of success; 0 otherwise. - ] - SideEffects [ADD variables are created in the manager.] + @return 1 in case of success; 0 otherwise. - SeeAlso [] + @sideeffect %ADD variables are created in the manager. -******************************************************************************/ +*/ int Ntr_ShortestPaths( DdManager * dd, @@ -243,29 +239,27 @@ Ntr_ShortestPaths( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Bellman-Ford algorithm for single-source shortest paths. - Synopsis [Bellman-Ford algorithm for single-source shortest paths.] + @return the vector of the distances of all states from the initial + states. - Description [Bellman-Ford algorithm for single-source shortest - paths. Returns the vector of the distances of all states from the - initial states. In case of multiple initial states the distance for + @details In case of multiple initial states the distance for each state is from the nearest initial state. Negative-weight cycles are detected, though only in the naive way. (Lack of convergence after nodes-1 iterations.) In such a case, a constant - ADD with value minus infinity is returned. Bellman-Ford is based on + %ADD with value minus infinity is returned. Bellman-Ford is based on matrix-vector multiplication. The matrix is the distance matrix D(x,y), such that D(a,b) is the length of the arc connecting state a to state b. The vector V(x) stores the distances of all states from the initial states. The actual vector used in the matrix-vector multiplication is diff(x), that holds those distances that have - changed during the last update.] + changed during the last update. - SideEffects [] + @see ntrWarshall ntrSquare - SeeAlso [ntrWarshall ntrSquare] - -******************************************************************************/ +*/ static DdNode * ntrBellman( DdManager *dd, @@ -362,17 +356,9 @@ ntrBellman( } /* end of ntrBellman */ -/**Function******************************************************************** - - Synopsis [Floyd-Warshall algorithm for all-pair shortest paths.] - - Description [] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Floyd-Warshall algorithm for all-pair shortest paths. +*/ static DdNode * ntrWarshall( DdManager *dd, @@ -455,27 +441,19 @@ ntrWarshall( } /* end of ntrWarshall */ -/**Function******************************************************************** - - Synopsis [Repeated squaring algorithm for all-pairs shortest paths.] - - Description [] - - SideEffects [] - - SeeAlso [] - -******************************************************************************/ +/** + @brief Repeated squaring algorithm for all-pairs shortest paths. +*/ static DdNode * ntrSquare( - DdManager *dd /* manager */, - DdNode *D /* D(z,y): distance matrix */, - DdNode **x /* array of x variables */, - DdNode **y /* array of y variables */, - DdNode **z /* array of z variables */, - int vars /* number of variables in each of the three arrays */, - int pr /* verbosity level */, - int st /* use the selective trace algorithm */) + DdManager *dd /**< manager */, + DdNode *D /**< D(z,y): distance matrix */, + DdNode **x /**< array of x variables */, + DdNode **y /**< array of y variables */, + DdNode **z /**< array of z variables */, + int vars /**< number of variables in each of the three arrays */, + int pr /**< verbosity level */, + int st /**< use the selective trace algorithm */) { DdNode *zero; DdNode *I; /* identity matirix */ diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrZddTest.c b/resources/3rdparty/cudd-3.0.0/nanotrav/ntrZddTest.c similarity index 84% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrZddTest.c rename to resources/3rdparty/cudd-3.0.0/nanotrav/ntrZddTest.c index d1a8d83d3..f837d7040 100644 --- a/resources/3rdparty/cudd-2.5.0/src/nanotrav/ntrZddTest.c +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/ntrZddTest.c @@ -1,18 +1,14 @@ -/**CFile*********************************************************************** - - FileName [ntrZddTest.c] +/** + @file - PackageName [ntr] + @ingroup nanotrav - Synopsis [ZDD test functions.] + @brief %ZDD test functions. - Description [] - - SeeAlso [] - - Author [Fabio Somenzi] + @author Fabio Somenzi - Copyright [Copyright (c) 1995-2012, Regents of the University of Colorado + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado All rights reserved. @@ -42,9 +38,10 @@ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE.] + POSSIBILITY OF SUCH DAMAGE. + @endparblock -******************************************************************************/ +*/ #include "ntr.h" #include "cuddInt.h" @@ -65,15 +62,12 @@ /* Variable declarations */ /*---------------------------------------------------------------------------*/ -#ifndef lint -static char rcsid[] UTIL_UNUSED = "$Id: ntrZddTest.c,v 1.15 2012/02/05 01:53:01 fabio Exp fabio $"; -#endif /*---------------------------------------------------------------------------*/ /* Macro declarations */ /*---------------------------------------------------------------------------*/ -/**AutomaticStart*************************************************************/ +/** \cond */ /*---------------------------------------------------------------------------*/ /* Static function prototypes */ @@ -81,24 +75,22 @@ static char rcsid[] UTIL_UNUSED = "$Id: ntrZddTest.c,v 1.15 2012/02/05 01:53:01 static int reorderZdd (BnetNetwork *net, DdManager *dd, NtrOptions *option); -/**AutomaticEnd***************************************************************/ +/** \endcond */ + /*---------------------------------------------------------------------------*/ /* Definition of exported functions */ /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Tests ZDDs. - Synopsis [Tests ZDDs.] + @return 1 if successful; 0 otherwise. - Description [Tests ZDDs. Returns 1 if successful; 0 otherwise.] + @sideeffect Creates %ZDD variables in the manager. - SideEffects [Creates ZDD variables in the manager.] - - SeeAlso [] - -******************************************************************************/ +*/ int Ntr_testZDD( DdManager * dd, @@ -124,7 +116,7 @@ Ntr_testZDD( if (result == 0) return(0); if (option->node == NULL) { for (nz = 0; nz < net->noutputs; nz++) { - if (!st_lookup(net->hash,net->outputs[nz],&node)) { + if (!st_lookup(net->hash,net->outputs[nz],(void **)&node)) { return(0); } zdd[nz] = Cudd_zddPortFromBdd(dd, node->dd); @@ -138,7 +130,7 @@ Ntr_testZDD( } } } else { - if (!st_lookup(net->hash,option->node,&node)) { + if (!st_lookup(net->hash,option->node,(void **)&node)) { return(0); } zdd[0] = Cudd_zddPortFromBdd(dd, node->dd); @@ -175,11 +167,11 @@ Ntr_testZDD( if (checkBdd) { Cudd_Ref(checkBdd); if (option->node == NULL) { - if (!st_lookup(net->hash,net->outputs[i],&node)) { + if (!st_lookup(net->hash,net->outputs[i],(void **)&node)) { return(0); } } else { - if (!st_lookup(net->hash,option->node,&node)) { + if (!st_lookup(net->hash,option->node,(void **)&node)) { return(0); } } @@ -250,7 +242,10 @@ Ntr_testZDD( /* Perform ZDD reordering. */ result = reorderZdd(net,dd,option); - if (result == 0) return(0); + if (result == 0) { + (void) fprintf(stderr,"Error during ZDD reordering\n"); + return(0); + } /* Print final ZDD order. */ nvars = Cudd_ReadZddSize(dd); @@ -261,7 +256,7 @@ Ntr_testZDD( } if (option->reordering != CUDD_REORDER_NONE) { for (i = 0; i < net->npis; i++) { - if (!st_lookup(net->hash,net->inputs[i],&node)) { + if (!st_lookup(net->hash,net->inputs[i],(void **)&node)) { FREE(names); return(0); } @@ -269,7 +264,7 @@ Ntr_testZDD( names[level] = node->name; } for (i = 0; i < net->nlatches; i++) { - if (!st_lookup(net->hash,net->latches[i][1],&node)) { + if (!st_lookup(net->hash,net->latches[i][1],(void **)&node)) { FREE(names); return(0); } @@ -297,17 +292,12 @@ Ntr_testZDD( } /* end of Ntr_testZDD */ -/**Function******************************************************************** - - Synopsis [Builds ZDD covers.] - - Description [] - - SideEffects [Creates ZDD variables in the manager.] +/** + @brief Builds %ZDD covers. - SeeAlso [] + @sideeffect Creates %ZDD variables in the manager. -******************************************************************************/ +*/ int Ntr_testISOP( DdManager * dd, @@ -332,7 +322,7 @@ Ntr_testISOP( if (option->node == NULL) { nz = net->noutputs; for (i = 0; i < nz; i++) { - if (!st_lookup(net->hash,net->outputs[i],&node)) { + if (!st_lookup(net->hash,net->outputs[i],(void **)&node)) { return(0); } bdd = Cudd_zddIsop(dd, node->dd, node->dd, &zdd[i]); @@ -367,7 +357,7 @@ Ntr_testISOP( } } else { nz = 1; - if (!st_lookup(net->hash,option->node,&node)) { + if (!st_lookup(net->hash,option->node,(void **)&node)) { return(0); } bdd = Cudd_zddIsop(dd, node->dd, node->dd, &zdd[0]); @@ -428,23 +418,21 @@ Ntr_testISOP( /*---------------------------------------------------------------------------*/ -/**Function******************************************************************** +/** + @brief Applies reordering to the ZDDs. - Synopsis [Applies reordering to the ZDDs.] + @details Explicitly applies reordering to the ZDDs. - Description [Explicitly applies reordering to the ZDDs. Returns 1 if - successful; 0 otherwise.] + @return 1 if successful; 0 otherwise. - SideEffects [None] + @sideeffect None - SeeAlso [] - -*****************************************************************************/ +*/ static int reorderZdd( - BnetNetwork * net, - DdManager * dd /* DD Manager */, - NtrOptions * option) + BnetNetwork * net /**< boolean network */, + DdManager * dd /**< DD Manager */, + NtrOptions * option /**< options */) { int result; /* return value from functions */ diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/rcn25.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/rcn25.blif similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/rcn25.blif rename to resources/3rdparty/cudd-3.0.0/nanotrav/rcn25.blif diff --git a/resources/3rdparty/cudd-2.5.0/src/nanotrav/s27.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/s27.blif similarity index 100% rename from resources/3rdparty/cudd-2.5.0/src/nanotrav/s27.blif rename to resources/3rdparty/cudd-3.0.0/nanotrav/s27.blif diff --git a/resources/3rdparty/cudd-3.0.0/nanotrav/s27b.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/s27b.blif new file mode 100644 index 000000000..3ebcf76bd --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/s27b.blif @@ -0,0 +1,22 @@ +.model s27b.bench +.inputs G0 G1 G2 G3 +.outputs G17 +.latch G10 G5 0 +.latch G11 G6 0 +.latch G13 G7 0 +.names G11 G17 +0 1 +.names G0 G11 G10 +10 1 +.names G5 G9 G11 +00 1 +.names G2 G12 G13 +00 1 +.names G0 G6 G8 +01 1 +.names G1 G7 G12 +00 1 +.names G3 G8 G12 G9 +-1- 0 +1-1 0 +.end diff --git a/resources/3rdparty/cudd-3.0.0/nanotrav/s27c.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/s27c.blif new file mode 100644 index 000000000..ff86fb951 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/s27c.blif @@ -0,0 +1,14 @@ +.model s27c.bench +.outputs G11 +.latch G10 G5 0 +.latch G11 G6 0 +.latch G7 G7 0 +.names G11 G10 +0 1 +.names G5 G9 G11 +00 1 +.names G6 G8 +1 1 +.names G8 G7 G9 +01 1 +.end diff --git a/resources/3rdparty/cudd-3.0.0/nanotrav/s382.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/s382.blif new file mode 100644 index 000000000..82c4db310 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/s382.blif @@ -0,0 +1,414 @@ +.model s382.bench +.inputs FM TEST CLR +.outputs GRN1 GRN2 RED1 YLW2 RED2 YLW1 +.latch TESTLVIINLATCHVCDAD TESTL 0 +.latch FMLVIINLATCHVCDAD FML 0 +.latch TCOMB_YA2 OLATCH_Y2L 0 +.latch Y1C OLATCHVUC_6 0 +.latch R2C OLATCHVUC_5 0 +.latch TCOMB_RA1 OLATCH_R1L 0 +.latch TCOMB_GA2 OLATCH_G2L 0 +.latch TCOMB_GA1 OLATCH_G1L 0 +.latch TCOMB_FE_BF OLATCH_FEL 0 +.latch C3_Q3VD C3_Q3 0 +.latch C3_Q2VD C3_Q2 0 +.latch C3_Q1VD C3_Q1 0 +.latch C3_Q0VD C3_Q0 0 +.latch UC_16VD UC_16 0 +.latch UC_17VD UC_17 0 +.latch UC_18VD UC_18 0 +.latch UC_19VD UC_19 0 +.latch UC_8VD UC_8 0 +.latch UC_9VD UC_9 0 +.latch UC_10VD UC_10 0 +.latch UC_11VD UC_11 0 +.names OUTBUFVBUFG1VIIR1 GRN1 +0 1 +.names OUTBUFVBUFG2VIIR1 GRN2 +0 1 +.names OUTBUFVBUFR1VIIR1 RED1 +0 1 +.names OUTBUFVBUFY2VIIR1 YLW2 +0 1 +.names OUTBUFVBUFR2VIIR1 RED2 +0 1 +.names OUTBUFVBUFY1VIIR1 YLW1 +0 1 +.names TESTLVIINLATCHVCDN TESTLVIINMUX TESTLVIINLATCHVCDAD +11 1 +.names FMLVIINLATCHVCDN FMLVIINMUX FMLVIINLATCHVCDAD +11 1 +.names TCOMBVNODE12 TCOMBVNQA TCOMB_YA2 +00 1 +.names Y1CVAD2NF Y1CVAD1NF Y1C +00 1 +.names R2CVAD2NF R2CVAD1NF R2C +00 1 +.names TCOMBVNCLR TCOMB_RA1VOR2NF TCOMB_RA1VOR1NF TCOMB_RA1 +0-- 1 +-0- 1 +--0 1 +.names TCOMB_GA2VAD4NF TCOMB_GA2VAD3NF TCOMB_GA2VAD2NF TCOMB_GA2VAD1NF TCOMB_GA2 +0000 1 +.names TCOMBVNODE8 TCOMB_GA1VAD1NF TCOMB_GA1 +00 1 +.names II84 TCOMB_FE_BF +0 1 +.names CLRB C3_Q3VZ UC_27 C3_Q3VD +000 1 +.names CLRB C3_Q2VZ UC_27 C3_Q2VD +000 1 +.names CLRB C3_Q1VZ UC_27 C3_Q1VD +000 1 +.names CLRB C3_Q0VZ UC_27 C3_Q0VD +000 1 +.names CLRB UC_16VZ C2_CO UC_16VD +000 1 +.names CLRB UC_17VZ C2_CO UC_17VD +000 1 +.names CLRB UC_18VZ C2_CO UC_18VD +000 1 +.names CLRB UC_19VZ C2_CO UC_19VD +000 1 +.names CLRB UC_8VZ C1_CO UC_8VD +000 1 +.names CLRB UC_9VZ C1_CO UC_9VD +000 1 +.names CLRB UC_10VZ C1_CO UC_10VD +000 1 +.names CLRB UC_11VZ C1_CO UC_11VD +000 1 +.names TESTL TESTLVIINLATCHN +0 1 +.names FML FMLVIINLATCHN +0 1 +.names OLATCHVUC_6 OLATCH_Y1L +0 1 +.names OLATCHVUC_5 OLATCH_R2L +0 1 +.names C3_Q3 UC_23 +0 1 +.names C3_Q2 UC_24 +0 1 +.names C3_Q1 UC_25 +0 1 +.names C3_Q0 UC_26 +0 1 +.names UC_16 UC_20 +0 1 +.names UC_17 C2_QN2 +0 1 +.names UC_18 UC_21 +0 1 +.names UC_19 UC_22 +0 1 +.names UC_8 UC_12 +0 1 +.names UC_9 UC_13 +0 1 +.names UC_10 UC_14 +0 1 +.names UC_11 UC_15 +0 1 +.names FM FMBVIIR1 +0 1 +.names CLR CLRBVIIR1 +0 1 +.names FML TCOMBVNFM +0 1 +.names TEST TESTBVIIR1 +0 1 +.names C3_Q0 TCOMBVNQA +0 1 +.names C3_Q1 TCOMBVNQB +0 1 +.names C3_Q2 TCOMBVNQC +0 1 +.names C3_Q3 TCOMBVNQD +0 1 +.names UC_11 UC_11VUC_0 +0 1 +.names OLATCH_G1L OUTBUFVBUFG1VIIR1 +0 1 +.names OLATCH_G2L OUTBUFVBUFG2VIIR1 +0 1 +.names OLATCH_FEL TCOMBVNFEL +0 1 +.names OLATCH_R1L OUTBUFVBUFR1VIIR1 +0 1 +.names OLATCH_Y2L OUTBUFVBUFY2VIIR1 +0 1 +.names FMBVIIR1 FMB +0 1 +.names CLRBVIIR1 CLRB +0 1 +.names TESTBVIIR1 TESTB +0 1 +.names UC_11VUC_0 UC_11VZ +0 1 +.names UC_15 C1VCO0 +0 1 +.names OLATCH_R2L OUTBUFVBUFR2VIIR1 +0 1 +.names OLATCH_Y1L OUTBUFVBUFY1VIIR1 +0 1 +.names FMB FMLVIINMUXVIIR1 +0 1 +.names CLRB TESTLVIINLATCHVCDN +0 1 +.names CLRB FMLVIINLATCHVCDN +0 1 +.names CLRB TCOMBVNCLR +0 1 +.names TESTB TESTLVIINMUXVIIR1 +0 1 +.names C1_CO TESTL CTST +00 1 +.names CTST C2VIINHN +0 1 +.names C1VCO2 UC_8 UC_8VZVOR1NF +1- 1 +-1 1 +.names UC_8VZVOR1NF UC_8VZ +0 1 +.names C2VCIIA CTST UC_20 C2_CO +000 1 +.names C2_CO CO2 +0 1 +.names FMLVIINMUXVOR2NF FMLVIINMUXVOR1NF FMLVIINMUXVND1 +0- 1 +-0 1 +.names FMLVIINMUXVND1 FMLVIINMUX +0 1 +.names TESTLVIINMUXVOR2NF TESTLVIINMUXVOR1NF TESTLVIINMUXVND1 +0- 1 +-0 1 +.names TESTLVIINMUXVND1 TESTLVIINMUX +0 1 +.names TCOMBVNODE16 TCOMBVNODE14 TCOMB_FE +0- 1 +-0 1 +.names TCOMB_FE II84 +0 1 +.names TCOMB_FE FEN +0 1 +.names C2VCO2 UC_16 UC_16VZVOR1NF +1- 1 +-1 1 +.names UC_16VZVOR1NF UC_16VZ +0 1 +.names CO2 C3VIINHN +0 1 +.names C3VCO2 C3_Q3 C3_Q3VZVOR1NF +1- 1 +-1 1 +.names C3_Q3VZVOR1NF C3_Q3VZ +0 1 +.names TCOMBVNFM TCOMBVNQD TCOMBVNQB C3_Q0 TCOMBVNODE6 +0--- 1 +-0-- 1 +--0- 1 +---0 1 +.names TCOMBVNODE6 OLATCH_FEL TCOMB_GA1VAD1NF +11 1 +.names OLATCH_FEL TCOMBVNCLR TCOMB_GA2VAD4NF +11 1 +.names C3_Q2 TCOMBVNCLR TCOMB_GA2VAD3NF +11 1 +.names C3_Q0 C3_Q1 TCOMBVNCLR TCOMB_GA2VAD2NF +111 1 +.names TCOMBVNQA C3_Q3 TCOMBVNCLR TCOMB_GA2VAD1NF +111 1 +.names TCOMB_FE C2_QN2 R2CVAD1NF +11 1 +.names TCOMBVNODE16 TCOMBVNODE3 TCOMB_YA1 +0- 1 +-0 1 +.names TCOMB_YA1 C2_QN2 Y1CVAD1NF +11 1 +.names FEN TCOMB_YA1 Y1CVAD2NF +11 1 +.names TCOMB_RA2VOR3NF TCOMB_RA2VOR1NF TCOMB_RA2 +0- 1 +-0 1 +.names FEN TCOMB_RA2 R2CVAD2NF +11 1 +.names C3_Q2 C3_Q3 OLATCH_FEL TCOMB_RA1VOR2NF +1-- 1 +-1- 1 +--1 1 +.names C3_Q0 C3_Q1 TCOMBVNFM TCOMBVNODE8VOR1NF +1-- 1 +-1- 1 +--1 1 +.names TCOMBVNQA C3_Q1 C3_Q2 OLATCH_FEL TCOMB_RA1VOR1NF +1--- 1 +-1-- 1 +--1- 1 +---1 1 +.names TCOMBVNQD TCOMBVNFM TCOMBVNODE8VOR2NF +1- 1 +-1 1 +.names FMB FML FMLVIINMUXVOR1NF +1- 1 +-1 1 +.names TCOMBVNQC CLRB TCOMB_RA2VOR3NF +1- 1 +-1 1 +.names C3_Q0 C3_Q1 TCOMBVNQD CLRB TCOMB_RA2VOR1NF +1--- 1 +-1-- 1 +--1- 1 +---1 1 +.names C3_Q2 TCOMBVNQD CLRB TCOMBVNODE4VOR2NF +1-- 1 +-1- 1 +--1 1 +.names TCOMBVNQC C3_Q3 TCOMBVNFM CLRB TCOMBVNODE4VOR1NF +1--- 1 +-1-- 1 +--1- 1 +---1 1 +.names TESTB TESTL TESTLVIINMUXVOR1NF +1- 1 +-1 1 +.names TCOMBVNQB C3_Q0 TCOMBVNODE18 +0- 1 +-0 1 +.names TCOMBVNODE18 FML C3_Q3 TCOMBVNQC TCOMBVNODE16VOR1NF +1--- 1 +-1-- 1 +--1- 1 +---1 1 +.names UC_13 UC_14 UC_15 C1VCO2 +000 1 +.names UC_14 UC_15 C1VCO1 +00 1 +.names C1VCO1 UC_9 UC_9VZVOR1NF +1- 1 +-1 1 +.names C1VCO0 UC_10 UC_10VZVOR1NF +1- 1 +-1 1 +.names FMLVIINMUXVIIR1 FMLVIINLATCHN FMLVIINMUXVOR2NF +1- 1 +-1 1 +.names TESTLVIINMUXVIIR1 TESTLVIINLATCHN TESTLVIINMUXVOR2NF +1- 1 +-1 1 +.names CTST C2_QN2 UC_21 UC_22 C2VCO2 +0000 1 +.names CTST UC_21 UC_22 C2VCO1 +000 1 +.names C2VCO1 UC_17 UC_17VZVOR1NF +1- 1 +-1 1 +.names CTST UC_22 C2VCO0 +00 1 +.names C2VCO0 UC_18 UC_18VZVOR1NF +1- 1 +-1 1 +.names C2VIINHN UC_19 UC_19VZVOR1NF +1- 1 +-1 1 +.names CO2 UC_24 UC_25 UC_26 C3VCO2 +0000 1 +.names CO2 UC_25 UC_26 C3VCO1 +000 1 +.names C3VCO1 C3_Q2 C3_Q2VZVOR1NF +1- 1 +-1 1 +.names CO2 UC_26 C3VCO0 +00 1 +.names C3VCO0 C3_Q1 C3_Q1VZVOR1NF +1- 1 +-1 1 +.names C3VIINHN C3_Q0 C3_Q0VZVOR1NF +1- 1 +-1 1 +.names C1VCO1 UC_9 UC_9VUC_0 +0- 1 +-0 1 +.names C1VCO0 UC_10 UC_10VUC_0 +0- 1 +-0 1 +.names TCOMBVNODE4VOR2NF TCOMBVNODE4VOR1NF TCOMBVNODE4 +0- 1 +-0 1 +.names CLRB TCOMBVNFM TCOMBVNQC C3_Q1 TCOMBVNODE15 +0000 1 +.names TCOMBVNODE15 TCOMBVNQA TCOMBVNODE14 +0- 1 +-0 1 +.names TCOMBVNCLR TCOMBVNFEL TCOMBVNQC C3_Q1 TCOMBVNODE12 +0--- 1 +-0-- 1 +--0- 1 +---0 1 +.names TCOMBVNCLR C3_Q2 TCOMBVNODE8VOR2NF TCOMBVNODE8VOR1NF TCOMBVNODE8 +0--- 1 +-0-- 1 +--0- 1 +---0 1 +.names CLRB TCOMBVNFEL TCOMBVNODE19 +00 1 +.names TCOMBVNODE19 TCOMBVNODE16VOR1NF TCOMBVNODE16 +0- 1 +-0 1 +.names UC_9VZVOR1NF UC_9VUC_0 UC_9VZ +0- 1 +-0 1 +.names UC_10VZVOR1NF UC_10VUC_0 UC_10VZ +0- 1 +-0 1 +.names TCOMBVNODE4 TCOMBVNQB TCOMBVNQA TCOMBVNODE3 +0-- 1 +-0- 1 +--0 1 +.names C2VCO1 UC_17 UC_17VUC_0 +0- 1 +-0 1 +.names C2VCO0 UC_18 UC_18VUC_0 +0- 1 +-0 1 +.names C2VIINHN UC_19 UC_19VUC_0 +0- 1 +-0 1 +.names UC_17VZVOR1NF UC_17VUC_0 UC_17VZ +0- 1 +-0 1 +.names UC_18VZVOR1NF UC_18VUC_0 UC_18VZ +0- 1 +-0 1 +.names UC_19VZVOR1NF UC_19VUC_0 UC_19VZ +0- 1 +-0 1 +.names C3VCO1 C3_Q2 C3_Q2VUC_0 +0- 1 +-0 1 +.names C3VCO0 C3_Q1 C3_Q1VUC_0 +0- 1 +-0 1 +.names C3VIINHN C3_Q0 C3_Q0VUC_0 +0- 1 +-0 1 +.names C3_Q2VZVOR1NF C3_Q2VUC_0 C3_Q2VZ +0- 1 +-0 1 +.names C3_Q1VZVOR1NF C3_Q1VUC_0 C3_Q1VZ +0- 1 +-0 1 +.names C3_Q0VZVOR1NF C3_Q0VUC_0 C3_Q0VZ +0- 1 +-0 1 +.names C3_Q2 C3_Q1 C3_Q0 C3VCIIA +000 1 +.names UC_9 UC_10 UC_11 C1VCIIA +000 1 +.names UC_17 UC_18 UC_19 C2VCIIA +000 1 +.names C1VCIIA UC_12 C1_CO +00 1 +.names C3VCIIA CO2 UC_23 UC_27 +000 1 +.end diff --git a/resources/3rdparty/cudd-3.0.0/nanotrav/s641.blif b/resources/3rdparty/cudd-3.0.0/nanotrav/s641.blif new file mode 100644 index 000000000..127a58b2a --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/s641.blif @@ -0,0 +1,809 @@ +.model s641.bench +.inputs G1 G2 G3 G4 G5 G6 G8 G9 G10 G11 G12 G13 G14 G15 G16 G17 G18 G19 G20 G21 G22 G23 G24 G25 G26 G27 G28 G29 G30 G31 G32 G33 G34 G35 G36 +.outputs G91 G94 G107 G83 G84 G85 G100BF G98BF G96BF G92 G87BF G89BF G101BF G106BF G97BF G104BF G88BF G99BF G105BF G86BF G95BF G103BF G90 +.latch G380 G64 0 +.latch G262 G65 0 +.latch G394 G66 0 +.latch G250 G67 0 +.latch G122 G68 0 +.latch G133 G69 0 +.latch G138 G70 0 +.latch G139 G71 0 +.latch G140 G72 0 +.latch G141 G73 0 +.latch G142 G74 0 +.latch G125 G75 0 +.latch G126 G76 0 +.latch G127 G77 0 +.latch G128 G78 0 +.latch G129 G79 0 +.latch G130 G80 0 +.latch G131 G81 0 +.latch G132 G82 0 +.names II165 G91 +0 1 +.names IIII178 G94 +0 1 +.names G313 G18 G107 +11 1 +.names G316 G19 G83 +11 1 +.names G319 G20 G84 +11 1 +.names G322 G21 G85 +11 1 +.names G100 G100BF +0 1 +.names G98 G98BF +0 1 +.names G96 G96BF +0 1 +.names G350 G28 G92 +11 1 +.names G87 G87BF +0 1 +.names G89 G89BF +0 1 +.names G101 G101BF +0 1 +.names G106 G106BF +0 1 +.names G97 G97BF +0 1 +.names G104 G104BF +0 1 +.names G88 G88BF +0 1 +.names G99 G99BF +0 1 +.names G105 G105BF +0 1 +.names IIII322 G138 +0 1 +.names G86 G86BF +0 1 +.names G95 G95BF +0 1 +.names G103 G103BF +0 1 +.names G298 G26 G90 +11 1 +.names II551 G380 +0 1 +.names G366 G392 G395 G397 G262 +1111 1 +.names II476 G394 +0 1 +.names G366 G396 G250 +11 1 +.names IIII210 G122 +0 1 +.names IIII287 G133 +0 1 +.names IIII329 G139 +0 1 +.names IIII336 G140 +0 1 +.names IIII343 G141 +0 1 +.names IIII350 G142 +0 1 +.names IIII230 G125 +0 1 +.names IIII237 G126 +0 1 +.names IIII244 G127 +0 1 +.names IIII251 G128 +0 1 +.names IIII258 G129 +0 1 +.names IIII265 G130 +0 1 +.names IIII272 G131 +0 1 +.names IIII279 G132 +0 1 +.names G1 IIII633 +0 1 +.names G2 G366 +0 1 +.names G3 G379 +0 1 +.names G4 IIII643 +0 1 +.names G5 IIII646 +0 1 +.names G6 IIII649 +0 1 +.names G8 IIII652 +0 1 +.names G9 IIII655 +0 1 +.names G10 IIII660 +0 1 +.names G11 IIII680 +0 1 +.names G12 IIII684 +0 1 +.names G13 IIII687 +0 1 +.names G27 II165 +0 1 +.names G29 IIII178 +0 1 +.names G70 II169 +0 1 +.names G71 II172 +0 1 +.names G72 II175 +0 1 +.names G80 II178 +0 1 +.names G73 II181 +0 1 +.names G81 II184 +0 1 +.names G74 II187 +0 1 +.names G82 II190 +0 1 +.names G75 II193 +0 1 +.names G68 II196 +0 1 +.names G76 II199 +0 1 +.names G69 II202 +0 1 +.names G77 II205 +0 1 +.names G78 II208 +0 1 +.names G79 II211 +0 1 +.names IIII633 G352 +0 1 +.names IIII643 G360 +0 1 +.names IIII646 G361 +0 1 +.names IIII649 G362 +0 1 +.names IIII652 G363 +0 1 +.names IIII655 G364 +0 1 +.names IIII660 G367 +0 1 +.names IIII680 G386 +0 1 +.names IIII684 G388 +0 1 +.names IIII687 G389 +0 1 +.names II169 G113 +0 1 +.names II172 G115 +0 1 +.names II175 G117 +0 1 +.names II178 G219 +0 1 +.names II181 G119 +0 1 +.names II184 G221 +0 1 +.names II187 G121 +0 1 +.names II190 G223 +0 1 +.names II193 G209 +0 1 +.names II196 G109 +0 1 +.names II199 G211 +0 1 +.names II202 G111 +0 1 +.names II205 G213 +0 1 +.names II208 G215 +0 1 +.names II211 G217 +0 1 +.names G360 G110 +0 1 +.names G360 G114 +0 1 +.names G360 G118 +0 1 +.names G360 G216 +0 1 +.names G360 G218 +0 1 +.names G360 G220 +0 1 +.names G360 G222 +0 1 +.names G364 G365 +0 1 +.names G367 G368 +0 1 +.names G386 G387 +0 1 +.names G388 G225 +0 1 +.names G389 G390 +0 1 +.names G386 G388 G389 G289 +111 1 +.names G289 IIII356 +0 1 +.names G110 G111 G324 +11 1 +.names G324 II254 +0 1 +.names G324 II257 +0 1 +.names G114 G115 G338 +11 1 +.names G338 II260 +0 1 +.names G338 II263 +0 1 +.names G118 G119 G344 +11 1 +.names G344 II266 +0 1 +.names G344 II269 +0 1 +.names G216 G217 G312 +11 1 +.names G312 II272 +0 1 +.names G218 G219 G315 +11 1 +.names G315 II275 +0 1 +.names G220 G221 G318 +11 1 +.names G318 II278 +0 1 +.names G222 G223 G321 +11 1 +.names G321 II281 +0 1 +.names IIII356 G143 +0 1 +.names II254 G166 +0 1 +.names II257 G325 +0 1 +.names II260 G194 +0 1 +.names II263 G339 +0 1 +.names II266 G202 +0 1 +.names II269 G345 +0 1 +.names II272 G313 +0 1 +.names II275 G316 +0 1 +.names II278 G319 +0 1 +.names II281 G322 +0 1 +.names G143 II303 +0 1 +.names G232 G248 G65 G281 +1-- 1 +-1- 1 +--1 1 +.names G281 IIII299 +0 1 +.names G234 G67 G264 G283 +1-- 1 +-1- 1 +--1 1 +.names G283 IIII313 +0 1 +.names G166 II287 +0 1 +.names G194 II291 +0 1 +.names G202 II295 +0 1 +.names II303 G350 +0 1 +.names IIII299 IIII301 +0 1 +.names IIII313 IIII315 +0 1 +.names II287 G381 +0 1 +.names G325 G35 G100 +11 1 +.names II291 G375 +0 1 +.names G339 G33 G98 +11 1 +.names II295 G371 +0 1 +.names G345 G31 G96 +11 1 +.names IIII301 G135 +0 1 +.names IIII315 G137 +0 1 +.names G381 G382 +0 1 +.names G375 G376 +0 1 +.names G371 G372 +0 1 +.names G135 II321 +0 1 +.names G137 II324 +0 1 +.names II321 G329 +0 1 +.names II324 G333 +0 1 +.names G329 G23 G87 +11 1 +.names G87 IIII406 +0 1 +.names G333 G25 G89 +11 1 +.names G89 IIII422 +0 1 +.names IIII406 G173 +0 1 +.names IIII422 G183 +0 1 +.names G173 II335 +0 1 +.names G183 II338 +0 1 +.names II335 G174 +0 1 +.names II338 G184 +0 1 +.names G174 II341 +0 1 +.names G184 G359 +0 1 +.names II341 G355 +0 1 +.names G359 G108 +0 1 +.names G355 G356 +0 1 +.names G356 G116 +0 1 +.names G108 G109 G293 +11 1 +.names G293 II354 +0 1 +.names G293 II357 +0 1 +.names G214 G215 G309 +11 1 +.names G309 II360 +0 1 +.names G309 II363 +0 1 +.names II354 G146 +0 1 +.names II357 G294 +0 1 +.names II360 G162 +0 1 +.names II363 G310 +0 1 +.names G116 G117 G341 +11 1 +.names G341 II366 +0 1 +.names G341 II369 +0 1 +.names G210 G211 G303 +11 1 +.names G303 II372 +0 1 +.names G303 II375 +0 1 +.names G146 II378 +0 1 +.names G162 II382 +0 1 +.names II366 G198 +0 1 +.names II369 G342 +0 1 +.names II372 G154 +0 1 +.names II375 G304 +0 1 +.names II378 G383 +0 1 +.names G294 G36 G101 +11 1 +.names II382 G396 +0 1 +.names G310 G17 G106 +11 1 +.names G198 II386 +0 1 +.names G154 II390 +0 1 +.names G383 G384 +0 1 +.names G396 G397 +0 1 +.names II386 G373 +0 1 +.names G342 G32 G97 +11 1 +.names II390 G392 +0 1 +.names G304 G15 G104 +11 1 +.names G384 IIII476 +0 1 +.names G366 G396 G278 +11 1 +.names G278 IIII279 +0 1 +.names G373 G374 +0 1 +.names G392 G393 +0 1 +.names IIII476 G224 +0 1 +.names G233 G249 G263 G282 +1-- 1 +-1- 1 +--1 1 +.names G282 IIII306 +0 1 +.names G374 G375 G237 +11 1 +.names G237 II373 +0 1 +.names II373 G286 +0 1 +.names G224 IIII208 +0 1 +.names IIII306 IIII308 +0 1 +.names G286 IIII334 +0 1 +.names G236 G252 G285 +1- 1 +-1 1 +.names G285 IIII327 +0 1 +.names IIII208 IIII210 +0 1 +.names IIII308 G136 +0 1 +.names IIII334 IIII336 +0 1 +.names IIII327 IIII329 +0 1 +.names G136 II442 +0 1 +.names II442 G331 +0 1 +.names G331 G24 G88 +11 1 +.names G88 IIII414 +0 1 +.names IIII414 G178 +0 1 +.names G178 II449 +0 1 +.names II449 G179 +0 1 +.names G179 II452 +0 1 +.names II452 G357 +0 1 +.names G357 G358 +0 1 +.names G358 G112 +0 1 +.names G112 G113 G335 +11 1 +.names G335 II460 +0 1 +.names G335 II463 +0 1 +.names G212 G213 G306 +11 1 +.names G306 II466 +0 1 +.names G306 II469 +0 1 +.names II460 G190 +0 1 +.names II463 G336 +0 1 +.names II466 G158 +0 1 +.names II469 G307 +0 1 +.names G190 II472 +0 1 +.names G158 II476 +0 1 +.names G158 G395 +0 1 +.names II472 G377 +0 1 +.names G336 G34 G99 +11 1 +.names G366 G158 G397 G277 +111 1 +.names G277 IIII272 +0 1 +.names G307 G16 G105 +11 1 +.names G377 G378 +0 1 +.names G366 G392 G395 G397 G276 +1111 1 +.names G276 IIII265 +0 1 +.names G231 G247 G261 G280 +1-- 1 +-1- 1 +--1 1 +.names G280 IIII292 +0 1 +.names G378 G381 G235 +11 1 +.names G235 II440 +0 1 +.names II440 G284 +0 1 +.names IIII292 IIII294 +0 1 +.names G284 IIII320 +0 1 +.names G230 G246 G279 +1- 1 +-1 1 +.names G279 IIII285 +0 1 +.names IIII294 G134 +0 1 +.names IIII320 IIII322 +0 1 +.names IIII285 IIII287 +0 1 +.names G134 II517 +0 1 +.names II517 G327 +0 1 +.names G327 G22 G86 +11 1 +.names G86 IIII398 +0 1 +.names IIII398 G168 +0 1 +.names G168 II524 +0 1 +.names II524 G169 +0 1 +.names G169 II527 +0 1 +.names II527 G353 +0 1 +.names G353 G354 +0 1 +.names G354 G120 +0 1 +.names G120 G121 G347 +11 1 +.names G347 II535 +0 1 +.names G347 II538 +0 1 +.names G208 G209 G300 +11 1 +.names G300 II541 +0 1 +.names G300 II544 +0 1 +.names II535 G206 +0 1 +.names II538 G348 +0 1 +.names II541 G150 +0 1 +.names II544 G301 +0 1 +.names G206 II547 +0 1 +.names G150 II551 +0 1 +.names G150 G391 +0 1 +.names II547 G369 +0 1 +.names G348 G30 G95 +11 1 +.names G301 G14 G103 +11 1 +.names G369 G370 +0 1 +.names G395 G397 IIII553 G275 +111 1 +.names G275 IIII258 +0 1 +.names G226 G242 G257 G271 +1-- 1 +-1- 1 +--1 1 +.names G271 IIII230 +0 1 +.names G370 G371 G239 +11 1 +.names G239 II511 +0 1 +.names II511 G288 +0 1 +.names G227 G243 G258 G272 +1-- 1 +-1- 1 +--1 1 +.names G272 IIII237 +0 1 +.names G228 G244 G259 G273 +1-- 1 +-1- 1 +--1 1 +.names G273 IIII244 +0 1 +.names G229 G245 G260 G274 +1-- 1 +-1- 1 +--1 1 +.names G274 IIII251 +0 1 +.names G288 IIII348 +0 1 +.names G238 G254 G287 +1- 1 +-1 1 +.names G287 IIII341 +0 1 +.names G265 G266 G267 IIII546 G270 +1--- 1 +-1-- 1 +--1- 1 +---1 1 +.names G270 IIII222 +0 1 +.names IIII348 IIII350 +0 1 +.names IIII341 IIII343 +0 1 +.names IIII222 IIII224 +0 1 +.names IIII224 G124 +0 1 +.names G124 II608 +0 1 +.names II608 G298 +0 1 +.names G379 G387 G231 +11 1 +.names G379 G387 G232 +11 1 +.names G379 G387 G233 +11 1 +.names G379 G387 G234 +11 1 +.names G379 G365 G368 G390 G247 +1111 1 +.names G379 G365 G367 G390 G248 +1111 1 +.names G379 G364 G368 G390 G263 +1111 1 +.names G379 G364 G367 G390 G264 +1111 1 +.names G379 G359 G214 +0- 1 +-0 1 +.names G379 G356 G210 +0- 1 +-0 1 +.names G364 G367 G383 G390 G266 +1111 1 +.names G366 G396 G229 +11 1 +.names G352 G396 G245 +11 1 +.names G366 G66 G397 G249 +111 1 +.names G365 G367 G373 IIII533 +111 1 +.names G366 G392 G227 +11 1 +.names G392 G361 G243 +11 1 +.names G375 G390 IIII533 G265 +111 1 +.names G374 G376 G236 +11 1 +.names G355 G374 G252 +11 1 +.names G366 G64 G393 IIII527 +111 1 +.names G379 G358 G212 +0- 1 +-0 1 +.names G366 G158 G228 +11 1 +.names G158 G362 G244 +11 1 +.names G393 G395 G397 IIII515 +111 1 +.names G395 G397 IIII527 G261 +111 1 +.names G364 G368 G377 IIII512 +111 1 +.names G377 G381 G383 G387 IIII538 +1111 1 +.names G381 G390 IIII512 G256 +111 1 +.names G378 G382 G230 +11 1 +.names G357 G378 G246 +11 1 +.names G379 G354 G208 +0- 1 +-0 1 +.names G366 G150 G226 +11 1 +.names G150 G363 G242 +11 1 +.names G366 G150 G393 IIII553 +111 1 +.names G391 G395 G397 IIII518 +111 1 +.names G391 G393 G397 IIII521 +111 1 +.names G352 G391 G393 IIII524 +111 1 +.names G365 G368 G369 IIII495 +111 1 +.names G363 G369 G371 IIII515 G257 +1111 1 +.names G369 G371 G373 G375 IIII537 +1111 1 +.names G361 G373 G375 IIII518 G258 +1111 1 +.names G362 G377 G381 IIII521 G259 +1111 1 +.names G395 G383 IIII524 G260 +111 1 +.names G371 G390 IIII495 G241 +111 1 +.names IIII537 IIII538 G267 +11 1 +.names G370 G372 G238 +11 1 +.names G353 G370 G254 +11 1 +.names G225 G241 G256 IIII546 +1-- 1 +-1- 1 +--1 1 +.end diff --git a/resources/3rdparty/cudd-3.0.0/nanotrav/test_ntrv.test.in b/resources/3rdparty/cudd-3.0.0/nanotrav/test_ntrv.test.in new file mode 100644 index 000000000..e2038231d --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/nanotrav/test_ntrv.test.in @@ -0,0 +1,81 @@ +#! /bin/sh + +# A script to test nanotrav. +# Each item in argslist corresponds to one run. + +EXE=@EXEEXT@ +srcdir=@srcdir@ + +# The separator IFS is set to a colon so that we can have spaces between +# arguments. Each entry consists of a model name and a list of arguments. +OIFS=$IFS +IFS=: +argslist="\ +C17,-cover:\ +C880,-ordering dfs -autodyn -automethod sifting -reordering sifting -drop:\ +s27,-ordering hw -reordering annealing -trav:\ +s27b,-ordering dfs -reordering win4 -verify ${srcdir}/nanotrav/s27.blif:\ +s27c,-trav -image depend -depend:\ +mult32a,-autodyn -reordering sifting -trav:\ +s382,-trav -image part -autodyn -automethod sifting -drop -scc -shortpaths bellman:\ +s641,-trav -autodyn -automethod group -drop -clauses -density -decomp -zdd:\ +closest,-reordering genetic -drop -closest:\ +adj49,-ordering dfs -reordering cogroup -drop -char2vect -cofest:\ +ham01,-reordering linear:\ +miniFirst,-second ${srcdir}/nanotrav/miniSecond.blif:\ +rcn25,-envelope" + +verbosity=1 + +# Discard statistics and remove CPU times. +sed_command='-r:-e:2d:-e:/modifiable/,$d:-e:s/[0-9][0-9]*\.?[0-9]* sec//:-e:s/[0-9][0-9]* recursive//' + +echo TAP version 13 +echo 1..13 +exitstatus=0 +count=0 + +# Create FIFOs for communication between sed processes and diff. +mkfifo nanotrav/tst_fifo nanotrav/out_fifo +# Create empty file. +: > ./nanotrav/differences + +for argres in $argslist +do + IFS=, # split model name from arguments + set -- $argres + IFS=: + echo "# executing" "nanotrav/nanotrav$EXE -p $verbosity" \ + "$2 ${srcdir}/nanotrav/${1}.blif > ./nanotrav/${1}.tst" + `eval "nanotrav/nanotrav -p $verbosity $2 ${srcdir}/nanotrav/${1}.blif > ./nanotrav/${1}.tst"` + failed=`expr $? != 0` + # If nanotrav completed successfully, compare this run's fitered output + # to the reference filtered output. + if test x$failed = x0; then + echo "# comparing" "./nanotrav/${1}.tst to ${srcdir}/nanotrav/${1}.out" + `sed ${sed_command} ./nanotrav/${1}.tst > nanotrav/tst_fifo &\ + sed ${sed_command} ${srcdir}/nanotrav/${1}.out > nanotrav/out_fifo &\ + diff -b nanotrav/tst_fifo nanotrav/out_fifo >> ./nanotrav/differences` + failed=`expr $? != 0` + fi + exitstatus=`expr $exitstatus + $failed` + count=`expr $count + 1` + if test x$failed = x0 ; then + echo "ok $count $1" + else + echo "not ok $count $1" + fi +done + +# Clean up and report. +rm nanotrav/tst_fifo nanotrav/out_fifo +echo "# $exitstatus failed sub-tests out of $count" +if test x$exitstatus = x0; then + rm ./nanotrav/differences +else + echo '# Check file "./nanotrav/differences"' +fi +# Restore internal field separator. +IFS=$OIFS + +exit 0 diff --git a/resources/3rdparty/cudd-3.0.0/st/Included.am b/resources/3rdparty/cudd-3.0.0/st/Included.am new file mode 100644 index 000000000..780ce607a --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/st/Included.am @@ -0,0 +1,16 @@ +cudd_libcudd_la_SOURCES += st/st.h st/st.c + +check_PROGRAMS += st/testst +st_testst_SOURCES = st/testst.c +st_testst_CPPFLAGS = $(cudd_libcudd_la_CPPFLAGS) +st_testst_LDADD = cudd/libcudd.la + +check_SCRIPTS += st/test_st.test +EXTRA_DIST += st/test_st.test.in +if !CROSS_COMPILING +TESTS += st/test_st.test +endif !CROSS_COMPILING + +st/test_st.test: st/test_st.test.in Makefile + $(do_subst) $< > $@ + chmod +x $@ diff --git a/resources/3rdparty/cudd-3.0.0/st/st.c b/resources/3rdparty/cudd-3.0.0/st/st.c new file mode 100644 index 000000000..004c44c57 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/st/st.c @@ -0,0 +1,1198 @@ +/** + @file + + @ingroup st + + @brief Symbol table package. + + @details The st library provides functions to create, maintain, + and query symbol tables. + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" +#include "st.h" + +/*---------------------------------------------------------------------------*/ +/* Constant declarations */ +/*---------------------------------------------------------------------------*/ + + +/*---------------------------------------------------------------------------*/ +/* Type declarations */ +/*---------------------------------------------------------------------------*/ + +/** + * @brief Type of symbol table entries. + */ +typedef struct st_table_entry st_table_entry; + +/*---------------------------------------------------------------------------*/ +/* Stucture declarations */ +/*---------------------------------------------------------------------------*/ + +/** + * @brief Symbol table entry. + */ +struct st_table_entry { + void *key; + void *record; + st_table_entry *next; +}; + +/** + * @brief Symbol table header. + */ +struct st_table { + st_compare_t compare; + st_hash_t hash; + st_compare_arg_t compare_arg; + st_hash_arg_t hash_arg; + void const * arg; + int num_bins; + int num_entries; + int max_density; + int reorder_flag; + double grow_factor; + st_table_entry **bins; +}; + +/** + * @brief Symbol table generator. + */ +struct st_generator { + st_table const *table; + st_table_entry const *entry; + int index; +}; + +/*---------------------------------------------------------------------------*/ +/* Variable declarations */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Macro declarations */ +/*---------------------------------------------------------------------------*/ + +/** + * @brief Compares two numbers or two pointers. + * + * @details Used by the default comparison functions. + */ +#define ST_NUMCMP(x,y) ((x) != (y)) + +/** + * @brief Hash function for numbers. + */ +#define ST_NUMHASH(x,size) ((int)((uintptr_t)(x)%(uintptr_t)(size))) + +/** + * @brief Amount by which pointers should be shifted right when hashing. + * + * @details This is to discard bits that are (likely to be) 0 due to + * alignment constraints. + */ +#if SIZEOF_VOID_P == 8 +#define st_shift 3 +#else +#define st_shift 2 +#endif + +/** + * @brief Hash function for pointers. + */ +#define ST_PTRHASH(x,size) ((int)(((uintptr_t)(x)>>st_shift)%(uintptr_t)(size))) + +/** + * @brief Compares two entries. + */ +#define EQUAL(table, x, y) \ + ((((table)->compare == st_numcmp) || ((table)->compare == st_ptrcmp)) ?\ + (ST_NUMCMP((x),(y)) == 0) : ((table)->compare) ?\ + ((*(table)->compare)((x), (y)) == 0) :\ + ((*(table)->compare_arg)((x), (y), (table)->arg) == 0)) + +/** + * @brief Computes the hash of one entry. + */ +#define do_hash(key, table)\ + (((table)->hash == st_ptrhash) ? ST_PTRHASH((key), (table)->num_bins) : \ + ((table)->hash == st_numhash) ? ST_NUMHASH((key), (table)->num_bins) : \ + ((table)->hash) ? (*(table)->hash)((key), (table)->num_bins) : \ + (*(table)->hash_arg)((key), (table)->num_bins, (table)->arg)) + +/** + * @brief Compares the new key to one in a collision list. + */ +#define PTR_NOT_EQUAL(table, ptr, user_key)\ + ((ptr) != NIL(st_table_entry) && \ + !EQUAL((table), (user_key), (ptr)->key)) + +/** + * @brief Looks up an entry in a collision list. + * + * @details If the entry is found and the reorder flag is set, the found + * entry is brought to the fore of the collision list. + */ +#define FIND_ENTRY(table, hash_val, key, ptr, last) \ + (last) = &(table)->bins[hash_val];\ + (ptr) = *(last);\ + while (PTR_NOT_EQUAL((table), (ptr), (key))) {\ + (last) = &(ptr)->next; (ptr) = *(last);\ + }\ + if ((ptr) != NIL(st_table_entry) && (table)->reorder_flag) {\ + *(last) = (ptr)->next;\ + (ptr)->next = (table)->bins[hash_val];\ + (table)->bins[hash_val] = (ptr);\ + } + +/** + * @brief Adds an entry to a table. + * + * @deprecated This macro does not check if memory allocation fails. + * Use at your own risk. + */ +#define ADD_DIRECT(table, key, value, hash_val, newt)\ +{\ + if (table->num_entries/table->num_bins >= table->max_density) {\ + rehash(table);\ + hash_val = do_hash(key,table);\ + }\ + \ + newt = ALLOC(st_table_entry, 1);\ + \ + newt->key = key;\ + newt->record = value;\ + newt->next = table->bins[hash_val];\ + table->bins[hash_val] = newt;\ + table->num_entries++;\ +} + +/** \cond */ + +/*---------------------------------------------------------------------------*/ +/* Static function prototypes */ +/*---------------------------------------------------------------------------*/ + +static int rehash (st_table *); + +/** \endcond */ + + +/*---------------------------------------------------------------------------*/ +/* Definition of exported functions */ +/*---------------------------------------------------------------------------*/ + +/** + @brief Creates and initializes a table. + + @details Creates and initializes a table with the comparison function + compare_fn and hash function hash_fn. compare_fn is + + int compare_fn(const void *key1, const void *key2) + + It returns `<,=,> 0` depending on whether `key1 <,=,> key2` by some + measure.<p> + hash_fn is + + int hash_fn(void *key, int modulus) + + It returns an integer between `0` and `modulus-1` such that if + `compare_fn(key1,key2) == 0` then `hash_fn(key1) == hash_fn(key2)`.<p> + There are five predefined hash and comparison functions in st. + For keys as numbers: + + st_numhash(key, modulus) { return (unsigned int) key % modulus; } + st_numcmp(x,y) { return (int) x - (int) y; } + + For keys as pointers: + + st_ptrhash(key, modulus) { return ((unsigned int) key/4) % modulus } + st_ptrcmp(x,y) { return (int) x - (int) y; } + + For keys as strings: + + st_strhash(x,y) - a reasonable hashing function for strings + strcmp(x,y) - the standard library function + + It is recommended to use these particular functions if they fit your + needs, since st will recognize certain of them and run more quickly + because of it. + + @sideeffect None + + @see st_init_table_with_params st_free_table + +*/ +st_table * +st_init_table(st_compare_t compare, st_hash_t hash) +{ + return st_init_table_with_params(compare, hash, ST_DEFAULT_INIT_TABLE_SIZE, + ST_DEFAULT_MAX_DENSITY, + ST_DEFAULT_GROW_FACTOR, + ST_DEFAULT_REORDER_FLAG); + +} /* st_init_table */ + + +/** + @brief Create a table with given parameters. + + @details The full blown table initializer. compare and hash are + the same as in st_init_table. density is the largest the average + number of entries per hash bin there should be before the table is + grown. grow_factor is the factor the table is grown by when it + becomes too full. size is the initial number of bins to be allocated + for the hash table. If reorder_flag is non-zero, then every time an + entry is found, it is moved to the top of the chain.<p> + st_init_table(compare, hash) is equivelent to + + st_init_table_with_params(compare, hash, ST_DEFAULT_INIT_TABLE_SIZE, + ST_DEFAULT_MAX_DENSITY, ST_DEFAULT_GROW_FACTOR, + ST_DEFAULT_REORDER_FLAG); + + @sideeffect None + + @see st_init_table st_free_table + +*/ +st_table * +st_init_table_with_params( + st_compare_t compare, + st_hash_t hash, + int size, + int density, + double grow_factor, + int reorder_flag) +{ + int i; + st_table *newt; + + newt = ALLOC(st_table, 1); + if (newt == NIL(st_table)) { + return NIL(st_table); + } + newt->compare = compare; + newt->hash = hash; + newt->compare_arg = (st_compare_arg_t) 0; + newt->hash_arg = (st_hash_arg_t) 0; + newt->arg = NIL(void); + newt->num_entries = 0; + newt->max_density = density; + newt->grow_factor = grow_factor; + newt->reorder_flag = reorder_flag; + if (size <= 0) { + size = 1; + } + newt->num_bins = size; + newt->bins = ALLOC(st_table_entry *, size); + if (newt->bins == NIL(st_table_entry *)) { + FREE(newt); + return NIL(st_table); + } + for(i = 0; i < size; i++) { + newt->bins[i] = 0; + } + return newt; + +} /* st_init_table_with_params */ + + +/** + @brief Creates and initializes a table. + + @details Like st_init_table_with_params, but the comparison and + hash functions are passed an extra parameter `arg` that is + registered in the table at initialization. + + @see st_init_table_with_params +*/ +st_table * +st_init_table_with_params_and_arg( + st_compare_arg_t compare, + st_hash_arg_t hash, + void const * arg, + int size, + int density, + double growth_factor, + int reorder_flag) +{ + st_table *table; + + table = st_init_table_with_params((st_compare_t) 0, (st_hash_t) 0, size, + density, growth_factor, reorder_flag); + if (table == NIL(st_table)) + return NIL(st_table); + table->compare_arg = compare; + table->hash_arg = hash; + table->arg = arg; + + return table; + +} /* st_init_table_with_params_and_arg */ + + +/** + @brief Creates and initializes a table. + + @details Like st_init_table, but the comparison and hash functions are + passed an extra parameter `arg` that is registered in the table at + initialization. + + @see st_init_table st_init_table_with_params_and_arg +*/ +st_table * +st_init_table_with_arg( + st_compare_arg_t compare, + st_hash_arg_t hash, + void const * arg) +{ + return st_init_table_with_params_and_arg(compare, hash, arg, + ST_DEFAULT_INIT_TABLE_SIZE, + ST_DEFAULT_MAX_DENSITY, + ST_DEFAULT_GROW_FACTOR, + ST_DEFAULT_REORDER_FLAG); + +} /* st_init_table_with_arg */ + + +/** + @brief Free a table. + + @details Any internal storage associated with table is freed. It is + the user's responsibility to free any storage associated with the + pointers he placed in the table (by perhaps using st_foreach). + + @sideeffect None + + @see st_init_table st_init_table_with_params + +*/ +void +st_free_table(st_table *table) +{ + st_table_entry *ptr, *next; + int i; + + for(i = 0; i < table->num_bins ; i++) { + ptr = table->bins[i]; + while (ptr != NIL(st_table_entry)) { + next = ptr->next; + FREE(ptr); + ptr = next; + } + } + FREE(table->bins); + FREE(table); + +} /* st_free_table */ + + +/** + @brief Lookup up `key` in `table`. + + @details If an entry is found, 1 is returned and if `value` is not + nil, the variable it points to is set to the associated value. If + an entry is not found, 0 is returned and the variable pointed by + value is unchanged. + + @sideeffect The location pointed by value is modified. + + @see st_lookup_int + +*/ +int +st_lookup(st_table *table, void const *key, void **value) +{ + int hash_val; + st_table_entry *ptr, **last; + + hash_val = do_hash(key, table); + + FIND_ENTRY(table, hash_val, key, ptr, last); + + if (ptr == NIL(st_table_entry)) { + return 0; + } else { + if (value != NIL(void *)) { + *value = ptr->record; + } + return 1; + } + +} /* st_lookup */ + + +/** + @brief Lookup up `key` in `table`. + + @details If an entry is found, 1 is returned and if `value` is not + nil, the variable it points to is set to the associated integer + value. If an entry is not found, 0 is return and the variable + pointed by `value` is unchanged. + + @sideeffect The location pointed by value is modified. + + @see st_lookup + +*/ +int +st_lookup_int(st_table *table, void const *key, int *value) +{ + int hash_val; + st_table_entry *ptr, **last; + + hash_val = do_hash(key, table); + + FIND_ENTRY(table, hash_val, key, ptr, last); + + if (ptr == NIL(st_table_entry)) { + return 0; + } else { + if (value != NIL(int)) { + *value = (int) (intptr_t) ptr->record; + } + return 1; + } + +} /* st_lookup_int */ + + +/** + @brief Insert value in `table` under the key `key`. + + @return 1 if there was an entry already under the key; 0 if there + was no entry under the key and insertion was successful; + ST_OUT_OF_MEM otherwise. In either of the first two cases the new + value is added. + + @sideeffect None + +*/ +int +st_insert(st_table *table, void *key, void *value) +{ + int hash_val; + st_table_entry *newt; + st_table_entry *ptr, **last; + + hash_val = do_hash(key, table); + + FIND_ENTRY(table, hash_val, key, ptr, last); + + if (ptr == NIL(st_table_entry)) { + if (table->num_entries/table->num_bins >= table->max_density) { + if (rehash(table) == ST_OUT_OF_MEM) { + return ST_OUT_OF_MEM; + } + hash_val = do_hash(key, table); + } + newt = ALLOC(st_table_entry, 1); + if (newt == NIL(st_table_entry)) { + return ST_OUT_OF_MEM; + } + newt->key = key; + newt->record = value; + newt->next = table->bins[hash_val]; + table->bins[hash_val] = newt; + table->num_entries++; + return 0; + } else { + ptr->record = value; + return 1; + } + +} /* st_insert */ + + +/** + @brief Place 'value' in 'table' under the key 'key'. + + @details This is done without checking if 'key' is in 'table' + already. This should only be used if you are sure there is not + already an entry for 'key', since it is undefined which entry you + would later get from st_lookup or st_find_or_add. + + @return 1 if successful; ST_OUT_OF_MEM otherwise. + + @sideeffect None + + @see st_lookup st_find_or_add + +*/ +int +st_add_direct(st_table *table, void *key, void *value) +{ + int hash_val; + st_table_entry *newt; + + if (table->num_entries / table->num_bins >= table->max_density) { + if (rehash(table) == ST_OUT_OF_MEM) { + return ST_OUT_OF_MEM; + } + } + hash_val = do_hash(key, table); + newt = ALLOC(st_table_entry, 1); + if (newt == NIL(st_table_entry)) { + return ST_OUT_OF_MEM; + } + newt->key = key; + newt->record = value; + newt->next = table->bins[hash_val]; + table->bins[hash_val] = newt; + table->num_entries++; + return 1; + +} /* st_add_direct */ + + +/** + @brief Lookup `key` in `table`; if not found, create an entry. + + @details In either case set slot to point to the field in the entry + where the value is stored. The value associated with `key` may then + be changed by accessing directly through slot. As an example: + + void **slot; + void *key; + void *value = item_ptr // ptr to a malloc'd structure + + if (st_find_or_add(table, key, &slot) == 1) { + FREE(*slot); // free the old value of the record + } + *slot = value; // attach the new value to the record + + This replaces the equivelent code: + + if (st_lookup(table, key, &ovalue) == 1) { + FREE(ovalue); + } + st_insert(table, key, value); + + @return 1 if an entry already existed, 0 if it did not exist and + creation was successful; ST_OUT_OF_MEM otherwise. + + @sideeffect The location pointed by slot is modified. + + @see st_find + +*/ +int +st_find_or_add(st_table *table, void *key, void ***slot) +{ + int hash_val; + st_table_entry *newt, *ptr, **last; + + hash_val = do_hash(key, table); + + FIND_ENTRY(table, hash_val, key, ptr, last); + + if (ptr == NIL(st_table_entry)) { + if (table->num_entries / table->num_bins >= table->max_density) { + if (rehash(table) == ST_OUT_OF_MEM) { + return ST_OUT_OF_MEM; + } + hash_val = do_hash(key, table); + } + newt = ALLOC(st_table_entry, 1); + if (newt == NIL(st_table_entry)) { + return ST_OUT_OF_MEM; + } + newt->key = key; + newt->record = NIL(void); + newt->next = table->bins[hash_val]; + table->bins[hash_val] = newt; + table->num_entries++; + if (slot != NIL(void **)) *slot = &newt->record; + return 0; + } else { + if (slot != NIL(void **)) *slot = &ptr->record; + return 1; + } + +} /* st_find_or_add */ + + +/** + @brief Lookup `key` in `table`. + + @details Like st_find_or_add, but does not create an entry if one is + not found. + + @sideeffect The location pointed by slot is modified. + + @see st_find_or_add + +*/ +int +st_find(st_table *table, void const *key, void ***slot) +{ + int hash_val; + st_table_entry *ptr, **last; + + hash_val = do_hash(key, table); + + FIND_ENTRY(table, hash_val, key, ptr, last); + + if (ptr == NIL(st_table_entry)) { + return 0; + } else { + if (slot != NIL(void **)) { + *slot = &ptr->record; + } + return 1; + } + +} /* st_find */ + + +/** + @brief Returns a copy of old_table and all its members. + + @details (st_table *) 0 is returned if there was insufficient memory + to do the copy. + + @sideeffect None + +*/ +st_table * +st_copy +(st_table const *old_table) +{ + st_table *new_table; + st_table_entry *ptr, *newptr, *next, *newt; + int i, j, num_bins = old_table->num_bins; + + new_table = ALLOC(st_table, 1); + if (new_table == NIL(st_table)) { + return NIL(st_table); + } + + *new_table = *old_table; + new_table->bins = ALLOC(st_table_entry *, num_bins); + if (new_table->bins == NIL(st_table_entry *)) { + FREE(new_table); + return NIL(st_table); + } + for(i = 0; i < num_bins ; i++) { + new_table->bins[i] = NIL(st_table_entry); + ptr = old_table->bins[i]; + while (ptr != NIL(st_table_entry)) { + newt = ALLOC(st_table_entry, 1); + if (newt == NIL(st_table_entry)) { + for (j = 0; j <= i; j++) { + newptr = new_table->bins[j]; + while (newptr != NIL(st_table_entry)) { + next = newptr->next; + FREE(newptr); + newptr = next; + } + } + FREE(new_table->bins); + FREE(new_table); + return NIL(st_table); + } + *newt = *ptr; + newt->next = new_table->bins[i]; + new_table->bins[i] = newt; + ptr = ptr->next; + } + } + return new_table; + +} /* st_copy */ + + +/** + @brief Deletes the entry with the key pointed to by `keyp`. + + @details If the entry is found, 1 is returned, the variable pointed + by `keyp` is set to the actual key and the variable pointed by + `value` is set to the corresponding entry. (This allows the freeing + of the associated storage.) If the entry is not found, then 0 is + returned and nothing is changed. + + @sideeffect The locations pointed by keyp and value are modified. + + @see st_delete_int + +*/ +int +st_delete(st_table *table, void **keyp, void **value) +{ + int hash_val; + void *key = *keyp; + st_table_entry *ptr, **last; + + hash_val = do_hash(key, table); + + FIND_ENTRY(table, hash_val, key, ptr ,last); + + if (ptr == NIL(st_table_entry)) { + return 0; + } + + *last = ptr->next; + if (value != NIL(void *)) *value = ptr->record; + *keyp = ptr->key; + FREE(ptr); + table->num_entries--; + return 1; + +} /* st_delete */ + + +/** + @brief Deletes the entry with the key pointed to by `keyp`. + + @details `value` must be a pointer to an integer. If the entry is + found, 1 is returned, the variable pointed by `keyp` is set to the + actual key and the variable pointed by `value` is set to the + corresponding entry. (This allows the freeing of the associated + storage.) If the entry is not found, then 0 is returned and nothing + is changed. + + @sideeffect The locations pointed by keyp and value are modified. + + @see st_delete + +*/ +int +st_delete_int(st_table *table, void **keyp, int *value) +{ + int hash_val; + void *key = *keyp; + st_table_entry *ptr, **last; + + hash_val = do_hash(key, table); + + FIND_ENTRY(table, hash_val, key, ptr ,last); + + if (ptr == NIL(st_table_entry)) { + return 0; + } + + *last = ptr->next; + if (value != NIL(int)) *value = (int) (intptr_t) ptr->record; + *keyp = ptr->key; + FREE(ptr); + table->num_entries--; + return 1; + +} /* st_delete_int */ + + +/** + @brief Returns the number of entries in the table `table`. + + @sideeffect None + +*/ +int st_count(st_table const *table) +{ + return table->num_entries; +} + + +/** + @brief Iterates over the elements of a table. + + @details + For each (key, value) record in `table`, st_foreach + calls func with the arguments + + (*func)(key, value, arg) + + If func returns ST_CONTINUE, st_foreach continues + processing entries. If func returns ST_STOP, st_foreach stops + processing and returns immediately. If func returns ST_DELETE, then + the entry is deleted from the symbol table and st_foreach continues. + In the case of ST_DELETE, it is func's responsibility to free the + key and value, if necessary. The order in which the records are + visited will be seemingly random. + + @return 1 if all items in the table were generated and 0 if the + generation sequence was aborted using ST_STOP. + + @sideeffect None + + @see st_foreach_item st_foreach_item_int + +*/ +int +st_foreach(st_table *table, st_foreach_t func, void *arg) +{ + st_table_entry *ptr, **last; + enum st_retval retval; + int i; + + for(i = 0; i < table->num_bins; i++) { + last = &table->bins[i]; ptr = *last; + while (ptr != NIL(st_table_entry)) { + retval = (*func)(ptr->key, ptr->record, arg); + switch (retval) { + case ST_CONTINUE: + last = &ptr->next; ptr = *last; + break; + case ST_STOP: + return 0; + case ST_DELETE: + *last = ptr->next; + table->num_entries--; /* cstevens@ic */ + FREE(ptr); + ptr = *last; + } + } + } + return 1; + +} /* st_foreach */ + + +/** + @brief String hash function. + + @sideeffect None + + @see st_init_table + +*/ +int +st_strhash(void const *string, int modulus) +{ + int val = 0; + int c; + char const * s = (char const *) string; + + while ((c = *s++) != '\0') { + val = val*997 + c; + } + + return ((val < 0) ? -val : val)%modulus; + +} /* st_strhash */ + + +/** + @brief Integral number hash function. + + @sideeffect None + + @see st_init_table st_numcmp + +*/ +int +st_numhash(void const *x, int size) +{ + return ST_NUMHASH(x, size); + +} /* st_numhash */ + + +/** + @brief Pointer hash function. + + @sideeffect None + + @see st_init_table st_ptrcmp + +*/ +int +st_ptrhash(void const *x, int size) +{ + return ST_PTRHASH(x, size); + +} /* st_ptrhash */ + + +/** + @brief Integral number comparison function. + + @sideeffect None + + @see st_init_table st_numhash + +*/ +int +st_numcmp(void const *x, void const *y) +{ + return ST_NUMCMP(x, y); + +} /* st_numcmp */ + + +/** + @brief Pointer comparison function. + + @sideeffect None + + @see st_init_table st_ptrhash + +*/ +int +st_ptrcmp(void const *x, void const *y) +{ + return ST_NUMCMP(x, y); + +} /* st_ptrcmp */ + + +/** + @brief Initializes a generator. + + @details Returns a generator handle which when used with + st_gen() will progressively return each (key, value) record in + `table`. + + @sideeffect None + + @see st_free_gen + +*/ +st_generator * +st_init_gen(st_table const *table) +{ + st_generator *gen; + + gen = ALLOC(st_generator, 1); + if (gen == NIL(st_generator)) { + return NIL(st_generator); + } + gen->table = table; + gen->entry = NIL(st_table_entry); + gen->index = 0; + return gen; + +} /* st_init_gen */ + + +/** + @brief Returns the next (key, value) pair in the generation sequence. + + @details@parblock + Given a generator returned by st_init_gen(), this + routine returns the next (key, value) pair in the generation + sequence. The pointer `value_p` can be zero which means no value + will be returned. When there are no more items in the generation + sequence, the routine returns 0. + + While using a generation sequence, deleting any (key, value) pair + other than the one just generated may cause a fatal error when + st_gen() is called later in the sequence and is therefore not + recommended. + @endparblock + + @sideeffect The locations pointed by key_p and value_p are modified. + + @see st_gen_int + +*/ +int +st_gen(st_generator *gen, void **key_p, void **value_p) +{ + int i; + + if (gen->entry == NIL(st_table_entry)) { + /* try to find next entry */ + for(i = gen->index; i < gen->table->num_bins; i++) { + if (gen->table->bins[i] != NIL(st_table_entry)) { + gen->index = i+1; + gen->entry = gen->table->bins[i]; + break; + } + } + if (gen->entry == NIL(st_table_entry)) { + return 0; /* that's all folks ! */ + } + } + *key_p = gen->entry->key; + if (value_p != NIL(void *)) { + *value_p = gen->entry->record; + } + gen->entry = gen->entry->next; + return 1; + +} /* st_gen */ + + +/** + @brief Returns the next (key, value) pair in the generation + sequence. + + @details Given a generator returned by st_init_gen(), this + routine returns the next (key, value) pair in the generation + sequence. `value_p` must be a pointer to an integer. The pointer + `value_p` can be zero which means no value will be returned. When + there are no more items in the generation sequence, the routine + returns 0. + + @sideeffect The locations pointed by key_p and value_p are modified. + + @see st_gen + +*/ +int +st_gen_int(st_generator *gen, void **key_p, int *value_p) +{ + int i; + + if (gen->entry == NIL(st_table_entry)) { + /* try to find next entry */ + for(i = gen->index; i < gen->table->num_bins; i++) { + if (gen->table->bins[i] != NIL(st_table_entry)) { + gen->index = i+1; + gen->entry = gen->table->bins[i]; + break; + } + } + if (gen->entry == NIL(st_table_entry)) { + return 0; /* that's all folks ! */ + } + } + *key_p = gen->entry->key; + if (value_p != NIL(int)) { + *value_p = (int) (intptr_t) gen->entry->record; + } + gen->entry = gen->entry->next; + return 1; + +} /* st_gen_int */ + + +/** + @brief Reclaims the resources associated with `gen`. + + @details After generating all items in a generation sequence, + this routine must be called to reclaim the resources associated with + `gen`. + + @sideeffect None + + @see st_init_gen + +*/ +void +st_free_gen(st_generator *gen) +{ + FREE(gen); + +} /* st_free_gen */ + + +/*---------------------------------------------------------------------------*/ +/* Definition of internal functions */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Definition of static functions */ +/*---------------------------------------------------------------------------*/ + +/** + @brief Rehashes a symbol table. + + @sideeffect None + + @see st_insert + +*/ +static int +rehash(st_table *table) +{ + st_table_entry *ptr, *next, **old_bins; + int i, old_num_bins, hash_val, old_num_entries; + + /* save old values */ + old_bins = table->bins; + old_num_bins = table->num_bins; + old_num_entries = table->num_entries; + + /* rehash */ + table->num_bins = (int) (table->grow_factor * old_num_bins); + if (table->num_bins % 2 == 0) { + table->num_bins += 1; + } + table->num_entries = 0; + table->bins = ALLOC(st_table_entry *, table->num_bins); + if (table->bins == NIL(st_table_entry *)) { + table->bins = old_bins; + table->num_bins = old_num_bins; + table->num_entries = old_num_entries; + return ST_OUT_OF_MEM; + } + /* initialize */ + for (i = 0; i < table->num_bins; i++) { + table->bins[i] = 0; + } + + /* copy data over */ + for (i = 0; i < old_num_bins; i++) { + ptr = old_bins[i]; + while (ptr != NIL(st_table_entry)) { + next = ptr->next; + hash_val = do_hash(ptr->key, table); + ptr->next = table->bins[hash_val]; + table->bins[hash_val] = ptr; + table->num_entries++; + ptr = next; + } + } + FREE(old_bins); + + return 1; + +} /* rehash */ diff --git a/resources/3rdparty/cudd-3.0.0/st/st.h b/resources/3rdparty/cudd-3.0.0/st/st.h new file mode 100644 index 000000000..89b21a840 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/st/st.h @@ -0,0 +1,269 @@ +/** + @file + + @ingroup st + + @brief Symbol table package. + + @details The st library provides functions to create, maintain, + and query symbol tables. + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#ifndef ST_H_ +#define ST_H_ + +/*---------------------------------------------------------------------------*/ +/* Nested includes */ +/*---------------------------------------------------------------------------*/ + +/*---------------------------------------------------------------------------*/ +/* Constant declarations */ +/*---------------------------------------------------------------------------*/ + +/** + * @brief Value returned if memory is exhausted. + */ +#define ST_OUT_OF_MEM -10000 + +/** + * @brief Default value for the maximum table density. + * @see st_init_table_with_params + */ +#define ST_DEFAULT_MAX_DENSITY 5 + +/** + * @brief Default value for the initial table size. + * @see st_init_table_with_params + */ +#define ST_DEFAULT_INIT_TABLE_SIZE 11 + +/** + * @brief Default table growth factor. + * @see st_init_table_with_params + */ +#define ST_DEFAULT_GROW_FACTOR 2.0 + +/** + * @brief Default table reorder flag. + * @see st_init_table_with_params + */ +#define ST_DEFAULT_REORDER_FLAG 0 + +/*---------------------------------------------------------------------------*/ +/* Stucture declarations */ +/*---------------------------------------------------------------------------*/ + + +/*---------------------------------------------------------------------------*/ +/* Type declarations */ +/*---------------------------------------------------------------------------*/ + +/** + * @brief Type of symbol tables. + */ +typedef struct st_table st_table; + +/** + * @brief Type of symbol table generators. + */ +typedef struct st_generator st_generator; + +/** + * @brief Type of return values for iterators. + */ +enum st_retval {ST_CONTINUE, ST_STOP, ST_DELETE}; + +/** + * @brief Type for function passed to @ref st_foreach. + */ +typedef enum st_retval (*st_foreach_t)(void *, void *, void *); + +/** + * @brief Type of comparison functions. + */ +typedef int (*st_compare_t)(void const *, void const *); + +/** + * @brief Type of hash functions. + */ +typedef int (*st_hash_t)(void const *, int); + +/** + * @brief Type of comparison functions with extra argument. + */ +typedef int (*st_compare_arg_t)(void const *, void const *, void const *); + +/** + * @brief Type of hash functions with extra argument. + */ +typedef int (*st_hash_arg_t)(void const *, int, void const *); + +/*---------------------------------------------------------------------------*/ +/* Variable declarations */ +/*---------------------------------------------------------------------------*/ + + +/*---------------------------------------------------------------------------*/ +/* Macro declarations */ +/*---------------------------------------------------------------------------*/ + +/** + @brief Checks whethere `key` is in `table`. + + @details Returns 1 if there is an entry under `key` in `table`, 0 + otherwise. + + @sideeffect None + + @see st_lookup + +*/ +#define st_is_member(table,key) st_lookup(table,key,(void **) 0) + + +/** + @brief Iteration macro. + + @details + An iteration macro which loops over all the entries in + `table`, setting `key` to point to the key and `value` to the + associated value (if it is not nil). `gen` is a generator variable + used internally. Sample usage: + + void *key, *value; + st_generator *gen; + + st_foreach_item(table, gen, &key, &value) { + process_item(value); + } + + @sideeffect None + + @see st_foreach_item_int st_foreach + +*/ +#define st_foreach_item(table, gen, key, value) \ + for(gen=st_init_gen(table); st_gen(gen,key,value) || (st_free_gen(gen),0);) + + +/** + @brief Iteration macro. + + @details + An iteration macro which loops over all the entries in + `table`, setting `key` to point to the key and `value` to the + associated value (if it is not nil). `value` is assumed to be a + pointer to an integer. `gen` is a generator variable used + internally. Sample usage: + + void *key; + int value; + st_generator *gen; + + st_foreach_item_int(table, gen, &key, &value) { + process_item(value); + } + + @sideeffect None + + @see st_foreach_item st_foreach + +*/ +#define st_foreach_item_int(table, gen, key, value) \ + for(gen=st_init_gen(table); st_gen_int(gen,key,value) || (st_free_gen(gen),0);) + +/*---------------------------------------------------------------------------*/ +/* Function prototypes */ +/*---------------------------------------------------------------------------*/ + +#ifdef __cplusplus +extern "C" { +#endif + +st_table *st_init_table_with_params (st_compare_t, st_hash_t, int, int, double, int); +st_table *st_init_table (st_compare_t, st_hash_t); +st_table *st_init_table_with_params_and_arg (st_compare_arg_t, st_hash_arg_t, void const *, int, int, double, int); + st_table *st_init_table_with_arg (st_compare_arg_t, st_hash_arg_t, void const *); +void st_free_table (st_table *); +int st_lookup (st_table *, void const *, void **); +int st_lookup_int (st_table *, void const *, int *); +int st_insert (st_table *, void *, void *); +int st_add_direct (st_table *, void *, void *); +int st_find_or_add (st_table *, void *, void ***); +int st_find (st_table *, void const *, void ***); +st_table *st_copy (st_table const *); +int st_delete (st_table *, void **, void **); +int st_delete_int (st_table *, void **, int *); +int st_count(st_table const *); +int st_foreach (st_table *, st_foreach_t, void *); +int st_strhash (void const *, int); +int st_numhash (void const *, int); +int st_ptrhash (void const *, int); +int st_numcmp (void const *, void const *); +int st_ptrcmp (void const *, void const *); +st_generator *st_init_gen (st_table const *); +int st_gen (st_generator *, void **, void **); +int st_gen_int (st_generator *, void **, int *); +void st_free_gen (st_generator *); + +#ifdef __cplusplus +} /* end of extern "C" */ +#endif + +#endif /* ST_H_ */ diff --git a/resources/3rdparty/cudd-3.0.0/st/test_st.test.in b/resources/3rdparty/cudd-3.0.0/st/test_st.test.in new file mode 100644 index 000000000..0b08afc97 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/st/test_st.test.in @@ -0,0 +1,8 @@ +#! /bin/sh + +EXE=@EXEEXT@ +srcdir=@srcdir@ + +st/testst$EXE + +exit 0 diff --git a/resources/3rdparty/cudd-3.0.0/st/testst.c b/resources/3rdparty/cudd-3.0.0/st/testst.c new file mode 100644 index 000000000..31ee0fa59 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/st/testst.c @@ -0,0 +1,375 @@ +/** + @file + + @ingroup st + + @brief Simple test program of the st library. + + @copyright@parblock + Copyright (c) 2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" +#include "st.h" + +/** + @brief Just some struct type. +*/ +typedef struct mys { + double a; + int b; + int c; +} mys_t; + + +/** \cond */ + +static int testString(void); +static int testStruct(void); +static int testUintPtr(void); +static int testInt(void); +static int testArg(void); +static int mys_cmp(void const * key1, void const * key2); +static int mys_hash(void const * key, int size); +static enum st_retval mys_accm(void * key, void * value, void * arg); +static int array_hash(void const * key, int modulus, void const * arg); +static int array_cmp(void const * key1, void const * key2, void const *arg); + +/** \endcond */ + +/** + @brief Main program. + + @return the number of failed tests. + + @details Uses TAP (Test Anything Protocol) to report results. +*/ +int +main(void) +{ + int ret = 0; + printf("TAP version 13\n1..5\n"); + + if (testString() != 0) { + ret++; + printf("not "); + } + printf("ok 1 string table\n"); + + if (testStruct() != 0) { + ret++; + printf("not "); + } + printf("ok 2 struct-to-uintptr_t map\n"); + + if (testUintPtr() != 0) { + ret++; + printf("not "); + } + printf("ok 3 uintptr_t-to-string map\n"); + + if (testInt() != 0) { + ret++; + printf("not "); + } + printf("ok 4 int-to-int map\n"); + + if (testArg() != 0) { + ret++; + printf("not "); + } + printf("ok 5 table with arg\n"); + + return ret; +} + + +/** + @brief Tests a table that stores C strings. + + @return 0 if successful; the number of errors otherwise. +*/ +static int +testString(void) +{ + int error = 0; + char foo[] = "foo"; + char *cp = foo; + char bar[] = "bar"; + char foobar[] = "foobar"; + st_table * tbl = st_init_table((st_compare_t) strcmp, st_strhash); + if (!tbl) + error++; + if (st_insert(tbl, foo, NULL) != 0) + error++; + if (st_insert(tbl, bar, NULL) != 0) + error++; + if (st_insert(tbl, foobar, NULL) != 0) + error++; + if (!st_is_member(tbl, "foo")) + error++; + if (!st_delete(tbl, (void **) &cp, NULL)) + error++; + if (st_count(tbl) != 2) + error++; + if (st_insert(tbl, bar, NULL) != 1) + error++; + st_free_table(tbl); + return error; +} + + +/** + @brief Tests a table that maps user-defined structs to uintptr_t. + + @return 0 if successful; the number of errors otherwise. +*/ +static int +testStruct(void) +{ + int error = 0; + mys_t m1 = {3.5, 4, 11}; + mys_t m2 = {6.7, 5, -2}; + uintptr_t u; + st_table * tbl = st_init_table(mys_cmp, mys_hash); + if (!tbl) + error++; + if (st_insert(tbl, &m1, (void *)(uintptr_t) 2) != 0) + error++; + if (st_insert(tbl, &m2, (void *)(uintptr_t) 5) != 0) + error++; + if (st_lookup(tbl, &m1, (void **) &u) != 1) + error++; + if (u != 2) + error++; + u = 0; + if (st_foreach(tbl, mys_accm, &u) != 1) + error++; + if (u != 7) + error++; + st_free_table(tbl); + return error; +} + + +/** + @brief Tests a table that maps values of type uintptr_t to strings. + + @return 0 if successful; the number of errors otherwise. +*/ +static int +testUintPtr(void) +{ + int error = 0; + char foo[] = "foo"; + char * cp; + st_table * tbl = st_init_table(st_numcmp, st_numhash); + if (!tbl) + error++; + if (st_insert(tbl, (void *)(uintptr_t) 2, foo) != 0) + error++; + if (st_lookup(tbl, (void *)(uintptr_t) 2, (void **) &cp) != 1) + error++; + if (strcmp(cp, "foo") != 0) + error++; + if (st_is_member(tbl, (void *)(uintptr_t) 76)) + error++; + st_free_table(tbl); + return error; +} + + +/** + @brief Tests a table that maps ints to ints. + + @return 0 if successful; the number of errors otherwise. +*/ +static int +testInt(void) +{ + int error = 0; + int n1 = -2; + int n2; + void * e; + int i; + st_generator * gen; + st_table * tbl = st_init_table(st_numcmp, st_numhash); + if (!tbl) + error++; + if (st_insert(tbl, (void *)(intptr_t) n1, (void *)(intptr_t) 3) != 0) + error++; + if (st_lookup_int(tbl, (void *)(intptr_t) n1, &n2) != 1) + error++; + if (n2 != 3) + error++; + e = (void *)(intptr_t) n1; + if (st_delete_int(tbl, &e, &n2) != 1) + error++; + if ((int)(intptr_t) e != n1 || n2 != 3) + error++; + if (st_count(tbl) != 0) + error++; + for (i = 0; i < 100000; i++) { + if (st_insert(tbl, (void *)(intptr_t) i, (void *)(intptr_t) i) != 0) + error++; + } + st_foreach_item_int(tbl, gen, &e, &n1) { + if ((int)(intptr_t) e != n1) + error++; + } + st_free_table(tbl); + return error; +} + + +/** + @brief Tests a table of arrays of ints. + + @return 0 if successful; 1 otherwise. +*/ +static int +testArg(void) +{ + size_t const n = 5; + int error = 0; + int a1[] = {0,1,2,3,4}; + int a2[] = {4,3,2,1,0}; + int *a3 = a1; + intptr_t val = 0; + st_table *tbl = st_init_table_with_arg(array_cmp, array_hash, (void *) n); + if (!tbl) + error++; + if (st_insert(tbl, a1, (void *)(intptr_t) 1) != 0) + error++; + if (st_insert(tbl, a2, (void *)(intptr_t) 2) != 0) + error++; + if (!st_is_member(tbl, a1)) + error++; + if (!st_delete(tbl, (void **) &a3, (void **) &val)) + error++; + if (a3[0] != a1[0] || val != 1) + error++; + if (st_is_member(tbl, a1)) + error++; + if (!st_is_member(tbl, a2)) + error++; + st_free_table(tbl); + return error; +} + + +/** + @brief Compares two items of type mys_t. + + @return 0 if they compare equal and 1 otherwise. +*/ +static int +mys_cmp(void const * key1, void const * key2) +{ + mys_t const *m1 = (mys_t const *) key1; + mys_t const *m2 = (mys_t const *) key2; + + return m1->b != m2->b || m1->c != m2->c; +} + + +/** + @brief Hashes one item of type mys_t. + + @return the hash value. +*/ +static int +mys_hash(void const * key, int size) +{ + mys_t const *m = (mys_t const *) key; + return (int)((((unsigned) m->b >> 4) ^ ((unsigned) m->c >> 5)) % size); +} + + +/** + @brief Accumulates the values associated to items of type mys_t. + + @return ST_CONTINUE +*/ +static enum st_retval +mys_accm(void * key, void * value, void * arg) +{ + (void) key; /* avoid warning */ + uintptr_t v = (uintptr_t) value; + uintptr_t * accum = (uintptr_t *) arg; + *accum += v; + return ST_CONTINUE; +} + + +/** + @brief Compares two arrays of ints. + + @details The length of the two arrays is in `arg`. + + @return 0 if they compare equal and 1 otherwise. +*/ +static int +array_cmp(void const * key1, void const * key2, void const *arg) +{ + int const *a1 = (int const *) key1; + int const *a2 = (int const *) key2; + size_t const size = (size_t const) arg; + size_t i; + for (i = 0; i < size; i++) { + if (a1[i] != a2[i]) + return 1; + } + return 0; +} + + +/** + @brief Hashes one array of ints. + + @return the hash value. +*/ +static int +array_hash(void const * key, int modulus, void const * arg) +{ + int const *a = (int const *) key; + size_t const size = (size_t const) arg; + int val = 0; + size_t i; + for (i = 0; i < size; i++) { + val = val * 997 + a[i]; + } + return ((val < 0) ? -val : val) % modulus; +} diff --git a/resources/3rdparty/cudd-3.0.0/util/Included.am b/resources/3rdparty/cudd-3.0.0/util/Included.am new file mode 100644 index 000000000..af34d5450 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/Included.am @@ -0,0 +1,9 @@ +cudd_libcudd_la_SOURCES += util/util.h util/cstringstream.h \ + util/cpu_stats.c util/cpu_time.c util/cstringstream.c util/datalimit.c \ + util/pathsearch.c util/pipefork.c util/prtime.c util/safe_mem.c \ + util/strsav.c util/texpand.c util/ucbqsort.c +if MINGW64 +if CROSS_COMPILING +cudd_libcudd_la_LIBADD = -lws2_32 -lpsapi +endif +endif diff --git a/resources/3rdparty/cudd-3.0.0/util/cpu_stats.c b/resources/3rdparty/cudd-3.0.0/util/cpu_stats.c new file mode 100644 index 000000000..56998253e --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/cpu_stats.c @@ -0,0 +1,239 @@ +/** + @file + + @ingroup util + + @brief CPU statistics. + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#define _BSD_SOURCE +#include "util.h" + +#if HAVE_SYS_TIME_H == 1 +#include <sys/time.h> +#endif +#if HAVE_SYS_RESOURCE_H == 1 +#include <sys/resource.h> +#endif + +#ifdef BSD +#if defined(_IBMR2) +#define etext _etext +#define edata _edata +#define end _end +#endif + +extern int end, etext, edata; + +#endif + +#ifdef _WIN32 +#include <winsock2.h> +#include <psapi.h> +#endif + +/** + @brief Prints CPU statistics. + + The amount of detail printed depends on the host operating system. + +*/ +void +util_print_cpu_stats(FILE *fp) +{ +#if HAVE_GETRUSAGE == 1 && HAVE_GETRLIMIT == 1 + struct rusage rusage; + double user, system, scale; + long text, data; + struct rlimit rlp; + long vm_limit, vm_soft_limit; + char hostname[257]; +#ifdef BSD + long vm_text, vm_init_data, vm_uninit_data, vm_sbrk_data; +#endif + + /* Get the hostname */ + (void) gethostname(hostname, sizeof(hostname)); + hostname[sizeof(hostname)-1] = '\0'; /* just in case */ + +#ifdef BSD + /* Get the virtual memory sizes */ + vm_text = (long) (((long) (&etext)) / 1024.0 + 0.5); + vm_init_data = (long) (((long) (&edata) - (long) (&etext)) / 1024.0 + 0.5); + vm_uninit_data = (long) (((long) (&end) - (long) (&edata)) / 1024.0 + 0.5); + vm_sbrk_data = (long) (((long) sbrk(0) - (long) (&end)) / 1024.0 + 0.5); +#endif + + /* Get virtual memory limits */ + (void) getrlimit(RLIMIT_DATA, &rlp); + vm_limit = (long) (rlp.rlim_max / 1024.0 + 0.5); + vm_soft_limit = (long) (rlp.rlim_cur / 1024.0 + 0.5); + + /* Get usage stats */ + (void) getrusage(RUSAGE_SELF, &rusage); + user = rusage.ru_utime.tv_sec + rusage.ru_utime.tv_usec * 1e-6; + system = rusage.ru_stime.tv_sec + rusage.ru_stime.tv_usec * 1e-6; + scale = (user + system)*100.0; + if (scale == 0.0) scale = 0.001; + text = (int) (rusage.ru_ixrss / scale + 0.5); + data = (int) ((rusage.ru_idrss + rusage.ru_isrss) / scale + 0.5); + +#elif defined(_WIN32) + char hostname[257]; + WSADATA wsaData; + FILETIME creationTime, exitTime, kernelTime, userTime; + double user, system; + MEMORYSTATUSEX statex; + size_t vm_limit; + PROCESS_MEMORY_COUNTERS pmc; + size_t peak_working_set; + long page_faults; + + /* Get the hostname */ + WSAStartup(MAKEWORD(2, 2), &wsaData); + (void) gethostname(hostname, sizeof(hostname)); + hostname[sizeof(hostname)-1] = '\0'; /* just in case */ + WSACleanup(); + + /* Get usage stats */ + if (GetProcessTimes(GetCurrentProcess(), &creationTime, &exitTime, + &kernelTime, &userTime)) { + ULARGE_INTEGER integerSystemTime, integerUserTime; + integerUserTime.u.LowPart = userTime.dwLowDateTime; + integerUserTime.u.HighPart = userTime.dwHighDateTime; + user = (double) integerUserTime.QuadPart * 1e-7; + integerSystemTime.u.LowPart = kernelTime.dwLowDateTime; + integerSystemTime.u.HighPart = kernelTime.dwHighDateTime; + system = (double) integerSystemTime.QuadPart * 1e-7; + } else { + user = system = 0.0; + } + statex.dwLength = sizeof(statex); + if (GlobalMemoryStatusEx(&statex)) { + vm_limit = (size_t) (statex.ullTotalVirtual / 1024.0 + 0.5); + } else { + vm_limit = 0; + } + if (GetProcessMemoryInfo(GetCurrentProcess(), &pmc, sizeof(pmc))) { + peak_working_set = (size_t) (pmc.PeakWorkingSetSize / 1024.0 + 0.5); + page_faults = (long) pmc.PageFaultCount; + } else { + peak_working_set = 0; + page_faults = 0; + } +#endif + +#if (HAVE_GETRUSAGE == 1 && HAVE_GETRLIMIT == 1) || defined(_WIN32) + (void) fprintf(fp, "Runtime Statistics\n"); + (void) fprintf(fp, "------------------\n"); + (void) fprintf(fp, "Machine name: %s\n", hostname); + (void) fprintf(fp, "User time %6.1f seconds\n", user); + (void) fprintf(fp, "System time %6.1f seconds\n\n", system); + +#if HAVE_GETRUSAGE == 1 && HAVE_GETRLIMIT == 1 + (void) fprintf(fp, "Average resident text size = %5ldK\n", text); + (void) fprintf(fp, "Average resident data+stack size = %5ldK\n", data); + (void) fprintf(fp, "Maximum resident size = %5ldK\n\n", + rusage.ru_maxrss); +#if defined(BSD) + (void) fprintf(fp, "Virtual text size = %5ldK\n", + vm_text); + (void) fprintf(fp, "Virtual data size = %5ldK\n", + vm_init_data + vm_uninit_data + vm_sbrk_data); + (void) fprintf(fp, " data size initialized = %5ldK\n", + vm_init_data); + (void) fprintf(fp, " data size uninitialized = %5ldK\n", + vm_uninit_data); + (void) fprintf(fp, " data size sbrk = %5ldK\n", + vm_sbrk_data); +#endif + (void) fprintf(fp, "Virtual memory limit = "); + if (rlp.rlim_cur == RLIM_INFINITY) + (void) fprintf(fp, "unlimited"); + else + (void) fprintf(fp, "%5ldK", vm_soft_limit); + if (rlp.rlim_max == RLIM_INFINITY) + (void) fprintf(fp, " (unlimited)\n"); + else + (void) fprintf(fp, " (%ldK)\n\n", vm_limit); + + (void) fprintf(fp, "Major page faults = %ld\n", rusage.ru_majflt); + (void) fprintf(fp, "Minor page faults = %ld\n", rusage.ru_minflt); + (void) fprintf(fp, "Swaps = %ld\n", rusage.ru_nswap); + (void) fprintf(fp, "Input blocks = %ld\n", rusage.ru_inblock); + (void) fprintf(fp, "Output blocks = %ld\n", rusage.ru_oublock); + (void) fprintf(fp, "Context switch (voluntary) = %ld\n", rusage.ru_nvcsw); + (void) fprintf(fp, "Context switch (involuntary) = %ld\n", rusage.ru_nivcsw); +#else + (void) fprintf(fp, "Maximum resident size = "); + if (peak_working_set == 0) + (void) fprintf(fp, "unavailable\n"); + else + (void) fprintf(fp, "%" PRIszt "K\n", peak_working_set); + (void) fprintf(fp, "Virtual memory limit = "); + if (vm_limit == 0) + (void) fprintf(fp, "unavailable\n"); + else + (void) fprintf(fp, "%5" PRIszt "K\n", vm_limit); + (void) fprintf(fp, "Page faults = %ld\n", page_faults); +#endif +#else + (void) fprintf(fp, "Usage statistics not available\n"); +#endif +} diff --git a/resources/3rdparty/cudd-3.0.0/util/cpu_time.c b/resources/3rdparty/cudd-3.0.0/util/cpu_time.c new file mode 100644 index 000000000..337155140 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/cpu_time.c @@ -0,0 +1,136 @@ +/** + @file + + @ingroup util + + @brief System time calls + + @details Provide a uniform interface across different operating systems. + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" + +#if HAVE_SYS_TIMES_H == 1 +#include <sys/times.h> +#endif + +#ifdef _WIN32 +#include <windows.h> +#endif + +/** + * @brief returns a long which represents the elapsed processor + * time in milliseconds since some constant reference. + */ +long +util_cpu_time(void) +{ +#if HAVE_SYSCONF == 1 + + /* Code for POSIX systems */ + + struct tms buffer; + long nticks; /* number of clock ticks per second */ + + nticks = sysconf(_SC_CLK_TCK); + times(&buffer); + return (long) ((buffer.tms_utime + buffer.tms_stime) * (1000.0/nticks)); + +#elif defined(_WIN32) + FILETIME creationTime, exitTime, kernelTime, userTime; + if (GetProcessTimes(GetCurrentProcess(), &creationTime, &exitTime, + &kernelTime, &userTime)) { + ULARGE_INTEGER integerTime; + integerTime.u.LowPart = userTime.dwLowDateTime; + integerTime.u.HighPart = userTime.dwHighDateTime; + return (long) (integerTime.QuadPart / 10000); + } else { + return 0; + } +#else + return 0L; +#endif + +} + +/** + * @brief returns a long which represents the elapsed processor + * time in milliseconds since some constant reference. It includes + * waited-for terminated children. + */ +long +util_cpu_ctime(void) +{ +#if HAVE_SYSCONF == 1 + + /* Code for POSIX systems */ + + struct tms buffer; + long nticks; /* number of clock ticks per second */ + + nticks = sysconf(_SC_CLK_TCK); + times(&buffer); + return (long) ((buffer.tms_utime + buffer.tms_cutime) * (1000.0/nticks)); + +#else + return 0L; +#endif + +} + diff --git a/resources/3rdparty/cudd-3.0.0/util/cstringstream.c b/resources/3rdparty/cudd-3.0.0/util/cstringstream.c new file mode 100644 index 000000000..9af649b3a --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/cstringstream.c @@ -0,0 +1,195 @@ +/** + @file + + @ingroup cstringstream + + @brief Simple string streams in C. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 2014-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include <stdio.h> +#include <stdlib.h> +#include <string.h> +#include "cstringstream.h" + +/** + * @brief Type of a simple extensible string buffer. + */ +struct _cstringstream { + size_t capacity; /**< elements allocated */ + size_t inUse; /**< elements currently in use */ + char * data; /**< actual data */ +}; + +cstringstream newStringStream(void) { + cstringstream ss; + ss = (cstringstream) malloc(sizeof(struct _cstringstream)); + if (!ss) return NULL; + ss->capacity = 1; /* parsimonious */ + ss->inUse = 0; + ss->data = (char *) malloc(sizeof(char) * ss->capacity); + if (!ss->data) { + free(ss); + return NULL; + } + return ss; +} + +void deleteStringStream(cstringstream ss) { + if (ss) { + free(ss->data); + free(ss); + } +} + +int clearStringStream(cstringstream ss) { + if (!ss) return -1; + ss->inUse = 0; + return 0; +} + +cstringstream copyStringStream(const_cstringstream src) { + cstringstream dest; + if (!src) return 0; + dest = newStringStream(); + if (!dest) return 0; + if (resizeStringStream(dest, src->inUse)) { + deleteStringStream(dest); + return 0; + } + strncpy(dest->data, src->data, src->inUse); + return dest; +} + +int resizeStringStream(cstringstream ss, size_t newSize) { + if (newSize > ss->capacity) { + /* To avoid too many calls to realloc, we choose the larger of + * twice the current size and the new requested size. */ + size_t newCapacity = 2 * ss->capacity; + if (newCapacity < newSize) + newCapacity = newSize; + char * tmp = (char *) realloc(ss->data, newCapacity * sizeof(char)); + /* If the allocation fails, leave the array alone. */ + if (!tmp) return -1; + ss->data = tmp; + ss->capacity = newCapacity; + } + /* Here we are guaranteed that newSize <= ss->capacity. */ + ss->inUse = newSize; + return 0; +} + +int sizeStringStream(const_cstringstream ss, size_t * num) { + if (!ss || !num) return -1; + *num = ss->inUse; + return 0; +} + +int getStringStream(const_cstringstream ss, size_t index, char * c) { + if (!ss || !c || index >= ss->inUse) return -1; + *c = ss->data[index]; + return 0; +} + +int appendCharStringStream(cstringstream ss, char c) { + if (!ss) return -1; + if (resizeStringStream(ss, ss->inUse + 1)) return -1; + /* Now we have space. */ + ss->data[ss->inUse-1] = c; + return 0; +} + +int appendStringStringStream(cstringstream ss, char const * s) { + if (!ss) return -1; + size_t len = strlen(s); + if (resizeStringStream(ss, ss->inUse + len)) return -1; + /* Now we have space. */ + strncpy(ss->data + ss->inUse - len, s, len); + return 0; +} + +int appendIntStringStream(cstringstream ss, int d) { + char str[256]; + if (!ss) return -1; + sprintf(str, "%d", d); + return appendStringStringStream(ss, str); +} + +int appendUnsignedStringStream(cstringstream ss, unsigned u) { + char str[256]; + if (!ss) return -1; + sprintf(str, "%u", u); + return appendStringStringStream(ss, str); +} + +int appendLongStringStream(cstringstream ss, long ld) { + char str[256]; + if (!ss) return -1; + sprintf(str, "%ld", ld); + return appendStringStringStream(ss, str); +} + +int appendUnsignedLongStringStream(cstringstream ss, unsigned long lu) { + char str[256]; + if (!ss) return -1; + sprintf(str, "%lu", lu); + return appendStringStringStream(ss, str); +} + +int appendDoubleStringStream(cstringstream ss, double g) { + char str[256]; + if (!ss) return -1; + sprintf(str, "%g", g); + return appendStringStringStream(ss, str); +} + +int putStringStream(cstringstream ss, size_t index, char c) { + if (!ss || index >= ss->inUse) return -1; + ss->data[index] = c; + return 0; +} + +char * stringFromStringStream(const_cstringstream ss) { + if (!ss) return 0; + char * str = (char *) malloc(sizeof(char) * (ss->inUse + 1)); + if (!str) return 0; + strncpy(str, ss->data, ss->inUse); + str[ss->inUse] = '\0'; + return str; +} diff --git a/resources/3rdparty/cudd-3.0.0/util/cstringstream.h b/resources/3rdparty/cudd-3.0.0/util/cstringstream.h new file mode 100644 index 000000000..b5a85cd52 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/cstringstream.h @@ -0,0 +1,162 @@ +/** + @file + + @ingroup cstringstream + + @brief Package for simple stringstreams in C. + + @author Fabio Somenzi + + @copyright@parblock + Copyright (c) 2014-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + + $Id: cstringstream.h,v 1.1 2015/07/01 20:36:47 fabio Exp fabio $ + +*/ +#ifndef CSTRINGSTREAM_H_ +#define CSTRINGSTREAM_H_ + +#ifdef __cplusplus +extern "C" { +#endif + +/*---------------------------------------------------------------------------*/ +/* Type declarations */ +/*---------------------------------------------------------------------------*/ + +/** + * @brief Type of a string stream. + */ +typedef struct _cstringstream * cstringstream; + +/** + * @brief Const-qualified version of cstringstream. + */ +typedef struct _cstringstream const * const_cstringstream; + +/*---------------------------------------------------------------------------*/ +/* Function prototypes */ +/*---------------------------------------------------------------------------*/ + +/** + * @brief Returns a new cstringstream with an empty string. + * @return NULL if creation fails. + */ +cstringstream newStringStream(void); +/** + * @brief Frees cstringstream ss. + */ +void deleteStringStream(cstringstream ss); +/** + * @brief Clears the contents of cstringstream ss. + * @return 0 if succesful and -1 if ss is an invalid pointer. + */ +int clearStringStream(cstringstream ss); +/** + * @brief Copies cstringstream src to a new cstringstream. + * @return 0 if succesful or -1 if src is an invalid pointer + * or memory allocation fails. + */ +cstringstream copyStringStream(const_cstringstream src); +/** + * @brief Changes the size of cstringstream ss. + * @return 0 if successful or -1 if resizing fails. + */ +int resizeStringStream(cstringstream ss, size_t newSize); +/** + * @brief Writes the size of cstringstream ss to the location pointed by num. + * @return 0 if succesful or -1 if ss is an invalid pointer. + */ +int sizeStringStream(const_cstringstream ss, size_t * num); +/** + * @brief Writes the i-th element of cstringstream ss to the location + * pointed by c. + * @return 0 if successful or -1 otherwise. + */ +int getStringStream(const_cstringstream ss, size_t i, char * c); +/** + * @brief Adds char c at the end of cstringstream ss. + * @return 0 if successful or -1 otherwise. + */ +int appendCharStringStream(cstringstream ss, char c); +/** + * @brief Adds string s at the end of cstringstream ss. + * @return 0 if successful or -1 otherwise. + */ +int appendStringStringStream(cstringstream ss, char const * s); +/** + * @brief Adds int d at the end of cstringstream ss. + * @return 0 if successful or -1 otherwise. + */ +int appendIntStringStream(cstringstream ss, int d); +/** + * @brief Adds unsigned u at the end of cstringstream ss. + * @return 0 if successful or -1 otherwise. + */ +int appendUnsignedStringStream(cstringstream ss, unsigned u); +/** + * @brief Adds long ld at the end of cstringstream ss. + * @return 0 if successful or -1 otherwise. + */ +int appendLongStringStream(cstringstream ss, long ld); +/** + * @brief Adds unsigned long lu at the end of cstringstream ss. + * @return 0 if successful or -1 otherwise. + */ +int appendUnsignedLongStringStream(cstringstream ss, unsigned long lu); +/** + * @brief Adds double g at the end of cstringstream ss. + * @return 0 if successful or -1 otherwise. + */ +int appendDoubleStringStream(cstringstream ss, double g); +/** + * @brief Sets the i-th element of cstringstream ss to c. + * @return 0 if successful or -1 otherwise. + * + * The i-th element of ss must already exist. + */ +int putStringStream(cstringstream ss, size_t index, char c); +/** + * @brief Returns a NULL-terminated string from the contents of + * cstringstream ss. + * @details In case of failure, it returns NULL. + * The returned string must be freed by the caller. + */ +char * stringFromStringStream(const_cstringstream ss); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/resources/3rdparty/cudd-3.0.0/util/datalimit.c b/resources/3rdparty/cudd-3.0.0/util/datalimit.c new file mode 100644 index 000000000..98479b7c8 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/datalimit.c @@ -0,0 +1,112 @@ +/** + @file + + @ingroup util + + @brief Access to datasize limit. + + @copyright@parblock + Copyright (c) 1995-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "config.h" + +#if HAVE_STDINT_H == 1 +#include <stdint.h> +#endif +#if HAVE_STDDEF_H == 1 +#include <stddef.h> +#endif + +#if HAVE_SYS_RESOURCE_H == 1 +#if HAVE_SYS_TIME_H == 1 +#include <sys/time.h> +#endif +#include <sys/resource.h> +#endif + +#ifdef _WIN32 +#include <windows.h> +#endif + +/** + * @brief Default value returned if getrlimit not available. + */ +#ifndef RLIMIT_DATA_DEFAULT +#define RLIMIT_DATA_DEFAULT 268435456 /* assume 256MB by default */ +#endif + +/** + * @def EXTERN + * @brief Allows C linkage when compiling as C++. + */ +#ifndef EXTERN +# ifdef __cplusplus +# define EXTERN extern "C" +# else +# define EXTERN extern +# endif +#endif + +EXTERN size_t getSoftDataLimit(void); + +/** + * @brief Gets the soft datasize limit. + */ +size_t +getSoftDataLimit(void) +{ +#if HAVE_SYS_RESOURCE_H == 1 && HAVE_GETRLIMIT == 1 && defined(RLIMIT_DATA) + struct rlimit rl; + int result; + + result = getrlimit(RLIMIT_DATA, &rl); + if (result != 0 || rl.rlim_cur == RLIM_INFINITY) + return (size_t) RLIMIT_DATA_DEFAULT; + else + return (size_t) rl.rlim_cur; +#elif defined(_WIN32) + /* Not quite the same, because this returns available physical memory. */ + MEMORYSTATUSEX statex; + statex.dwLength = sizeof(statex); + if (GlobalMemoryStatusEx(&statex)) + return (size_t) statex.ullTotalPhys; + else + return (size_t) RLIMIT_DATA_DEFAULT; +#else + return (size_t) RLIMIT_DATA_DEFAULT; +#endif + +} /* end of getSoftDataLimit */ diff --git a/resources/3rdparty/cudd-3.0.0/util/pathsearch.c b/resources/3rdparty/cudd-3.0.0/util/pathsearch.c new file mode 100644 index 000000000..c0c2f1add --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/pathsearch.c @@ -0,0 +1,167 @@ +/** + @file + + @ingroup util + + @brief Search in PATH. + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" + +/** \cond */ + +static int check_file (char const *, char const *); + +/** \endcond */ + +/** + * @brief Looks for a program in the directories specified by PATH. + */ +char * +util_path_search(char const *prog) +{ +#ifdef UNIX + return util_file_search(prog, getenv("PATH"), (char *) "x"); +#else + return util_file_search(prog, NIL(char), (char *) "x"); +#endif +} + + +/** + * @brief Searches for a file given a set of paths. + */ +char * +util_file_search( + char const *file, /**< file we're looking for */ + char *path, /**< search path, colon separated */ + char const *mode /**< "r", "w", or "x" */) +{ + int quit; + char *buffer, *filename, *save_path, *cp; + + if (path == 0 || strcmp(path, "") == 0) { + path = (char *) "."; /* just look in the current directory */ + } + + save_path = path = util_strsav(path); + quit = 0; + do { + cp = strchr(path, ':'); + if (cp != 0) { + *cp = '\0'; + } else { + quit = 1; + } + + /* cons up the filename out of the path and file name */ + if (strcmp(path, ".") == 0) { + buffer = util_strsav(file); + } else { + buffer = ALLOC(char, strlen(path) + strlen(file) + 4); + (void) sprintf(buffer, "%s/%s", path, file); + } + filename = util_tilde_expand(buffer); + FREE(buffer); + + /* see if we can access it */ + if (check_file(filename, mode)) { + FREE(save_path); + return filename; + } + FREE(filename); + path = ++cp; + } while (! quit); + + FREE(save_path); + return 0; +} + +/** + * @brief Checks user permissions for a file. + */ +static int +check_file(char const *filename, char const *mode) +{ +#ifdef UNIX + int access_mode = /*F_OK*/ 0; + + if (strcmp(mode, "r") == 0) { + access_mode = /*R_OK*/ 4; + } else if (strcmp(mode, "w") == 0) { + access_mode = /*W_OK*/ 2; + } else if (strcmp(mode, "x") == 0) { + access_mode = /*X_OK*/ 1; + } + return access(filename, access_mode) == 0; +#else + FILE *fp; + int got_file; + + if (strcmp(mode, "x") == 0) { + mode = "r"; + } + fp = fopen(filename, mode); + got_file = (fp != 0); + if (fp != 0) { + (void) fclose(fp); + } + return got_file; +#endif +} diff --git a/resources/3rdparty/cudd-3.0.0/util/pipefork.c b/resources/3rdparty/cudd-3.0.0/util/pipefork.c new file mode 100644 index 000000000..abba1da2a --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/pipefork.c @@ -0,0 +1,161 @@ +/** + @file + + @ingroup util + + @brief Forks a command and sets up pipes to and from. + + @author Rick L Spickelmier + @author Richard Rudell + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "config.h" +#if HAVE_UNISTD_H == 1 +#define _POSIX_SOURCE +#include <unistd.h> +#endif +#include <stdio.h> +#if HAVE_SYS_WAIT_H == 1 +#include <sys/wait.h> +#endif + +/** + * @def EXTERN + * @brief Allows C linkage when compiling as C++. + */ +#ifndef EXTERN +# ifdef __cplusplus +# define EXTERN extern "C" +# else +# define EXTERN extern +# endif +#endif + + +/** + * @brief Forks a command and sets up pipes to and from. + * + * @return 1 for success, with toCommand and fromCommand pointing to + * the streams; 0 for failure + */ +int +util_pipefork( + char * const *argv, /**< normal argv argument list */ + FILE **toCommand, /**< pointer to the sending stream */ + FILE **fromCommand, /**< pointer to the reading stream */ + int *pid /**< process ID */) +{ +#if HAVE_SYS_WAIT_H == 1 + int forkpid, waitPid; + int topipe[2], frompipe[2]; + char buffer[1024]; + int status; + + /* create the PIPES... + * fildes[0] for reading from command + * fildes[1] for writing to command + */ + if (pipe(topipe)) return(0); + if (pipe(frompipe)) return(0); + + if ((forkpid = fork()) == 0) { + /* child here, connect the pipes */ + (void) dup2(topipe[0], fileno(stdin)); + (void) dup2(frompipe[1], fileno(stdout)); + + (void) close(topipe[0]); + (void) close(topipe[1]); + (void) close(frompipe[0]); + (void) close(frompipe[1]); + + (void) execvp(argv[0], argv); + (void) sprintf(buffer, "util_pipefork: can not exec %s", argv[0]); + perror(buffer); + (void) _exit(1); + } + + if (pid) { + *pid = forkpid; + } + + waitPid = waitpid(-1, &status, WNOHANG); + + /* parent here, use fork() semantics to get return status */ + if (waitPid == forkpid && WIFEXITED(status)) { + return 0; + } + if ((*toCommand = fdopen(topipe[1], "w")) == NULL) { + return 0; + } + if ((*fromCommand = fdopen(frompipe[0], "r")) == NULL) { + return 0; + } + (void) close(topipe[0]); + (void) close(frompipe[1]); + return 1; +#else + (void) argv; /* to avoid warning */ + (void) toCommand; /* to avoid warning */ + (void) fromCommand; /* to avoid warning */ + (void) pid; /* to avoid warning */ + (void) fprintf(stderr, + "util_pipefork: not implemented on your operating system\n"); + return 0; +#endif +} diff --git a/resources/3rdparty/cudd-3.0.0/util/prtime.c b/resources/3rdparty/cudd-3.0.0/util/prtime.c new file mode 100644 index 000000000..b169827dd --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/prtime.c @@ -0,0 +1,80 @@ +/** + @file + + @ingroup util + + @brief Time printing utility. + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" + +/** + * @brief Massages a long that represents a time interval in + * milliseconds into a string suitable for output. + * + * Hack for IBM/PC -- avoids using floating point. + */ +char * +util_print_time(unsigned long t) +{ + static char s[40]; + + (void) sprintf(s, "%lu.%02lu sec", t/1000, (t%1000)/10); + return s; +} diff --git a/resources/3rdparty/cudd-3.0.0/util/safe_mem.c b/resources/3rdparty/cudd-3.0.0/util/safe_mem.c new file mode 100644 index 000000000..74aaf94b3 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/safe_mem.c @@ -0,0 +1,128 @@ +/** + @file + + @ingroup util + + @brief Interface routines to be placed between a program and the + system memory allocator. + + The function pointer MMoutOfMemory() contains a vector to handle a + 'out-of-memory' error (which, by default, points at a simple wrap-up + and exit routine). + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * @brief Global out-of-memory handler. + */ +void (*MMoutOfMemory)(size_t) = MMout_of_memory; + +#ifdef __cplusplus +} +#endif + + +/** + * @brief Out of memory for lazy people: flush and exit. + */ +void +MMout_of_memory(size_t size) +{ + (void) fflush(stdout); + (void) fprintf(stderr, + "\nCUDD: out of memory allocating %" PRIszt " bytes\n", + (size_t) size); + exit(1); +} + +/** + * @brief malloc replacement. + */ +void * +MMalloc(size_t size) +{ + void *p; + + if ((p = malloc(size)) == NIL(void)) { + if (MMoutOfMemory != 0 ) (*MMoutOfMemory)(size); + return NIL(void); + } + return p; +} + + +/** + * @brief realloc replacement. + */ +void * +MMrealloc(void *obj, size_t size) +{ + void *p; + + if ((p = realloc(obj, size)) == NIL(void)) { + if (MMoutOfMemory != 0 ) (*MMoutOfMemory)(size); + return NIL(void); + } + return p; +} diff --git a/resources/3rdparty/cudd-3.0.0/util/strsav.c b/resources/3rdparty/cudd-3.0.0/util/strsav.c new file mode 100644 index 000000000..4adc278bf --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/strsav.c @@ -0,0 +1,74 @@ +/** + @file + + @ingroup util + + @brief String copying. + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" + +/** + * @brief Returns a copy of a string. + */ +char * +util_strsav(char const *s) +{ + return strcpy(ALLOC(char, strlen(s)+1), s); +} diff --git a/resources/3rdparty/cudd-3.0.0/util/texpand.c b/resources/3rdparty/cudd-3.0.0/util/texpand.c new file mode 100644 index 000000000..3e2cd0616 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/texpand.c @@ -0,0 +1,120 @@ +/** + @file + + @ingroup util + + @brief Tilde expansion. + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ + +#include "util.h" + +#ifdef BSD +#include <pwd.h> +#endif + +/** + * @brief Expands tilde in a file name + */ +char * +util_tilde_expand(char const *fname) +{ +#ifdef BSD + struct passwd *userRecord; + char username[256], *filename; + register int i, j; + + filename = ALLOC(char, strlen(fname) + 256); + + /* Clear the return string */ + i = 0; + filename[0] = '\0'; + + /* Tilde? */ + if (fname[0] == '~') { + j = 0; + i = 1; + while ((fname[i] != '\0') && (fname[i] != '/')) { + username[j++] = fname[i++]; + } + username[j] = '\0'; + + if (username[0] == '\0') { + /* ~/ resolves to home directory of current user */ + if ((userRecord = getpwuid(getuid())) != 0) { + (void) strcat(filename, userRecord->pw_dir); + } else { + i = 0; + } + } else { + /* ~user/ resolves to home directory of 'user' */ + if ((userRecord = getpwnam(username)) != 0) { + (void) strcat(filename, userRecord->pw_dir); + } else { + i = 0; + } + } + } + + /* Concantenate remaining portion of file name */ + (void) strcat(filename, fname + i); + return filename; +#else + return util_strsav(fname); +#endif +} diff --git a/resources/3rdparty/cudd-3.0.0/util/ucbqsort.c b/resources/3rdparty/cudd-3.0.0/util/ucbqsort.c new file mode 100644 index 000000000..47f04f181 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/ucbqsort.c @@ -0,0 +1,308 @@ +/** + @file + + @ingroup util + + @brief Ancient implementation of qsort. + + @details This is shipped with CUDD so that results of reordering may + be more reproducible across different platforms. + + qsort.c 4.2 (Berkeley) 3/9/83 + + Our own version of the system qsort routine which is faster by an average + of 25%, with lows and highs of 10% and 50%. + The THRESHold below is the insertion sort threshold, and has been adjusted + for records of size 48 bytes. + The MTHREShold is where we stop finding a better median. + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + + */ + +#include "util.h" + +#ifndef USE_SYSTEM_QSORT +/** + @brief Threshold for insertion. +*/ +#define THRESH 4 +/** + @brief Threshold for median. +*/ +#define MTHRESH 6 + +/** + @brief Miscellaneous information. +*/ +typedef struct { + QSFP qcmp; /**< the comparison routine */ + int qsz; /**< size of each record */ + int thresh; /**< THRESHold in chars */ + int mthresh; /**< MTHRESHold in chars */ +} info_t; + +/*---------------------------------------------------------------------------*/ +/* Static function prototypes */ +/*---------------------------------------------------------------------------*/ + +/** \cond */ + +static void qst (char *base, char *max, info_t const * info); + +/** \endcond */ + +/*---------------------------------------------------------------------------*/ +/* Definition of exported functions */ +/*---------------------------------------------------------------------------*/ + +#undef min +#undef max +#endif +/** + * @brief Implements the quicksort algorithm. + * + * @details First, set up some global parameters for qst to share. + * Then, quicksort with qst(), and then a cleanup insertion sort + * ourselves. Sound simple? It's not... + */ +void +util_qsort( + void *vbase /**< start address of array */, + int n /**< number of items */, + int size /**< size of each item */, + QSFP compar /**< comparison function */) +{ +#ifdef USE_SYSTEM_QSORT + qsort(vbase, n, size, compar); +#else + char *base = (char *) vbase; + char c, *i, *j, *lo, *hi; + char *min, *max; + info_t info; + + if (n <= 1) + return; + info.qsz = size; + info.qcmp = compar; + info.thresh = size * THRESH; + info.mthresh = size * MTHRESH; + max = base + n * size; + if (n >= THRESH) { + qst(base, max, &info); + hi = base + info.thresh; + } else { + hi = max; + } + /* + * First put smallest element, which must be in the first THRESH, in + * the first position as a sentinel. This is done just by searching + * the first THRESH elements (or the first n if n < THRESH), finding + * the min, and swapping it into the first position. + */ + for (j = lo = base; (lo += size) < hi; ) + if ((*compar)(j, lo) > 0) + j = lo; + if (j != base) { + /* swap j into place */ + for (i = base, hi = base + size; i < hi; ) { + c = *j; + *j++ = *i; + *i++ = c; + } + } + /* + * With our sentinel in place, we now run the following hyper-fast + * insertion sort. For each remaining element, min, from [1] to [n-1], + * set hi to the index of the element AFTER which this one goes. + * Then, do the standard insertion sort shift on a character at a time + * basis for each element in the frob. + */ + for (min = base; (hi = min += size) < max; ) { + while ((*compar)(hi -= size, min) > 0) + /* void */; + if ((hi += size) != min) { + for (lo = min + size; --lo >= min; ) { + c = *lo; + for (i = j = lo; (j -= size) >= hi; i = j) + *i = *j; + *i = c; + } + } + } +#endif +} + + +/*---------------------------------------------------------------------------*/ +/* Definition of static functions */ +/*---------------------------------------------------------------------------*/ + +/** + * @brief Do a quicksort. + * + * @details First, find the median element, and put that one in the + * first place as the discriminator. (This "median" is just the + * median of the first, last and middle elements). (Using this median + * instead of the first element is a big win). Then, the usual + * partitioning/swapping, followed by moving the discriminator into + * the right place. Then, figure out the sizes of the two partions, + * do the smaller one recursively and the larger one via a repeat of + * this code. Stopping when there are less than THRESH elements in a + * partition and cleaning up with an insertion sort (in our caller) is + * a huge win. All data swaps are done in-line, which is space-losing + * but time-saving. (And there are only three places where this is + * done). + */ +#ifndef USE_SYSTEM_QSORT +static void +qst(char *base, char *max, info_t const * info) +{ + char c, *i, *j, *jj; + int ii; + char *mid, *tmp; + intptr_t lo, hi; + + /* + * At the top here, lo is the number of characters of elements in the + * current partition. (Which should be max - base). + * Find the median of the first, last, and middle element and make + * that the middle element. Set j to largest of first and middle. + * If max is larger than that guy, then it's that guy, else compare + * max with loser of first and take larger. Things are set up to + * prefer the middle, then the first in case of ties. + */ + lo = max - base; /* number of elements as chars */ + do { + mid = i = base + info->qsz * ((lo / info->qsz) >> 1); + if (lo >= info->mthresh) { + j = ((*info->qcmp)((jj = base), i) > 0 ? jj : i); + if ((*info->qcmp)(j, (tmp = max - info->qsz)) > 0) { + /* switch to first loser */ + j = (j == jj ? i : jj); + if ((*info->qcmp)(j, tmp) < 0) + j = tmp; + } + if (j != i) { + ii = info->qsz; + do { + c = *i; + *i++ = *j; + *j++ = c; + } while (--ii); + } + } + /* + * Semi-standard quicksort partitioning/swapping + */ + for (i = base, j = max - info->qsz; ; ) { + while (i < mid && (*info->qcmp)(i, mid) <= 0) + i += info->qsz; + while (j > mid) { + if ((*info->qcmp)(mid, j) <= 0) { + j -= info->qsz; + continue; + } + tmp = i + info->qsz; /* value of i after swap */ + if (i == mid) { + /* j <-> mid, new mid is j */ + mid = jj = j; + } else { + /* i <-> j */ + jj = j; + j -= info->qsz; + } + goto swap; + } + if (i == mid) { + break; + } else { + /* i <-> mid, new mid is i */ + jj = mid; + tmp = mid = i; /* value of i after swap */ + j -= info->qsz; + } + swap: + ii = info->qsz; + do { + c = *i; + *i++ = *jj; + *jj++ = c; + } while (--ii); + i = tmp; + } + /* + * Look at sizes of the two partitions, do the smaller + * one first by recursion, then do the larger one by + * making sure lo is its size, base and max are update + * correctly, and branching back. But only repeat + * (recursively or by branching) if the partition is + * of at least size THRESH. + */ + i = (j = mid) + info->qsz; + if ((lo = j - base) <= (hi = max - i)) { + if (lo >= info->thresh) + qst(base, j, info); + base = i; + lo = hi; + } else { + if (hi >= info->thresh) + qst(i, max, info); + max = j; + } + } while (lo >= info->thresh); +} +#endif diff --git a/resources/3rdparty/cudd-3.0.0/util/util.h b/resources/3rdparty/cudd-3.0.0/util/util.h new file mode 100644 index 000000000..ee111ec58 --- /dev/null +++ b/resources/3rdparty/cudd-3.0.0/util/util.h @@ -0,0 +1,230 @@ +/** + @file + + @ingroup util + + @brief Low-level utilities. + + @copyright@parblock + Copyright (c) 1994-1998 The Regents of the Univ. of California. + All rights reserved. + + Permission is hereby granted, without written agreement and without license + or royalty fees, to use, copy, modify, and distribute this software and its + documentation for any purpose, provided that the above copyright notice and + the following two paragraphs appear in all copies of this software. + + IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT + OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF + CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO PROVIDE + MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + @endparblock + + @copyright@parblock + Copyright (c) 1999-2015, Regents of the University of Colorado + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + Neither the name of the University of Colorado nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + @endparblock + +*/ +#ifndef UTIL_H_ +#define UTIL_H_ + +#include "config.h" + +#if HAVE_ASSERT_H == 1 +#include <assert.h> +#else +#error assert.h is needed to build this package +#endif + +#if HAVE_UNISTD_H == 1 +#include <unistd.h> +#endif + +#include <stdio.h> +#include <ctype.h> + +#if HAVE_STDLIB_H +#include <stdlib.h> +#else +#error stdlib.h is needed to build this package +#endif + +#if HAVE_STRING_H == 1 +#include <string.h> +#else +#error string.h is needed to build this package +#endif + +#if HAVE_INTTYPES_H == 1 +#include <inttypes.h> +#else +#error inttypes.h is needed to build this package +#endif + +/** + * @def PRIszt + * @brief Format string for a size_t value. + */ +#if defined(_WIN32) && !defined(__USE_MINGW_ANSI_STDIO) +#ifndef PRIuPTR +#define PRIuPTR "Iu" +#endif +#ifndef PRIxPTR +#define PRIxPTR "Ix" +#endif +#ifndef PRIiPTR +#define PRIiPTR "Id" +#endif +#define PRIszt "Iu" +#else +#define PRIszt "zu" +#endif + +/** + * @def UTIL_UNUSED + * @brief Macro to tell gcc that a variable is intentionally unused. + */ +#if defined(__GNUC__) +#if __GNUC__ > 2 || __GNUC_MINOR__ >= 7 +#define UTIL_UNUSED __attribute__ ((unused)) +#else +#define UTIL_UNUSED +#endif +#else +#define UTIL_UNUSED +#endif + +/** + * @brief Type-decorated NULL (for documentation). + */ +#define NIL(type) ((type *) 0) + +/* #define USE_MM */ /* choose default memory allocator */ + +/** + * @def ALLOC + * @brief Wrapper for either malloc or MMalloc. + * @details Which function is wrapped depends on whether USE_MM is defined. + */ + +/** + * @def REALLOC + * @brief Wrapper for either realloc or MMrealloc. + * @details Which function is wrapped depends on whether USE_MM is defined. + */ + +/** + * @def FREE + * @brief Wrapper for free. + * @details Sets its argument to 0 after freeing. + */ + +#if defined(USE_MM) +/* Assumes the memory manager is default one. */ +#define ALLOC(type, num) \ + ((type *) malloc(sizeof(type) * (num))) +#define REALLOC(type, obj, num) \ + ((type *) realloc(obj, sizeof(type) * (num))) +#else +/* Use replacements that call MMoutOfMemory if allocation fails. */ +#define ALLOC(type, num) \ + ((type *) MMalloc(sizeof(type) * (size_t) (num))) +#define REALLOC(type, obj, num) \ + ((type *) MMrealloc((obj), sizeof(type) * (size_t) (num))) +#endif +/* In any case, set to zero the pointer to freed memory. */ +#define FREE(obj) (free(obj), (obj) = 0) + +/** + * @brief Prints message and terminates execution. + */ +#define fail(why) {\ + (void) fprintf(stderr, "Fatal error: file %s, line %d\n%s\n",\ + __FILE__, __LINE__, why);\ + (void) fflush(stdout);\ + abort();\ +} + +/* These arguably do NOT belong in util.h */ +/** + * @brief Computes the absolute value of its argument. + */ +#define ABS(a) ((a) < 0 ? -(a) : (a)) +/** + * @brief Computes the maximum of its two arguments. + */ +#define MAX(a,b) ((a) > (b) ? (a) : (b)) +/** + * @brief Computes the minimum of its two arguments. + */ +#define MIN(a,b) ((a) < (b) ? (a) : (b)) + +/** + * @brief Type of comparison functions for util_qsort. + */ +typedef int (*QSFP)(void const *, void const *); + +#ifdef __cplusplus +extern "C" { +#endif + +#ifndef USE_MM +extern void *MMalloc(size_t); +extern void *MMrealloc(void *, size_t); +#endif +extern void MMout_of_memory(size_t); +extern void (*MMoutOfMemory) (size_t); + +extern long util_cpu_time(void); +extern long util_cpu_ctime(void); +extern char *util_path_search(char const *); +extern char *util_file_search(char const *, char *, char const *); +extern void util_print_cpu_stats(FILE *); +extern char *util_print_time(unsigned long); +extern char *util_strsav(char const *); +extern char *util_tilde_expand(char const *); +extern size_t getSoftDataLimit(void); +extern void util_qsort (void *vbase, int n, int size, QSFP compar); +extern int util_pipefork(char * const * argv, FILE ** toCommand, + FILE ** fromCommand, int * pid); +#ifdef __cplusplus +} +#endif + +#endif /* UTIL_H_ */ diff --git a/src/models/symbolic/Model.cpp b/src/models/symbolic/Model.cpp index 9840a3188..b2549e5a2 100644 --- a/src/models/symbolic/Model.cpp +++ b/src/models/symbolic/Model.cpp @@ -91,7 +91,8 @@ namespace storm { template<storm::dd::DdType Type, typename ValueType> std::size_t Model<Type, ValueType>::getSizeInBytes() const { - return sizeof(*this) + sizeof(DdNode) * (reachableStates.getNodeCount() + initialStates.getNodeCount() + transitionMatrix.getNodeCount()); + // FIXME: This assumes a fixed value of 16 bytes per node, which isn't necessarily true. + return sizeof(*this) + 16 * (reachableStates.getNodeCount() + initialStates.getNodeCount() + transitionMatrix.getNodeCount()); } template<storm::dd::DdType Type, typename ValueType> diff --git a/src/storage/bisimulation/DeterministicModelBisimulationDecomposition.cpp b/src/storage/bisimulation/DeterministicModelBisimulationDecomposition.cpp index bc48fdffc..4ef7d93b3 100644 --- a/src/storage/bisimulation/DeterministicModelBisimulationDecomposition.cpp +++ b/src/storage/bisimulation/DeterministicModelBisimulationDecomposition.cpp @@ -542,7 +542,7 @@ namespace storm { // However, for weak bisimulation, we need to make sure the representative state is a non-silent one (if // there is any such state). - if (this->options.getType() == BisimulationType::Weak) { + if (this->options.getType() == BisimulationType::Weak && this->model.getType() == storm::models::ModelType::Dtmc) { for (auto const& state : block) { if (!isSilent(state)) { representativeState = state; diff --git a/src/storage/dd/cudd/InternalCuddAdd.cpp b/src/storage/dd/cudd/InternalCuddAdd.cpp index 10107ff2c..e30fd71e6 100644 --- a/src/storage/dd/cudd/InternalCuddAdd.cpp +++ b/src/storage/dd/cudd/InternalCuddAdd.cpp @@ -230,6 +230,7 @@ namespace storm { if (numberOfDdVariables == 0) { return 0; } + std::cout << "num dd vars: " << numberOfDdVariables << std::endl; return static_cast<uint_fast64_t>(this->getCuddAdd().CountMinterm(static_cast<int>(numberOfDdVariables))); } @@ -366,7 +367,7 @@ namespace storm { } return std::make_shared<Odd>(nullptr, elseOffset, nullptr, thenOffset); - } else if (ddVariableIndices[currentLevel] < static_cast<uint_fast64_t>(dd->index)) { + } else if (ddVariableIndices[currentLevel] < Cudd_NodeReadIndex(dd)) { // If we skipped the level in the DD, we compute the ODD just for the else-successor and use the same // node for the then-successor as well. std::shared_ptr<Odd> elseNode = createOddRec(dd, manager, currentLevel + 1, maxLevel, ddVariableIndices, uniqueTableForLevels); @@ -406,15 +407,15 @@ namespace storm { if (currentLevel == maxLevel) { ValueType& targetValue = targetVector[offsets != nullptr ? (*offsets)[currentOffset] : currentOffset]; targetValue = function(targetValue, Cudd_V(dd)); - } else if (ddVariableIndices[currentLevel] < dd->index) { + } else if (ddVariableIndices[currentLevel] < Cudd_NodeReadIndex(dd)) { // If we skipped a level, we need to enumerate the explicit entries for the case in which the bit is set // and for the one in which it is not set. composeWithExplicitVectorRec(dd, offsets, currentLevel + 1, maxLevel, currentOffset, odd.getElseSuccessor(), ddVariableIndices, targetVector, function); composeWithExplicitVectorRec(dd, offsets, currentLevel + 1, maxLevel, currentOffset + odd.getElseOffset(), odd.getThenSuccessor(), ddVariableIndices, targetVector, function); } else { // Otherwise, we simply recursively call the function for both (different) cases. - composeWithExplicitVectorRec(Cudd_E(dd), offsets, currentLevel + 1, maxLevel, currentOffset, odd.getElseSuccessor(), ddVariableIndices, targetVector, function); - composeWithExplicitVectorRec(Cudd_T(dd), offsets, currentLevel + 1, maxLevel, currentOffset + odd.getElseOffset(), odd.getThenSuccessor(), ddVariableIndices, targetVector, function); + composeWithExplicitVectorRec(Cudd_E_const(dd), offsets, currentLevel + 1, maxLevel, currentOffset, odd.getElseSuccessor(), ddVariableIndices, targetVector, function); + composeWithExplicitVectorRec(Cudd_T_const(dd), offsets, currentLevel + 1, maxLevel, currentOffset + odd.getElseOffset(), odd.getThenSuccessor(), ddVariableIndices, targetVector, function); } } @@ -434,7 +435,7 @@ namespace storm { if (currentLevel == maxLevel) { groups.push_back(InternalAdd<DdType::CUDD, ValueType>(ddManager, cudd::ADD(ddManager->getCuddManager(), dd))); - } else if (ddGroupVariableIndices[currentLevel] < dd->index) { + } else if (ddGroupVariableIndices[currentLevel] < Cudd_NodeReadIndex(dd)) { splitIntoGroupsRec(dd, groups, ddGroupVariableIndices, currentLevel + 1, maxLevel); splitIntoGroupsRec(dd, groups, ddGroupVariableIndices, currentLevel + 1, maxLevel); } else { @@ -459,15 +460,15 @@ namespace storm { if (currentLevel == maxLevel) { groups.push_back(std::make_pair(InternalAdd<DdType::CUDD, ValueType>(ddManager, cudd::ADD(ddManager->getCuddManager(), dd1)), InternalAdd<DdType::CUDD, ValueType>(ddManager, cudd::ADD(ddManager->getCuddManager(), dd2)))); - } else if (ddGroupVariableIndices[currentLevel] < dd1->index) { - if (ddGroupVariableIndices[currentLevel] < dd2->index) { + } else if (ddGroupVariableIndices[currentLevel] < Cudd_NodeReadIndex(dd1)) { + if (ddGroupVariableIndices[currentLevel] < Cudd_NodeReadIndex(dd2)) { splitIntoGroupsRec(dd1, dd2, groups, ddGroupVariableIndices, currentLevel + 1, maxLevel); splitIntoGroupsRec(dd1, dd2, groups, ddGroupVariableIndices, currentLevel + 1, maxLevel); } else { splitIntoGroupsRec(dd1, Cudd_T(dd2), groups, ddGroupVariableIndices, currentLevel + 1, maxLevel); splitIntoGroupsRec(dd1, Cudd_E(dd2), groups, ddGroupVariableIndices, currentLevel + 1, maxLevel); } - } else if (ddGroupVariableIndices[currentLevel] < dd2->index) { + } else if (ddGroupVariableIndices[currentLevel] < Cudd_NodeReadIndex(dd2)) { splitIntoGroupsRec(Cudd_T(dd1), dd2, groups, ddGroupVariableIndices, currentLevel + 1, maxLevel); splitIntoGroupsRec(Cudd_E(dd1), dd2, groups, ddGroupVariableIndices, currentLevel + 1, maxLevel); } else { @@ -500,26 +501,26 @@ namespace storm { DdNode const* thenElse; DdNode const* thenThen; - if (ddColumnVariableIndices[currentColumnLevel] < dd->index) { + if (ddColumnVariableIndices[currentColumnLevel] < Cudd_NodeReadIndex(dd)) { elseElse = elseThen = thenElse = thenThen = dd; - } else if (ddRowVariableIndices[currentColumnLevel] < dd->index) { - elseElse = thenElse = Cudd_E(dd); - elseThen = thenThen = Cudd_T(dd); + } else if (ddRowVariableIndices[currentColumnLevel] < Cudd_NodeReadIndex(dd)) { + elseElse = thenElse = Cudd_E_const(dd); + elseThen = thenThen = Cudd_T_const(dd); } else { - DdNode const* elseNode = Cudd_E(dd); - if (ddColumnVariableIndices[currentColumnLevel] < elseNode->index) { + DdNode const* elseNode = Cudd_E_const(dd); + if (ddColumnVariableIndices[currentColumnLevel] < Cudd_NodeReadIndex(elseNode)) { elseElse = elseThen = elseNode; } else { - elseElse = Cudd_E(elseNode); - elseThen = Cudd_T(elseNode); + elseElse = Cudd_E_const(elseNode); + elseThen = Cudd_T_const(elseNode); } - DdNode const* thenNode = Cudd_T(dd); - if (ddColumnVariableIndices[currentColumnLevel] < thenNode->index) { + DdNode const* thenNode = Cudd_T_const(dd); + if (ddColumnVariableIndices[currentColumnLevel] < Cudd_NodeReadIndex(thenNode)) { thenElse = thenThen = thenNode; } else { - thenElse = Cudd_E(thenNode); - thenThen = Cudd_T(thenNode); + thenElse = Cudd_E_const(thenNode); + thenThen = Cudd_T_const(thenNode); } } diff --git a/src/storage/dd/cudd/InternalCuddBdd.cpp b/src/storage/dd/cudd/InternalCuddBdd.cpp index ce285fc1d..607b68428 100644 --- a/src/storage/dd/cudd/InternalCuddBdd.cpp +++ b/src/storage/dd/cudd/InternalCuddBdd.cpp @@ -287,13 +287,13 @@ namespace storm { // If we are at the maximal level, the value to be set is stored as a constant in the DD. if (currentRowLevel == maxLevel) { result.set(currentRowOffset, true); - } else if (ddRowVariableIndices[currentRowLevel] < dd->index) { + } else if (ddRowVariableIndices[currentRowLevel] < Cudd_NodeReadIndex(dd)) { toVectorRec(dd, manager, result, rowOdd.getElseSuccessor(), complement, currentRowLevel + 1, maxLevel, currentRowOffset, ddRowVariableIndices); toVectorRec(dd, manager, result, rowOdd.getThenSuccessor(), complement, currentRowLevel + 1, maxLevel, currentRowOffset + rowOdd.getElseOffset(), ddRowVariableIndices); } else { // Otherwise, we compute the ODDs for both the then- and else successors. - DdNode* elseDdNode = Cudd_E(dd); - DdNode* thenDdNode = Cudd_T(dd); + DdNode const* elseDdNode = Cudd_E_const(dd); + DdNode const* thenDdNode = Cudd_T_const(dd); // Determine whether we have to evaluate the successors as if they were complemented. bool elseComplemented = Cudd_IsComplement(elseDdNode) ^ complement; @@ -347,7 +347,7 @@ namespace storm { } return std::make_shared<Odd>(nullptr, elseOffset, nullptr, thenOffset); - } else if (ddVariableIndices[currentLevel] < static_cast<uint_fast64_t>(dd->index)) { + } else if (ddVariableIndices[currentLevel] < Cudd_NodeReadIndex(dd)) { // If we skipped the level in the DD, we compute the ODD just for the else-successor and use the same // node for the then-successor as well. std::shared_ptr<Odd> elseNode = createOddRec(dd, manager, currentLevel + 1, complement, maxLevel, ddVariableIndices, uniqueTableForLevels); @@ -356,8 +356,8 @@ namespace storm { return std::make_shared<Odd>(elseNode, totalOffset, thenNode, totalOffset); } else { // Otherwise, we compute the ODDs for both the then- and else successors. - DdNode* thenDdNode = Cudd_T(dd); - DdNode* elseDdNode = Cudd_E(dd); + DdNode const* thenDdNode = Cudd_T_const(dd); + DdNode const* elseDdNode = Cudd_E_const(dd); // Determine whether we have to evaluate the successors as if they were complemented. bool elseComplemented = Cudd_IsComplement(elseDdNode) ^ complement; @@ -388,15 +388,15 @@ namespace storm { if (currentLevel == maxLevel) { result[currentIndex++] = values[currentOffset]; - } else if (ddVariableIndices[currentLevel] < dd->index) { + } else if (ddVariableIndices[currentLevel] < Cudd_NodeReadIndex(dd)) { // If we skipped a level, we need to enumerate the explicit entries for the case in which the bit is set // and for the one in which it is not set. filterExplicitVectorRec(dd, manager, currentLevel + 1, complement, maxLevel, ddVariableIndices, currentOffset, odd.getElseSuccessor(), result, currentIndex, values); filterExplicitVectorRec(dd, manager, currentLevel + 1, complement, maxLevel, ddVariableIndices, currentOffset + odd.getElseOffset(), odd.getThenSuccessor(), result, currentIndex, values); } else { // Otherwise, we compute the ODDs for both the then- and else successors. - DdNode* thenDdNode = Cudd_T(dd); - DdNode* elseDdNode = Cudd_E(dd); + DdNode const* thenDdNode = Cudd_T_const(dd); + DdNode const* elseDdNode = Cudd_E_const(dd); // Determine whether we have to evaluate the successors as if they were complemented. bool elseComplemented = Cudd_IsComplement(elseDdNode) ^ complement;