This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: printing "tree" type data
- From: Ian Lance Taylor <iant at google dot com>
- To: ranjith kumar <ranjit_kumar_b4u at yahoo dot co dot uk>
- Cc: gcc-help at gcc dot gnu dot org
- Date: 04 Jun 2007 16:17:55 -0700
- Subject: Re: printing "tree" type data
- References: <20070604142104.22149.qmail@web27411.mail.ukl.yahoo.com>
ranjith kumar <ranjit_kumar_b4u@yahoo.co.uk> writes:
> I want to print the last statement(which is of
> "tree" type) in a given basic block.
>
> The last statement of a basic-block pointed by bb can
> be get by last_stmt(bb);
> I want to see that instruction.
>
> I want to print that statement to a dump file or
> standard output. Ordinary data types can be printed by
> fprintf in source code. But how to print "tree" data
> type?
Look at the debug_tree and debug_generic_stmt functions.
Look at gcc/gdbinit.in for some useful gdb macros.
Ian