This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

more obstack cleaning up


You'll never believe this, but there are actually places in GCC that
include obstack.h and yet don't actually use obstacks any more!

And, there are some bogus comments that refer to obstacks!

Bootstrapped on x86-linux.

-- 
Geoff Keating <geoffk@redhat.com>

===File ~/patches/gcc-trimobstackinc.patch==================
Index: ChangeLog
2002-08-05  Geoffrey Keating  <geoffk@redhat.com>

	* attribs.c: Don't include obstack.h.
	* builtins.c: Likewise.
	* cfganal.c: Likewise.
	* cfgbuild.c: Likewise.
	* cfgcleanup.c: Likewise.
	* emit-rtl.c: Likewise.
	* loop.c: Likewise.
	* stmt.c: Likewise.

Index: cp/ChangeLog
2002-08-05  Geoffrey Keating  <geoffk@redhat.com>

	* class.c: Don't include obstack.h.
	(popclass): 
	* decl2.c: Delete bogus comment.
	* error.c: Don't include obstack.h.
	* except.c: Likewise.
	(dump_type): Correct comment.
	* method.c: Don't include obstack.h.
	* tree.c: Likewise.

Index: java/ChangeLog
2002-08-05  Geoffrey Keating  <geoffk@redhat.com>

	* mangle_name.c: Don't include obstack.h twice.
	* xref.c: Don't include obstack.h.

Index: attribs.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/attribs.c,v
retrieving revision 1.23
diff -p -u -p -r1.23 attribs.c
--- attribs.c	26 May 2002 15:01:10 -0000	1.23
+++ attribs.c	5 Aug 2002 18:40:25 -0000
@@ -29,7 +29,6 @@ Software Foundation, 59 Temple Place - S
 #include "ggc.h"
 #include "expr.h"
 #include "tm_p.h"
-#include "obstack.h"
 #include "cpplib.h"
 #include "target.h"
 #include "langhooks.h"
Index: builtins.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/builtins.c,v
retrieving revision 1.158
diff -p -u -p -r1.158 builtins.c
--- builtins.c	3 Aug 2002 23:21:30 -0000	1.158
+++ builtins.c	5 Aug 2002 18:40:25 -0000
@@ -25,7 +25,6 @@ Software Foundation, 59 Temple Place - S
 #include "real.h"
 #include "rtl.h"
 #include "tree.h"
-#include "obstack.h"
 #include "flags.h"
 #include "regs.h"
 #include "hard-reg-set.h"
Index: cfganal.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cfganal.c,v
retrieving revision 1.25
diff -p -u -p -r1.25 cfganal.c
--- cfganal.c	1 Jun 2002 09:24:41 -0000	1.25
+++ cfganal.c	5 Aug 2002 18:40:25 -0000
@@ -28,7 +28,6 @@ Software Foundation, 59 Temple Place - S
 #include "insn-config.h"
 #include "recog.h"
 #include "toplev.h"
-#include "obstack.h"
 #include "tm_p.h"
 
 /* Store the data structures necessary for depth-first search.  */
Index: cfgbuild.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cfgbuild.c,v
retrieving revision 1.26
diff -p -u -p -r1.26 cfgbuild.c
--- cfgbuild.c	19 Jul 2002 23:11:18 -0000	1.26
+++ cfgbuild.c	5 Aug 2002 18:40:25 -0000
@@ -45,7 +45,6 @@ Software Foundation, 59 Temple Place - S
 #include "except.h"
 #include "toplev.h"
 #include "timevar.h"
-#include "obstack.h"
 
 static int count_basic_blocks		PARAMS ((rtx));
 static void find_basic_blocks_1		PARAMS ((rtx));
Index: cfgcleanup.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cfgcleanup.c,v
retrieving revision 1.62
diff -p -u -p -r1.62 cfgcleanup.c
--- cfgcleanup.c	10 Jun 2002 21:36:12 -0000	1.62
+++ cfgcleanup.c	5 Aug 2002 18:40:26 -0000
@@ -46,8 +46,6 @@ Software Foundation, 59 Temple Place - S
 #include "tm_p.h"
 #include "target.h"
 
-#include "obstack.h"
-
 /* cleanup_cfg maintains following flags for each basic block.  */
 
 enum bb_flags
Index: emit-rtl.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/emit-rtl.c,v
retrieving revision 1.288
diff -p -u -p -r1.288 emit-rtl.c
--- emit-rtl.c	29 Jul 2002 19:53:34 -0000	1.288
+++ emit-rtl.c	5 Aug 2002 18:40:26 -0000
@@ -50,7 +50,6 @@ Software Foundation, 59 Temple Place - S
 #include "insn-config.h"
 #include "recog.h"
 #include "real.h"
-#include "obstack.h"
 #include "bitmap.h"
 #include "basic-block.h"
 #include "ggc.h"
Index: loop.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/loop.c,v
retrieving revision 1.415
diff -p -u -p -r1.415 loop.c
--- loop.c	23 Jul 2002 19:19:32 -0000	1.415
+++ loop.c	5 Aug 2002 18:40:27 -0000
@@ -38,7 +38,6 @@ Software Foundation, 59 Temple Place - S
 #include "system.h"
 #include "rtl.h"
 #include "tm_p.h"
-#include "obstack.h"
 #include "function.h"
 #include "expr.h"
 #include "hard-reg-set.h"
