public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/52285] New: [4.7 Regression] libgcrypt _gcry_burn_stack slowdown Date: Thu, 16 Feb 2012 18:28:00 -0000 [thread overview] Message-ID: <bug-52285-4@http.gcc.gnu.org/bugzilla/> (raw) http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52285 Bug #: 52285 Summary: [4.7 Regression] libgcrypt _gcry_burn_stack slowdown Classification: Unclassified Product: gcc Version: 4.7.0 Status: UNCONFIRMED Keywords: missed-optimization Severity: normal Priority: P3 Component: tree-optimization AssignedTo: unassigned@gcc.gnu.org ReportedBy: jakub@gcc.gnu.org #define wipememory2(_ptr,_set,_len) do { \ volatile char *_vptr=(volatile char *)(_ptr); \ unsigned long _vlen=(_len); \ while(_vlen) { *_vptr=(_set); _vptr++; _vlen--; } \ } while(0) #define wipememory(_ptr,_len) wipememory2(_ptr,0,_len) __attribute__((noinline, noclone)) void _gcry_burn_stack (int bytes) { char buf[64]; wipememory (buf, sizeof buf); bytes -= sizeof buf; if (bytes > 0) _gcry_burn_stack (bytes); } is one of the hot parts of gcrypt camellia256 ECB benchmark which apparently slowed down in 4.7 compared to 4.6. The routine is called many times, usually with bytes equal to 372. The above first slowed down the whole benchmark from ~ 2040ms to ~ 2400ms (-O2 -march=corei7-avx -fPIC) in http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=178104 and then (somewhat surprisingly) became tiny bit faster again with http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=181172 , which no longer tail recursion optimizes the function (in this case suprisingly a win, but generally IMHO a mistake).
next reply other threads:[~2012-02-16 18:23 UTC|newest] Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top 2012-02-16 18:28 jakub at gcc dot gnu.org [this message] 2012-02-16 18:41 ` [Bug tree-optimization/52285] " jakub at gcc dot gnu.org 2012-02-16 18:47 ` jakub at gcc dot gnu.org 2012-02-16 18:53 ` jakub at gcc dot gnu.org 2012-02-16 23:07 ` jakub at gcc dot gnu.org 2012-02-20 11:20 ` jakub at gcc dot gnu.org 2012-02-20 21:46 ` [Bug middle-end/52285] " pinskia at gcc dot gnu.org 2012-02-22 10:10 ` jakub at gcc dot gnu.org 2012-03-22 9:00 ` [Bug middle-end/52285] [4.7/4.8 " rguenth at gcc dot gnu.org 2012-06-14 8:29 ` rguenth at gcc dot gnu.org 2012-09-20 10:23 ` jakub at gcc dot gnu.org 2012-11-13 10:30 ` steven at gcc dot gnu.org 2012-11-13 10:44 ` jakub at gcc dot gnu.org 2012-11-13 23:38 ` steven at gcc dot gnu.org 2013-04-11 8:00 ` [Bug middle-end/52285] [4.7/4.8/4.9 " rguenth at gcc dot gnu.org 2014-06-12 13:49 ` [Bug middle-end/52285] [4.7/4.8/4.9/4.10 " rguenth at gcc dot gnu.org 2014-12-19 13:42 ` [Bug middle-end/52285] [4.8/4.9/5 " jakub at gcc dot gnu.org 2015-06-23 8:25 ` [Bug middle-end/52285] [4.8/4.9/5/6 " rguenth at gcc dot gnu.org 2015-06-26 20:17 ` [Bug middle-end/52285] [4.9/5/6 " jakub at gcc dot gnu.org 2015-06-26 20:38 ` jakub at gcc dot gnu.org 2021-05-14 9:46 ` [Bug middle-end/52285] [9/10/11/12 " jakub at gcc dot gnu.org 2021-06-01 8:05 ` rguenth at gcc dot gnu.org 2022-05-27 9:34 ` [Bug middle-end/52285] [10/11/12/13 " rguenth at gcc dot gnu.org 2022-06-28 10:30 ` jakub at gcc dot gnu.org 2023-07-07 10:29 ` [Bug middle-end/52285] [11/12/13/14 " 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-52285-4@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).