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
f39369a4
Commit
f39369a4
authored
May 09, 2014
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adding switch -C <num> to 'amap' to control max number of cuts at a node.
parent
140fd9ad
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
19 additions
and
5 deletions
+19
-5
src/base/abci/abc.c
+14
-2
src/map/amap/amap.h
+1
-0
src/map/amap/amapCore.c
+1
-0
src/map/amap/amapMerge.c
+3
-3
No files found.
src/base/abci/abc.c
View file @
f39369a4
...
...
@@ -14063,7 +14063,7 @@ int Abc_CommandAmap( Abc_Frame_t * pAbc, int argc, char ** argv )
fSweep
=
0
;
Amap_ManSetDefaultParams
(
pPars
);
Extra_UtilGetoptReset
();
while
(
(
c
=
Extra_UtilGetopt
(
argc
,
argv
,
"FAEQmxisvh"
)
)
!=
EOF
)
while
(
(
c
=
Extra_UtilGetopt
(
argc
,
argv
,
"FA
C
EQmxisvh"
)
)
!=
EOF
)
{
switch
(
c
)
{
...
...
@@ -14089,6 +14089,17 @@ int Abc_CommandAmap( Abc_Frame_t * pAbc, int argc, char ** argv )
if
(
pPars
->
nIterArea
<
0
)
goto
usage
;
break
;
case
'C'
:
if
(
globalUtilOptind
>=
argc
)
{
Abc_Print
(
-
1
,
"Command line switch
\"
-C
\"
should be followed by a floating point number.
\n
"
);
goto
usage
;
}
pPars
->
nCutsMax
=
atoi
(
argv
[
globalUtilOptind
]);
globalUtilOptind
++
;
if
(
pPars
->
nCutsMax
<
0
)
goto
usage
;
break
;
case
'E'
:
if
(
globalUtilOptind
>=
argc
)
{
...
...
@@ -14190,10 +14201,11 @@ int Abc_CommandAmap( Abc_Frame_t * pAbc, int argc, char ** argv )
return
0
;
usage:
Abc_Print
(
-
2
,
"usage: amap [-FA <num>] [-EQ <float>] [-mxisvh]
\n
"
);
Abc_Print
(
-
2
,
"usage: amap [-FA
C
<num>] [-EQ <float>] [-mxisvh]
\n
"
);
Abc_Print
(
-
2
,
"
\t
performs standard cell mapping of the current network
\n
"
);
Abc_Print
(
-
2
,
"
\t
-F num : the number of iterations of area flow [default = %d]
\n
"
,
pPars
->
nIterFlow
);
Abc_Print
(
-
2
,
"
\t
-A num : the number of iterations of exact area [default = %d]
\n
"
,
pPars
->
nIterArea
);
Abc_Print
(
-
2
,
"
\t
-C num : the maximum number of cuts at a node [default = %d]
\n
"
,
pPars
->
nCutsMax
);
Abc_Print
(
-
2
,
"
\t
-E float : sets epsilon used for tie-breaking [default = %f]
\n
"
,
pPars
->
fEpsilon
);
Abc_Print
(
-
2
,
"
\t
-Q float : area/delay preference ratio [default = %.2f (area-only)]
\n
"
,
pPars
->
fADratio
);
Abc_Print
(
-
2
,
"
\t
-m : toggles using MUX matching [default = %s]
\n
"
,
pPars
->
fUseMuxes
?
"yes"
:
"no"
);
src/map/amap/amap.h
View file @
f39369a4
...
...
@@ -46,6 +46,7 @@ struct Amap_Par_t_
{
int
nIterFlow
;
// iterations of area flow
int
nIterArea
;
// iteratoins of exact area
int
nCutsMax
;
// the maximum number of cuts at a node
int
fUseMuxes
;
// enables the use of MUXes
int
fUseXors
;
// enables the use of XORs
int
fFreeInvs
;
// assume inverters are free (area = 0)
...
...
src/map/amap/amapCore.c
View file @
f39369a4
...
...
@@ -48,6 +48,7 @@ void Amap_ManSetDefaultParams( Amap_Par_t * p )
memset
(
p
,
0
,
sizeof
(
Amap_Par_t
)
);
p
->
nIterFlow
=
1
;
// iterations of area flow
p
->
nIterArea
=
4
;
// iteratoins of exact area
p
->
nCutsMax
=
500
;
// the maximum number of cuts at a node
p
->
fUseMuxes
=
0
;
// enables the use of MUXes
p
->
fUseXors
=
1
;
// enables the use of XORs
p
->
fFreeInvs
=
0
;
// assume inverters are free (area = 0)
...
...
src/map/amap/amapMerge.c
View file @
f39369a4
...
...
@@ -173,7 +173,7 @@ Amap_Cut_t * Amap_ManCutCreate3( Amap_Man_t * p,
***********************************************************************/
void
Amap_ManCutSaveStored
(
Amap_Man_t
*
p
,
Amap_Obj_t
*
pNode
)
{
int
nMaxCuts
=
500
;
int
nMaxCuts
=
p
->
pPars
->
nCutsMax
;
int
*
pBuffer
;
Amap_Cut_t
*
pNext
,
*
pCut
;
int
i
,
nWords
,
Entry
,
nCuts
,
nCuts2
;
...
...
@@ -522,8 +522,8 @@ void Amap_ManMerge( Amap_Man_t * p )
if
(
p
->
pPars
->
fVerbose
)
{
printf
(
"AIG object is %d bytes. "
,
(
int
)
sizeof
(
Amap_Obj_t
)
);
printf
(
"Internal AIG = %5.2f MB. Cuts = %5.2f MB.
\n
"
,
1
.
0
*
Amap_ManObjNum
(
p
)
*
sizeof
(
Amap_Obj_t
)
/
(
1
<<
20
),
1
.
0
*
p
->
nBytesUsed
/
(
1
<<
20
)
);
printf
(
"Internal AIG = %5.2f MB. Cuts = %5.2f MB.
CutsMax = %d.
\n
"
,
1
.
0
*
Amap_ManObjNum
(
p
)
*
sizeof
(
Amap_Obj_t
)
/
(
1
<<
20
),
1
.
0
*
p
->
nBytesUsed
/
(
1
<<
20
)
,
p
->
pPars
->
nCutsMax
);
printf
(
"Node =%6d. Try =%9d. Try3 =%10d. Used =%7d. R =%6.2f. "
,
Amap_ManNodeNum
(
p
),
p
->
nCutsTried
,
p
->
nCutsTried3
,
p
->
nCutsUsed
,
1
.
0
*
p
->
nCutsUsed
/
Amap_ManNodeNum
(
p
)
);
...
...
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