This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Do not emit SAVE_EXPR for already assigned SSA_NAMEs (PR71606).


On Thu, Jul 7, 2016 at 4:01 PM, Martin Liška <mliska@suse.cz> wrote:
> On 07/01/2016 12:15 PM, Richard Biener wrote:
>> IMHO using fold-convert in this case is bogus and ideally the testcase
>> should have been diagnosed.
>>
>> fold_convertible_p has a comment
>>
>> /* Returns true, if ARG is convertible to TYPE using a NOP_EXPR.  *
>>
>> but clearly it isn't generating just a NOP_EXPR (or VIEW_CONVERT_EXPR
>> or other single operation) here.
>>
>> So that is the thing to fix.  The way we build / insert the init stmts
>> can also be improved by properly
>> gimplifying the rhs first but of course that likely runs into the
>> SAVE_EXPR case you mentioned.
>>
>> Richard.
>
> Hello Richard.
>
> I've tried to mark COMPLEX_TYPE as not acceptable by fold_convertible_p,
> which fixes the ICE and regression and bootstrap on x86_64-linux-gnu also looks
> fine.
>
> Is it sufficient, or we would need more sophisticated approach to handle the PR?

I think it's fine though the inliners initializer handling looks
incredibly fragile to me ;)

Richard.

> Thanks,
> Martin


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]