SWDEV-348565 - Support for += operator.

Change-Id: I29045733de3906849e68b89c22e01badc9bd2b24


[ROCm/clr commit: 638f9a7c0e]
This commit is contained in:
Jaydeep Patel
2022-08-01 14:07:02 +00:00
کامیت شده توسط Jaydeepkumar Patel
والد 1752b3049e
کامیت d019772bd0
@@ -296,9 +296,18 @@ template <typename F>
struct __HIP_Coordinates {
using R = decltype(F{}(0));
struct __X { __device__ operator R() const noexcept { return F{}(0); } };
struct __Y { __device__ operator R() const noexcept { return F{}(1); } };
struct __Z { __device__ operator R() const noexcept { return F{}(2); } };
struct __X {
__device__ operator R() const noexcept { return F{}(0); }
__device__ R operator+=(const R& rhs) { return F{}(0) + rhs; }
};
struct __Y {
__device__ operator R() const noexcept { return F{}(1); }
__device__ R operator+=(const R& rhs) { return F{}(1) + rhs; }
};
struct __Z {
__device__ operator R() const noexcept { return F{}(2); }
__device__ R operator+=(const R& rhs) { return F{}(2) + rhs; }
};
static constexpr __X x{};
static constexpr __Y y{};