petsc-main 2021-03-07
Report Typos and Errors

PetscSFSetFromOptions

set PetscSF options using the options database

Synopsis

#include "petscsf.h" 
PetscErrorCode PetscSFSetFromOptions(PetscSF sf)
Logically Collective

Input Arguments

sf - star forest

Options Database Keys

-sf_type - implementation type, see PetscSFSetType()
-sf_rank_order - sort composite points for gathers and scatters in rank order, gathers are non-deterministic otherwise
-sf_use_default_stream - Assume callers of SF computed the input root/leafdata with the default cuda stream. SF will also use the default stream to process data. Therefore, no stream synchronization is needed between SF and its caller (default: true). If true, this option only works with -use_gpu_aware_mpi 1.
-sf_use_stream_aware_mpi - Assume the underlying MPI is cuda-stream aware and SF won't sync streams for send/recv buffers passed to MPI (default: false). If true, this option only works with -use_gpu_aware_mpi 1.
-sf_backend cuda | hip | kokkos - Select the device backend SF uses. Currently SF has these backends: cuda, hip and Kokkos. On CUDA (HIP) devices, one can choose cuda (hip) or kokkos with the default being kokkos. On other devices, the only available is kokkos.

Level

intermediate

Location

src/vec/is/sf/interface/sf.c

Examples

src/vec/is/sf/tutorials/ex1.c.html
src/vec/is/sf/tutorials/ex2.c.html
src/vec/is/sf/tutorials/ex1f.F90.html

Implementations

PetscSFSetFromOptions_Window in src/vec/is/sf/impls/window/sfwindow.c

Index of all PetscSF routines
Table of Contents for all manual pages
Index of all manual pages