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

Scott Constable via cfe-commits cfe-commits at lists.llvm.org
Sun Nov 24 22:33:15 PST 2024


scottconstable wrote:

> Although the default calling convention uses 6 registers, others like RegCall uses more. Do you want to check calling convention as well?

AFAIK the use case for KCFI is very narrow: the x86-64 Linux kernel. And I don't believe that the kernel uses (or even allows?) any calling convention other than the default. The kernel documentation also says that the eBPF calling convention "maps directly to ABIs used by the kernel on 64-bit architectures." But I admit I am not an expert on the Linux ABI nor am I an expert on the full scope of KCFI use cases.

Maybe @lvwr can weigh in?

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


More information about the cfe-commits mailing list