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
e19d21a0
Commit
e19d21a0
authored
Jun 23, 2014
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improvements to CNF generation.
parent
938ffa5a
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
5 deletions
+3
-5
src/aig/gia/giaGig.c
+1
-1
src/aig/gia/giaMf.c
+2
-4
No files found.
src/aig/gia/giaGig.c
View file @
e19d21a0
...
@@ -138,7 +138,7 @@ void Gia_ManPrintDelays( Vec_Int_t * vObjs, Vec_Int_t * vStore )
...
@@ -138,7 +138,7 @@ void Gia_ManPrintDelays( Vec_Int_t * vObjs, Vec_Int_t * vStore )
Gia_Man_t
*
Gia_ManBuildGig2
(
Vec_Int_t
*
vObjs
,
Vec_Int_t
*
vStore
,
char
*
pFileName
)
Gia_Man_t
*
Gia_ManBuildGig2
(
Vec_Int_t
*
vObjs
,
Vec_Int_t
*
vStore
,
char
*
pFileName
)
{
{
Gia_Man_t
*
pNew
,
*
pTemp
;
Gia_Man_t
*
pNew
,
*
pTemp
;
int
*
nObjs
=
Gia_ManGigCount
(
vObjs
,
vStore
);
//
int * nObjs = Gia_ManGigCount( vObjs, vStore );
Vec_Int_t
*
vNets
=
Vec_IntAlloc
(
Vec_IntSize
(
vObjs
)
);
Vec_Int_t
*
vNets
=
Vec_IntAlloc
(
Vec_IntSize
(
vObjs
)
);
Vec_Int_t
*
vTypes
=
Vec_IntAlloc
(
Vec_IntSize
(
vObjs
)
);
Vec_Int_t
*
vTypes
=
Vec_IntAlloc
(
Vec_IntSize
(
vObjs
)
);
Vec_Int_t
*
vMap
;
Vec_Int_t
*
vMap
;
...
...
src/aig/gia/giaMf.c
View file @
e19d21a0
...
@@ -339,7 +339,6 @@ Cnf_Dat_t * Mf_ManDeriveCnf( Mf_Man_t * p, int fCnfObjIds, int fAddOrCla )
...
@@ -339,7 +339,6 @@ Cnf_Dat_t * Mf_ManDeriveCnf( Mf_Man_t * p, int fCnfObjIds, int fAddOrCla )
// create CNF IDs
// create CNF IDs
if
(
fCnfObjIds
)
if
(
fCnfObjIds
)
{
{
int
iVar
=
1
;
iVar
+=
1
+
Gia_ManCiNum
(
p
->
pGia
)
+
Gia_ManCoNum
(
p
->
pGia
);
iVar
+=
1
+
Gia_ManCiNum
(
p
->
pGia
)
+
Gia_ManCoNum
(
p
->
pGia
);
Gia_ManForEachCoId
(
p
->
pGia
,
Id
,
i
)
Gia_ManForEachCoId
(
p
->
pGia
,
Id
,
i
)
Vec_IntWriteEntry
(
vCnfIds
,
Id
,
Id
);
Vec_IntWriteEntry
(
vCnfIds
,
Id
,
Id
);
...
@@ -353,7 +352,6 @@ Cnf_Dat_t * Mf_ManDeriveCnf( Mf_Man_t * p, int fCnfObjIds, int fAddOrCla )
...
@@ -353,7 +352,6 @@ Cnf_Dat_t * Mf_ManDeriveCnf( Mf_Man_t * p, int fCnfObjIds, int fAddOrCla )
}
}
else
else
{
{
int
iVar
=
1
;
Gia_ManForEachCoId
(
p
->
pGia
,
Id
,
i
)
Gia_ManForEachCoId
(
p
->
pGia
,
Id
,
i
)
Vec_IntWriteEntry
(
vCnfIds
,
Id
,
iVar
++
);
Vec_IntWriteEntry
(
vCnfIds
,
Id
,
iVar
++
);
Gia_ManForEachAndReverseId
(
p
->
pGia
,
Id
)
Gia_ManForEachAndReverseId
(
p
->
pGia
,
Id
)
...
@@ -479,7 +477,7 @@ Cnf_Dat_t * Mf_ManDeriveCnf( Mf_Man_t * p, int fCnfObjIds, int fAddOrCla )
...
@@ -479,7 +477,7 @@ Cnf_Dat_t * Mf_ManDeriveCnf( Mf_Man_t * p, int fCnfObjIds, int fAddOrCla )
static
inline
int
Mf_CutComputeTruth6
(
Mf_Man_t
*
p
,
Mf_Cut_t
*
pCut0
,
Mf_Cut_t
*
pCut1
,
int
fCompl0
,
int
fCompl1
,
Mf_Cut_t
*
pCutR
,
int
fIsXor
)
static
inline
int
Mf_CutComputeTruth6
(
Mf_Man_t
*
p
,
Mf_Cut_t
*
pCut0
,
Mf_Cut_t
*
pCut1
,
int
fCompl0
,
int
fCompl1
,
Mf_Cut_t
*
pCutR
,
int
fIsXor
)
{
{
// extern int Mf_ManTruthCanonicize( word * t, int nVars );
// extern int Mf_ManTruthCanonicize( word * t, int nVars );
int
nOldSupp
=
pCutR
->
nLeaves
,
nCubes
=
0
,
truthId
,
fCompl
;
word
t
;
int
nOldSupp
=
pCutR
->
nLeaves
,
truthId
,
fCompl
;
word
t
;
word
t0
=
*
Vec_MemReadEntry
(
p
->
vTtMem
,
Abc_Lit2Var
(
pCut0
->
iFunc
));
word
t0
=
*
Vec_MemReadEntry
(
p
->
vTtMem
,
Abc_Lit2Var
(
pCut0
->
iFunc
));
word
t1
=
*
Vec_MemReadEntry
(
p
->
vTtMem
,
Abc_Lit2Var
(
pCut1
->
iFunc
));
word
t1
=
*
Vec_MemReadEntry
(
p
->
vTtMem
,
Abc_Lit2Var
(
pCut1
->
iFunc
));
if
(
Abc_LitIsCompl
(
pCut0
->
iFunc
)
^
fCompl0
)
t0
=
~
t0
;
if
(
Abc_LitIsCompl
(
pCut0
->
iFunc
)
^
fCompl0
)
t0
=
~
t0
;
...
@@ -531,7 +529,7 @@ static inline int Mf_CutComputeTruth( Mf_Man_t * p, Mf_Cut_t * pCut0, Mf_Cut_t *
...
@@ -531,7 +529,7 @@ static inline int Mf_CutComputeTruth( Mf_Man_t * p, Mf_Cut_t * pCut0, Mf_Cut_t *
}
}
static
inline
int
Mf_CutComputeTruthMux6
(
Mf_Man_t
*
p
,
Mf_Cut_t
*
pCut0
,
Mf_Cut_t
*
pCut1
,
Mf_Cut_t
*
pCutC
,
int
fCompl0
,
int
fCompl1
,
int
fComplC
,
Mf_Cut_t
*
pCutR
)
static
inline
int
Mf_CutComputeTruthMux6
(
Mf_Man_t
*
p
,
Mf_Cut_t
*
pCut0
,
Mf_Cut_t
*
pCut1
,
Mf_Cut_t
*
pCutC
,
int
fCompl0
,
int
fCompl1
,
int
fComplC
,
Mf_Cut_t
*
pCutR
)
{
{
int
nOldSupp
=
pCutR
->
nLeaves
,
nCubes
=
0
,
truthId
,
fCompl
;
word
t
;
int
nOldSupp
=
pCutR
->
nLeaves
,
truthId
,
fCompl
;
word
t
;
word
t0
=
*
Vec_MemReadEntry
(
p
->
vTtMem
,
Abc_Lit2Var
(
pCut0
->
iFunc
));
word
t0
=
*
Vec_MemReadEntry
(
p
->
vTtMem
,
Abc_Lit2Var
(
pCut0
->
iFunc
));
word
t1
=
*
Vec_MemReadEntry
(
p
->
vTtMem
,
Abc_Lit2Var
(
pCut1
->
iFunc
));
word
t1
=
*
Vec_MemReadEntry
(
p
->
vTtMem
,
Abc_Lit2Var
(
pCut1
->
iFunc
));
word
tC
=
*
Vec_MemReadEntry
(
p
->
vTtMem
,
Abc_Lit2Var
(
pCutC
->
iFunc
));
word
tC
=
*
Vec_MemReadEntry
(
p
->
vTtMem
,
Abc_Lit2Var
(
pCutC
->
iFunc
));
...
...
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