mirror of https://github.com/YosysHQ/abc.git
Compiler problem.
This commit is contained in:
parent
e7504c6dab
commit
589e2edec2
|
|
@ -30,8 +30,8 @@
|
||||||
ABC_NAMESPACE_IMPL_START
|
ABC_NAMESPACE_IMPL_START
|
||||||
|
|
||||||
/* on/off switches */
|
/* on/off switches */
|
||||||
#define REFINE_BY_SIM_1 0
|
#define REFINE_BY_SIM_1 0
|
||||||
#define REFINE_BY_SIM_2 0
|
#define REFINE_BY_SIM_2 0
|
||||||
#define BACKTRACK_BY_SAT 1
|
#define BACKTRACK_BY_SAT 1
|
||||||
#define SELECT_DYNAMICALLY 0
|
#define SELECT_DYNAMICALLY 0
|
||||||
|
|
||||||
|
|
@ -89,10 +89,10 @@ struct sim_result {
|
||||||
struct saucy {
|
struct saucy {
|
||||||
/* Graph data */
|
/* Graph data */
|
||||||
int n; /* Size of domain */
|
int n; /* Size of domain */
|
||||||
int *adj; /* Neighbors of k: edg[adj[k]]..edg[adj[k+1]] */
|
int *adj; /* Neighbors of k: edg[adj[k]]..edg[adj[k+1]] */
|
||||||
int *edg; /* Actual neighbor data */
|
int *edg; /* Actual neighbor data */
|
||||||
int *dadj; /* Fanin neighbor indices, for digraphs */
|
int *dadj; /* Fanin neighbor indices, for digraphs */
|
||||||
int *dedg; /* Fanin neighbor data, for digraphs */
|
int *dedg; /* Fanin neighbor data, for digraphs */
|
||||||
|
|
||||||
/* Coloring data */
|
/* Coloring data */
|
||||||
struct coloring left, right;
|
struct coloring left, right;
|
||||||
|
|
@ -203,17 +203,17 @@ static char *bits(int n) { return ABC_CALLOC(char, n); }
|
||||||
static char * getVertexName(Abc_Ntk_t *pNtk, int v);
|
static char * getVertexName(Abc_Ntk_t *pNtk, int v);
|
||||||
static int * generateProperInputVector(Abc_Ntk_t * pNtk, struct coloring *c, Vec_Int_t * randomVector);
|
static int * generateProperInputVector(Abc_Ntk_t * pNtk, struct coloring *c, Vec_Int_t * randomVector);
|
||||||
static int ifInputVectorsAreConsistent(struct saucy * s, int * leftVec, int * rightVec);
|
static int ifInputVectorsAreConsistent(struct saucy * s, int * leftVec, int * rightVec);
|
||||||
static int ifOutputVectorsAreConsistent(struct saucy * s, int * leftVec, int * rightVec);
|
static int ifOutputVectorsAreConsistent(struct saucy * s, int * leftVec, int * rightVec);
|
||||||
static Vec_Ptr_t ** findTopologicalOrder(Abc_Ntk_t * pNtk);
|
static Vec_Ptr_t ** findTopologicalOrder(Abc_Ntk_t * pNtk);
|
||||||
static void getDependencies(Abc_Ntk_t *pNtk, Vec_Int_t** iDep, Vec_Int_t** oDep);
|
static void getDependencies(Abc_Ntk_t *pNtk, Vec_Int_t** iDep, Vec_Int_t** oDep);
|
||||||
static struct saucy_graph * buildDepGraph (Abc_Ntk_t *pNtk, Vec_Int_t ** iDep, Vec_Int_t ** oDep);
|
static struct saucy_graph * buildDepGraph (Abc_Ntk_t *pNtk, Vec_Int_t ** iDep, Vec_Int_t ** oDep);
|
||||||
static struct saucy_graph * buildSim1Graph(Abc_Ntk_t * pNtk, struct coloring *c, Vec_Int_t * randVec, Vec_Int_t ** iDep, Vec_Int_t ** oDep);
|
static struct saucy_graph * buildSim1Graph(Abc_Ntk_t * pNtk, struct coloring *c, Vec_Int_t * randVec, Vec_Int_t ** iDep, Vec_Int_t ** oDep);
|
||||||
static struct saucy_graph * buildSim2Graph(Abc_Ntk_t * pNtk, struct coloring *c, Vec_Int_t * randVec, Vec_Int_t ** iDep, Vec_Int_t ** oDep, Vec_Ptr_t ** topOrder, Vec_Int_t ** obs, Vec_Int_t ** ctrl);
|
static struct saucy_graph * buildSim2Graph(Abc_Ntk_t * pNtk, struct coloring *c, Vec_Int_t * randVec, Vec_Int_t ** iDep, Vec_Int_t ** oDep, Vec_Ptr_t ** topOrder, Vec_Int_t ** obs, Vec_Int_t ** ctrl);
|
||||||
static Vec_Int_t * assignRandomBitsToCells(Abc_Ntk_t * pNtk, struct coloring *c);
|
static Vec_Int_t * assignRandomBitsToCells(Abc_Ntk_t * pNtk, struct coloring *c);
|
||||||
int Abc_NtkCecSat_saucy(Abc_Ntk_t * pNtk1, Abc_Ntk_t * pNtk2, int * pModel);
|
static int Abc_NtkCecSat_saucy(Abc_Ntk_t * pNtk1, Abc_Ntk_t * pNtk2, int * pModel);
|
||||||
struct sim_result * analyzeConflict(Abc_Ntk_t * pNtk, int * pModel, int fVerbose);
|
static struct sim_result * analyzeConflict(Abc_Ntk_t * pNtk, int * pModel, int fVerbose);
|
||||||
static void bumpActivity (struct saucy * s, struct sim_result * cex);
|
static void bumpActivity (struct saucy * s, struct sim_result * cex);
|
||||||
static void reduceDB(struct saucy * s);
|
static void reduceDB(struct saucy * s);
|
||||||
|
|
||||||
|
|
||||||
static int
|
static int
|
||||||
|
|
@ -1228,7 +1228,7 @@ refineBySim1_init(struct saucy *s, struct coloring *c)
|
||||||
if (allOutputsAreDistinguished) break;
|
if (allOutputsAreDistinguished) break;
|
||||||
|
|
||||||
randVec = assignRandomBitsToCells(s->pNtk, c);
|
randVec = assignRandomBitsToCells(s->pNtk, c);
|
||||||
g = buildSim1Graph(s->pNtk, c, randVec, s->iDep, s->oDep);
|
g = buildSim1Graph(s->pNtk, c, randVec, s->iDep, s->oDep);
|
||||||
assert(g != NULL);
|
assert(g != NULL);
|
||||||
|
|
||||||
s->adj = g->adj;
|
s->adj = g->adj;
|
||||||
|
|
@ -1282,7 +1282,7 @@ refineBySim1_left(struct saucy *s, struct coloring *c)
|
||||||
if (allOutputsAreDistinguished) break;
|
if (allOutputsAreDistinguished) break;
|
||||||
|
|
||||||
randVec = assignRandomBitsToCells(s->pNtk, c);
|
randVec = assignRandomBitsToCells(s->pNtk, c);
|
||||||
g = buildSim1Graph(s->pNtk, c, randVec, s->iDep, s->oDep);
|
g = buildSim1Graph(s->pNtk, c, randVec, s->iDep, s->oDep);
|
||||||
assert(g != NULL);
|
assert(g != NULL);
|
||||||
|
|
||||||
s->adj = g->adj;
|
s->adj = g->adj;
|
||||||
|
|
@ -2784,7 +2784,7 @@ getDependencies(Abc_Ntk_t *pNtk, Vec_Int_t** iDep, Vec_Int_t** oDep)
|
||||||
printf("\n");
|
printf("\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
printf("\n"); */
|
printf("\n"); */
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
@ -3032,7 +3032,7 @@ buildSim2Graph( Abc_Ntk_t * pNtk, struct coloring *c, Vec_Int_t * randVec, Vec_I
|
||||||
|
|
||||||
for (i = 0; i < numins; i++) {
|
for (i = 0; i < numins; i++) {
|
||||||
if (!c->clen[c->cfront[i+numouts]]) continue;
|
if (!c->clen[c->cfront[i+numouts]]) continue;
|
||||||
if (vPiValues[i] == 0) vPiValues[i] = 1;
|
if (vPiValues[i] == 0) vPiValues[i] = 1;
|
||||||
else vPiValues[i] = 0;
|
else vPiValues[i] = 0;
|
||||||
|
|
||||||
output2 = Abc_NtkSimulateOneNode( pNtk, vPiValues, i, topOrder );
|
output2 = Abc_NtkSimulateOneNode( pNtk, vPiValues, i, topOrder );
|
||||||
|
|
@ -3045,7 +3045,7 @@ buildSim2Graph( Abc_Ntk_t * pNtk, struct coloring *c, Vec_Int_t * randVec, Vec_I
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (vPiValues[i] == 0) vPiValues[i] = 1;
|
if (vPiValues[i] == 0) vPiValues[i] = 1;
|
||||||
else vPiValues[i] = 0;
|
else vPiValues[i] = 0;
|
||||||
|
|
||||||
ABC_FREE( output2 );
|
ABC_FREE( output2 );
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue