INFO: No output directory specified (--dir) INFO: Using directory: "ILL_H16_IN5_Mantid_20250813_233916" INFO: Regenerating c-file: ILL_H16_IN5_Mantid.c DEBUG: CMD: /home/willend/micromamba/bin/mcstas -t -o ./ILL_H16_IN5_Mantid.c ILL_H16_IN5_Mantid.instr Info: 'PSD_Detector' is a contributed component. CFLAGS= @NEXUSFLAGS@ WARNING: The parameter powder_format of sampleMantid is initialized using a static {,,,} vector. -> Such static vectors support literal numbers ONLY. -> Any vector use of variables or defines must happen via a DECLARE/INITIALIZE pointer. WARNING: The parameter format of hous is initialized using a static {,,,} vector. -> Such static vectors support literal numbers ONLY. -> Any vector use of variables or defines must happen via a DECLARE/INITIALIZE pointer. ----------------------------------------------------------- Generating single GPU kernel or single CPU section layout: -> SPLIT N at component sampleMantid ----------------------------------------------------------- Generating GPU/CPU -DFUNNEL layout: -> SPLIT within buffer at component sampleMantid ----------------------------------------------------------- DEBUG: CMD: /home/willend/micromamba/bin/mcstas finished INFO: Linting generated code: ./ILL_H16_IN5_Mantid.c DEBUG: CMD: cppcheck ./ILL_H16_IN5_Mantid.c --check-level=exhaustive --force -DMCDEFAULT_NCOUNT=1000000 -UMC_PORTABLE -DND_BUFFER=10000000 -UNOABSORB_INF_NAN -UOMPI_MPI_H -DSIGABRT -DSIGBREAK -DSIGBUS -DSIGPE -DSIGHUP -DSIGILL -DSIGINT -DSIGKILL -DSIGUSR1 -DSIGUSR2 -DSIGPIPE -DSIGQUIT -DSIGSEGV -DSIGTRAP -DSIGURG -DSIGFPE -DSIGKILL -DSIGTERM -UTEST -UUSE_OPENCL -UWIN32 -UOPENACC -UGCCOFFLOAD -U_MSC_VER -U_MSC_EXTENSIONS -U_WIN32 -UWIN32 -D__unix__ -UDANSE -UFUNNEL -UMC_ANCIENT_COMPATIBILITY -UMC_POL_COMPAT -UNEUTRONICS -Uisnan -Uisinf Checking ILL_H16_IN5_Mantid.c ... Checking ILL_H16_IN5_Mantid.c: MCDEFAULT_NCOUNT=1000000;ND_BUFFER=10000000;SIGABRT=1;SIGBREAK=1;SIGBUS=1;SIGPE=1;SIGHUP=1;SIGILL=1;SIGINT=1;SIGKILL=1;SIGUSR1=1;SIGUSR2=1;SIGPIPE=1;SIGQUIT=1;SIGSEGV=1;SIGTRAP=1;SIGURG=1;SIGFPE=1;SIGKILL=1;SIGTERM=1;__unix__=1... ILL_H16_IN5_Mantid.c:13879:37: warning: If memory allocation fails, then there is a possible null pointer dereference: w_file2full [nullPointerOutOfMemory] for (index_w=0; index_w < w_bins; w_file2full[index_w++]=0); ^ ILL_H16_IN5_Mantid.c:13877:31: note: Assuming allocation function fails double *w_file2full = malloc(w_bins*sizeof(double)); /* lookup table for fast file -> Sqw_full allocation */ ^ ILL_H16_IN5_Mantid.c:13877:31: note: Assignment 'w_file2full=malloc(w_bins*sizeof(double))', assigned value is 0 double *w_file2full = malloc(w_bins*sizeof(double)); /* lookup table for fast file -> Sqw_full allocation */ ^ ILL_H16_IN5_Mantid.c:13879:37: note: Null pointer dereference for (index_w=0; index_w < w_bins; w_file2full[index_w++]=0); ^ ILL_H16_IN5_Mantid.c:13919:39: warning: If memory allocation fails, then there is a possible null pointer dereference: q_file2full [nullPointerOutOfMemory] for (index_q=0; index_q < q_bins; q_file2full[index_q++]=0); ^ ILL_H16_IN5_Mantid.c:13918:29: note: Assuming allocation function fails double *q_file2full=malloc(q_bins*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:13918:29: note: Assignment 'q_file2full=malloc(q_bins*sizeof(double))', assigned value is 0 double *q_file2full=malloc(q_bins*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:13919:39: note: Null pointer dereference for (index_q=0; index_q < q_bins; q_file2full[index_q++]=0); ^ ILL_H16_IN5_Mantid.c:13938:5: warning: If memory allocation fails, then there is a possible null pointer dereference: q_file2full [nullPointerOutOfMemory] q_file2full[index_q] = index_q_file; ^ ILL_H16_IN5_Mantid.c:13918:29: note: Assuming allocation function fails double *q_file2full=malloc(q_bins*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:13918:29: note: Assignment 'q_file2full=malloc(q_bins*sizeof(double))', assigned value is 0 double *q_file2full=malloc(q_bins*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:13938:5: note: Null pointer dereference q_file2full[index_q] = index_q_file; ^ ILL_H16_IN5_Mantid.c:13948:20: warning: If memory allocation fails, then there is a possible null pointer dereference: q_file2full [nullPointerOutOfMemory] index_q_file = q_file2full[index_q]; ^ ILL_H16_IN5_Mantid.c:13918:29: note: Assuming allocation function fails double *q_file2full=malloc(q_bins*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:13918:29: note: Assignment 'q_file2full=malloc(q_bins*sizeof(double))', assigned value is 0 double *q_file2full=malloc(q_bins*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:13948:20: note: Null pointer dereference index_q_file = q_file2full[index_q]; ^ ILL_H16_IN5_Mantid.c:23285:5: warning: If memory allocation fails, then there is a possible null pointer dereference: E_p [nullPointerOutOfMemory] E_p[i] = Table_Index(Part_He_3_p,i,0); ^ ILL_H16_IN5_Mantid.c:23281:26: note: Assuming allocation function fails E_p = (double *) malloc(nH_p*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23281:9: note: Assignment 'E_p=(double*)malloc(_comp->_parameters.nH_p*sizeof(double))', assigned value is 0 E_p = (double *) malloc(nH_p*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23285:5: note: Null pointer dereference E_p[i] = Table_Index(Part_He_3_p,i,0); ^ ILL_H16_IN5_Mantid.c:23286:9: warning: If memory allocation fails, then there is a possible null pointer dereference: E_p [nullPointerOutOfMemory] if (E_p[i] != Table_Index(Part_Stop_p,i,0)) { ^ ILL_H16_IN5_Mantid.c:23281:26: note: Assuming allocation function fails E_p = (double *) malloc(nH_p*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23281:9: note: Assignment 'E_p=(double*)malloc(_comp->_parameters.nH_p*sizeof(double))', assigned value is 0 E_p = (double *) malloc(nH_p*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23286:9: note: Null pointer dereference if (E_p[i] != Table_Index(Part_Stop_p,i,0)) { ^ ILL_H16_IN5_Mantid.c:23291:5: warning: If memory allocation fails, then there is a possible null pointer dereference: dEdx_p [nullPointerOutOfMemory] dEdx_p[i] = PressureConv*Table_Index(Part_He_3_p,i,1) + PressureStop*Table_Index(Part_Stop_p,i,1); ^ ILL_H16_IN5_Mantid.c:23283:29: note: Assuming allocation function fails dEdx_p = (double *) malloc(nH_p*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23283:12: note: Assignment 'dEdx_p=(double*)malloc(_comp->_parameters.nH_p*sizeof(double))', assigned value is 0 dEdx_p = (double *) malloc(nH_p*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23286:16: note: Assuming condition is false if (E_p[i] != Table_Index(Part_Stop_p,i,0)) { ^ ILL_H16_IN5_Mantid.c:23291:5: note: Null pointer dereference dEdx_p[i] = PressureConv*Table_Index(Part_He_3_p,i,1) + PressureStop*Table_Index(Part_Stop_p,i,1); ^ ILL_H16_IN5_Mantid.c:23293:17: warning: If memory allocation fails, then there is a possible null pointer dereference: E_p [nullPointerOutOfMemory] FullEnergyP = E_p[nH_p-1]; ^ ILL_H16_IN5_Mantid.c:23281:26: note: Assuming allocation function fails E_p = (double *) malloc(nH_p*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23281:9: note: Assignment 'E_p=(double*)malloc(_comp->_parameters.nH_p*sizeof(double))', assigned value is 0 E_p = (double *) malloc(nH_p*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23286:16: note: Assuming condition is false if (E_p[i] != Table_Index(Part_Stop_p,i,0)) { ^ ILL_H16_IN5_Mantid.c:23293:17: note: Null pointer dereference FullEnergyP = E_p[nH_p-1]; ^ ILL_H16_IN5_Mantid.c:23299:30: warning: If memory allocation fails, then there is a possible null pointer dereference: DAP [nullPointerOutOfMemory] for (i=0; i_parameters.nH_p*sizeof(double))', assigned value is 0 DAP = (double *) malloc((nH_p)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23299:30: note: Null pointer dereference for (i=0; i_parameters.nH_p+1)*sizeof(double))', assigned value is 0 MuAP = (double *) malloc((nH_p+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23302:3: note: Null pointer dereference MuAP[0] = 0; ^ ILL_H16_IN5_Mantid.c:23303:30: warning: If memory allocation fails, then there is a possible null pointer dereference: MuAP [nullPointerOutOfMemory] for (i=1; i_parameters.nH_p+1)*sizeof(double))', assigned value is 0 MuAP = (double *) malloc((nH_p+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23303:30: note: Null pointer dereference for (i=1; i_parameters.nH_p*sizeof(double))', assigned value is 0 DAP = (double *) malloc((nH_p)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23303:45: note: Null pointer dereference for (i=1; i_parameters.nH_p+1)*sizeof(double))', assigned value is 0 MuAP = (double *) malloc((nH_p+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23308:63: note: Null pointer dereference for (i=1; i_parameters.nH_p+1)*sizeof(double))', assigned value is 0 TempVar34 = (double *) malloc((nH_p+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23313:30: note: Null pointer dereference for (i=0; i_parameters.nH_p+1)*sizeof(double))', assigned value is 0 TempVar34 = (double *) malloc((nH_p+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23314:45: note: Null pointer dereference for (i=0; i_parameters.nH_p+1)*sizeof(double))', assigned value is 0 TempVar34 = (double *) malloc((nH_p+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23315:30: note: Null pointer dereference for (i=0; i_parameters.nH_p+1)*sizeof(double))', assigned value is 0 TempVar34 = (double *) malloc((nH_p+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23316:45: note: Null pointer dereference for (i=0; i_parameters.nH_p*sizeof(double))', assigned value is 0 ETP1 = (double *) malloc((nH_p)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23321:28: note: Null pointer dereference for (i=0; i_parameters.nH_p*sizeof(double))', assigned value is 0 PTP1 = (double *) malloc((nH_p)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23324:28: note: Null pointer dereference for (i=0; i_parameters.nH_p*sizeof(double))', assigned value is 0 PTP1 = (double *) malloc((nH_p)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23329:52: note: Null pointer dereference for (i=1; i_parameters.nH_p*sizeof(double))', assigned value is 0 ETP1 = (double *) malloc((nH_p)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23329:62: note: Null pointer dereference for (i=1; i_parameters.nH_t*sizeof(double))', assigned value is 0 E_t = (double *) malloc(nH_t*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23339:5: note: Null pointer dereference E_t[i] = Table_Index(Part_He_3_t,i,0); ^ ILL_H16_IN5_Mantid.c:23340:9: warning: If memory allocation fails, then there is a possible null pointer dereference: E_t [nullPointerOutOfMemory] if (E_t[i] != Table_Index(Part_Stop_t,i,0)) { ^ ILL_H16_IN5_Mantid.c:23335:26: note: Assuming allocation function fails E_t = (double *) malloc(nH_t*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23335:9: note: Assignment 'E_t=(double*)malloc(_comp->_parameters.nH_t*sizeof(double))', assigned value is 0 E_t = (double *) malloc(nH_t*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23340:9: note: Null pointer dereference if (E_t[i] != Table_Index(Part_Stop_t,i,0)) { ^ ILL_H16_IN5_Mantid.c:23345:5: warning: If memory allocation fails, then there is a possible null pointer dereference: dEdx_t [nullPointerOutOfMemory] dEdx_t[i] = PressureConv*Table_Index(Part_He_3_t,i,1) + PressureStop*Table_Index(Part_Stop_t,i,1); ^ ILL_H16_IN5_Mantid.c:23337:29: note: Assuming allocation function fails dEdx_t = (double *) malloc(nH_t*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23337:12: note: Assignment 'dEdx_t=(double*)malloc(_comp->_parameters.nH_t*sizeof(double))', assigned value is 0 dEdx_t = (double *) malloc(nH_t*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23340:16: note: Assuming condition is false if (E_t[i] != Table_Index(Part_Stop_t,i,0)) { ^ ILL_H16_IN5_Mantid.c:23345:5: note: Null pointer dereference dEdx_t[i] = PressureConv*Table_Index(Part_He_3_t,i,1) + PressureStop*Table_Index(Part_Stop_t,i,1); ^ ILL_H16_IN5_Mantid.c:23347:17: warning: If memory allocation fails, then there is a possible null pointer dereference: E_t [nullPointerOutOfMemory] FullEnergyT = E_t[nH_t-1]; ^ ILL_H16_IN5_Mantid.c:23335:26: note: Assuming allocation function fails E_t = (double *) malloc(nH_t*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23335:9: note: Assignment 'E_t=(double*)malloc(_comp->_parameters.nH_t*sizeof(double))', assigned value is 0 E_t = (double *) malloc(nH_t*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23340:16: note: Assuming condition is false if (E_t[i] != Table_Index(Part_Stop_t,i,0)) { ^ ILL_H16_IN5_Mantid.c:23347:17: note: Null pointer dereference FullEnergyT = E_t[nH_t-1]; ^ ILL_H16_IN5_Mantid.c:23355:30: warning: If memory allocation fails, then there is a possible null pointer dereference: DAT [nullPointerOutOfMemory] for (i=0; i_parameters.nH_t*sizeof(double))', assigned value is 0 DAT = (double *) malloc((nH_t)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23355:30: note: Null pointer dereference for (i=0; i_parameters.nH_t+1)*sizeof(double))', assigned value is 0 MuAT = (double *) malloc((nH_t+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23358:3: note: Null pointer dereference MuAT[0] = 0; ^ ILL_H16_IN5_Mantid.c:23359:30: warning: If memory allocation fails, then there is a possible null pointer dereference: MuAT [nullPointerOutOfMemory] for (i=1; i_parameters.nH_t+1)*sizeof(double))', assigned value is 0 MuAT = (double *) malloc((nH_t+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23359:30: note: Null pointer dereference for (i=1; i_parameters.nH_t*sizeof(double))', assigned value is 0 DAT = (double *) malloc((nH_t)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23359:40: note: Null pointer dereference for (i=1; i_parameters.nH_t+1)*sizeof(double))', assigned value is 0 MuAT = (double *) malloc((nH_t+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23364:59: note: Null pointer dereference for (i=1; i_parameters.nH_t+1)*sizeof(double))', assigned value is 0 TempVar35 = (double *) malloc((nH_t+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23369:30: note: Null pointer dereference for (i=0; i_parameters.nH_t+1)*sizeof(double))', assigned value is 0 TempVar35 = (double *) malloc((nH_t+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23370:45: note: Null pointer dereference for (i=0; i_parameters.nH_t+1)*sizeof(double))', assigned value is 0 TempVar35 = (double *) malloc((nH_t+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23371:30: note: Null pointer dereference for (i=0; i_parameters.nH_t+1)*sizeof(double))', assigned value is 0 TempVar35 = (double *) malloc((nH_t+1)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23372:45: note: Null pointer dereference for (i=0; i_parameters.nH_t*sizeof(double))', assigned value is 0 ETT1 = (double *) malloc((nH_t)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23377:28: note: Null pointer dereference for (i=0; i_parameters.nH_t*sizeof(double))', assigned value is 0 PTT1 = (double *) malloc((nH_t)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23380:28: note: Null pointer dereference for (i=0; i_parameters.nH_t*sizeof(double))', assigned value is 0 PTT1 = (double *) malloc((nH_t)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23385:52: note: Null pointer dereference for (i=1; i_parameters.nH_t*sizeof(double))', assigned value is 0 ETT1 = (double *) malloc((nH_t)*sizeof(double)); ^ ILL_H16_IN5_Mantid.c:23385:62: note: Null pointer dereference for (i=1; i