Crates.io | rudy-db |
lib.rs | rudy-db |
version | 0.0.10 |
created_at | 2025-06-27 18:12:07.323851+00 |
updated_at | 2025-08-09 19:55:16.075749+00 |
description | A user-friendly library for interacting with debugging information of Rust compiled artifacts using DWARF |
homepage | https://github.com/samscott89/rudy |
repository | https://github.com/samscott89/rudy |
max_upload_size | |
id | 1729189 |
size | 3,607,538 |
A Rust library for interacting with debugging information of compiled artifacts using DWARF format. Provides lazy evaluation and incremental computation for long-running processes like debuggers.
⚠️ Experimental Status: This library is in early development (0.0.x). The API is unstable and subject to breaking changes.
[!IMPORTANT] See the announcement post for more on the rationale/design behind Rudy.
We also provide an example rudy-lldb
extension that brings the capabilities of rudy-db
to the lldb
debugger.
Here's a short demo:
Quick Install:
cargo install rudy-lldb
rudy-lldb-server install
This will download the LLDB client script and configure your ~/.lldbinit
automatically.
Manual Install:
rudy-lldb
from source: cargo install rudy-lldb
curl https://raw.githubusercontent.com/samscott89/rudy/main/rudy-lldb/python/rudy_lldb.py -o ~/.lldb/rudy_lldb.py
~/.lldbinit
: echo "command script import ~/.lldb/rudy_lldb.py" >> ~/.lldbinit
Server Management: The rudy-lldb server will automatically start when you run your first rd
command in LLDB. You can also manage it manually:
rudy-lldb-server start
- Start the server
rudy-lldb-server stop
- Stop the server
Set RUDY_AUTOSTART=0
to disable automatic server startup
rudy-dwarf
) - Parser combinators and visitor patterns abstracting gimlirudy-db
) - DebugInfo
wrapper with salsa-based incremental cachingrudy-lldb
) - RPC server for interactive debuggingLazy evaluation using salsa for incremental computation
Low-level DWARF parser combinators and visitor structs
Higher-level DebugInfo
wrapper for common debugging operations
Cross-platform support (x86_64, aarch64 on macOS, Linux)
Here's a simple example of loading a binary and resolving type information from a memory address:
use rudy_db::DebugDb;
use anyhow::Result;
fn main() -> Result<()> {
// Create a new database
let mut db = DebugDb::new();
// Get debug information for a binary
let debug_info = DebugInfo::new(&db, "/path/to/binary")?;
// Find a function by name
let function = db.find_function_by_name("my_function")?;
// get all params:
for param in &function.params {
println!("Param: {:?} with type: {}", param.name, param.ty.display_name());
}
Ok(())
}
This project is licensed under the MIT License - see the LICENSE file for details.
Note: This is an experimental project. Please report any issues or feature requests on our GitHub issue tracker.