public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "tkoenig at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug target/95018] [10/11 Regression] Excessive unrolling for Fortran library array handling Date: Mon, 11 May 2020 19:13:38 +0000 [thread overview] Message-ID: <bug-95018-4-BTo7SERRoN@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-95018-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95018 --- Comment #16 from Thomas Koenig <tkoenig at gcc dot gnu.org> --- Hi, I was unable to find a performance problem, so I take back my presumption of the original problem. I have checked two versions of the preprocessed source, with +#pragma GCC unroll 1 while (count[n] == extent[n]) { as the difference. What I found was that with the pragma and -O2 - stack size decreased from 752 bytes to 432 bytes, from the stdu 1,-752(1) instruction - object code size decreased from 7042 to 1936 bytes, determined by looking at the addresses of objdump --disassemble (I also found that #pragma GCC unroll 2 was ignored, but that's for another PR). Considering we have this idiom around 400 times in libgfortran, I would estimate an increase of the size of libgfortan of around two Megabytes. So, what to do? I don't know if the gcc optimization routines can even consider this particular loop to be one that is not often used, although it is an inner loop. As far as libgfortran is concerned, we could simply use the pragma on our sources, but maybe other people have the same issue.
next prev parent reply other threads:[~2020-05-11 19:13 UTC|newest] Thread overview: 40+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-05-09 7:58 [Bug target/95018] New: " tkoenig at gcc dot gnu.org 2020-05-09 8:00 ` [Bug target/95018] " tkoenig at gcc dot gnu.org 2020-05-09 8:10 ` tkoenig at gcc dot gnu.org 2020-05-09 8:36 ` [Bug target/95018] [11 Regression] " tkoenig at gcc dot gnu.org 2020-05-09 9:01 ` tkoenig at gcc dot gnu.org 2020-05-09 9:03 ` tkoenig at gcc dot gnu.org 2020-05-09 9:42 ` [Bug target/95018] [10/11 " tkoenig at gcc dot gnu.org 2020-05-09 13:21 ` tkoenig at gcc dot gnu.org 2020-05-11 5:03 ` tkoenig at gcc dot gnu.org 2020-05-11 5:18 ` tkoenig at gcc dot gnu.org 2020-05-11 7:53 ` guojiufu at gcc dot gnu.org 2020-05-11 8:07 ` guojiufu at gcc dot gnu.org 2020-05-11 8:13 ` guojiufu at gcc dot gnu.org 2020-05-11 8:32 ` guojiufu at gcc dot gnu.org 2020-05-11 9:20 ` tkoenig at gcc dot gnu.org 2020-05-11 14:09 ` guojiufu at gcc dot gnu.org 2020-05-11 19:13 ` tkoenig at gcc dot gnu.org [this message] 2020-05-12 5:58 ` guojiufu at gcc dot gnu.org 2020-05-12 6:06 ` guojiufu at gcc dot gnu.org 2020-05-12 7:41 ` rguenth at gcc dot gnu.org 2020-05-12 7:50 ` rguenth at gcc dot gnu.org 2020-05-12 9:30 ` tkoenig at gcc dot gnu.org 2020-05-12 9:46 ` tkoenig at gcc dot gnu.org 2020-05-12 10:08 ` rguenth at gcc dot gnu.org 2020-05-12 10:27 ` rguenther at suse dot de 2020-05-13 2:33 ` guojiufu at gcc dot gnu.org 2020-05-13 2:59 ` guojiufu at gcc dot gnu.org 2020-05-13 3:37 ` guojiufu at gcc dot gnu.org 2020-05-13 6:07 ` rguenth at gcc dot gnu.org 2020-05-13 7:54 ` tkoenig at gcc dot gnu.org 2020-05-13 8:14 ` rguenth at gcc dot gnu.org 2020-05-13 9:54 ` guojiufu at gcc dot gnu.org 2020-05-13 10:14 ` rguenth at gcc dot gnu.org 2020-05-13 11:24 ` guojiufu at gcc dot gnu.org 2020-05-19 5:42 ` guojiufu at gcc dot gnu.org 2020-06-07 9:41 ` cvs-commit at gcc dot gnu.org 2020-06-08 2:54 ` guojiufu at gcc dot gnu.org 2020-06-08 5:12 ` tkoenig at gcc dot gnu.org 2020-06-09 2:50 ` guojiufu at gcc dot gnu.org 2020-06-19 14:39 ` cvs-commit 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-95018-4-BTo7SERRoN@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).