moved things around
authorJorge Gorbe <j.gorbe@stcsl.es>
Tue, 20 Nov 2012 19:07:29 +0000 (20:07 +0100)
committerJorge Gorbe <j.gorbe@stcsl.es>
Tue, 20 Nov 2012 19:07:29 +0000 (20:07 +0100)
slides/fascinating.png [new file with mode: 0644]
slides/index.html
slides/mckayla.jpg [new file with mode: 0644]
slides/reactionguys.jpg [new file with mode: 0644]

diff --git a/slides/fascinating.png b/slides/fascinating.png
new file mode 100644 (file)
index 0000000..ab778ef
Binary files /dev/null and b/slides/fascinating.png differ
index c504e9d8fa35802258b8c4ade2b4617700a3a3b5..d576414b39470ca811b150d46ed2788294844a92 100644 (file)
                         <li> You can try crazy new ideas :D </li>
                     </ul>
                 </section>
-
                 <section>
-                    <h2>Extension points</h2>
-                    <ul>
-                        <li class="fragment">Pretty printers</li>
-                        <li class="fragment">Custom commands</li>
-                        <li class="fragment">Code auto-loading</li>
-                        <li class="fragment">Event handlers (<code>stop, cont, exited, new_objfile</code>)</li>
-                        <li class="fragment">"Convenience functions"</li>
-                        <li class="fragment">Custom parameters (like "<code>set parameter value</code>", then retrieve values from commands, etc)</li>
-                    </ul>
-                </section>
-
-                <!--
-                <section>
-                    <h2>Fun with breakpoints!</h2>
-                    <h3>Conditional breakpoints</h3>
-                    <p> <code> break myfile.cpp:99 if x &gt; 0 </code> </p>
-                    <p class="fragment">Not so interesting</p>
-                 </section>
-                -->
-
-                <section>
-                    <h2> <a href="http://slackito.com/2011/12/09/poor-mans-tracepoints-with-gdb/">Poor man's tracepoints</a> </h2>
+                    <section>
+                        <h2><b>OLD</b> extension points</h2>
+                        <ul>
+                            <li>Breakpoint actions</li>
+                            <li>Canned sequences as commands</li>
+                            <li>Hook pre and post execution of gdb commands</li>
+                            <li>.gdbinit for autoloading</li>
+                        </ul>
+                        <div class="fragment">
+                            <p style="margin-top:40px">Nothing impressive here</p>
+                            <img src="mckayla.jpg">
+                        </div>
+                    </section>
+                    <section>
+                        <h2> Breakpoint actions </h2>
+                        <p><a href="http://slackito.com/2011/12/09/poor-mans-tracepoints-with-gdb/">Poor man's tracepoints</a> </p>
 <pre>
 break myfile.cpp:99
 Breakpoint 1 at 0x401193: file myfile.c, line 99.
@@ -114,13 +107,13 @@ End with a line saying just "end".
 &gt;cont
 &gt;end
 </pre>
-                    <p class="fragment">
-                        That <code>cont</code> screws single-stepping (solvable with Python, see <a href="http://tromey.com/blog/?p=698">this blog post</a>)
-                    </p>
-                </section>
+                        <p class="fragment">
+                            That <code>cont</code> screws single-stepping (solvable with Python, see <a href="http://tromey.com/blog/?p=698">this blog post</a>)
+                        </p>
+                    </section>
 
-                <section>
-                <h2> Custom commands (1/3) </h2>
+                    <section>
+                    <h2> Canned sequences (1/2) </h2>
 <pre>
 (gdb) define plist
 Type commands for definition of "plist".
@@ -132,11 +125,11 @@ End with a line saying just "end".
  >end
 >end
 </pre>
-                </section>
+                    </section>
 
-                <section>
-                <h2> Custom commands (2/3) </h2>
-                <p>A more complex example, from PpluX's <a href="http://code.google.com/p/slb/source/browse/extra/lua_utils.gdb?name=default">SLB repo</a></p>
+                    <section>
+                    <h2> Canned sequences (2/2) </h2>
+                    <p>A more complex example, from PpluX's <a href="http://code.google.com/p/slb/source/browse/extra/lua_utils.gdb?name=default">SLB repo</a></p>
 
 <pre><code>define luastack
     set $top = lua_gettop($arg0)
@@ -158,26 +151,55 @@ End with a line saying just "end".
         set $i = $i + 1
     end
 </code></pre>
