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
31430043
Commit
31430043
authored
Mar 29, 2016
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Windowing for technology mapping.
parent
e026f05a
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
51 additions
and
13 deletions
+51
-13
abclib.dsp
+4
-0
src/aig/gia/gia.h
+21
-12
src/aig/gia/giaIf.c
+24
-0
src/aig/gia/giaMan.c
+1
-1
src/aig/gia/giaSplit.c
+0
-0
src/aig/gia/module.make
+1
-0
No files found.
abclib.dsp
View file @
31430043
...
...
@@ -4367,6 +4367,10 @@ SOURCE=.\src\aig\gia\giaSpeedup.c
# End Source File
# Begin Source File
SOURCE=.\src\aig\gia\giaSplit.c
# End Source File
# Begin Source File
SOURCE=.\src\aig\gia\giaStg.c
# End Source File
# Begin Source File
...
...
src/aig/gia/gia.h
View file @
31430043
...
...
@@ -112,6 +112,7 @@ struct Gia_Man_t_
int
fAddStrash
;
// performs additional structural hashing
int
fSweeper
;
// sweeper is running
int
*
pRefs
;
// the reference count
int
*
pLutRefs
;
// the reference count
Vec_Int_t
*
vLevels
;
// levels of the nodes
int
nLevels
;
// the mamixum level
int
nConstrs
;
// the number of constraints
...
...
@@ -536,18 +537,25 @@ static inline void Gia_ObjSetNumId( Gia_Man_t * p, int Id, int n )
static
inline
void
Gia_ObjSetNum
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
,
int
n
)
{
Vec_IntWriteEntry
(
p
->
vTtNums
,
Gia_ObjId
(
p
,
pObj
),
n
);
}
static
inline
void
Gia_ObjResetNumId
(
Gia_Man_t
*
p
,
int
Id
)
{
Vec_IntWriteEntry
(
p
->
vTtNums
,
Id
,
-
ABC_INFINITY
);
}
static
inline
int
Gia_ObjRefNumId
(
Gia_Man_t
*
p
,
int
Id
)
{
return
p
->
pRefs
[
Id
];
}
static
inline
int
Gia_ObjRefIncId
(
Gia_Man_t
*
p
,
int
Id
)
{
return
p
->
pRefs
[
Id
]
++
;
}
static
inline
int
Gia_ObjRefDecId
(
Gia_Man_t
*
p
,
int
Id
)
{
return
--
p
->
pRefs
[
Id
];
}
static
inline
int
Gia_ObjRefNum
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
return
Gia_ObjRefNumId
(
p
,
Gia_ObjId
(
p
,
pObj
)
);
}
static
inline
int
Gia_ObjRefInc
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
return
Gia_ObjRefIncId
(
p
,
Gia_ObjId
(
p
,
pObj
)
);
}
static
inline
int
Gia_ObjRefDec
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
return
Gia_ObjRefDecId
(
p
,
Gia_ObjId
(
p
,
pObj
)
);
}
static
inline
void
Gia_ObjRefFanin0Inc
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
){
Gia_ObjRefInc
(
p
,
Gia_ObjFanin0
(
pObj
));
}
static
inline
void
Gia_ObjRefFanin1Inc
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
){
Gia_ObjRefInc
(
p
,
Gia_ObjFanin1
(
pObj
));
}
static
inline
void
Gia_ObjRefFanin2Inc
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
){
Gia_ObjRefInc
(
p
,
Gia_ObjFanin2
(
p
,
pObj
));
}
static
inline
void
Gia_ObjRefFanin0Dec
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
){
Gia_ObjRefDec
(
p
,
Gia_ObjFanin0
(
pObj
));
}
static
inline
void
Gia_ObjRefFanin1Dec
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
){
Gia_ObjRefDec
(
p
,
Gia_ObjFanin1
(
pObj
));
}
static
inline
void
Gia_ObjRefFanin2Dec
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
){
Gia_ObjRefDec
(
p
,
Gia_ObjFanin2
(
p
,
pObj
));
}
static
inline
int
Gia_ObjRefNumId
(
Gia_Man_t
*
p
,
int
Id
)
{
return
p
->
pRefs
[
Id
];
}
static
inline
int
Gia_ObjRefIncId
(
Gia_Man_t
*
p
,
int
Id
)
{
return
p
->
pRefs
[
Id
]
++
;
}
static
inline
int
Gia_ObjRefDecId
(
Gia_Man_t
*
p
,
int
Id
)
{
return
--
p
->
pRefs
[
Id
];
}
static
inline
int
Gia_ObjRefNum
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
return
Gia_ObjRefNumId
(
p
,
Gia_ObjId
(
p
,
pObj
)
);
}
static
inline
int
Gia_ObjRefInc
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
return
Gia_ObjRefIncId
(
p
,
Gia_ObjId
(
p
,
pObj
)
);
}
static
inline
int
Gia_ObjRefDec
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
return
Gia_ObjRefDecId
(
p
,
Gia_ObjId
(
p
,
pObj
)
);
}
static
inline
void
Gia_ObjRefFanin0Inc
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
Gia_ObjRefInc
(
p
,
Gia_ObjFanin0
(
pObj
));
}
static
inline
void
Gia_ObjRefFanin1Inc
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
Gia_ObjRefInc
(
p
,
Gia_ObjFanin1
(
pObj
));
}
static
inline
void
Gia_ObjRefFanin2Inc
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
Gia_ObjRefInc
(
p
,
Gia_ObjFanin2
(
p
,
pObj
));
}
static
inline
void
Gia_ObjRefFanin0Dec
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
Gia_ObjRefDec
(
p
,
Gia_ObjFanin0
(
pObj
));
}
static
inline
void
Gia_ObjRefFanin1Dec
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
Gia_ObjRefDec
(
p
,
Gia_ObjFanin1
(
pObj
));
}
static
inline
void
Gia_ObjRefFanin2Dec
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
Gia_ObjRefDec
(
p
,
Gia_ObjFanin2
(
p
,
pObj
));
}
static
inline
int
Gia_ObjLutRefNumId
(
Gia_Man_t
*
p
,
int
Id
)
{
assert
(
p
->
pLutRefs
);
return
p
->
pLutRefs
[
Id
];
}
static
inline
int
Gia_ObjLutRefIncId
(
Gia_Man_t
*
p
,
int
Id
)
{
assert
(
p
->
pLutRefs
);
return
p
->
pLutRefs
[
Id
]
++
;
}
static
inline
int
Gia_ObjLutRefDecId
(
Gia_Man_t
*
p
,
int
Id
)
{
assert
(
p
->
pLutRefs
);
return
--
p
->
pLutRefs
[
Id
];
}
static
inline
int
Gia_ObjLutRefNum
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
assert
(
p
->
pLutRefs
);
return
p
->
pLutRefs
[
Gia_ObjId
(
p
,
pObj
)];
}
static
inline
int
Gia_ObjLutRefInc
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
assert
(
p
->
pLutRefs
);
return
p
->
pLutRefs
[
Gia_ObjId
(
p
,
pObj
)]
++
;
}
static
inline
int
Gia_ObjLutRefDec
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
assert
(
p
->
pLutRefs
);
return
--
p
->
pLutRefs
[
Gia_ObjId
(
p
,
pObj
)];
}
static
inline
void
Gia_ObjSetTravIdCurrent
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
assert
(
Gia_ObjId
(
p
,
pObj
)
<
p
->
nTravIdsAlloc
);
p
->
pTravIds
[
Gia_ObjId
(
p
,
pObj
)]
=
p
->
nTravIds
;
}
static
inline
void
Gia_ObjSetTravIdPrevious
(
Gia_Man_t
*
p
,
Gia_Obj_t
*
pObj
)
{
assert
(
Gia_ObjId
(
p
,
pObj
)
<
p
->
nTravIdsAlloc
);
p
->
pTravIds
[
Gia_ObjId
(
p
,
pObj
)]
=
p
->
nTravIds
-
1
;
}
...
...
@@ -1251,6 +1259,7 @@ extern int Gia_ManLutNum( Gia_Man_t * p );
extern
int
Gia_ManLutLevel
(
Gia_Man_t
*
p
);
extern
void
Gia_ManLutParams
(
Gia_Man_t
*
p
,
int
*
pnCurLuts
,
int
*
pnCurEdges
,
int
*
pnCurLevels
);
extern
void
Gia_ManSetRefsMapped
(
Gia_Man_t
*
p
);
extern
void
Gia_ManSetLutRefs
(
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
*
p
,
Gia_Man_t
*
pGia
);
...
...
src/aig/gia/giaIf.c
View file @
31430043
...
...
@@ -257,6 +257,30 @@ void Gia_ManSetRefsMapped( Gia_Man_t * p )
/**Function*************************************************************
Synopsis [Assigns levels.]
Description []
SideEffects []
SeeAlso []
***********************************************************************/
void
Gia_ManSetLutRefs
(
Gia_Man_t
*
p
)
{
Gia_Obj_t
*
pObj
;
int
i
,
k
,
iFan
;
ABC_FREE
(
p
->
pLutRefs
);
p
->
pLutRefs
=
ABC_CALLOC
(
int
,
Gia_ManObjNum
(
p
)
);
Gia_ManForEachCo
(
p
,
pObj
,
i
)
Gia_ObjLutRefInc
(
p
,
Gia_ObjFanin0
(
pObj
)
);
Gia_ManForEachLut
(
p
,
i
)
Gia_LutForEachFanin
(
p
,
i
,
iFan
,
k
)
Gia_ObjLutRefInc
(
p
,
Gia_ManObj
(
p
,
iFan
)
);
}
/**Function*************************************************************
Synopsis [Calculate mapping overlap.]
Description []
...
...
src/aig/gia/giaMan.c
View file @
31430043
...
...
@@ -136,7 +136,7 @@ void Gia_ManStop( Gia_Man_t * p )
ABC_FREE
(
p
->
pNexts
);
ABC_FREE
(
p
->
pSibls
);
ABC_FREE
(
p
->
pRefs
);
// ABC_FREE( p->pNode
Refs );
ABC_FREE
(
p
->
pLut
Refs
);
ABC_FREE
(
p
->
pHTable
);
ABC_FREE
(
p
->
pMuxes
);
ABC_FREE
(
p
->
pObjs
);
...
...
src/aig/gia/giaSplit.c
0 → 100644
View file @
31430043
This diff is collapsed.
Click to expand it.
src/aig/gia/module.make
View file @
31430043
...
...
@@ -65,6 +65,7 @@ SRC += src/aig/gia/giaAig.c \
src/aig/gia/giaSim2.c
\
src/aig/gia/giaSort.c
\
src/aig/gia/giaSpeedup.c
\
src/aig/gia/giaSplit.c
\
src/aig/gia/giaStg.c
\
src/aig/gia/giaStr.c
\
src/aig/gia/giaSupMin.c
\
...
...
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