Commit 7b4c352b authored by Cyrill Gorcunov's avatar Cyrill Gorcunov

compiler: Add likely/unlikely hints

Will be needed for file-ids handling.
Signed-off-by: 's avatarCyrill Gorcunov <gorcunov@openvz.org>
Acked-by: 's avatarPavel Emelyanov <xemul@parallels.com>
parent 0d9a5b8b
......@@ -23,6 +23,9 @@
# define __always_inline inline __attribute__((always_inline))
#endif
#define likely(x) __builtin_expect(!!(x), 1)
#define unlikely(x) __builtin_expect(!!(x), 0)
#ifndef always_inline
# define always_inline __always_inline
#endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment