dbcsr_rget_any Subroutine

public subroutine dbcsr_rget_any(base, source, win, win_data, myproc, disp, request, origin_datatype, target_datatype)

Single-sided Get function of encapsulated data.

Arguments

TypeIntentOptionalAttributesName
type(dbcsr_data_obj), intent(in) :: base
integer, intent(in) :: source
integer, intent(in) :: win
type(dbcsr_data_obj), intent(in) :: win_data
integer, intent(in), optional :: myproc
integer, intent(in), optional :: disp
integer, intent(out) :: request
type(mp_type_descriptor_type), intent(in), optional :: origin_datatype
type(mp_type_descriptor_type), intent(in), optional :: target_datatype

Contents

Source Code


Source Code

   SUBROUTINE dbcsr_rget_any(base, source, win, win_data, myproc, disp, request, &
      !! Single-sided Get function of encapsulated data.
                             origin_datatype, target_datatype)
      TYPE(dbcsr_data_obj), INTENT(IN)                   :: base
      INTEGER, INTENT(IN)                                :: source, win
      TYPE(dbcsr_data_obj), INTENT(IN)                   :: win_data
      INTEGER, INTENT(IN), OPTIONAL                      :: myproc, disp
      INTEGER, INTENT(OUT)                               :: request
      TYPE(mp_type_descriptor_type), INTENT(IN), &
         OPTIONAL                                        :: origin_datatype, target_datatype

      IF (dbcsr_data_get_type(base) /= dbcsr_data_get_type(win_data)) &
         DBCSR_ABORT("Mismatch data type between buffer and window")

      SELECT CASE (dbcsr_data_get_type(base))
      CASE (dbcsr_type_real_4)
         CALL mp_rget(base%d%r_sp, source, win, win_data%d%r_sp, myproc, &
                      disp, request, origin_datatype, target_datatype)
      CASE (dbcsr_type_real_8)
         CALL mp_rget(base%d%r_dp, source, win, win_data%d%r_dp, myproc, &
                      disp, request, origin_datatype, target_datatype)
      CASE (dbcsr_type_complex_4)
         CALL mp_rget(base%d%c_sp, source, win, win_data%d%c_sp, myproc, &
                      disp, request, origin_datatype, target_datatype)
      CASE (dbcsr_type_complex_8)
         CALL mp_rget(base%d%c_dp, source, win, win_data%d%c_dp, myproc, &
                      disp, request, origin_datatype, target_datatype)
      CASE default
         DBCSR_ABORT("Incorrect data type")
      END SELECT
   END SUBROUTINE dbcsr_rget_any