From 75e4f35abe8bac10fed18d3c4849680b759e3beb Mon Sep 17 00:00:00 2001 From: rationalcoder Date: Sat, 19 Aug 2017 22:08:27 -0500 Subject: [PATCH] Added EASY_FORCE_INLINE --- .../include/easy/easy_compiler_support.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/easy_profiler_core/include/easy/easy_compiler_support.h b/easy_profiler_core/include/easy/easy_compiler_support.h index db2ade0..41b667e 100644 --- a/easy_profiler_core/include/easy/easy_compiler_support.h +++ b/easy_profiler_core/include/easy/easy_compiler_support.h @@ -82,6 +82,8 @@ VarName = VarInitializer # endif +#define EASY_FORCE_INLINE __forceinline + #elif defined (__clang__) ////////////////////////////////////////////////////////////////////////// // Clang Compiler @@ -102,6 +104,8 @@ # define EASY_FINAL # endif +#define EASY_FORCE_INLINE inline __attribute__((always_inline)) + #elif defined(__GNUC__) ////////////////////////////////////////////////////////////////////////// // GNU Compiler @@ -124,6 +128,8 @@ # define EASY_FINAL # endif +#define EASY_FORCE_INLINE inline __attribute__((always_inline)) + #endif // END // TODO: Add other compilers support ////////////////////////////////////////////////////////////////////////// @@ -147,6 +153,10 @@ # define EASY_FINAL final #endif +#ifndef EASY_FORCE_INLINE +# define EASY_FORCE_INLINE inline +#endif + #ifndef PROFILER_API # define PROFILER_API #endif