[clang] [Clang][attr] Add 'kcfi_salt' attribute (PR #141846)
Miguel Ojeda via cfe-commits
cfe-commits at lists.llvm.org
Thu Jul 17 02:49:28 PDT 2025
================
@@ -3643,6 +3643,64 @@ make the function's CFI jump table canonical. See :ref:`the CFI documentation
}];
}
+def KCFISaltDocs : Documentation {
+ let Category = DocCatFunction;
+ let Content = [{
+Use ``__attribute__((kcfi_salt("<salt>")))`` on a function declaration, function
+definition, or typedef to help distinguish CFI hashes between functions with
+the same type signature.
----------------
ojeda wrote:
Like in the kernel patch, it would be nice to summarize the use case, i.e. in what cases we would want to apply this.
https://github.com/llvm/llvm-project/pull/141846
More information about the cfe-commits
mailing list