Commit ed044066 by Michael Meissner Committed by Michael Meissner

rs6000.c (init_float128_ieee): Prevent complex multiply and divide external…

rs6000.c (init_float128_ieee): Prevent complex multiply and divide external functions from being created more...

2018-06-23  Michael Meissner  <meissner@linux.ibm.com>

	* config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
	multiply and divide external functions from being created more
	than once.

From-SVN: r261870
parent e8ccf824
...@@ -5,6 +5,9 @@ ...@@ -5,6 +5,9 @@
IEEE 128-bit long double. IEEE 128-bit long double.
(neg<mode>2_internal): Use the correct mode to check whether the (neg<mode>2_internal): Use the correct mode to check whether the
mode is IBM extended. mode is IBM extended.
* config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
multiply and divide external functions from being created more
than once.
2018-06-21 Eric Botcazou <ebotcazou@adacore.com> 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
......
...@@ -17892,9 +17892,14 @@ init_float128_ieee (machine_mode mode) ...@@ -17892,9 +17892,14 @@ init_float128_ieee (machine_mode mode)
{ {
if (FLOAT128_VECTOR_P (mode)) if (FLOAT128_VECTOR_P (mode))
{ {
/* Set up to call __mulkc3 and __divkc3 under -mabi=ieeelongdouble. */ static bool complex_muldiv_init_p = false;
if (mode == TFmode && TARGET_IEEEQUAD)
/* Set up to call __mulkc3 and __divkc3 under -mabi=ieeelongdouble. If
we have clone or target attributes, this will be called a second
time. We want to create the built-in function only once. */
if (mode == TFmode && TARGET_IEEEQUAD && !complex_muldiv_init_p)
{ {
complex_muldiv_init_p = true;
built_in_function fncode_mul = built_in_function fncode_mul =
(built_in_function) (BUILT_IN_COMPLEX_MUL_MIN + TCmode (built_in_function) (BUILT_IN_COMPLEX_MUL_MIN + TCmode
- MIN_MODE_COMPLEX_FLOAT); - MIN_MODE_COMPLEX_FLOAT);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment