Skip to content

[ESIMD] Remove simd move test cases #15062

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

Merged
merged 5 commits into from
Aug 14, 2024
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
18 changes: 5 additions & 13 deletions sycl/include/sycl/ext/intel/esimd/detail/simd_obj_impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
#include <sycl/ext/intel/esimd/detail/intrin.hpp>
#include <sycl/ext/intel/esimd/detail/memory_intrin.hpp>
#include <sycl/ext/intel/esimd/detail/sycl_util.hpp>
#include <sycl/ext/intel/esimd/detail/test_proxy.hpp>
#include <sycl/ext/intel/esimd/detail/type_format.hpp>
#include <sycl/ext/intel/esimd/simd_view.hpp>

Expand Down Expand Up @@ -1038,8 +1037,8 @@ class [[__sycl_detail__::__uses_aspects__(
/** @tparam SimdT The argument object type(auto-deduced). */ \
/** @param RHS The argument object. */ \
template <class T1, class SimdT, \
class = std::enable_if_t<(is_simd_type_v<Derived> == \
is_simd_type_v<SimdT>)&&COND>> \
class = std::enable_if_t< \
(is_simd_type_v<Derived> == is_simd_type_v<SimdT>) && COND>> \
Derived &operator OPASSIGN( \
const __ESIMD_DNS::simd_obj_impl<T1, N, SimdT> &RHS) { \
auto Res = *this BINOP RHS; \
Expand All @@ -1056,10 +1055,9 @@ class [[__sycl_detail__::__uses_aspects__(
/** @param RHS The argument object. */ \
template <class SimdT1, class RegionT1, \
class T1 = typename RegionT1::element_type, \
class = std::enable_if_t< \
(is_simd_type_v<Derived> == \
is_simd_type_v<SimdT1>)&&(RegionT1::length == length) && \
COND>> \
class = std::enable_if_t<(is_simd_type_v<Derived> == \
is_simd_type_v<SimdT1>) && \
(RegionT1::length == length) && COND>> \
Derived &operator OPASSIGN( \
const __ESIMD_NS::simd_view<SimdT1, RegionT1> &RHS) { \
auto Res = *this BINOP RHS.read(); \
Expand Down Expand Up @@ -1132,9 +1130,6 @@ class [[__sycl_detail__::__uses_aspects__(
#undef __ESIMD_ARITH_OP_FILTER
#undef __ESIMD_DEF_SIMD_OBJ_IMPL_OPASSIGN

// Getter for the test proxy member, if enabled
__ESIMD_DECLARE_TEST_PROXY_ACCESS

private:
// The underlying data for this vector.
raw_vector_type M_data;
Expand All @@ -1159,9 +1154,6 @@ class [[__sycl_detail__::__uses_aspects__(
PropertyListT = {}) SYCL_ESIMD_FUNCTION;

protected:
// The test proxy if enabled
__ESIMD_DECLARE_TEST_PROXY

void set(const raw_vector_type &Val) {
#ifndef __SYCL_DEVICE_ONLY__
M_data = Val;
Expand Down
29 changes: 8 additions & 21 deletions sycl/include/sycl/ext/intel/esimd/detail/simd_view_impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@

#include <sycl/aspects.hpp>
#include <sycl/ext/intel/esimd/detail/intrin.hpp>
#include <sycl/ext/intel/esimd/detail/test_proxy.hpp>
#include <sycl/ext/intel/esimd/detail/type_format.hpp>

namespace sycl {
Expand Down Expand Up @@ -300,10 +299,9 @@ class [[__sycl_detail__::__uses_aspects__(
/* OPASSIGN simd_obj_impl */ \
template <class T1, int N1, class SimdT1, class T = element_type, \
class SimdT = BaseTy, \
class = \
std::enable_if_t<(is_simd_type_v<SimdT> == \
is_simd_type_v<SimdT1>)&&(N1 == length) && \
COND>> \
class = std::enable_if_t<(is_simd_type_v<SimdT> == \
is_simd_type_v<SimdT1>) && \
(N1 == length) && COND>> \
Derived &operator OPASSIGN(const simd_obj_impl<T1, N1, SimdT1> &RHS) { \
auto Res = read() BINOP RHS; \
write(Res); \
Expand All @@ -316,9 +314,8 @@ class [[__sycl_detail__::__uses_aspects__(
typename __ESIMD_NS::shape_type<RegionT1>::element_type, \
class T = element_type, class SimdT = BaseTy, \
class = std::enable_if_t< \
(is_simd_type_v<SimdT> == is_simd_type_v<SimdT1>)&&( \
length == __ESIMD_NS::shape_type<RegionT1>::length) && \
COND>> \
(is_simd_type_v<SimdT> == is_simd_type_v<SimdT1>) && \
(length == __ESIMD_NS::shape_type<RegionT1>::length) && COND>> \
Derived &operator OPASSIGN(const simd_view_impl<SimdT1, RegionT1> &RHS) { \
*this OPASSIGN RHS.read(); \
return cast_this_to_derived(); \
Expand Down Expand Up @@ -404,14 +401,10 @@ class [[__sycl_detail__::__uses_aspects__(
/// region viewed by this object.
/// @param Other The source rvalue object.
/// @return This object cast to the derived class.
Derived &operator=(Derived &&Other) {
__esimd_move_test_proxy(Other);
return write(Other.read());
}
Derived &operator=(Derived &&Other) { return write(Other.read()); }

/// Move assignment operator. Updates the target region viewed by this object.
simd_view_impl &operator=(simd_view_impl &&Other) {
__esimd_move_test_proxy(Other);
return write(Other.read());
}

Expand All @@ -425,8 +418,8 @@ class [[__sycl_detail__::__uses_aspects__(
/// @return This object cast to the derived class.
template <class T, int N, class SimdT,
class = std::enable_if_t<(is_simd_type_v<SimdT> ==
is_simd_type_v<BaseTy>)&&(length ==
SimdT::length)>>
is_simd_type_v<BaseTy>) &&
(length == SimdT::length)>>
Derived &operator=(const simd_obj_impl<T, N, SimdT> &Other) {
return write(convert_vector<element_type, typename SimdT::element_type, N>(
Other.data()));
Expand Down Expand Up @@ -587,16 +580,10 @@ class [[__sycl_detail__::__uses_aspects__(

/// @cond EXCLUDE
public:
// Getter for the test proxy member, if enabled
__ESIMD_DECLARE_TEST_PROXY_ACCESS

protected:
// The reference to the base object, which must be a simd object
BaseTy &M_base;

// The test proxy if enabled
__ESIMD_DECLARE_TEST_PROXY

// The region applied on the base object. Its type could be
// - region1d_t
// - region2d_t
Expand Down
111 changes: 0 additions & 111 deletions sycl/include/sycl/ext/intel/esimd/detail/test_proxy.hpp

This file was deleted.

Loading
Loading