On Tue, 6 May 2025, andre.simoesdiasvie...@arm.com wrote:

> 
> Prunes code from the trivial true/false conditions.

-  gcc_assert (vec_num == 1 || 1);
+  gcc_assert (vec_num == 1);

that looks like a now stronger assert, pruning would have removed
the assert instead?

   if (ncopies > 1
-      && (0
-         || (!REDUC_GROUP_FIRST_ELEMENT (stmt_info)
-             && SLP_TREE_LANES (slp_node) == 1))
+      && (!REDUC_GROUP_FIRST_ELEMENT (stmt_info)
+         && SLP_TREE_LANES (slp_node) == 1)

the extra parens around the "inner" && is no longer needed, the
conditions can be brought in-line with the outer &&


> ---
>  gcc/tree-vect-loop.cc | 540 ++++++++++++------------------------------
>  1 file changed, 155 insertions(+), 385 deletions(-)
> 
> 

-- 
Richard Biener <rguent...@suse.de>
SUSE Software Solutions Germany GmbH,
Frankenstrasse 146, 90461 Nuernberg, Germany;
GF: Ivo Totev, Andrew McDonald, Werner Knoblich; (HRB 36809, AG Nuernberg)

Reply via email to