public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "jiawei at iscas dot ac.cn" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/102892] [12 Regression] Dead Code Elimination Regression at -O3 (trunk vs 11.2.0)
Date: Fri, 22 Apr 2022 03:04:03 +0000 [thread overview]
Message-ID: <bug-102892-4-CtSTGExaoU@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-102892-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102892
jiawei <jiawei at iscas dot ac.cn> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jiawei at iscas dot ac.cn
--- Comment #11 from jiawei <jiawei at iscas dot ac.cn> ---
(In reply to Eric Botcazou from comment #8)
I use the RISC-V target test and get the same result, and link fail with
'undefined reference to `foo`'.
> The test fails (to link) on SPARC though, here's the .optimized dump at -O3:
>
> ;; Function main (main, funcdef_no=0, decl_uid=1488, cgraph_uid=1,
> symbol_order=1) (executed once)
>
> Removing basic block 8
> Removing basic block 9
> Removing basic block 10
> Removing basic block 11
> int main ()
> {
> unsigned int ivtmp.8;
> long int a;
> long int _1;
> void * _2;
> unsigned int _17;
>
> <bb 2> [local count: 44232128]:
> if (a_9(D) != 1)
> goto <bb 6>; [89.00%]
> else
> goto <bb 7>; [11.00%]
>
> <bb 3> [local count: 715863673]:
> # ivtmp.8_23 = PHI <ivtmp.8_24(5), ivtmp.8_7(6)>
> bar ();
> _2 = (void *) ivtmp.8_23;
> _1 = MEM[(long int *)_2];
> if (_1 == 1)
> goto <bb 4>; [20.24%]
> else
> goto <bb 5>; [79.76%]
>
> <bb 4> [local count: 144890806]:
> foo ();
>
> <bb 5> [local count: 715863674]:
> ivtmp.8_24 = ivtmp.8_23 + 4;
> if (_17 != ivtmp.8_24)
> goto <bb 3>; [66.67%]
> else
> goto <bb 7>; [33.33%]
>
> <bb 6> [local count: 238597362]:
> ivtmp.8_7 = (unsigned int) &b;
> _17 = ivtmp.8_7 + 8;
> goto <bb 3>; [100.00%]
>
> <bb 7> [local count: 44232131]:
> return 0;
> }
next prev parent reply other threads:[~2022-04-22 3:04 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-22 9:39 [Bug tree-optimization/102892] New: " theodort at inf dot ethz.ch
2021-10-22 9:48 ` [Bug tree-optimization/102892] " aldyh at gcc dot gnu.org
2021-10-22 21:19 ` pinskia at gcc dot gnu.org
2021-10-23 9:29 ` aldyh at gcc dot gnu.org
2021-11-10 14:24 ` marxin at gcc dot gnu.org
2021-11-10 15:42 ` aldyh at gcc dot gnu.org
2021-11-10 15:46 ` marxin at gcc dot gnu.org
2021-11-10 15:52 ` aldyh at gcc dot gnu.org
2021-11-10 19:27 ` cvs-commit at gcc dot gnu.org
2022-03-28 9:18 ` ebotcazou at gcc dot gnu.org
2022-03-28 14:37 ` aldyh at gcc dot gnu.org
2022-03-28 14:55 ` jakub at gcc dot gnu.org
2022-04-22 3:04 ` jiawei at iscas dot ac.cn [this message]
2022-05-04 0:50 ` [Bug tree-optimization/102892] [12/13 " palmer at gcc dot gnu.org
2022-05-04 0:50 ` palmer at gcc dot gnu.org
2022-05-04 11:58 ` jiawei at iscas dot ac.cn
2022-05-06 8:31 ` jakub at gcc dot gnu.org
2022-07-26 13:21 ` rguenth at gcc dot gnu.org
2022-09-29 22:34 ` cvs-commit at gcc dot gnu.org
2022-10-19 9:42 ` cvs-commit at gcc dot gnu.org
2022-10-19 9:43 ` rguenth 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-102892-4-CtSTGExaoU@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).