Skip to content
Open
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
9 changes: 5 additions & 4 deletions include/nvexec/stream/common.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -429,10 +429,11 @@ namespace nv::execution
using decayed_tuple_t = ::cuda::std::tuple<__decay_t<Ts>...>;

template <class Sender, class Env>
using variant_storage_t =
__for_each_completion_signature_t<__completion_signatures_of_t<Sender, Env>,
decayed_tuple_t,
__munique<__q<_nullable_variant_t>>::__f>;
using variant_storage_t = __for_each_completion_signature_t<
__completion_signatures_of_t<Sender, Env>,
decayed_tuple_t,
__munique<
__mbind_back_q<_nullable_variant_t, ::cuda::std::tuple<set_error_t, cudaError_t>>>::__f>;

inline constexpr get_stream_provider_t get_stream_provider{};

Expand Down
5 changes: 3 additions & 2 deletions include/nvexec/stream/continues_on.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -239,9 +239,10 @@ namespace nv::execution::_strm

template <__decay_copyable Self, class... Env>
static consteval auto get_completion_signatures()
-> __completion_signatures_of_t<__copy_cvref_t<Self, Sender>, Env...>
{
return {};
return exec::concat_completion_signatures(
STDEXEC::get_completion_signatures<__copy_cvref_t<Self, Sender>, Env...>(),
STDEXEC::completion_signatures<set_error_t(cudaError_t)>());
}

[[nodiscard]]
Expand Down
10 changes: 8 additions & 2 deletions include/stdexec/__detail/__completion_behavior.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -134,11 +134,17 @@ namespace STDEXEC
struct __common_t
{
template <__behavior... _CSs>
requires(sizeof...(_CSs) > 0)
STDEXEC_ATTRIBUTE(nodiscard, host, device)
constexpr auto operator()(__constant_t<_CSs>... __cbs) const noexcept
{
return (__cbs | ...);
if constexpr (sizeof...(_CSs) == 0)
{
return __completion_behavior::__unknown;
}
else
{
return (__cbs | ...);
}
}
};

Expand Down
Loading
Loading