Line data Source code
1 1 : // Distributed under the MIT License.
2 : // See LICENSE.txt for details.
3 :
4 : /// \file
5 : /// Defines macro to always inline a function.
6 :
7 : #pragma once
8 :
9 : #if SPECTRE_USE_ALWAYS_INLINE && defined(__GNUC__)
10 : /// \ingroup UtilitiesGroup
11 : /// Always inline a function. Only use this if you benchmarked the code.
12 : #define SPECTRE_ALWAYS_INLINE __attribute__((always_inline)) inline
13 : #else
14 : /// \ingroup UtilitiesGroup
15 : /// Always inline a function. Only use this if you benchmarked the code.
16 1 : #define SPECTRE_ALWAYS_INLINE inline
17 : #endif
|