summaryrefslogtreecommitdiffstats
path: root/src/opt/dec
diff options
context:
space:
mode:
Diffstat (limited to 'src/opt/dec')
-rw-r--r--src/opt/dec/decAbc.c8
-rw-r--r--src/opt/dec/decFactor.c1
-rw-r--r--src/opt/dec/decMan.c2
-rw-r--r--src/opt/dec/decUtil.c13
4 files changed, 12 insertions, 12 deletions
diff --git a/src/opt/dec/decAbc.c b/src/opt/dec/decAbc.c
index 6adb0f98..2886668e 100644
--- a/src/opt/dec/decAbc.c
+++ b/src/opt/dec/decAbc.c
@@ -43,7 +43,7 @@
Abc_Obj_t * Dec_GraphToNetwork( Abc_Ntk_t * pNtk, Dec_Graph_t * pGraph )
{
Abc_Obj_t * pAnd0, * pAnd1;
- Dec_Node_t * pNode;
+ Dec_Node_t * pNode = NULL; // Suppress "might be used uninitialized"
int i;
// check for constant function
if ( Dec_GraphIsConst(pGraph) )
@@ -77,7 +77,7 @@ Abc_Obj_t * Dec_GraphToNetwork( Abc_Ntk_t * pNtk, Dec_Graph_t * pGraph )
Abc_Obj_t * Dec_GraphToNetworkNoStrash( Abc_Ntk_t * pNtk, Dec_Graph_t * pGraph )
{
Abc_Obj_t * pAnd, * pAnd0, * pAnd1;
- Dec_Node_t * pNode;
+ Dec_Node_t * pNode = NULL; // Suppress "might be used uninitialized"
int i;
// check for constant function
if ( Dec_GraphIsConst(pGraph) )
@@ -217,7 +217,7 @@ void Dec_GraphUpdateNetwork( Abc_Obj_t * pRoot, Dec_Graph_t * pGraph, bool fUpda
***********************************************************************/
Hop_Obj_t * Dec_GraphToNetworkAig( Hop_Man_t * pMan, Dec_Graph_t * pGraph )
{
- Dec_Node_t * pNode;
+ Dec_Node_t * pNode = NULL; // Suppress "might be used uninitialized"
Hop_Obj_t * pAnd0, * pAnd1;
int i;
// check for constant function
@@ -278,7 +278,7 @@ Hop_Obj_t * Dec_GraphFactorSop( Hop_Man_t * pMan, char * pSop )
***********************************************************************/
Ivy_Obj_t * Dec_GraphToNetworkIvy( Ivy_Man_t * pMan, Dec_Graph_t * pGraph )
{
- Dec_Node_t * pNode;
+ Dec_Node_t * pNode = NULL; // Suppress "might be used uninitialized"
Ivy_Obj_t * pAnd0, * pAnd1;
int i;
// check for constant function
diff --git a/src/opt/dec/decFactor.c b/src/opt/dec/decFactor.c
index 768dcd9b..94205196 100644
--- a/src/opt/dec/decFactor.c
+++ b/src/opt/dec/decFactor.c
@@ -231,7 +231,6 @@ Dec_Edge_t Dec_FactorTrivial( Dec_Graph_t * pFForm, Mvc_Cover_t * pCover )
Dec_Man_t * pManDec = Abc_FrameReadManDec();
Vec_Int_t * vEdgeCubes = pManDec->vCubes;
Vec_Int_t * vEdgeLits = pManDec->vLits;
- Mvc_Manager_t * pMem = pManDec->pMvcMem;
Dec_Edge_t eNode;
Mvc_Cube_t * pCube;
// create the factored form for each cube
diff --git a/src/opt/dec/decMan.c b/src/opt/dec/decMan.c
index 65857461..3d65ffc5 100644
--- a/src/opt/dec/decMan.c
+++ b/src/opt/dec/decMan.c
@@ -42,7 +42,7 @@
Dec_Man_t * Dec_ManStart()
{
Dec_Man_t * p;
- int clk = clock();
+// int clk = clock();
p = ALLOC( Dec_Man_t, 1 );
p->pMvcMem = Mvc_ManagerStart();
p->vCubes = Vec_IntAlloc( 8 );
diff --git a/src/opt/dec/decUtil.c b/src/opt/dec/decUtil.c
index 463bc7e2..aeabeac4 100644
--- a/src/opt/dec/decUtil.c
+++ b/src/opt/dec/decUtil.c
@@ -41,7 +41,7 @@
DdNode * Dec_GraphDeriveBdd( DdManager * dd, Dec_Graph_t * pGraph )
{
DdNode * bFunc, * bFunc0, * bFunc1;
- Dec_Node_t * pNode;
+ Dec_Node_t * pNode = NULL; // Suppress "might be used uninitialized"
int i;
// sanity checks
@@ -91,7 +91,8 @@ DdNode * Dec_GraphDeriveBdd( DdManager * dd, Dec_Graph_t * pGraph )
unsigned Dec_GraphDeriveTruth( Dec_Graph_t * pGraph )
{
unsigned uTruths[5] = { 0xAAAAAAAA, 0xCCCCCCCC, 0xF0F0F0F0, 0xFF00FF00, 0xFFFF0000 };
- unsigned uTruth, uTruth0, uTruth1;
+ unsigned uTruth = 0; // Suppress "might be used uninitialized"
+ unsigned uTruth0, uTruth1;
Dec_Node_t * pNode;
int i;
@@ -109,17 +110,17 @@ unsigned Dec_GraphDeriveTruth( Dec_Graph_t * pGraph )
// assign the elementary variables
Dec_GraphForEachLeaf( pGraph, pNode, i )
- pNode->pFunc = (void *)uTruths[i];
+ pNode->pFunc = (void *)(PORT_PTRUINT_T)uTruths[i];
// compute the function for each internal node
Dec_GraphForEachNode( pGraph, pNode, i )
{
- uTruth0 = (unsigned)Dec_GraphNode(pGraph, pNode->eEdge0.Node)->pFunc;
- uTruth1 = (unsigned)Dec_GraphNode(pGraph, pNode->eEdge1.Node)->pFunc;
+ uTruth0 = (unsigned)(PORT_PTRUINT_T)Dec_GraphNode(pGraph, pNode->eEdge0.Node)->pFunc;
+ uTruth1 = (unsigned)(PORT_PTRUINT_T)Dec_GraphNode(pGraph, pNode->eEdge1.Node)->pFunc;
uTruth0 = pNode->eEdge0.fCompl? ~uTruth0 : uTruth0;
uTruth1 = pNode->eEdge1.fCompl? ~uTruth1 : uTruth1;
uTruth = uTruth0 & uTruth1;
- pNode->pFunc = (void *)uTruth;
+ pNode->pFunc = (void *)(PORT_PTRUINT_T)uTruth;
}
// complement the result if necessary