Actual source code: pcregis.c

      1: #define PETSCKSP_DLL

     3:  #include src/ksp/pc/pcimpl.h

      6: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_Jacobi(PC);
      7: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_BJacobi(PC);
      8: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_PBJacobi(PC);
      9: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_ILU(PC);
     10: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_None(PC);
     11: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_LU(PC);
     12: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_SOR(PC);
     13: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_Shell(PC);
     14: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_MG(PC);
     15: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_Eisenstat(PC);
     16: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_ICC(PC);
     17: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_ASM(PC);
     18: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_KSP(PC);
     19: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_Composite(PC);
     20: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_Redundant(PC);
     21: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_NN(PC);
     22: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_Cholesky(PC);
     23: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_FieldSplit(PC);
     24: #if defined(PETSC_HAVE_ML)
     25: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_ML(PC);
     26: #endif
     27: #if defined(PETSC_HAVE_SPAI)
     28: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_SPAI(PC);
     29: #endif
     30: #if defined(PETSC_HAVE_SAMG)
     31: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_SAMG(PC);
     32: #endif
     33: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_Mat(PC);
     34: #if defined(PETSC_HAVE_HYPRE)
     35: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_HYPRE(PC);
     36: #endif
     37: #if !defined(PETSC_USE_64BIT_INT) && !defined(PETSC_USE_COMPLEX) && !defined(PETSC_USE_SINGLE) && !defined(PETSC_USE_MAT_SINGLE)
     38: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_TFS(PC);
     39: #endif
     40: #if defined(PETSC_HAVE_PROMETHEUS)
     41: EXTERN PetscErrorCode PETSCKSP_DLLEXPORT PCCreate_Prometheus(PC);
     42: #endif

     49: /*@C
     50:    PCRegisterAll - Registers all of the preconditioners in the PC package.

     52:    Not Collective

     54:    Input Parameter:
     55: .  path - the library where the routines are to be found (optional)

     57:    Level: advanced

     59: .keywords: PC, register, all

     61: .seealso: PCRegisterDynamic(), PCRegisterDestroy()
     62: @*/
     63: PetscErrorCode PETSCKSP_DLLEXPORT PCRegisterAll(const char path[])
     64: {

     68:   PCRegisterAllCalled = PETSC_TRUE;

     70:   PCRegisterDynamic(PCNONE         ,path,"PCCreate_None",PCCreate_None);
     71:   PCRegisterDynamic(PCJACOBI       ,path,"PCCreate_Jacobi",PCCreate_Jacobi);
     72:   PCRegisterDynamic(PCPBJACOBI     ,path,"PCCreate_PBJacobi",PCCreate_PBJacobi);
     73:   PCRegisterDynamic(PCBJACOBI      ,path,"PCCreate_BJacobi",PCCreate_BJacobi);
     74:   PCRegisterDynamic(PCSOR          ,path,"PCCreate_SOR",PCCreate_SOR);
     75:   PCRegisterDynamic(PCLU           ,path,"PCCreate_LU",PCCreate_LU);
     76:   PCRegisterDynamic(PCSHELL        ,path,"PCCreate_Shell",PCCreate_Shell);
     77:   PCRegisterDynamic(PCMG           ,path,"PCCreate_MG",PCCreate_MG);
     78:   PCRegisterDynamic(PCEISENSTAT    ,path,"PCCreate_Eisenstat",PCCreate_Eisenstat);
     79:   PCRegisterDynamic(PCILU          ,path,"PCCreate_ILU",PCCreate_ILU);
     80:   PCRegisterDynamic(PCICC          ,path,"PCCreate_ICC",PCCreate_ICC);
     81:   PCRegisterDynamic(PCCHOLESKY     ,path,"PCCreate_Cholesky",PCCreate_Cholesky);
     82:   PCRegisterDynamic(PCASM          ,path,"PCCreate_ASM",PCCreate_ASM);
     83:   PCRegisterDynamic(PCKSP          ,path,"PCCreate_KSP",PCCreate_KSP);
     84:   PCRegisterDynamic(PCCOMPOSITE    ,path,"PCCreate_Composite",PCCreate_Composite);
     85:   PCRegisterDynamic(PCREDUNDANT    ,path,"PCCreate_Redundant",PCCreate_Redundant);
     86:   PCRegisterDynamic(PCNN           ,path,"PCCreate_NN",PCCreate_NN);
     87:   PCRegisterDynamic(PCMAT          ,path,"PCCreate_Mat",PCCreate_Mat);
     88:   PCRegisterDynamic(PCFIELDSPLIT   ,path,"PCCreate_FieldSplit",PCCreate_FieldSplit);
     89: #if defined(PETSC_HAVE_ML)
     90:   PCRegisterDynamic(PCML           ,path,"PCCreate_ML",PCCreate_ML);
     91: #endif
     92: #if defined(PETSC_HAVE_SPAI)
     93:   PCRegisterDynamic(PCSPAI         ,path,"PCCreate_SPAI",PCCreate_SPAI);
     94: #endif
     95: #if defined(PETSC_HAVE_SAMG)
     96:   PCRegisterDynamic(PCSAMG         ,path,"PCCreate_SAMG",PCCreate_SAMG);
     97: #endif
     98: #if defined(PETSC_HAVE_HYPRE)
     99:   PCRegisterDynamic(PCHYPRE        ,path,"PCCreate_HYPRE",PCCreate_HYPRE);
    100: #endif
    101: #if !defined(PETSC_USE_64BIT_INT) && !defined(PETSC_USE_COMPLEX) && !defined(PETSC_USE_SINGLE) && !defined(PETSC_USE_MAT_SINGLE)
    102:   PCRegisterDynamic(PCTFS         ,path,"PCCreate_TFS",PCCreate_TFS);
    103: #endif
    104: #if defined(PETSC_HAVE_PROMETHEUS)
    105:   PCRegisterDynamic(PCPROMETHEUS  ,path,"PCCreate_Prometheus",PCCreate_Prometheus);
    106: #endif

    108:   return(0);
    109: }