Change *.cpp to *.cxx
PCFIELDSPLIT: add PCMatApply() implementation
Add automatic generated fortran support for setting and returning contextsMajor cleanup of the code for setting and returning application (previously called user) contexts - PetscCtx ctx is now t
Add automatic generated fortran support for setting and returning contextsMajor cleanup of the code for setting and returning application (previously called user) contexts - PetscCtx ctx is now the standard for passing in contexts - PetscCtxRt ctx is the standard for passing out contexts, including context destroy routines based on PetscCtxDestroyFnBoth of these are typedef to void*Also removed most use of user and userctx for context arguments now consistently named ctxImproved documentation on PetscCtx and PetscCtxRt and on how to use contexts (including getting them) from Fortran
show more ...
Minor cleanup: use MPI_IN_PLACE when possible and avoid extra allocation
Merge branch 'barry/2025-10-18/optimize-aij-ops' into 'main'Refactor handling of diagonal marking in *AIJ and SELL matricesSee merge request petsc/petsc!8797
- Replace MatMissingDiagonal() and MatMarkDiagonals_SeqXXX() with MatGetDiagonalMarkers_SeqXXX() - Mat_SeqXXX->diag is not automatically created during MatAssemblyEnd() saving memory and time
- Replace MatMissingDiagonal() and MatMarkDiagonals_SeqXXX() with MatGetDiagonalMarkers_SeqXXX() - Mat_SeqXXX->diag is not automatically created during MatAssemblyEnd() saving memory and time - Accessing Mat_SeqXXX->diag now requires the use of MatGetDiagonalMarkers_SeqXXX() except when the current values are known to be correct; for example during numerical factorizations and solves - Mat_SeqXXX->diag is now never shared among matrices; hence the free_diag flag is gone. That was always a risky proposition since any of the owning matrices could chang the values thus making them incorrect for other owners.
MatDense: safeguards to avoid faulty inputs
Change names of Mat_XXX product contexts to MatProductCtx_XXX for code maintainabilityUpdate destroy callback of all MatProductCtx and MatShellSetMatProductOperation() to use PetscCtxDestroyFn
Enable ScaLAPACK and MUMPS for other precisions
Merge branch 'barry/2025-09-04/deprecate-mpiu-bool' into 'main'Deprecate MPIU_BOOL which used to be for PETSc's enum Bool but now is just MPI_C_BOOLSee merge request petsc/petsc!8691
Deprecate MPIU_BOOL which used to be for PETSc' enum Bool but now is just MPI_C_BOOL so no longer needs its own name
Mat: add ops for zerorowscolumnslocal
Remove unnecessary braces around one-linersgit grep -lE "[ ]*(if|for|while) \(.*\) {[^;]*;[^;]*}$" -- '*.c' '*.cxx' '*.cu' '*.h' '*.hpp' '*.cpp' | xargs sed -i '' -E 's#([ ]*)(if|for|while) \((.*)\
Remove unnecessary braces around one-linersgit grep -lE "[ ]*(if|for|while) \(.*\) {[^;]*;[^;]*}$" -- '*.c' '*.cxx' '*.cu' '*.h' '*.hpp' '*.cpp' | xargs sed -i '' -E 's#([ ]*)(if|for|while) \((.*)\) {([^;]*);([^;]*)}$#\1\2 \(\3\)\4;\5#'
Convert some SETERRQ() to PetscCheck()
One-liners from petsc/petsc!5344 and petsc/petsc!5557Slightly reworked regular expressiongit ls-files -z -- '*.c' '*.cxx' '*.cu' '*.h' '*.hpp' '*.cpp' | while IFS= read -r -d '' file; do cat
One-liners from petsc/petsc!5344 and petsc/petsc!5557Slightly reworked regular expressiongit ls-files -z -- '*.c' '*.cxx' '*.cu' '*.h' '*.hpp' '*.cpp' | while IFS= read -r -d '' file; do cat $file | tr '\n' '\r' | sed -E 's/\r([ ]*)(for|if|while|else) ([^\r]*)\{\r[ ]*Petsc([a-zA-Z]*)\(([^\r]*)\);\r[ ]*\}\r/\r\1\2 \3Petsc\4(\5);\r/g' | tr '\r' '\n' > ${file}.joe; mv ${file}.joe ${file}done
missing "s" for isascii and issundials
Make MatGetCurrentMemType first class API
Merge remote-tracking branch 'origin/release'
Docs: fix wrong parameter for Fortran usersex76f.F90:87:101: 87 | PetscCallA(MatCreateDense(PETSC_COMM_WORLD,m,PETSC_DECIDE,PETSC_DECIDE,N,PETSC_NULL_SCALAR,C,ierr)) |
Docs: fix wrong parameter for Fortran usersex76f.F90:87:101: 87 | PetscCallA(MatCreateDense(PETSC_COMM_WORLD,m,PETSC_DECIDE,PETSC_DECIDE,N,PETSC_NULL_SCALAR,C,ierr)) | 1Error: There is no specific subroutine for the generic 'matcreatedense' at (1)
MatOps cleanup
MatMPIDense: Fix implicit PetscInt -> PetscMPIInt conversion in recent changes
Mat: Fix and improve the performance of dense matrix multiplicationMat: Add MATDENSEFROMVECTYPE constructor typeNow in a tests set you can do``` testset: args: -mat_type densefromvectype
Mat: Fix and improve the performance of dense matrix multiplicationMat: Add MATDENSEFROMVECTYPE constructor typeNow in a tests set you can do``` testset: args: -mat_type densefromvectype test: test_cuda requires: cuda args: -vec_type veccuda test: test_hip requires: hip args: -vec_type vechip```(This assumes that you call `MatSetVecType()` before you call`MatSetFromOptions()`)Mat_MPIDense: Cache offsets of MatDenseGetSubMatrix() to avoid communication in more casesMat: Add missing implementations for internal "MatMultColumnRange()" interfaceMat_MPIDense: Fix the zeroing of buffers in multiplication routinesMat_MPIDense: Add optimization of MatMatMult routines when all columns are owned by rank 0The communication for intermediate buffers can be handled with allreduce / bcast operations,but we use the PetscSF matvec context instead of MPI routines directly so that we willuse gpu-aware MPI if possible.
Fix wrong case for PETSc
Doc: add notes to the const usage in VecPlaceArray, VecReplaceArray etc
12345678910>>...34