[petsc-users] an error message related to nest matrix

Mike Wick michael.wick.1980 at gmail.com
Tue Aug 14 12:19:22 CDT 2018


Hi:

I have a simple code myself to learn the basic usage of nest matrix. It
assembles a 3x3 nest matrix and solve with that nest matrix. I can run it
without a preconditioner. Running the code with -pc_type fieldsplit just
leads to an error message. I have no clue of what goes wrong. The message
is in below. I also have my code attached.

Thanks,

M

[0]PETSC ERROR: PetscTrFreeDefault() called from VecRestoreArray_Nest()
line 678 in /home/lib/petsc-3.9.1-src/src/vec/vec/impls/nest/vecnest.c
[0]PETSC ERROR: Block at address 0x2784ec8 is corrupted; cannot free;
may be block not allocated with PetscMalloc()
[0]PETSC ERROR: --------------------- Error Message
--------------------------------------------------------------
[0]PETSC ERROR: Memory corruption:
http://www.mcs.anl.gov/petsc/documentation/installation.html#valgrind
[0]PETSC ERROR: Bad location or corrupted memory
[0]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for
trouble shooting.
[0]PETSC ERROR: Petsc Release Version 3.9.1, Apr, 29, 2018
[0]PETSC ERROR: ./matnest on a  named bacon by mike Tue Aug 14 10:03:56 2018
[0]PETSC ERROR: Configure options --with-x=0 -with-pic --with-make-np=12
--with-mpi-compilers=1 --with-mpi-dir=/home/lib/mpich-3.2/
--with-scalar-type=real --with-shared-libraries=1 --with-precision=double
--with-chaco=1 --download-chaco --with-hypre=1 --download-hypre
--with-plapack=1 --download-plapack --with-spai=1 --download-spai
--with-sundials=1 --download-sundials --with-mumps=1 --download-mumps
--with-scalapack=1 --download-scalapack --with-blacs=1 --download-blacs
--with-spooles=1 --download-spooles --with-suitesparse=1
--download-suitesparse --with-superlu_dist=1 --download-superlu_dist
--with-superlu=1 --download-superlu --with-zoltan=1 --download-zoltan=1
--with-debugging=yes --download-fblaslapack --with-ml=1 --download-ml
--with-eigen=1 --download-eigen --prefix=~/lib/petsc-3.9.1-debug
[0]PETSC ERROR: #1 PetscTrFreeDefault() line 269 in
/home/lib/petsc-3.9.1-src/src/sys/memory/mtr.c
[0]PETSC ERROR: #2 VecRestoreArray_Nest() line 678 in
/home/lib/petsc-3.9.1-src/src/vec/vec/impls/nest/vecnest.c
[0]PETSC ERROR: #3 VecRestoreArrayRead() line 1835 in
/home/lib/petsc-3.9.1-src/src/vec/vec/interface/rvector.c
[0]PETSC ERROR: #4 VecRestoreArrayPair() line 511 in
/home/lib/petsc-3.9.1-src/include/petscvec.h
[0]PETSC ERROR: #5 VecScatterBegin_SSToSS() line 671 in
/home/lib/petsc-3.9.1-src/src/vec/vscat/impls/vscat.c
[0]PETSC ERROR: #6 VecScatterBegin() line 1779 in
/home/lib/petsc-3.9.1-src/src/vec/vscat/impls/vscat.c
[0]PETSC ERROR: #7 PCApply_FieldSplit() line 1040 in
/home/lib/petsc-3.9.1-src/src/ksp/pc/impls/fieldsplit/fieldsplit.c
[0]PETSC ERROR: #8 PCApply() line 457 in
/home/lib/petsc-3.9.1-src/src/ksp/pc/interface/precon.c
[0]PETSC ERROR: #9 KSP_PCApply() line 276 in
/home/lib/petsc-3.9.1-src/include/petsc/private/kspimpl.h
[0]PETSC ERROR: #10 KSPInitialResidual() line 67 in
/home/lib/petsc-3.9.1-src/src/ksp/ksp/interface/itres.c
[0]PETSC ERROR: #11 KSPSolve_GMRES() line 233 in
/home/lib/petsc-3.9.1-src/src/ksp/ksp/impls/gmres/gmres.c
[0]PETSC ERROR: #12 KSPSolve() line 669 in
/home/lib/petsc-3.9.1-src/src/ksp/ksp/interface/itfunc.c
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20180814/8e390588/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test_nest_mat.cpp
Type: text/x-c++src
Size: 6143 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20180814/8e390588/attachment.bin>


More information about the petsc-users mailing list