kokkos-execution 0.0.1
Loading...
Searching...
No Matches
Tests::Impl Namespace Reference

Classes

class  CompileTimeOptionalTest_value_Test
 Because we need at least one discoverable runtime test per unit. More...
class  CompletionSignalTest
class  CompletionSignalTest_depend_on_event_policy_Test
class  CompletionSignalTest_inline_fence_exec_policy_Test
class  CompletionSignalTest_order_on_exec_policy_Test
class  CompletionSignalTest_schedule_wait_event_policy_Test
class  CompletionSignaturesTest
class  CompletionSignaturesTest_parallel_for_Test
struct  ConvertibleToString
 A type that is implicitly convertible to a std::string, but is not one. More...
class  DependencyTest
class  DependencyTest_different_type_Test
class  DependencyTest_same_type_Test
class  DispatchLabelTest_deduplicate_Test
class  EventTest
 Fixture that enables callbacks with Kokkos::utils::tests::scoped::callbacks::Manager. More...
class  EventTest_default_instance_Test
class  EventTest_record_and_wait_and_record_and_wait_Test
class  EventTest_record_and_wait_Test
class  EventTest_uniqueness_Test
class  EventTest_wait_exec_event_different_type_Test
class  EventTest_wait_exec_event_for_same_type_Test
class  EventTest_wait_exec_events_for_same_type_Test
class  EventTest_works_intended_usage_pattern_Test
struct  FixedString
 Fixed-capacity string built from a char array. More...
class  FixedStringTest_converts_to_string_view_and_string_Test
class  forwarding_queryable_Test
struct  FwdPropC
class  get_property_label_Test
class  is_useless_Test
 Because we need at least one discoverable runtime test per unit. More...
class  LabelTest_static_label_Test
struct  MakePolicyTest
class  MakePolicyTest_execution_space_instance_Test
struct  PropA
struct  Receiver
class  RecordEvent_description_Test
struct  SomeTrait
struct  SomeTraitWithComplexDiagnose
struct  Tag
struct  TestType
class  WaitEvent_description_Test

Typedefs

using disabled_t = Kokkos::Execution::Impl::CompileTimeOptional<false, TestType>
using enabled_t = Kokkos::Execution::Impl::CompileTimeOptional<true, TestType>
using sndr_t
using env_with_stop_token_t = stdexec::prop<stdexec::get_stop_token_t, stdexec::inplace_stop_token>
using trait_ok_t = SomeTrait<int>
using trait_ko_A_t = SomeTrait<std::string>
using trait_ko_B_t = SomeTrait<std::string_view>
using diagnose_ok_t = Kokkos::Execution::Impl::diagnose_t<trait_ok_t>
using diagnose_ko_A_t = Kokkos::Execution::Impl::diagnose_t<trait_ko_A_t>
using diagnose_ko_B_t = Kokkos::Execution::Impl::diagnose_t<trait_ko_B_t>
using diagnose_ok_ok_t = Kokkos::Execution::Impl::diagnose_t<trait_ok_t, trait_ok_t>
using diagnose_ok_ko_A_t = Kokkos::Execution::Impl::diagnose_t<trait_ok_t, trait_ko_A_t>
using diagnose_ko_A_ko_B_t = Kokkos::Execution::Impl::diagnose_t<trait_ko_A_t, trait_ko_B_t>

Functions

consteval bool test_disabled_is_empty_and_trivially_copyable ()
consteval bool test_size_of_enabled ()
consteval bool test_constructible ()
consteval bool test_completion_signal_traits ()
consteval bool test_add_nothing_empty_env ()
consteval bool test_add_error_empty_env ()
consteval bool test_add_nothing_stop_env ()
consteval bool test_add_error_stop_env ()
consteval bool test_diagnose_t_single ()
consteval bool test_diagnose_t_many ()
consteval bool test_first_error_t ()
consteval bool test_keep_errors_t ()
consteval bool test_mandate_or_explain ()
consteval bool test_rebind_t ()
consteval bool test_collapse_t ()
consteval bool test_dispatch_label_v ()
consteval bool test_dispatch_label ()
consteval bool test_dispatch_label_noexcept ()
template<Kokkos::ExecutionSpace Exec>
consteval bool test_models_event ()
template<Kokkos::ExecutionSpace Exec>
consteval bool test_has_exec_wait_event ()
consteval bool test_FixedString_is_fixed_string ()
consteval bool test_FixedString_deduces_capacity_from_literal ()
template<size_t Size>
consteval bool test_FixedString_layout ()
consteval bool test_FixedString_is_constructible_from_matching_char_array_only ()
consteval bool test_FixedString_from_literal ()
consteval bool test_FixedString_from_empty_literal ()
consteval bool test_view_is_noexcept ()
consteval bool test_FixedString_is_usable_as_a_template_parameter ()
consteval bool test_label ()
consteval bool test_label_ctad ()
consteval bool test_labeled ()
consteval bool test_static_label ()
consteval bool test_as_convertible_to_string_std_string ()
consteval bool test_as_convertible_to_string_convertible ()
consteval bool test_as_convertible_to_string_not_convertible_will_materialize ()
consteval bool test_make_policy_result_t ()
consteval bool test_make_policy_noexceptness ()
consteval bool test_has_property ()
consteval bool test_get_property ()

