public inbox for gcc-prs@sourceware.org help / color / mirror / Atom feed
From: Glen Nakamura <glen@imodulo.com> To: nobody@gcc.gnu.org Cc: gcc-prs@gcc.gnu.org, Subject: Re: optimization/10185: [3.3/3.4 regression] Wrong code with 3-int-structs & optimization Date: Sat, 22 Mar 2003 08:16:00 -0000 [thread overview] Message-ID: <20030322081600.26770.qmail@sources.redhat.com> (raw) The following reply was made to PR optimization/10185; it has been noted by GNATS. From: Glen Nakamura <glen@imodulo.com> To: gcc-gnats@gcc.gnu.org, gcc-bugs@gcc.gnu.org, rassahah@neofonie.de Cc: Subject: Re: optimization/10185: [3.3/3.4 regression] Wrong code with 3-int-structs & optimization Date: Fri, 21 Mar 2003 22:13:39 -1000 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=10185 Aloha, This bug has similar symptoms to PR opt/10087. The gcse pass generates the following code (notice insn 106 is redundant to insn 103): (insn 22 88 103 3 0x4014b764 (parallel [ (set (reg/s:SI 65) (plus:SI (reg:SI 79) (const_int -1 [0xffffffff]))) (clobber (reg:CC 17 flags)) ]) 146 {*addsi_1} (nil) (nil)) (insn 103 22 23 3 (nil) (set (reg:SI 79) (reg/s:SI 65)) 38 {*movsi_1} (nil) (nil)) (insn 23 103 106 3 0x4014b764 (set (mem/f:SI (plus:SI (reg/f:SI 20 frame) (const_int -4 [0xfffffffc])) [5 S4 A32]) (reg/s:SI 65)) 38 {*movsi_1} (nil) (expr_list:REG_EQUAL (plus:SI (reg:SI 67) (const_int -1 [0xffffffff])) (nil))) (insn 106 23 25 3 (nil) (set (reg:SI 79) (reg/s:SI 65)) 38 {*movsi_1} (nil) (nil)) The loop pass then considers insn 103 and insn 106 as places where biv 79 is incremented. This is incorrect since insn 106 sets reg 76 to the same value as insn 103. Now during strength reduction, the giv is incremented after insn 103 and insn 106 resulting in a delta that is twice the correct value. This test case passes with the patch from: http://gcc.gnu.org/ml/gcc-patches/2003-03/msg01932.html - glen
next reply other threads:[~2003-03-22 8:16 UTC|newest] Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top 2003-03-22 8:16 Glen Nakamura [this message] -- strict thread matches above, loose matches on Subject: below -- 2003-03-24 19:08 mmitchel 2003-03-24 18:39 Jan Hubicka 2003-03-22 1:16 Janis Johnson 2003-03-21 22:56 Steven Bosscher 2003-03-21 15:40 bangerth
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=20030322081600.26770.qmail@sources.redhat.com \ --to=glen@imodulo.com \ --cc=gcc-prs@gcc.gnu.org \ --cc=nobody@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: linkBe 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).