List:Commits« Previous MessageNext Message »
From:Ole John Aske Date:April 30 2009 8:45am
Subject:bzr commit into mysql-5.1-telco-7.0 branch (ole.john.aske:2879) Bug#44570
View as plain text  
#At file:///home/oa136780/mysql/mysql-5.1-telco-7.0/ based on revid:ole.john.aske@stripped

 2879 Ole John Aske	2009-04-30 [merge]
      Fix bug#44570

    modified:
      include/my_global.h
=== modified file 'include/my_global.h'
--- a/include/my_global.h	2009-02-16 08:36:46 +0000
+++ b/include/my_global.h	2009-04-30 08:45:04 +0000
@@ -156,9 +156,17 @@
 #define __builtin_expect(x, expected_value) (x)
 #endif
 
+#if defined(NDEBUG)
 #define likely(x)	__builtin_expect((x),1)
 #define unlikely(x)	__builtin_expect((x),0)
-
+#else
+/*
+  No branch hinting in DEBUG as this enables warning in case
+  of malformed predicates: ie. use of '=' instead if '=='
+*/
+#define likely(x)	(x)
+#define unlikely(x)	(x)
+#endif
 
 /*
   The macros below are useful in optimising places where it has been


Attachment: [text/bzr-bundle] bzr/ole.john.aske@sun.com-20090430084504-2c8iheeuc631njs5.bundle
Thread
bzr commit into mysql-5.1-telco-7.0 branch (ole.john.aske:2879) Bug#44570Ole John Aske30 Apr