1
0
mirror of https://github.com/php/php-src.git synced 2026-04-09 09:03:04 +02:00

GNU compilers remove hot attribute proposal. (#8922)

While the cold attribute has its place, the hot one however
does one have real justification for use, even more so with
modern toolchains.
This commit is contained in:
David CARLIER
2023-01-25 19:51:22 +00:00
committed by GitHub
parent 48db3423a5
commit 90b0e77921

View File

@@ -265,7 +265,6 @@ char *alloca();
#if defined(__GNUC__) && ZEND_GCC_VERSION >= 4003
# define ZEND_COLD __attribute__((cold))
# define ZEND_HOT __attribute__((hot))
# ifdef __OPTIMIZE__
# define ZEND_OPT_SIZE __attribute__((optimize("Os")))
# define ZEND_OPT_SPEED __attribute__((optimize("Ofast")))
@@ -275,7 +274,6 @@ char *alloca();
# endif
#else
# define ZEND_COLD
# define ZEND_HOT
# define ZEND_OPT_SIZE
# define ZEND_OPT_SPEED
#endif
@@ -283,11 +281,9 @@ char *alloca();
#if defined(__GNUC__) && ZEND_GCC_VERSION >= 5000
# define ZEND_ATTRIBUTE_UNUSED_LABEL __attribute__((unused));
# define ZEND_ATTRIBUTE_COLD_LABEL __attribute__((cold));
# define ZEND_ATTRIBUTE_HOT_LABEL __attribute__((hot));
#else
# define ZEND_ATTRIBUTE_UNUSED_LABEL
# define ZEND_ATTRIBUTE_COLD_LABEL
# define ZEND_ATTRIBUTE_HOT_LABEL
#endif
#if defined(__GNUC__) && ZEND_GCC_VERSION >= 3004 && defined(__i386__)