This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling



------- Comment #7 from ubizjak at gmail dot com  2008-03-18 14:34 -------
asm dump with GCC: (GNU) 4.4.0 20080318 (experimental) and -O2
-fomit-frame-pointer:

function_calling_listener:
        movl    20(%esp), %eax  # data.d, data.d
        movl    16(%esp), %ecx  # data.c, data.c
        movl    %eax, 12(%esp)  # data.d,
        movl    %ecx, 8(%esp)   # data.c,
        jmp     *%ecx   # data.c

-O0:

function_calling_listener:
        pushl   %ebx    #
        subl    $24, %esp       #,
        movl    36(%esp), %ebx  # data.listener, D.1190
        movl    48(%esp), %eax  # data.d, D.1191
        movl    44(%esp), %edx  # data.c, D.1192
        movl    32(%esp), %ecx  # data.a, D.1193
        movl    %eax, 8(%esp)   # D.1191,
        movl    %edx, 4(%esp)   # D.1192,
        movl    %ecx, (%esp)    # D.1193,
        call    *%ebx   # D.1190
        addl    $24, %esp       #,
        popl    %ebx    #
        ret


-- 


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]