Skip to content

eBPF tracing support #239

Open
Open
@hariom-qure

Description

@hariom-qure

Linking the original issue here (we use rules_python, where I raised it first): bazel-contrib/rules_python#1737

I want to use eBPF to do arbitrary performance profiling of our code, but its not very useful if the python interpreter is not compiled with dtrace and frame pointer support. Without these two, all the information about function names are lost in the stack trace.
The important flags:

  1. --with-dtrace: This flag enables static markers inside python which we can hook into using eBPF (details: https://docs.python.org/3/howto/instrumentation.html)
  2. Enable Frame pointer: -fno-omit-frame-pointer in gcc. This makes sure the information of function names in stack trace is not lost. References: https://www.brendangregg.com/blog/2024-03-17/the-return-of-the-frame-pointers.html

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestwishNot on the immediate roadmap

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions