public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] Fix invalid RTL sharing caused by STV changes
@ 2019-08-21  7:58 Richard Biener
  0 siblings, 0 replies; only message in thread
From: Richard Biener @ 2019-08-21  7:58 UTC (permalink / raw)
  To: gcc-patches


I am testing the following and will commit it as obvious.

Richard.

2019-08-21  Richard Biener  <rguenther@suse.de>

	PR target/91498
	* config/i386/i386-features.c
	(general_scalar_chain::make_vector_copies): Copy stack temporary
	rtx when using it multiple times.
	(general_scalar_chain::convert_reg): Likewise.

Index: gcc/config/i386/i386-features.c
===================================================================
--- gcc/config/i386/i386-features.c	(revision 274764)
+++ gcc/config/i386/i386-features.c	(working copy)
@@ -706,7 +706,7 @@ general_scalar_chain::make_vector_copies
 				gen_rtx_SUBREG (SImode, reg, 4));
 	      }
 	    else
-	      emit_move_insn (tmp, reg);
+	      emit_move_insn (copy_rtx (tmp), reg);
 	    emit_insn (gen_rtx_SET (gen_rtx_SUBREG (vmode, vreg, 0),
 				    gen_gpr_to_xmm_move_src (vmode, tmp)));
 	  }
@@ -810,7 +810,7 @@ general_scalar_chain::convert_reg (unsig
 				  adjust_address (tmp, SImode, 4));
 		}
 	      else
-		emit_move_insn (scopy, tmp);
+		emit_move_insn (scopy, copy_rtx (tmp));
 	    }
 	  else if (!TARGET_64BIT && smode == DImode)
 	    {

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-08-21  7:25 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-21  7:58 [PATCH] Fix invalid RTL sharing caused by STV changes Richard Biener

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).