Discussion Locked

To Convert Assembly code into any Progra

0 helpful
5 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

Hi ,

I have requirement where I need to convert Assembly code in to some Higher end Code like VB or c/c++ where I can make the changes.

Someone has any idea / done it before ?
Any utilities available to do so ?

Immidiate response is greatly appreciated.

Pramod

5 replies

by geoffreyc

I haven't seen anything that will automatically convert assembler into a higher level language, though that doesn't mean it wont exist of course. I have done it for simple code before, but it is a matter of determining what the assembler is doing and then rewriting the program in the higher language. You may need to learn assembler to do this.
The good thing will be that you wont need to worry about assigning memory if you use something like VB to write it anew. You can then go through and, for example, see in the assembler that an input is being assigned to a section of memory and then added to another section of memory previously assigned. You can then rewrite as variable A + variable B. This would of course be a long and tedious process. It may be faster rewriting the whole code from scratch, knowing only the functions it is to perform, if the assembler is of any great length.

by wls

There used to be a product called Sourcer which would read machine language and then reconstruct assembly language and comment it.

However, assembly language (the pseduo-representation of machine language) is as good as you're ever going to get [realistically speaking]. During the course of language translation, there are a lot of one-way operations that happen.

For instance, suppose you have a function that operates on thirty different values. Your compiler may perform some operations at compile time -- like evaluating constants in the expression. And then it may realize that it only needs one or two registers at any given time to perform the actual calculation.

A library known as Spontaneous Assembly was amazingly faster because it did all its work in registers and not on the stack.

By the time machine code is executed, you've lost all high-level abstractions, variable names, class names, function names, and programmer comments.

This discussion is closed to new replies.