[lld] [LLD, MachO] Add `getUnwindInfoEncodingHash` to `BPSectionOrderer.cpp`. (PR #105587)

Peter Rong via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 23 12:00:51 PDT 2024


================
@@ -60,6 +61,30 @@ getRelocHash(const Reloc &reloc,
   return getRelocHash(kind, sectionIdx.value_or(0), 0, reloc.addend);
 }
 
+// Get a hash of the unwind info (after relocation).
+// This hash is not 100% accurate, but it's good enough for compression.
----------------
DataCorrupted wrote:

Proposing `Hash(lsda->getName() + personality->getName() + utohexstr(encoding))` (name is "<null>" if it is a nullpointer)

https://github.com/llvm/llvm-project/pull/105587


More information about the llvm-commits mailing list