bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug gas/21590] Arm assembler generates incorrect transformation from ld


From: ramana.radhakrishnan at foss dot arm.com
Subject: [Bug gas/21590] Arm assembler generates incorrect transformation from ldr to movs
Date: Wed, 14 Jun 2017 07:52:55 +0000

https://sourceware.org/bugzilla/show_bug.cgi?id=21590

--- Comment #4 from ramana.radhakrishnan at foss dot arm.com ---
On 13/06/17 23:31, manojgupta at google dot com wrote:
> https://sourceware.org/bugzilla/show_bug.cgi?id=21590


I believe this was fixed by 
https://sourceware.org/ml/binutils/2017-04/msg00179.html

Trunk for the testcase produces the following output.



00000000 <__clone>:
    0:   2800            cmp     r0, #0
    2:   bf14            ite     ne
    4:   2900            cmpne   r1, #0
    6:   f06f 0015       mvneq.w r0, #21
    a:   f43f affe       beq.w   0 <__syscall_error>
    e:   f841 3d04       str.w   r3, [r1, #-4]!
   12:   f841 0d04       str.w   r0, [r1, #-4]!
   16:   4610            mov     r0, r2
   18:   4694            mov     ip, r2
   1a:   b490            push    {r4, r7}
   1c:   9a02            ldr     r2, [sp, #8]
   1e:   9b03            ldr     r3, [sp, #12]
   20:   9c04            ldr     r4, [sp, #16]
   22:   f04f 0778       mov.w   r7, #120        ; 0x78
   26:   df00            svc     0
   28:   2800            cmp     r0, #0
   2a:   d003            beq.n   34 <__clone+0x34>
   2c:   bc90            pop     {r4, r7}
   2e:   f6ff affe       blt.w   0 <__syscall_error>
   32:   4770            bx      lr
   34:   f41c 3f80       tst.w   ip, #65536      ; 0x10000
   38:   d10e            bne.n   58 <__clone+0x58>
   3a:   ee1d 0f70       mrc     15, 0, r0, cr13, cr0, {3}
   3e:   4601            mov     r1, r0
   40:   f41c 7f80       tst.w   ip, #256        ; 0x100
   44:   f04f 0714       mov.w   r7, #20
   48:   bf14            ite     ne
   4a:   f04f 30ff       movne.w r0, #4294967295 ; 0xffffffff
   4e:   df00            svceq   0
   50:   f5a1 618b       sub.w   r1, r1, #1112   ; 0x458
   54:   6008            str     r0, [r1, #0]
   56:   6048            str     r0, [r1, #4]
   58:   9801            ldr     r0, [sp, #4]
   5a:   f85d cb08       ldr.w   ip, [sp], #8
   5e:   47e0            blx     ip
   60:   f7ff bffe       b.w     0 <_exit>


Thanks,
Ramana


>
> Manoj Gupta <manojgupta at google dot com> changed:
>
>            What    |Removed                     |Added
> ----------------------------------------------------------------------------
>                  CC|                            |matthew.wahab at arm dot com
>

-- 
You are receiving this mail because:
You are on the CC list for the bug.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]