Variables

constexpr char suffix [] = " with the given suffix"
constexpr std::string_view label_of_exec = Kokkos::Execution::Impl::display_string_of<TEST_EXECUTION_SPACE>()
constexpr std::string_view label_as_view = Kokkos::Execution::Impl::dispatch_label< TEST_EXECUTION_SPACE, suffix>()
constexpr std::string_view view_a = Kokkos::Execution::Impl::dispatch_label< TEST_EXECUTION_SPACE, suffix>()
constexpr std::string_view view_b = Kokkos::Execution::Impl::dispatch_label< TEST_EXECUTION_SPACE, suffix>()
Tests::Impl::PropA prop_a
Tests::Impl::FwdPropC fwd_prop_c
constinit const auto constinit_label = Kokkos::Execution::label("my label")
 constinit requires static initialization.

Typedef Documentation

◆ diagnose_ko_A_ko_B_t

◆ diagnose_ko_A_t

◆ diagnose_ko_B_t

◆ diagnose_ok_ko_A_t

◆ diagnose_ok_ok_t

◆ diagnose_ok_t

◆ disabled_t

◆ enabled_t

◆ env_with_stop_token_t

using Tests::Impl::env_with_stop_token_t = stdexec::prop<stdexec::get_stop_token_t, stdexec::inplace_stop_token>

Definition at line 58 of file test_completion_signatures.cpp.

◆ sndr_t

Initial value:
decltype(stdexec::schedule(std::declval<experimental::execution::single_thread_context>().get_scheduler()) | stdexec::then([]() noexcept {
}))

Definition at line 28 of file test_completion_signatures.cpp.

◆ trait_ko_A_t

using Tests::Impl::trait_ko_A_t = SomeTrait<std::string>

Definition at line 33 of file test_diagnostics.cpp.

◆ trait_ko_B_t

using Tests::Impl::trait_ko_B_t = SomeTrait<std::string_view>

Definition at line 34 of file test_diagnostics.cpp.

◆ trait_ok_t

Definition at line 32 of file test_diagnostics.cpp.

Function Documentation

◆ test_add_error_empty_env()

bool Tests::Impl::test_add_error_empty_env ( )
consteval
Test
Check return type of Kokkos::Execution::Impl::completion_signatures_add with an added error completion signature and an empty environment.

Definition at line 44 of file test_completion_signatures.cpp.

References Kokkos::Execution::Impl::completion_signatures_add(), and test_add_error_empty_env().

◆ test_add_error_stop_env()

bool Tests::Impl::test_add_error_stop_env ( )
consteval

◆ test_add_nothing_empty_env()

bool Tests::Impl::test_add_nothing_empty_env ( )
consteval
Test
Check return type of Kokkos::Execution::Impl::completion_signatures_add without added completion signature and an empty environment.

Definition at line 33 of file test_completion_signatures.cpp.

References Kokkos::Execution::Impl::completion_signatures_add(), and test_add_nothing_empty_env().

◆ test_add_nothing_stop_env()

bool Tests::Impl::test_add_nothing_stop_env ( )
consteval

◆ test_as_convertible_to_string_convertible()

bool Tests::Impl::test_as_convertible_to_string_convertible ( )
consteval

◆ test_as_convertible_to_string_not_convertible_will_materialize()

bool Tests::Impl::test_as_convertible_to_string_not_convertible_will_materialize ( )
consteval

◆ test_as_convertible_to_string_std_string()

bool Tests::Impl::test_as_convertible_to_string_std_string ( )
consteval

◆ test_collapse_t()

bool Tests::Impl::test_collapse_t ( )
consteval
Test
Check that Kokkos::Execution::Impl::collapse_t works as expected.

Definition at line 159 of file test_diagnostics.cpp.

References test_collapse_t().

◆ test_completion_signal_traits()

bool Tests::Impl::test_completion_signal_traits ( )
consteval
Test
Check the size of Kokkos::Execution::Impl::CompletionSignal.

The size is larger than the sum of the sizes of the members because of padding.

Definition at line 62 of file test_completion_signal.cpp.

References test_completion_signal_traits().

◆ test_constructible()

bool Tests::Impl::test_constructible ( )
consteval
Test
Both enabled and disabled versions are constructible from the same arguments as their value type.

