Re: [petsc-users] [petsc-dev] 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-users] [petsc-dev] 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-users] [petsc-dev] 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

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

2022-02-02 Thread Marius Buerkle
and creating it again later with the same preallocate. Anyway it works with MatDuplicate for now. > Gesendet: Dienstag, den 01.02.2022 um 16:45 Uhr > Von: "Patrick Sanan" > An: "Jed Brown" > Cc: "Marius Buerkle" , "PETSc users list" &g

Re: [petsc-users] [petsc-dev] 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

Re: [petsc-users] [petsc-dev] 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. >> >> > >> >> >

Re: [petsc-users] [petsc-dev] 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

Re: [petsc-users] [petsc-dev] 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

Re: [petsc-users] [petsc-dev] 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-users] [petsc-dev] 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

Re: [petsc-users] [petsc-dev] 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 =