Re: [PATCH] Fix __mulv[dt]i3 and expand_mul_overflow (PR target/82274)

2017-10-13 Thread Ian Lance Taylor via gcc-patches
On Fri, Sep 22, 2017 at 6:03 AM, Jakub Jelinek wrote: > > 2017-09-22 Jakub Jelinek > > PR target/82274 > * internal-fn.c (expand_mul_overflow): If both operands have > the same highpart of -1 or 0 and the topmost bit of lowpart >

[PATCH] Fix __mulv[dt]i3 and expand_mul_overflow (PR target/82274)

2017-09-22 Thread Jakub Jelinek
Hi! An overflow isn't detected on multiplication of signed integer with all ones in the upper half of bits and all zeros in the lower half by itself, either with -ftrapv, or __builtin_mul_overflow{,_p}, or signed-integer-overflow sanitization. For libgcc, we have various cases we handle earlier