Commit Graph

11 Commits

Author SHA1 Message Date
Gabriel Dos Reis 9e2878cff2 gengtype.h (options::info): Change type to const char *.
* gengtype.h (options::info): Change type to const char *.
        (enum gc_used_enum): Move out of struct type scope.
        * gengtype.c (create_option): Convert initializer for
        option::info to
        appropiate type.
        (adjust_field_type, walk_type, write_func_for_structure,
        write_root, write_roots): Remove pointless cast.

From-SVN: r85436
2004-08-02 12:48:49 +00:00
Geoffrey Keating b453c95fd3 Index: libcpp/ChangeLog
2004-05-29  Geoffrey Keating  <geoffk@apple.com>

	* symtab.c (ht_create): Set entries_owned.
	(ht_destroy): Honour entries_owned.
	(ht_expand): Likewise.
	(ht_load): New.

Index: libcpp/include/ChangeLog
2004-05-29  Geoffrey Keating  <geoffk@apple.com>

	* symtab.h (struct ht): New field 'entries_owned'
	(ht_load): New prototype.

Index: gcc/ChangeLog
2004-05-29  Geoffrey Keating  <geoffk@apple.com>

	* gengtype-yacc.y: Add NESTED_PTR token.
	(option): Record `nested_ptr' option.
	* gengtype-lex.l: Handle `nested_ptr' keyword.
	* gengtype.c (walk_type): Process `nested_ptr' option.
	* gengtype.h (struct nested_ptr_data): New.
	* doc/gty.texi (GTY Options): Document `nested_ptr' option.
	* stringpool.c (struct string_pool_data): Make 'entries' point to
	ht_identifier instead of tree.
	(gt_pch_save_stringpool): Don't adjust pointers.
	(gt_pch_restore_stringpool): Call ht_load.

From-SVN: r82438
2004-05-30 00:49:06 +00:00
Zack Weinberg 1431042ef1 gengtype.c (create_option): New function.
* gengtype.c (create_option): New function.
	* gengtype.h: Prototype it.
	* gengtype-yacc.y (stringseq): New rule.
	(option): Use create_option.  Add new bare ID production.  Use
	stringseq, not STRING directly.

	* alias.c, bitmap.c, c-decl.c, cgraph.h, cpplib.h, cselib.h
	* dwarf2out.c, emit-rtl.c, function.h, lists.c, tree.h
	* varray.h, config/alpha/alpha.c, cp/name-lookup.c, cp/parser.c
	* f/com.c, java/builtins.c, java/expr.c, java/jcf.h, java/parse.h:
	Use new shorter form of GTY markers.

	* doc/gty.texi: Rewrite.

From-SVN: r80091
2004-03-30 19:19:06 +00:00
Kazu Hirata d9221e016b alias.c, [...]: Update copyright.
* alias.c, basic-block.h, c-common.c, c-common.h,
	c-cppbuiltin.c, c-opts.c, c-pragma.c, c-pretty-print.c,
	calls.c, cfg.c, cfgcleanup.c, cfgrtl.c, cgraph.h, collect2.c,
	combine.c, cppcharset.c, cpphash.h, cppinit.c, cpplib.c,
	cpplib.h, cppmacro.c, crtstuff.c, cselib.c, cselib.h,
	defaults.h, df.c, dominance.c, et-forest.c, expmed.c, expr.c,
	expr.h, fix-header.c, function.h, gcc.c, gcse.c, genattrtab.c,
	genautomata.c, genconditions.c, genemit.c, genflags.c,
	gengtype.c, gengtype.h, genopinit.c, genrecog.c, gensupport.c,
	ggc-zone.c, graph.c, haifa-sched.c, input.h, integrate.c,
	langhooks-def.h, langhooks.c, langhooks.h, line-map.c,
	line-map.h, local-alloc.c, optabs.c, optabs.h, postreload.c,
	ra.h, recog.c, reg-stack.c, regmove.c, reload.c, reorg.c,
	rtl.c, sched-deps.c, sched-ebb.c, sdbout.c, system.h,
	target.h, targhooks.c, toplev.h, tree-inline.c, unwind-pe.h,
	unwind.h, varray.c, varray.h: Update copyright.

From-SVN: r76302
2004-01-21 20:40:04 +00:00
Steven Bosscher 8c80adb754 gengtype.c (header_file): Make it static.
* gengtype.c (header_file): Make it static.
	(write_types_process_field, write_enum_defn): Minor whitespace fixes.
	* gengtype.h (header_file): No longer extern.

