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
2d179204
Commit
2d179204
authored
Feb 19, 2017
by
Yen-Sheng Ho
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
working on pdr with wla
parent
2732cbc1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
47 additions
and
14 deletions
+47
-14
src/base/wlc/wlcAbs.c
+5
-9
src/proof/pdr/pdrIncr.c
+42
-5
No files found.
src/base/wlc/wlcAbs.c
View file @
2d179204
...
@@ -323,7 +323,7 @@ int Wlc_NtkPdrAbs( Wlc_Ntk_t * p, Wlc_Par_t * pPars )
...
@@ -323,7 +323,7 @@ int Wlc_NtkPdrAbs( Wlc_Ntk_t * p, Wlc_Par_t * pPars )
Pdr_Par_t
PdrPars
,
*
pPdrPars
=
&
PdrPars
;
Pdr_Par_t
PdrPars
,
*
pPdrPars
=
&
PdrPars
;
Pdr_ManSetDefaultParams
(
pPdrPars
);
Pdr_ManSetDefaultParams
(
pPdrPars
);
pPdrPars
->
fVerbose
=
pPars
->
fPdrVerbose
;
pPdrPars
->
fVerbose
=
pPars
->
fPdrVerbose
;
pPdrPars
->
fVeryVerbose
=
1
;
pPdrPars
->
fVeryVerbose
=
0
;
// perform refinement iterations
// perform refinement iterations
for
(
nIters
=
1
;
nIters
<
pPars
->
nIterMax
;
nIters
++
)
for
(
nIters
=
1
;
nIters
<
pPars
->
nIterMax
;
nIters
++
)
...
@@ -368,14 +368,10 @@ int Wlc_NtkPdrAbs( Wlc_Ntk_t * p, Wlc_Par_t * pPars )
...
@@ -368,14 +368,10 @@ int Wlc_NtkPdrAbs( Wlc_Ntk_t * p, Wlc_Par_t * pPars )
pAig
=
Gia_ManToAigSimple
(
pGia
);
pAig
=
Gia_ManToAigSimple
(
pGia
);
pPdr
=
Pdr_ManStart
(
pAig
,
pPdrPars
,
NULL
);
pPdr
=
Pdr_ManStart
(
pAig
,
pPdrPars
,
NULL
);
if
(
vClauses
)
{
if
(
vClauses
)
{
if
(
Vec_VecSize
(
vClauses
)
==
1
)
{
Vec_VecFree
(
vClauses
);
vClauses
=
NULL
;
}
else
{
assert
(
Vec_VecSize
(
vClauses
)
>=
2
);
assert
(
Vec_VecSize
(
vClauses
)
>=
2
);
IPdr_ManRestore
(
pPdr
,
vClauses
);
IPdr_ManRestore
(
pPdr
,
vClauses
);
}
}
}
RetValue
=
IPdr_ManSolveInt
(
pPdr
);
RetValue
=
IPdr_ManSolveInt
(
pPdr
);
...
@@ -406,7 +402,7 @@ int Wlc_NtkPdrAbs( Wlc_Ntk_t * p, Wlc_Par_t * pPars )
...
@@ -406,7 +402,7 @@ int Wlc_NtkPdrAbs( Wlc_Ntk_t * p, Wlc_Par_t * pPars )
}
}
// spurious CEX, continue solving
// spurious CEX, continue solving
vClauses
=
IPdr_ManSaveClauses
(
pPdr
,
0
);
vClauses
=
IPdr_ManSaveClauses
(
pPdr
,
1
);
Pdr_ManStop
(
pPdr
);
Pdr_ManStop
(
pPdr
);
// update the set of objects to be un-abstracted
// update the set of objects to be un-abstracted
...
@@ -465,7 +461,7 @@ int Wlc_NtkAbsCore( Wlc_Ntk_t * p, Wlc_Par_t * pPars )
...
@@ -465,7 +461,7 @@ int Wlc_NtkAbsCore( Wlc_Ntk_t * p, Wlc_Par_t * pPars )
//pPdrPars->fSkipDown = 0; // use 'pdr -nc' (improved generalization)
//pPdrPars->fSkipDown = 0; // use 'pdr -nc' (improved generalization)
//pPdrPars->nRestLimit = 500; // reset queue or proof-obligations when it gets larger than this
//pPdrPars->nRestLimit = 500; // reset queue or proof-obligations when it gets larger than this
pPdrPars
->
fVerbose
=
pPars
->
fPdrVerbose
;
pPdrPars
->
fVerbose
=
pPars
->
fPdrVerbose
;
pPdrPars
->
fVeryVerbose
=
1
;
pPdrPars
->
fVeryVerbose
=
0
;
// perform refinement iterations
// perform refinement iterations
for
(
nIters
=
1
;
nIters
<
pPars
->
nIterMax
;
nIters
++
)
for
(
nIters
=
1
;
nIters
<
pPars
->
nIterMax
;
nIters
++
)
{
{
...
...
src/proof/pdr/pdrIncr.c
View file @
2d179204
...
@@ -77,12 +77,52 @@ void IPdr_ManPrintClauses( Vec_Vec_t * vClauses, int kStart, int nRegs )
...
@@ -77,12 +77,52 @@ void IPdr_ManPrintClauses( Vec_Vec_t * vClauses, int kStart, int nRegs )
SeeAlso []
SeeAlso []
***********************************************************************/
***********************************************************************/
int
IPdr_ManCheckClauses
(
Pdr_Man_t
*
p
)
{
Pdr_Set_t
*
pCubeK
;
Vec_Ptr_t
*
vArrayK
;
int
j
,
k
,
RetValue
,
kMax
=
Vec_PtrSize
(
p
->
vSolvers
)
-
1
;
int
iStartFrame
=
1
;
Vec_VecForEachLevelStartStop
(
p
->
vClauses
,
vArrayK
,
k
,
iStartFrame
,
kMax
)
{
Vec_PtrForEachEntry
(
Pdr_Set_t
*
,
vArrayK
,
pCubeK
,
j
)
{
RetValue
=
Pdr_ManCheckCube
(
p
,
k
,
pCubeK
,
NULL
,
0
,
0
,
1
);
if
(
!
RetValue
)
{
printf
(
"Cube[%d][%d] not inductive!
\n
"
,
k
,
j
);
}
assert
(
RetValue
==
1
);
}
}
return
1
;
}
/**Function*************************************************************
Synopsis []
Description []
SideEffects []
SeeAlso []
***********************************************************************/
Vec_Vec_t
*
IPdr_ManSaveClauses
(
Pdr_Man_t
*
p
,
int
fDropLast
)
Vec_Vec_t
*
IPdr_ManSaveClauses
(
Pdr_Man_t
*
p
,
int
fDropLast
)
{
{
int
i
,
k
;
int
i
,
k
;
Vec_Vec_t
*
vClausesSaved
;
Vec_Vec_t
*
vClausesSaved
;
Pdr_Set_t
*
pCla
;
Pdr_Set_t
*
pCla
;
if
(
Vec_VecSize
(
p
->
vClauses
)
==
1
)
return
NULL
;
if
(
Vec_VecSize
(
p
->
vClauses
)
==
2
&&
fDropLast
)
return
NULL
;
if
(
fDropLast
)
if
(
fDropLast
)
vClausesSaved
=
Vec_VecStart
(
Vec_VecSize
(
p
->
vClauses
)
-
1
);
vClausesSaved
=
Vec_VecStart
(
Vec_VecSize
(
p
->
vClauses
)
-
1
);
else
else
...
@@ -147,9 +187,6 @@ int IPdr_ManRestore( Pdr_Man_t * p, Vec_Vec_t * vClauses )
...
@@ -147,9 +187,6 @@ int IPdr_ManRestore( Pdr_Man_t * p, Vec_Vec_t * vClauses )
assert
(
vClauses
);
assert
(
vClauses
);
printf
(
"IPdr restore:
\n
"
);
IPdr_ManPrintClauses
(
vClauses
,
0
,
Aig_ManRegNum
(
p
->
pAig
)
);
Vec_VecFree
(
p
->
vClauses
);
Vec_VecFree
(
p
->
vClauses
);
p
->
vClauses
=
vClauses
;
p
->
vClauses
=
vClauses
;
...
@@ -197,8 +234,8 @@ int IPdr_ManSolveInt( Pdr_Man_t * p )
...
@@ -197,8 +234,8 @@ int IPdr_ManSolveInt( Pdr_Man_t * p )
if
(
Vec_VecSize
(
p
->
vClauses
)
==
0
)
if
(
Vec_VecSize
(
p
->
vClauses
)
==
0
)
Pdr_ManCreateSolver
(
p
,
(
iFrame
=
0
)
);
Pdr_ManCreateSolver
(
p
,
(
iFrame
=
0
)
);
else
{
else
{
iFrame
=
Vec_VecSize
(
p
->
vClauses
);
iFrame
=
Vec_VecSize
(
p
->
vClauses
)
-
1
;
Pdr_ManCreateSolver
(
p
,
iFrame
);
IPdr_ManCheckClauses
(
p
);
}
}
while
(
1
)
while
(
1
)
{
{
...
...
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