On Tue, Mar 8, 2011 at 6:56 PM, Michael Meissner <meiss...@linux.vnet.ibm.com> wrote: > PR 47755 fixed some bugs on VSX with V2DI constants, but the patch itself had > problems. In particular, the easy_altivec_constant support assumed the > largest > int size was SImode. This would cause the compiler to generate VSPLTI{W,S,B} > to load up a constant instead of loading it up from memory. > > This patch only allows (vector long long) { 0, 0 } and > (vector long long) { -1, -1 } as easy V2DI constants. There are some other > constants that could be generated using the Altivec instructions in the > future. > > I bootstrapped this patch and had no regressions with make check. Is it ok to > install? > > [gcc] > 2011-03-08 Michael Meissner <meiss...@linux.vnet.ibm.com> > > PR target/47755 > * config/rs6000/rs6000.c (easy_altivec_constant): Correctly handle > V2DI/V2DF constants. Only all 0's or all 1's are easy. > (output_vec_const_move): Ditto. > > [gcc/testsuite] > 2011-03-08 Michael Meissner <meiss...@linux.vnet.ibm.com> > > PR target/47755 > * gcc.target/powerpc/pr47755-2.c: New file.
Should the CONST_INT test be wrapped in #ifdef HOST_BITS_PER_WIDE_INT? Okay. Thanks, David