Index: stmt.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/stmt.c,v
retrieving revision 1.267
diff -p -u -p -r1.267 stmt.c
--- stmt.c	11 Jun 2002 12:21:40 -0000	1.267
+++ stmt.c	5 Aug 2002 18:40:28 -0000
@@ -46,7 +46,6 @@ Software Foundation, 59 Temple Place - S
 #include "expr.h"
 #include "libfuncs.h"
 #include "hard-reg-set.h"
-#include "obstack.h"
 #include "loop.h"
 #include "recog.h"
 #include "machmode.h"
Index: cp/class.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cp/class.c,v
retrieving revision 1.460
diff -p -u -p -r1.460 class.c
--- cp/class.c	4 Aug 2002 14:43:46 -0000	1.460
+++ cp/class.c	5 Aug 2002 18:40:31 -0000
@@ -35,8 +35,6 @@ Boston, MA 02111-1307, USA.  */
 #include "lex.h"
 #include "target.h"
 
-#include "obstack.h"
-
 /* The number of nested classes being processed.  If we are not in the
    scope of any class, this is zero.  */
 
@@ -5547,8 +5545,6 @@ void
 popclass ()
 {
   poplevel_class ();
-  /* Since poplevel_class does the popping of class decls nowadays,
-     this really only frees the obstack used for these decls.  */
   pop_class_decls ();
 
   current_class_depth--;
Index: cp/decl2.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cp/decl2.c,v
retrieving revision 1.554
diff -p -u -p -r1.554 decl2.c
--- cp/decl2.c	1 Aug 2002 06:20:41 -0000	1.554
+++ cp/decl2.c	5 Aug 2002 18:40:31 -0000
@@ -4330,8 +4330,7 @@ pop_scope (t)
 }
 
 /* [basic.lookup.koenig] */
-/* A non-zero return value in the functions below indicates an error.
-   All nodes allocated in the procedure are on the scratch obstack. */
+/* A non-zero return value in the functions below indicates an error.  */
 
 struct arg_lookup
 {
Index: cp/error.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cp/error.c,v
retrieving revision 1.183
diff -p -u -p -r1.183 error.c
--- cp/error.c	25 Jul 2002 21:13:36 -0000	1.183
+++ cp/error.c	5 Aug 2002 18:40:32 -0000
@@ -24,7 +24,6 @@ Boston, MA 02111-1307, USA.  */
 #include "tree.h"
 #include "cp-tree.h"
 #include "real.h"
-#include "obstack.h"
 #include "toplev.h"
 #include "flags.h"
 #include "diagnostic.h"
@@ -316,8 +315,8 @@ dump_template_bindings (parms, args)
     }
 }
 
-/* Dump into the obstack a human-readable equivalent of TYPE.  FLAGS
-   controls the format.  */
+/* Dump a human-readable equivalent of TYPE.  FLAGS controls the
+   format.  */
 
 static void
 dump_type (t, flags)
Index: cp/except.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cp/except.c,v
retrieving revision 1.142
diff -p -u -p -r1.142 except.c
--- cp/except.c	1 Apr 2002 20:26:13 -0000	1.142
+++ cp/except.c	5 Aug 2002 18:40:32 -0000
@@ -31,7 +31,6 @@ Boston, MA 02111-1307, USA.  */
 #include "libfuncs.h"
 #include "cp-tree.h"
 #include "flags.h"
-#include "obstack.h"
 #include "output.h"
 #include "except.h"
 #include "toplev.h"
Index: cp/method.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cp/method.c,v
retrieving revision 1.226
diff -p -u -p -r1.226 method.c
--- cp/method.c	1 Aug 2002 04:46:19 -0000	1.226
+++ cp/method.c	5 Aug 2002 18:40:32 -0000
@@ -27,7 +27,6 @@ Boston, MA 02111-1307, USA.  */
 #include "system.h"
 #include "tree.h"
 #include "cp-tree.h"
-#include "obstack.h"
 #include "rtl.h"
 #include "expr.h"
 #include "output.h"
Index: cp/tree.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cp/tree.c,v
retrieving revision 1.291
diff -p -u -p -r1.291 tree.c
--- cp/tree.c	2 Aug 2002 17:21:34 -0000	1.291
+++ cp/tree.c	5 Aug 2002 18:40:32 -0000
@@ -22,7 +22,6 @@ Boston, MA 02111-1307, USA.  */
 
 #include "config.h"
 #include "system.h"
-#include "obstack.h"
 #include "tree.h"
 #include "cp-tree.h"
 #include "flags.h"
Index: java/mangle_name.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/java/mangle_name.c,v
retrieving revision 1.4
diff -p -u -p -r1.4 mangle_name.c
--- java/mangle_name.c	20 Dec 2001 22:48:51 -0000	1.4
+++ java/mangle_name.c	5 Aug 2002 18:40:34 -0000
@@ -32,7 +32,6 @@ The Free Software Foundation is independ
 #include "java-tree.h"
 #include "obstack.h"
 #include "toplev.h"
-#include "obstack.h"
 
 static void append_unicode_mangled_name PARAMS ((const char *, int));
 #ifndef HAVE_AS_UTF8
Index: java/xref.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/java/xref.c,v
retrieving revision 1.9
diff -p -u -p -r1.9 xref.c
--- java/xref.c	21 Jan 2000 20:57:00 -0000	1.9
+++ java/xref.c	5 Aug 2002 18:40:34 -0000
@@ -31,8 +31,6 @@ The Free Software Foundation is independ
 #include "xref.h"
 #include "jcf.h"
 #include "parse.h"
-#include "obstack.h"
-
 
 static xref_flag_table xref_table [] = {
   {NULL, NULL, NULL, NULL},
============================================================


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]