On Tue, Dec 18, 2018 at 08:25:37AM +0100, Uros Bizjak wrote: > > <case IX86_BUILTIN_GATHER3ALTDIV8SF>: Check for non-VECTOR_MODE_P > > rather than VOIDmode. > > This entry doesn't match the change, you are checking for > VECTOR_MODE_P. On a related note, should similar
Ok, I'll write: Check for VECTOR_MODE_P rather than non-VOIDmode. > IX86_BUILTIN_GATHER3ALTDIV16{SF,SI} builtins be changed in the same > way? No, because IX86_BUILTIN_GATHER3ALTDIV16S{F,I} has always the HImode for the mask argument (sometimes CONST_INT with VOIDmode) and wants QImode. The reason we need the change in this patch is that we have the same case handling: case IX86_BUILTIN_GATHERALTDIV8SF: case IX86_BUILTIN_GATHERALTDIV8SI: which have V8S[IF]mode for the mask argument and we want to do what is inside of the if where the patch changes the guard, and case IX86_BUILTIN_GATHER3ALTDIV8SF: case IX86_BUILTIN_GATHER3ALTDIV8SI: which have QImode mask argument (sometimes CONST_INT with VOIDmode) and wants QImode (just cares about the low 4 bits of it rather than all 8 bits it was passed in). We could use a kand, but the instruction ignores the argument and we'd need to load the mask immediate 15 into a register, copy it into a mask register and then kand. Jakub