Commit 108b83c1 by Jakub Jelinek Committed by Jakub Jelinek

re PR rtl-optimization/84989 (_mm512_broadcast_f32x4 triggers ICE in…

re PR rtl-optimization/84989 (_mm512_broadcast_f32x4 triggers ICE in simplify_const_unary_operation, at simplify-rtx.c:1731)

	PR rtl-optimization/84989
	* simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
	VEC_DUPLICATE with scalar result mode.

	* gcc.target/i386/pr84989.c: New test.

From-SVN: r258709
parent ad6aec71
2018-03-21 Jakub Jelinek <jakub@redhat.com>
PR rtl-optimization/84989
* simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
VEC_DUPLICATE with scalar result mode.
2018-03-21 Martin Liska <mliska@suse.cz> 2018-03-21 Martin Liska <mliska@suse.cz>
PR ipa/84963 PR ipa/84963
......
...@@ -1692,7 +1692,9 @@ simplify_unary_operation_1 (enum rtx_code code, machine_mode mode, rtx op) ...@@ -1692,7 +1692,9 @@ simplify_unary_operation_1 (enum rtx_code code, machine_mode mode, rtx op)
break; break;
} }
if (VECTOR_MODE_P (mode) && vec_duplicate_p (op, &elt)) if (VECTOR_MODE_P (mode)
&& vec_duplicate_p (op, &elt)
&& code != VEC_DUPLICATE)
{ {
/* Try applying the operator to ELT and see if that simplifies. /* Try applying the operator to ELT and see if that simplifies.
We can duplicate the result if so. We can duplicate the result if so.
......
2018-03-21 Jakub Jelinek <jakub@redhat.com>
PR rtl-optimization/84989
* gcc.target/i386/pr84989.c: New test.
2018-03-21 Christophe Lyon <christophe.lyon@linaro.org> 2018-03-21 Christophe Lyon <christophe.lyon@linaro.org>
* gcc.target/arm/pr82518.c: Require arm_neon_hw. * gcc.target/arm/pr82518.c: Require arm_neon_hw.
......
/* PR rtl-optimization/84989 */
/* { dg-do compile } */
/* { dg-options "-O2 -mavx512f" } */
#include <x86intrin.h>
__m512
foo (float a, float *b)
{
return _mm512_sub_ps (_mm512_broadcast_f32x4 (_mm_load_ps (b)),
_mm512_broadcast_f32x4 (_mm_set1_ps (a)));
}
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