Stokhos Package Browser (Single Doxygen Collection) Version of the Day
Loading...
Searching...
No Matches
Classes | Namespaces | Macros | Functions | Variables
Stokhos_KokkosViewMPVectorUnitTest.hpp File Reference
#include "Teuchos_TestingHelpers.hpp"
#include "Teuchos_UnitTestHelpers.hpp"
#include "Stokhos_UnitTestHelpers.hpp"
#include "Stokhos_Sacado_Kokkos_MP_Vector.hpp"
#include "Stokhos_Ensemble_Sizes.hpp"
#include "Kokkos_Core.hpp"
Include dependency graph for Stokhos_KokkosViewMPVectorUnitTest.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  ApplyView< DataType, LayoutType, ExecutionSpace >
 
struct  NoLayout
 
struct  ApplyView< DataType, NoLayout, ExecutionSpace >
 
struct  Test::MPVectorAtomicFunctor< ViewType >
 

Namespaces

namespace  Test
 

Macros

#define VIEW_MP_VECTOR_TESTS_STORAGE_LAYOUT(STORAGE, LAYOUT)
 
#define VIEW_MP_VECTOR_TESTS_STORAGE(STORAGE)
 
#define VIEW_MP_VECTOR_TESTS_ORDINAL_SCALAR_DEVICE(ORDINAL, SCALAR, DEVICE)
 
#define VIEW_MP_VECTOR_TESTS_DEVICE(DEVICE)    VIEW_MP_VECTOR_TESTS_ORDINAL_SCALAR_DEVICE( int, double, DEVICE )
 

Functions

template<typename scalar , typename ordinal >
scalar generate_vector_coefficient (const ordinal nFEM, const ordinal nStoch, const ordinal iColFEM, const ordinal iStoch)
 
template<typename ViewType >
bool checkVectorView (const ViewType &v, Teuchos::FancyOStream &out)
 
template<typename ViewType >
bool checkConstantVectorView (const ViewType &v, const typename ViewType::value_type &v_expected, Teuchos::FancyOStream &out)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, Size, Storage, Layout)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, DeepCopy, Storage, Layout)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, DeepCopy_ConstantScalar, Storage, Layout)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, DeepCopy_ConstantVector, Storage, Layout)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, DeepCopy_ConstantVector2, Storage, Layout)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_1_DECL (Kokkos_View_MP, DeepCopy_Subview_Range, Storage)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, DeepCopy_HostArray, Storage, Layout)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, DeepCopy_DeviceArray, Storage, Layout)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, Unmanaged, Storage, Layout)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, PartitionHost, Storage, Layout)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, Flatten, Storage, Layout)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, DeviceAtomic, Storage, Layout)
 
 TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL (Kokkos_View_MP, AssignData, Storage, Layout)
 

Variables

const int global_num_rows = 11
 
const int global_num_cols = STOKHOS_DEFAULT_ENSEMBLE_SIZE
 

Macro Definition Documentation

◆ VIEW_MP_VECTOR_TESTS_STORAGE_LAYOUT

