Re: [PATCH, rs6000] Fix PR78695

2016-12-11 Thread Bill Schmidt
Ah, I misread your comment and went hunting for DF_REF_ARTIFICIAL. Sorry! Will fix. Thanks again, Bill > On Dec 11, 2016, at 5:29 PM, Segher Boessenkool > wrote: > > On Sun, Dec 11, 2016 at 03:31:35PM -0600, Bill Schmidt wrote: >> On 12/11/16 2:00 PM, Segher Boessenkool wrote: >>> Maybe thi

Re: [PATCH, rs6000] Fix PR78695

2016-12-11 Thread Segher Boessenkool
On Sun, Dec 11, 2016 at 03:31:35PM -0600, Bill Schmidt wrote: > On 12/11/16 2:00 PM, Segher Boessenkool wrote: > > Maybe this should use DF_REF_IS_ARTIFICIAL? Or if that doesn't work, > > DF_REF_INSN_INFO? > > > OK, currently regstrapping the following, which also fixes the problem with > a non-bo

Re: [PATCH, rs6000] Fix PR78695

2016-12-11 Thread Bill Schmidt
Hi Segher, This indeed bootstrapped on powerpc64le-unknown-linux-gnu with no regressions. Ok for trunk? Thanks for the review! Bill On 12/11/16 3:31 PM, Bill Schmidt wrote: > Hi Segher, > > On 12/11/16 2:00 PM, Segher Boessenkool wrote: >> Maybe this should use DF_REF_IS_ARTIFICIAL? Or if th

Re: [PATCH, rs6000] Fix PR78695

2016-12-11 Thread Bill Schmidt
Hi Segher, On 12/11/16 2:00 PM, Segher Boessenkool wrote: > Maybe this should use DF_REF_IS_ARTIFICIAL? Or if that doesn't work, > DF_REF_INSN_INFO? > OK, currently regstrapping the following, which also fixes the problem with a non-bootstrap compiler. Is this ok for trunk if it succeeds? Thank

Re: [PATCH, rs6000] Fix PR78695

2016-12-11 Thread Segher Boessenkool
Hi Bill, On Sun, Dec 11, 2016 at 01:35:59PM -0600, Bill Schmidt wrote: > --- gcc/config/rs6000/rs6000.c(revision 243506) > +++ gcc/config/rs6000/rs6000.c(working copy) > @@ -41433,6 +41433,12 @@ find_alignment_op (rtx_insn *insn, rtx base_reg) >if (!base_def_link || base_de

[PATCH, rs6000] Fix PR78695

2016-12-11 Thread Bill Schmidt
Hi, PR78695 demonstrates a bug in swap analysis where we assume that a data-flow definition contains a nonzero insn_info. This assumption is wrong at least when -fstack-protector is in effect, as the definition of the base register of the stack protector is not associated with any insn. This pat