RE: [r16-3760 Regression] FAIL: g++.target/i386/pr116896-1.C -std=gnu++23 scan-assembler-times \tjp\t 1 on Linux/x86_64

"Jiang, Haochen via Gcc-regression" <[email protected]>
Newsgroups gmane.comp.gcc.regression,gmane.comp.gcc.patches
Message-ID <SJ5PPF77D28E3C29014C34E3F51CB9F1CADEC08A@SJ5PPF77D28E3C2.namprd11.prod.outlook.com>
> From: Robin Dapp <[email protected]>
> Sent: Friday, September 12, 2025 2:53 PM
> 
> > FAIL: gcc.target/i386/pr116896.c scan-assembler-times \tjp\t 2
> > FAIL: g++.target/i386/pr116896-1.C  -std=gnu++20  scan-assembler-times
> \tjp\t 1
> > FAIL: g++.target/i386/pr116896-1.C  -std=gnu++23  scan-assembler-times
> \tjp\t 1
> > FAIL: g++.target/i386/pr116896-1.C  -std=gnu++26  scan-assembler-times
> \tjp\t 1
> >
> > with GCC configured with
> >
> > ../../gcc/configure --prefix=/export/users3/haochenj/src/gcc-
> bisect/master/master/r16-3760/usr --enable-clocale=gnu --with-system-zlib -
> -with-demangler-in-ld --with-fpmath=sse --enable-languages=c,c++,fortran --
> enable-cet --without-isl --enable-libmpx x86_64-linux --disable-bootstrap
> >
> 
> Grml, I had seen this error during testing but it didn't appear any more during
> the final round with the latest patch version.
> 
> This is the difference:
> 
> Before:
> 
> foo:
> .LFB0:
>         .cfi_startproc
>         xorl    %eax, %eax
>         vcomiss %xmm1, %xmm0
>         jp      .L2
>         seta    %al
>         sbbl    $0, %eax
>         ret
> .L2:
>         movl    $2, %eax
>         ret
> 	.cfi_endproc
> 
> After:
> 
> foo:
> .LFB0:
>         .cfi_startproc
>         xorl    %eax, %eax
>         vcomiss %xmm1, %xmm0
>         movl    $2, %edx
>         seta    %al
>         sbbl    $0, %eax
>         vucomiss        %xmm1, %xmm0
>         cmovp   %edx, %eax
>         ret
> 	.cfi_endproc
> 
> Is the "before" what we want, given the two other functions in the test are
> branchless?  I suppose so, as the if-converted sequence is pretty lengthy.
> 

I also believe that we should keep the before one. The main problem I suppose
would be the extra ucomi here. It is an even bigger problem than the conditional
jmp vs cmov originally in that PR.

Thx,
Haochen
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.