[02/12] Move declare_mgen_finite_alias definition

Message ID 20180620020426.20372-3-tuliom@linux.ibm.com
State New
Headers show
Series
  • Introduce ieee128 symbols and redirections
Related show

Commit Message

Tulio Magno Quites Machado Filho June 20, 2018, 2:04 a.m.
Move declare_mgen_finite_alias, declare_mgen_finite_alias_s and
declare_mgen_finite_alias_x to a shared place in order to reuse them in
other files that also declare _finite aliases.

2018-06-19  Tulio Magno Quites Machado Filho  <tuliom@linux.ibm.com>

	* math/e_exp2_template.c (declare_mgen_finite_alias,
	declare_mgen_finite_alias_s, declare_mgen_finite_alias_x): Move to...
	* sysdeps/generic/math-type-macros.h (declare_mgen_finite_alias,
	declare_mgen_finite_alias_s, declare_mgen_finite_alias_x): ... here.

Signed-off-by: Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>

---
 math/e_exp2_template.c             |  7 -------
 sysdeps/generic/math-type-macros.h | 15 +++++++++++++++
 2 files changed, 15 insertions(+), 7 deletions(-)

-- 
2.14.4

Comments

Joseph Myers June 20, 2018, 10:39 a.m. | #1
How does this patch differ from the version I already approved?

-- 
Joseph S. Myers
joseph@codesourcery.com
Tulio Magno Quites Machado Filho June 20, 2018, 1:14 p.m. | #2
Joseph Myers <joseph@codesourcery.com> writes:

> How does this patch differ from the version I already approved?


There is no difference.  I re-sent it because it's part of the patch set.
I can merge it you believe it's OK.

-- 
Tulio Magno
Joseph Myers June 20, 2018, 9:04 p.m. | #3
On Wed, 20 Jun 2018, Tulio Magno Quites Machado Filho wrote:

> Joseph Myers <joseph@codesourcery.com> writes:

> 

> > How does this patch differ from the version I already approved?

> 

> There is no difference.  I re-sent it because it's part of the patch set.

> I can merge it you believe it's OK.


Approved patches not depending on other unapproved patches should be 
committed (unless the approval is specifically conditional on some other 
change) to reduce the size of future patch series revisions.

-- 
Joseph S. Myers
joseph@codesourcery.com
Tulio Magno Quites Machado Filho June 20, 2018, 9:09 p.m. | #4
Joseph Myers <joseph@codesourcery.com> writes:

> On Wed, 20 Jun 2018, Tulio Magno Quites Machado Filho wrote:

>

>> Joseph Myers <joseph@codesourcery.com> writes:

>> 

>> > How does this patch differ from the version I already approved?

>> 

>> There is no difference.  I re-sent it because it's part of the patch set.

>> I can merge it you believe it's OK.

>

> Approved patches not depending on other unapproved patches should be 

> committed (unless the approval is specifically conditional on some other 

> change) to reduce the size of future patch series revisions.


Ack.
Pushed as badba23cacde.

Thanks!

-- 
Tulio Magno

Patch

diff --git a/math/e_exp2_template.c b/math/e_exp2_template.c
index 30ed4af49b..19f9780b05 100644
--- a/math/e_exp2_template.c
+++ b/math/e_exp2_template.c
@@ -21,13 +21,6 @@ 
 #include <math-underflow.h>
 #include <float.h>
 
-#define declare_mgen_finite_alias_x(from, to) \
-	strong_alias (from, to ## _finite)
-#define declare_mgen_finite_alias_s(from,to) \
-	declare_mgen_finite_alias_x (from, to)
-#define declare_mgen_finite_alias(from, to) \
-	declare_mgen_finite_alias_s (M_SUF (from), M_SUF (to))
-
 FLOAT
 M_DECL_FUNC (__ieee754_exp2) (FLOAT x)
 {
diff --git a/sysdeps/generic/math-type-macros.h b/sysdeps/generic/math-type-macros.h
index 0e8ef16d7a..5250815253 100644
--- a/sysdeps/generic/math-type-macros.h
+++ b/sysdeps/generic/math-type-macros.h
@@ -74,6 +74,21 @@ 
 # error "SET_NAN_PAYLOAD must be defined."
 #endif
 
+#ifndef declare_mgen_finite_alias_x
+#define declare_mgen_finite_alias_x(from, to)	\
+  strong_alias (from, to ## _finite)
+#endif
+
+#ifndef declare_mgen_finite_alias_s
+# define declare_mgen_finite_alias_s(from,to)	\
+  declare_mgen_finite_alias_x (from, to)
+#endif
+
+#ifndef declare_mgen_finite_alias
+# define declare_mgen_finite_alias(from, to)	\
+  declare_mgen_finite_alias_s (M_SUF (from), M_SUF (to))
+#endif
+
 #define __M_CONCAT(a,b) a ## b
 #define __M_CONCATX(a,b) __M_CONCAT(a,b)