[PATCH] D120574: [dsymutil] Apply relocations present in Swift reflection sections

Augusto Noronha via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Feb 25 10:36:38 PST 2022


augusto2112 created this revision.
augusto2112 added reviewers: aprantl, JDevlieghere, rastogishubham.
Herald added a subscriber: hiraditya.
augusto2112 requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

The strippable Swift reflection sections contain subtractor relocations
that need to be applied. There are two situations we need to support.

1. Both symbols used in the relocation come from the .o file (for example, one symbol lives in __swift5_fieldmd and the second in __swift5_reflstr).
2. One symbol comes from th .o file and the second from the main binary (for example, __swift5_fieldmd and __swift5_typeref).


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D120574

Files:
  llvm/include/llvm/Object/ObjectFile.h
  llvm/lib/Object/ObjectFile.cpp
  llvm/tools/dsymutil/DwarfLinkerForBinary.cpp
  llvm/tools/dsymutil/DwarfLinkerForBinary.h
  llvm/tools/dsymutil/MachOUtils.cpp
  llvm/tools/dsymutil/MachOUtils.h

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D120574.411455.patch
Type: text/x-patch
Size: 20069 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220225/e53dfe51/attachment.bin>


More information about the llvm-commits mailing list