+                    </section>
 
-                </section>
+                    <section>
+                        <h2> Command hooks </h2>
+                        <p> You can also create hooks which run just before or after any gdb command: </p>
+                        <ul style="text-align:left;">
+                            <li> <code>define hook-command</code> to run things <b>before</b> <code>command</code> </li>
+                            <li> <code>define hookpost-command</code> to run things <b>after</b> <code>command</code> </li>
 
-                <section>
-                    <h2> Custom commands (3/3) </h2>
-                    <p> You can also create hooks which run just before or after any gdb command: </p>
-                    <ul style="text-align:left;">
-                        <li> <code>define hook-command</code> to run things <b>before</b> <code>command</code> </li>
-                        <li> <code>define hookpost-command</code> to run things <b>after</b> <code>command</code> </li>
+                    </section>
 
                 </section>
 
                 <section>
                     <h2>Enter Python</h2>
                     <ul>
-                        <li> GDB 7.x has (optionally) an embedded Python interpreter and a Python API </li>
-                        <li> Still being refined, but quite usable </li>
+                        <li> GDB 7.x has (optionally) an embedded Python interpreter... </li>
+                        <li class="fragment"> ...and a Python API <br>
+                        <img src="reactionguys.jpg">
+                        </li>
+                        <small class="fragment">(there are still some quirks here and there, but it's quite usable :D)</small>
                     </ul>
                 </section>
 
+                <section>
+                    <h2><b>NEW</b> Extension points</h2>
+                    <ul>
+                        <li class="fragment">Pretty printers <br>
+                            <small>custom representation of data structures</small>
+                        </li>
+                        <li class="fragment">Custom commands <br>
+                            <small>can even define custom parameters to be set via gdb's <code>set parameter value</code> mechanism</small>
+                        </li>
+                        <li class="fragment">Code auto-loading <br>
+                            <small>e.g. load pretty printers when a library is loaded, register things at init</small>
+                        </li>
+
+                        <li class="fragment">Event handlers <br>
+                            <small><code>stop, cont, exited, new_objfile</code></small>
+                        </li>
+                        <li class="fragment">"Convenience functions"
+                            <small>
+                            hook expression evaluation, e.g. define <code>$caller_is(string)</code> and then <code>break file:line if $caller_is("main")</code>,
+                            see this <a href="http://tromey.com/blog/?p=515">article with a implementation of $caller_is()</a>
+                            </small>
+
+                        </li>
+                    </ul>
+                </section>
                 <section>
                     <h2>Python in GDB</h2>
                     <p> Hello World </p>
@@ -295,6 +317,13 @@ DoNothingCommand() # and instance it
                 </section>
 
                 <section>
+                    <h2>The Python API</h2>
+                    <p> Pretty much every gdb concept is exposed to Python scripts via the API. </p>
+                    <p> <a href="http://sourceware.org/gdb/onlinedocs/gdb/Python-API.html#Python-API">GDB Docs - Python API</a></p>
+                </section>
+
+                <section>
+                <h1>Demo</h1>
                 </section>
 
                 <section>
@@ -319,6 +348,12 @@ DoNothingCommand() # and instance it
                     </ul>
                 </section>
 
+                <section>
+                    <h1>Thanks!</h1>
+                    <h2>Questions?</h2>
+                    <small>(Don't forget to check out the links in next slide if you are viewing this at home)</small>
+                </section>
+
                 <section>
                     <h2>Resources</h2>
                     <ul>
@@ -326,11 +361,6 @@ DoNothingCommand() # and instance it
                     <li> <a href="http://en.wikibooks.org/wiki/Linux_Applications_Debugging_Techniques">http://en.wikibooks.org/wiki/Linux_Applications_Debugging_Techniques</a></li>
                 </section>
 
-                <section>
-                    <h1>Thanks!</h1>
-                    <h2>Questions?</h2>
-                </section>
-
                 <!-- End slides. -->
 
                     </div>
diff --git a/slides/mckayla.jpg b/slides/mckayla.jpg
new file mode 100644 (file)
index 0000000..1b2fb43
Binary files /dev/null and b/slides/mckayla.jpg differ
diff --git a/slides/reactionguys.jpg b/slides/reactionguys.jpg
new file mode 100644 (file)
index 0000000..0c0816f
Binary files /dev/null and b/slides/reactionguys.jpg differ