older versions of gcc don't support the cold attribute so make its
presence conditional.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
* documentation.
*/
void __rte_panic(const char *funcname , const char *format, ...)
+#ifdef __GNUC__
+#if (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ > 2))
__attribute__((cold))
+#endif
+#endif
__attribute__((noreturn))
__attribute__((format(printf, 2, 3)));
* - Negative on error.
*/
int rte_log(uint32_t level, uint32_t logtype, const char *format, ...)
+#ifdef __GNUC__
+#if (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ > 2))
__attribute__((cold))
+#endif
+#endif
__attribute__((format(printf, 3, 4)));
/**