Just started out with x86 assembly and slowly getting the hang of it. IDA produces nice graphs that make it much easier to follow all the jumps and function calls and stuff.

I've looked at examples of arithmetics, control flow, loops, and function calls, and feel that I could reasonably take a chunk of instructions and reproduce the same logic in Java or C.

Are there tools that will automatically take assembly and convert it to, say, C? I imagine for some people that at some point it becomes more of a chore than an exercise after doing it for years.

  • An example I saw before is a simple XOR encryption algorithm that used a 64 KB key for some reason. That's not something you want to type out manually...
    – MxLDevs
    Jun 19, 2014 at 21:19
  • 1
    Decompilation is not that simple, the most complex thing is about rebuilding the high-level structures of the program that have been lost during the compilation process (variables, functions, modules/classes, ...).
    – perror
    Jun 19, 2014 at 21:32
  • @perror I'm thinking more along the lines of subroutines and low-level structures. For example, after digging around with a debugger I've pinpointed the exact set of subroutines that perform a certain operation, and that is all that I need. Oh except there are a million instructions involved.
    – MxLDevs
    Jun 19, 2014 at 21:40
  • You can use decompiler in IDA to produce a C file. It's not included in free version of IDA though.
    – Paul
    Jun 20, 2014 at 7:57

2 Answers 2


Yes, that type of tool is called a

Several examples below:


There's also asm2c that works on assembly source code instead of executables or objects files.

Swift tool to transform DOS/PMODEW 386 TASM Assembly code to C code

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.