8 releases

Uses new Rust 2024

new 0.1.7 Apr 14, 2025
0.1.6 Apr 11, 2025

#209 in Compression

Download history 577/week @ 2025-04-06

577 downloads per month

MIT license

155KB
2.5K SLoC

Rust 1.5K SLoC // 0.0% comments Python 1.5K SLoC // 0.3% comments Shell 10 SLoC // 0.3% comments

Contains (ELF exe/lib, 6KB) tests/data/test.elf

RVDASM

A RISC-V disassmbler written in rust.

Key features

  • Correct: code-gen from riscv-opcodes
  • Programmer-friedly: outputs to struct, not string
  • Simple: easy to read and modify

Usage

Example:

RUST_LOG=debug cargo run  --example dasm -- --file [ELF] --print

Supported Extensions

I, M, A , C, F, D, V, zicsr.

Distinguishes XLEN of 32 or 64.

Development Notes

The isa.rs file is generated from iansseijelly:riscv-opcodes. This repo is also registered as a submodule in ${ROOT}/riscv-opcodes. Run gen.sh in that repo to generate isa.rs and isa_consts.rs.

Dependencies