public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "vda.linux at googlemail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug rtl-optimization/21182] [4.6/4.7/4.8 Regression] gcc can use registers but uses stack instead Date: Sun, 20 Jan 2013 14:40:00 -0000 [thread overview] Message-ID: <bug-21182-4-ZATLAj360r@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-21182-4@http.gcc.gnu.org/bugzilla/> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21182 --- Comment #11 from Denis Vlasenko <vda.linux at googlemail dot com> 2013-01-20 14:39:42 UTC --- (In reply to comment #10) > 4.4.7 and 4.5.4 generate the same code (no stack use) for -D/-UNAIL_REGS. > With 4.6.3, the -DNAIL_REGS code regresses very much (IRA ...), the > -UNAIL_REGS code is nearly perfect but less good than 4.4/4.5 (if you > only consider grep esp serpent.s | wc -l). Same behavior with 4.7.2. > > Trunk got somewhat worse with -UNAIL_REGS but better with -DNAIL_REGS (at -O2): > > -UNAIL_REGS -DNAIL_REGS > 4.5.4 3 3 > 4.6.3 15 101 This matches what I see with 4.6.3 - 15 insns with %esp (and no %ebp): $ grep '%esp' serpent-4.6.3-O2.asm 4: 83 ec 04 sub $0x4,%esp 7: 8b 4c 24 20 mov 0x20(%esp),%ecx b: 8b 44 24 18 mov 0x18(%esp),%eax 22e: 89 0c 24 mov %ecx,(%esp) 239: 23 3c 24 and (%esp),%edi 588: 89 0c 24 mov %ecx,(%esp) 58f: 23 3c 24 and (%esp),%edi 8f4: 89 0c 24 mov %ecx,(%esp) 8fd: 23 3c 24 and (%esp),%edi c60: 89 0c 24 mov %ecx,(%esp) c6b: 23 3c 24 and (%esp),%edi d37: 89 14 24 mov %edx,(%esp) d5a: 8b 44 24 1c mov 0x1c(%esp),%eax d5e: 33 14 24 xor (%esp),%edx d70: 83 c4 04 add $0x4,%esp > The most important thing to fix is the -UNAIL_REGS case of course. Sure. NAIL_REGS is only a hack meant to demonstrate that regs *can* be allocated optimally.
next prev parent reply other threads:[~2013-01-20 14:40 UTC|newest] Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top [not found] <bug-21182-4@http.gcc.gnu.org/bugzilla/> 2013-01-18 0:48 ` [Bug rtl-optimization/21182] " vda.linux at googlemail dot com 2013-01-18 0:51 ` vda.linux at googlemail dot com 2013-01-18 0:55 ` vda.linux at googlemail dot com 2013-01-18 0:57 ` pinskia at gcc dot gnu.org 2013-01-18 10:39 ` [Bug rtl-optimization/21182] [4.6/4.7/4.8 Regression] " rguenth at gcc dot gnu.org 2013-01-20 14:40 ` vda.linux at googlemail dot com [this message] 2013-03-13 20:38 ` steven at gcc dot gnu.org 2013-04-12 15:18 ` [Bug rtl-optimization/21182] [4.7/4.8/4.9 " jakub at gcc dot gnu.org 2014-06-12 13:49 ` [Bug rtl-optimization/21182] [4.7/4.8/4.9/4.10 " rguenth at gcc dot gnu.org 2014-12-19 13:35 ` [Bug rtl-optimization/21182] [4.8/4.9/5 " jakub at gcc dot gnu.org 2015-06-23 8:35 ` [Bug rtl-optimization/21182] [4.8/4.9/5/6 " rguenth at gcc dot gnu.org 2015-06-26 20:03 ` [Bug rtl-optimization/21182] [4.9/5/6 " jakub at gcc dot gnu.org 2015-06-26 20:32 ` jakub at gcc dot gnu.org 2021-01-26 13:43 ` [Bug rtl-optimization/21182] [8/9/10/11 " rguenth at gcc dot gnu.org 2021-04-27 11:37 ` [Bug rtl-optimization/21182] [8/9/10/11/12 " jakub at gcc dot gnu.org 2021-07-28 7:04 ` [Bug rtl-optimization/21182] [9/10/11/12 " rguenth at gcc dot gnu.org 2022-04-21 7:47 ` rguenth at gcc dot gnu.org 2023-05-29 10:01 ` [Bug rtl-optimization/21182] [10/11/12/13/14 " jakub at gcc dot gnu.org 2023-07-15 7:36 ` [Bug rtl-optimization/21182] [11/12/13/14 " pinskia 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-21182-4-ZATLAj360r@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: 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).