[Patch, fortran] PR 37131, inline matmul
Mikael Morin
mikael.morin@sfr.fr
Tue Jul 21 17:27:00 GMT 2015
Le 20/07/2015 23:55, Thomas Koenig a écrit :
> Hi,
>
> I'm back from holiday, so I can finally reply.
>
>
> Am 13.07.2015 um 21:54 schrieb Thomas Schwinge:
>
>> --- gcc/fortran/iresolve.c
>> +++ gcc/fortran/iresolve.c
>> @@ -2207,6 +2207,9 @@ gfc_resolve_fe_runtime_error (gfc_code *c)
>> a->name = "%VAL";
>>
>> c->resolved_sym = gfc_get_intrinsic_sub_symbol (name);
>> + //TODO
>> + extern tree gfor_fndecl_runtime_error;
>> + c->resolved_sym->backend_decl = gfor_fndecl_runtime_error;
>> }
>
> This patch actually works quite well. I cannot check the varargs part
> on x86_64, but the non-return part is OK. Obviously, the backend decl
> for runtime_error needs to be set.
>
> The question is where to put this. iresolve.c seems conceptually wrong,
> but I cannot find a clean place to put this in trans-*, without
> special casing in strange places.
>
For what it's worth, I had started hacking on this; I attach what it
looks like after a few cleanups.
I would like to avoid the hack in iresolve. So let's reuse the
frontend-passes.c part of my patch (set resolved_isym) and then handle
it in gfc_conv_intrinsic_subroutine, the way my patch does it (I'm not
sure it actually fixes anything) or some other way (set
resolved_sym->backend_decl as in iresolve, ...).
Mikael
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Schwinge.diff
Type: text/x-patch
Size: 5953 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20150721/414d18ad/attachment.bin>
More information about the Fortran
mailing list