This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Tree-SSA Newbie Questions
- From: Sebastian Pop <sebastian dot pop at cri dot ensmp dot fr>
- To: Ranjit Mathew <rmathew at gmail dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: Thu, 13 May 2004 15:05:25 +0200
- Subject: Re: Tree-SSA Newbie Questions
- References: <c7vr42$pvt$1@sea.gmane.org>
On Thu, May 13, 2004 at 06:21:54PM +0530, Ranjit Mathew wrote:
> Hi,
>
> I'm a newbie to tree-ssa and have a few questions:
>
> 1. Why isn't Tree Browser enabled for all front-ends
> when --enable-tree-browser is used? For Java, I manually
> added tree-browser.o to its Make-lang.in and things
> seemed to work just fine - I was able to use browse_tree()
> from within GDB, etc.
>
That's because the following patch didn't included @TREE-BROWSER@ in
each compiler or didn't included it at the right place: the fix is to
include this directly into OBJS-common:
OBJS-common = ... @ANDER@ ... @TREE-BROWSER@ ...
2004-04-05 Ben Elliston <bje@au.ibm.com>
* Makefile.in (OBJS-common): Remove tree-browser.o.
(cc1): Depend on @TREEBROWSER@ and include in list of objects.
* configure.ac: Add --enable-tree-browser option.
* configure: Rebuild.
Index: Makefile.in
===================================================================
RCS file: /cvs/gcc/gcc/gcc/Makefile.in,v
retrieving revision 1.903.2.198
diff -u -p -r1.903.2.198 Makefile.in
--- Makefile.in 2 Apr 2004 13:41:36 -0000 1.903.2.198
+++ Makefile.in 5 Apr 2004 03:50:07 -0000
@@ -868,7 +868,7 @@ C_OBJS = c-parse.o c-lang.o stub-objc.o
OBJS-common = \
tree-cfg.o tree-dfa.o tree-eh.o tree-ssa.o tree-optimize.o tree-simple.o \
tree-alias-type.o gimplify.o tree-pretty-print.o tree-into-ssa.o \
- tree-outof-ssa.o tree-alias-common.o tree-ssa-ccp.o tree-browser.o \
+ tree-outof-ssa.o tree-alias-common.o tree-ssa-ccp.o \
@ANDER@ tree-ssa-dce.o tree-ssa-copy.o tree-nrv.o tree-ssa-copyrename.o \
tree-ssa-pre.o tree-ssa-live.o tree-ssa-operands.o tree-ssa-alias.o \
tree-ssa-phiopt.o tree-ssa-forwprop.o tree-nested.o tree-ssa-dse.o \
@@ -1152,9 +1152,9 @@ $(SPECS): xgcc$(exeext)
gcc-cross: xgcc$(exeext)
cp xgcc$(exeext) gcc-cross$(exeext)
-cc1$(exeext): $(C_OBJS) $(BACKEND) $(LIBDEPS)
+cc1$(exeext): $(C_OBJS) $(BACKEND) $(LIBDEPS) @TREEBROWSER@
$(CC) $(ALL_CFLAGS) $(LDFLAGS) -o cc1$(exeext) \
- $(C_OBJS) $(BACKEND) $(LIBS)
+ $(C_OBJS) @TREEBROWSER@ $(BACKEND) $(LIBS)
# Build the version of limits.h that we will install.
xlimits.h: glimits.h limitx.h limity.h
Index: configure.ac
===================================================================
RCS file: /cvs/gcc/gcc/gcc/configure.ac,v
retrieving revision 2.10.2.9
diff -u -p -r2.10.2.9 configure.ac
--- configure.ac 2 Apr 2004 13:41:36 -0000 2.10.2.9
+++ configure.ac 5 Apr 2004 03:50:10 -0000
@@ -544,6 +544,14 @@ if test x$enable_gather_detailed_mem_sta
[Define to enable detailed memory allocation stats gathering.])
fi
+AC_ARG_ENABLE(tree-browser,
+[ --enable-tree-browser enable the tree browsing routines for debugging], [],
+[enable_tree_browser=no])
+if test x$enable_tree_browser = xyes ; then
+ TREEBROWSER=tree-browser.o
+fi
+AC_SUBST(TREEBROWSER)
+
# -------------------------------
# Miscenalleous configure options
# -------------------------------