Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-07 Thread Patrick Sanan
ius Buerkle" , "Patrick Sanan" < >> patrick.sa...@gmail.com> >> >> Cc: "PETSc users list" , petsc-dev < >> petsc-dev@mcs.anl.gov> >> >> Betreff: Re: Aw: Re: [petsc-dev] [petsc-users] >> MatPreallocatorPreallocate segfault with

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-04 Thread Patrick Sanan
Thanks for the feedback. > > > >> Gesendet: Donnerstag, den 03.02.2022 um 03:09 Uhr > >> Von: "Jed Brown" > >> An: "Marius Buerkle" , "Patrick Sanan" < > patrick.sa...@gmail.com> > >> Cc: "PETSc users list"

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-03 Thread Jed Brown
n: "Marius Buerkle" , "Patrick Sanan" >> >> Cc: "PETSc users list" , petsc-dev >> >> Betreff: Re: Aw: Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate >> segfault with PETSC 3.16 >> >> Marius Buerkle writes: >&g

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-03 Thread Marius Buerkle
03:09 Uhr > Von: "Jed Brown" > An: "Marius Buerkle" , "Patrick Sanan" > > Cc: "PETSc users list" , petsc-dev > > Betreff: Re: Aw: Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate > segfault with PETSC 3.16 > > Mari

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-03 Thread Marius Buerkle
t; , petsc-dev > Betreff: Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault > with PETSC 3.16 > > That works, as in the attached example - Marius, would that work for your > case? > > Am Di., 1. Feb. 2022 um 16:33 Uhr schrieb Jed Brown : > > > Patrick Sanan writes:

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-02 Thread Jed Brown
Marius Buerkle writes: > Thanks for they reply. Yes the example works, this is how I was doing it > before. But the matrix is rather big and i need a matrix with the same > structure at various points in my code. So it was convenient to create the > matrix with preallocate, destroy it after us

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-02 Thread Patrick Sanan
There is also the hedge of adding a parameter and API function to control which of these two behaviors is used, and if trying to preallocate twice, throwing an error that instructs the user how to change the behavior, noting that it will increase peak memory usage. Am Di., 1. Feb. 2022 um 17:07 Uh

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-01 Thread Jed Brown
Stefano Zampini writes: > Il giorno mar 1 feb 2022 alle ore 18:34 Jed Brown ha > scritto: > >> Patrick Sanan writes: >> >> > Am Di., 1. Feb. 2022 um 16:20 Uhr schrieb Jed Brown : >> > >> >> Patrick Sanan writes: >> >> >> >> > Sorry about the delay on this. I can reproduce. >> >> > >> >> > This

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-01 Thread Stefano Zampini
Il giorno mar 1 feb 2022 alle ore 18:34 Jed Brown ha scritto: > Patrick Sanan writes: > > > Am Di., 1. Feb. 2022 um 16:20 Uhr schrieb Jed Brown : > > > >> Patrick Sanan writes: > >> > >> > Sorry about the delay on this. I can reproduce. > >> > > >> > This regression appears to be a result of th

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-01 Thread Patrick Sanan
That works, as in the attached example - Marius, would that work for your case? Am Di., 1. Feb. 2022 um 16:33 Uhr schrieb Jed Brown : > Patrick Sanan writes: > > > Am Di., 1. Feb. 2022 um 16:20 Uhr schrieb Jed Brown : > > > >> Patrick Sanan writes: > >> > >> > Sorry about the delay on this. I c

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-01 Thread Jed Brown
Patrick Sanan writes: > Am Di., 1. Feb. 2022 um 16:20 Uhr schrieb Jed Brown : > >> Patrick Sanan writes: >> >> > Sorry about the delay on this. I can reproduce. >> > >> > This regression appears to be a result of this optimization: >> > https://gitlab.com/petsc/petsc/-/merge_requests/4273 >> >>

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-01 Thread Patrick Sanan
Am Di., 1. Feb. 2022 um 16:20 Uhr schrieb Jed Brown : > Patrick Sanan writes: > > > Sorry about the delay on this. I can reproduce. > > > > This regression appears to be a result of this optimization: > > https://gitlab.com/petsc/petsc/-/merge_requests/4273 > > Thanks for tracking this down. Is t

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-01 Thread Jed Brown
Patrick Sanan writes: > Sorry about the delay on this. I can reproduce. > > This regression appears to be a result of this optimization: > https://gitlab.com/petsc/petsc/-/merge_requests/4273 Thanks for tracking this down. Is there a reason to prefer preallocating twice ierr = MatPreallocato

Re: [petsc-dev] [petsc-users] MatPreallocatorPreallocate segfault with PETSC 3.16

2022-02-01 Thread Patrick Sanan
Sorry about the delay on this. I can reproduce. This regression appears to be a result of this optimization: https://gitlab.com/petsc/petsc/-/merge_requests/4273 The changes there including having MatPreallocator destroy its internal hash structure within MatPreallocatorPreallocate(), which allow