[clang] [Clang] Fix preserved C++ field indices (PR #226790)
via cfe-commits
cfe-commits at lists.llvm.org
Sun Oct 18 18:52:14 PDT 2026
yonghong-song wrote:
@tamird I looked at your pull request, I think your implementation is correct
at least for the current front-end change.
But I don't know you final goal.
First, bpf does not support general C++ codes. It may support some C++ but I guess
we are not there yet.
Second, what is your goal here? I guess you want to support CO-RE relocation for
C++ with bpf clang-side intrinsic's. Note that the attribute 'preserve_access_index'
and 'preserve_static_offset' for C only plus a few others like btf_decl_tag/btf_type_tag/bpf_fastcall.
So your eventual goal is to support C++ for full (close to full) features?
But this could be very complicated?
I would be great to explain the motivation, steps, and eventual goal, before going
deep implementing for C++ for llvm bpf. Alexei does have a C++ bpf prog example
with exception handling:
https://lore.kernel.org/bpf/20261018010246.1643877-6-alexei.starovoitov@gmail.com/
which means we could expand C++ in bpf. But still some future plan will be helpful.
https://github.com/llvm/llvm-project/pull/226790
More information about the cfe-commits
mailing list