From: Martin Mares Date: Thu, 12 Jun 2003 21:36:57 +0000 (+0000) Subject: Added macros for hinting branch predictor. X-Git-Tag: holmes-import~1252 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=f874b43fb65e4fadc591319f1aea6084bb72254b;p=libucw.git Added macros for hinting branch predictor. --- diff --git a/lib/config.h b/lib/config.h index ee782b69..cc2d86da 100644 --- a/lib/config.h +++ b/lib/config.h @@ -83,6 +83,8 @@ typedef s32 sh_off_t; #define PACKED __attribute__((packed)) #define CONST __attribute__((const)) #define PURE __attribute__((const)) +#define likely(x) __builtin_expect((x),1) +#define unlikely(x) __builtin_expect((x),0) #else #error This program requires the GNU C compiler.