AmrDualArray< T > Struct Template Reference

AMR-Wind API: amr_wind::tioga_iface::AmrDualArray< T > Struct Template Reference
AMR-Wind API v0.1.0
CFD solver for wind plant simulations
Loading...
Searching...
No Matches
amr_wind::tioga_iface::AmrDualArray< T > Struct Template Reference

#include <overset_types.H>

Inheritance diagram for amr_wind::tioga_iface::AmrDualArray< T >:
[legend]

Public Types

using ArrayType = amrex::Gpu::DeviceVector<T>
 
using HostArrayType = amrex::Vector<T>
 

Public Member Functions

 AmrDualArray ()
 
 AmrDualArray (const size_t len)
 Construct arrays on host/device with a given length.
 
void resize (const size_t len)
 Resize arrays on host and device.
 
size_t size () const
 Return the size of the arrays.
 
void copy_to_device ()
 Copy data from host to device.
 
void copy_to_host ()
 Copy data from device to host.
 

Public Attributes

ArrayType d_view
 Data on device.
 
HostArrayType h_view
 Data on host.
 

Detailed Description

template<typename T>
struct amr_wind::tioga_iface::AmrDualArray< T >

Wrapper to handle host/device views of the data for TIOGA overset

Member Typedef Documentation

◆ ArrayType

template<typename T >
using amr_wind::tioga_iface::AmrDualArray< T >::ArrayType = amrex::Gpu::DeviceVector<T>

◆ HostArrayType

template<typename T >
using amr_wind::tioga_iface::AmrDualArray< T >::HostArrayType = amrex::Vector<T>

Constructor & Destructor Documentation

◆ AmrDualArray() [1/2]

template<typename T >
amr_wind::tioga_iface::AmrDualArray< T >::AmrDualArray ( )
inline

◆ AmrDualArray() [2/2]

template<typename T >
amr_wind::tioga_iface::AmrDualArray< T >::AmrDualArray ( const size_t len)
inlineexplicit

Construct arrays on host/device with a given length.

Member Function Documentation

◆ copy_to_device()

template<typename T >
void amr_wind::tioga_iface::AmrDualArray< T >::copy_to_device ( )
inline

Copy data from host to device.

◆ copy_to_host()

template<typename T >
void amr_wind::tioga_iface::AmrDualArray< T >::copy_to_host ( )
inline

Copy data from device to host.

◆ resize()

template<typename T >
void amr_wind::tioga_iface::AmrDualArray< T >::resize ( const size_t len)
inline

Resize arrays on host and device.

◆ size()

template<typename T >
size_t amr_wind::tioga_iface::AmrDualArray< T >::size ( ) const
inline

Return the size of the arrays.

Member Data Documentation

◆ d_view

template<typename T >
ArrayType amr_wind::tioga_iface::AmrDualArray< T >::d_view

Data on device.

◆ h_view

template<typename T >
HostArrayType amr_wind::tioga_iface::AmrDualArray< T >::h_view

Data on host.


The documentation for this struct was generated from the following file: