Skip to content

Valgrind Error Details

back to process details
back to processes overview
Executable/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
PID26354
PPID16382
Unique ID0x120b
Text104,544 bytes in 4 blocks are still reachable in loss record 4,618 of 4,624
Auxiliary
Suppression{
   <insert_a_suppression_name_here>
   Memcheck:Leak
   match-leak-kinds: reachable
   fun:malloc
   fun:PXAllocate2
   fun:PXCreateLocAttachRealElem
   fun:PXCreateAttachRealElem
   fun:PXComputeMassMatrix
   fun:PXPreComputeMassMatrix
   fun:PXCalculateResidual
   fun:PXUnsteadyPrimalStageResidual
   fun:PXSolveUnsteadyStep
   fun:PXComputeCurrentResidual
   fun:PXProlongatedStateResidual
   fun:PXTruthSurrogate
   fun:PXErrorIndicatorOutput
   fun:PXFillAttachmentSet
   fun:PXAdaptHPDirectSingleStep
   fun:PXAdaptHPDirectSingleStepWrapper
   fun:PXSolveUnsteadyDualProblem
   fun:PXSolveDual
   fun:PXPSequencing
   fun:main
}

Stacktrace

Object/usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so
Functionmalloc
File/Line
CodeSource code not available

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXAllocate2
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/Fundamentals/PXMemory.c:146
Code
136     *po=NULL;
137     return PX_NO_ERROR;
138   }
139 
140   if ( (_po   = (char **)mallocn1*sizeof(char *) )) == NULL ){
141     *po=NULL;
142     return PXError(PX_MEMORY_ERROR);
143   }
144 
145   if (n2 != 0){
146     if ( (temp = (char  *)malloc(tot)                 ) == NULL ) {
147       free(_po;
148       *po=NULL;
149       return PXError(PX_MEMORY_ERROR);
150     }
151 

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXCreateLocAttachRealElem
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/Grid/PXGridAttachments.c:873
Code
0863   /* Set rank */
0864   rank = StateRank*nbf;
0865   (*RealElemData)->rank = rank;
0866 
0867   /* Get number of elements */
0868   nelem = pg->ElementGroup[egrp].nElement;
0869 
0870   /* Allocate space for Value */
0871   (*RealElemData)->value = NULL;
0872   if (nelem > 0) {
0873     PXErrorReturnPXAllocate2nelem, rank, sizeof(PX_REAL)(void **)&((*RealElemData)->value) ) );
0874   }
0875 
0876   return PX_NO_ERROR;
0877 /* End PXCreateLocAttachRealElem */
0878 

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXCreateAttachRealElem
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/Grid/PXGridAttachments.c:1106
Code
1096 PXCreateAttachRealElemPX_Grid *pg, const char title[]int egrp, enum PXE_SolutionOrder order, int StateRank, PX_AttachmentRealElem **RealElemData ){
1097   int an;     // attachment number
1098 
1099   /* Create Generic Attachment */
1100   PXErrorReturnPXCreateGenAttachpg, title, &an ) );
1101 
1102   /* Set Attachment Type */
1103   pg->Attachment[an].type = PXE_AttachmentRealElem;
1104 
1105   /* Create Local Attachment */
1106   PXErrorReturnPXCreateLocAttachRealElempg, egrp, order, StateRank, (PX_AttachmentRealElem **&(pg->Attachment[an].data)) );
1107 
1108   /* Set Reader and Write */
1109   pg->Attachment[an].Writer = PXWriteLocAttachRealElem;
1110   pg->Attachment[an].Reader = PXReadLocAttachRealElem;
1111 

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXComputeMassMatrix
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/Grid/PXBasis.c:531
Code
0521   memsettitle, '\0', PX_MAXSTRLEN );
0522 
0523   /* Get Dim */
0524   Dim = pg->Dim;
0525 
0526   /* Get number of basis functions */
0527   PXErrorReturnPXOrder2nbf(order, &nbf) );
0528 
0529   /* Create Mass Matrix Attachment */
0530   sprintf(title, "%s_%d_%d""MassMatrix", order, egrp);
0531   PXErrorReturnPXCreateAttachRealElempg, title, egrp, order, nbf, &MMData ));
0532   MMData->DataType = PXE_AttachmentDataType_TemporarySolver;
0533 
0534   /*---------------------*/
0535   /* Compute Mass Matrix */
0536   /*---------------------*/

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXPreComputeMassMatrix
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/Grid/PXBasis.c:946
Code
0936   for (egrp = 0; egrp < negrp+nghostegrp; egrp++) {
0937     /* Get element type */
0938     //type = pg->ElementGroup[egrp].type;
0939 
0940     //if ( ( type != PXE_UniformTriangleQ1) && ( type != PXE_UniformTetQ1 ) ) {
0941     if(1){
0942       /* Search for existing mass matrix */
0943       ierr = PXSearchMassMatrix(pg, egrp, order[egrp%negrp], &MMData);
0944       if (ierr == PX_SEARCH_NOT_FOUND) {
0945         /* If not found compute mass matrix */
0946         PXErrorReturnPXComputeMassMatrix(pg, egrp, order[egrp%negrp]));
0947       }
0948       else{
0949         PXErrorReturn(ierr);
0950       }
0951 

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXCalculateResidual
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXResidual.c:16304
Code
16294 
16295   /* Begin Ghost update */
16296   PXErrorReturnPXAttachGREGhostUpdateBegin(pg, State) );
16297   for (outputrank = 0; outputrank < NAdjOutput; outputrank++) {
16298     PXErrorReturnPXAttachGREGhostUpdateBegin(pg, AdjState[outputrank]) );
16299   }
16300   for (iSensParam = 0; iSensParam < nSensParam; iSensParam++)
16301     PXErrorReturnPXAttachGREGhostUpdateBegin(pg, TanState[iSensParam]) );
16302 
16303   /* Make sure mass matrix exists if not create it */
16304   PXErrorReturnPXPreComputeMassMatrix(pg, State->order) );
16305 
16306   /* Pre-residual calculation functions */
16307   PXErrorReturnPXPreResidual(pxa, &ResJobParams, PXE_False, State) );
16308 
16309   //PXErrorReturn( PXPrecalcElemThings(pxa, State->order) );

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXUnsteadyPrimalStageResidual
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXSolver.c:4806
Code
04796   }
04797 
04798 
04799   /* Set to spatial residual */
04800   /* Must be the first term added after zeroing because of scaling */
04801   if explicitStage == PXE_False ){
04802 
04803     if SpatialResidual != NULL ){
04804       PXErrorReturnPXAttachGRESetEqualpg, Residual, SpatialResidual) );
04805     else {
04806       PXErrorReturnPXCalculateResidualpxa, mode, State, NULL, NULL,
04807                                           Residual, NULL, NULL, NULL ) );
04808     }
04809 
04810     tempReal = diagonalFactor*unsteadyStep.butcherCoef[iStage][iStage];
04811     PXErrorReturnPXAttachGREScalepg, PXE_False, Residual, tempReal, NULL ));

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXSolveUnsteadyStep
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXSolver.c:9217
Code
09207                                                   StageSpatialRes,
09208                                                   NULL, NULL, NULL, NULL, NULL ) );
09209       }
09210     }
09211 
09212     /* Finish the stage residual calculation (we have already included a 'Source', so it is not passed intentionally */
09213     for iStage=; iStage<nStage ; iStage++ ){
09214       /* Retrieve Source terms from StageRes[iStage] (StageRes[iStage] gets zero'd inside stage residual calc) */
09215       if Source != NULL && UnsteadyFlag == PXE_True )
09216         PXErrorReturnPXAttachGRESetEqual(pg, Source, StageRes[iStage] ) );
09217       PXErrorReturnPXUnsteadyPrimalStageResidualpxa, mode, UnsteadyStruct, currentIndex, iStage,
09218                                                     StageState[iStage], Source,
09219                                                     (iStage<nStage-1)?(StageSpatialRes[iStage]):(NULL),
09220                                                         StageRes[iStage] ) );
09221     }
09222   }

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXComputeCurrentResidual
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXSolver.c:5286
Code
05276         StageResidual[iStage]->DataType = PXE_AttachmentDataType_Residual;
05277       }
05278       (*pStageResidualIn= StageResidual;
05279     }
05280     else
05281     /* Attachment exists, and just need to initialize it */
05282       StageResidual = (*pStageResidualIn);
05283     }
05284 
05285     /* Compute residual for given primal state(s) */
05286     PXErrorReturnPXSolveUnsteadySteppxa, currentIndex, UnsteadyStruct,
05287                                         UnsteadyFlag, PXE_Mode_Residual,
05288                                         StageState, NULL,
05289                                         PrevState, StageResidual,
05290                                         NULL, NULL, NULL, NULL,
05291                                         NULL, NULL, NULL, NULL, NULL, NULL, NULL,

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXProlongatedStateResidual
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXErrEst.c:1185
Code
1175 
1176     if pProStageResidualIn != NULL ){
1177       if pProStageAdjResidualIn != NULL ){
1178   /* Both residuals */
1179   PXErrorReturnPXComputeCurrentResidual(pxa, currentIndex, UnsteadyStruct, UnsteadyFlag,
1180             ProStageState, ProPrevState, &ProStageResidual,
1181             ProStageAdjState, ProNextStageAdjState, &ProStageAdjResidual) );
1182       }
1183       else{
1184   /* Primal residual only */
1185   PXErrorReturnPXComputeCurrentResidual(pxa, currentIndex, UnsteadyStruct, UnsteadyFlag,
1186             ProStageState, ProPrevState, &ProStageResidual,
1187             NULL, NULL, NULL) );
1188       }
1189     }
1190     else if pProStageAdjResidualIn != NULL ){

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXTruthSurrogate
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXErrEst.c:1332
Code
1322   /* we need to compute (=> create LocAttachGRE) TSStageAdjState if DualTSFlag == True AND
1323     (pTSStageAdjIn == NULL (implies no StateAdj was passed in) OR
1324 
1325     *pTSStageAdjIn == NULL (something was passed in, but it points to NULL)
1326   */
1327   if UnsteadyFlag == PXE_True ){
1328     Need_TSPrevState         = ((pTSPrevStateIn         == NULL || *pTSPrevStateIn        ==NULL&& PrimalTSFlag==PXE_True? PXE_True : PXE_False;
1329     Need_TSNextStageAdjState = ((pTSNextStageAdjStateIn == NULL || *pTSNextStageAdjStateIn==NULL&& DualTSFlag==PXE_True  ? PXE_True : PXE_False;
1330   }
1331 
1332   PXErrorReturnPXProlongatedStateResidualpxa, currentIndex, UnsteadyStruct,
1333                                              StageState,
1334                                              PrevState,
1335                                              StageAdjState,
1336                                              NextStageAdjState,
1337                                              ((Need_TSStageState        == PXE_True? &TSStageState : NULL),

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXErrorIndicatorOutput
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXErrEst.c:1562
Code
1552   /* compute higher order primal and adjoint residuals at the prolongated states */
1553   /*-----------------------------------------------------------------------------*/
1554 
1555   if ComputePrimalTSFlag == PXE_True || ComputeDualTSFlag == PXE_True ){
1556     if PrintFlag == PXE_True ){
1557       PXPrintf("\n-------------------------------------------------------------------\n");
1558       PXPrintf(  " Smoothing primal and/or adjoint solutions using nonlinear solver.\n");
1559       PXPrintf(  "-------------------------------------------------------------------\n");
1560     }
1561 
1562     PXErrorReturnPXTruthSurrogate(pxa, currentIndex, UnsteadyStruct,
1563                                     ComputePrimalTSFlag, ComputeDualTSFlag, LocalFlag,
1564                                     StageState, PrevState, StageAdjState, NextStageAdjState,
1565                                     &TSStageState, &TSPrevState, &ProStageResidual,
1566                                     &TSStageAdjState, &TSNextStageAdjState,
1567                                     (DualErrorFlag==PXE_True||pProStageAdjResidualIn!=NULL)?&ProStageAdjResidual:NULL ) );

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXFillAttachmentSet
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXHPAdaptDirect.c:2311
Code
2301                &(AttachSet->TSNextStageAdjState) ) );
2302     }
2303   }
2304 
2305   AttachSet->nStage        = nStage;
2306   AttachSet->nPrevState    = nPrevState;
2307   AttachSet->maxNStage     = maxNStage;
2308   AttachSet->maxNPrevState = maxNPrevState;
2309 
2310   /* Perform error estimate */
2311   PXErrorReturn(PXErrorIndicatorOutputpxa,UnsteadyIndex,UnsteadyStruct,
2312           UnsteadyFlag, PXE_True, PXE_False,
2313           PXE_False, PXE_False,
2314           AttachSet->StageState,AttachSet->PrevState,
2315           AttachSet->StageAdjState,AttachSet->NextStageAdjState,
2316           NULL,NULL,NULL,

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXAdaptHPDirectSingleStep
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXHPAdaptDirect.c:7757
Code
7747   /* compute truth surrogate and error indicator*/
7748   PXErrorReturn(PXInitAttachSet(AttachSet));
7749 #ifdef PX_TIMING
7750   PXBarrier();
7751   c0 = PXclock();
7752 #endif
7753 
7754 #ifPX_UNIT_TEST==)
7755   PXErrorReturn(PXFillAttachmentSetDummy(pxa,AttachSet,pErrorEstSum,pErrorEstAbsSum));
7756 #else
7757   PXErrorReturn(PXFillAttachmentSet(pxa,AttachSet,UnsteadyIndex,pErrorEstSum,pErrorEstAbsSum));
7758 #endif
7759 
7760   if porder0 != NULL *porder0 = AttachSet->StageState[0]->order[0];
7761 #ifdef PX_TIMING
7762   PXBarrier();

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXAdaptHPDirectSingleStepWrapper
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXHPAdaptDirect.c:7869
Code
7859   else {
7860     pgmesh = pg->pgback;
7861     if (pgmesh == NULLPXErrorReturn(PX_BAD_INPUT);
7862   }
7863   PXErrorReturn(PXConvertGrid2Mesh(pgmesh,meshback,Mesh2GridMap));
7864 
7865   /* Initialize elemerror */
7866   PXErrorReturn(PXAllocateElementError(meshback,ElemError));
7867 
7868   /* Fill element error for this single step */
7869   PXErrorReturnPXAdaptHPDirectSingleSteppxa, UnsteadyIndex,
7870                                             meshback, Mesh2GridMap, ElemError, NULL,
7871                                             pErrorEstSum, pErrorEstAbsSum ) );
7872 
7873   /* Retrieve error and metric GRE attachments */
7874   PXErrorReturnPXAttachSearch(pgmesh,"ElemError0",NULL,(void *)&ElemError0) );

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXSolveUnsteadyDualProblem
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXSolver.c:10865
Code
10855                                                               &ErrorEstSum, &ErrorEstAbsSum) );
10856 
10857       }
10858       else
10859       {
10860 
10861 #ifdef PX_TIMING
10862         c0 = PXclock();
10863 #endif
10864         /* Build grid and fill ElemError structure */
10865         PXErrorReturnPXAdaptHPDirectSingleStepWrapper(pxa, currentIndex,
10866                                                         &ErrorEstSum, &ErrorEstAbsSum) );
10867 #ifdef PX_TIMING
10868         c1 = PXclock();
10869         PXPrintf("Time : (DualSolve(P+1andLocSolve)) = %f\n", c1-c0 );
10870 #endif

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXSolveDual
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXRunSolver.c:529
Code
0519   PXErrorReturnPXGetKeyValueIntpxa->Parameter, "AdaptIter", &AdaptIter ) );
0520 
0521   /*--------------------*/
0522   /* Solve Dual Problem */
0523   /*--------------------*/
0524 
0525   PXPrintf("\n*************\n");
0526   PXPrintf(  " Dual Solver \n");
0527   PXPrintf(  "*************\n");
0528 
0529   PXErrorReturnPXSolveUnsteadyDualProblem(pxa, &AdaptFlag, &ConvergedFlag) );
0530 
0531   /*-------------------*/
0532   /* Write Output File */
0533   /*-------------------*/
0534 

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
FunctionPXPSequencing
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXRunSolver.c:710
Code
0700       if iSolOrder == SolOrder ){
0701   iAdaptFlag = AdaptFlag;
0702       else {
0703   iAdaptFlag = PXE_False;
0704       }
0705 
0706 #ifdef PX_TIMING
0707     PXBarrier();
0708     c0 = PXclock();
0709 #endif
0710       PXErrorReturnPXSolveDual(pxa, iAdaptFlag, aiter, &ConvergedFlag, &iSolOrder) );
0711 #ifdef PX_TIMING
0712     PXBarrier();
0713     c1 = PXclock();
0714     PXPrintf("Time : (DualSolveTotal) = %f\n", c1-c0 );
0715 #endif

Object/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/platforms/relwithdebinfo_gnu/bin/ProjectXExec
Functionmain
File/Line/home1/jenkins/workspace/ProjectX_Weekly/PX_ARC/relwithdebinfo_gnu/buildnode/reynolds/src/PXRunSolver.c:999
Code
0989     PXErrorReturnPXInitializeAdaptIterpxa, aiter ) );
0990     //pg = pxa->pg;
0991 
0992 #ifdef PX_TIMING
0993     PXBarrier();
0994     c2=PXclock();
0995     PXPrintf("Time : (InitializeAdaptIter) = %f\n", c2 - c1 );
0996 #endif
0997 
0998     /* Perform PSequencing */
0999     PXErrorReturnPXPSequencingpxa, AdaptFlag, aiter, &ConvergedFlag ) );
1000 
1001 #ifdef PX_TIMING
1002     PXBarrier();
1003     c1=PXclock();
1004     PXPrintf("Time : (PXPSequencing) = %f\n",  c1 - c2);