[llvm-bugs] [Bug 51055] New: lld/mac: Implement support for linker optimization hints (.loh)

via llvm-bugs llvm-bugs at lists.llvm.org
Sun Jul 11 16:14:15 PDT 2021


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

            Bug ID: 51055
           Summary: lld/mac: Implement support for linker optimization
                    hints (.loh)
           Product: lld
           Version: unspecified
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: MachO
          Assignee: unassignedbugs at nondot.org
          Reporter: nicolasweber at gmx.de
                CC: gkm at fb.com, jezreel at gmail.com,
                    llvm-bugs at lists.llvm.org, smeenai at fb.com

LLVM supports `.loh` directives
(llvm/trunk/test/MC/AArch64/arm64-directive_loh.s). Per
https://reviews.llvm.org/D49929:

"""
The hints are there so that the linker can turn (non-adjacent) ADRP/ADD
sequences, and similar, into ADR/NOP if the referenced symbol ends up close
enough; this saves a cycle or so on Apple CPUs. To do that the compiler marks
instruction-pairs used to generate a single address and saves that data off in
a special MachO load command. I suppose it is sort of a souped-up relocation
which specifies two addresses to be relocated instead of just one.
"""

I think we don't support that yet in lld.

-- 
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/20210711/6581eaef/attachment.html>


More information about the llvm-bugs mailing list