I've fixed the redundant conditions in the expressions pointed out by
83822. Bootstrap/regtest passes on ppc64le, ok for trunk?

    Aaron


2018-03-29  Aaron Sawdey  <acsaw...@linux.vnet.ibm.com>

        PR target/83822
        * config/rs6000/rs6000-string.c (expand_compare_loop): Fix redundant
        condition.
        * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Fix redundant
        condition.

-- 
Aaron Sawdey, Ph.D.  acsaw...@linux.vnet.ibm.com
050-2/C113  (507) 253-7520 home: 507/263-0782
IBM Linux Technology Center - PPC Toolchain
Index: gcc/config/rs6000/rs6000-c.c
===================================================================
--- gcc/config/rs6000/rs6000-c.c	(revision 258900)
+++ gcc/config/rs6000/rs6000-c.c	(working copy)
@@ -642,8 +642,7 @@
 	  cpp_get_callbacks (pfile)->macro_to_expand = rs6000_macro_to_expand;
 	}
     }
-  if (!TARGET_HARD_FLOAT
-      || (TARGET_HARD_FLOAT && !TARGET_DOUBLE_FLOAT))
+  if (!TARGET_HARD_FLOAT || !TARGET_DOUBLE_FLOAT)
     builtin_define ("_SOFT_DOUBLE");
   /* Used by lwarx/stwcx. errata work-around.  */
   if (rs6000_cpu == PROCESSOR_PPC405)
Index: gcc/config/rs6000/rs6000-string.c
===================================================================
--- gcc/config/rs6000/rs6000-string.c	(revision 258900)
+++ gcc/config/rs6000/rs6000-string.c	(working copy)
@@ -966,8 +966,7 @@
       rtx final_cleanup = gen_label_rtx ();
       rtx cmp_rem_before = gen_reg_rtx (word_mode);
       /* Compare one more word_mode chunk if needed.  */
-      if (!bytes_is_const
-	  || (bytes_is_const && bytes_remaining >= load_mode_size))
+      if (!bytes_is_const || bytes_remaining >= load_mode_size)
 	{
 	  /* If remainder length < word length, branch to final
 	     cleanup compare.  */

Reply via email to