{"id":5449,"date":"2014-03-30T22:11:10","date_gmt":"2014-03-30T22:11:10","guid":{"rendered":"https:\/\/unknownerror.org\/index.php\/2014\/03\/30\/how-can-i-force-gdb-to-disassemble-collection-of-common-programming-errors\/"},"modified":"2014-03-30T22:11:10","modified_gmt":"2014-03-30T22:11:10","slug":"how-can-i-force-gdb-to-disassemble-collection-of-common-programming-errors","status":"publish","type":"post","link":"https:\/\/unknownerror.org\/index.php\/2014\/03\/30\/how-can-i-force-gdb-to-disassemble-collection-of-common-programming-errors\/","title":{"rendered":"How can I force GDB to disassemble?-Collection of common programming errors"},"content":{"rendered":"<p>Do you only want to disassemble your actual main? If so try this:<\/p>\n<pre><code>(gdb) info line main \n(gdb) disas STARTADDRESS ENDADDRESS\n<\/code><\/pre>\n<p>Like so:<\/p>\n<pre><code>USER@MACHINE \/cygdrive\/c\/prog\/dsa\n$ gcc-3.exe -g main.c\n\nUSER@MACHINE \/cygdrive\/c\/prog\/dsa\n$ gdb a.exe\nGNU gdb 6.8.0.20080328-cvs (cygwin-special)\n...\n(gdb) info line main\nLine 3 of \"main.c\" starts at address 0x401050  and ends at 0x401075<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Do you only want to disassemble your actual main? If so try this: (gdb) info line main (gdb) disas STARTADDRESS ENDADDRESS Like so: USER@MACHINE \/cygdrive\/c\/prog\/dsa $ gcc-3.exe -g main.c USER@MACHINE \/cygdrive\/c\/prog\/dsa $ gdb a.exe GNU gdb 6.8.0.20080328-cvs (cygwin-special) &#8230; (gdb) info line main Line 3 of &#8220;main.c&#8221; starts at address 0x401050 and ends at 0x401075<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-5449","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/5449","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/comments?post=5449"}],"version-history":[{"count":0,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/5449\/revisions"}],"wp:attachment":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/media?parent=5449"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/categories?post=5449"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/tags?post=5449"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}