且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何查看code :: Blocks的拆卸?

更新时间:2023-02-27 15:11:56

那种拆卸,作者显示在文章中被称为间叶拆卸(C和拆卸交错)这几家的IDE如Visual Studio支持。 code块不支持。但是,code块有这样一个独立的反汇编窗口

如何查看code :: Blocks的拆卸?

选择一个源代码行。右键点击。说运行到光标。现在调试 - >调试Windows的>拆卸。相反,运行到光标,您还可以设置断点,然后做到这一点。但不知何故未与矿顺利,所以我建议运行到光标方法。

希望它帮助。

I read this article about some low level underpinnings of C/C++, and the author is basically showing us through the assembly code generated by the compiler, line by line. He is using VS 2010, but I don't, I use Code::Blocks. How do I view the disassembly there? When I go to debugger, and click disassembly, it shows me a blank window...

This is the C++ (.cpp) code (the whole code) I compiled:

int main()
{
    int x = 1;
    int y = 2;
    int z = 0;

    z = x + y;

    return 0;
}

The kind of disassembly that the author shows in the article is called inter-leaved disassembly ( C and disassembly interleaved ) which a few IDEs like Visual Studio support. Code Blocks does not support. But Code Blocks has a separate disassembly window like this

Select a source line. Right Click. Say Run to Cursor. Now Debug->Debugging Windows->Disassembly. Instead of Run to cursor you can also set break points and then do this. But somehow it wasn't going well with mine, so I am suggesting Run to Cursor method.

Hope it helps.