atomic.h File Reference
This file contains an implementation of the atomic class as described in the SYCL specification. More...
#include <algorithm>
#include <atomic>
#include <type_traits>
#include "memory_scope.h"
#include "multi_pointer.h"
Go to the source code of this file.
Classes | |
struct | cl::sycl::atomic< T, addressSpace > |
Atomic class template. More... | |
struct | cl::sycl::device_type< elemT, addressSpace > |
struct | cl::sycl::atomic< T, addressSpace > |
Atomic class template. More... | |
Namespaces | |
cl | |
deduce_type_t takes an arbitrary type and attempts to map it to a cl::sycl::cl_type . | |
cl::sycl | |
Typedefs | |
using | cl::sycl::atomic_int = atomic< cl_int > |
Atomic int object with default global address space. More... | |
using | cl::sycl::atomic_uint = atomic< cl_uint > |
Atomic unsigned int object with default global address space. More... | |
using | cl::sycl::atomic_float = atomic< cl_float > |
Atomic float object with default global address space. More... | |
Enumerations | |
enum | cl::sycl::memory_order : int { cl::sycl::memory_order::relaxed = static_cast<int>(std::memory_order_relaxed) } |
Only relaxed memory order is supported in SYCL 1.2.1. More... | |
Functions | |
template<typename T , access::address_space addressSpace> | |
T | cl::sycl::atomic_load (atomic< T, addressSpace > object, memory_order mem_order=memory_order::relaxed) |
Global function atomic_load. More... | |
template<typename T , access::address_space addressSpace> | |
void | cl::sycl::atomic_store (atomic< T, addressSpace > object, T operand, memory_order mem_order=memory_order::relaxed) |
Global function atomic_store. More... | |
template<typename T , access::address_space addressSpace> | |
T | cl::sycl::atomic_exchange (atomic< T, addressSpace > object, T operand, memory_order mem_order=memory_order::relaxed) |
Global function atomic_exchange. More... | |
template<typename T , access::address_space addressSpace> | |
cl_bool | cl::sycl::atomic_compare_exchange_strong (atomic< T, addressSpace > object, T &expected, T desired, memory_order success=memory_order::relaxed, memory_order fail=memory_order::relaxed) |
Global function atomic_compare_exchange. More... | |
template<typename T , access::address_space addressSpace> | |
T | cl::sycl::atomic_fetch_add (atomic< T, addressSpace > object, T operand, memory_order mem_order=memory_order::relaxed) |
Global function atomic_add. More... | |
template<typename T , access::address_space addressSpace> | |
T | cl::sycl::atomic_fetch_sub (atomic< T, addressSpace > object, T operand, memory_order mem_order=memory_order::relaxed) |
Global function atomic_sub. More... | |
template<typename T , access::address_space addressSpace> | |
T | cl::sycl::atomic_fetch_and (atomic< T, addressSpace > object, T operand, memory_order mem_order=memory_order::relaxed) |
Global function atomic_and. More... | |
template<typename T , access::address_space addressSpace> | |
T | cl::sycl::atomic_fetch_or (atomic< T, addressSpace > object, T operand, memory_order mem_order=memory_order::relaxed) |
Global function atomic_or. More... | |
template<typename T , access::address_space addressSpace> | |
T | cl::sycl::atomic_fetch_xor (atomic< T, addressSpace > object, T operand, memory_order mem_order=memory_order::relaxed) |
Global function atomic_xor. More... | |
template<typename T , access::address_space addressSpace> | |
T | cl::sycl::atomic_fetch_min (atomic< T, addressSpace > object, T operand, memory_order mem_order=memory_order::relaxed) |
Global function atomic_min. More... | |
template<typename T , access::address_space addressSpace> | |
T | cl::sycl::atomic_fetch_max (atomic< T, addressSpace > object, T operand, memory_order mem_order=memory_order::relaxed) |
Global function atomic_max. More... | |
Detailed Description
This file contains an implementation of the atomic class as described in the SYCL specification.
Definition in file atomic.h.