Commit 5ec270b
authored
Fix compilation for PETSc (AMReX-Codes#3005)
We cannot include PETSc headers too early because it might redefine MPI
routines as macros
(https://github.com/petsc/petsc/blob/main/include/petsclog.h#L441). They
break MPI calls like below,
MPI_Allreduce(&tmp, &vi, 1,
ParallelDescriptor::Mpi_typemap<T>::type(),
ParallelDescriptor::Mpi_op<T,amrex::Greater<T>>(), comm);
because of the `,` in `<T,amrex::Greater<T>>`.1 parent 735c351 commit 5ec270b
1 file changed
+3
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
3 | | - | |
4 | | - | |
5 | 2 | | |
6 | 3 | | |
7 | 4 | | |
8 | 5 | | |
9 | 6 | | |
10 | 7 | | |
11 | 8 | | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| |||
0 commit comments