omptgt_backend_t Derived Type

type, public, extends(base_backend_t) :: omptgt_backend_t


Inherits

type~~omptgt_backend_t~~InheritsGraph type~omptgt_backend_t omptgt_backend_t type~base_backend_t base_backend_t type~omptgt_backend_t->type~base_backend_t type~allocator_t allocator_t type~base_backend_t->type~allocator_t allocator type~mesh_t mesh_t type~base_backend_t->type~mesh_t mesh type~poisson_fft_t poisson_fft_t type~base_backend_t->type~poisson_fft_t poisson_fft type~field_t field_t type~allocator_t->type~field_t first type~geo_t geo_t type~mesh_t->type~geo_t geo type~grid_t grid_t type~mesh_t->type~grid_t grid type~par_t par_t type~mesh_t->type~par_t par type~poisson_fft_t->type~mesh_t mesh type~field_t->type~field_t next

Inherited by

type~~omptgt_backend_t~~InheritedByGraph type~omptgt_backend_t omptgt_backend_t type~backend_setup_t backend_setup_t type~backend_setup_t->type~omptgt_backend_t omptgt_backend

Components

Type Visibility Attributes Name Initial
integer, public :: n_halo = 4

DistD2 implementation is hardcoded for 4 halo layers for all backends

type(mesh_t), public, pointer :: mesh
class(allocator_t), public, pointer :: allocator
class(poisson_fft_t), public, pointer :: poisson_fft
real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: u_recv_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: u_recv_e_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: u_send_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: u_send_e_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: v_recv_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: v_recv_e_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: v_send_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: v_send_e_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: w_recv_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: w_recv_e_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: w_send_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: w_send_e_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: du_send_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: du_send_e_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: du_recv_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: du_recv_e_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: dud_send_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: dud_send_e_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: dud_recv_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: dud_recv_e_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: d2u_send_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: d2u_send_e_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: d2u_recv_s_dev => null()

Device halo buffers, as in cuda_backend_t

real(kind=dp), public, pointer, contiguous, dimension(:, :, :) :: d2u_recv_e_dev => null()

Device halo buffers, as in cuda_backend_t


Constructor

public interface omptgt_backend_t

  • private function omptgt_backend_init(mesh, allocator) result(backend)

    Constructs the backend over a device-resident allocator and allocates its halo buffers, sized for the largest exchange of any direction.

    Arguments

    Type IntentOptional Attributes Name
    type(mesh_t), intent(inout), target :: mesh
    class(allocator_t), intent(inout), target :: allocator

    Return Value type(omptgt_backend_t)


Type-Bound Procedures

