-#ifdef EMSCRIPTEN
-
-#ifndef __clang__
-# error not clang?
-#endif
-
-// clang cpp11 check is per feature
-#if !__has_feature(cxx_constexpr)
-# error constexpr needed for compile-time-math. Use -std=c+11
-#endif
-
-#define _CPP11
-
+/**
+ * @brief Two macros to provide branch predictor information.
+ * DALI_LIKELY should be used when a branch is taken in almost all cases so the
+ * branch predictor can avoid pre-fetching. The code for else branch
+ * DALI_UNLIKELY should be used when a branch is almost never taken.
+ * @SINCE_1_0.0
+ */
+#ifdef __GNUC
+#define DALI_LIKELY(expression) __builtin_expect( !!(expression), 1 )
+#define DALI_UNLIKELY(expression) __builtin_expect( !!(expression), 0 )
+#else
+#define DALI_LIKELY(expression) !!(expression)
+#define DALI_UNLIKELY(expression) !!(expression)