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



             Bug #: 55019

           Summary: Incorrectly use live argument register to save high

                    register in thumb1 prologue

    Classification: Unclassified

           Product: gcc

           Version: 4.7.3

            Status: UNCONFIRMED

          Severity: normal

          Priority: P3

         Component: target

        AssignedTo: unassig...@gcc.gnu.org

        ReportedBy: terry....@arm.com





When run 4.7 regression test on cortex-m0 with options "-mthumb -mcpu=cortex-m0

-O1 -funroll-loops", case gcc.dg/torture/builtin-complex-1.c will fail due to

the corruption of argument register as shown in below:



compare:

    push    {r3, r4, r6, lr}

    mov    r6, fp

    mov    r4, sl

    mov    r3, r9    <<-- r3 is clobbered

    push    {r3, r4, r6}

    mov    r6, r8

    push    {r6}

    mov    fp, r0

    mov    sl, r1

    mov    r9, r2

    mov    r8, r3  <<-- wrong value is used

Reply via email to