[Bug target/60520] stack adjustment are not merged anymore

ubizjak at gmail dot com gcc-bugzilla@gcc.gnu.org
Fri Mar 14 08:59:00 GMT 2014


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60520

--- Comment #8 from Uroš Bizjak <ubizjak at gmail dot com> ---
(In reply to Uroš Bizjak from comment #7)
> (In reply to Jakub Jelinek from comment #6)
> > Furthermore, it is already fixed since r208551.
> 
> Indeed, the fix for PR57320 also fixed this one.

However, using "-O2 -m32 -fno-omit-frame-pointer" an unnecessary stack
adjustment remains, even after r208551:

test:
        movl    bar, %eax
        movl    (%eax), %edx
        testl   %edx, %edx
        jne     .L7
        ret
        .p2align 4,,10
        .p2align 3
        pushl   %ebp
        movl    %esp, %ebp
        subl    $20, %esp
        pushl   %eax
        call    foo
        addl    $16, %esp     <<<<
        leave
        ret


More information about the Gcc-bugs mailing list