This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: stap/eBPF language features brainstorm


On 07/11/2018 04:13 PM, Serhei Makarov wrote:
> Some very rough ideas on how to jam further desirable SystemTap language features into the constraints of eBPF. The goal isn't for total feature-parity with the kernel backend (that's not feasible) but for the restrictions to be clear and understandable, e.g.:

... 
> - Certain operations (e.g. foreach) can only be done in userspace. It's clearly documented which probes run in userspace (e.g. begin, end, selected ?timer probes).

A number of the systemtap script have idioms like the following from iotop.stp:

global io_stat,device
global read_bytes,write_bytes

...

probe timer.ms(5000) {
  /* write out data */
  /* clear data */
  delete io_stat
  delete device
  read_bytes = 0
  write_bytes = 0  
}

Is there some way to clear out all the previous entries in the bpf map from the timer probe?

-Will


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]