Re: [PATCH, reload] PRE_INC with invalid hard reg

2016-02-12 Thread Bernd Schmidt
On 02/12/2016 04:27 AM, Alan Modra wrote: I don't understand this comment. If we're pushing a reload of the inner reg, then the SECONDARY_MEMORY_NEEDED code in push_reload will fire. Why then should there be any need to do anything special in find_reloads_address_1 regarding secondary memory?

Re: [PATCH, reload] PRE_INC with invalid hard reg

2016-02-12 Thread Jeff Law
On 02/11/2016 08:27 PM, Alan Modra wrote: On Thu, Feb 11, 2016 at 03:29:05PM +0100, Bernd Schmidt wrote: On 02/11/2016 10:45 AM, Alan Modra wrote: Due to uses elsewhere in vsx instructions, reload chooses to put psuedo 185 in fr31, which can't be used as a base register in the following: Wha

Re: [PATCH, reload] PRE_INC with invalid hard reg

2016-02-11 Thread Alan Modra
On Thu, Feb 11, 2016 at 03:29:05PM +0100, Bernd Schmidt wrote: > On 02/11/2016 10:45 AM, Alan Modra wrote: > > >Due to uses elsewhere in vsx instructions, reload chooses to put > >psuedo 185 in fr31, which can't be used as a base register in the > >following: > > What code exactly makes the choic

Re: [PATCH, reload] PRE_INC with invalid hard reg

2016-02-11 Thread Bernd Schmidt
On 02/11/2016 10:45 AM, Alan Modra wrote: Due to uses elsewhere in vsx instructions, reload chooses to put psuedo 185 in fr31, which can't be used as a base register in the following: What code exactly makes the choice of fr31? I assume this is in reg_renumber, so it's IRA and not reload that

[PATCH, reload] PRE_INC with invalid hard reg

2016-02-11 Thread Alan Modra
This is PR68973 part 1, the fix for the regression of g++.dg/pr67211.C on powerpc64-linux -mcpu=power7, which turns out to be a reload problem. Due to uses elsewhere in vsx instructions, reload chooses to put psuedo 185 in fr31, which can't be used as a base register in the following: (se