DECLARATIONS ///.
GLOBAL VARIABLES ///.
Date [Ver. 1.0. Started - June 20, 2005.]
] FUNCTION DEFINITIONS /// Function*************************************************************
50{
51 int fEnableBmcOnly = 0;
52
53 int fEnableCounter = 1;
54 int fEnableComment = 0;
55
57 FILE * pFile;
59 int RetValue = -1;
60 int Depth = -1;
61
62 int nFrames = 50;
63 int nSizeMax = 500000;
64 int nBTLimit = 10000;
65 int fRewrite = 0;
66 int fNewAlgo = 1;
67 int fVerbose = 0;
68 clock_t clkTotal = clock();
69
70 if ( argc != 2 )
71 {
72 printf( " Expecting one command-line argument (an input file in AIGER format).\n" );
73 printf( " usage: %s <file.aig>\n", argv[0] );
74 return 0;
75 }
76 pFile = fopen( argv[1], "r" );
77 if ( pFile == NULL )
78 {
79 printf( " Cannot open input AIGER file \"%s\".\n", argv[1] );
80 printf( " usage: %s <file.aig>\n", argv[0] );
81 return 0;
82 }
83 fclose( pFile );
85 if ( pAig == NULL )
86 {
87 printf( " Parsing the AIGER file \"%s\" has failed.\n", argv[1] );
88 printf( " usage: %s <file.aig>\n", argv[0] );
89 return 0;
90 }
91
93 if ( !fEnableBmcOnly )
94 {
95
96 if ( pAig->nRegs != 0 )
97 RetValue =
Saig_ManBmcSimple( pAig, nFrames, nSizeMax, nBTLimit, fRewrite, fVerbose, NULL, 0, 0 );
98
99
100 if ( RetValue != 0 )
101 {
105
111
116 }
117 }
118
119
120 if ( RetValue == -1 && pAig->nRegs != 0 )
121 {
122 int nFrames = 200;
123 int nSizeMax = 500000;
124 int nBTLimit = 10000000;
125 int fRewrite = 0;
126 RetValue =
Saig_ManBmcSimple( pAig, nFrames, nSizeMax, nBTLimit, fRewrite, fVerbose, &Depth, 0, 0 );
127 if ( RetValue != 0 )
128 RetValue = -1;
129 }
130
131
132 pFile = stdout;
133
134
135 if ( RetValue == 0 )
136 {
137
138 fprintf( pFile, "1" );
139 if ( fEnableCounter )
140 {
141 printf( "\n" );
142 if ( pAig->pSeqModel )
143 Fra_SmlWriteCounterExample( pFile, pAig, pAig->pSeqModel );
144 }
145
146 if ( fEnableComment )
147 {
148 printf( " # File %10s. ", argv[1] );
149 PRT(
"Time", clock() - clkTotal );
150 }
151
152 if ( pFile != stdout )
153 fclose(pFile);
156 }
157 else if ( RetValue == 1 )
158 {
159
160 fprintf( pFile, "0" );
161
162 if ( fEnableComment )
163 {
164 printf( " # File %10s. ", argv[1] );
165 PRT(
"Time", clock() - clkTotal );
166 }
167 printf( "\n" );
168
169 if ( pFile != stdout )
170 fclose(pFile);
173 }
174 else
175 {
176
177 fprintf( pFile, "2" );
178
179 if ( fEnableComment )
180 {
181 printf( " # File %10s. ", argv[1] );
182 PRT(
"Time", clock() - clkTotal );
183 }
184 printf( "\n" );
185
186 if ( pFile != stdout )
187 fclose(pFile);
190 }
191 return 0;
192}
void Aig_ManSetRegNum(Aig_Man_t *p, int nRegs)
void Aig_ManStop(Aig_Man_t *p)
typedefABC_NAMESPACE_HEADER_START struct Aig_Man_t_ Aig_Man_t
INCLUDES ///.
int Saig_ManBmcSimple(Aig_Man_t *pAig, int nFrames, int nSizeMax, int nBTLimit, int fRewrite, int fVerbose, int *piFrame, int nCofFanLit, int fUseSatoko)
void Dar_LibStart()
MACRO DEFINITIONS ///.
void Fra_SecSetDefaultParams(Fra_Sec_t *p)
DECLARATIONS ///.
struct Fra_Sec_t_ Fra_Sec_t
int Fra_FraigSec(Aig_Man_t *p, Fra_Sec_t *pParSec, Aig_Man_t **ppResult)
Aig_Man_t * Ioa_ReadAiger(char *pFileName, int fCheck)