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
f917de34
Commit
f917de34
authored
Jul 20, 2013
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improvements to the SCL package.
parent
56592b28
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
29 additions
and
11 deletions
+29
-11
src/map/mpm/mpmGates.c
+1
-1
src/map/scl/scl.c
+0
-0
src/map/scl/sclDnsize.c
+2
-1
src/map/scl/sclInt.h
+3
-1
src/map/scl/sclUpsize.c
+4
-4
src/map/scl/sclUtil.c
+19
-4
No files found.
src/map/mpm/mpmGates.c
View file @
f917de34
...
...
@@ -218,7 +218,7 @@ Abc_Ntk_t * Mpm_ManDeriveMappedAbcNtk( Mpm_Man_t * p, Mio_Library_t * pMio )
pObj
=
Abc_NtkCreateNode
(
pNtk
);
pObj
->
pData
=
Vec_PtrEntry
(
vNpnGatesMio
,
Abc_Lit2Var
(
pCutBest
->
iFunc
)
);
assert
(
pObj
->
pData
!=
NULL
);
fCompl
=
Abc_LitIsCompl
(
pCutBest
->
iFunc
)
^
((
Config
>>
16
)
&
1
);
fCompl
=
pCutBest
->
fCompl
^
Abc_LitIsCompl
(
pCutBest
->
iFunc
)
^
((
Config
>>
16
)
&
1
);
Config
&=
0xFFFF
;
for
(
k
=
0
;
k
<
(
int
)
pCutBest
->
nLeaves
;
k
++
)
{
...
...
src/map/scl/scl.c
View file @
f917de34
This diff is collapsed.
Click to expand it.
src/map/scl/sclDnsize.c
View file @
f917de34
...
...
@@ -254,12 +254,13 @@ void Abc_SclDnsizePerform( SC_Lib * pLib, Abc_Ntk_t * pNtk, SC_DnSizePars * pPar
printf
(
"Delay =%8.2f ps. "
,
pPars
->
DUser
);
printf
(
"Iters =%5d. "
,
pPars
->
nIters
);
printf
(
"UseDept =%2d. "
,
pPars
->
fUseDept
);
printf
(
"UseWL =%2d. "
,
pPars
->
fUseWireLoads
);
printf
(
"Timeout =%4d sec"
,
pPars
->
TimeOut
);
printf
(
"
\n
"
);
}
// prepare the manager; collect init stats
p
=
Abc_SclManStart
(
pLib
,
pNtk
,
1
,
pPars
->
fUseDept
,
SC_LibTimeFromPs
(
pLib
,
pPars
->
DUser
)
);
p
=
Abc_SclManStart
(
pLib
,
pNtk
,
pPars
->
fUseWireLoads
,
pPars
->
fUseDept
,
SC_LibTimeFromPs
(
pLib
,
pPars
->
DUser
)
);
p
->
timeTotal
=
Abc_Clock
();
assert
(
p
->
vGatesBest
==
NULL
);
p
->
vGatesBest
=
Vec_IntDup
(
p
->
vGates
);
...
...
src/map/scl/sclInt.h
View file @
f917de34
...
...
@@ -85,6 +85,7 @@ struct SC_UpSizePars_
int
TimeOut
;
int
fUseDept
;
int
fDumpStats
;
int
fUseWireLoads
;
int
fVerbose
;
int
fVeryVerbose
;
};
...
...
@@ -98,6 +99,7 @@ struct SC_DnSizePars_
int
TimeOut
;
int
fUseDept
;
int
fDumpStats
;
int
fUseWireLoads
;
int
fVerbose
;
int
fVeryVerbose
;
};
...
...
@@ -480,7 +482,7 @@ extern void Abc_SclPrintCells( SC_Lib * p );
extern
Vec_Int_t
*
Abc_SclManFindGates
(
SC_Lib
*
pLib
,
Abc_Ntk_t
*
p
);
extern
void
Abc_SclManSetGates
(
SC_Lib
*
pLib
,
Abc_Ntk_t
*
p
,
Vec_Int_t
*
vGates
);
extern
void
Abc_SclPrintGateSizes
(
SC_Lib
*
pLib
,
Abc_Ntk_t
*
p
);
extern
void
Abc_SclMinsizePerform
(
SC_Lib
*
pLib
,
Abc_Ntk_t
*
p
,
int
fVerbose
);
extern
void
Abc_SclMinsizePerform
(
SC_Lib
*
pLib
,
Abc_Ntk_t
*
p
,
int
f
UseMax
,
int
f
Verbose
);
ABC_NAMESPACE_HEADER_END
...
...
src/map/scl/sclUpsize.c
View file @
f917de34
...
...
@@ -475,16 +475,16 @@ void Abc_SclUpsizePerform( SC_Lib * pLib, Abc_Ntk_t * pNtk, SC_UpSizePars * pPar
{
printf
(
"Upsizing parameters: "
);
printf
(
"Iters =%5d. "
,
pPars
->
nIters
);
printf
(
"Time win
dow =%3d %%. "
,
pPars
->
Window
);
printf
(
"Time win
=%3d %%. "
,
pPars
->
Window
);
printf
(
"Update ratio =%3d %%. "
,
pPars
->
Ratio
);
printf
(
"Max steps =%3d. "
,
pPars
->
Notches
);
printf
(
"UseDept =%2d. "
,
pPars
->
fUseDept
);
printf
(
"UseWL =%2d. "
,
pPars
->
fUseWireLoads
);
printf
(
"Timeout =%4d sec"
,
pPars
->
TimeOut
);
printf
(
"
\n
"
);
}
// prepare the manager; collect init stats
p
=
Abc_SclManStart
(
pLib
,
pNtk
,
1
,
pPars
->
fUseDept
,
0
);
p
=
Abc_SclManStart
(
pLib
,
pNtk
,
pPars
->
fUseWireLoads
,
pPars
->
fUseDept
,
0
);
p
->
timeTotal
=
Abc_Clock
();
assert
(
p
->
vGatesBest
==
NULL
);
p
->
vGatesBest
=
Vec_IntDup
(
p
->
vGates
);
...
...
@@ -572,7 +572,7 @@ void Abc_SclUpsizePerform( SC_Lib * pLib, Abc_Ntk_t * pNtk, SC_UpSizePars * pPar
if
(
pPars
->
fVerbose
)
Abc_SclUpsizePrint
(
p
,
i
,
pPars
->
Window
,
nAllPos
/
(
i
?
i
:
1
),
nAllNodes
/
(
i
?
i
:
1
),
nAllUpsizes
/
(
i
?
i
:
1
),
nAllTfos
/
(
i
?
i
:
1
),
1
);
else
printf
(
"
\r
"
);
printf
(
"
\r
"
);
// report runtime
p
->
timeTotal
=
Abc_Clock
()
-
p
->
timeTotal
;
if
(
pPars
->
fVerbose
)
...
...
src/map/scl/sclUtil.c
View file @
f917de34
...
...
@@ -303,17 +303,33 @@ void Abc_SclPrintGateSizes( SC_Lib * pLib, Abc_Ntk_t * p )
SeeAlso []
***********************************************************************/
void
Abc_SclMinsizePerform
(
SC_Lib
*
pLib
,
Abc_Ntk_t
*
p
,
int
fVerbose
)
SC_Cell
*
Abc_SclFindMaxAreaCell
(
SC_Cell
*
pRepr
)
{
SC_Cell
*
pCell
,
*
pBest
=
pRepr
;
float
AreaBest
=
pRepr
->
area
;
int
i
;
SC_RingForEachCell
(
pRepr
,
pCell
,
i
)
if
(
AreaBest
<
pCell
->
area
)
{
AreaBest
=
pCell
->
area
;
pBest
=
pCell
;
}
return
pBest
;
}
void
Abc_SclMinsizePerform
(
SC_Lib
*
pLib
,
Abc_Ntk_t
*
p
,
int
fUseMax
,
int
fVerbose
)
{
Vec_Int_t
*
vMinCells
,
*
vGates
;
SC_Cell
*
pCell
,
*
pRepr
=
NULL
;
SC_Cell
*
pCell
,
*
pRepr
=
NULL
,
*
pBest
=
NULL
;
Abc_Obj_t
*
pObj
;
int
i
,
k
,
gateId
;
// map each gate in the library into its min-size prototype
vMinCells
=
Vec_IntStartFull
(
Vec_PtrSize
(
pLib
->
vCells
)
);
SC_LibForEachCellClass
(
pLib
,
pRepr
,
i
)
{
pBest
=
fUseMax
?
Abc_SclFindMaxAreaCell
(
pRepr
)
:
pRepr
;
SC_RingForEachCell
(
pRepr
,
pCell
,
k
)
Vec_IntWriteEntry
(
vMinCells
,
pCell
->
Id
,
pRepr
->
Id
);
Vec_IntWriteEntry
(
vMinCells
,
pCell
->
Id
,
pBest
->
Id
);
}
// update each cell
vGates
=
Abc_SclManFindGates
(
pLib
,
p
);
Abc_NtkForEachNode1
(
p
,
pObj
,
i
)
...
...
@@ -329,7 +345,6 @@ void Abc_SclMinsizePerform( SC_Lib * pLib, Abc_Ntk_t * p, int fVerbose )
Vec_IntFree
(
vGates
);
}
////////////////////////////////////////////////////////////////////////
/// END OF FILE ///
////////////////////////////////////////////////////////////////////////
...
...
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