GithubHelp home page GithubHelp logo

rust-libprobe's Introduction

libprobe: Static probes for Rust

probe crate minimum rustc 1.59 probe documentation build status

With the probe! macro, programmers can place static instrumentation points in their code to mark events of interest. These are compiled into platform-specific implementations, e.g. SystemTap SDT on Linux. Probes are designed to have negligible overhead during normal operation, so they can be present in all builds, and only activated using those external tools.

Documentation

Using libprobe

probe! is available on crates.io. The recommended way to use it is to add a line into your Cargo.toml such as:

[dependencies]
probe = "0.3"

Then use probe::probe; in your code and insert macro calls wherever you want to mark something, probe!(provider, name, args...). The provider and name are identifiers of your choice, and any additional arguments are runtime expressions that will be cast as isize for the probe consumer to read.

Rust integration

I hope that this library can eventually be a standard part of the Rust distribution -- see the rust pull request and original enhancement issue. It works fine as a standalone library, but if it were incorporated, then even Rust's own libraries could define probe points.

License

libprobe follows the same license choices as The Rust Project itself, in order to ease a future merge.

See LICENSE-APACHE, LICENSE-MIT, and COPYRIGHT for details.

rust-libprobe's People

Contributors

acolley avatar cuviper avatar nelhage avatar ratmice avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.