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
bc2f199b
Commit
bc2f199b
authored
Dec 13, 2011
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Started SAT-based reparameterization.
parent
8fdc5d22
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
15 additions
and
8 deletions
+15
-8
abclib.dsp
+4
-0
src/aig/aig/aigRepar.c
+0
-0
src/aig/aig/module.make
+1
-0
src/base/abci/abc.c
+3
-2
src/sat/bsat/satProof.c
+0
-0
src/sat/bsat/satSolver2.c
+2
-6
src/sat/bsat/satSolver2.h
+5
-0
No files found.
abclib.dsp
View file @
bc2f199b
...
...
@@ -3227,6 +3227,10 @@ SOURCE=.\src\aig\aig\aigPartSat.c
# End Source File
# Begin Source File
SOURCE=.\src\aig\aig\aigRepar.c
# End Source File
# Begin Source File
SOURCE=.\src\aig\aig\aigRepr.c
# End Source File
# Begin Source File
...
...
src/aig/aig/aigRepar.c
0 → 100644
View file @
bc2f199b
This diff is collapsed.
Click to expand it.
src/aig/aig/module.make
View file @
bc2f199b
...
...
@@ -17,6 +17,7 @@ SRC += src/aig/aig/aigCheck.c \
src/aig/aig/aigPart.c
\
src/aig/aig/aigPartReg.c
\
src/aig/aig/aigPartSat.c
\
src/aig/aig/aigRepar.c
\
src/aig/aig/aigRepr.c
\
src/aig/aig/aigRet.c
\
src/aig/aig/aigRetF.c
\
...
...
src/base/abci/abc.c
View file @
bc2f199b
...
...
@@ -8891,12 +8891,13 @@ int Abc_CommandTest( Abc_Frame_t * pAbc, int argc, char ** argv )
*/
{
extern
void
Abs_VfaManTest
(
Aig_Man_t
*
pAig
,
int
nFrames
,
int
nConfLimit
,
int
fVerbose
);
// extern void Abs_VfaManTest( Aig_Man_t * pAig, int nFrames, int nConfLimit, int fVerbose );
extern
void
Aig_ManInterRepar
(
Aig_Man_t
*
pMan
,
int
fVerbose
);
extern
Aig_Man_t
*
Abc_NtkToDar
(
Abc_Ntk_t
*
pNtk
,
int
fExors
,
int
fRegisters
);
if
(
pNtk
)
{
Aig_Man_t
*
pAig
=
Abc_NtkToDar
(
pNtk
,
0
,
1
);
A
bs_VfaManTest
(
pAig
,
32
,
1000000
,
1
);
A
ig_ManInterRepar
(
pAig
,
1
);
Aig_ManStop
(
pAig
);
}
}
...
...
src/sat/bsat/satProof.c
View file @
bc2f199b
This diff is collapsed.
Click to expand it.
src/sat/bsat/satSolver2.c
View file @
bc2f199b
...
...
@@ -144,11 +144,9 @@ static inline void solver2_clear_marks(sat_solver2* s) {
static
inline
satset
*
clause_read
(
sat_solver2
*
s
,
cla
h
)
{
return
(
h
&
1
)
?
satset_read
(
&
s
->
learnts
,
h
>>
1
)
:
satset_read
(
&
s
->
clauses
,
h
>>
1
);
}
static
inline
cla
clause_handle
(
sat_solver2
*
s
,
satset
*
c
)
{
return
c
->
learnt
?
(
satset_handle
(
&
s
->
learnts
,
c
)
<<
1
)
|
1
:
satset_handle
(
&
s
->
clauses
,
c
)
<<
1
;
}
static
inline
int
clause_check
(
sat_solver2
*
s
,
satset
*
c
)
{
return
c
->
learnt
?
satset_check
(
&
s
->
learnts
,
c
)
:
satset_check
(
&
s
->
clauses
,
c
);
}
static
inline
int
clause_proofid
(
sat_solver2
*
s
,
satset
*
c
,
int
partA
)
{
return
c
->
learnt
?
(
veci_begin
(
&
s
->
claProofs
)[
c
->
Id
]
<<
2
)
|
(
partA
<<
1
)
:
(
satset_handle
(
&
s
->
clauses
,
c
)
<<
2
)
|
1
;
}
static
inline
int
clause_proofid
(
sat_solver2
*
s
,
satset
*
c
,
int
partA
)
{
return
c
->
learnt
?
(
veci_begin
(
&
s
->
claProofs
)[
c
->
Id
]
<<
2
)
|
(
partA
<<
1
)
:
(
satset_handle
(
&
s
->
clauses
,
c
)
<<
2
)
|
(
partA
<<
1
)
|
1
;
}
static
inline
int
clause_is_used
(
sat_solver2
*
s
,
cla
h
)
{
return
(
h
&
1
)
?
(
h
>>
1
)
<
s
->
hLearntPivot
:
(
h
>>
1
)
<
s
->
hClausePivot
;
}
//static inline int var_reason (sat_solver2* s, int v) { return (s->reasons[v]&1) ? 0 : s->reasons[v] >> 1; }
//static inline int lit_reason (sat_solver2* s, int l) { return (s->reasons[lit_var(l)&1]) ? 0 : s->reasons[lit_var(l)] >> 1; }
//static inline satset* var_unit_clause(sat_solver2* s, int v) { return (s->reasons[v]&1) ? clause_read(s, s->reasons[v] >> 1) : NULL; }
...
...
@@ -163,9 +161,6 @@ int clause_is_partA (sat_solver2* s, int h) { return clause
void
clause_set_partA
(
sat_solver2
*
s
,
int
h
,
int
partA
)
{
clause_read
(
s
,
h
)
->
partA
=
partA
;
}
int
clause_id
(
sat_solver2
*
s
,
int
h
)
{
return
clause_read
(
s
,
h
)
->
Id
;
}
#define sat_solver_foreach_clause( s, c, h ) satset_foreach_entry( &s->clauses, c, h, 1 )
#define sat_solver_foreach_learnt( s, c, h ) satset_foreach_entry( &s->learnts, c, h, 1 )
//=================================================================================================
// Simple helpers:
...
...
@@ -1452,6 +1447,7 @@ int sat_solver2_addclause(sat_solver2* s, lit* begin, lit* end)
if
(
!
solver2_enqueue
(
s
,
begin
[
0
],
0
)
)
assert
(
0
);
}
//satset_print( clause_read(s, Cid) );
return
Cid
;
}
...
...
src/sat/bsat/satSolver2.h
View file @
bc2f199b
...
...
@@ -184,6 +184,11 @@ static inline void satset_print (satset * c) {
for ( i = 0; (i < veci_size(pVec)) && ((c) = satset_read(p, veci_begin(pVec)[i])); i++ )
#define satset_foreach_var( p, var, i, start ) \
for ( i = start; (i < (int)(p)->nEnts) && ((var) = lit_var((p)->pEnts[i])); i++ )
#define satset_foreach_lit( p, lit, i, start ) \
for ( i = start; (i < (int)(p)->nEnts) && ((lit) = (p)->pEnts[i]); i++ )
#define sat_solver_foreach_clause( s, c, h ) satset_foreach_entry( &s->clauses, c, h, 1 )
#define sat_solver_foreach_learnt( s, c, h ) satset_foreach_entry( &s->learnts, c, h, 1 )
//=================================================================================================
// Public APIs:
...
...
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