I am trying to debug a long running windows fortran model. The problem seems to present only after the model has been running for over 100 hours. The model is a single threaded fortran application with lots of places to go wrong...
The process stops and a windows error dialog appears stating:
Problem Event Name: APPCRASH
Fault Module Name: KERNELBASE.DLL
Exception Code: c0000005
This is a generic Access Violation code and I need more information. Even though I compiled with traceback on no additional information is available. The process is still running till i close the dialog. I have tried dumping the stack and looking at it with windbg, but it seems only to tell me that I have requested a core dump. See attached file. Is there any way to get more information about where this error is occuring?
I recently found a solution to a similar problem by replacing an inline call with an explicit memory allocation:
Call write_stuff(group, & arpart(:,pack(idx_part, mask_part)), & alpart(:,pack(idx_part, mask_part)) )
allocate(ar(npseudo,records),al(npseudo,records)) ar = arpart(:,pack(idx_part, mask_part)) al = alpart(:,pack(idx_part, mask_part)) Call write_stuff(group, ar, al) deallocate(ar,al)
In this case - it seems that the call to write_stuff was not working well with the temporary arrays in a strange way that depended on the size of the array. This kinds of black magic - works sometimes stuff is extremely painstaking to find - especially when the error takes 100 hours to present.
Is there some way to get more information when the dialog appears - a different core dump or some other analysis in windbg?