Hello guys.

I currently code in C++.But I want to gain knowledge of internals of C++.So , I want to analyse my each and every program in ASM.

I use Windows 7 platform and code::blocks.Please provide necessary information or tools , which can help me in this regard.

Thanks!

g++ -S foo.cpp will produce a foo.s file, which is the ASM code corresponding to your source code.

If you use custom makefiles in c::b, you might be able to generate them automatically.

Thanks for reply.But please explain how I produce asm code through that command.I mean where to put that command in c::b , as I always use "run and build" button.

Thanks for reply.But please explain how I produce asm code through that command.I mean where to put that command in c::b , as I always use "run and build" button.

"Project" menu > "Build Options..." item > "Compiler settings" tab > "Other options" sub-tab > Add compiler options to the text area.

What you type in depends on your compiler. If you're using GCC, try "-save-temps"--it will both compile your program and preserve the generated assembly files.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.