+2018-10-19 Ilya Leoshkevich <iii@linux.ibm.com>
+
+ PR rtl-optimization/87596
+ * lra-constraints.c (spill_hard_reg_in_range): Use INSN_P () +
+ lra_get_insn_recog_data () instead of lra_insn_recog_data[]
+ for instructions in FROM..TO range.
+
2018-10-19 Eric Botcazou <ebotcazou@adacore.com>
* cfgexpand.c (expand_one_var): Use specific wording in error message
continue;
for (insn = from; insn != NEXT_INSN (to); insn = NEXT_INSN (insn))
{
- lra_insn_recog_data_t id = lra_insn_recog_data[uid = INSN_UID (insn)];
- struct lra_static_insn_data *static_id = id->insn_static_data;
+ struct lra_static_insn_data *static_id;
struct lra_insn_reg *reg;
- if (bitmap_bit_p (&lra_reg_info[hard_regno].insn_bitmap, uid))
+ if (!INSN_P (insn))
+ continue;
+ if (bitmap_bit_p (&lra_reg_info[hard_regno].insn_bitmap,
+ INSN_UID (insn)))
break;
+ static_id = lra_get_insn_recog_data (insn)->insn_static_data;
for (reg = static_id->hard_regs; reg != NULL; reg = reg->next)
if (reg->regno == hard_regno)
break;
+2018-10-19 Ilya Leoshkevich <iii@linux.ibm.com>
+
+ PR rtl-optimization/87596
+ * gcc.target/i386/pr87596.c: New test.
+
2018-10-19 Eric Botcazou <ebotcazou@adacore.com>
* gnat.dg/frame_overflow2.adb: New test.
--- /dev/null
+/* LRA corner case which triggered a segfault. */
+/* Reduced testcase by Arseny Solokha. */
+/* { dg-do compile { target int128 } } */
+/* { dg-options "-O1 -fschedule-insns -ftrapv -funroll-all-loops -fno-tree-dominator-opts -fno-tree-loop-im" } */
+
+void
+wh (__int128 *ku)
+{
+ unsigned int *dp;
+
+ while (*ku < 1)
+ {
+ *dp <<= 32; /* { dg-warning "left shift count >= width of type" } */
+ ++*ku;
+ }
+}