Blame SOURCES/gcc48-rh1469697-19.patch

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