[PATCH] rs6000: ICE when using an MMA type as a function param
Peter Bergner
bergner@linux.ibm.com
Wed Aug 12 02:07:40 GMT 2020
On 8/11/20 9:00 PM, Segher Boessenkool wrote:
> Not just params, but return values as well. "Error on MMA types in
> function prototype"?
Yes, it started out as a function param issue and then while working
on this, I decided I better look at what happens when they're used
as return values. I'll update the commit message to include return
values.
>> + static struct function *fn = NULL;
>> +
>> + /* We do not allow MMA types being used as return values. Only report
>> + the invalid return value usage the first time we encounter it. */
>> + if (for_return
>> + && fn != cfun
>> + && (mode == POImode || mode == PXImode))
>
> "fn" is always zero here.
>
>> + {
>> + fn = cfun;
>
> And what you set here is unused.
It's a static local variable, so how is it always zero and unused?
>> +/* { dg-options "-mdejagnu-cpu=power10 -O2 -w" } */
>
> Do you need -w or could a less heavy hammer work as well?
I could probably declare bar0(), bar1(), bar2() and bar3() and
those might go away? I didn't for some reason, but that may have
been for some earlier iteration of the test case. I'll have a
look at removing that.
Peter
More information about the Gcc-patches
mailing list