#dwarf #debugging #elf #object-file #eh-frame

no-std gimli

A library for reading and writing the DWARF debugging format

35 releases (breaking)

0.28.1 Nov 24, 2023
0.27.3 Jun 15, 2023
0.27.2 Feb 15, 2023
0.27.0 Nov 24, 2022
0.3.0 Jul 27, 2016

#12 in Parser implementations

Download history 1146941/week @ 2023-11-26 1159273/week @ 2023-12-03 1223639/week @ 2023-12-10 1078428/week @ 2023-12-17 602000/week @ 2023-12-24 1018513/week @ 2023-12-31 1272202/week @ 2024-01-07 1264378/week @ 2024-01-14 1290771/week @ 2024-01-21 1343989/week @ 2024-01-28 1404480/week @ 2024-02-04 1416339/week @ 2024-02-11 1406223/week @ 2024-02-18 1472634/week @ 2024-02-25 1463697/week @ 2024-03-03 570972/week @ 2024-03-10

5,010,092 downloads per month
Used in 28,135 crates (70 directly)

MIT/Apache

1.5MB
36K SLoC

gimli

Build Status Coverage Status

gimli is a library for reading and writing the DWARF debugging format.

  • Zero copy: everything is just a reference to the original input buffer. No copies of the input data get made.

  • Lazy: you can iterate compilation units without parsing their contents. Parse only as many debugging information entry (DIE) trees as you iterate over. gimli also uses DW_AT_sibling references to avoid parsing a DIE's children to find its next sibling, when possible.

  • Cross-platform: gimli makes no assumptions about what kind of object file you're working with. The flipside to that is that it's up to you to provide an ELF loader on Linux or Mach-O loader on macOS.

    • Unsure which object file parser to use? Try the cross-platform object crate. See the gimli-examples crate for usage with gimli.

Install

Add this to your Cargo.toml:

[dependencies]
gimli = "0.28.1"

The minimum supported Rust version is:

  • 1.60.0 for the read feature and its dependencies.
  • 1.65.0 for other features.

Documentation

License

Licensed under either of

at your option.

Contribution

See CONTRIBUTING.md for hacking.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Dependencies