Message ID | 20160804051434.GK20904@bubble.grove.modra.org |
---|---|
State | New |
Headers | show |
On Thu, Aug 04, 2016 at 02:44:34PM +0930, Alan Modra wrote: > On Wed, Aug 03, 2016 at 03:30:53PM -0400, Michael Meissner wrote: > > On Mon, Aug 01, 2016 at 09:00:43AM +0930, Alan Modra wrote: > > > Hi Mike, > > > I've been looking at a lot of reload/lra code lately in trying to fix > > > pr71680, and noticed a change to rs6000_preferred_reload_class. > > > > > > In https://gcc.gnu.org/ml/gcc-patches/2016-05/msg00134.html you made > > > preferred_reload_class pick a register class when given NO_REGS as an > > > argument. That seems odd to me given the usual behaviour of > > > preferred_reload_class is to restrict reg classes. Did you mean to > > > make that change? I'm wondering whether something you were playing > > > with escaped upstream, because there is no ChangeLog for it as far as > > > I can see.. > > > > I was playing with that, but given the patch was meant to be complex only, I > > suspect we should try taking it out now, and see if it affects anything. > > Now bootstrapped and regression tested powerpc64le-linux and > powerpc64-linux. OK to apply? Okay, thanks, Segher > * config/rs6000/rs6000.c (rs6000_preferred_reload_class): Delete > code accidentally committed 2016-05-02 providing class when given > NO_REGS.
diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index 5a9ddd9..b923cfb 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -20441,25 +20441,6 @@ rs6000_preferred_reload_class (rtx x, enum reg_class rclass) return NO_REGS; } - /* If we haven't picked a register class, and the type is a vector or - floating point type, prefer to use the VSX, FPR, or Altivec register - classes. */ - if (rclass == NO_REGS) - { - if (TARGET_VSX && VECTOR_MEM_VSX_OR_P8_VECTOR_P (mode)) - return VSX_REGS; - - if (TARGET_ALTIVEC && VECTOR_MEM_ALTIVEC_P (mode)) - return ALTIVEC_REGS; - - if (DECIMAL_FLOAT_MODE_P (mode)) - return TARGET_DFP ? FLOAT_REGS : NO_REGS; - - if (TARGET_FPRS && TARGET_HARD_FLOAT && FLOAT_MODE_P (mode) - && (reg_addr[mode].addr_mask[RELOAD_REG_FPR] & RELOAD_REG_VALID) != 0) - return FLOAT_REGS; - } - if (GET_MODE_CLASS (mode) == MODE_INT && rclass == NON_SPECIAL_REGS) return GENERAL_REGS;