Re: [PATCH] i386: Fix ix86_fold_builtin shift folding [PR93418]

2020-01-27 Thread Jeff Law
On Tue, 2020-01-28 at 00:41 +0100, Jakub Jelinek wrote: > Hi! > > The following testcase is miscompiled, because the variable shift left > operand, { -1, -1, -1, -1 } is represented as a VECTOR_CST with > VECTOR_CST_NPATTERNS 1 and VECTOR_CST_NELTS_PER_PATTERN 1, so when > we call builder.new_unar

[PATCH] i386: Fix ix86_fold_builtin shift folding [PR93418]

2020-01-27 Thread Jakub Jelinek
Hi! The following testcase is miscompiled, because the variable shift left operand, { -1, -1, -1, -1 } is represented as a VECTOR_CST with VECTOR_CST_NPATTERNS 1 and VECTOR_CST_NELTS_PER_PATTERN 1, so when we call builder.new_unary_operation, builder.encoded_nelts () will be just 1 and thus we enc