#define VIEW_MP_VECTOR_TESTS_STORAGE_LAYOUT ( STORAGE,
LAYOUT )
Value:
Kokkos_View_MP, Size, STORAGE, LAYOUT ) \
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT( \
Kokkos_View_MP, DeepCopy, STORAGE, LAYOUT ) \
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT( \
Kokkos_View_MP, DeepCopy_ConstantScalar, STORAGE, LAYOUT ) \
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT( \
Kokkos_View_MP, DeepCopy_ConstantVector, STORAGE, LAYOUT ) \
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT( \
Kokkos_View_MP, DeepCopy_ConstantVector2, STORAGE, LAYOUT ) \
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT( \
Kokkos_View_MP, Unmanaged, STORAGE, LAYOUT ) \
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT( \
Kokkos_View_MP, Flatten, STORAGE, LAYOUT ) \
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT( \
Kokkos_View_MP, AssignData, STORAGE, LAYOUT )
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT(Tpetra_CrsMatrix, MatVec, double, Node) TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT(Tpetra_CrsMatrix

Definition at line 595 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ VIEW_MP_VECTOR_TESTS_STORAGE

#define VIEW_MP_VECTOR_TESTS_STORAGE ( STORAGE)
Value:
using Kokkos::LayoutLeft; \
using Kokkos::LayoutRight; \
VIEW_MP_VECTOR_TESTS_STORAGE_LAYOUT(STORAGE, NoLayout) \
VIEW_MP_VECTOR_TESTS_STORAGE_LAYOUT(STORAGE, LayoutLeft) \
VIEW_MP_VECTOR_TESTS_STORAGE_LAYOUT(STORAGE, LayoutRight) \
TEUCHOS_UNIT_TEST_TEMPLATE_1_INSTANT( \
Kokkos_View_MP, DeepCopy_Subview_Range, STORAGE )

Definition at line 627 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ VIEW_MP_VECTOR_TESTS_ORDINAL_SCALAR_DEVICE

#define VIEW_MP_VECTOR_TESTS_ORDINAL_SCALAR_DEVICE ( ORDINAL,
SCALAR,
DEVICE )
Value:
VIEW_MP_VECTOR_TESTS_STORAGE( SFS ) \
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT( \
Kokkos_View_MP, PartitionHost, SFS, NoLayout ) \
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT( \
Kokkos_View_MP, PartitionHost, SFS, LayoutLeft ) \
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT( \
Kokkos_View_MP, PartitionHost, SFS, LayoutRight )
Statically allocated storage class.

Definition at line 638 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ VIEW_MP_VECTOR_TESTS_DEVICE

#define VIEW_MP_VECTOR_TESTS_DEVICE ( DEVICE)     VIEW_MP_VECTOR_TESTS_ORDINAL_SCALAR_DEVICE( int, double, DEVICE )

Definition at line 648 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

Function Documentation

◆ generate_vector_coefficient()

template<typename scalar , typename ordinal >
scalar generate_vector_coefficient ( const ordinal nFEM,
const ordinal nStoch,
const ordinal iColFEM,
const ordinal iStoch )
inline

Definition at line 61 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ checkVectorView()

template<typename ViewType >
bool checkVectorView ( const ViewType & v,
Teuchos::FancyOStream & out )

Definition at line 74 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ checkConstantVectorView()

template<typename ViewType >
bool checkConstantVectorView ( const ViewType & v,
const typename ViewType::value_type & v_expected,
Teuchos::FancyOStream & out )

Definition at line 130 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [1/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
Size ,
Storage ,
Layout  )

Definition at line 174 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [2/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
DeepCopy ,
Storage ,
Layout  )

Definition at line 187 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [3/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
DeepCopy_ConstantScalar ,
Storage ,
Layout  )

Definition at line 222 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [4/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
DeepCopy_ConstantVector ,
Storage ,
Layout  )

Definition at line 240 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [5/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
DeepCopy_ConstantVector2 ,
Storage ,
Layout  )

Definition at line 258 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_1_DECL()

TEUCHOS_UNIT_TEST_TEMPLATE_1_DECL ( Kokkos_View_MP ,
DeepCopy_Subview_Range ,
Storage  )

Definition at line 279 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [6/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
DeepCopy_HostArray ,
Storage ,
Layout  )

Definition at line 326 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [7/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
DeepCopy_DeviceArray ,
Storage ,
Layout  )

Definition at line 360 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [8/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
Unmanaged ,
Storage ,
Layout  )

Definition at line 387 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [9/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
PartitionHost ,
Storage ,
Layout  )

Definition at line 425 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [10/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
Flatten ,
Storage ,
Layout  )

Definition at line 498 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [11/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
DeviceAtomic ,
Storage ,
Layout  )

Definition at line 551 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL() [12/12]

TEUCHOS_UNIT_TEST_TEMPLATE_2_DECL ( Kokkos_View_MP ,
AssignData ,
Storage ,
Layout  )

Definition at line 569 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

Variable Documentation

◆ global_num_rows

const int global_num_rows = 11

Definition at line 171 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.

◆ global_num_cols

const int global_num_cols = STOKHOS_DEFAULT_ENSEMBLE_SIZE

Definition at line 172 of file Stokhos_KokkosViewMPVectorUnitTest.hpp.