Actual source code: vecregall.c

petsc-3.6.1 2015-07-22
Report Typos and Errors
  2: #include <petscvec.h>
  3: #include <petsc/private/vecimpl.h>
  4: PETSC_EXTERN PetscErrorCode VecCreate_Seq(Vec);
  5: PETSC_EXTERN PetscErrorCode VecCreate_MPI(Vec);
  6: PETSC_EXTERN PetscErrorCode VecCreate_Standard(Vec);
  7: PETSC_EXTERN PetscErrorCode VecCreate_Shared(Vec);
  8: #if defined(PETSC_HAVE_CUSP)
  9: PETSC_EXTERN PetscErrorCode VecCreate_SeqCUSP(Vec);
 10: PETSC_EXTERN PetscErrorCode VecCreate_MPICUSP(Vec);
 11: PETSC_EXTERN PetscErrorCode VecCreate_CUSP(Vec);
 12: #endif
 13: #if defined(PETSC_HAVE_VIENNACL)
 14: PETSC_EXTERN PetscErrorCode VecCreate_SeqViennaCL(Vec);
 15: PETSC_EXTERN PetscErrorCode VecCreate_MPIViennaCL(Vec);
 16: PETSC_EXTERN PetscErrorCode VecCreate_ViennaCL(Vec);
 17: #endif

 21: /*@C
 22:   VecRegisterAll - Registers all of the vector components in the Vec package.

 24:   Not Collective

 26:   Level: advanced

 28: .keywords: Vec, register, all
 29: .seealso:  VecRegister(), VecRegisterDestroy(), VecRegister()
 30: @*/
 31: PetscErrorCode  VecRegisterAll(void)
 32: {

 36:   if (VecRegisterAllCalled) return(0);
 37:   VecRegisterAllCalled = PETSC_TRUE;

 39:   VecRegister(VECSEQ,        VecCreate_Seq);
 40:   VecRegister(VECMPI,        VecCreate_MPI);
 41:   VecRegister(VECSTANDARD,   VecCreate_Standard);
 42:   VecRegister(VECSHARED,     VecCreate_Shared);
 43: #if defined PETSC_HAVE_CUSP
 44:   VecRegister(VECSEQCUSP,    VecCreate_SeqCUSP);
 45:   VecRegister(VECMPICUSP,    VecCreate_MPICUSP);
 46:   VecRegister(VECCUSP,       VecCreate_CUSP);
 47: #endif
 48: #if defined PETSC_HAVE_VIENNACL
 49:   VecRegister(VECSEQVIENNACL,    VecCreate_SeqViennaCL);
 50:   VecRegister(VECMPIVIENNACL,    VecCreate_MPIViennaCL);
 51:   VecRegister(VECVIENNACL,       VecCreate_ViennaCL);
 52: #endif
 53:   return(0);
 54: }