[Bug tree-optimization/126856] [17 Regression] mpfr and mpc started failing tests recently since r17-3204

amacleod at redhat dot com via Gcc-bugs <[email protected]>
Newsgroups gmane.comp.gcc.bugs
Message-ID <[email protected]/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=126856

--- Comment #3 from Andrew Macleod <amacleod at redhat dot com> ---
(In reply to Drea Pinski from comment #1)
> Confirmed.
> 
> What is happening is we have:
>   exp.0_1 = (unsigned int) exp_8(D);
> 
> Which gets recorded as:
> Folding statement: exp.0_1 = (unsigned int) exp_8(D);
>  Registering value_relation (exp.0_1 pe32 exp_8(D)) (bb2) at exp.0_1 =
> (unsigned int) exp_8(D);
> 
> 
> and then when the simple_dce happens we change the assignment to exp.0_1 to:
> 
> exp.0_1 = 0;
> 
> And then we look at:
> Folding statement: _5 = (short unsigned int) exp_8(D);
>  Registering value_relation (_5 pe16 exp_8(D)) (bb6) at _5 = (short unsigned
> int) exp_8(D);
> Queued stmt for removal.  Folds to: 0
> 
> Which is wrong.
> 
> So this is caused by r17-3204-ge02ce3b8c4574c.
> 
> Let me try to get a testcase without unions and fp.

Nice analysis.  ugg.  Thats not pretty.  I need to sleep on that one.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.