re PR target/79058 (ARM: internal compiler error: in extract_constrain_insn, at recog...
authorVladimir Makarov <vmakarov@redhat.com>
Tue, 17 Jan 2017 16:11:55 +0000 (16:11 +0000)
committerVladimir Makarov <vmakarov@gcc.gnu.org>
Tue, 17 Jan 2017 16:11:55 +0000 (16:11 +0000)
2017-01-17  Vladimir Makarov  <vmakarov@redhat.com>

PR target/79058
* ira-conflicts.c (ira_build_conflicts): Update total conflict
hard regs for inner regno.

2017-01-17  Vladimir Makarov  <vmakarov@redhat.com>

PR target/79058
* gcc.target/arm/pr79058.c: New.

From-SVN: r244535

gcc/ChangeLog
gcc/ira-conflicts.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/arm/pr79058.c [new file with mode: 0644]

index 282d1c90d590bed7ecd888823488d009ddc7ddb7..cc05d2c9c2c55e59ff9a7aecd8de59563658870d 100644 (file)
@@ -1,3 +1,9 @@
+2017-01-17  Vladimir Makarov  <vmakarov@redhat.com>
+
+       PR target/79058
+       * ira-conflicts.c (ira_build_conflicts): Update total conflict
+       hard regs for inner regno.
+
 2017-01-17  Martin Liska  <mliska@suse.cz>
 
        PR ipa/71207
index 1a8c08caaa4266721369312aeb35d7f21a7a2dce..57dba151d8d9beec38166bda6b139c4983596483 100644 (file)
@@ -787,8 +787,12 @@ ira_build_conflicts (void)
                   if (outer_regno < 0
                       || !in_hard_reg_set_p (reg_class_contents[aclass],
                                              outer_mode, outer_regno))
-                    SET_HARD_REG_BIT (OBJECT_CONFLICT_HARD_REGS (obj),
-                                      inner_regno);
+                    {
+                      SET_HARD_REG_BIT (OBJECT_TOTAL_CONFLICT_HARD_REGS (obj),
+                                        inner_regno);
+                      SET_HARD_REG_BIT (OBJECT_CONFLICT_HARD_REGS (obj),
+                                        inner_regno);
+                    }
                }
            }
 
index e211eb8c3192732a7f59730ab097d638687fdfc5..0eda15b930b0d7fa67ad63fa8b85f5ad27d26753 100644 (file)
@@ -1,3 +1,8 @@
+2017-01-17  Vladimir Makarov  <vmakarov@redhat.com>
+
+       PR target/79058
+       * gcc.target/arm/pr79058.c: New.
+
 2017-01-17  Jakub Jelinek  <jakub@redhat.com>
 
        PR tree-optimization/71854
diff --git a/gcc/testsuite/gcc.target/arm/pr79058.c b/gcc/testsuite/gcc.target/arm/pr79058.c
new file mode 100644 (file)
index 0000000..f2841f5
--- /dev/null
@@ -0,0 +1,12 @@
+/* { dg-do compile } */
+/* { dg-skip-if "do not override -mcpu" { *-*-* } { "-mcpu=*" } { "-mcpu=arm7tdmi" } } */
+/* { dg-options "-Os -mbig-endian -mcpu=arm7tdmi" } */
+
+enum { NILFS_SEGMENT_USAGE_ACTIVE, NILFS_SEGMENT_USAGE_DIRTY } a;
+
+void fn2 (long long);
+
+void fn1() {
+  int b = a & 1 << NILFS_SEGMENT_USAGE_DIRTY;
+  fn2 (b ? (long long) -1 : 0);
+}