diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2013-07-12 13:14:44 -0700 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2013-07-12 13:14:44 -0700 |
commit | 804e0261abb949616a3b26b83a63423bea3b673c (patch) | |
tree | 55aff72ceb0e9eaa284a21cd16e3894a933dd369 | |
parent | 4b5ffde3b7dfe4dd6d3c5fd750b61dfbd992a544 (diff) | |
download | abc-804e0261abb949616a3b26b83a63423bea3b673c.tar.gz abc-804e0261abb949616a3b26b83a63423bea3b673c.tar.bz2 abc-804e0261abb949616a3b26b83a63423bea3b673c.zip |
Compiler warnings.
-rw-r--r-- | src/base/abci/abc.c | 6 | ||||
-rw-r--r-- | src/base/abci/abcSaucy.c | 42 |
2 files changed, 24 insertions, 24 deletions
diff --git a/src/base/abci/abc.c b/src/base/abci/abc.c index c6b31207..cc52941d 100644 --- a/src/base/abci/abc.c +++ b/src/base/abci/abc.c @@ -10040,7 +10040,7 @@ usage: ***********************************************************************/ int Abc_CommandTest( Abc_Frame_t * pAbc, int argc, char ** argv ) { - Abc_Ntk_t * pNtk = Abc_FrameReadNtk(pAbc); +// Abc_Ntk_t * pNtk = Abc_FrameReadNtk(pAbc); int nCutMax = 1; int nLeafMax = 10; int nDivMax = 50; @@ -29560,7 +29560,7 @@ usage: if ( pPars->DelayTarget == -1 ) sprintf(Buffer, "best possible" ); else - sprintf(Buffer, "%.2f", pPars->DelayTarget ); + sprintf(Buffer, "%d", pPars->DelayTarget ); Abc_Print( -2, "usage: &if2 [-D num] [-vh]\n" ); Abc_Print( -2, "\t performs technology mapping of the network\n" ); Abc_Print( -2, "\t-D num : sets the delay constraint for the mapping [default = %s]\n", Buffer ); @@ -32647,7 +32647,7 @@ usage: ***********************************************************************/ int Abc_CommandAbc9Test( Abc_Frame_t * pAbc, int argc, char ** argv ) { - Gia_Man_t * pTemp = NULL; +// Gia_Man_t * pTemp = NULL; int c, fVerbose = 0; int nFrames = 3; int fSwitch = 0; diff --git a/src/base/abci/abcSaucy.c b/src/base/abci/abcSaucy.c index 3c7464f5..7ffbf9fb 100644 --- a/src/base/abci/abcSaucy.c +++ b/src/base/abci/abcSaucy.c @@ -533,7 +533,7 @@ add_conterexample(struct saucy *s, struct sim_result * cex) } for (i = 0; i < Vec_PtrSize(s->satCounterExamples); i++) { - savedcex = Vec_PtrEntry(s->satCounterExamples, i); + savedcex = (struct sim_result *)Vec_PtrEntry(s->satCounterExamples, i); if (savedcex->inVecSignature == cex->inVecSignature) { //bumpActivity(s, savedcex); return 0; @@ -1165,12 +1165,12 @@ backtrackBysatCounterExamples(struct saucy *s, struct coloring *c) if (Vec_PtrSize(s->satCounterExamples) == 0) return 1; for (i = 0; i < Vec_PtrSize(s->satCounterExamples); i++) { - cex1 = Vec_PtrEntry(s->satCounterExamples, i); + cex1 = (struct sim_result *)Vec_PtrEntry(s->satCounterExamples, i); for (j = 0; j < Vec_PtrSize(s->satCounterExamples); j++) { if (flag[j]) continue; - cex2 = Vec_PtrEntry(s->satCounterExamples, j); + cex2 = (struct sim_result *)Vec_PtrEntry(s->satCounterExamples, j); res = ifInputVectorsAreConsistent(s, cex1->inVec, cex2->inVec); if (res == -2) { @@ -1325,7 +1325,7 @@ refineBySim1_other(struct saucy *s, struct coloring *c) int ret, nsplits; for (i = s->randomVectorSplit_sim1[s->lev-1]; i < s->randomVectorSplit_sim1[s->lev]; i++) { - randVec = Vec_PtrEntry(s->randomVectorArray_sim1, i); + randVec = (Vec_Int_t *)Vec_PtrEntry(s->randomVectorArray_sim1, i); g = buildSim1Graph(s->pNtk, c, randVec, s->iDep, s->oDep); if (g == NULL) { @@ -1457,7 +1457,7 @@ refineBySim2_other(struct saucy *s, struct coloring *c) int ret, nsplits; for (i = s->randomVectorSplit_sim2[s->lev-1]; i < s->randomVectorSplit_sim2[s->lev]; i++) { - randVec = Vec_PtrEntry(s->randomVectorArray_sim2, i); + randVec = (Vec_Int_t *)Vec_PtrEntry(s->randomVectorArray_sim2, i); g = buildSim2Graph(s->pNtk, c, randVec, s->iDep, s->oDep, s->topOrder, s->obs, s->ctrl); if (g == NULL) { @@ -2050,11 +2050,11 @@ rewind_simulation_vectors(struct saucy *s, int lev) { int i; for (i = s->randomVectorSplit_sim1[lev]; i < Vec_PtrSize(s->randomVectorArray_sim1); i++) - Vec_IntFree(Vec_PtrEntry(s->randomVectorArray_sim1, i)); + Vec_IntFree((Vec_Int_t *)Vec_PtrEntry(s->randomVectorArray_sim1, i)); Vec_PtrShrink(s->randomVectorArray_sim1, s->randomVectorSplit_sim1[lev]); for (i = s->randomVectorSplit_sim2[lev]; i < Vec_PtrSize(s->randomVectorArray_sim2); i++) - Vec_IntFree(Vec_PtrEntry(s->randomVectorArray_sim2, i)); + Vec_IntFree((Vec_Int_t *)Vec_PtrEntry(s->randomVectorArray_sim2, i)); Vec_PtrShrink(s->randomVectorArray_sim2, s->randomVectorSplit_sim2[lev]); } @@ -2163,12 +2163,12 @@ prepare_permutation_ntk(struct saucy *s) for (i = 0; i < s->n; ++i) { if (i < numouts) { - pObj = Vec_PtrEntry(s->pNtk->vPos, i); - pObjPerm = Vec_PtrEntry(s->pNtk_permuted->vPos, s->gamma[i]); + pObj = (Abc_Obj_t *)Vec_PtrEntry(s->pNtk->vPos, i); + pObjPerm = (Abc_Obj_t *)Vec_PtrEntry(s->pNtk_permuted->vPos, s->gamma[i]); } else { - pObj = Vec_PtrEntry(s->pNtk->vPis, i - numouts); - pObjPerm = Vec_PtrEntry(s->pNtk_permuted->vPis, s->gamma[i] - numouts); + pObj = (Abc_Obj_t *)Vec_PtrEntry(s->pNtk->vPis, i - numouts); + pObjPerm = (Abc_Obj_t *)Vec_PtrEntry(s->pNtk_permuted->vPis, s->gamma[i] - numouts); } Abc_ObjAssignName( pObjPerm, Abc_ObjName(pObj), NULL ); @@ -2217,12 +2217,12 @@ unprepare_permutation_ntk(struct saucy *s) for (i = 0; i < s->n; ++i) { if (i < numouts) { - pObj = Vec_PtrEntry(s->pNtk->vPos, s->gamma[i]); - pObjPerm = Vec_PtrEntry(s->pNtk_permuted->vPos, i); + pObj = (Abc_Obj_t *)Vec_PtrEntry(s->pNtk->vPos, s->gamma[i]); + pObjPerm = (Abc_Obj_t *)Vec_PtrEntry(s->pNtk_permuted->vPos, i); } else { - pObj = Vec_PtrEntry(s->pNtk->vPis, s->gamma[i] - numouts); - pObjPerm = Vec_PtrEntry(s->pNtk_permuted->vPis, i - numouts); + pObj = (Abc_Obj_t *)Vec_PtrEntry(s->pNtk->vPis, s->gamma[i] - numouts); + pObjPerm = (Abc_Obj_t *)Vec_PtrEntry(s->pNtk_permuted->vPis, i - numouts); } Abc_ObjAssignName( pObjPerm, Abc_ObjName(pObj), NULL ); @@ -2546,9 +2546,9 @@ saucy_free(struct saucy *s) Vec_IntFree( s->ctrl[i] ); } for (i = 0; i < Vec_PtrSize(s->randomVectorArray_sim1); i++) - Vec_IntFree(Vec_PtrEntry(s->randomVectorArray_sim1, i)); + Vec_IntFree((Vec_Int_t *)Vec_PtrEntry(s->randomVectorArray_sim1, i)); for (i = 0; i < Vec_PtrSize(s->randomVectorArray_sim2); i++) - Vec_IntFree(Vec_PtrEntry(s->randomVectorArray_sim2, i)); + Vec_IntFree((Vec_Int_t *)Vec_PtrEntry(s->randomVectorArray_sim2, i)); Vec_PtrFree( s->randomVectorArray_sim1 ); Vec_PtrFree( s->randomVectorArray_sim2 ); ABC_FREE(s->randomVectorSplit_sim1); @@ -2695,9 +2695,9 @@ getVertexName(Abc_Ntk_t *pNtk, int v) int numouts = Abc_NtkPoNum(pNtk); if (v < numouts) - pObj = Vec_PtrEntry(pNtk->vPos, v); + pObj = (Abc_Obj_t *)Vec_PtrEntry(pNtk->vPos, v); else - pObj = Vec_PtrEntry(pNtk->vPis, v - numouts); + pObj = (Abc_Obj_t *)Vec_PtrEntry(pNtk->vPis, v - numouts); return Abc_ObjName(pObj); } @@ -3100,7 +3100,7 @@ bumpActivity( struct saucy * s, struct sim_result * cex ) if ( (cex->activity += s->activityInc) > 1e20 ) { /* Rescale: */ for (i = 0; i < Vec_PtrSize(s->satCounterExamples); i++) { - cex2 = Vec_PtrEntry(s->satCounterExamples, i); + cex2 = (struct sim_result *)Vec_PtrEntry(s->satCounterExamples, i); cex2->activity *= 1e-20; } s->activityInc *= 1e-20; @@ -3116,7 +3116,7 @@ reduceDB( struct saucy * s ) while (Vec_PtrSize(s->satCounterExamples) > (0.7 * MAX_LEARNTS)) { for (i = j = 0; i < Vec_PtrSize(s->satCounterExamples); i++) { - cex = Vec_PtrEntry(s->satCounterExamples, i); + cex = (struct sim_result *)Vec_PtrEntry(s->satCounterExamples, i); if (cex->activity < extra_lim) { ABC_FREE(cex->inVec); ABC_FREE(cex->outVec); |