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
c344f3e3
Commit
c344f3e3
authored
Aug 20, 2014
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Propagating timing support to the new synthesis/mapping commands.
parent
6dbaa4d0
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
34 additions
and
41 deletions
+34
-41
src/aig/gia/gia.h
+2
-0
src/aig/gia/giaAig.c
+2
-6
src/aig/gia/giaAiger.c
+5
-4
src/aig/gia/giaBalance.c
+6
-0
src/aig/gia/giaIf.c
+9
-19
src/aig/gia/giaSweep.c
+1
-3
src/base/abci/abc.c
+7
-7
src/misc/tim/timMan.c
+1
-1
src/misc/tim/timTime.c
+1
-1
No files found.
src/aig/gia/gia.h
View file @
c344f3e3
...
...
@@ -1184,6 +1184,8 @@ extern void Gia_ManSetRefsMapped( Gia_Man_t * p );
extern
void
Gia_ManSetIfParsDefault
(
void
*
pIfPars
);
extern
void
Gia_ManMappingVerify
(
Gia_Man_t
*
p
);
extern
void
Gia_ManTransferMapping
(
Gia_Man_t
*
pGia
,
Gia_Man_t
*
p
);
extern
void
Gia_ManTransferPacking
(
Gia_Man_t
*
pGia
,
Gia_Man_t
*
p
);
extern
void
Gia_ManTransferTiming
(
Gia_Man_t
*
pGia
,
Gia_Man_t
*
p
);
extern
Gia_Man_t
*
Gia_ManPerformMapping
(
Gia_Man_t
*
p
,
void
*
pIfPars
,
int
fNormalized
);
extern
Gia_Man_t
*
Gia_ManPerformSopBalance
(
Gia_Man_t
*
p
,
int
nCutNum
,
int
nRelaxRatio
,
int
fVerbose
);
extern
Gia_Man_t
*
Gia_ManPerformDsdBalance
(
Gia_Man_t
*
p
,
int
nCutNum
,
int
nRelaxRatio
,
int
fVerbose
);
...
...
src/aig/gia/giaAig.c
View file @
c344f3e3
...
...
@@ -559,9 +559,7 @@ Gia_Man_t * Gia_ManCompress2( Gia_Man_t * p, int fUpdateLevel, int fVerbose )
Aig_ManStop
(
pTemp
);
pGia
=
Gia_ManFromAig
(
pNew
);
Aig_ManStop
(
pNew
);
pGia
->
pManTime
=
p
->
pManTime
;
p
->
pManTime
=
NULL
;
pGia
->
pAigExtra
=
p
->
pAigExtra
;
p
->
pAigExtra
=
NULL
;
pGia
->
nAnd2Delay
=
p
->
nAnd2Delay
;
p
->
nAnd2Delay
=
0
;
Gia_ManTransferTiming
(
p
,
pGia
);
return
pGia
;
}
...
...
@@ -587,9 +585,7 @@ Gia_Man_t * Gia_ManPerformDch( Gia_Man_t * p, void * pPars )
// pGia = Gia_ManFromAig( pNew );
pGia
=
Gia_ManFromAigChoices
(
pNew
);
Aig_ManStop
(
pNew
);
pGia
->
pManTime
=
p
->
pManTime
;
p
->
pManTime
=
NULL
;
pGia
->
pAigExtra
=
p
->
pAigExtra
;
p
->
pAigExtra
=
NULL
;
pGia
->
nAnd2Delay
=
p
->
nAnd2Delay
;
p
->
nAnd2Delay
=
0
;
Gia_ManTransferTiming
(
p
,
pGia
);
return
pGia
;
}
...
...
src/aig/gia/giaAiger.c
View file @
c344f3e3
...
...
@@ -785,7 +785,10 @@ Gia_Man_t * Gia_AigerReadFromMemory( char * pContents, int nFileSize, int fSkipS
}
Vec_IntFreeP
(
&
vInits
);
if
(
!
fSkipStrash
&&
pNew
->
vMapping
)
Abc_Print
(
0
,
"Structural hashing enabled while reading AIGER may have invalidated the mapping. Consider using
\"
&r -s
\"
.
\n
"
);
{
Abc_Print
(
0
,
"Structural hashing enabled while reading AIGER invalidated the mapping. Consider using
\"
&r -s
\"
.
\n
"
);
Vec_IntFreeP
(
&
pNew
->
vMapping
);
}
return
pNew
;
}
...
...
@@ -1035,11 +1038,9 @@ void Gia_AigerWrite( Gia_Man_t * pInit, char * pFileName, int fWriteSymbols, int
{
// printf( "Gia_AigerWrite(): Normalizing AIG for writing.\n" );
p
=
Gia_ManDupNormalize
(
pInit
);
p
->
pManTime
=
pInit
->
pManTime
;
pInit
->
pManTime
=
NULL
;
Gia_ManTransferTiming
(
pInit
,
p
)
;
p
->
vNamesIn
=
pInit
->
vNamesIn
;
pInit
->
vNamesIn
=
NULL
;
p
->
vNamesOut
=
pInit
->
vNamesOut
;
pInit
->
vNamesOut
=
NULL
;
p
->
pAigExtra
=
pInit
->
pAigExtra
;
pInit
->
pAigExtra
=
NULL
;
p
->
nAnd2Delay
=
pInit
->
nAnd2Delay
;
pInit
->
nAnd2Delay
=
0
;
p
->
nConstrs
=
pInit
->
nConstrs
;
pInit
->
nConstrs
=
0
;
}
else
...
...
src/aig/gia/giaBalance.c
View file @
c344f3e3
...
...
@@ -970,6 +970,12 @@ Gia_Man_t * Gia_ManAreaBalance( Gia_Man_t * p, int fSimpleAnd, int nNewNodesMax,
pNew2
=
Gia_ManDupNoMuxes
(
pNew1
);
if
(
fVerbose
)
Gia_ManPrintStats
(
pNew2
,
NULL
);
Gia_ManStop
(
pNew1
);
// normalize if needed
if
(
!
Gia_ManIsNormalized
(
pNew2
)
)
{
pNew2
=
Gia_ManDupNormalize
(
pNew1
=
pNew2
);
Gia_ManStop
(
pNew1
);
}
return
pNew2
;
}
...
...
src/aig/gia/giaIf.c
View file @
c344f3e3
...
...
@@ -1583,18 +1583,6 @@ void Gia_ManTransferMapping( Gia_Man_t * pGia, Gia_Man_t * p )
}
Gia_ManMappingVerify
(
p
);
}
/**Function*************************************************************
Synopsis [Transfers packing from hie GIA to normalized GIA.]
Description [Hie GIA (pGia) points to normalized GIA (p).]
SideEffects []
SeeAlso []
***********************************************************************/
void
Gia_ManTransferPacking
(
Gia_Man_t
*
pGia
,
Gia_Man_t
*
p
)
{
Vec_Int_t
*
vPackingNew
;
...
...
@@ -1629,6 +1617,12 @@ void Gia_ManTransferPacking( Gia_Man_t * pGia, Gia_Man_t * p )
assert
(
p
->
vPacking
==
NULL
);
p
->
vPacking
=
vPackingNew
;
}
void
Gia_ManTransferTiming
(
Gia_Man_t
*
pGia
,
Gia_Man_t
*
p
)
{
p
->
pManTime
=
pGia
->
pManTime
;
pGia
->
pManTime
=
NULL
;
p
->
pAigExtra
=
pGia
->
pAigExtra
;
pGia
->
pAigExtra
=
NULL
;
p
->
nAnd2Delay
=
pGia
->
nAnd2Delay
;
pGia
->
nAnd2Delay
=
0
;
}
/**Function*************************************************************
...
...
@@ -1699,7 +1693,7 @@ Gia_Man_t * Gia_ManPerformMapping( Gia_Man_t * p, void * pp, int fNormalized )
Abc_Print
(
0
,
"Switching activity computation for designs with boxes is disabled.
\n
"
);
}
if
(
p
->
pManTime
)
pIfMan
->
pManTim
=
Tim_ManDup
(
(
Tim_Man_t
*
)
p
->
pManTime
,
0
);
pIfMan
->
pManTim
=
Tim_ManDup
(
(
Tim_Man_t
*
)
p
->
pManTime
,
pPars
->
fDelayOpt
||
pPars
->
fDelayOptLut
||
pPars
->
fDsdBalance
||
pPars
->
fUserRecLib
);
if
(
!
If_ManPerformMapping
(
pIfMan
)
)
{
If_ManStop
(
pIfMan
);
...
...
@@ -1718,17 +1712,13 @@ Gia_Man_t * Gia_ManPerformMapping( Gia_Man_t * p, void * pp, int fNormalized )
pNew
->
pSpec
=
Abc_UtilStrsav
(
p
->
pSpec
);
Gia_ManSetRegNum
(
pNew
,
Gia_ManRegNum
(
p
)
);
// return the original (unmodified by the mapper) timing manager
pNew
->
pManTime
=
p
->
pManTime
;
p
->
pManTime
=
NULL
;
pNew
->
pAigExtra
=
p
->
pAigExtra
;
p
->
pAigExtra
=
NULL
;
pNew
->
nAnd2Delay
=
p
->
nAnd2Delay
;
p
->
nAnd2Delay
=
0
;
Gia_ManTransferTiming
(
p
,
pNew
);
Gia_ManStop
(
p
);
// normalize and transfer mapping
pNew
=
Gia_ManDupNormalize
(
p
=
pNew
);
Gia_ManTransferMapping
(
p
,
pNew
);
Gia_ManTransferPacking
(
p
,
pNew
);
pNew
->
pManTime
=
p
->
pManTime
;
p
->
pManTime
=
NULL
;
pNew
->
pAigExtra
=
p
->
pAigExtra
;
p
->
pAigExtra
=
NULL
;
pNew
->
nAnd2Delay
=
p
->
nAnd2Delay
;
p
->
nAnd2Delay
=
0
;
Gia_ManTransferTiming
(
p
,
pNew
);
Gia_ManStop
(
p
);
return
pNew
;
}
...
...
src/aig/gia/giaSweep.c
View file @
c344f3e3
...
...
@@ -328,9 +328,7 @@ Gia_Man_t * Gia_ManFraigSweep( Gia_Man_t * p, void * pPars )
Gia_ManStop
(
pTemp
);
// normalize the result
pNew
=
Gia_ManDupNormalize
(
pTemp
=
pNew
);
pNew
->
pManTime
=
pTemp
->
pManTime
;
pTemp
->
pManTime
=
NULL
;
pNew
->
pAigExtra
=
pTemp
->
pAigExtra
;
pTemp
->
pAigExtra
=
NULL
;
pNew
->
nAnd2Delay
=
pTemp
->
nAnd2Delay
;
pTemp
->
nAnd2Delay
=
0
;
Gia_ManTransferTiming
(
pTemp
,
pNew
);
Gia_ManStop
(
pTemp
);
// return the result
assert
(
pNew
->
pManTime
!=
NULL
);
...
...
src/base/abci/abc.c
View file @
c344f3e3
...
...
@@ -28068,13 +28068,13 @@ usage:
int
Abc_CommandAbc9Syn2
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
)
{
Gia_Man_t
*
pTemp
;
int
c
,
fVerbose
=
0
;
int
fOldAlgo
=
0
;
int
fCoarsen
=
1
;
int
fCutMin
=
0
;
int
nRelaxRatio
=
20
;
int
fDelayMin
=
1
;
int
fVeryVerbose
=
0
;
int
c
,
fVerbose
=
0
;
int
fOldAlgo
=
0
;
int
fCoarsen
=
1
;
int
fCutMin
=
0
;
int
nRelaxRatio
=
20
;
int
fDelayMin
=
0
;
int
fVeryVerbose
=
0
;
Extra_UtilGetoptReset
();
while
(
(
c
=
Extra_UtilGetopt
(
argc
,
argv
,
"Rakmdvwh"
)
)
!=
EOF
)
{
src/misc/tim/timMan.c
View file @
c344f3e3
...
...
@@ -128,7 +128,7 @@ Tim_Man_t * Tim_ManDup( Tim_Man_t * p, int fUnitDelay )
pDelayTableNew
[
1
]
=
(
int
)
pDelayTable
[
1
];
pDelayTableNew
[
2
]
=
(
int
)
pDelayTable
[
2
];
for
(
k
=
0
;
k
<
nInputs
*
nOutputs
;
k
++
)
pDelayTableNew
[
3
+
k
]
=
fUnitDelay
?
1
.
0
:
pDelayTable
[
3
+
k
];
pDelayTableNew
[
3
+
k
]
=
fUnitDelay
?
(
float
)
fUnitDelay
:
pDelayTable
[
3
+
k
];
// assert( (int)pDelayTableNew[0] == Vec_PtrSize(pNew->vDelayTables) );
assert
(
Vec_PtrEntry
(
pNew
->
vDelayTables
,
i
)
==
NULL
);
Vec_PtrWriteEntry
(
pNew
->
vDelayTables
,
i
,
pDelayTableNew
);
...
...
src/misc/tim/timTime.c
View file @
c344f3e3
...
...
@@ -154,7 +154,7 @@ void Tim_ManSetCiRequired( Tim_Man_t * p, int iCi, float Delay )
void
Tim_ManSetCoRequired
(
Tim_Man_t
*
p
,
int
iCo
,
float
Delay
)
{
assert
(
iCo
<
p
->
nCos
);
assert
(
!
p
->
fUseTravId
||
p
->
pCos
[
iCo
].
TravId
!=
p
->
nTravIds
);
assert
(
!
p
->
fUseTravId
||
!
p
->
nTravIds
||
p
->
pCos
[
iCo
].
TravId
!=
p
->
nTravIds
);
p
->
pCos
[
iCo
].
timeReq
=
Delay
;
p
->
pCos
[
iCo
].
TravId
=
p
->
nTravIds
;
}
...
...
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