[petsc-users] seg fault with VecGetArray

Mohammad Mirzadeh mirzadeh at gmail.com
Sat May 12 03:33:11 CDT 2012


Hi guys,

I'm having a really weird issue here! My code seg faults for certain
problem size and after using gdb I have been able to pinpoint the problem
to a VecGetArray call. Here's a series of things I have tried so far

1) -on_error_attach_debugger -----> unsuccessful; does not launch debugger
2) -start_in_debugger -------> unsuccessful; does not start debugger
3) attaching debugger myself -----> code runs in debugger and seg faults
when calling VecGetArray
4) using ierr=VecGetArray;CHKERRQ(ierr) ------> PETSc does not produce
error messages; the code simply seg faults and terminates
5) checking the values of ierr inside the debugger ---------> They are all
0 up untill the code terminates; I think this means petsc does not generate
error?
6) checking for memory leak with valgrind -----------> All I get are leaks
from OpenMPI and PetscInitialize and PetscFinalize; I think these are
just routine and safe?

What else can I try to find the problem? Any recommendation is really
appreciated!

Thanks,
Mohammad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20120512/f245629f/attachment.htm>


More information about the petsc-users mailing list