[compiler-rt] [libcxx] [libcxxabi] [libunwind] [runtimes][PAC] Harden unwinding when possible (PR #143230)
Oliver Hunt via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 7 15:50:22 PDT 2025
================
@@ -541,7 +583,38 @@ struct scan_results
};
} // unnamed namespace
+} // extern "C"
+
+#if !defined(_LIBCXXABI_ARM_EHABI)
+namespace {
+// The logical model for casting authenticated function pointers makes
+// it impossible to directly cast them without breaking the authentication,
+// as a result we need this pair of helpers.
+//
+// __ptrauth_nop_cast cannot be used here as the authentication schemas include
+// address diversification.
+template <typename PtrType>
+void set_landing_pad_as_ptr(scan_results& results, const PtrType& out) {
----------------
ojhunt wrote:
none of those macros work -> these are address discriminated values. That's also why memcpy does not work.
https://github.com/llvm/llvm-project/pull/143230
More information about the llvm-commits
mailing list