Re: [RFC bpf-next 2/9] bpf, x86: add new map type: instructions set

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 2025-06-19 at 18:55 +0000, Anton Protopopov wrote:

[...]

> > I think such maps would be a bit more ergonomic it original
> > instruction index would be saved as well, e.g:
> > 
> >   (original_offset, xlated_offset, jitted_offset)
> > 
> > Otherwise user would have to recover original offset from some
> > external mapping. This information is stored in orig_xlated_off
> > anyway.
> 
> I do agree that this might be convenient to have the original_offset.
> But the only use case I see here is "BPF debuggers". Such programs
> will be able to build this mapping themselves.
> 
> I would add it as is, the only obstacle I see now is map key size.
> Now from BPF point of view and from userspace point of view it is 8.
> Userspace sees (u32 xlated, u32 jitted), and BPF sees *ip. I haven't
> looked at how much work it is to have different key sizes for
> userspace and BPF, and if this breaks things too much.

Uh-oh, I haven't thought about key size being different for kernel/user,
might be a conundrum indeed.

[...]






[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux