#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#ifndef THIRD_PARTY_BLINK_RENDERER_PLATFORM_WTF_ATOMIC_OPERATIONS_H_
#define THIRD_PARTY_BLINK_RENDERER_PLATFORM_WTF_ATOMIC_OPERATIONS_H_
#include <atomic>
#include <cstddef>
#include <type_traits>
#include "base/check_op.h"
#include "base/compiler_specific.h"
#include "build/build_config.h"
#include "third_party/blink/renderer/platform/wtf/wtf_export.h"
namespace WTF {
template <typename T>
ALWAYS_INLINE std::atomic<T>* AsAtomicPtr(T* t) { … }
template <typename T>
ALWAYS_INLINE const std::atomic<T>* AsAtomicPtr(const T* t) { … }
WTF_EXPORT void AtomicReadMemcpy(void* to, const void* from, size_t bytes);
namespace internal {
template <size_t bytes, typename AlignmentType>
ALWAYS_INLINE void AtomicReadMemcpyAligned(void* to, const void* from) { … }
}
template <size_t bytes, size_t alignment>
ALWAYS_INLINE void AtomicReadMemcpy(void* to, const void* from) { … }
WTF_EXPORT void AtomicWriteMemcpy(void* to, const void* from, size_t bytes);
namespace internal {
template <size_t bytes, typename AlignmentType>
ALWAYS_INLINE void AtomicWriteMemcpyAligned(void* to, const void* from) { … }
}
template <size_t bytes, size_t alignment>
ALWAYS_INLINE void AtomicWriteMemcpy(void* to, const void* from) { … }
WTF_EXPORT void AtomicMemzero(void* buf, size_t bytes);
namespace internal {
template <size_t bytes, typename AlignmentType>
ALWAYS_INLINE void AtomicMemzeroAligned(void* buf) { … }
}
template <size_t bytes, size_t alignment>
ALWAYS_INLINE void AtomicMemzero(void* buf) { … }
template <typename T>
ALWAYS_INLINE void AtomicWriteSwap(T& lhs, T& rhs) { … }
}
#endif