cudd
3.0.0
The University of Colorado Decision Diagram Package
|
Main program for the nanotrav program. More...
Macros | |
#define | NTR_VERSION "Nanotrav Version #0.13, Release date 2015/7/15" |
#define | BUFLENGTH 8192 |
Functions | |
int | main (int argc, char **argv) |
Main program for ntr. More... | |
static NtrOptions * | mainInit () |
Allocates the option structure and initializes it. More... | |
static void | ntrReadOptions (int argc, char **argv, NtrOptions *option) |
Reads the command line options. More... | |
static void | ntrReadOptionsFile (char *name, char ***argv, int *argc) |
Reads the program options from a file. More... | |
static char * | readLine (FILE *fp) |
Reads a line from the option file. More... | |
static FILE * | open_file (char *filename, const char *mode) |
Opens a file. More... | |
static int | reorder (BnetNetwork *net, DdManager *dd, NtrOptions *option) |
Explicitly applies reordering to the DDs. More... | |
static void | freeOption (NtrOptions *option) |
Frees the option structure and its appendages. More... | |
static DdManager * | startCudd (NtrOptions *option, int nvars) |
Starts the CUDD manager with the desired options. More... | |
static int | ntrReadTree (DdManager *dd, char *treefile, int nvars) |
Reads the variable group tree from a file. More... | |
Variables | |
static char | buffer [8192] |
Main program for the nanotrav program.
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.
|
static |
Frees the option structure and its appendages.
int main | ( | int | argc, |
char ** | argv | ||
) |
Main program for ntr.
Performs initialization. Reads command line options and network(s). Builds BDDs with reordering, and optionally does reachability analysis. Prints stats.
|
static |
|
static |
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.
|
static |
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.
|
static |
Reads the variable group tree from a file.
|
static |
Opens a file.
Opens a file, or fails with an error message and exits. Allows '-' as a synonym for standard input.
|
static |
Reads a line from the option file.
|
static |
Explicitly applies reordering to the DDs.
|
static |
Starts the CUDD manager with the desired options.
Starts with 0 variables, because Ntr_buildDDs will create new variables rather than using whatever already exists.