procedure, public :: field_add_const_x_face => field_add_const_x_face_base

  • public subroutine field_add_const_x_face_base(self, f, c, at_end)

    Adds a uniform constant c to one x-normal face plane of a DIR_X field, in place. Used to enforce exact outlet mass conservation: after the convective outflow update, the outlet-plane mean is shifted uniformly so that it matches the prescribed inlet mean (mirrors Incompact3d's bxxn = bxxn - ut + ut1). at_end = .true. -> the x = nx plane (outlet) at_end = .false. -> the x = 1 plane (inlet)

    Arguments

    Type IntentOptional Attributes Name
    class(base_backend_t) :: self
    class(field_t), intent(inout) :: f
    real(kind=dp), intent(in) :: c
    logical, intent(in) :: at_end

procedure, public :: field_set_x_inlet_plane => field_set_x_inlet_plane_base

  • public subroutine field_set_x_inlet_plane_base(self, f, plane)

    Overwrites the x = 1 plane (pencil index 1) of a DIR_X field with the host array plane(ny, nz), in local VERT dims. Only the plane crosses to the device, so a time-varying inlet can be refreshed without uploading and reordering a full 3D field.

    Arguments

    Type IntentOptional Attributes Name
    class(base_backend_t) :: self
    class(field_t), intent(inout) :: f
    real(kind=dp), intent(in), dimension(:, :) :: plane

procedure, public :: init_poisson_fft => init_poisson_fft_base

  • public subroutine init_poisson_fft_base(self, mesh, xdirps, ydirps, zdirps, lowmem)

    Allocates and initialises the backend's FFT based Poisson solver.

    Arguments

    Type IntentOptional Attributes Name
    class(base_backend_t) :: self
    type(mesh_t), intent(in), target :: mesh
    type(dirps_t), intent(in) :: xdirps
    type(dirps_t), intent(in) :: ydirps
    type(dirps_t), intent(in) :: zdirps
    logical, intent(in), optional :: lowmem

procedure, public :: base_init

procedure, public :: get_field_data

  • public subroutine get_field_data(self, data, f, dir)

    Extract data from field f optionally reordering into dir orientation. To output in same orientation as f, use call ...%get_field_data(data, f, f%dir)

    Arguments

    Type IntentOptional Attributes Name
    class(base_backend_t) :: self
    real(kind=dp), intent(out), dimension(:, :, :) :: data

    Output array

    class(field_t), intent(in) :: f

    Field

    integer, intent(in), optional :: dir

    Desired orientation of output array (defaults to Cartesian)

procedure, public :: set_field_data

  • public subroutine set_field_data(self, f, data, dir)

    Arguments

    Type IntentOptional Attributes Name
    class(base_backend_t) :: self
    class(field_t), intent(inout) :: f

    Field

    real(kind=dp), intent(in), dimension(:, :, :) :: data

    Input array

    integer, intent(in), optional :: dir

    Orientation of input array (defaults to Cartesian)

procedure, public :: supports_device_field_export

  • public function supports_device_field_export(self, f)

    Whether export_field_to_device can pack field f without staging it through host memory. Backends without device memory keep this default and report no support.

    Arguments

    Type IntentOptional Attributes Name
    class(base_backend_t), intent(in) :: self
    class(field_t), intent(in) :: f

    Return Value logical

procedure, public :: export_field_to_device

  • public subroutine export_field_to_device(self, buffer, f, dims, to_sp)

    Pack the first dims Cartesian points of field f into a contiguous device buffer, in (i, j, k) order without padding.

    Read more…

    Arguments

    Type IntentOptional Attributes Name
    class(base_backend_t) :: self
    type(c_ptr), intent(in) :: buffer
    class(field_t), intent(in) :: f
    integer, intent(in) :: dims(3)
    logical, intent(in) :: to_sp

procedure, public :: alloc_tdsops => alloc_omptgt_tdsops

  • private subroutine alloc_omptgt_tdsops(self, tdsops, n_tds, delta, operation, scheme, bc_start, bc_end, stretch, stretch_correct, n_halo, from_to, sym, c_nu, nu0_nu, filter_alpha)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(tdsops_t), intent(inout), allocatable :: tdsops
    integer, intent(in) :: n_tds
    real(kind=dp), intent(in) :: delta
    character(len=*), intent(in) :: operation
    character(len=*), intent(in) :: scheme
    integer, intent(in) :: bc_start
    integer, intent(in) :: bc_end
    real(kind=dp), intent(in), optional :: stretch(:)
    real(kind=dp), intent(in), optional :: stretch_correct(:)
    integer, intent(in), optional :: n_halo
    character(len=*), intent(in), optional :: from_to
    logical, intent(in), optional :: sym
    real(kind=dp), intent(in), optional :: c_nu
    real(kind=dp), intent(in), optional :: nu0_nu
    real(kind=dp), intent(in), optional :: filter_alpha

procedure, public :: transeq_x => transeq_x_omptgt

  • private subroutine transeq_x_omptgt(self, du, dv, dw, u, v, w, nu, dirps)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: du
    class(field_t), intent(inout) :: dv
    class(field_t), intent(inout) :: dw
    class(field_t), intent(in) :: u
    class(field_t), intent(in) :: v
    class(field_t), intent(in) :: w
    real(kind=dp), intent(in) :: nu
    type(dirps_t), intent(in) :: dirps

procedure, public :: transeq_y => transeq_y_omptgt

  • private subroutine transeq_y_omptgt(self, du, dv, dw, u, v, w, nu, dirps)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: du
    class(field_t), intent(inout) :: dv
    class(field_t), intent(inout) :: dw
    class(field_t), intent(in) :: u
    class(field_t), intent(in) :: v
    class(field_t), intent(in) :: w
    real(kind=dp), intent(in) :: nu
    type(dirps_t), intent(in) :: dirps

procedure, public :: transeq_z => transeq_z_omptgt

  • private subroutine transeq_z_omptgt(self, du, dv, dw, u, v, w, nu, dirps)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: du
    class(field_t), intent(inout) :: dv
    class(field_t), intent(inout) :: dw
    class(field_t), intent(in) :: u
    class(field_t), intent(in) :: v
    class(field_t), intent(in) :: w
    real(kind=dp), intent(in) :: nu
    type(dirps_t), intent(in) :: dirps

procedure, public :: transeq_species => transeq_species_omptgt

  • private subroutine transeq_species_omptgt(self, dspec, uvw, spec, nu, dirps, sync)

    Computes the convection and diffusion of a scalar species in the direction of dirps. The species is always halo-exchanged; the transporting velocity only when sync is true, otherwise the u buffers still hold its halos from the preceding momentum transport.

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: dspec
    class(field_t), intent(in) :: uvw
    class(field_t), intent(in) :: spec
    real(kind=dp), intent(in) :: nu
    type(dirps_t), intent(in) :: dirps
    logical, intent(in) :: sync

procedure, public :: tds_solve => tds_solve_omptgt

  • private subroutine tds_solve_omptgt(self, du, u, tdsops)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: du
    class(field_t), intent(in) :: u
    class(tdsops_t), intent(in) :: tdsops

procedure, public :: thom_solve => thom_solve_omptgt

  • private subroutine thom_solve_omptgt(self, du, u, tdsops)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: du
    class(field_t), intent(in) :: u
    class(tdsops_t), intent(in) :: tdsops

procedure, public :: reorder => reorder_omptgt

  • private subroutine reorder_omptgt(self, u_, u, direction)

    Reorders u into u_ between the two data layouts encoded in direction, in a single pass for every pair of layouts (the CUDA backend goes through DIR_X for the pairs involving DIR_C).

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: u_
    class(field_t), intent(in) :: u
    integer, intent(in) :: direction

procedure, public :: sum_yintox => sum_yintox_omptgt

  • private subroutine sum_yintox_omptgt(self, u, u_)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: u
    class(field_t), intent(in) :: u_

procedure, public :: sum_zintox => sum_zintox_omptgt

  • private subroutine sum_zintox_omptgt(self, u, u_)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: u
    class(field_t), intent(in) :: u_

procedure, public :: veccopy => veccopy_omptgt

  • private subroutine veccopy_omptgt(self, dst, src)

    Copies src into dst. Both fields must share the same direction.

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: dst
    class(field_t), intent(in) :: src

procedure, public :: vecadd => vecadd_omptgt

  • private subroutine vecadd_omptgt(self, a, x, b, y)

    Computes y = ax + by.

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    real(kind=dp), intent(in) :: a
    class(field_t), intent(in) :: x
    real(kind=dp), intent(in) :: b
    class(field_t), intent(inout) :: y

procedure, public :: vecmult => vecmult_omptgt

procedure, public :: scalar_product => scalar_product_omptgt

  • private function scalar_product_omptgt(self, x, y) result(s)

    scalar_product_base

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(in) :: x
    class(field_t), intent(in) :: y

    Return Value real(kind=dp)

procedure, public :: vector_norm_squared => vector_norm_squared_omptgt

  • private function vector_norm_squared_omptgt(self, a, b, c) result(norm_squared)

    Global sum of a2 + b2 + c**2, with one MPI reduction.

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(in) :: a
    class(field_t), intent(in) :: b
    class(field_t), intent(in) :: c

    Return Value real(kind=dp)

procedure, public :: field_labelled_sums => field_labelled_sums_omptgt

  • private subroutine field_labelled_sums_omptgt(self, sums, g, label, a, b, c)

    field_labelled_sums_base

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    real(kind=dp), intent(out) :: sums(:,:)
    class(field_t), intent(in) :: g
    class(field_t), intent(in) :: label
    class(field_t), intent(in) :: a
    class(field_t), intent(in) :: b
    class(field_t), intent(in) :: c

procedure, public :: field_labelled_axpy => field_labelled_axpy_omptgt

  • private subroutine field_labelled_axpy_omptgt(self, coeffs, g, label, a, b, c)

    field_labelled_axpy_base

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    real(kind=dp), intent(in) :: coeffs(:,:)
    class(field_t), intent(in) :: g
    class(field_t), intent(in) :: label
    class(field_t), intent(inout) :: a
    class(field_t), intent(inout) :: b
    class(field_t), intent(inout) :: c

procedure, public :: field_max_mean => field_max_mean_omptgt

  • private subroutine field_max_mean_omptgt(self, max_val, mean_val, f, enforced_data_loc)

    field_max_mean_base

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    real(kind=dp), intent(out) :: max_val
    real(kind=dp), intent(out) :: mean_val
    class(field_t), intent(in) :: f
    integer, intent(in), optional :: enforced_data_loc

procedure, public :: slice_max_sum => slice_max_sum_omptgt

  • private subroutine slice_max_sum_omptgt(self, max_val, sum_val, f, i_slice, enforced_data_loc)

    slice_max_sum_base

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    real(kind=dp), intent(out) :: max_val
    real(kind=dp), intent(out) :: sum_val
    class(field_t), intent(in) :: f
    integer, intent(in) :: i_slice
    integer, intent(in), optional :: enforced_data_loc

procedure, public :: field_scale => field_scale_omptgt

  • private subroutine field_scale_omptgt(self, f, a)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(in) :: f
    real(kind=dp), intent(in) :: a

procedure, public :: field_shift => field_shift_omptgt

  • private subroutine field_shift_omptgt(self, f, a)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(in) :: f
    real(kind=dp), intent(in) :: a

procedure, public :: field_set_face => field_set_face_omptgt

  • private subroutine field_set_face_omptgt(self, f, c_start, c_end, face, bc_start, bc_end, flow_rate_diff)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: f
    real(kind=dp), intent(in) :: c_start
    real(kind=dp), intent(in) :: c_end
    integer, intent(in) :: face
    integer, intent(in), optional :: bc_start
    integer, intent(in), optional :: bc_end
    real(kind=dp), intent(in), optional :: flow_rate_diff

procedure, public :: field_set_y_plane => field_set_y_plane_omptgt

  • private subroutine field_set_y_plane_omptgt(self, f, c, plane)

    m_base_backend

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: f
    real(kind=dp), intent(in) :: c
    integer, intent(in) :: plane

procedure, public :: field_plane_sums => field_plane_sums_omptgt

  • private subroutine field_plane_sums_omptgt(self, sums, f)

    m_base_backend

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    real(kind=dp), intent(out) :: sums(:)
    class(field_t), intent(in) :: f

procedure, public :: field_set_abl_wall_stress => field_set_abl_wall_stress_omptgt

  • private subroutine field_set_abl_wall_stress_omptgt(self, stress, u, w, sample_plane, stress_plane, drag_coeff, component)

    m_base_backend

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: stress
    class(field_t), intent(in) :: u
    class(field_t), intent(in) :: w
    integer, intent(in) :: sample_plane
    integer, intent(in) :: stress_plane
    real(kind=dp), intent(in) :: drag_coeff
    integer, intent(in) :: component

procedure, public :: field_set_face_from_field => field_set_face_from_field_omptgt

  • private subroutine field_set_face_from_field_omptgt(self, f, f_start, c_end, face, bc_start, bc_end, flow_rate_diff)

    Set a face of f using values supplied by another field f_start. Both fields must be DIR_X VERT pencil-layout. X_FACE uses the inlet plane (pencil index 1) of f_start plus a convective outflow update at the right face. Y_FACE copies the bottom and top y-pencil planes of f_start onto the corresponding planes of f (Dirichlet only).

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: f
    class(field_t), intent(in) :: f_start
    real(kind=dp), intent(in) :: c_end
    integer, intent(in) :: face
    integer, intent(in), optional :: bc_start
    integer, intent(in), optional :: bc_end
    real(kind=dp), intent(in), optional :: flow_rate_diff

procedure, public :: field_add_face_from_field => field_add_face_from_field_omptgt

  • private subroutine field_add_face_from_field_omptgt(self, f, g, face, bc_start, bc_end)

    m_base_backend

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: f
    class(field_t), intent(in) :: g
    integer, intent(in) :: face
    integer, intent(in) :: bc_start
    integer, intent(in) :: bc_end

procedure, public :: compute_vorticity => compute_vorticity_omptgt

  • private subroutine compute_vorticity_omptgt(self, field_out, dudx, dudy, dudz, dvdx, dvdy, dvdz, dwdx, dwdy, dwdz)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: field_out
    class(field_t), intent(in) :: dudx
    class(field_t), intent(in) :: dudy
    class(field_t), intent(in) :: dudz
    class(field_t), intent(in) :: dvdx
    class(field_t), intent(in) :: dvdy
    class(field_t), intent(in) :: dvdz
    class(field_t), intent(in) :: dwdx
    class(field_t), intent(in) :: dwdy
    class(field_t), intent(in) :: dwdz

procedure, public :: compute_qcriterion => compute_qcriterion_omptgt

  • private subroutine compute_qcriterion_omptgt(self, field_out, dudx, dudy, dudz, dvdx, dvdy, dvdz, dwdx, dwdy, dwdz)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: field_out
    class(field_t), intent(in) :: dudx
    class(field_t), intent(in) :: dudy
    class(field_t), intent(in) :: dudz
    class(field_t), intent(in) :: dvdx
    class(field_t), intent(in) :: dvdy
    class(field_t), intent(in) :: dvdz
    class(field_t), intent(in) :: dwdx
    class(field_t), intent(in) :: dwdy
    class(field_t), intent(in) :: dwdz

procedure, public :: compute_smagorinsky_nut => compute_smagorinsky_nut_omptgt

  • private subroutine compute_smagorinsky_nut_omptgt(self, nut, mixing_length_sq, dudx, dudy, dudz, dvdx, dvdy, dvdz, dwdx, dwdy, dwdz)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: nut
    class(field_t), intent(in) :: mixing_length_sq
    class(field_t), intent(in) :: dudx
    class(field_t), intent(in) :: dudy
    class(field_t), intent(in) :: dudz
    class(field_t), intent(in) :: dvdx
    class(field_t), intent(in) :: dvdy
    class(field_t), intent(in) :: dvdz
    class(field_t), intent(in) :: dwdx
    class(field_t), intent(in) :: dwdy
    class(field_t), intent(in) :: dwdz

procedure, public :: compute_sgs_stress => compute_sgs_stress_omptgt

  • private subroutine compute_sgs_stress_omptgt(self, stress, nut, gradient_a, gradient_b, scale_a, scale_b)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: stress
    class(field_t), intent(in) :: nut
    class(field_t), intent(in) :: gradient_a
    class(field_t), intent(in) :: gradient_b
    real(kind=dp), intent(in) :: scale_a
    real(kind=dp), intent(in) :: scale_b

procedure, public :: field_volume_integral => field_volume_integral_omptgt

  • private function field_volume_integral_omptgt(self, f) result(s)

    volume integral of a field

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(in) :: f

    Return Value real(kind=dp)

procedure, public :: copy_data_to_f => copy_data_to_f_omptgt

  • private subroutine copy_data_to_f_omptgt(self, f, data)

    Copies a host array of the field's shape into a device-resident field.

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t), intent(inout) :: self
    class(field_t), intent(inout) :: f
    real(kind=dp), intent(in), dimension(:, :, :) :: data

