[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 cfe-commits cfe-commits at lists.llvm.org
Thu May 4 13:00:37 PDT 2023


jyknight added a comment.

I wonder if we actually need to define a clang frontend flag for this; I suspect nobody will ever want to specify it, since the only non-canonical personality clang will ever generate that changes behavior is the pure-C destructor-only personality, `__gnu_personality_v0`. Otherwise, it could only arise from assembly or IR.

For a test-case, can just use `-mllvm -emit-compact-unwind-non-canonical`.



================
Comment at: llvm/lib/MC/MCAsmBackend.cpp:119
+
+bool MCAsmBackend::isDarwinCanonicalPersonality(const MCSymbol *Sym) const {
+  if (Sym && Sym->isMachO()) {
----------------
This could use a comment as to why these two are "canonical" and why "__gcc_personality_v0" is excluded despite being similar.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D144999



More information about the cfe-commits mailing list