0

Hi!
I need help . Can you tell me how can I view the Machine Code of a certain C++ Source Code? I have tried typing [DEBUG filename.exe] in the command prompt but how can I view the declarations of the variables used ? Your replies would be highly appreciated =)
Thanks Hi!
I need help . Can you tell me how can I view the Machine Code of a certain C++ Source Code? I have tried typing [DEBUG filename.exe] in the command prompt but how can I view the declarations of the variables used ? Your replies would be highly appreciated =)
Thanks

2
Contributors
1
Reply
2
Views
9 Years
Discussion Span
Last Post by Narue
0

Viewing the "machine code" is pretty much a silly idea. More likely you want to see the assembly code that corresponds to the machine code. In that case there are two easy ways depending on whether you have the C++ code available or not.

If you have the source code, simply compile it with whatever switch your compiler provides for assembly output. Most likely you'll get some easy to read assembly with the matching C++ source interspersed as comments so you have a better idea what's going on.

If you don't have the source code but you do have an executable, you can use a tool like OllyDbg that gives you detailed information on the runtime execution as well as a good disassembly.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.