procedure, public :: copy_f_to_data => copy_f_to_data_omptgt

  • private subroutine copy_f_to_data_omptgt(self, data, f)

    Copies a device-resident field into a host array of its shape.

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t), intent(inout) :: self
    real(kind=dp), intent(out), dimension(:, :, :) :: data
    class(field_t), intent(in) :: f

procedure, public :: sync => sync_omptgt

  • private subroutine sync_omptgt(self)

    Waits for outstanding device work (see device_sync).

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self

procedure, public :: get_device_bw_info => get_device_bw_info_omptgt

  • private subroutine get_device_bw_info_omptgt(self, mem_clock_rt, mem_bus_width, available)

    Reports the memory clock rate (kHz) and bus width (bits) of the default device. OpenMP has no query for them, so they come from the vendor runtime (see m_omptgt_device_info); available is false when that runtime cannot be found.

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    integer, intent(out) :: mem_clock_rt
    integer, intent(out) :: mem_bus_width
    logical, intent(out) :: available

procedure, public :: transeq_omptgt_dist

  • private subroutine transeq_omptgt_dist(self, du, dv, dw, u, v, w, nu, dirps)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: du
    class(field_t), intent(inout) :: dv
    class(field_t), intent(inout) :: dw
    class(field_t), intent(in) :: u
    class(field_t), intent(in) :: v
    class(field_t), intent(in) :: w
    real(kind=dp), intent(in) :: nu
    type(dirps_t), intent(in) :: dirps

procedure, public :: tds_solve_dist

  • private subroutine tds_solve_dist(self, du, u, tdsops)

    Arguments

    Type IntentOptional Attributes Name
    class(omptgt_backend_t) :: self
    class(field_t), intent(inout) :: du
    class(field_t), intent(in) :: u
    class(tdsops_t), intent(in) :: tdsops