d930a6e
From 7327af4c323f6d4f500bf4aaa66a9cac6236772f Mon Sep 17 00:00:00 2001
d930a6e
From: Jim Meyering <meyering@redhat.com>
d930a6e
Date: Wed, 26 Oct 2011 20:08:52 +0200
d930a6e
Subject: [PATCH] Revert "Use leaf function attribute in __THROW"
d930a6e
d930a6e
This reverts commit aa78043a4aafe5db1a1a76d544a833b63b4c5f5c
d930a6e
and the related 49a43d80ec5c97cf6136b1ee2687414773b2d5aa.
d930a6e
This fixes http://bugzilla.redhat.com/747377
d930a6e
---
d930a6e
 misc/sys/cdefs.h |   15 +++------------
d930a6e
 2 files changed, 3 insertions(+), 14 deletions(-)
d930a6e
d930a6e
diff --git a/misc/sys/cdefs.h b/misc/sys/cdefs.h
d930a6e
index 72073e8..165a94a 100644
d930a6e
--- a/misc/sys/cdefs.h
d930a6e
+++ b/misc/sys/cdefs.h
d930a6e
@@ -38,27 +38,18 @@
d930a6e
d930a6e
 #ifdef __GNUC__
d930a6e
d930a6e
-/* All functions, except those with callbacks, are leaf functions.  */
d930a6e
-# if __GNUC_PREREQ (4, 6) && !defined _LIBC
d930a6e
-#  define __LEAF , __leaf__
d930a6e
-#  define __LEAF_ATTR __attribute__ ((__leaf__))
d930a6e
-# else
d930a6e
-#  define __LEAF
d930a6e
-#  define __LEAF_ATTR
d930a6e
-# endif
d930a6e
-
d930a6e
 /* GCC can always grok prototypes.  For C++ programs we add throw()
d930a6e
    to help it optimize the function calls.  But this works only with
d930a6e
    gcc 2.8.x and egcs.  For gcc 3.2 and up we even mark C functions
d930a6e
    as non-throwing using a function attribute since programs can use
d930a6e
    the -fexceptions options for C code as well.  */
d930a6e
 # if !defined __cplusplus && __GNUC_PREREQ (3, 3)
d930a6e
-#  define __THROW	__attribute__ ((__nothrow__ __LEAF))
d930a6e
-#  define __NTH(fct)	__attribute__ ((__nothrow__ __LEAF)) fct
d930a6e
+#  define __THROW	__attribute__ ((__nothrow__))
d930a6e
+#  define __NTH(fct)	__attribute__ ((__nothrow__)) fct
d930a6e
 # else
d930a6e
 #  if defined __cplusplus && __GNUC_PREREQ (2,8)
d930a6e
 #   define __THROW	throw ()
d930a6e
-#   define __NTH(fct)	__LEAF_ATTR fct throw ()
d930a6e
+#   define __NTH(fct)	fct throw ()
d930a6e
 #  else
d930a6e
 #   define __THROW
d930a6e
 #   define __NTH(fct)	fct
d930a6e
--
d930a6e
1.7.7.1