[llvm-bugs] [Bug 34928] New: adrp of weak undef produces different result than in bfd

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Oct 12 09:21:51 PDT 2017


https://bugs.llvm.org/show_bug.cgi?id=34928

            Bug ID: 34928
           Summary: adrp of weak undef produces different result than in
                    bfd
           Product: lld
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: ELF
          Assignee: unassignedbugs at nondot.org
          Reporter: rafael.espindola at gmail.com
                CC: llvm-bugs at lists.llvm.org, peter.smith at linaro.org

Given

        .globl  _start
_start:
        adrp    x0, foo
        add     x0, x0, :lo12:foo
        ret

        .hidden foo
        .weak foo

lld produces

_start:                                                            
   20000:       00 ff ff 90     adrp    x0, #-131072               
   20004:       00 00 00 91     add     x0, x0, #0                 
   20008:       c0 03 5f d6     ret 

bfd produces

_start:
  400078:       00 00 00 90     adrp    x0, #0                     
  40007c:       00 00 00 91     add     x0, x0, #0                 
  400080:       c0 03 5f d6     ret

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20171012/65ab2a10/attachment.html>


More information about the llvm-bugs mailing list