c预处理器

Function attributes - Align and inline

Note: Use MSVC to interpret alignment and inline.

Default

#ifndef _FX
#define _FX       // ALIGNED NOINLINE
#endif

aligned

  • vs2013
#ifndef ALIGNED
#define __declspec(align(16))
#endif
  • vs2015+
#ifndef ALIGNED
#define alignas(16)
#endif

Noline

#ifndef NOINLINE
#define NOINLINE  __declspec(noinline)
#endif

Ref