Skip to content
Open
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
12 changes: 8 additions & 4 deletions sycl/include/sycl/queue.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3310,7 +3310,8 @@ class __SYCL_EXPORT queue : public detail::OwnerLessBase<queue> {
RestT &&...Rest) {
constexpr detail::code_location CodeLoc = getCodeLocation<KernelName>();
detail::tls_code_loc_t TlsCodeLocCapture(CodeLoc);
using KernelType = std::tuple_element_t<0, std::tuple<RestT...>>;
using KernelType = std::remove_const_t<
std::remove_reference_t<std::tuple_element_t<0, std::tuple<RestT...>>>>;

// TODO The handler-less path does not support reductions, and
// kernel functions with the kernel_handler type argument yet.
Expand Down Expand Up @@ -3340,7 +3341,8 @@ class __SYCL_EXPORT queue : public detail::OwnerLessBase<queue> {
parallel_for(nd_range<Dims> Range, RestT &&...Rest) {
constexpr detail::code_location CodeLoc = getCodeLocation<KernelName>();
detail::tls_code_loc_t TlsCodeLocCapture(CodeLoc);
using KernelType = std::tuple_element_t<0, std::tuple<RestT...>>;
using KernelType = std::remove_const_t<
std::remove_reference_t<std::tuple_element_t<0, std::tuple<RestT...>>>>;

// TODO The handler-less path does not support reductions, and
// kernel functions with the kernel_handler type argument yet.
Expand Down Expand Up @@ -3402,7 +3404,8 @@ class __SYCL_EXPORT queue : public detail::OwnerLessBase<queue> {
parallel_for(nd_range<Dims> Range, event DepEvent, RestT &&...Rest) {
constexpr detail::code_location CodeLoc = getCodeLocation<KernelName>();
detail::tls_code_loc_t TlsCodeLocCapture(CodeLoc);
using KernelType = std::tuple_element_t<0, std::tuple<RestT...>>;
using KernelType = std::remove_const_t<
std::remove_reference_t<std::tuple_element_t<0, std::tuple<RestT...>>>>;

// TODO The handler-less path does not support reductions, and
// kernel functions with the kernel_handler type argument yet.
Expand Down Expand Up @@ -3469,7 +3472,8 @@ class __SYCL_EXPORT queue : public detail::OwnerLessBase<queue> {
RestT &&...Rest) {
constexpr detail::code_location CodeLoc = getCodeLocation<KernelName>();
detail::tls_code_loc_t TlsCodeLocCapture(CodeLoc);
using KernelType = std::tuple_element_t<0, std::tuple<RestT...>>;
using KernelType = std::remove_const_t<
std::remove_reference_t<std::tuple_element_t<0, std::tuple<RestT...>>>>;

// TODO The handler-less path does not support reductions, and
// kernel functions with the kernel_handler type argument yet.
Expand Down