MCPcopy Create free account
hub / github.com/Tencent/hpc-ops / find_if

Function find_if

3rd/cutlass/include/cute/algorithm/tuple_algorithms.hpp:282–293  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

280
281template <class T, class F>
282CUTE_HOST_DEVICE constexpr
283auto
284find_if(T const& t, F&& f)
285{
286 if constexpr (is_tuple<T>::value) {
287 return detail::tapply(t, f, [] (auto... a) { return cute::C<find_true_v<decltype(a)::value...>>{}; }, tuple_seq<T>{});
288 } else {
289 return cute::C<decltype(f(t))::value ? 0 : 1>{};
290 }
291
292 CUTE_GCC_UNREACHABLE;
293}
294
295template <class T, class X>
296CUTE_HOST_DEVICE constexpr

Callers 4

make_tma_atom_im2colFunction · 0.85
construct_tma_gbasisFunction · 0.85
make_tma_copy_descFunction · 0.85
findFunction · 0.85

Calls 2

tapplyFunction · 0.85
fFunction · 0.85

Tested by

no test coverage detected