public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "zhouyi04 at ios dot cn" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/35452] erasing uncessary warning for basic block frequency computation
Date: Wed, 05 Mar 2008 07:03:00 -0000	[thread overview]
Message-ID: <20080305070313.30083.qmail@sourceware.org> (raw)
In-Reply-To: <bug-35452-14209@http.gcc.gnu.org/bugzilla/>



------- Comment #1 from zhouyi04 at ios dot cn  2008-03-05 07:03 -------
(In reply to comment #0)
Sorry there are some problem with 1st patch because the edge e
maybe removed after redirection.
 2    4
 | \ /
 \  5
  \ |
    6
In function redirect_edge_succ_nodup, the edge from 5 to 6 will
be removed because there exists one from 2 to 6.

following is correct patch:
--- gcc/gcc/tree-cfgcleanup.c~  Wed Mar  5 14:13:00 2008
+++ gcc/gcc/tree-cfgcleanup.c   Wed Mar  5 14:13:52 2008
@@ -418,6 +418,10 @@
     {
       bitmap_set_bit (cfgcleanup_altered_bbs, e->src->index);

+
+      bb->frequency -= EDGE_FREQUENCY(e);
+      bb->count -= e->count;
+
       if (e->flags & EDGE_ABNORMAL)
        {
          /* If there is an abnormal edge, redirect it anyway, and

#########################################################
By the way, the frequency and count of forwarder block's succor will not be
affected because he is the only child of the forwarder block.

Anyone help me regression test it please


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35452


  reply	other threads:[~2008-03-05  7:03 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-04  3:34 [Bug tree-optimization/35452] New: " zhouyi04 at ios dot cn
2008-03-05  7:03 ` zhouyi04 at ios dot cn [this message]
2009-04-18 20:01 ` [Bug tree-optimization/35452] " steven at gcc dot gnu dot 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=20080305070313.30083.qmail@sourceware.org \
    --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).