Usually due to uninitialized variables. You can try valgrind. Read tutorial from page 3 of https://www.mcs.anl.gov/petsc/petsc-20/tutorial/PETSc1.pdf --Junchao Zhang
On Fri, Oct 18, 2019 at 6:23 AM Shidi Yan via petsc-users <[email protected]<mailto:[email protected]>> wrote: Dear developers, I am using ParMETIS to do dynamic load balancing for the mesh. If my code is compiled with optimiser options (e.g., -O2 -O3), I have the following errors when the code calls function from ParMETIS: ***ASSERTION failed on line 176 of file externalpackages/git.parmetis/libparmetis/comm.c: j == nnbrs externalpackages/git.parmetis/libparmetis/comm.c:176: libparmetis__CommSetup: Assertion `j == nnbrs' failed. However, if the code is compiled with debugging mode ( -g), I do not have any errors. I am wondering is it the bug from my part. Thank you very much for your time. Kind Regards, Shidi