Definition at line 44 of file test_compile_time_optional.cpp.

References test_constructible().

◆ test_diagnose_t_many()

bool Tests::Impl::test_diagnose_t_many ( )
consteval
Test
Check that Kokkos::Execution::Impl::diagnose_t works as expected when given many types.
Warning
A stdexec::__mlist is not an error, even when it contains errors.

Definition at line 59 of file test_diagnostics.cpp.

References test_diagnose_t_many().

◆ test_diagnose_t_single()

bool Tests::Impl::test_diagnose_t_single ( )
consteval
Test
Check that Kokkos::Execution::Impl::diagnose_t works as expected when given a single type.

Definition at line 44 of file test_diagnostics.cpp.

References test_diagnose_t_single().

◆ test_disabled_is_empty_and_trivially_copyable()

bool Tests::Impl::test_disabled_is_empty_and_trivially_copyable ( )
consteval
Test
A disabled Kokkos::Execution::Impl::CompileTimeOptional is empty and trivially copyable.

Definition at line 30 of file test_compile_time_optional.cpp.

References test_disabled_is_empty_and_trivially_copyable().

◆ test_dispatch_label()

bool Tests::Impl::test_dispatch_label ( )
consteval

◆ test_dispatch_label_noexcept()

bool Tests::Impl::test_dispatch_label_noexcept ( )
consteval

◆ test_dispatch_label_v()

bool Tests::Impl::test_dispatch_label_v ( )
consteval

◆ test_first_error_t()

bool Tests::Impl::test_first_error_t ( )
consteval
Test
Check that Kokkos::Execution::Impl::first_error_t works as expected.

Definition at line 79 of file test_diagnostics.cpp.

References test_first_error_t().

◆ test_FixedString_deduces_capacity_from_literal()

bool Tests::Impl::test_FixedString_deduces_capacity_from_literal ( )
consteval
Test
Check that Kokkos::Execution::Impl::FixedString properly deduces its capacity from the input literal.

Definition at line 34 of file test_fixed_string.cpp.

References test_FixedString_deduces_capacity_from_literal().

◆ test_FixedString_from_empty_literal()

◆ test_FixedString_from_literal()

bool Tests::Impl::test_FixedString_from_literal ( )
consteval

◆ test_FixedString_is_constructible_from_matching_char_array_only()

bool Tests::Impl::test_FixedString_is_constructible_from_matching_char_array_only ( )
consteval
Test
Check how Kokkos::Execution::Impl::FixedString can be constructed.

It cannot be constructed from a mismatch-in-size array.

It cannot be constructed from a char pointer.

Definition at line 59 of file test_fixed_string.cpp.

References test_FixedString_is_constructible_from_matching_char_array_only().

◆ test_FixedString_is_fixed_string()

bool Tests::Impl::test_FixedString_is_fixed_string ( )
consteval

◆ test_FixedString_is_usable_as_a_template_parameter()

bool Tests::Impl::test_FixedString_is_usable_as_a_template_parameter ( )
consteval
Test
Check that Kokkos::Execution::Impl::FixedString can be used as a template parameter.

Definition at line 133 of file test_fixed_string.cpp.

References test_FixedString_is_usable_as_a_template_parameter().

◆ test_FixedString_layout()

template<size_t Size>
bool Tests::Impl::test_FixedString_layout ( )
consteval
Test
Check the layout of Kokkos::Execution::Impl::FixedString.

Definition at line 47 of file test_fixed_string.cpp.

References test_FixedString_layout().

◆ test_get_property()

bool Tests::Impl::test_get_property ( )
consteval
Test
Check that Kokkos::Execution::Impl::get_property works as expected.

A non-template type property.

A template type property.

Definition at line 57 of file test_properties.cpp.

References Kokkos::Execution::Impl::get_property(), TEST_GET_PROPERTY, and test_get_property().

◆ test_has_exec_wait_event()

template<Kokkos::ExecutionSpace Exec>
bool Tests::Impl::test_has_exec_wait_event ( )
consteval

◆ test_has_property()

bool Tests::Impl::test_has_property ( )
consteval
Test
Check that Kokkos::Execution::Impl::has_property works as expected.

Definition at line 22 of file test_properties.cpp.

References Kokkos::Execution::Impl::has_property(), and test_has_property().

◆ test_keep_errors_t()

bool Tests::Impl::test_keep_errors_t ( )
consteval
Test
Check that Kokkos::Execution::Impl::keep_errors_t works as expected.

Definition at line 97 of file test_diagnostics.cpp.

References test_keep_errors_t().

◆ test_label()

bool Tests::Impl::test_label ( )
consteval
Test
Check that Kokkos::Execution::Impl::label works as expected.

Definition at line 21 of file test_label.cpp.

