Re: [petsc-users] [EXTERNAL] Re: Using multiple MPI ranks with COO interface crashes in some cases

2022-11-21 Thread Junchao Zhang
On Mon, Nov 21, 2022 at 9:31 AM Fackler, Philip wrote: > Not sure why. I'm using the same compiler. But you can try constructing > the object explicitly on that line: > > idPairs.push_back(core::RowColPair{i, i}); > WIth your change, I continued but met another error:

Re: [petsc-users] Petsc Fortran Memory stack trace

2022-11-21 Thread Nicholas Arnold-Medabalimi
Thanks for the information, that clarifies quite a bit. Unfortunately I probably have a number of memory issues that are colliding that I need to clean up. Thanks On Mon, Nov 21, 2022 at 3:18 PM Barry Smith wrote: > > My understanding of Fortran bounds checking is that before each array >

Re: [petsc-users] Petsc Fortran Memory stack trace

2022-11-21 Thread Barry Smith
My understanding of Fortran bounds checking is that before each array access in Fortran it checks to see if the index is valid for the array you are accessing; that is it is from start to end if you had declared the array as double precision, dimension (start:end) :: A It should also

Re: [petsc-users] Petsc Fortran Memory stack trace

2022-11-21 Thread Matthew Knepley
On Mon, Nov 21, 2022 at 2:44 PM Nicholas Arnold-Medabalimi < narno...@umich.edu> wrote: > I have been using valgrind with the mem checker. I should have mentioned > that. My question was probably ill posed. I'm more asking about is how > linking petsc affects the stack trace provided by the

Re: [petsc-users] Petsc Fortran Memory stack trace

2022-11-21 Thread Nicholas Arnold-Medabalimi
I have been using valgrind with the mem checker. I should have mentioned that. My question was probably ill posed. I'm more asking about is how linking petsc affects the stack trace provided by the compiler side checks. Valgrind is great but sometimes is a little ambiguous whereas the compile side

Re: [petsc-users] Petsc Fortran Memory stack trace

2022-11-21 Thread Sanjay Govindjee
Other options I have found useful: -v --leak-check=full --show-reachable=yes On 11/21/22 11:27 AM, Satish Balay via petsc-users wrote: valgrind is a useful tool to learn to use.. valgrind --tool=memcheck ./executable Satish On Mon, 21 Nov 2022, Nicholas Arnold-Medabalimi wrote: Hi Petsc

Re: [petsc-users] Petsc Fortran Memory stack trace

2022-11-21 Thread Satish Balay via petsc-users
valgrind is a useful tool to learn to use.. valgrind --tool=memcheck ./executable Satish On Mon, 21 Nov 2022, Nicholas Arnold-Medabalimi wrote: > Hi Petsc users > > I'm working on an integration of Petsc into an existing fortran code. Most > of my memory debugging is very primitive and is

[petsc-users] Petsc Fortran Memory stack trace

2022-11-21 Thread Nicholas Arnold-Medabalimi
Hi Petsc users I'm working on an integration of Petsc into an existing fortran code. Most of my memory debugging is very primitive and is usually accomplished using the -check bounds option in the compiler. However with Petsc attached the stack trace becomes much more opaque compared to the

Re: [petsc-users] [EXTERNAL] Re: Using multiple MPI ranks with COO interface crashes in some cases

2022-11-21 Thread Fackler, Philip via petsc-users
Not sure why. I'm using the same compiler. But you can try constructing the object explicitly on that line: idPairs.push_back(core::RowColPair{i, i}); Philip Fackler Research Software Engineer, Application Engineering Group Advanced Computing Systems Research Section Computer Science and