43 releases

0.1.45 Oct 8, 2020
0.1.44 Oct 3, 2020
0.1.41 Sep 14, 2020
0.1.36 Aug 27, 2020
0.1.20 Jun 28, 2020

#93 in #x86-64

Download history 6/week @ 2024-07-21 73/week @ 2024-07-28 63/week @ 2024-09-22 27/week @ 2024-09-29

104 downloads per month

MIT license

120KB
3K SLoC

x64_asm at crates.io x64_asm at docs.rs

x64_asm

x86_64 assembler

Get Started

How to use as an assembler command

cargo build
./target/debug/x64_asm <assembly-file in AT&T syntax>

How to use as a Rust crate

See documentation

use x64_asm;

fn main() -> Result<(), Box<dyn std::error::Error>>{
    // you can pass a file(or string).
    let elf_builder = x64_asm::assemble_file("asm.s", x64_asm::Syntax::ATANDT)?;
    
    elf_builder.generate_elf_file("obj.o")?;

    Ok(())
}

Test

cargo test
cargo test --features sample

Dependencies


lib.rs:

An x86_64 assembler.

Dependencies

~1.6–2.3MB
~47K SLoC