1#ifndef KOKKOS_EXECUTION_TESTS_UTILS_FUNCTORS_COUNTER_HPP
2#define KOKKOS_EXECUTION_TESTS_UTILS_FUNCTORS_COUNTER_HPP
4#include "Kokkos_Core.hpp"
17 static inline std::atomic<unsigned int>
next_id{0};
22 :
id(
next_id.fetch_add(1, std::memory_order_relaxed)) {
31 :
id(
next_id.fetch_add(1, std::memory_order_relaxed)) {
41 :
id(
next_id.fetch_add(1, std::memory_order_relaxed)) {
50 template <
typename... Args>
51 KOKKOS_FUNCTION
void operator()(Args&&...) const noexcept {
static std::atomic< unsigned int > move_assignments
static std::atomic< unsigned int > copy_constructions
Counter & operator=(Counter &&) noexcept
static std::atomic< unsigned int > destructions
void operator()(Args &&...) const noexcept
Counter(Counter &&) noexcept
static std::atomic< unsigned int > next_id
static std::atomic< unsigned int > default_constructions
static std::atomic< unsigned int > move_constructions
static std::atomic< unsigned int > copy_assignments
Counter & operator=(const Counter &) noexcept
Counter(const Counter &) noexcept