[petsc-users] KSP_Solve crashes in debug mode

Barry Smith bsmith at petsc.dev
Thu Feb 9 12:02:28 CST 2023


  Hmm, looks like your build may be funny? It is not in debug mode 

frame #2: 0x000000010eda20c8 libpetsc.3.018.dylib`PetscHeaderDestroy_Private + 1436
    frame #3: 0x000000010f10176c libpetsc.3.018.dylib`VecDestroy + 808
    frame #4: 0x0000000110199f34 libpetsc.3.018.dylib`KSPSolve_Private + 512

In debugger mode it would show the line numbers where the crash occurred and help us determine the problem. I do note the -g being used by the compilers so cannot explain off hand why it does not display the debug information.

  Barry


> On Feb 9, 2023, at 12:42 PM, Sajid Ali Syed via petsc-users <petsc-users at mcs.anl.gov> wrote:
> 
> Hi PETSc-developers, 
> 
> In our application we call KSP_Solve as part of a step to propagate a beam through a lattice. I am observing a crash within KSP_Solve for an application only after the 43rd call to KSP_Solve when building the application and PETSc in debug mode, full logs for which are attached with this email (1 MPI rank and 4 OMP threads were used, but this crash occurs with multiple MPI ranks as well ). I am also including the last few lines of the configuration for this build. This crash does not occur when building the application and PETSc in release mode. 
> 
> Could someone tell me what causes this crash and if anything can be done to prevent it? Thanks in advance.
> 
> The configuration of this solver is here : 
> https://github.com/fnalacceleratormodeling/synergia2/blob/sajid/features/openpmd_basic_integration/src/synergia/collective/space_charge_3d_fd_utils.cc#L273-L292
> 
> 
> Thank You,
> Sajid Ali (he/him) | Research Associate
> Scientific Computing Division
> Fermi National Accelerator Laboratory
> s-sajid-ali.github.io <http://s-sajid-ali.github.io/>
> <ksp_crash_log>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20230209/c441482d/attachment.html>


More information about the petsc-users mailing list