Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KokkosBatched - PR to match trilinos 6959 #635

Merged
merged 1 commit into from
Mar 12, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions src/batched/KokkosBatched_Gemm_Serial_Impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = C.dimension(0),
n = C.dimension(1),
k = A.dimension(1);
m = C.extent(0),
n = C.extent(1),
k = A.extent(1);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down Expand Up @@ -155,9 +155,9 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = C.dimension(0),
n = C.dimension(1),
k = A.dimension(0);
m = C.extent(0),
n = C.extent(1),
k = A.extent(0);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down Expand Up @@ -264,9 +264,9 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = C.dimension(0),
n = C.dimension(1),
k = A.dimension(1);
m = C.extent(0),
n = C.extent(1),
k = A.extent(1);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down Expand Up @@ -373,9 +373,9 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = C.dimension(0),
n = C.dimension(1),
k = A.dimension(0);
m = C.extent(0),
n = C.extent(1),
k = A.extent(0);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down
8 changes: 4 additions & 4 deletions src/batched/KokkosBatched_Gemv_Serial_Impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = A.dimension(0),
m = A.extent(0),
n = 1,
k = A.dimension(1);
k = A.extent(1);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down Expand Up @@ -150,9 +150,9 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = A.dimension(0),
m = A.extent(0),
n = 1,
k = A.dimension(1);
k = A.extent(1);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down
4 changes: 2 additions & 2 deletions src/batched/KokkosBatched_LU_Serial_Impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = A.dimension(0),
n = A.dimension(1);
m = A.extent(0),
n = A.extent(1);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down
20 changes: 10 additions & 10 deletions src/batched/KokkosBatched_Trsm_Serial_Impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = B.dimension(0),
n = B.dimension(1);
m = B.extent(0),
n = B.extent(1);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down Expand Up @@ -128,8 +128,8 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = B.dimension(0),
n = B.dimension(1);
m = B.extent(0),
n = B.extent(1);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down Expand Up @@ -223,8 +223,8 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = B.dimension(0),
n = B.dimension(1);
m = B.extent(0),
n = B.extent(1);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down Expand Up @@ -319,8 +319,8 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = B.dimension(0),
n = B.dimension(1);
m = B.extent(0),
n = B.extent(1);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down Expand Up @@ -413,8 +413,8 @@ namespace KokkosBatched {
//typedef typename vector_type::value_type value_type;

const int
m = B.dimension(0),
n = B.dimension(1);
m = B.extent(0),
n = B.extent(1);

static_assert(is_vector<vector_type>::value, "value type is not vector type");
static_assert(vector_type::vector_length == 4 || vector_type::vector_length == 8,
Expand Down
6 changes: 3 additions & 3 deletions src/batched/KokkosBatched_Util.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,7 @@

#include "KokkosKernels_config.h"

namespace KokkosBatched {

// TPL macros
// TPL macros
#if defined (KOKKOSKERNELS_ENABLE_TPL_MKL)
#define __KOKKOSBATCHED_INTEL_MKL__ 1
#include "mkl_version.h"
Expand All @@ -38,6 +36,8 @@ namespace KokkosBatched {
#endif
#endif

namespace KokkosBatched {

#if defined (KOKKOSKERNELS_ENABLE_TPL_CUBLAS)
#define __KOKKOSKERNELS_NVIDIA_CUBLAS__ 1
#endif
Expand Down
18 changes: 0 additions & 18 deletions src/batched/KokkosBatched_Vector_SIMD_View.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,24 +57,6 @@ namespace KokkosBatched {
extent_int( const iType & r ) const
{ return static_cast<int>(_a.extent(r)*(r == PackDim::value ? vector_length : 1)); }

#ifdef KOKKOS_ENABLE_DEPRECATED_CODE

template< typename iType >
KOKKOS_INLINE_FUNCTION constexpr
typename std::enable_if< std::is_integral<iType>::value , size_t >::type
dimension( const iType & r ) const { return extent( r ); }

KOKKOS_INLINE_FUNCTION constexpr size_t dimension_0() const { return _a.extent(0)*(0 == PackDim::value ? vector_length : 1); }
KOKKOS_INLINE_FUNCTION constexpr size_t dimension_1() const { return _a.extent(1)*(1 == PackDim::value ? vector_length : 1); }
KOKKOS_INLINE_FUNCTION constexpr size_t dimension_2() const { return _a.extent(2)*(2 == PackDim::value ? vector_length : 1); }
KOKKOS_INLINE_FUNCTION constexpr size_t dimension_3() const { return _a.extent(3)*(3 == PackDim::value ? vector_length : 1); }
KOKKOS_INLINE_FUNCTION constexpr size_t dimension_4() const { return _a.extent(4)*(4 == PackDim::value ? vector_length : 1); }
KOKKOS_INLINE_FUNCTION constexpr size_t dimension_5() const { return _a.extent(5)*(5 == PackDim::value ? vector_length : 1); }
KOKKOS_INLINE_FUNCTION constexpr size_t dimension_6() const { return _a.extent(6)*(6 == PackDim::value ? vector_length : 1); }
KOKKOS_INLINE_FUNCTION constexpr size_t dimension_7() const { return _a.extent(7)*(7 == PackDim::value ? vector_length : 1); }

#endif

KOKKOS_INLINE_FUNCTION constexpr size_t size() const {
return (_a.size() * vector_length);
}
Expand Down