This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Fix PR90610


Another mistake in the vec_perm -> bit_insert change.

Bootstrapped on x86_64-unknown-linux-gnu, testing in progress.

Richard.

2019-05-27  Richard Biener  <rguenther@suse.de>

	PR middle-end/90610
	* match.pd (vec_perm): Avoid clobbering op0 when not generating
	a bit-insert.

Index: gcc/match.pd
===================================================================
--- gcc/match.pd	(revision 271644)
+++ gcc/match.pd	(working copy)
@@ -5453,8 +5453,8 @@ (define_operator_list COND_TERNARY
 		   first vector we only can insert the first elt from
 		   the first vector.  */
 	        at = 0;
-		ins = fold_read_from_vector (cop0, 0);
-	        op0 = op1;
+		if ((ins = fold_read_from_vector (cop0, 0)))
+		  op0 = op1;
 	      }
 	    else
 	      {


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]