Blame SOURCES/gcc48-rh1469697-19.patch

13f101
2017-10-31  Segher Boessenkool  <segher@kernel.crsahing.org>
13f101
13f101
       PR target/82674
13f101
       * config/rs6000/rs6000.md (allocate_stack): Force update interval
13f101
       into a register if it does not fit into an immediate offset field.
13f101
13f101
13f101
diff -Nrup a/gcc/config/rs6000/rs6000.md b/gcc/config/rs6000/rs6000.md
13f101
--- a/gcc/config/rs6000/rs6000.md	2017-11-06 09:12:21.128237467 -0700
13f101
+++ b/gcc/config/rs6000/rs6000.md	2017-11-06 09:13:40.521601373 -0700
13f101
@@ -11886,6 +11886,9 @@
13f101
 	{
13f101
 	  rtx loop_lab, end_loop;
13f101
 	  bool rotated = CONST_INT_P (rounded_size);
13f101
+	  rtx update = GEN_INT (-probe_interval);
13f101
+	  if (probe_interval > 32768)
13f101
+	    update = force_reg (Pmode, update);
13f101
 
13f101
 	  emit_stack_clash_protection_probe_loop_start (&loop_lab, &end_loop,
13f101
 							last_addr, rotated);
13f101
@@ -11893,13 +11896,11 @@
13f101
 	  if (Pmode == SImode)
13f101
 	    emit_insn (gen_movsi_update_stack (stack_pointer_rtx,
13f101
 					       stack_pointer_rtx,
13f101
-					       GEN_INT (-probe_interval),
13f101
-					       chain));
13f101
+					       update, chain));
13f101
 	  else
13f101
 	    emit_insn (gen_movdi_di_update_stack (stack_pointer_rtx,
13f101
 					          stack_pointer_rtx,
13f101
-					          GEN_INT (-probe_interval),
13f101
-					          chain));
13f101
+					          update, chain));
13f101
 	  emit_stack_clash_protection_probe_loop_end (loop_lab, end_loop,
13f101
 						      last_addr, rotated);
13f101
 	}