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 rtl-optimization/38644] Optimization flag -O1 -fschedule-insns2 causes wrong code



------- Comment #18 from sebastian dot huber at embedded-brains dot de  2010-08-12 08:19 -------
This bug is still present in GCC 4.6.0 20100807 (arm-eabi-gcc -O1
-fschedule-insns2 -mthumb):

readStream:
        push    {r4, lr}
        sub     sp, sp, #8
        mov     r4, sp
        mov     r3, #0
        strb    r3, [r4, #7]
        add     r4, r4, #7
        ldr     r3, [r0]
        mov     r1, r4
        mov     r2, #1
        bl      doStreamReadBlock
        add     sp, sp, #8
        ldrb    r0, [r4]
        @ sp needed for prologue
        pop     {r4}
        pop     {r1}
        bx      r1
        .size   readStream, .-readStream
        .ident  "GCC: (GNU) 4.6.0 20100807 (experimental)"


-- 


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


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