Skip to content

Commit

Permalink
Merge pull request #297 from devreal/consolidate_make_tt_tpl
Browse files Browse the repository at this point in the history
Consolidate make_tt_tpl and make_tt
  • Loading branch information
evaleev authored Nov 1, 2024
2 parents 7fb4027 + 19c23c4 commit 2ec6982
Show file tree
Hide file tree
Showing 6 changed files with 208 additions and 207 deletions.
12 changes: 8 additions & 4 deletions examples/madness/mrattg.cc
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,8 @@ namespace detail {
using compress_out_type = std::tuple<Rout, Rout, cnodeOut<T, K, 1>>;
using compress_in_type = std::tuple<Rin, Rin>;
template <typename compfuncT>
using compwrap_type = ttg::CallableWrapTT<compfuncT, true, Key<1>, compress_out_type, Rin, Rin>;
using compwrap_type = ttg::CallableWrapTT<compfuncT, void, true, true, ttg::ExecutionSpace::Host,
Key<1>, compress_out_type, Rin, Rin>;
};

template <typename T, size_t K>
Expand All @@ -187,7 +188,8 @@ namespace detail {
using compress_out_type = std::tuple<Rout, Rout, Rout, Rout, cnodeOut<T, K, 2>>;
using compress_in_type = std::tuple<Rin, Rin, Rin, Rin>;
template <typename compfuncT>
using compwrap_type = ttg::CallableWrapTT<compfuncT, true, Key<2>, compress_out_type, Rin, Rin, Rin, Rin>;
using compwrap_type = ttg::CallableWrapTT<compfuncT, void, true, true, ttg::ExecutionSpace::Host,
Key<2>, compress_out_type, Rin, Rin, Rin, Rin>;
};

template <typename T, size_t K>
Expand All @@ -198,7 +200,8 @@ namespace detail {
using compress_in_type = std::tuple<Rin, Rin, Rin, Rin, Rin, Rin, Rin, Rin>;
template <typename compfuncT>
using compwrap_type =
ttg::CallableWrapTT<compfuncT, true, Key<3>, compress_out_type, Rin, Rin, Rin, Rin, Rin, Rin, Rin, Rin>;
ttg::CallableWrapTT<compfuncT, void, true, true, ttg::ExecutionSpace::Host,
Key<3>, compress_out_type, Rin, Rin, Rin, Rin, Rin, Rin, Rin, Rin>;
};
}; // namespace detail

Expand Down Expand Up @@ -277,7 +280,8 @@ auto make_compress(rnodeEdge<T, K, NDIM>& in, cnodeEdge<T, K, NDIM>& out, const

using sendfuncT = decltype(&send_leaves_up<T, K, NDIM>);
using sendwrapT =
ttg::CallableWrapTT<sendfuncT, true, Key<NDIM>, typename ::detail::tree_types<T, K, NDIM>::compress_out_type,
ttg::CallableWrapTT<sendfuncT, void, true, true, ttg::ExecutionSpace::Host,
Key<NDIM>, typename ::detail::tree_types<T, K, NDIM>::compress_out_type,
FunctionReconstructedNode<T, K, NDIM>>;
using compfuncT = decltype(&do_compress<T, K, NDIM>);
using compwrapT = typename ::detail::tree_types<T, K, NDIM>::template compwrap_type<compfuncT>;
Expand Down
1 change: 1 addition & 0 deletions ttg/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ set(ttg-util-headers
${CMAKE_CURRENT_SOURCE_DIR}/ttg/util/meta.h
${CMAKE_CURRENT_SOURCE_DIR}/ttg/util/meta/callable.h
${CMAKE_CURRENT_SOURCE_DIR}/ttg/util/print.h
${CMAKE_CURRENT_SOURCE_DIR}/ttg/util/scope_exit.h
${CMAKE_CURRENT_SOURCE_DIR}/ttg/util/span.h
${CMAKE_CURRENT_SOURCE_DIR}/ttg/util/trace.h
${CMAKE_CURRENT_SOURCE_DIR}/ttg/util/tree.h
Expand Down
1 change: 1 addition & 0 deletions ttg/ttg/madness/ttg.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
#include "ttg/util/macro.h"
#include "ttg/util/meta.h"
#include "ttg/util/meta/callable.h"
#include "ttg/util/scope_exit.h"
#include "ttg/util/void.h"
#include "ttg/world.h"
#include "ttg/coroutine.h"
Expand Down
Loading

0 comments on commit 2ec6982

Please sign in to comment.