re PR target/77526 (ICE: in verify_dominators, at dominance.c:1039 with -mstringop...
authorJakub Jelinek <jakub@redhat.com>
Fri, 16 Sep 2016 07:10:08 +0000 (09:10 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Fri, 16 Sep 2016 07:10:08 +0000 (09:10 +0200)
PR target/77526
* combine.c (rest_of_handle_combine): If any edges have been purged,
free dominators if available.

* gcc.target/i386/pr77526.c: New test.

From-SVN: r240174

gcc/ChangeLog
gcc/combine.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/i386/pr77526.c [new file with mode: 0644]

index 0287d52..2d40745 100644 (file)
@@ -1,4 +1,10 @@
 2016-09-16  Jakub Jelinek  <jakub@redhat.com>
+
+       PR target/77526
+       * combine.c (rest_of_handle_combine): If any edges have been purged,
+       free dominators if available.
+
+2016-09-16  Jakub Jelinek  <jakub@redhat.com>
            Eric Botcazou  <ebotcazou@adacore.com>
 
        PR middle-end/77594
index 1b262f9..1e43d48 100644 (file)
@@ -14393,6 +14393,8 @@ rest_of_handle_combine (void)
      instructions.  */
   if (rebuild_jump_labels_after_combine)
     {
+      if (dom_info_available_p (CDI_DOMINATORS))
+       free_dominance_info (CDI_DOMINATORS);
       timevar_push (TV_JUMP);
       rebuild_jump_labels (get_insns ());
       cleanup_cfg (0);
index 8d739b5..91d1962 100644 (file)
@@ -1,4 +1,9 @@
 2016-09-16  Jakub Jelinek  <jakub@redhat.com>
+
+       PR target/77526
+       * gcc.target/i386/pr77526.c: New test.
+
+2016-09-16  Jakub Jelinek  <jakub@redhat.com>
            Eric Botcazou  <ebotcazou@adacore.com>
 
        PR middle-end/77594
diff --git a/gcc/testsuite/gcc.target/i386/pr77526.c b/gcc/testsuite/gcc.target/i386/pr77526.c
new file mode 100644 (file)
index 0000000..91b946a
--- /dev/null
@@ -0,0 +1,13 @@
+/* PR target/77526 */
+/* { dg-do compile { target int128 } } */
+/* { dg-options "-Os -fno-forward-propagate -fno-gcse -fno-rerun-cse-after-loop -mstringop-strategy=byte_loop -Wno-psabi" } */
+
+typedef char U __attribute__((vector_size(64)));
+typedef __int128 V __attribute__((vector_size(64)));
+
+V
+foo (int a, int b, __int128 c, U u)
+{
+  u = (u >> (u & 7)) | (u << -(u & 7));
+  return a + b + c + (V)u;
+}