[PATCH] D144999: [RFC][MC][MachO]Only emits compact-unwind format for "canonical" personality symbols. For the rest, use DWARFs.

James Y Knight via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 16 08:34:39 PDT 2023


jyknight added a comment.

Looks reasonable to me -- but I'd like to see the LLD change implemented and both pieces tested together end-to-end before this is submitted.

> James' previous comment was suggesting to leave out __gcc_personality_v0 from the set of canonical (because it's rarely used), leaving one unused slot.

My suggestion was primarily for the previous proposal. Excluding it doesn't really have much of a benefit currently, since we also won't use it for anything else.

Probably fine to leave as you have it though, since C unwind is so rarely used anyways. And in the potential future where we decide to implement the more complex scheme of choosing whether to use compact or dwarf unwind at link-time, not having prebuilt objects/archives hanging around that require all 3 slots of compact-unwind would be helpful.



================
Comment at: llvm/lib/MC/MCAsmBackend.cpp:123
+    return name.compare("__gxx_personality_v0,") == 0 ||
+           name.compare("__objc_personality_v0") == 0;
+  }
----------------
Probably should only return true if Sym->isExternal()?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D144999/new/

https://reviews.llvm.org/D144999



More information about the llvm-commits mailing list