On Sat, Apr 15, 2017 at 01:43:18AM -0400, Michael Meissner wrote: > You are right, and my patch was too complicated. All I needed to do was > remove > the upper register checks. In looking at it, since the insn before being > split > has both register and memory versions, if the register allocator can't > allocate > a register, it will push the value on to the stack, and adjust the address > with > the variable index and do a load. Performance with the store and load, likely > will not be ideal, but it should work. > > Because of the interactions with the debug switches -mno-upper-regs-<xxx>, I > decided to add tests for all of the variable extract built-ins with each of > the > no-upper regs switches. > > I've tested this on a little endian power8 system and it bootstrapped and ran > make check with no regressions. Is it ok for the trunk?
Much simpler indeed :-) Looks fine to me, please commit. Thanks, Segher > 2017-04-15 Michael Meissner <meiss...@linux.vnet.ibm.com> > > PR target/80099 > * config/rs6000/rs6000.c (rs6000_expand_vector_extract): Eliminate > unneeded test for TARGET_UPPER_REGS_SF. > * config/rs6000/vsx.md (vsx_extract_v4sf_var): Likewise. > > [gcc/testsuite] > 2017-04-15 Michael Meissner <meiss...@linux.vnet.ibm.com> > > PR target/80099 > * gcc.target/powerpc/pr80099-1.c: New test. > * gcc.target/powerpc/pr80099-2.c: Likewise. > * gcc.target/powerpc/pr80099-3.c: Likewise. > * gcc.target/powerpc/pr80099-4.c: Likewise. > * gcc.target/powerpc/pr80099-5.c: Likewise.