MySQL  8.0.15
Source Code Documentation
my_compiler.h File Reference

Header for compiler-dependent features. More...

#include <assert.h>
#include <stddef.h>
#include "my_config.h"

Go to the source code of this file.

Classes

struct  my_alignment_imp< alignment >
 C++ Type Traits. More...
 
struct  my_aligned_storage< size, alignment >
 A POD type with a given size and alignment. More...
 

Macros

#define MY_ASSERT_UNREACHABLE()
 
#define MY_ALIGNOF(type)
 
#define MY_ALIGNED(size)
 
#define ALWAYS_INLINE   __attribute__((always_inline)) inline
 
#define NO_INLINE   __attribute__((noinline))
 
#define __has_attribute(x)   0
 
#define SUPPRESS_UBSAN
 
#define SUPPRESS_TSAN
 
#define STDCALL
 

Functions

bool likely (bool expr)
 
bool unlikely (bool expr)
 
template<>
struct MY_ALIGNED (1) my_alignment_imp< 1 >
 
template<>
struct MY_ALIGNED (2) my_alignment_imp< 2 >
 
template<>
struct MY_ALIGNED (4) my_alignment_imp< 4 >
 
template<>
struct MY_ALIGNED (8) my_alignment_imp< 8 >
 
template<>
struct MY_ALIGNED (16) my_alignment_imp< 16 >
 

Detailed Description

Header for compiler-dependent features.

Intended to contain a set of reusable wrappers for preprocessor macros, attributes, pragmas, and any other features that are specific to a target compiler.

Macro Definition Documentation

◆ __has_attribute

#define __has_attribute (   x)    0

◆ ALWAYS_INLINE

#define ALWAYS_INLINE   __attribute__((always_inline)) inline

◆ MY_ALIGNED

#define MY_ALIGNED (   size)

◆ MY_ALIGNOF

#define MY_ALIGNOF (   type)

◆ MY_ASSERT_UNREACHABLE

#define MY_ASSERT_UNREACHABLE ( )
Value:
do { \
assert(0); \
} while (0)

◆ NO_INLINE

#define NO_INLINE   __attribute__((noinline))

◆ STDCALL

#define STDCALL

◆ SUPPRESS_TSAN

#define SUPPRESS_TSAN

◆ SUPPRESS_UBSAN

#define SUPPRESS_UBSAN

Function Documentation

◆ likely()

bool likely ( bool  expr)
inline

◆ MY_ALIGNED() [1/5]

template<>
struct MY_ALIGNED ( 16  )

◆ MY_ALIGNED() [2/5]

template<>
struct MY_ALIGNED ( )

◆ MY_ALIGNED() [3/5]

template<>
struct MY_ALIGNED ( )

◆ MY_ALIGNED() [4/5]

template<>
struct MY_ALIGNED ( )

◆ MY_ALIGNED() [5/5]

template<>
struct MY_ALIGNED ( )

◆ unlikely()

bool unlikely ( bool  expr)
inline