aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.8.3/gcc/gdbinit.in
diff options
context:
space:
mode:
authorDan Albert <danalbert@google.com>2016-02-24 13:48:45 -0800
committerDan Albert <danalbert@google.com>2016-02-24 13:51:18 -0800
commitb9de1157289455b0ca26daff519d4a0ddcd1fa13 (patch)
tree4c56cc0a34b91f17033a40a455f26652304f7b8d /gcc-4.8.3/gcc/gdbinit.in
parent098157a754787181cfa10e71325832448ddcea98 (diff)
downloadtoolchain_gcc-b9de1157289455b0ca26daff519d4a0ddcd1fa13.tar.gz
toolchain_gcc-b9de1157289455b0ca26daff519d4a0ddcd1fa13.tar.bz2
toolchain_gcc-b9de1157289455b0ca26daff519d4a0ddcd1fa13.zip
Update 4.8.1 to 4.8.3.
My previous drop was the wrong version. The platform mingw is currently using 4.8.3, not 4.8.1 (not sure how I got that wrong). From ftp://ftp.gnu.org/gnu/gcc/gcc-4.8.3/gcc-4.8.3.tar.bz2. Bug: http://b/26523949 Change-Id: Id85f1bdcbbaf78c7d0b5a69e74c798a08f341c35
Diffstat (limited to 'gcc-4.8.3/gcc/gdbinit.in')
-rw-r--r--gcc-4.8.3/gcc/gdbinit.in210
1 files changed, 210 insertions, 0 deletions
diff --git a/gcc-4.8.3/gcc/gdbinit.in b/gcc-4.8.3/gcc/gdbinit.in
new file mode 100644
index 000000000..e2c7a8c4e
--- /dev/null
+++ b/gcc-4.8.3/gcc/gdbinit.in
@@ -0,0 +1,210 @@
+# Copyright (C) 2001-2013 Free Software Foundation, Inc.
+#
+# This file is part of GCC.
+#
+# GCC is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3, or (at your option)
+# any later version.
+#
+# GCC is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with GCC; see the file COPYING3. If not see
+# <http://www.gnu.org/licenses/>.
+
+define pr
+set debug_rtx ($)
+end
+
+document pr
+Print the full structure of the rtx that is $.
+Works only when an inferior is executing.
+end
+
+define prl
+set debug_rtx_list ($, debug_rtx_count)
+end
+
+document prl
+Print the full structure of all rtx insns beginning at $.
+Works only when an inferior is executing.
+Uses variable debug_rtx_count to control number of insns printed:
+ debug_rtx_count > 0: print from $ on.
+ debug_rtx_count < 0: print a window around $.
+
+There is also debug_rtx_find (rtx, uid) that will scan a list for UID and print
+it using debug_rtx_list. Usage example: set $foo=debug_rtx_find(first, 42)
+end
+
+define pt
+set debug_tree ($)
+end
+
+document pt
+Print the full structure of the tree that is $.
+Works only when an inferior is executing.
+end
+
+define pct
+set debug_c_tree ($)
+end
+
+document pct
+Print the tree that is $ in C syntax.
+Works only when an inferior is executing.
+end
+
+define pgg
+set debug_gimple_stmt ($)
+end
+
+document pgg
+Print the Gimple statement that is $ in C syntax.
+Works only when an inferior is executing.
+end
+
+define pgq
+set debug_gimple_seq ($)
+end
+
+document pgq
+Print the Gimple sequence that is $ in C syntax.
+Works only when an inferior is executing.
+end
+
+define pgs
+set debug_generic_stmt ($)
+end
+
+document pgs
+Print the statement that is $ in C syntax.
+Works only when an inferior is executing.
+end
+
+define pge
+set debug_generic_expr ($)
+end
+
+document pge
+Print the expression that is $ in C syntax.
+Works only when an inferior is executing.
+end
+
+define ptc
+output (enum tree_code) $.common.code
+echo \n
+end
+
+document ptc
+Print the tree-code of the tree node that is $.
+end
+
+define pdn
+output $.decl_minimal.name->identifier.id.str
+echo \n
+end
+
+document pdn
+Print the name of the decl-node that is $.
+end
+
+define ptn
+output $.type.name->decl_minimal.name->identifier.id.str
+echo \n
+end
+
+document ptn
+Print the name of the type-node that is $.
+end
+
+define pvt
+set debug_vec_tree ($)
+end
+
+document pvt
+Print the VEC(tree) that is in $.
+end
+
+define pdd
+set debug_dwarf_die ($)
+end
+
+document pdd
+Print the dw_die_ref that is in $.
+end
+
+define prc
+output (enum rtx_code) $.code
+echo \ (
+output $.mode
+echo )\n
+end
+
+document prc
+Print the rtx-code and machine mode of the rtx that is $.
+end
+
+define pi
+print $.u.fld[0].rt_rtx@7
+end
+
+document pi
+Print the fields of an instruction that is $.
+end
+
+define pbs
+set print_binding_stack ()
+end
+
+document pbs
+In cc1plus, print the current binding stack, frame by frame, up to and
+including the global binding level.
+end
+
+define pbb
+set dump_bb ($, stderr, 0)
+end
+
+document pbb
+Dump the basic block that is in $, including rtx.
+end
+
+define pbm
+set bitmap_print (stderr, $, "", "\n")
+end
+
+document pbm
+Dump the bitmap that is in $ as a comma-separated list of numbers.
+end
+
+# Define some macros helpful to gdb when it is expanding macros.
+macro define __FILE__ "gdb"
+macro define __LINE__ 1
+
+# Gracefully handle aborts in functions used from gdb.
+set unwindonsignal on
+
+# Put breakpoints at exit and fancy_abort in case abort is mapped
+# to either fprintf/exit or fancy_abort.
+b fancy_abort
+
+# Put a breakpoint on internal_error to help with debugging ICEs.
+b internal_error
+
+set complaints 0
+# Don't let abort actually run, as it will make
+# stdio stop working and therefore the `pr' command above as well.
+# Put this last because gcc does not reference it any more unless
+# USE_SYSTEM_ABORT is defined, so gdb may complain and bail out.
+b exit
+b abort
+
+# Skip all inline functions in tree.h.
+# These are used in accessor macros.
+# Note that this is added at the end because older gdb versions
+# do not understand the 'skip' command.
+skip file tree.h