We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 01183d7 commit 16a7f46Copy full SHA for 16a7f46
Objects/obmalloc.c
@@ -1457,7 +1457,7 @@ PyObject_Free(void *ptr)
1457
1458
/* If we're using GCC, use __builtin_expect() to reduce overhead of
1459
the valgrind checks */
1460
-#if defined(__GNUC__) && (__GNUC__ > 2) && defined(__OPTIMIZE__)
+#if (defined(__clang__) || (defined(__GNUC__) && (__GNUC__ > 2))) && defined(__OPTIMIZE__)
1461
# define UNLIKELY(value) __builtin_expect((value), 0)
1462
# define LIKELY(value) __builtin_expect((value), 1)
1463
#else
0 commit comments