Skip to contentSkip to conversation

BPF: Extending eBPF as a generic tracing engine

LSF/MM TOPIC Kris Van Hees 1 participant 2 messages Feb 23, 2019 – Apr 8, 2019 BPF

lore
Share & tools
lore
#0 lore raw

Topic: Extending eBPF as a generic tracing engine

My presentation covers a few new features to the eBPF implementation in support of tracing tools. The main goal is to allow tracing tools the ability to encode actions with probes/events, beyond the context of what the current probes/events provide.

The features to discuss are:

- Allowing BPF-to-BPF tail-calling between BPF programs of different program types (ussing a context conversion/casting mechanism that BPF program types can provide. This patch is being posted to the netdev group this weekend, along with an example on how to use it.
- Using the context conversion mechanism to associate task info with probe/event context, and have a BPF program operate on that, which reduces the dependency (or need) for helper functions.
- Consider the option of having BPF program sub-types (for some program types), which could even provide for loadable modules to implement some specific extensions to a more generic BPF program type.
- Extending the context handling code and access checking to allow for pointer references to auxilliary structs (to an arbitrary depth). This makes it possible to do a lot more with contexts, such as having it store a pointer to a trace output buffer so you can have BPF instructions store to it directly.

The talk will focus on why this will help tracing a lot, and how it will advance BPF as a tracing facility. I want to solicit feedback on these features so there can be common road forward to enhancing tracing based on BPF.

#1 lore raw

Hi,

I have not heard any reply to the topic I proosed for the BPF track? Could you please let me know by when notification can be expected on whether the proposal is accepted or not?

Cheers,
Kris

Quoted 29 lines · Kris Van Hees

Topic: Extending eBPF as a generic tracing engine

My presentation covers a few new features to the eBPF implementation in support of tracing tools. The main goal is to allow tracing tools the ability to encode actions with probes/events, beyond the context of what the current probes/events provide.

The features to discuss are:

- Allowing BPF-to-BPF tail-calling between BPF programs of different program types (ussing a context conversion/casting mechanism that BPF program types can provide. This patch is being posted to the netdev group this weekend, along with an example on how to use it.
- Using the context conversion mechanism to associate task info with probe/event context, and have a BPF program operate on that, which reduces the dependency (or need) for helper functions.
- Consider the option of having BPF program sub-types (for some program types), which could even provide for loadable modules to implement some specific extensions to a more generic BPF program type.
- Extending the context handling code and access checking to allow for pointer references to auxilliary structs (to an arbitrary depth). This makes it possible to do a lot more with contexts, such as having it store a pointer to a trace output buffer so you can have BPF instructions store to it directly.

The talk will focus on why this will help tracing a lot, and how it will advance BPF as a tracing facility. I want to solicit feedback on these features so there can be common road forward to enhancing tracing based on BPF.