[clang] [X86] Enhance kCFI type IDs with a 3-bit arity indicator. (PR #117121)

2024-11-21 Thread Sebastian Österlund via cfe-commits
@@ -2196,8 +2197,32 @@ llvm::ConstantInt *CodeGenModule::CreateKCFITypeId(QualType T) { if (getCodeGenOpts().SanitizeCfiICallNormalizeIntegers) Out << ".normalized"; - return llvm::ConstantInt::get(Int32Ty, - static_cast(llvm::xxHash64(O

[clang] [llvm] [X86] Extend kCFI with a 3-bit arity indicator (PR #121070)

2025-01-22 Thread Sebastian Österlund via cfe-commits
sirmc wrote: I had a quick look (sorry for not getting to this earlier, was traveling around Vietnam for a few weeks). Looks good to me. Especially the trick of encoding the arity into the MOV32ri register seems very neat from a compatibility standpoint. So if I understand this correctly, the