xref: /petsc/doc/changes/dev.md (revision 76c6338944e4871467ad7a763eee41b62845c2b0)
1# Changes: Development
2
3% STYLE GUIDELINES:
4% * Capitalize sentences
5% * Use imperative, e.g., Add, Improve, Change, etc.
6% * Don't use a period (.) at the end of entries
7% * If multiple sentences are needed, use a period or semicolon to divide sentences, but not at the end of the final sentence
8
9```{rubric} General:
10```
11
12```{rubric} Configure/Build:
13```
14
15- Make `SYCL` a `devicePackage`, i.e., builds `--with-sycl` now have `PETSC_HAVE_DEVICE` defined
16- Add the option `--with-devicelanguage` to compile `PetscDevice` code using either a C or C++ compiler
17- Add `Caliper`, an instrumentation and performance profiling library that can be used to profile `Hypre`.
18
19```{rubric} Sys:
20```
21
22- Add `PetscCallHYPRE()` to check HYPRE error codes and print error messages on failure
23
24
25```{rubric} Event Logging:
26```
27
28- Add two approaches for GPU energy monitoring:  `-log_view_gpu_energy` and `-log_view_gpu_energy_meter`
29- Add API `PetscLogGpuEnergy()`, `PetscLogGpuEnergyMeter()`, `PetscLogGpuEnergyMeterBegin()` and `PetscLogGpuEnergyMeterEnd()` for GPU energy monitoring
30
31```{rubric} PetscViewer:
32```
33
34-  Change the final argument of `PetscViewerGLVisSetFields()` to `PetscCtxDestroyFn *`. This means the destroy function must dereference the argument before operating on it
35
36```{rubric} PetscDraw:
37```
38
39```{rubric} AO:
40```
41
42```{rubric} IS:
43```
44
45```{rubric} VecScatter / PetscSF:
46```
47
48```{rubric} PF:
49```
50
51```{rubric} Vec:
52```
53
54```{rubric} PetscSection:
55```
56
57```{rubric} PetscPartitioner:
58```
59
60```{rubric} Mat:
61```
62
63- Change the `destroy()` function argument of `MatShellSetMatProductOperation()` to type `PetscCtxDestroyFn *`. This means the destroy function must dereference the argument before operating on it
64- Remove `MatMissingDiagonal()`. Developers should use `MatGetDiagonalMarkers_SeqXXX()` when the functionality is needed
65- Change `MatSetOption(A, MAT_HERMITIAN, PETSC_TRUE)` for `MatSBAIJ` to no longer automatically set the option `MAT_SYMMETRIC` to `PETSC_FALSE`. It is now the duty of the user to call `MatSetOption(A, MAT_SYMMETRIC, PETSC_FALSE)` if a `MatSBAIJ` is Hermitian but not symmetric
66
67```{rubric} MatCoarsen:
68```
69
70```{rubric} PC:
71```
72
73- Add multi-precision support for MUMPS. One could use `-pc_precision <single, double>` to set the precision to be used by MUMPS, which can be different from `PetscScalar`'s precision
74
75```{rubric} KSP:
76```
77
78- Remove `KSPHPDDMPrecision` in favor of `PetscPrecision`
79
80```{rubric} SNES:
81```
82
83- Change the `destroy()` function argument of `SNESSetConvergenceTest()` to type `PetscCtxDestroyFn *`. This means the destroy function must dereference the argument before operating on it
84- Add `SNESSetObjectiveDomainError()`
85- Change `SNES_DIVERGED_FNORM_NAN` to `SNES_DIVERGED_FUNCTION_NANORINF`
86- Add `SNES_DIVERGED_OBJECTIVE_NANORINF`
87- Add `SNES_DIVERGED_OBJECTIVE_DOMAIN`
88- Add developer functions `SNESCheckFunctionDomainError()`, `SNESLineSearchCheckFunctionDomainError()`, `SNESCheckObjectiveDomainError()`, `SNESLineSearchCheckObjectiveDomainError()`, `SNESCheckJacobianDomainError()`, and `SNESLineSearchCheckJacobianDomainError()`
89
90```{rubric} SNESLineSearch:
91```
92
93```{rubric} TS:
94```
95
96- Add `TSPseudoComputeFunction()` to get nonlinear residual while avoiding recalculation if possible
97- Remove unused `TSPseudoVerifyTimeStepDefault()`
98- Remove `TSPseudoComputeTimeStep()` and `TSPseudoVerifyTimeStep()`
99- Change the `destroy()` function argument of `TSTrajectorySetTransform()` to type `PetscCtxDestroyFn *`. This means the destroy function must dereference the argument before operating on it
100- Correct option `-ts_max_reject` to `-ts_max_step_rejections`
101- Correct option `-ts_dt` to `-ts_time_step`
102
103```{rubric} TAO:
104```
105
106```{rubric} PetscRegressor:
107```
108
109```{rubric} DM/DA:
110```
111
112-  Change the final argument of `DMShellSetDestroyContext()` to `PetscCtxDestroyFn *`. This means the destroy function must dereference the argument before operating on it
113
114```{rubric} DMSwarm:
115```
116
117```{rubric} DMPlex:
118```
119
120- Add `DMPlexVecGetClosureAtDepth()`
121- Add an extra communicator argument to `DMPlexFilter()` to allow extracting local meshes
122
123```{rubric} FE/FV:
124```
125
126```{rubric} DMNetwork:
127```
128
129```{rubric} DMStag:
130```
131
132```{rubric} DT:
133```
134
135```{rubric} Fortran:
136```
137