Re: [PATCH] widening_mul, i386: Improve spaceship expansion on x86 [PR103973]

2022-01-15 Thread Uros Bizjak via Gcc-patches
On Sat, Jan 15, 2022 at 10:56 AM Jakub Jelinek wrote: > > On Sat, Jan 15, 2022 at 09:29:05AM +0100, Uros Bizjak wrote: > > > --- gcc/config/i386/i386.md.jj 2022-01-14 11:51:34.432384170 +0100 > > > +++ gcc/config/i386/i386.md 2022-01-14 18:22:41.140906449 +0100 > > > @@ -23886,6 +23886,18 @@

Re: [PATCH] widening_mul, i386: Improve spaceship expansion on x86 [PR103973]

2022-01-15 Thread Jakub Jelinek via Gcc-patches
On Sat, Jan 15, 2022 at 09:29:05AM +0100, Uros Bizjak wrote: > > --- gcc/config/i386/i386.md.jj 2022-01-14 11:51:34.432384170 +0100 > > +++ gcc/config/i386/i386.md 2022-01-14 18:22:41.140906449 +0100 > > @@ -23886,6 +23886,18 @@ (define_insn "hreset" > >[(set_attr "type" "other") > > (

Re: [PATCH] widening_mul, i386: Improve spaceship expansion on x86 [PR103973]

2022-01-15 Thread Uros Bizjak via Gcc-patches
On Fri, Jan 14, 2022 at 11:56 PM Jakub Jelinek wrote: > > Hi! > > C++20: > #include > auto cmp4way(double a, double b) > { > return a <=> b; > } > expands to: > ucomisd %xmm1, %xmm0 > jp .L8 > movl$0, %eax > jne .L8 > .L2: > ret > .p2

[PATCH] widening_mul, i386: Improve spaceship expansion on x86 [PR103973]

2022-01-14 Thread Jakub Jelinek via Gcc-patches
Hi! C++20: #include auto cmp4way(double a, double b) { return a <=> b; } expands to: ucomisd %xmm1, %xmm0 jp .L8 movl$0, %eax jne .L8 .L2: ret .p2align 4,,10 .p2align 3 .L8: comisd %xmm0, %xmm1 movl$-1, %e