[all-commits] [llvm/llvm-project] 742a82: [lld-macho] Implement support for ObjC relative me...

alx32 via All-commits all-commits at lists.llvm.org
Wed Mar 27 14:34:49 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 742a82a729925dc79641beb649f492003be40725
      https://github.com/llvm/llvm-project/commit/742a82a729925dc79641beb649f492003be40725
  Author: alx32 <103613512+alx32 at users.noreply.github.com>
  Date:   2024-03-27 (Wed, 27 Mar 2024)

  Changed paths:
    M lld/MachO/Config.h
    M lld/MachO/Driver.cpp
    M lld/MachO/InputSection.cpp
    M lld/MachO/InputSection.h
    M lld/MachO/MapFile.cpp
    M lld/MachO/ObjC.h
    M lld/MachO/Options.td
    M lld/MachO/SyntheticSections.cpp
    M lld/MachO/SyntheticSections.h
    M lld/MachO/Writer.cpp
    A lld/test/MachO/objc-relative-method-lists-simple.s

  Log Message:
  -----------
  [lld-macho] Implement support for ObjC relative method lists (#86231)

The MachO format supports relative offsets for ObjC method lists. This
support is present already in ld64. With this change we implement this
support in lld also.

Relative method lists can be identified by a specific flag (0x80000000)
in the method list header. When this flag is present, the method list
will contain 32-bit relative offsets to the current Program Counter
(PC), instead of absolute pointers.
Additionally, when relative method lists are used, the offset to the
selector name will now be relative and point to the selector reference
(selref) instead of the name itself.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list