This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/32131] knowing that stride==1 when using allocated arrays and escaping allocatable arrays
- From: "tkoenig at alice-dsl dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 29 May 2007 17:47:30 -0000
- Subject: [Bug fortran/32131] knowing that stride==1 when using allocated arrays and escaping allocatable arrays
- References: <bug-32131-10391@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #5 from tkoenig at alice-dsl dot net 2007-05-29 17:47 -------
Subject: Re: knowing that stride==1 when using
allocated arrays and escaping allocatable arrays
On Tue, 2007-05-29 at 04:52 +0000, pinskia at gcc dot gnu dot org wrote:
> we think we change a's stride
> which we don't (and cannot in this case).
I can see two ways to address this issue (both of them worth pursuing):
a) For allocatable arrays, we can always assume stride=1.
b) We can tell the middle-end that our random number generator doesn't
modify the array descriptor (similar to PR 20165). Once we've fixed
PR 20165, this should be easy, but I don't see anybody working on it.
So, maybe looking at a) is better.
Personally, I like the allocatable array feature of Fortran 95 very
much. It'd be a pity if this carried a big performance overhead.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32131