summaryrefslogtreecommitdiff
path: root/Zend/zend_portability.h
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@zend.com>2015-08-19 14:40:56 +0300
committerDmitry Stogov <dmitry@zend.com>2015-08-19 14:40:56 +0300
commit71af54e5f6656af070e4dccd1470bb1376c89568 (patch)
treefccae330f52f8e1848d1f3921b03b8e8b7e0ed70 /Zend/zend_portability.h
parent066f6f6ad8bf9ff3b548d768c811931bab320cd5 (diff)
downloadphp-git-71af54e5f6656af070e4dccd1470bb1376c89568.tar.gz
Mark error and exception functions as "cold" (Matt's idea)
Diffstat (limited to 'Zend/zend_portability.h')
-rw-r--r--Zend/zend_portability.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/Zend/zend_portability.h b/Zend/zend_portability.h
index 55523501c7..77cd3ee734 100644
--- a/Zend/zend_portability.h
+++ b/Zend/zend_portability.h
@@ -216,9 +216,13 @@ char *alloca();
#if defined(__GNUC__) && ZEND_GCC_VERSION >= 4003
# define ZEND_ATTRIBUTE_UNUSED __attribute__((unused))
# define ZEND_ATTRIBUTE_UNUSED_LABEL __attribute__((cold, unused));
+# define ZEND_COLD __attribute__((cold))
+# define ZEND_HOT __attribute__((cold))
#else
# define ZEND_ATTRIBUTE_UNUSED
# define ZEND_ATTRIBUTE_UNUSED_LABEL
+# define ZEND_COLD __attribute__((cold))
+# define ZEND_HOT __attribute__((cold));
#endif
#if defined(__GNUC__) && ZEND_GCC_VERSION >= 3004 && defined(__i386__)