From-SVN: r76140
2004-01-19 08:38:38 +00:00
Andreas Jaeger 3d7aafde11 genrecog.c: Use ISO C90 prototypes.
* genrecog.c: Use ISO C90 prototypes.
	(nodes_identical): Correct declaration to match prototype.
	(maybe_both_true): Likewise.
	(merge_trees): Likewise.

	* genpeep.c (gen_peephole): Remove #if 0 code.
	Use ISO C90 prototypes.

	* genattrtab.c (copy_rtx_unchanging): Remove #if 0'ed code.
	Remove #if 0'ed function simplify_by_alternatives.
	(optimize_attrs): Remove #if 0'ed code.
	Remove ^L.
	Use ISO C90 prototypes.
	(make_canonical): Remove #if 0'ed code.
	(convert_const_symbol_ref): Remove #if 0'ed function.

	* gen-protos.c (main): Check for argument.

	* rtl.h: Use ISO C90 prototypes for functions from lists.c.

	* params.h: Use ISO C90 prototypes.
	* params.c: Likewise.
	* intl.c: Likewise.
	* intl.h: Likewise.
	* lists.c: Likewise.
	* errors.c: Likewise.
	* errors.h: Likewise.
	* gencodes.c: Likewise.
	* genpreds.c: Likewise.
	* genattr.c: Likewise.
	* gen-protos.c: Likewise.
	* genflags.c: Likewise
	* genconditions.c: Likewise.
	* genautomata.c: Likewise.
	* gencheck.c: Likewise.
	* genconfig.c: Likewise.
	* genconstants.c: Likewise.
	* genemit.c: Likewise.
	* genextract.c: Likewise.
	* gengenrtl.c: Likewise.
	* gengtype.c: Likewise.
	* gengtype.h: Likewise.
	* genopinit.c: Likewise.
	* genoutput.c: Likewise.
	* gensupport.c: Likewise.
	* gensupport.h: Likewise.

From-SVN: r67296
2003-06-01 17:59:10 +02:00
Geoffrey Keating 36a5eadd1a Index: gcc/ChangeLog
2002-09-12  Geoffrey Keating  <geoffk@apple.com>

	* ggc-common.c (ggc_mark_rtx_children_1): Update for changed name
	mangling.

	The following changes are merged from pch-branch:

	* doc/gty.texi (GTY Options): Document %a.
	* gengtype.c (do_scalar_typedef): New function.
	(process_gc_options): Handle `length' option.
	(set_gc_used_type): A pointer to an array of structures doesn't
	qualify as a pointer to a structure.
	(output_escaped_param): Add `%a' escape.
	(write_gc_structure_fields): Allow 'desc' on array of unions.
	(main): Define `uint8', `jword' and `JCF_u2' as scalars; use
	do_scalar_typedef.

	* gengtype.c (enum rtx_code): Make global.
	(rtx_format): Make global.
	(rtx_next): New.
	(gen_rtx_next): New.
	(write_rtx_next): New.
	(adjust_field_rtx_def): Skip fields marked by chain_next.
	(open_base_files): Delete redundant prototype.
	(write_enum_defn): New.
	(output_mangled_typename): Correct abort call.
	(write_gc_marker_routine_for_structure): Handle chain_next and
	chain_prev options.
	(finish_root_table): Don't output redundant \n.
	(main): Call gen_rtx_next, write_rtx_next, write_enum_defn.
	* c-tree.h (union lang_tree_node): Add chain_next option.

	* gengtype.h (NUM_PARAM): New definition.
	(struct type): For TYPE_PARAM_STRUCT, allow multiple parameters.
	* gengtype.c (find_param_structure): New.
	(adjust_field_type): Handle param<n>_is option.
	(process_gc_options): Detect use_params option.  Update callers.
	(set_gc_used_type): Add 'param' parameter, update callers.  Handle
	'use_params' option.
	(open_base_files): Add splay-tree.h to list of files included.
	(output_mangled_typename): New.
	(write_gc_structure_fields): Update 'param' parameter to support
	multiple parameters.  Change name mangling.  Allow parameterized
	fields to have an apparent scalar type.  Handle param<n>_is options,
	use_param option.
	(write_gc_marker_routine_for_structure): Update for change to name
	mangling.  Better guess the output file for parameterized types.
	(write_gc_types): Update for change to name mangling.
	(write_gc_root): Update for change to name mangling.  Handle (ignore)
	param<n>_is options.
	* doc/gty.texi (GTY Options): Add description of param<n>_is
	options, use_params option.
	* ggc.h (ggc_mark_rtx): Update for changed name mangling.
	* gengtype-lex.l: Produce token for param<n>_is.
	* gengtype-yacc.y: Parse param<n>_is.

	* gengtype.c (adjust_field_tree_exp): Don't name a variable 'rindex'.

	* rtl.c: Update comment describing rtx_format.
	* rtl.h (union rtunion): Separate definition and typedef.
	(struct rtx_def): Use gengtype to mark.
	* Makefile.in (gengtype.o): Also depend on rtl.def.
	* ggc.h (ggc_mark_rtx_children): Delete prototype.
	(ggc_mark_rtx): Change to alias of gengtype-generated routine.
	* ggc-common.c (ggc_mark_rtx_children): Delete.
	(ggc_mark_rtx_children_1): Delete.
	(gt_ggc_m_rtx_def): Delete.
	* gengtype.c (adjust_field_rtx_def): New.
	(adjust_field_type): Call adjust_field_rtx_def.
	(write_gc_structure_fields): Add 'default' case to switch if none
	is specified; remove unused code.

	* tree.h (struct tree_exp): Update for change to meaning
	of special.
	* gengtype.c (adjust_field_tree_exp): New function.
	(adjust_field_type): Handle `tree_exp' special here.
	(write_gc_structure_fields): Don't handle `tree_exp' special here.
	Handle new `dot' option.

	* gengtype.h: Make `info' a pointer-to-const.
	* gengtype-yacc.y (yacc_ids): Use xasprintf.

	* gengtype.c (write_gc_structure_fields): Remove implementation
	of `always' option, add `default' option.
	* doc/gty.texi (GTY Options): Remove documentation of `always',
	add `default'.

