Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
abc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kestrel Collaboration
Kestrel Tooling
abc
Commits
40bfe2fb
Commit
40bfe2fb
authored
Nov 09, 2020
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Experiments with SAT sweeping.
parent
0b89fd38
Changes
9
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
1184 additions
and
5 deletions
+1184
-5
abclib.dsp
abclib.dsp
+4
-0
src/aig/gia/gia.h
src/aig/gia/gia.h
+3
-1
src/aig/gia/giaEquiv.c
src/aig/gia/giaEquiv.c
+4
-2
src/base/abci/abc.c
src/base/abci/abc.c
+8
-2
src/proof/cec/cecCore.c
src/proof/cec/cecCore.c
+5
-0
src/proof/cec/cecInt.h
src/proof/cec/cecInt.h
+3
-0
src/proof/cec/cecSatG2.c
src/proof/cec/cecSatG2.c
+1153
-0
src/proof/cec/cecSweep.c
src/proof/cec/cecSweep.c
+3
-0
src/proof/cec/module.make
src/proof/cec/module.make
+1
-0
No files found.
abclib.dsp
View file @
40bfe2fb
...
...
@@ -5415,6 +5415,10 @@ SOURCE=.\src\proof\cec\cecSatG.c
# End Source File
# Begin Source File
SOURCE=.\src\proof\cec\cecSatG2.c
# End Source File
# Begin Source File
SOURCE=.\src\proof\cec\cecSeq.c
# End Source File
# Begin Source File
...
...
src/aig/gia/gia.h
View file @
40bfe2fb
...
...
@@ -1069,9 +1069,11 @@ static inline void Gia_ClassUndoPair( Gia_Man_t * p, int i ) { a
#define Gia_ManForEachClassReverse( p, i ) \
for ( i = Gia_ManObjNum(p) - 1; i > 0; i-- ) if ( !Gia_ObjIsHead(p, i) ) {} else
#define Gia_ClassForEachObj( p, i, iObj ) \
for ( assert(Gia_ObjIsHead(p, i)), iObj = i; iObj > 0; iObj = Gia_ObjNext(p, iObj) )
for ( assert(Gia_ObjIsHead(p, i)
&& i
), iObj = i; iObj > 0; iObj = Gia_ObjNext(p, iObj) )
#define Gia_ClassForEachObj1( p, i, iObj ) \
for ( assert(Gia_ObjIsHead(p, i)), iObj = Gia_ObjNext(p, i); iObj > 0; iObj = Gia_ObjNext(p, iObj) )
#define Gia_ClassForEachObjStart( p, i, iObj, Start ) \
for ( assert(Gia_ObjIsHead(p, i)), iObj = Gia_ObjNext(p, Start); iObj > 0; iObj = Gia_ObjNext(p, iObj) )
static
inline
int
Gia_ObjFoffsetId
(
Gia_Man_t
*
p
,
int
Id
)
{
return
Vec_IntEntry
(
p
->
vFanout
,
Id
);
}
...
...
src/aig/gia/giaEquiv.c
View file @
40bfe2fb
...
...
@@ -480,8 +480,10 @@ void Gia_ManEquivPrintClasses( Gia_Man_t * p, int fVerbose, float Mem )
}
CounterX
-=
Gia_ManCoNum
(
p
);
nLits
=
Gia_ManCiNum
(
p
)
+
Gia_ManAndNum
(
p
)
-
Counter
-
CounterX
;
Abc_Print
(
1
,
"cst =%8d cls =%7d lit =%8d unused =%8d proof =%6d mem =%5.2f MB
\n
"
,
Counter0
,
Counter
,
nLits
,
CounterX
,
Proved
,
(
Mem
==
0
.
0
)
?
8
.
0
*
Gia_ManObjNum
(
p
)
/
(
1
<<
20
)
:
Mem
);
// Abc_Print( 1, "cst =%8d cls =%7d lit =%8d unused =%8d proof =%6d mem =%5.2f MB\n",
// Counter0, Counter, nLits, CounterX, Proved, (Mem == 0.0) ? 8.0*Gia_ManObjNum(p)/(1<<20) : Mem );
Abc_Print
(
1
,
"cst =%8d cls =%7d lit =%8d unused =%8d proof =%6d
\n
"
,
Counter0
,
Counter
,
nLits
,
CounterX
,
Proved
);
assert
(
Gia_ManEquivCheckLits
(
p
,
nLits
)
);
if
(
fVerbose
)
{
...
...
src/base/abci/abc.c
View file @
40bfe2fb
...
...
@@ -36286,14 +36286,15 @@ int Abc_CommandAbc9Fraig( Abc_Frame_t * pAbc, int argc, char ** argv )
{
extern Gia_Man_t * Cec2_ManSimulateTest( Gia_Man_t * p, Cec_ParFra_t * pPars );
extern Gia_Man_t * Cec3_ManSimulateTest( Gia_Man_t * p, Cec_ParFra_t * pPars );
extern Gia_Man_t * Cec4_ManSimulateTest( Gia_Man_t * p, Cec_ParFra_t * pPars );
Cec_ParFra_t ParsFra, * pPars = &ParsFra;
Gia_Man_t * pTemp;
int c, fUseAlgo = 0, fUseAlgoG = 0;
int c, fUseAlgo = 0, fUseAlgoG = 0
, fUseAlgoG2 = 0
;
Cec_ManFraSetDefaultParams( pPars );
pPars->fSatSweeping = 1;
pPars->nItersMax = 1000000;
Extra_UtilGetoptReset();
while ( ( c = Extra_UtilGetopt( argc, argv, "WRILDCrmdckngwvh" ) ) != EOF )
while ( ( c = Extra_UtilGetopt( argc, argv, "WRILDCrmdckng
x
wvh" ) ) != EOF )
{
switch ( c )
{
...
...
@@ -36384,6 +36385,9 @@ int Abc_CommandAbc9Fraig( Abc_Frame_t * pAbc, int argc, char ** argv )
case 'g':
fUseAlgoG ^= 1;
break;
case 'x':
fUseAlgoG2 ^= 1;
break;
case 'w':
pPars->fVeryVerbose ^= 1;
break;
...
...
@@ -36403,6 +36407,8 @@ int Abc_CommandAbc9Fraig( Abc_Frame_t * pAbc, int argc, char ** argv )
pTemp = Cec2_ManSimulateTest( pAbc->pGia, pPars );
else if ( fUseAlgoG )
pTemp = Cec3_ManSimulateTest( pAbc->pGia, pPars );
else if ( fUseAlgoG2 )
pTemp = Cec4_ManSimulateTest( pAbc->pGia, pPars );
else
pTemp = Cec_ManSatSweeping( pAbc->pGia, pPars, 0 );
Abc_FrameUpdateGia( pAbc, pTemp );
src/proof/cec/cecCore.c
View file @
40bfe2fb
...
...
@@ -348,6 +348,8 @@ Gia_Man_t * Cec_ManSatSweeping( Gia_Man_t * pAig, Cec_ParFra_t * pPars, int fSil
Cec_ManPat_t
*
pPat
;
int
i
,
fTimeOut
=
0
,
nMatches
=
0
;
abctime
clk
,
clk2
,
clkTotal
=
Abc_Clock
();
if
(
pPars
->
fVerbose
)
printf
(
"Simulating %d words for %d rounds. SAT solving with %d conflicts.
\n
"
,
pPars
->
nWords
,
pPars
->
nRounds
,
pPars
->
nBTLimit
);
// duplicate AIG and transfer equivalence classes
Gia_ManRandom
(
1
);
...
...
@@ -519,6 +521,9 @@ p->timeSat += Abc_Clock() - clk;
}
}
finalize:
if
(
pPars
->
fVerbose
)
printf
(
"Performed %d SAT calls: P = %d D = %d F = %d
\n
"
,
p
->
nAllProvedS
+
p
->
nAllDisprovedS
+
p
->
nAllFailedS
,
p
->
nAllProvedS
,
p
->
nAllDisprovedS
,
p
->
nAllFailedS
);
if
(
p
->
pPars
->
fVerbose
&&
p
->
pAig
)
{
Abc_Print
(
1
,
"NBeg = %d. NEnd = %d. (Gain = %6.2f %%). RBeg = %d. REnd = %d. (Gain = %6.2f %%).
\n
"
,
...
...
src/proof/cec/cecInt.h
View file @
40bfe2fb
...
...
@@ -153,6 +153,9 @@ struct Cec_ManFra_t_
int
nAllProved
;
// total number of proved nodes
int
nAllDisproved
;
// total number of disproved nodes
int
nAllFailed
;
// total number of failed nodes
int
nAllProvedS
;
// total number of proved nodes
int
nAllDisprovedS
;
// total number of disproved nodes
int
nAllFailedS
;
// total number of failed nodes
// runtime stats
abctime
timeSim
;
// unsat
abctime
timePat
;
// unsat
...
...
src/proof/cec/cecSatG2.c
0 → 100644
View file @
40bfe2fb
This diff is collapsed.
Click to expand it.
src/proof/cec/cecSweep.c
View file @
40bfe2fb
...
...
@@ -289,6 +289,9 @@ p->timeSim += Abc_Clock() - clk;
p
->
nAllFailed
++
;
}
}
p
->
nAllProvedS
+=
p
->
nAllProved
;
p
->
nAllDisprovedS
+=
p
->
nAllDisproved
;
p
->
nAllFailedS
+=
p
->
nAllFailed
;
return
0
;
}
...
...
src/proof/cec/module.make
View file @
40bfe2fb
...
...
@@ -8,6 +8,7 @@ SRC += src/proof/cec/cecCec.c \
src/proof/cec/cecPat.c
\
src/proof/cec/cecSat.c
\
src/proof/cec/cecSatG.c
\
src/proof/cec/cecSatG2.c
\
src/proof/cec/cecSeq.c
\
src/proof/cec/cecSolve.c
\
src/proof/cec/cecSplit.c
\
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment