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
93ad6e7d
Commit
93ad6e7d
authored
Nov 03, 2014
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Making public some APIs.
parent
505747d4
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
30 additions
and
21 deletions
+30
-21
src/aig/gia/gia.h
+20
-1
src/aig/gia/giaSim.c
+7
-17
src/bool/lucky/luckySimple.c
+3
-3
No files found.
src/aig/gia/gia.h
View file @
93ad6e7d
...
...
@@ -189,7 +189,6 @@ struct Gia_Man_t_
};
typedef
struct
Gps_Par_t_
Gps_Par_t
;
struct
Gps_Par_t_
{
...
...
@@ -246,6 +245,20 @@ struct Gia_ParSim_t_
int
iOutFail
;
// index of the failed output
};
typedef
struct
Gia_ManSim_t_
Gia_ManSim_t
;
struct
Gia_ManSim_t_
{
Gia_Man_t
*
pAig
;
Gia_ParSim_t
*
pPars
;
int
nWords
;
Vec_Int_t
*
vCis2Ids
;
Vec_Int_t
*
vConsts
;
// simulation information
unsigned
*
pDataSim
;
// simulation data
unsigned
*
pDataSimCis
;
// simulation data for CIs
unsigned
*
pDataSimCos
;
// simulation data for COs
};
typedef
struct
Jf_Par_t_
Jf_Par_t
;
struct
Jf_Par_t_
{
...
...
@@ -1279,6 +1292,12 @@ extern int * Gia_SortFloats( float * pArray, int * pPerm, int nSiz
/*=== giaSim.c ============================================================*/
extern
void
Gia_ManSimSetDefaultParams
(
Gia_ParSim_t
*
p
);
extern
int
Gia_ManSimSimulate
(
Gia_Man_t
*
pAig
,
Gia_ParSim_t
*
pPars
);
extern
unsigned
*
Gia_SimDataExt
(
Gia_ManSim_t
*
p
,
int
i
);
extern
unsigned
*
Gia_SimDataCiExt
(
Gia_ManSim_t
*
p
,
int
i
);
extern
unsigned
*
Gia_SimDataCoExt
(
Gia_ManSim_t
*
p
,
int
i
);
extern
void
Gia_ManSimInfoInit
(
Gia_ManSim_t
*
p
);
extern
void
Gia_ManSimInfoTransfer
(
Gia_ManSim_t
*
p
);
extern
void
Gia_ManSimulateRound
(
Gia_ManSim_t
*
p
);
/*=== giaSpeedup.c ============================================================*/
extern
float
Gia_ManDelayTraceLut
(
Gia_Man_t
*
p
);
extern
float
Gia_ManDelayTraceLutPrint
(
Gia_Man_t
*
p
,
int
fVerbose
);
...
...
src/aig/gia/giaSim.c
View file @
93ad6e7d
...
...
@@ -27,24 +27,14 @@ ABC_NAMESPACE_IMPL_START
/// DECLARATIONS ///
////////////////////////////////////////////////////////////////////////
typedef
struct
Gia_ManSim_t_
Gia_ManSim_t
;
struct
Gia_ManSim_t_
{
Gia_Man_t
*
pAig
;
Gia_ParSim_t
*
pPars
;
int
nWords
;
Vec_Int_t
*
vCis2Ids
;
Vec_Int_t
*
vConsts
;
// simulation information
unsigned
*
pDataSim
;
// simulation data
unsigned
*
pDataSimCis
;
// simulation data for CIs
unsigned
*
pDataSimCos
;
// simulation data for COs
};
static
inline
unsigned
*
Gia_SimData
(
Gia_ManSim_t
*
p
,
int
i
)
{
return
p
->
pDataSim
+
i
*
p
->
nWords
;
}
static
inline
unsigned
*
Gia_SimDataCi
(
Gia_ManSim_t
*
p
,
int
i
)
{
return
p
->
pDataSimCis
+
i
*
p
->
nWords
;
}
static
inline
unsigned
*
Gia_SimDataCo
(
Gia_ManSim_t
*
p
,
int
i
)
{
return
p
->
pDataSimCos
+
i
*
p
->
nWords
;
}
unsigned
*
Gia_SimDataExt
(
Gia_ManSim_t
*
p
,
int
i
)
{
return
Gia_SimData
(
p
,
i
);
}
unsigned
*
Gia_SimDataCiExt
(
Gia_ManSim_t
*
p
,
int
i
)
{
return
Gia_SimDataCi
(
p
,
i
);
}
unsigned
*
Gia_SimDataCoExt
(
Gia_ManSim_t
*
p
,
int
i
)
{
return
Gia_SimDataCo
(
p
,
i
);
}
////////////////////////////////////////////////////////////////////////
/// FUNCTION DEFINITIONS ///
////////////////////////////////////////////////////////////////////////
...
...
@@ -436,7 +426,7 @@ static inline void Gia_ManSimulateNode( Gia_ManSim_t * p, Gia_Obj_t * pObj )
SeeAlso []
***********************************************************************/
static
inline
void
Gia_ManSimInfoInit
(
Gia_ManSim_t
*
p
)
void
Gia_ManSimInfoInit
(
Gia_ManSim_t
*
p
)
{
int
iPioNum
,
i
;
Vec_IntForEachEntry
(
p
->
vCis2Ids
,
iPioNum
,
i
)
...
...
@@ -459,7 +449,7 @@ static inline void Gia_ManSimInfoInit( Gia_ManSim_t * p )
SeeAlso []
***********************************************************************/
static
inline
void
Gia_ManSimInfoTransfer
(
Gia_ManSim_t
*
p
)
void
Gia_ManSimInfoTransfer
(
Gia_ManSim_t
*
p
)
{
int
iPioNum
,
i
;
Vec_IntForEachEntry
(
p
->
vCis2Ids
,
iPioNum
,
i
)
...
...
@@ -482,7 +472,7 @@ static inline void Gia_ManSimInfoTransfer( Gia_ManSim_t * p )
SeeAlso []
***********************************************************************/
static
inline
void
Gia_ManSimulateRound
(
Gia_ManSim_t
*
p
)
void
Gia_ManSimulateRound
(
Gia_ManSim_t
*
p
)
{
Gia_Obj_t
*
pObj
;
int
i
,
iCis
=
0
,
iCos
=
0
;
...
...
src/bool/lucky/luckySimple.c
View file @
93ad6e7d
...
...
@@ -103,7 +103,7 @@ void fillInFlipArray(permInfo* pi)
}
inline
int
factorial
(
int
n
)
static
inline
int
factorial
(
int
n
)
{
return
(
n
==
1
||
n
==
0
)
?
1
:
factorial
(
n
-
1
)
*
n
;
}
...
...
@@ -129,14 +129,14 @@ void freePermInfoPtr(permInfo* x)
free
(
x
->
swapArray
);
free
(
x
);
}
inline
void
minWord
(
word
*
a
,
word
*
b
,
word
*
minimal
,
int
nVars
)
static
inline
void
minWord
(
word
*
a
,
word
*
b
,
word
*
minimal
,
int
nVars
)
{
if
(
memCompare
(
a
,
b
,
nVars
)
==
-
1
)
Kit_TruthCopy_64bit
(
minimal
,
a
,
nVars
);
else
Kit_TruthCopy_64bit
(
minimal
,
b
,
nVars
);
}
inline
void
minWord3
(
word
*
a
,
word
*
b
,
word
*
minimal
,
int
nVars
)
static
inline
void
minWord3
(
word
*
a
,
word
*
b
,
word
*
minimal
,
int
nVars
)
{
if
(
memCompare
(
a
,
b
,
nVars
)
<=
0
)
{
...
...
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