Index: gcc/cp/ChangeLog
2002-09-12  Geoffrey Keating  <geoffk@apple.com>

	* cp-tree.h (union lang_tree_node): Add chain_next option.

Index: gcc/f/ChangeLog
2002-09-12  Geoffrey Keating  <geoffk@apple.com>

	* com.c (union lang_tree_node): Add chain_next option.

Index: gcc/java/ChangeLog
2002-09-12  Geoffrey Keating  <geoffk@apple.com>

	* java-tree.h (union lang_tree_node): Add chain_next option.

From-SVN: r57206
2002-09-16 18:33:23 +00:00
Tim Josling 8ac9d31fd9 Make gengtype.c language independent.
From-SVN: r55436
2002-07-14 01:59:15 +00:00
Geoffrey Keating e03856fe95 gengtype.h (xvasprintf): New prototype.
* gengtype.h (xvasprintf): New prototype.
	(xasprintf): New prototype.
	(struct outf): New.
	(get_output_file): Return an outf_p.
	(header_file): Is now an outf_p.
	(base_files): Now are outf_p.
	(oprintf): New.
	* gengtype.c: Replace all output FILE * with outf_p; use oprintf
	rather than stdio operations.  Use xasprintf in a few places,
	when appropriate.
	(xvasprintf): New.
	(xasprintf): New.
	(struct filemap): Delete.
	(files): Delete.
	(output_files): New.
	(oprintf): New.
	(create_file): Create an outf_p.  Add parameter to indicate output
	file name, change all callers.
	(open_base_files): Create gtype-desc.c here.
	(get_output_file_with_visibility): Rewrite.
	(get_output_file_name): Just look at 'name' field in struct outf.
	(close_output_files): Rewrite.

From-SVN: r54566
2002-06-12 22:57:45 +00:00
Kaveh R. Ghazi 57d802974a gengtype.h (error_at_line): Use PARAMS, not VPARAMS.
* gengtype.h (error_at_line): Use PARAMS, not VPARAMS.  Add
	ATTRIBUTE_PRINTF_2.
	* gengtype-lex.l: Fix format specifier warning.

From-SVN: r54394
2002-06-09 02:40:08 +00:00
Geoffrey Keating e2500fedef Merge from pch-branch up to tag pch-commit-20020603.
From-SVN: r54232
2002-06-04 07:11:05 +00:00