Actual source code: petscvecmod.F90

      1: module petscisdef
      2:   use, intrinsic :: ISO_C_binding
      3:   use petscsysdef
      4: #include <petsc/finclude/petscis.h>
      5: #include <../ftn/vec/petscis.h>
      6: #include <petsc/finclude/petscsf.h>
      7: #include <../ftn/vec/petscsf.h>
      8: #include <petsc/finclude/petscsection.h>
      9: #include <../ftn/vec/petscsection.h>

     11: end module

     13: !     Needed by Fortran stub petscsfgetgraph_()
     14: subroutine F90Array1dCreateSFNode(array, start, len, ptr)
     15:   use petscisdef
     16:   implicit none
     17:   PetscInt start, len
     18:   PetscSFNode, target :: array(start:start + len - 1)
     19:   PetscSFNode, pointer :: ptr(:)
     20:   ptr => array
     21: end subroutine
     22: #if defined(_WIN32) && defined(PETSC_USE_SHARED_LIBRARIES)
     23: !DEC$ ATTRIBUTES DLLEXPORT:: F90Array1dCreateSFNode
     24: #endif

     26: subroutine F90Array1dDestroySFNode(ptr)
     27:   use petscisdef
     28:   implicit none
     29:   PetscSFNode, pointer :: ptr(:)
     30:   nullify (ptr)
     31: end subroutine
     32: #if defined(_WIN32) && defined(PETSC_USE_SHARED_LIBRARIES)
     33: !DEC$ ATTRIBUTES DLLEXPORT:: F90Array1dDestroySFNode
     34: #endif

     36: !     ----------------------------------------------

     38: module petscis
     39:   use petscisdef
     40:   use petscsys

     42:   interface PetscSFDestroyRemoteOffsets
     43:     subroutine PetscSFDestroyRemoteOffsets(ptr, ierr)
     44:       use petscisdef
     45:       implicit none
     46:       PetscInt, pointer :: ptr(:)
     47:       PetscErrorCode :: ierr
     48:     end subroutine PetscSFDestroyRemoteOffsets
     49:   end interface

     51: #include <../src/vec/ftn-mod/petscis.h90>
     52: #include <../ftn/vec/petscsf.h90>
     53: #include <../ftn/vec/petscsection.h90>
     54: #include <../ftn/vec/petscis.h90>

     56: contains

     58: #include <../ftn/vec/petscsf.hf90>
     59: #include <../ftn/vec/petscsection.hf90>
     60: #include <../ftn/vec/petscis.hf90>

     62: end module

     64: !     ----------------------------------------------

     66: module petscvecdef
     67:   use petscisdef
     68: #include <petsc/finclude/petscvec.h>
     69: #include <../ftn/vec/petscvec.h>
     70: end module

     72: !     ----------------------------------------------

     74: module petscvec
     75:   use petscis
     76:   use petscvecdef

     78: #include <../src/vec/ftn-mod/petscvec.h90>
     79: #include <../ftn/vec/petscvec.h90>

     81: contains

     83: #include <../ftn/vec/petscvec.hf90>

     85: end module

     87: !     ----------------------------------------------

     89: module petscaodef
     90:   use petscsys
     91:   use petscvecdef
     92: #include <petsc/finclude/petscao.h>
     93: #include <../ftn/vec/petscao.h>
     94: end module

     96: !     ----------------------------------------------

     98: module petscao
     99:   use petscsys
    100:   use petscaodef
    101: #include <../ftn/vec/petscao.h90>
    102: contains
    103: #include <../ftn/vec/petscao.hf90>
    104: end module

    106: !     ----------------------------------------------

    108: module petscpfdef
    109:   use petscsys
    110:   use petscvecdef
    111: #include <petsc/finclude/petscpf.h>
    112: #include <../ftn/vec/petscpf.h>
    113: end module

    115: !     ----------------------------------------------

    117: module petscpf
    118:   use petscsys
    119:   use petscpfdef
    120: #include <../ftn/vec/petscpf.h90>
    121: contains
    122: #include <../ftn/vec/petscpf.hf90>
    123: end module