Merge remote-tracking branch 'origin/release'
Fix MPI_Comm_rank/size API mixups in helpers (#1865,#1866)
Housekeeping
- 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.
show more ...
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
distinguish Boolean and IntegerMPI_Comm_get_attr has PetscMPIInt as flag argument, not PetscBool. Namethis flag "iflg" (was used somewhere already).Use MPI_LAND instead of MPI_BAND for logical op
distinguish Boolean and IntegerMPI_Comm_get_attr has PetscMPIInt as flag argument, not PetscBool. Namethis flag "iflg" (was used somewhere already).Use MPI_LAND instead of MPI_BAND for logical operations instead ofMPI_MIN, MPI_MAX, and MPI_LAND.Note: Most of the previous code was probably working as intended, I didthe changes when debugging error related to the use of standard C Bool andkept them because it took me a while to understand that MPI has integerflags and PETSc has Booleans. Using different names makes this clear,but was and is not done consistently.
missing "s" for isascii and issundials
Make MatGetCurrentMemType first class API
MatOps cleanup
Fix Fortran interface of two functions
Minor cleanup of Fortran binding stuff to simplify future maintainanceThere is no distinction between F90 and non-F90 code so combine ftn-custom and f90-custom directories and fortranimpl.h and f90
Minor cleanup of Fortran binding stuff to simplify future maintainanceThere is no distinction between F90 and non-F90 code so combine ftn-custom and f90-custom directories and fortranimpl.h and f90impl.h files. Also move uses of f90 to ftn when simple
Fortran 90: fully embrace After 34 years!- deprecate use of 'F90' in Fortran function names- use Fortran pointers when appropriate- the new Fortran API is not backward compatible with previous ve
Fortran 90: fully embrace After 34 years!- deprecate use of 'F90' in Fortran function names- use Fortran pointers when appropriate- the new Fortran API is not backward compatible with previous versions!- also clean up inconsistent PETSc code detected by new Fortran generation tools- drop use of bfort- automatically generate all the Fortran PETSc objects, enums etc from the include files- generate most of the Fortran interface definitions and functions from the source code- simplify the number and organization of Fortran modulesCo-authored-by: Jose E. Roman <jroman@dsic.upv.es>
MatSetOption: ignore unused options instead of erroring out
Remove useless code
Add MatCopyHashToXAIJ() to copy hash table entries into an XAIJ matrix type
Merge branch 'jczhang/2024-09-05/feature-mat-get-vpb' into 'main'PC: add new mat ops MATOP_GET_{BLOCK, VBLOCK}_DIAGONALSee merge request petsc/petsc!7811
Fix MPIU_* routines to always return MPI error codes and thus be usable with PetscCallMPI()Introduce MPIU_Count to be used when MPI_Count is not available
PC: add new mat ops MATOP_GET_{BLOCK, VBLOCK}_DIAGONALso that a shell matrix can return its own (variable) point blocks in a matrix for use in PC (V)PBJacobi
Mat: fix -Wmissing-field-initializers
This requires some changes to user FORTRAN codePass PETSC_NULL_XXX_ARRAY when passing a NULL as an argument that is expecting an arrayPass PETSC_NULL_ENUM when argument returns an enum instead of
This requires some changes to user FORTRAN codePass PETSC_NULL_XXX_ARRAY when passing a NULL as an argument that is expecting an arrayPass PETSC_NULL_ENUM when argument returns an enum instead of PETSC_NULL_INTEGERPass arrays (and not scalar values) when the argument is expecting an array; this means replace, for example, the argument v with [v]Use PetscObjectIsNull(obj) to check if the object is NULL, instead of obj == PETSC_NULL_XXXThe compiler will now automatically prevent you from using the wrong argument type for the first three bullets aboveThis will also require an update sowing with the new sowing branch this MR is using.
Update source code removing all unneeded /*@C and associated manual stubs and interfaces
Remove multiple parentheses and extra semicolongit grep -l -E "\(\([a-zA-Z0-9_]+\)\(\*[a-zA-Z0-9_]+\)[, )]" | xargs sed -r -i'' 's#\(\(([a-zA-Z0-9_]+)\)\(\*([a-zA-Z0-9_]+)\)([, )])#\(\(\1\)\*\2\3#g
Remove multiple parentheses and extra semicolongit grep -l -E "\(\([a-zA-Z0-9_]+\)\(\*[a-zA-Z0-9_]+\)[, )]" | xargs sed -r -i'' 's#\(\(([a-zA-Z0-9_]+)\)\(\*([a-zA-Z0-9_]+)\)([, )])#\(\(\1\)\*\2\3#g'git grep -l -E "Petsc(.)*\(\(\*[a-zA-Z0-9_]*\)," | xargs sed -r -i'' 's#Petsc([a-zA-Z0-9_]*)\(\(\*([a-zA-Z0-9_]*)\), #Petsc\1(*\2, #g'git grep -l -E "([\!\&\~\*\(]|\)\)|\([^,\*\(]+\**\))\(([a-zA-Z0-9_]+((\.|->)[a-zA-Z0-9_]+|\[[a-zA-Z0-9_ \%\+\*\-]+\])+)\)" | xargs sed -r -i'' 's#([\!\&\~\*\(]|\)\)|\([^,\*\(]+\**\))\(([a-zA-Z0-9_]+((\.|->)[a-zA-Z0-9_]+|\[[a-zA-Z0-9_ \%\+\*\-]+\])+)\)#\1\2#g'
Clarify which MatCreate and friends copies the user provided valuesReported-by: Fabian Wermelinger <fab4100@posteo.ch>
12345678910>>...15