Merge branch 'jolivet/update-htool' into 'main'General housekeepingSee merge request petsc/petsc!9037
Cleanup ts/utils/dmplexlandau/tutorials/ex2.c
Fix the inconsistent usage of #if [!]defined XXX compared to defined(XXX)Thanks-to: Pierre JolivetAn LLM Claude detected the incosnsitency it was not used to remove the inconsistency
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 ...
added hook to turn off cubed sphere projection
DMPlexLandau: mesh bug fix
DMPlexLandau: 3d mesh optsAPI change in definition of radius in 3D; optimized cubed sphere projection of cube to sphere
opt 3d grids
added a new cubed sphere and optized 3d mesh params
fixing prefixes to get passed down in Landau
Fortran 2008 has unlimited polymorphic/'*'
Fix bad decisions made in writing TS. Fix -ts_dt to -ts_time_step and add initial time step to TSView outputcommit a5a92c11fa9681148df375b257eda4e09909b74eAuthor: Barry Smith <bsmith@petsc.de
Fix bad decisions made in writing TS. Fix -ts_dt to -ts_time_step and add initial time step to TSView outputcommit a5a92c11fa9681148df375b257eda4e09909b74eAuthor: Barry Smith <bsmith@petsc.dev>Date: Mon Dec 1 14:51:27 2025 -0500 add max_snes_failures to TSViewcommit 32d3e79f6fa743930b1bbf32d03b9181b5b5418aAuthor: Barry Smith <bsmith@petsc.dev>Fix wrongly named options and add to TSViewWrong name for options database key -ts_max_reject should be -ts_max_step_rejections!Add max_reject value to TSViewAdd max_snes_failures to TSViewAdd initial timestep to TSView
Fix -Wunused-but-set-variablesrc/dm/dt/fe/interface/fe.c:2420:41: warning: variable ‘g’ set but not used [-Wunused-but-set-variable=] 2420 | PetscInt dOffset = 0, fOffset = 0, f, g; |
Fix -Wunused-but-set-variablesrc/dm/dt/fe/interface/fe.c:2420:41: warning: variable ‘g’ set but not used [-Wunused-but-set-variable=] 2420 | PetscInt dOffset = 0, fOffset = 0, f, g; | ^src/dm/field/impls/da/dmfieldda.c:31:17: warning: variable ‘c’ set but not used [-Wunused-but-set-variable=] 31 | PetscInt i, c, dim; | ^src/dm/impls/plex/plex.c:8007:28: warning: variable ‘newP’ set but not used [-Wunused-but-set-variable=] 8007 | for (PetscInt p = 0, newP = 0, o = fStart, oNew = fNewStart; p < numPoints; p++) { | ^~~~src/ts/utils/dmplexlandau/plexland.c:351:39: warning: variable ‘loc_fdf_idx’ set but not used [-Wunused-but-set-variable=] 351 | for (PetscInt ei_r = 0, loc_fdf_idx = 0; ei_r < numCells[grid_r]; ++ei_r) { | ^~~~~~~~~~~
Fortran is always F2003: removed leftovers
place all the include statements at the topRepeated inclusion in multiple location, e.g. at the start of amodule or function is not needed. This becomes clear if all includes areoutside of the ac
place all the include statements at the topRepeated inclusion in multiple location, e.g. at the start of amodule or function is not needed. This becomes clear if all includes areoutside of the actual Fortran code.Added regex to check that with the help of @sbalay
checkbadSource: enforce proper style in makefiles
Fix the definition of PetscErrorCodeFn; this reverts API change in !8615Co-authored-by: Pierre Jolivet <pierre@joliv.et>Reported-by: Lisandro Dalcin <dalcinl@gmail.com>
Run fprettify
Merge remote-tracking branch 'origin/release'
Fix logic in DMTSCheckJacobian() for returning values versus printing results.
clang-format: update to v21 (and update CI)
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
fortran no semicolon at end of lineRemove all unneeded ; at end of Fortran source code lineAdd checkbadSource to check for semicolon at the end of lines
12345678910>>...22