diff options
author | Andy Lester <andy@petdance.com> | 2006-02-24 08:54:35 -0600 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2006-02-27 11:06:30 +0000 |
commit | b37c2d43c8bccbefe3985273e9661833102148d0 (patch) | |
tree | b996c0398e5f83c4ed03e0b1144f10819ba27a27 /perl.h | |
parent | ee94f8101362ee382e42ec2d404d79b0ab7d17ef (diff) | |
download | perl-b37c2d43c8bccbefe3985273e9661833102148d0.tar.gz |
Speedups and shrinkages of SvREFCNT_inc
Message-ID: <20060224205434.GA17867@petdance.com>
p4raw-id: //depot/perl@27334
Diffstat (limited to 'perl.h')
-rw-r--r-- | perl.h | 12 |
1 files changed, 10 insertions, 2 deletions
@@ -2957,11 +2957,19 @@ typedef pthread_key_t perl_key; appropriate to call return. In either case, include the lint directive. */ #ifdef HASATTRIBUTE_NORETURN -# define NORETURN_FUNCTION_END /* NOT REACHED */ +# define NORETURN_FUNCTION_END /* NOTREACHED */ #else -# define NORETURN_FUNCTION_END /* NOT REACHED */ return 0 +# define NORETURN_FUNCTION_END /* NOTREACHED */ return 0 #endif +#ifdef HASBUILTIN_EXPECT +# define EXPECT(expr,val) __builtin_expect(expr,val) +#else +# define EXPECT(expr,val) (expr) +#endif +#define LIKELY(cond) EXPECT(cond,1) +#define UNLIKELY(cond) EXPECT(cond,0) + /* Some unistd.h's give a prototype for pause() even though HAS_PAUSE ends up undefined. This causes the #define below to be rejected by the compiler. Sigh. |