kokkos-utils 0.0.1
 
Loading...
Searching...
No Matches
Helpers.hpp File Reference
#include "gmock/gmock.h"
#include "kokkos-utils/callbacks/Manager.hpp"

Go to the source code of this file.

Classes

class  Kokkos::utils::callbacks::ManagerTestFixture
 
class  Kokkos::utils::callbacks::impl::ContainsInOrderMatcher< T, Matchers >
 

Namespaces

namespace  Kokkos
 
namespace  Kokkos::utils
 
namespace  Kokkos::utils::callbacks
 
namespace  Kokkos::utils::callbacks::impl
 

Macros

#define TEST_F_WITH_CB_MGR(__test_fixture_name__, __test_name__)
 
#define DEFINE_EVENT_MATCHER(__eventtype__)
 
#define DEFINE_EVENT_WITH_NAME_MATCHER(__eventtype__)
 

Functions

template<typename... Matchers>
auto Kokkos::utils::callbacks::ABeginParallelForEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::AEndParallelForEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::ABeginParallelReduceEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::AEndParallelReduceEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::ABeginParallelScanEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::AEndParallelScanEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::ABeginFenceEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::AEndFenceEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::AAllocateDataEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::ADeallocateDataEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::ACreateProfileSectionEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::ADestroyProfileSectionEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::AStartProfileSectionEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::AStopProfileSectionEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::APushRegionEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::APopRegionEvent (Matchers &&... matchers)
 
template<typename... Matchers>
auto Kokkos::utils::callbacks::AProfileEvent (Matchers &&... matchers)
 
template<typename Matcher>
auto Kokkos::utils::callbacks::ABeginParallelForEventWithName (Matcher &&matcher)
 
template<typename Matcher>
auto Kokkos::utils::callbacks::ABeginParallelReduceEventWithName (Matcher &&matcher)
 
template<typename Matcher>
auto Kokkos::utils::callbacks::ABeginParallelScanEventWithName (Matcher &&matcher)
 
template<typename Matcher>
auto Kokkos::utils::callbacks::ABeginFenceEventWithName (Matcher &&matcher)
 
template<typename Matcher>
auto Kokkos::utils::callbacks::ACreateProfileSectionEventWithName (Matcher &&matcher)
 
template<typename Matcher>
auto Kokkos::utils::callbacks::APushRegionEventWithName (Matcher &&matcher)
 
template<typename Matcher>
auto Kokkos::utils::callbacks::AProfileEventWithName (Matcher &&matcher)
 
template<typename T, typename... Matchers>
auto Kokkos::utils::callbacks::ContainsInOrder (Matchers &&... matchers)
 

Macro Definition Documentation

◆ DEFINE_EVENT_MATCHER

#define DEFINE_EVENT_MATCHER ( __eventtype__)
Value:
template <typename... Matchers> \
auto A##__eventtype__(Matchers&&... matchers) \
{ \
using EventType = Kokkos::utils::callbacks::__eventtype__; \
if constexpr (sizeof...(Matchers) == 0) \
return ::testing::VariantWith<EventType>(::testing::_); \
else \
return ::testing::VariantWith<EventType>(::testing::AllOf(std::forward<Matchers>(matchers)...)); \
}

Definition at line 22 of file Helpers.hpp.

◆ DEFINE_EVENT_WITH_NAME_MATCHER

#define DEFINE_EVENT_WITH_NAME_MATCHER ( __eventtype__)
Value:
template <typename Matcher> \
auto A##__eventtype__##WithName(Matcher&& matcher) \
{ \
using EventType = Kokkos::utils::callbacks::__eventtype__; \
return ::testing::VariantWith<EventType>(::testing::Field(&EventType::name, std::forward<Matcher>(matcher))); \
}

Definition at line 51 of file Helpers.hpp.

◆ TEST_F_WITH_CB_MGR

#define TEST_F_WITH_CB_MGR ( __test_fixture_name__,
__test_name__ )
Value:
class __test_fixture_name__ : public ManagerTestFixture {}; \
TEST_F(__test_fixture_name__, __test_name__)

Definition at line 18 of file Helpers.hpp.