X86 assembly language is a family of backward-compatible assembly languages, which. Program for Linux in NASM style assembly using the C standard library; 8.6 'Hello world! In order to translate back into a flat address, the segment value is shifted four bits left (equivalent to multiplication by 24 or 16) then added to. GENERAL: CAN THE TOOLS TRANSLATE ASSEMBLY TO C? Is there a way to translate assembly language code to C using the Keil tools? The possible C interpretations are too varied for our tools to include an application which could interpret the 'intent' of assembly language code and convert it to a high-level language such as C.
Active3 years, 9 months ago
What process can be used to convert assembly code into equivalent C code? What kind of tools can be leveraged for higher result accuracy?
Madhav Datt90522 gold badges77 silver badges2323 bronze badges
BrianBrian
closed as off-topic by rkhb, Tunaki, Bhargav Rao♦, rene, Paul RoubDec 29 '15 at 20:57
This question appears to be off-topic. The users who voted to close gave this specific reason:
- 'Questions asking us to recommend or find a book, tool, software library, tutorial or other off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.' – rkhb, Tunaki, Bhargav Rao, rene, Paul Roub
5 Answers
You cannot go backward to the original C but can do a static binary translation into C that is equivalent to the machine instruction.
old_timerold_timer
51.1k77 gold badges6767 silver badges129129 bronze badges
DaniDani10.4k1111 gold badges5252 silver badges9191 bronze badges
The term you are looking for is 'decompiler'. Check here for a discussion:
Burton SamogradBurton Samograd
I used IDAPro in the past and it does a pretty good job doing what you need.
Check it out.
istudy0istudy085855 gold badges1212 silver badges2020 bronze badges
If you have an entire application originally written in Assembly, you could look for an automated tool that can convert the entire code base. One that does Assembler conversions that might want to take a look at is Datatek:
Datatek has developed a sophisticated tool-set and a highly customizable process for the automated conversion of Assembler to high-level languages such as C, C++, COBOL, C#, Java, etc.
Full disclosure: I work for Datatek, and personally think we provide a useful service.
Joshua HornJoshua Horn