public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Michael Matz <matz@suse.de>
To: Steven Bosscher <stevenb.gcc@gmail.com>
Cc: Paul Richard Thomas <paul.richard.thomas@gmail.com>,
	Dominique Dhumieres <dominiq@lps.ens.fr>,
	fortran@gcc.gnu.org,	gcc-patches@gcc.gnu.org
Subject: Re: Implement stack arrays even for unknown sizes
Date: Tue, 12 Apr 2011 11:54:00 -0000	[thread overview]
Message-ID: <Pine.LNX.4.64.1104121323070.1989@wotan.suse.de> (raw)
In-Reply-To: <BANLkTinR1XsZcNY1rPDnksB72NsdW_8Guw@mail.gmail.com>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 1456 bytes --]

Hello,

On Mon, 11 Apr 2011, Steven Bosscher wrote:

> > Try this patch.  I've verified that capacita and nf work with it and
> > -march=native -ffast-math -funroll-loops -fstack-arrays -O3 .  In fact all
> > of polyhedron works for me on these flags.  (I've set a ulimit -s of
> > 512MB, but I don't know if such a large amount is required).
> 
> FWIW, I don't think it is reasonable to require ulimit -s to run
> polyhedron.

Actually only nf requires about 16MB of stack size, all other benchmarks 
run fine with 8MB (which is the default for my systems).  Note that ICC 
compiled binaries have the same behaviour and also require the user to set 
ulimits.

> Isn't there a way to put a maximum on the size of the arrays on stack, 
> e.g. -fstack-arrays-limit= or something like that?

Not without generating contorded code.  The problem is that these arrays 
are variable length, hence runtime tests would be required, branching to 
malloc or stack_save/alloca, and also for the deallocation side, requiring 
a flag for branching to free or stack_restore.  And as we use the variable 
length facilities this is actually not controllable in such a way, the 
frontend doesn't generate alloca calls at all.

Nope, it's either all or nothing, like with ICC.

> BTW why does trans-array need gimple.h?

create_tmp_var_name.  gfc_create_var_np doesn't take a location and at 
that point input_location is already at the end of file.


Ciao,
Michael.

  reply	other threads:[~2011-04-12 11:54 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-09 10:08 Dominique Dhumieres
2011-04-09 12:17 ` Paul Richard Thomas
2011-04-10 13:29   ` Dominique Dhumieres
2011-04-11 11:49     ` Michael Matz
2011-04-11 11:58       ` Axel Freyn
2011-04-11 13:35       ` Eric Botcazou
2011-04-11 14:06         ` Dominique Dhumieres
2011-04-11 14:59         ` Michael Matz
2011-04-11 16:04   ` Michael Matz
2011-04-11 16:45     ` Steven Bosscher
2011-04-12 11:54       ` Michael Matz [this message]
2011-04-12 12:42         ` N.M. Maclaren
2011-04-11 16:46     ` Dominique Dhumieres
2011-04-11 16:59     ` H.J. Lu
2011-04-11 17:06       ` N.M. Maclaren
2011-04-11 18:28     ` Tobias Burnus
2011-04-11 21:18     ` Dominique Dhumieres
2011-04-12  6:23     ` Paul Richard Thomas
2011-04-12  6:35       ` Dominique Dhumieres
2011-04-13  9:42         ` Paul Richard Thomas
2011-04-13 10:38           ` Richard Guenther
2011-04-13 11:13             ` Richard Guenther
2011-04-14 13:32               ` Dominique Dhumieres
2011-04-13 13:46             ` Paul Richard Thomas
2011-04-14 13:59         ` Michael Matz
2011-04-14 15:28           ` Michael Matz
2011-04-14 19:29             ` Dominique Dhumieres
2011-04-15  2:01             ` Dominique Dhumieres
2011-04-15 12:38               ` Michael Matz
2011-04-15 14:06                 ` Dominique Dhumieres
2011-04-15 15:19                   ` Michael Matz
2011-04-15 15:26                     ` Jerry DeLisle
2011-04-15 22:41                       ` Michael Matz
2011-04-14 20:23     ` Tobias Burnus
2011-04-14 20:30       ` Tobias Burnus
  -- strict thread matches above, loose matches on Subject: below --
2011-04-08 21:29 Michael Matz
2011-04-09  8:21 ` N.M. Maclaren
2011-04-09  8:51   ` Magnus Fromreide
2011-04-09  9:02   ` Eric Botcazou
2011-04-09  9:49     ` N.M. Maclaren

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=Pine.LNX.4.64.1104121323070.1989@wotan.suse.de \
    --to=matz@suse.de \
    --cc=dominiq@lps.ens.fr \
    --cc=fortran@gcc.gnu.org \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=paul.richard.thomas@gmail.com \
    --cc=stevenb.gcc@gmail.com \
    /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).