summaryrefslogtreecommitdiffstats
path: root/.gdbinit
diff options
context:
space:
mode:
authorYann Ylavic <ylavic@apache.org>2015-03-14 00:59:42 +0100
committerYann Ylavic <ylavic@apache.org>2015-03-14 00:59:42 +0100
commit7249bf507515fb4ebce7fa693627f2e14c06e490 (patch)
treef3c68a21e36801ee2dd6df8aac2b649509e325bf /.gdbinit
parentwork w/ apr_skiplist_insert() (diff)
downloadapache2-7249bf507515fb4ebce7fa693627f2e14c06e490.tar.xz
apache2-7249bf507515fb4ebce7fa693627f2e14c06e490.zip
.gdbinit: Add dump_skiplist.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1666617 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to '.gdbinit')
-rw-r--r--.gdbinit19
1 files changed, 19 insertions, 0 deletions
diff --git a/.gdbinit b/.gdbinit
index 6b3f9b72a4..e28763d7d3 100644
--- a/.gdbinit
+++ b/.gdbinit
@@ -18,6 +18,25 @@ document dump_table
Print the key/value pairs in a table.
end
+define dump_skiplist
+ set $sl = (apr_skiplist *)$arg0
+ set $m = $sl->bottom
+ printf "skiplist@%p: size=%lu: height=%d\n", $sl, $sl->size, $sl->height
+ while ($m)
+ printf "(%p,%.12lx)", $m, $m->data
+ set $u = $m->up
+ while ($u)
+ printf " (%p,%.12lx)", $u, $u->data
+ set $u = $u->up
+ end
+ printf "\n"
+ set $m = $m->next
+ end
+end
+document dump_skiplist
+ Print the nodes/values in a skiplist
+end
+
define dump_string_hash
set $h = $arg0->array
set $n = $arg0->max