[llvm-branch-commits] [llvm] [BOLT][PAC] Warn about synchronous unwind tables (PR #165227)

Peter Waller via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Wed Oct 29 01:58:18 PDT 2025


================
@@ -133,11 +140,17 @@ Error PointerAuthCFIAnalyzer::runOnFunctions(BinaryContext &BC) {
   ParallelUtilities::runOnEachFunction(
       BC, ParallelUtilities::SchedulingPolicy::SP_INST_LINEAR, WorkFun,
       SkipPredicate, "PointerAuthCFIAnalyzer");
+
+  float IgnoredPercent = (100.0 * FunctionsIgnored) / Total;
   BC.outs() << "BOLT-INFO: PointerAuthCFIAnalyzer ran on " << Total
             << " functions. Ignored " << FunctionsIgnored << " functions "
-            << format("(%.2lf%%)", (100.0 * FunctionsIgnored) / Total)
+            << format("(%.2lf%%)", IgnoredPercent)
             << " because of CFI inconsistencies\n";
 
+  if (IgnoredPercent >= 10.0)
+    BC.outs() << "BOLT-WARNING: PointerAuthCFIAnalyzer only supports "
+                 "asynchronous unwind tables.\n";
----------------
peterwaller-arm wrote:

I think these are valid concerns. It could still be more actionable to the user without specifying the flag; calling out that the workload must be recompiled with them turned on. It could say something like "For C compilers the flag is typically spelled -fasynchronous-unwind-tables / -fno-asynchronous-unwind-tables". Even if a user is not using C this might turn out to be useful information to find relevant documentation.


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


More information about the llvm-branch-commits mailing list