Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
abc
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
abc
Commits
d22b3d05
Commit
d22b3d05
authored
Aug 10, 2012
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixing problem with max limit on the number of abstracted objects in &gla.
parent
65b652fa
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
23 deletions
+16
-23
src/aig/gia/giaAbsGla2.c
+15
-22
src/aig/gia/giaAbsVta.c
+1
-1
No files found.
src/aig/gia/giaAbsGla2.c
View file @
d22b3d05
...
@@ -1417,10 +1417,10 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
...
@@ -1417,10 +1417,10 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
if
(
p
->
pPars
->
fVerbose
)
if
(
p
->
pPars
->
fVerbose
)
{
{
Abc_Print
(
1
,
"Running gate-level abstraction (GLA) with the following parameters:
\n
"
);
Abc_Print
(
1
,
"Running gate-level abstraction (GLA) with the following parameters:
\n
"
);
Abc_Print
(
1
,
"FrameMax = %d ConfMax = %d Timeout = %d RatioMin = %d %%
.
\n
"
,
Abc_Print
(
1
,
"FrameMax = %d ConfMax = %d Timeout = %d RatioMin = %d %%
RatioMax = %d %%
\n
"
,
pPars
->
nFramesMax
,
pPars
->
nConfLimit
,
pPars
->
nTimeOut
,
pPars
->
nRatioMin
);
pPars
->
nFramesMax
,
pPars
->
nConfLimit
,
pPars
->
nTimeOut
,
pPars
->
nRatioMin
,
pPars
->
nRatioMax
);
Abc_Print
(
1
,
"L
earnStart = %d LearnDelta = %d LearnRatio = %d %%.
\n
"
,
Abc_Print
(
1
,
"L
rnStart = %d LrnDelta = %d LrnRatio = %d %% Skip = %d SimpleCNF = %d Dump = %d
\n
"
,
pPars
->
nLearnedStart
,
pPars
->
nLearnedDelta
,
pPars
->
nLearnedPerce
);
pPars
->
nLearnedStart
,
pPars
->
nLearnedDelta
,
pPars
->
nLearnedPerce
,
pPars
->
fUseSkip
,
pPars
->
fUseSimple
,
pPars
->
fDumpVabs
);
Abc_Print
(
1
,
" Frame %% Abs PPI FF LUT Confl Cex Vars Clas Lrns Time Mem
\n
"
);
Abc_Print
(
1
,
" Frame %% Abs PPI FF LUT Confl Cex Vars Clas Lrns Time Mem
\n
"
);
}
}
// iterate unrolling
// iterate unrolling
...
@@ -1517,9 +1517,6 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
...
@@ -1517,9 +1517,6 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
Vec_IntFree
(
vPPis
);
Vec_IntFree
(
vPPis
);
if
(
pPars
->
fVerbose
)
if
(
pPars
->
fVerbose
)
Ga2_ManAbsPrintFrame
(
p
,
f
,
sat_solver2_nconflicts
(
p
->
pSat
)
-
nConflsBeg
,
c
+
1
,
clock
()
-
clk
,
0
);
Ga2_ManAbsPrintFrame
(
p
,
f
,
sat_solver2_nconflicts
(
p
->
pSat
)
-
nConflsBeg
,
c
+
1
,
clock
()
-
clk
,
0
);
// verify
// if ( Vec_IntCheckUnique(p->vAbs) )
// Abc_Print( 1, "Vector has %d duplicated entries.\n", Vec_IntCheckUnique(p->vAbs) );
continue
;
continue
;
}
}
p
->
timeUnsat
+=
clock
()
-
clk2
;
p
->
timeUnsat
+=
clock
()
-
clk2
;
...
@@ -1527,7 +1524,6 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
...
@@ -1527,7 +1524,6 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
goto
finish
;
goto
finish
;
if
(
p
->
pSat
->
nRuntimeLimit
&&
clock
()
>
p
->
pSat
->
nRuntimeLimit
)
// timeout
if
(
p
->
pSat
->
nRuntimeLimit
&&
clock
()
>
p
->
pSat
->
nRuntimeLimit
)
// timeout
goto
finish
;
goto
finish
;
// assert( RetValue == l_False );
if
(
c
==
0
)
if
(
c
==
0
)
{
{
if
(
p
->
pPars
->
nFramesNoChange
>=
0
)
if
(
p
->
pPars
->
nFramesNoChange
>=
0
)
...
@@ -1548,8 +1544,9 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
...
@@ -1548,8 +1544,9 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
// purify UNSAT core
// purify UNSAT core
if
(
fUseSecondCore
)
if
(
fUseSecondCore
)
{
{
int
nOldCore
=
Vec_IntSize
(
vCore
);
// int nOldCore = Vec_IntSize(vCore);
Vec_IntSort
(
vCore
,
0
);
// reverse the order of objects in the core
// Vec_IntSort( vCore, 0 );
// Vec_IntPrint( vCore );
// Vec_IntPrint( vCore );
// create bookmark to be used for rollback
// create bookmark to be used for rollback
assert
(
nVarsOld
==
p
->
pSat
->
size
);
assert
(
nVarsOld
==
p
->
pSat
->
size
);
...
@@ -1565,8 +1562,6 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
...
@@ -1565,8 +1562,6 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
Ga2_ManAddToAbs
(
p
,
vCore
);
Ga2_ManAddToAbs
(
p
,
vCore
);
Vec_IntFree
(
vCore
);
Vec_IntFree
(
vCore
);
// if ( pPars->fVerbose )
// Ga2_ManAbsPrintFrame( p, f, sat_solver2_nconflicts(p->pSat)-nConflsBeg, c+1, clock() - clk, 0 );
}
}
// run SAT solver
// run SAT solver
clk2
=
clock
();
clk2
=
clock
();
...
@@ -1587,18 +1582,23 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
...
@@ -1587,18 +1582,23 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
Ga2_ManAddToAbs
(
p
,
vCore
);
Ga2_ManAddToAbs
(
p
,
vCore
);
Vec_IntFree
(
vCore
);
Vec_IntFree
(
vCore
);
// verify
// if ( Vec_IntCheckUnique(p->vAbs) )
// Abc_Print( 1, "Vector has %d duplicated entries.\n", Vec_IntCheckUnique(p->vAbs) );
break
;
break
;
}
}
if
(
pPars
->
fVerbose
)
if
(
pPars
->
fVerbose
)
Ga2_ManAbsPrintFrame
(
p
,
f
,
sat_solver2_nconflicts
(
p
->
pSat
)
-
nConflsBeg
,
c
,
clock
()
-
clk
,
1
);
Ga2_ManAbsPrintFrame
(
p
,
f
,
sat_solver2_nconflicts
(
p
->
pSat
)
-
nConflsBeg
,
c
,
clock
()
-
clk
,
1
);
// set model
if
(
c
>
0
)
if
(
c
>
0
)
{
{
Vec_IntFreeP
(
&
pAig
->
vGateClasses
);
Vec_IntFreeP
(
&
pAig
->
vGateClasses
);
pAig
->
vGateClasses
=
Ga2_ManAbsTranslate
(
p
);
pAig
->
vGateClasses
=
Ga2_ManAbsTranslate
(
p
);
// check if the number of objects is below limit
if
(
Vec_IntSize
(
p
->
vAbs
)
>=
p
->
nMarked
*
(
100
-
pPars
->
nRatioMin
)
/
100
)
{
Status
=
l_Undef
;
goto
finish
;
}
if
(
Abc_FrameIsBridgeMode
()
)
if
(
Abc_FrameIsBridgeMode
()
)
{
{
// cancel old one if it was sent
// cancel old one if it was sent
...
@@ -1634,13 +1634,6 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
...
@@ -1634,13 +1634,6 @@ int Ga2_ManPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
}
}
}
}
}
}
// check if the number of objects is below limit
if
(
Vec_IntSize
(
p
->
vAbs
)
>=
p
->
nMarked
*
(
100
-
pPars
->
nRatioMin
)
/
100
)
{
Status
=
l_Undef
;
break
;
}
}
}
finish:
finish:
p
->
pPars
->
nFramesNoChange
=
Abc_MaxInt
(
p
->
pPars
->
nFramesNoChange
,
0
);
p
->
pPars
->
nFramesNoChange
=
Abc_MaxInt
(
p
->
pPars
->
nFramesNoChange
,
0
);
...
...
src/aig/gia/giaAbsVta.c
View file @
d22b3d05
...
@@ -157,7 +157,7 @@ void Gia_VtaSetDefaultParams( Gia_ParVta_t * p )
...
@@ -157,7 +157,7 @@ void Gia_VtaSetDefaultParams( Gia_ParVta_t * p )
p
->
nLearnedDelta
=
200
;
// max number of learned clauses
p
->
nLearnedDelta
=
200
;
// max number of learned clauses
p
->
nLearnedPerce
=
70
;
// max number of learned clauses
p
->
nLearnedPerce
=
70
;
// max number of learned clauses
p
->
nTimeOut
=
0
;
// timeout in seconds
p
->
nTimeOut
=
0
;
// timeout in seconds
p
->
nRatioMin
=
1
0
;
// stop when less than this % of object is abstracted
p
->
nRatioMin
=
2
0
;
// stop when less than this % of object is abstracted
p
->
nRatioMax
=
30
;
// restart when more than this % of object is abstracted
p
->
nRatioMax
=
30
;
// restart when more than this % of object is abstracted
p
->
fUseTermVars
=
0
;
// use terminal variables
p
->
fUseTermVars
=
0
;
// use terminal variables
p
->
fUseRollback
=
0
;
// use rollback to the starting number of frames
p
->
fUseRollback
=
0
;
// use rollback to the starting number of frames
...
...
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