Actual source code: sfallgatherv.h

      1: #pragma once

      3: #include <petsc/private/sfimpl.h>
      4: #include <../src/vec/is/sf/impls/basic/sfpack.h>
      5: #include <../src/vec/is/sf/impls/basic/sfbasic.h>

      7: typedef struct {
      8:   SFBASICHEADER;
      9:   PetscMPIInt *displs, *recvcounts;
     10:   /* special treatment for one-to-all patterns detected at setup time */
     11:   PetscBool   bcast_pattern; /* bcast here means one-to-all; we might do MPI_Reduce with this pattern */
     12:   PetscMPIInt bcast_root;    /* the root rank in MPI_Bcast */
     13: } PetscSF_Allgatherv;

     15: PETSC_INTERN PetscErrorCode PetscSFSetUp_Allgather(PetscSF);
     16: PETSC_INTERN PetscErrorCode PetscSFSetUp_Allgatherv(PetscSF);
     17: PETSC_INTERN PetscErrorCode PetscSFReset_Allgatherv(PetscSF);
     18: PETSC_INTERN PetscErrorCode PetscSFDestroy_Allgatherv(PetscSF);
     19: PETSC_INTERN PetscErrorCode PetscSFFetchAndOpBegin_Allgatherv(PetscSF sf, MPI_Datatype, PetscMemType, void *, PetscMemType, const void *, void *, MPI_Op);
     20: PETSC_INTERN PetscErrorCode PetscSFFetchAndOpEnd_Allgatherv(PetscSF, MPI_Datatype, void *, const void *, void *, MPI_Op);
     21: PETSC_INTERN PetscErrorCode PetscSFGetRootRanks_Allgatherv(PetscSF, PetscMPIInt *, const PetscMPIInt **, const PetscInt **, const PetscInt **, const PetscInt **);
     22: PETSC_INTERN PetscErrorCode PetscSFGetLeafRanks_Allgatherv(PetscSF, PetscMPIInt *, const PetscMPIInt **, const PetscInt **, const PetscInt **);
     23: PETSC_INTERN PetscErrorCode PetscSFCreateLocalSF_Allgatherv(PetscSF, PetscSF *);
     24: PETSC_INTERN PetscErrorCode PetscSFGetGraph_Allgatherv(PetscSF, PetscInt *, PetscInt *, const PetscInt **, const PetscSFNode **);
     25: PETSC_INTERN PetscErrorCode PetscSFReduceEnd_Allgatherv(PetscSF, MPI_Datatype, const void *, void *, MPI_Op);