[PATCH] D155245: [MC][AsmParse] Diagnose improperly nested .cfi frames

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 16 23:22:23 PST 2023


MaskRay accepted this revision.
MaskRay added a comment.
This revision is now accepted and ready to land.

Looks great!



================
Comment at: llvm/lib/MC/MCParser/AsmParser.cpp:1953
 
+    if (CFIStartProcLoc && (Sym->isExternal() || Sym->isWeakExternal()))
+      return Error(StartTokLoc, "non-private labels cannot appear between "
----------------
Add a test for `isWeakExternal`?


================
Comment at: llvm/test/MC/MachO/AArch64/cfi-bad-nesting.s:1
+; RUN: not llvm-mc -triple arm64-apple-darwin %s -filetype=obj -o /dev/null 2>&1 | FileCheck %s
+
----------------
We could also use test/MC/MachO/ since this is generic, not specific to AArch64/


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

https://reviews.llvm.org/D155245



More information about the llvm-commits mailing list