[petsc-users] memory crash with optimized petsc

Jed Brown jedbrown at mcs.anl.gov
Mon Jun 3 08:56:27 CDT 2013


Fande Kong <fande.kong at colorado.edu> writes:

> Thanks Jed,
>
> I run code with options: -malloc_debug and  -malloc_dump and get the
> following results:
>
> [0]Total space allocated 217984 bytes
> [ 0]16 bytes PetscStrallocpy() line 186 in
> /home/fdkong/math/petsc-3.3-p7/src/sys/utils/str.c
>       [0]  PetscObjectChangeTypeName() line 129 in
> /home/fdkong/math/petsc-3.3-p7/src/sys/objects/pname.c
>       [0]  ISSetType() line 77 in
> /home/fdkong/math/petsc-3.3-p7/src/vec/is/interface/isreg.c
>       [0]  ISCreateGeneral() line 437 in
> /home/fdkong/math/petsc-3.3-p7/src/vec/is/impls/general/general.c
>       [0]  SpmcsDMMeshGetStratumIS() line 1375 in spmcsdmmesh.cpp
>       [0]  ComputeMatrix() line 279 in linearElasticity3d.cpp
>       [0]  KSPSetUp() line 182 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/ksp/interface/itfunc.c
>       [0]  PCSetUp() line 810 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/pc/interface/precon.c
>       [0]  KSPSetUp() line 182 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/ksp/interface/itfunc.c
>       [0]  KSPSetFromOptions() line 284 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/ksp/interface/itcl.c
> [ 0]32 bytes ISCreate_General() line 516 in
> /home/fdkong/math/petsc-3.3-p7/src/vec/is/impls/general/general.c
>       [0]  ISSetType() line 77 in
> /home/fdkong/math/petsc-3.3-p7/src/vec/is/interface/isreg.c
>       [0]  ISCreateGeneral() line 437 in
> /home/fdkong/math/petsc-3.3-p7/src/vec/is/impls/general/general.c
>       [0]  SpmcsDMMeshGetStratumIS() line 1375 in spmcsdmmesh.cpp
>       [0]  ComputeMatrix() line 279 in linearElasticity3d.cpp
>       [0]  KSPSetUp() line 182 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/ksp/interface/itfunc.c
>       [0]  PCSetUp() line 810 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/pc/interface/precon.c
>       [0]  KSPSetUp() line 182 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/ksp/interface/itfunc.c
>       [0]  KSPSetFromOptions() line 284 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/ksp/interface/itcl.c
> [ 0]128 bytes ISCreate() line 43 in
> /home/fdkong/math/petsc-3.3-p7/src/vec/is/interface/isreg.c
>       [0]  ISCreateGeneral() line 437 in
> /home/fdkong/math/petsc-3.3-p7/src/vec/is/impls/general/general.c
>       [0]  SpmcsDMMeshGetStratumIS() line 1375 in spmcsdmmesh.cpp
>       [0]  ComputeMatrix() line 279 in linearElasticity3d.cpp
>       [0]  KSPSetUp() line 182 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/ksp/interface/itfunc.c
>       [0]  PCSetUp() line 810 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/pc/interface/precon.c
>       [0]  KSPSetUp() line 182 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/ksp/interface/itfunc.c
>       [0]  KSPSetFromOptions() line 284 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/ksp/interface/itcl.c
> [ 0]64 bytes ISCreate() line 43 in
> /home/fdkong/math/petsc-3.3-p7/src/vec/is/interface/isreg.c
>       [0]  ISCreateGeneral() line 437 in
> /home/fdkong/math/petsc-3.3-p7/src/vec/is/impls/general/general.c
>       [0]  SpmcsDMMeshGetStratumIS() line 1375 in spmcsdmmesh.cpp
>       [0]  ComputeMatrix() line 279 in linearElasticity3d.cpp
>       [0]  KSPSetUp() line 182 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/ksp/interface/itfunc.c
>       [0]  PCSetUp() line 810 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/pc/interface/precon.c
>       [0]  KSPSetUp() line 182 in
> /home/fdkong/math/petsc-3.3-p7/src/ksp/ksp/interface/itfunc.c
>
> Whether it means that I malloced some objects and then I did not free them?
> Or something else? Or it is normal?

Is this the complete output or was there more?  This indicates that an
index set (IS) was not freed.  Note that index sets are
reference-counted and normally referenced from a few places.


More information about the petsc-users mailing list