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
2fbb4b18
Commit
2fbb4b18
authored
Nov 06, 2012
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improved DSD.
parent
db7852bb
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
55 additions
and
0 deletions
+55
-0
src/misc/util/utilTruth.h
+52
-0
src/opt/dau/dau.h
+3
-0
src/opt/dau/dauDsd.c
+0
-0
No files found.
src/misc/util/utilTruth.h
View file @
2fbb4b18
...
...
@@ -142,6 +142,22 @@ static inline void Abc_TtAnd( word * pOut, word * pIn1, word * pIn2, int nWords,
for
(
w
=
0
;
w
<
nWords
;
w
++
)
pOut
[
w
]
=
pIn1
[
w
]
&
pIn2
[
w
];
}
static
inline
void
Abc_TtXor
(
word
*
pOut
,
word
*
pIn1
,
word
*
pIn2
,
int
nWords
,
int
fCompl
)
{
int
w
;
if
(
fCompl
)
for
(
w
=
0
;
w
<
nWords
;
w
++
)
pOut
[
w
]
=
pIn1
[
w
]
^
~
pIn2
[
w
];
else
for
(
w
=
0
;
w
<
nWords
;
w
++
)
pOut
[
w
]
=
pIn1
[
w
]
^
pIn2
[
w
];
}
static
inline
void
Abc_TtMux
(
word
*
pOut
,
word
*
pCtrl
,
word
*
pIn1
,
word
*
pIn0
,
int
nWords
)
{
int
w
;
for
(
w
=
0
;
w
<
nWords
;
w
++
)
pOut
[
w
]
=
(
pCtrl
[
w
]
&
pIn1
[
w
])
|
(
~
pCtrl
[
w
]
&
pIn0
[
w
]);
}
static
inline
int
Abc_TtEqual
(
word
*
pIn1
,
word
*
pIn2
,
int
nWords
)
{
int
w
;
...
...
@@ -182,6 +198,42 @@ static inline int Abc_TtIsConst1( word * pIn1, int nWords )
return
0
;
return
1
;
}
static
inline
void
Abc_TtConst0
(
word
*
pIn1
,
int
nWords
)
{
int
w
;
for
(
w
=
0
;
w
<
nWords
;
w
++
)
pIn1
[
w
]
=
0
;
}
static
inline
void
Abc_TtConst1
(
word
*
pIn1
,
int
nWords
)
{
int
w
;
for
(
w
=
0
;
w
<
nWords
;
w
++
)
pIn1
[
w
]
=
~
(
word
)
0
;
}
/**Function*************************************************************
Synopsis [Compute elementary truth tables.]
Description []
SideEffects []
SeeAlso []
***********************************************************************/
static
inline
void
Abc_TtElemInit
(
word
**
pTtElems
,
int
nVars
)
{
int
i
,
k
,
nWords
=
Abc_TtWordNum
(
nVars
);
for
(
i
=
0
;
i
<
nVars
;
i
++
)
if
(
i
<
6
)
for
(
k
=
0
;
k
<
nWords
;
k
++
)
pTtElems
[
i
][
k
]
=
s_Truths6
[
i
];
else
for
(
k
=
0
;
k
<
nWords
;
k
++
)
pTtElems
[
i
][
k
]
=
(
k
&
(
1
<<
(
i
-
6
)))
?
~
(
word
)
0
:
0
;
}
/**Function*************************************************************
...
...
src/opt/dau/dau.h
View file @
2fbb4b18
...
...
@@ -55,7 +55,10 @@ ABC_NAMESPACE_HEADER_START
/*=== dauCanon.c ==========================================================*/
extern
unsigned
Abc_TtCanonicize
(
word
*
pTruth
,
int
nVars
,
char
*
pCanonPerm
);
/*=== dauDsd.c ==========================================================*/
extern
char
*
Dau_DsdDecompose
(
word
*
pTruth
,
int
nVarsInit
,
int
*
pnSizeNonDec
);
extern
word
*
Dau_DsdToTruth
(
char
*
p
,
int
nVars
);
ABC_NAMESPACE_HEADER_END
...
...
src/opt/dau/dauDsd.c
View file @
2fbb4b18
This diff is collapsed.
Click to expand it.
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