This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: g77 extension
- To: gcc at gcc dot gnu dot org
- Subject: Re: g77 extension
- From: Robert Anderson <rwa at alumni dot princeton dot edu>
- Date: Mon, 25 Jun 2001 08:32:56 -0700
- References: <Pine.LNX.4.31.0106251104010.1219-100000@cobra.localhost>
Robert Bernecky wrote:
> You could use SAC, APL, J, or perhaps even g95 -- a
> Fortran-9x dialect. I'm not sure how flexible g95 is -- haven't
> had time to look at it.
Are you proposing that I port a half million lines of numerical software to
the APL or J programming languages? That is, uh, not an option. g95 is also
not an option since it doesn't do anything but parse yet.
> There are a lot of problems
> with limitations in old languages that were not
> designed with arrays in mind.
f77 was not designed with arrays in mind? I find that an equally bizarre
statement to the suggestion that I port to APL.
Ideally what I would like is for someone with knowledge of g77 internals to
pipe up with a "that's do-able" or a "that's semi-doable" or a "that will
occupy you full time for 6 months" insight.
Thanks,
Bob
> > I am interested in extending g77 to allow array indexed expressions in
> > the declaration of array bounds. I believe this is not standard f77,
> > but I have yet to find any other f77 compiler that does not allow it.
> >
> > For example:
> >
> > subroutine sub(a,n)
> > integer n(2)
> > real a(n(1):n(2))
> >
> > g77 will not compile this due to the array indexing in the bounds
> > specification for array a. I have almost no experience with compiler
> > writing, but I would like to know if anyone knows what would be involved
> > in adding this extension. Is this 10 man-hours? 100 man-hours? A
> > complete rewrite?
> >
> > I am aware of the obvious workaround of passing scalars, but I have
> > about a half million lines of code where this construct is ubiquitous,
> > and rewriting to cater to only g77 may involve more effort than
> > modifying g77 itself (then again, it may not, this is what I'm trying to
> > determine).
> >
> > Any g77 gurus willing to comment?
> >
> > Thanks,
> > Bob Anderson
> >
> >
>
> Robert Bernecky Snake Island Research Inc.
> bernecky@acm.org 18 Fifth Street, Ward's Island
> +1 416 203 0854 Toronto, Ontario M5J 2B9 Canada
> http://www.snakeisland.com