References test_label().

◆ test_label_ctad()

bool Tests::Impl::test_label_ctad ( )
consteval
Test
Check that Kokkos::Execution::Impl::Label CTAD works as expected.

Any convertible-to std::string type maps to Kokkos::Execution::Impl::Label<std::string>.

Definition at line 40 of file test_label.cpp.

References test_label_ctad().

◆ test_labeled()

bool Tests::Impl::test_labeled ( )
consteval
Test
Check that Kokkos::Execution::Impl::labeled works as expected.

Definition at line 64 of file test_label.cpp.

References test_labeled().

◆ test_make_policy_noexceptness()

bool Tests::Impl::test_make_policy_noexceptness ( )
consteval

Definition at line 68 of file test_make_policy.cpp.

References test_make_policy_noexceptness().

◆ test_make_policy_result_t()

bool Tests::Impl::test_make_policy_result_t ( )
consteval

Definition at line 24 of file test_make_policy.cpp.

References test_make_policy_result_t().

◆ test_mandate_or_explain()

bool Tests::Impl::test_mandate_or_explain ( )
consteval
Test
Check that Kokkos::Execution::Impl::mandate_or_explain works as expected.
Note
We cannot check the cases where it fires, since it would generate a compile error.

When T::value is true, it succeeds.

When T::value is false but T has no diagnose, it does not fail on the static_assert and returns false.

When T::value is true, the T::diagnose is not instantiated, see also https://eel.is/c++draft/stmt.if#2.

Definition at line 129 of file test_diagnostics.cpp.

References Kokkos::Execution::Impl::mandate_or_explain(), and test_mandate_or_explain().

◆ test_models_event()

template<Kokkos::ExecutionSpace Exec>
bool Tests::Impl::test_models_event ( )
consteval
Test
Check that Kokkos::Execution::Impl::Event satisfies Kokkos::Execution::Impl::event.

Definition at line 49 of file test_event.cpp.

References test_models_event().

◆ test_rebind_t()

bool Tests::Impl::test_rebind_t ( )
consteval
Test
Check that Kokkos::Execution::Impl::rebind_t works as expected.

Definition at line 146 of file test_diagnostics.cpp.

References test_rebind_t().

◆ test_size_of_enabled()

bool Tests::Impl::test_size_of_enabled ( )
consteval
Test
The size of an enabled Kokkos::Execution::Impl::CompileTimeOptional is equal to the size of its value type.

Definition at line 37 of file test_compile_time_optional.cpp.

References test_size_of_enabled().

◆ test_static_label()

bool Tests::Impl::test_static_label ( )
consteval
Test
Check that Kokkos::Execution::label works as expected.

Definition at line 81 of file test_label.cpp.

References Kokkos::Execution::label(), and test_static_label().

◆ test_view_is_noexcept()

bool Tests::Impl::test_view_is_noexcept ( )
consteval
Test
Check whether Kokkos::Execution::Impl::FixedString::view is noexcept or not.

The standard does not specify that the std::string_view constructor from a pointer and a size is noexcept. Yet, implementers generally mark it noexcept.

Definition at line 105 of file test_fixed_string.cpp.

References test_view_is_noexcept(), and Kokkos::Execution::Impl::FixedString< N >::view().

Variable Documentation

◆ constinit_label

const auto Tests::Impl::constinit_label = Kokkos::Execution::label("my label")
constinit

constinit requires static initialization.

Definition at line 78 of file test_label.cpp.

◆ fwd_prop_c

Tests::Impl::FwdPropC Tests::Impl::fwd_prop_c

◆ label_as_view

std::string_view Tests::Impl::label_as_view = Kokkos::Execution::Impl::dispatch_label< TEST_EXECUTION_SPACE, suffix>()
constexpr

Definition at line 23 of file test_dispatch_label.cpp.

◆ label_of_exec

std::string_view Tests::Impl::label_of_exec = Kokkos::Execution::Impl::display_string_of<TEST_EXECUTION_SPACE>()
constexpr

Definition at line 21 of file test_dispatch_label.cpp.

◆ prop_a

Tests::Impl::PropA Tests::Impl::prop_a

◆ suffix

char Tests::Impl::suffix[] = " with the given suffix"
constexpr

Definition at line 19 of file test_dispatch_label.cpp.

◆ view_a

std::string_view Tests::Impl::view_a = Kokkos::Execution::Impl::dispatch_label< TEST_EXECUTION_SPACE, suffix>()
constexpr

Definition at line 62 of file test_dispatch_label.cpp.

◆ view_b

std::string_view Tests::Impl::view_b = Kokkos::Execution::Impl::dispatch_label< TEST_EXECUTION_SPACE, suffix>()
constexpr

Definition at line 63 of file test_dispatch_label.cpp.