We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 56b134c commit 1798bf2Copy full SHA for 1798bf2
dpctl/tensor/libtensor/include/kernels/elementwise_functions/common.hpp
@@ -240,16 +240,13 @@ struct UnaryStridedFunctor
240
241
void operator()(sycl::id<1> wid) const
242
{
243
- const argT *const &in = inp_;
244
- resT *const &out = res_;
245
-
246
- auto offsets_ = inp_out_indexer_(wid.get(0));
+ const auto &offsets_ = inp_out_indexer_(wid.get(0));
247
const py::ssize_t &inp_offset = offsets_.get_first_offset();
248
- const py::ssize_t &out_offset = offsets_.get_second_offset();
+ const py::ssize_t &res_offset = offsets_.get_second_offset();
249
250
UnaryOpT op{};
251
252
- out[out_offset] = op(in[inp_offset]);
+ res_[res_offset] = op(inp_[inp_offset]);
253
}
254
};
255
0 commit comments