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
655dc4e7
Commit
655dc4e7
authored
Aug 07, 2013
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improvements to buffering and sizing.
parent
8576e4b4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
30 additions
and
14 deletions
+30
-14
src/map/scl/sclSize.h
+30
-14
src/map/scl/sclUpsize.c
+0
-0
No files found.
src/map/scl/sclSize.h
View file @
655dc4e7
...
@@ -53,13 +53,13 @@ struct SC_Man_
...
@@ -53,13 +53,13 @@ struct SC_Man_
Vec_Int_t
*
vUpdates2
;
// sizing updates in this round
Vec_Int_t
*
vUpdates2
;
// sizing updates in this round
// timing information
// timing information
SC_Pair
*
pLoads
;
// loads for each gate
SC_Pair
*
pLoads
;
// loads for each gate
SC_Pair
*
pLoads2
;
// loads for each gate
SC_Pair
*
pLoads3
;
// loads for each gate
SC_Pair
*
pDepts
;
// departures for each gate
SC_Pair
*
pDepts
;
// departures for each gate
SC_Pair
*
pTimes
;
// arrivals for each gate
SC_Pair
*
pTimes
;
// arrivals for each gate
SC_Pair
*
pSlews
;
// slews for each gate
SC_Pair
*
pSlews
;
// slews for each gate
SC_Pair
*
pTimes2
;
// arrivals for each gate
SC_Pair
*
pTimes2
;
// arrivals for each gate
SC_Pair
*
pSlews2
;
// slews for each gate
SC_Pair
*
pSlews2
;
// slews for each gate
Vec_Flt_t
*
vLoads2
;
// backup storage for loads
Vec_Flt_t
*
vLoads3
;
// backup storage for loads
float
*
pSlack
;
// slacks for each gatt
float
*
pSlack
;
// slacks for each gatt
float
*
pInDrive
;
// maximum input drive strength
float
*
pInDrive
;
// maximum input drive strength
Vec_Int_t
*
vBestFans
;
// best fanouts
Vec_Int_t
*
vBestFans
;
// best fanouts
...
@@ -103,8 +103,6 @@ static inline SC_Cell * Abc_SclObjCell( SC_Man * p, Abc_Obj_t * pObj )
...
@@ -103,8 +103,6 @@ static inline SC_Cell * Abc_SclObjCell( SC_Man * p, Abc_Obj_t * pObj )
static
inline
void
Abc_SclObjSetCell
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
,
SC_Cell
*
pCell
)
{
Vec_IntWriteEntry
(
p
->
vGates
,
Abc_ObjId
(
pObj
),
pCell
->
Id
);
}
static
inline
void
Abc_SclObjSetCell
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
,
SC_Cell
*
pCell
)
{
Vec_IntWriteEntry
(
p
->
vGates
,
Abc_ObjId
(
pObj
),
pCell
->
Id
);
}
static
inline
SC_Pair
*
Abc_SclObjLoad
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
return
p
->
pLoads
+
Abc_ObjId
(
pObj
);
}
static
inline
SC_Pair
*
Abc_SclObjLoad
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
return
p
->
pLoads
+
Abc_ObjId
(
pObj
);
}
static
inline
SC_Pair
*
Abc_SclObjLoad2
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
return
p
->
pLoads2
+
Abc_ObjId
(
pObj
);
}
static
inline
SC_Pair
*
Abc_SclObjLoad3
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
return
p
->
pLoads3
+
Abc_ObjId
(
pObj
);
}
static
inline
SC_Pair
*
Abc_SclObjDept
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
return
p
->
pDepts
+
Abc_ObjId
(
pObj
);
}
static
inline
SC_Pair
*
Abc_SclObjDept
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
return
p
->
pDepts
+
Abc_ObjId
(
pObj
);
}
static
inline
SC_Pair
*
Abc_SclObjTime
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
return
p
->
pTimes
+
Abc_ObjId
(
pObj
);
}
static
inline
SC_Pair
*
Abc_SclObjTime
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
return
p
->
pTimes
+
Abc_ObjId
(
pObj
);
}
static
inline
SC_Pair
*
Abc_SclObjSlew
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
return
p
->
pSlews
+
Abc_ObjId
(
pObj
);
}
static
inline
SC_Pair
*
Abc_SclObjSlew
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
return
p
->
pSlews
+
Abc_ObjId
(
pObj
);
}
...
@@ -153,8 +151,6 @@ static inline SC_Man * Abc_SclManAlloc( SC_Lib * pLib, Abc_Ntk_t * pNtk )
...
@@ -153,8 +151,6 @@ static inline SC_Man * Abc_SclManAlloc( SC_Lib * pLib, Abc_Ntk_t * pNtk )
p
->
pNtk
=
pNtk
;
p
->
pNtk
=
pNtk
;
p
->
nObjs
=
Abc_NtkObjNumMax
(
pNtk
);
p
->
nObjs
=
Abc_NtkObjNumMax
(
pNtk
);
p
->
pLoads
=
ABC_CALLOC
(
SC_Pair
,
p
->
nObjs
);
p
->
pLoads
=
ABC_CALLOC
(
SC_Pair
,
p
->
nObjs
);
p
->
pLoads2
=
ABC_CALLOC
(
SC_Pair
,
p
->
nObjs
);
p
->
pLoads3
=
ABC_CALLOC
(
SC_Pair
,
p
->
nObjs
);
p
->
pDepts
=
ABC_CALLOC
(
SC_Pair
,
p
->
nObjs
);
p
->
pDepts
=
ABC_CALLOC
(
SC_Pair
,
p
->
nObjs
);
p
->
pTimes
=
ABC_CALLOC
(
SC_Pair
,
p
->
nObjs
);
p
->
pTimes
=
ABC_CALLOC
(
SC_Pair
,
p
->
nObjs
);
p
->
pSlews
=
ABC_CALLOC
(
SC_Pair
,
p
->
nObjs
);
p
->
pSlews
=
ABC_CALLOC
(
SC_Pair
,
p
->
nObjs
);
...
@@ -169,6 +165,8 @@ static inline SC_Man * Abc_SclManAlloc( SC_Lib * pLib, Abc_Ntk_t * pNtk )
...
@@ -169,6 +165,8 @@ static inline SC_Man * Abc_SclManAlloc( SC_Lib * pLib, Abc_Ntk_t * pNtk )
Vec_QuePush
(
p
->
vQue
,
i
);
Vec_QuePush
(
p
->
vQue
,
i
);
p
->
vUpdates
=
Vec_IntAlloc
(
1000
);
p
->
vUpdates
=
Vec_IntAlloc
(
1000
);
p
->
vUpdates2
=
Vec_IntAlloc
(
1000
);
p
->
vUpdates2
=
Vec_IntAlloc
(
1000
);
p
->
vLoads2
=
Vec_FltAlloc
(
1000
);
p
->
vLoads3
=
Vec_FltAlloc
(
1000
);
// intermediate data
// intermediate data
p
->
vNode2Gain
=
Vec_FltStart
(
p
->
nObjs
);
p
->
vNode2Gain
=
Vec_FltStart
(
p
->
nObjs
);
p
->
vNode2Gate
=
Vec_IntStart
(
p
->
nObjs
);
p
->
vNode2Gate
=
Vec_IntStart
(
p
->
nObjs
);
...
@@ -184,6 +182,8 @@ static inline void Abc_SclManFree( SC_Man * p )
...
@@ -184,6 +182,8 @@ static inline void Abc_SclManFree( SC_Man * p )
Vec_FltFreeP
(
&
p
->
vNode2Gain
);
Vec_FltFreeP
(
&
p
->
vNode2Gain
);
Vec_IntFreeP
(
&
p
->
vNode2Gate
);
Vec_IntFreeP
(
&
p
->
vNode2Gate
);
// intermediate data
// intermediate data
Vec_FltFreeP
(
&
p
->
vLoads2
);
Vec_FltFreeP
(
&
p
->
vLoads3
);
Vec_IntFreeP
(
&
p
->
vUpdates
);
Vec_IntFreeP
(
&
p
->
vUpdates
);
Vec_IntFreeP
(
&
p
->
vUpdates2
);
Vec_IntFreeP
(
&
p
->
vUpdates2
);
Vec_IntFreeP
(
&
p
->
vGatesBest
);
Vec_IntFreeP
(
&
p
->
vGatesBest
);
...
@@ -194,8 +194,6 @@ static inline void Abc_SclManFree( SC_Man * p )
...
@@ -194,8 +194,6 @@ static inline void Abc_SclManFree( SC_Man * p )
Vec_IntFreeP
(
&
p
->
vGates
);
Vec_IntFreeP
(
&
p
->
vGates
);
Vec_IntFreeP
(
&
p
->
vBestFans
);
Vec_IntFreeP
(
&
p
->
vBestFans
);
ABC_FREE
(
p
->
pLoads
);
ABC_FREE
(
p
->
pLoads
);
ABC_FREE
(
p
->
pLoads2
);
ABC_FREE
(
p
->
pLoads3
);
ABC_FREE
(
p
->
pDepts
);
ABC_FREE
(
p
->
pDepts
);
ABC_FREE
(
p
->
pTimes
);
ABC_FREE
(
p
->
pTimes
);
ABC_FREE
(
p
->
pSlews
);
ABC_FREE
(
p
->
pSlews
);
...
@@ -288,32 +286,50 @@ static inline void Abc_SclLoadStore( SC_Man * p, Abc_Obj_t * pObj )
...
@@ -288,32 +286,50 @@ static inline void Abc_SclLoadStore( SC_Man * p, Abc_Obj_t * pObj )
{
{
Abc_Obj_t
*
pFanin
;
Abc_Obj_t
*
pFanin
;
int
i
;
int
i
;
Vec_FltClear
(
p
->
vLoads2
);
Abc_ObjForEachFanin
(
pObj
,
pFanin
,
i
)
Abc_ObjForEachFanin
(
pObj
,
pFanin
,
i
)
*
Abc_SclObjLoad2
(
p
,
pFanin
)
=
*
Abc_SclObjLoad
(
p
,
pFanin
);
{
Vec_FltPush
(
p
->
vLoads2
,
Abc_SclObjLoad
(
p
,
pFanin
)
->
rise
);
Vec_FltPush
(
p
->
vLoads2
,
Abc_SclObjLoad
(
p
,
pFanin
)
->
fall
);
}
}
}
static
inline
void
Abc_SclLoadRestore
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
static
inline
void
Abc_SclLoadRestore
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
{
Abc_Obj_t
*
pFanin
;
Abc_Obj_t
*
pFanin
;
int
i
;
int
i
;
assert
(
Vec_FltSize
(
p
->
vLoads2
)
==
2
*
Abc_ObjFaninNum
(
pObj
)
);
Abc_ObjForEachFanin
(
pObj
,
pFanin
,
i
)
Abc_ObjForEachFanin
(
pObj
,
pFanin
,
i
)
*
Abc_SclObjLoad
(
p
,
pFanin
)
=
*
Abc_SclObjLoad2
(
p
,
pFanin
);
{
Abc_SclObjLoad
(
p
,
pFanin
)
->
rise
=
Vec_FltEntry
(
p
->
vLoads2
,
2
*
i
);
Abc_SclObjLoad
(
p
,
pFanin
)
->
fall
=
Vec_FltEntry
(
p
->
vLoads2
,
2
*
i
+
1
);
}
}
}
static
inline
void
Abc_SclLoadStore3
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
static
inline
void
Abc_SclLoadStore3
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
{
Abc_Obj_t
*
pFanin
;
Abc_Obj_t
*
pFanin
;
int
i
;
int
i
;
*
Abc_SclObjLoad3
(
p
,
pObj
)
=
*
Abc_SclObjLoad
(
p
,
pObj
);
Vec_FltClear
(
p
->
vLoads3
);
Abc_ObjForEachFanin
(
pObj
,
pFanin
,
i
)
Abc_ObjForEachFanin
(
pObj
,
pFanin
,
i
)
*
Abc_SclObjLoad3
(
p
,
pFanin
)
=
*
Abc_SclObjLoad
(
p
,
pFanin
);
{
Vec_FltPush
(
p
->
vLoads3
,
Abc_SclObjLoad
(
p
,
pFanin
)
->
rise
);
Vec_FltPush
(
p
->
vLoads3
,
Abc_SclObjLoad
(
p
,
pFanin
)
->
fall
);
}
Vec_FltPush
(
p
->
vLoads3
,
Abc_SclObjLoad
(
p
,
pObj
)
->
rise
);
Vec_FltPush
(
p
->
vLoads3
,
Abc_SclObjLoad
(
p
,
pObj
)
->
fall
);
}
}
static
inline
void
Abc_SclLoadRestore3
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
static
inline
void
Abc_SclLoadRestore3
(
SC_Man
*
p
,
Abc_Obj_t
*
pObj
)
{
{
Abc_Obj_t
*
pFanin
;
Abc_Obj_t
*
pFanin
;
int
i
;
int
i
;
*
Abc_SclObjLoad
(
p
,
pObj
)
=
*
Abc_SclObjLoad3
(
p
,
pObj
);
assert
(
Vec_FltSize
(
p
->
vLoads3
)
==
2
*
Abc_ObjFaninNum
(
pObj
)
+
2
);
Abc_ObjForEachFanin
(
pObj
,
pFanin
,
i
)
Abc_ObjForEachFanin
(
pObj
,
pFanin
,
i
)
*
Abc_SclObjLoad
(
p
,
pFanin
)
=
*
Abc_SclObjLoad3
(
p
,
pFanin
);
{
Abc_SclObjLoad
(
p
,
pFanin
)
->
rise
=
Vec_FltEntry
(
p
->
vLoads3
,
2
*
i
);
Abc_SclObjLoad
(
p
,
pFanin
)
->
fall
=
Vec_FltEntry
(
p
->
vLoads3
,
2
*
i
+
1
);
}
Abc_SclObjLoad
(
p
,
pObj
)
->
rise
=
Vec_FltEntry
(
p
->
vLoads3
,
2
*
i
);
Abc_SclObjLoad
(
p
,
pObj
)
->
fall
=
Vec_FltEntry
(
p
->
vLoads3
,
2
*
i
+
1
);
}
}
/**Function*************************************************************
/**Function*************************************************************
...
...
src/map/scl/sclUpsize.c
View file @
655dc4e7
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