diff options
author | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2005-09-03 08:53:48 +0000 |
---|---|---|
committer | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2005-09-03 08:53:48 +0000 |
commit | dbe33c933e60f6c5ef59856f66bb3363eaecdf8b (patch) | |
tree | 3be4f75f3891bd1867c1f9c7cc191d5e6bd03d20 | |
parent | df50ce22f3d832633cb401bf4da7c846fbe7e1ad (diff) |
likely() and unlikely() macros to help (newer) compilers optimize correctly
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@16369 b3059339-0415-0410-9bf9-f77b7e298cf2
-rwxr-xr-x | configure | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -7161,6 +7161,13 @@ $_def_restrict_keyword /* __builtin_expect branch prediction hint */ $_def_builtin_expect +#ifdef HAVE_BUILTIN_EXPECT +#define likely(x) __builtin_expect ((x) != 0, 1) +#define unlikely(x) __builtin_expect ((x) != 0, 0) +#else +#define likely(x) (x) +#define unlikely(x) (x) +#endif /* attribute(used) as needed by some compilers */ #if (__GNUC__ * 100 + __GNUC_MINOR__ >= 300) |