This is the mail archive of the
mailing list for the GCC project.
Re: Updated code for array argment passing
- From: Paul Brook <paul at nowt dot org>
- To: kejia_zh at nudt dot edu dot cn, fortran at gcc dot gnu dot org,gcc-patches at gcc dot gnu dot org
- Date: Tue, 25 Nov 2003 16:56:19 +0000
- Subject: Re: Updated code for array argment passing
- References: <20031125010416.7A9DE5C53B@ds20.nudt.edu.cn>
On Tuesday 25 November 2003 1:04 am, email@example.com wrote:
> Hi, paul
> I am sorry that the attach file I send last time did
> not include the modification code of trans-array.c.
> The new attach is all changes about array actual
> argument passing. would you please check them agian?
> 2003-11-24 Kejia Zhao <firstname.lastname@example.org>
> * trans-array.c (gfc_conv_array_parameter): Simplify
> array argument passing for array name actual argument.
> * trans-expr.c (gfc_conv_function_call): Ditto
> * trans-types.c (gfc_is_nodesc_array):Ditto.
! f = formal ? (!formal->sym->attr.pointer
! && formal->sym->as->type != AS_ASSUMED_SHAPE)
! : 0;
! g77 = (g77 && f) || sym->attr.always_explicit;
! gfc_conv_array_parameter (&parmse, arg->expr, argss, g77);
This is obviously wrong, and causes many testsuite failures. Please test
your patches with at least a "make check-f95" before submitting them.
You need to go back and recheck the logic in the above code. You also change
the value of "g77", making the calling convention dependent on the previous
arguments. This doesn't seem right.
Please also add a comment saying which calling convention (pointer (ie g77)
or array descriptor) is used in which circumstances.