Your company here — click to reach over 10,000 unique daily visitors

rasm2 - Man Page

radare2 assembler and disassembler tool


rasm2[-ABdDeEfCLvwrNqx] [-a arch] [-b bits] [-c cpu] [-F in:out] [-o offset] [-@ offset] [-O ofile] [-s syntax] [-i int] [-l int] [ARG]


This tool uses r_asm to assemble and disassemble files or hexpair strings. It supports a large list of architectures which can be listed using the -L flag.

-a arch

Set architecture plugin


Show analysis information of given hexpair string

-b bits

Set architecture bits


Binary input/output (-l is mandatory for binary input)

-c cpu

Select specific CPU (depends on -a arch)


Output in C format


Disassemble hexpair bytes. rasm2 -d 9090


Disassemble showing hexpair and opcode


Use big endian (or swap endianness if used more than once)


Output disassembled instructions in ESIL format.


Read data from file instead of ARG.

-F in:out

Specify input and/or output filters (att2intel, x86.pseudo, ...)


Show usage help message.


Show long help message including supported assembler directives

-l int

Input/Output length

-i int

Ignore/skip N bytes from the beginning of the input buffer


List loaded asm plugins


List loaded anal plugins


List loaded arch plugins

-o offset

Offset of the opcode to assemble (default is 0)

-@ offset

Alias for -o


Dont load any plugin, same as R2_NOPLUGINS=1 or r2 -NN

-O ofile

output to file, for example 'rasm2 -BF a a.asm'


Show output in r2 script

-s syntax

Select syntax output (intel, att)


Describe opcode (whats op)


Use hex dwords instead of hexpairs in the assembler output


Quiet output (handy for -L, -v, ...)


List the supported assembler and preprocessor directives with:

$rasm2 -hh


Assemble opcode:

$ rasm2 -a x86 -b 32 'mov eax, 33'

Disassemble opcode:

$ rasm2 -d 90

See Also



pancake <pancake@nopcode.org>

Referenced By


March 27, 2023