MySQL 8.4.2
Source Code Documentation
PFS_cacheline_atomic_ptr< T > Struct Template Reference

An atomic<T> variable, guaranteed to be alone in a CPU cache line. More...

#include <pfs_global.h>

Public Member Functions

 PFS_cacheline_atomic_ptr ()
 

Public Attributes

std::atomic< T > m_ptr
 
char m_full_cache_line [PFS_CACHE_LINE_SIZE - sizeof(std::atomic< T >)]
 

Detailed Description

template<class T>
struct PFS_cacheline_atomic_ptr< T >

An atomic<T> variable, guaranteed to be alone in a CPU cache line.

This is for performance, for variables accessed very frequently.

Constructor & Destructor Documentation

◆ PFS_cacheline_atomic_ptr()

template<class T >
PFS_cacheline_atomic_ptr< T >::PFS_cacheline_atomic_ptr ( )
inline

Member Data Documentation

◆ m_full_cache_line

template<class T >
char PFS_cacheline_atomic_ptr< T >::m_full_cache_line[PFS_CACHE_LINE_SIZE - sizeof(std::atomic< T >)]

◆ m_ptr

template<class T >
std::atomic<T> PFS_cacheline_atomic_ptr< T >::m_ptr

The documentation for this struct was generated from the following file: