public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "hubicka at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug testsuite/109596] [14 Regression] Lots of guality testcase fails on x86_64 after r14-162-gcda246f8b421ba
Date: Tue, 19 Mar 2024 15:47:48 +0000	[thread overview]
Message-ID: <bug-109596-4-KGCVUOGTWw@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-109596-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109596

--- Comment #6 from Jan Hubicka <hubicka at gcc dot gnu.org> ---
On this testcase trunk does get same dump as gcc13 for pass just before ch2

with ch2 we get:
@@ -192,9 +236,8 @@
   # DEBUG BEGIN_STMT
   goto <bb 5>; [100.00%]

-  <bb 3> [local count: 954449105]:
+  <bb 3> [local count: 954449104]:
   # j_15 = PHI <j_9(3), 0(5)>
-  # DEBUG j => j_15
   # DEBUG BEGIN_STMT
   a[b_14][j_15] = 0;
   # DEBUG BEGIN_STMT
@@ -203,29 +246,30 @@
   # DEBUG j => j_9
   # DEBUG BEGIN_STMT
   if (j_9 <= 7)
-    goto <bb 3>; [88.89%]
+    goto <bb 3>; [87.50%]
   else
-    goto <bb 4>; [11.11%]
+    goto <bb 4>; [12.50%]

   <bb 4> [local count: 119292720]:
+  # DEBUG j => 0
   # DEBUG BEGIN_STMT
   b_7 = b_14 + 1;
   # DEBUG b => b_7
   # DEBUG b => b_7
   # DEBUG BEGIN_STMT
   if (b_7 <= 6)
-    goto <bb 5>; [87.50%]
+    goto <bb 5>; [85.71%]
   else
-    goto <bb 6>; [12.50%]
+    goto <bb 6>; [14.29%]

   <bb 5> [local count: 119292720]:
   # b_14 = PHI <b_7(4), 0(2)>
-  # DEBUG b => b_14
   # DEBUG j => 0
   # DEBUG BEGIN_STMT
   goto <bb 3>; [100.00%]

   <bb 6> [local count: 17041817]:
+  # DEBUG b => 0
   # DEBUG BEGIN_STMT
   optimize_me_not ();
   # DEBUG BEGIN_STMT


So in addition to updating BB profile, we indeed end up moving debug statements
around.

The change of dump is:
+  Analyzing: if (b_1 <= 6)
+    Will eliminate peeled conditional in bb 6.
+    May duplicate bb 6
+  Not duplicating bb 8: it is single succ.
+  Analyzing: if (j_2 <= 7)
+    Will eliminate peeled conditional in bb 4.
+    May duplicate bb 4
+  Not duplicating bb 3: it is single succ.
 Loop 2 is not do-while loop: latch is not empty.
+    Duplicating header BB to obtain do-while loop
 Copying headers of loop 1
     Will duplicate bb 6
-  Not duplicating bb 8: it is single succ.
-Duplicating header of the loop 1 up to edge 6->8, 2 insns.
+Duplicating header of the loop 1 up to edge 6->7
 Loop 1 is do-while loop
 Loop 1 is now do-while loop.
+Exit count: 17041817 (estimated locally)
+Entry count: 17041817 (estimated locally)
+Peeled all exits: decreased number of iterations of loop 1 by 1.
 Copying headers of loop 2
     Will duplicate bb 4
-  Not duplicating bb 3: it is single succ.
-Duplicating header of the loop 2 up to edge 4->3, 2 insns.
+Duplicating header of the loop 2 up to edge 4->5
 Loop 2 is do-while loop
 Loop 2 is now do-while loop.
+Exit count: 119292720 (estimated locally)
+Entry count: 119292720 (estimated locally)
+Peeled all exits: decreased number of iterations of loop 2 by 1.

Dumps moved around, but we do same duplicaitons as before (BB6 and BB4 to
eliminate the conditionals).

  <bb 4> [local count: 1073741824]:
  # j_2 = PHI <0(8), j_9(3)>
  # DEBUG j => j_2
  # DEBUG BEGIN_STMT
  if (j_2 <= 7)
    goto <bb 3>; [88.89%]
  else
    goto <bb 5>; [11.11%]

  <bb 6> [local count: 136334537]:
  # b_1 = PHI <0(2), b_7(5)>
  # DEBUG b => b_1
  # DEBUG BEGIN_STMT
  if (b_1 <= 6)
    goto <bb 8>; [87.50%]
  else
    goto <bb 7>; [12.50%]

  parent reply	other threads:[~2024-03-19 15:47 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-23  1:46 [Bug testsuite/109596] New: [14 Regression] Lots of testcases " haochen.jiang at intel dot com
2023-04-24  7:06 ` [Bug testsuite/109596] " rguenth at gcc dot gnu.org
2024-01-12 10:58 ` [Bug testsuite/109596] [14 Regression] Lots of guality testcase " rguenth at gcc dot gnu.org
2024-03-19 14:14 ` jakub at gcc dot gnu.org
2024-03-19 15:23 ` jakub at gcc dot gnu.org
2024-03-19 15:27 ` hubicka at gcc dot gnu.org
2024-03-19 15:41 ` jakub at gcc dot gnu.org
2024-03-19 15:47 ` hubicka at gcc dot gnu.org [this message]
2024-03-19 15:58 ` hubicka at gcc dot gnu.org
2024-03-19 16:28 ` jakub at gcc dot gnu.org
2024-03-19 22:28 ` jakub at gcc dot gnu.org
2024-03-20 11:50 ` jakub at gcc dot gnu.org
2024-04-10  7:13 ` rguenth at gcc dot gnu.org
2024-04-11  6:53 ` rguenth at gcc dot gnu.org
2024-04-11  9:11 ` cvs-commit at gcc dot gnu.org
2024-04-11  9:12 ` rguenth at gcc dot gnu.org
2024-04-12 18:14 ` carlos.seo at linaro dot org
2024-04-12 18:18 ` pinskia at gcc dot gnu.org
2024-04-12 18:24 ` carlos.seo at linaro dot org
2024-04-13 11:36 ` haochen.jiang at intel dot com
2024-04-15 18:53 ` hubicka at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-109596-4-KGCVUOGTWw@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).