https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116896

--- Comment #23 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Created attachment 59274
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=59274&action=edit
gcc15-pr116896-peep2.patch

Peephole2 for the signed int <=> case (if the comparison is done in SImode).
With this I get:
        xorl    %edx, %edx
        xorl    %eax, %eax
        cmpl    %esi, %edi
        setl    %dl
        setg    %al
        subl    %edx, %eax
        ret
for the signed int case when inc/inc2 patches aren't applied.

Reply via email to