11#ifndef __Panzer_KokkosThyraConversion_hpp__
12#define __Panzer_KokkosThyraConversion_hpp__
14#include "Kokkos_Core.hpp"
16#include "Teuchos_RCP.hpp"
17#include "Teuchos_Ptr.hpp"
19#include "Thyra_VectorBase.hpp"
20#include "Thyra_DefaultSpmdVector.hpp"
22#include "Epetra_Vector.h"
25namespace kokkos_utils {
36 typedef Kokkos::View<double*,Kokkos::HostSpace ,Kokkos::MemoryTraits<Kokkos::Unmanaged > >
View;
43 typedef Kokkos::View<const double*,Kokkos::HostSpace ,Kokkos::MemoryTraits<Kokkos::Unmanaged > >
View;
47template <
typename VectorType>
57 auto values = Teuchos::ptr_dynamic_cast<Thyra::DefaultSpmdVector<double> >(Teuchos::ptrFromRef(v))->getRCPtr();
69 auto values = Teuchos::ptr_dynamic_cast<const Thyra::DefaultSpmdVector<double> >(Teuchos::ptrFromRef(v))->getRCPtr();
Kokkos::View< double *, Kokkos::HostSpace,Kokkos::MemoryTraits< Kokkos::Unmanaged > > View
Thyra::VectorBase< double > ThyraVector
const Thyra::VectorBase< double > ThyraVector
Kokkos::View< const double *, Kokkos::HostSpace,Kokkos::MemoryTraits< Kokkos::Unmanaged > > View
VectorToViewTraits< constEpetra_Vector >::View getView< const Epetra_Vector >(typename VectorToViewTraits< const Epetra_Vector >::ThyraVector &v)
VectorToViewTraits< Epetra_Vector >::View getView< Epetra_Vector >(typename VectorToViewTraits< Epetra_Vector >::ThyraVector &v)
VectorToViewTraits< VectorType >::View getView(typename VectorToViewTraits< VectorType >::ThyraVector &v)