public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "burnus at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/41137] inefficient zeroing of an array
Date: Mon, 21 Jun 2010 15:02:00 -0000	[thread overview]
Message-ID: <20100621150206.12616.qmail@sourceware.org> (raw)
In-Reply-To: <bug-41137-6642@http.gcc.gnu.org/bugzilla/>



------- Comment #7 from burnus at gcc dot gnu dot org  2010-06-21 15:02 -------
(In reply to comment #1)
> Just for reference, the difference in time between the two variants is truly
> impressive. About a factor of 11 with gcc 4.4 and 8 with gcc 4.5.

I get for the example the following values, note especially the newly added
CONTIGUOUS result:

  0.31601900     - assumed-shape
  0.21601403     - assumed-shape CONTIGUOUS 
  0.21601295      - explicit size (n,n,...)
  0.20801300      - explicit size (10,10,...)
  0.21601403      - explicit size (10*10*...)

Ignoring some measuring noise, assumed-shape is 46% (-O0) to 25% (-O3) slower
than explicit  size, but using the CONTIGUOUS attribute, the performance is
re-gained. I cannot reproduce the factor of 10 results, however. What surprises
me a bit is that -flto -fwhole-program does not reduce the speed penalty of
assumed-shape arrays.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41137


  parent reply	other threads:[~2010-06-21 15:02 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-21  6:15 [Bug fortran/41137] New: " jv244 at cam dot ac dot uk
2009-08-21  7:02 ` [Bug fortran/41137] " jv244 at cam dot ac dot uk
2009-08-21  7:40 ` dfranke at gcc dot gnu dot org
2009-08-21  8:29 ` jv244 at cam dot ac dot uk
2009-08-24 20:06 ` jv244 at cam dot ac dot uk
2009-11-01 16:21 ` tkoenig at gcc dot gnu dot org
2009-11-01 17:36 ` tkoenig at gcc dot gnu dot org
2010-05-07 21:02 ` dfranke at gcc dot gnu dot org
2010-06-21 15:02 ` burnus at gcc dot gnu dot org [this message]
2010-06-21 15:22 ` burnus at gcc dot gnu dot org
2010-06-21 15:49 ` jv244 at cam dot ac dot uk
2010-06-21 17:00 ` burnus at gcc dot gnu dot org
2010-06-21 17:44 ` jakub at gcc dot gnu dot org
2010-06-22 14:42 ` burnus at gcc dot gnu dot org
2010-06-22 15:25 ` jakub at gcc dot gnu dot org
     [not found] <bug-41137-4@http.gcc.gnu.org/bugzilla/>
2013-03-29  9:47 ` Joost.VandeVondele at mat dot ethz.ch
2013-03-29 22:19 ` tkoenig at gcc dot gnu.org
2013-03-29 22:39 ` burnus at gcc dot gnu.org
2014-05-01 12:16 ` dominiq at lps dot ens.fr
2014-05-01 12:35 ` Joost.VandeVondele at mat dot ethz.ch
2014-05-01 17:00 ` tkoenig 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=20100621150206.12616.qmail@sourceware.org \
    --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).