# Writing a Debugger From Scratch - DbgRs Part 7 - Disassembly

DevFeed: [Writing a Debugger From Scratch - DbgRs Part 7 - Disassembly](<https://devfeed.tech/articles/writing-a-debugger-from-scratch-dbgrs-part-7-disassembly-39739.md>)

Original publisher: [Read original article](<https://www.timdbg.com/posts/writing-a-debugger-from-scratch-part-7/>)

Author: Tim Misiak

Published: 2024-01-18T16:10:45Z

Content type: tutorial

Language: en

Sources: [TimDbg](<https://devfeed.tech/sources/timdbg.md>)

Topics: [debug](<https://devfeed.tech/topics/debug.md>), [Assembly](<https://devfeed.tech/topics/assembly.md>), [x86](<https://devfeed.tech/topics/x86.md>), [Rust](<https://devfeed.tech/topics/rust.md>), [Iced](<https://devfeed.tech/topics/iced.md>)

Tags: [assembly](<https://devfeed.tech/tags/assembly.md>), [code](<https://devfeed.tech/tags/code.md>), [debugger](<https://devfeed.tech/tags/debugger.md>), [debugging](<https://devfeed.tech/tags/debugging.md>), [encoding](<https://devfeed.tech/tags/encoding.md>), [memory](<https://devfeed.tech/tags/memory.md>), [rust](<https://devfeed.tech/tags/rust.md>), [windbg](<https://devfeed.tech/tags/windbg.md>), [x86](<https://devfeed.tech/tags/x86.md>)

## AI overview

This tutorial installment explains how the DbgRs low-level debugger adds disassembly for Windows x64 code. It introduces the challenges of decoding x86 instruction encodings and describes using a Rust disassembly crate with iced-x86 instead of implementing a complete disassembler from scratch.

## Source excerpt

(New to this series? Consider starting from part 1) At the end of the last post, DbgRs could display stacks, which is the single most powerful tool in the debugging arsenal. But once you have those frames to examine, you need to understand what that code was doing. Source code is one place to look at, but if you're using a low level debugger like WinDbg or KD there's a good chance you need to see the assembly code, which means we need a disassembler.