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
2ba46d52
Commit
2ba46d52
authored
Jul 19, 2016
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Extension in the detection code.
parent
190dc376
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
6 deletions
+15
-6
src/aig/gia/giaSweep.c
+3
-0
src/base/abci/abc.c
+9
-5
src/base/abci/abcDetect.c
+1
-1
src/base/io/ioReadBench.c
+2
-0
No files found.
src/aig/gia/giaSweep.c
View file @
2ba46d52
...
@@ -665,6 +665,8 @@ Gia_Man_t * Gia_ManSweepWithBoxesAndDomains( Gia_Man_t * p, void * pParsS, int f
...
@@ -665,6 +665,8 @@ Gia_Man_t * Gia_ManSweepWithBoxesAndDomains( Gia_Man_t * p, void * pParsS, int f
continue
;
continue
;
// find global equivalences
// find global equivalences
pClp
=
Gia_ManDupCollapse
(
pNew
,
pNew
->
pAigExtra
,
NULL
,
1
);
pClp
=
Gia_ManDupCollapse
(
pNew
,
pNew
->
pAigExtra
,
NULL
,
1
);
//Gia_DumpAiger( pClp, p->pSpec, iDom, 2 );
//Gia_ManPrintStats( pClp, NULL );
// compute equivalences
// compute equivalences
Gia_ManSweepComputeOneDomainEquivs
(
pClp
,
pNew
->
vRegClasses
,
iDom
,
pParsS
,
fConst
,
fEquiv
,
fVerbose
);
Gia_ManSweepComputeOneDomainEquivs
(
pClp
,
pNew
->
vRegClasses
,
iDom
,
pParsS
,
fConst
,
fEquiv
,
fVerbose
);
// transfer equivalences
// transfer equivalences
...
@@ -728,6 +730,7 @@ Gia_Man_t * Gia_ManSweepWithBoxes( Gia_Man_t * p, void * pParsC, void * pParsS,
...
@@ -728,6 +730,7 @@ Gia_Man_t * Gia_ManSweepWithBoxes( Gia_Man_t * p, void * pParsC, void * pParsS,
nFlops
=
Vec_IntCountEntry
(
pNew
->
vRegClasses
,
1
);
nFlops
=
Vec_IntCountEntry
(
pNew
->
vRegClasses
,
1
);
// find global equivalences
// find global equivalences
pClp
=
Gia_ManDupCollapse
(
pNew
,
pNew
->
pAigExtra
,
NULL
,
pParsC
?
0
:
1
);
pClp
=
Gia_ManDupCollapse
(
pNew
,
pNew
->
pAigExtra
,
NULL
,
pParsC
?
0
:
1
);
//Gia_DumpAiger( pClp, p->pSpec, 1, 1 );
// compute equivalences
// compute equivalences
if
(
pParsC
)
if
(
pParsC
)
Gia_ManFraigSweepPerform
(
pClp
,
pParsC
);
Gia_ManFraigSweepPerform
(
pClp
,
pParsC
);
...
...
src/base/abci/abc.c
View file @
2ba46d52
...
@@ -7226,15 +7226,18 @@ usage:
...
@@ -7226,15 +7226,18 @@ usage:
***********************************************************************/
***********************************************************************/
int
Abc_CommandDetect
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
)
int
Abc_CommandDetect
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
)
{
{
extern
void
Abc_NtkDetectClassesTest
(
Abc_Ntk_t
*
pNtk
,
int
fVerbose
);
extern
void
Abc_NtkDetectClassesTest
(
Abc_Ntk_t
*
pNtk
,
int
f
Seq
,
int
f
Verbose
);
Abc_Ntk_t
*
pNtk
;
Abc_Ntk_t
*
pNtk
;
int
c
,
fVerbose
=
0
;
int
c
,
f
Seq
=
0
,
f
Verbose
=
0
;
pNtk
=
Abc_FrameReadNtk
(
pAbc
);
pNtk
=
Abc_FrameReadNtk
(
pAbc
);
Extra_UtilGetoptReset
();
Extra_UtilGetoptReset
();
while
(
(
c
=
Extra_UtilGetopt
(
argc
,
argv
,
"vh"
)
)
!=
EOF
)
while
(
(
c
=
Extra_UtilGetopt
(
argc
,
argv
,
"
s
vh"
)
)
!=
EOF
)
{
{
switch
(
c
)
switch
(
c
)
{
{
case
's'
:
fSeq
^=
1
;
break
;
case
'v'
:
case
'v'
:
fVerbose
^=
1
;
fVerbose
^=
1
;
break
;
break
;
...
@@ -7254,12 +7257,13 @@ int Abc_CommandDetect( Abc_Frame_t * pAbc, int argc, char ** argv )
...
@@ -7254,12 +7257,13 @@ int Abc_CommandDetect( Abc_Frame_t * pAbc, int argc, char ** argv )
Abc_Print
(
-
1
,
"Only applicable to a logic network.
\n
"
);
Abc_Print
(
-
1
,
"Only applicable to a logic network.
\n
"
);
return
1
;
return
1
;
}
}
Abc_NtkDetectClassesTest
(
pNtk
,
fVerbose
);
Abc_NtkDetectClassesTest
(
pNtk
,
f
Seq
,
f
Verbose
);
return
0
;
return
0
;
usage:
usage:
Abc_Print
(
-
2
,
"usage: detect [-vh]
\n
"
);
Abc_Print
(
-
2
,
"usage: detect [-
s
vh]
\n
"
);
Abc_Print
(
-
2
,
"
\t
detects properties of internal nodes
\n
"
);
Abc_Print
(
-
2
,
"
\t
detects properties of internal nodes
\n
"
);
Abc_Print
(
-
2
,
"
\t
-s : toggle using sequential circuit information [default = %s]
\n
"
,
fSeq
?
"yes"
:
"no"
);
Abc_Print
(
-
2
,
"
\t
-v : toggle verbose printout [default = %s]
\n
"
,
fVerbose
?
"yes"
:
"no"
);
Abc_Print
(
-
2
,
"
\t
-v : toggle verbose printout [default = %s]
\n
"
,
fVerbose
?
"yes"
:
"no"
);
Abc_Print
(
-
2
,
"
\t
-h : print the command usage
\n
"
);
Abc_Print
(
-
2
,
"
\t
-h : print the command usage
\n
"
);
return
1
;
return
1
;
src/base/abci/abcDetect.c
View file @
2ba46d52
...
@@ -193,7 +193,7 @@ finish:
...
@@ -193,7 +193,7 @@ finish:
SeeAlso []
SeeAlso []
***********************************************************************/
***********************************************************************/
void
Abc_NtkDetectClassesTest
(
Abc_Ntk_t
*
pNtk
,
int
fVerbose
)
void
Abc_NtkDetectClassesTest
(
Abc_Ntk_t
*
pNtk
,
int
f
Seq
,
int
f
Verbose
)
{
{
printf
(
"This procedure is currently not used.
\n
"
);
printf
(
"This procedure is currently not used.
\n
"
);
}
}
...
...
src/base/io/ioReadBench.c
View file @
2ba46d52
...
@@ -94,6 +94,7 @@ Abc_Ntk_t * Io_ReadBenchNetwork( Extra_FileReader_t * p )
...
@@ -94,6 +94,7 @@ Abc_Ntk_t * Io_ReadBenchNetwork( Extra_FileReader_t * p )
// allocate the empty network
// allocate the empty network
pNtk
=
Abc_NtkStartRead
(
Extra_FileReaderGetFileName
(
p
)
);
pNtk
=
Abc_NtkStartRead
(
Extra_FileReaderGetFileName
(
p
)
);
pNtk
->
nConstrs
=
0
;
// go through the lines of the file
// go through the lines of the file
vString
=
Vec_StrAlloc
(
100
);
vString
=
Vec_StrAlloc
(
100
);
...
@@ -140,6 +141,7 @@ Abc_Ntk_t * Io_ReadBenchNetwork( Extra_FileReader_t * p )
...
@@ -140,6 +141,7 @@ Abc_Ntk_t * Io_ReadBenchNetwork( Extra_FileReader_t * p )
pTerm
=
Abc_NtkCreatePo
(
pNtk
);
pTerm
=
Abc_NtkCreatePo
(
pNtk
);
Abc_ObjAddFanin
(
pTerm
,
pNet
);
Abc_ObjAddFanin
(
pTerm
,
pNet
);
}
}
pNtk
->
nConstrs
++
;
}
}
else
else
{
{
...
...
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