Skip to content
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

Hotfixes for device execution #310

Merged
merged 3 commits into from
Nov 25, 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
6 changes: 2 additions & 4 deletions ttg/ttg/device/task.h
Original file line number Diff line number Diff line change
Expand Up @@ -244,8 +244,7 @@ namespace ttg::device {
}


template <std::size_t i, typename valueT, typename... out_keysT, typename... out_valuesT,
ttg::Runtime Runtime = ttg::ttg_runtime>
template <std::size_t i, typename valueT, ttg::Runtime Runtime = ttg::ttg_runtime>
inline detail::send_t sendv(valueT &&value) {
return sendv(i, std::forward<valueT>(value));
}
Expand Down Expand Up @@ -283,8 +282,7 @@ namespace ttg::device {
}
}

template <size_t KeyId, size_t I, size_t... Is, typename... RangesT, typename valueT,
typename... out_keysT, typename... out_valuesT>
template <size_t KeyId, size_t I, size_t... Is, typename... RangesT, typename valueT>
inline void prepare_broadcast(const std::tuple<RangesT...> &keylists, valueT &&value) {
using key_t = typename broadcast_keylist_trait<
std::tuple_element_t<KeyId, std::tuple<std::remove_reference_t<RangesT>...>>
Expand Down
3 changes: 2 additions & 1 deletion ttg/ttg/parsec/ttg.h
Original file line number Diff line number Diff line change
Expand Up @@ -1507,7 +1507,7 @@ namespace ttg_parsec {
PARSEC_OBJ_CONSTRUCT(gpu_task, parsec_list_item_t);
gpu_task->ec = parsec_task;
gpu_task->task_type = 0; // user task
gpu_task->last_data_check_epoch = 0; // used internally
gpu_task->last_data_check_epoch = std::numeric_limits<uint64_t>::max(); // used internally
gpu_task->pushout = 0;
gpu_task->submit = &TT::device_static_submit<Space>;

Expand Down Expand Up @@ -3837,6 +3837,7 @@ namespace ttg_parsec {
task->tt->set_outputs_tls_ptr(old_output_tls_ptr);
detail::parsec_ttg_caller = nullptr;
}
dev_task.destroy(); // safe to destroy the coroutine now
}
#endif // TTG_HAVE_DEVICE
/* the coroutine should have completed and we cannot access the promise anymore */
Expand Down
Loading