Commit Graph

418 Commits

Author SHA1 Message Date
Steven Bosscher be7a421eef output.h (__gcc_host_wide_int__): Move to hwint.h.
* output.h (__gcc_host_wide_int__): Move to hwint.h.
	(decl_default_tls_model): Move to tree.h
	(dump_file): Move to system.h.
	(default_stabs_asm_out_destructor, default_stabs_asm_out_constructor,
	dbxout_int, dbxout_stabd, dbxout_begin_stabn, dbxout_begin_stabn_sline,
	dbxout_begin_empty_stabs, dbxout_begin_simple_stabs,
	dbxout_begin_simple_stabs_desc, dbxout_stab_value_zero,
	dbxout_stab_value_zero, dbxout_stab_value_label_diff,
	dbxout_stab_value_internal_label,
	dbxout_stab_value_internal_label_diff): Move from here ...
	* dbxout.h: ... to here.
	* system.h (dump_file): Moved here from output.h.
	* hwint.h (__gcc_host_wide_int__): Moved here from output.h.
	* tree.h (decl_default_tls_model): Moved here from output.h.
	* varasm.c (default_stabs_asm_out_destructor,
	default_stabs_asm_out_constructor): Move from here ...
	* dbxout.c: ... to here.

	* gcov-dump.c (dump_file): Rename to dump_gcov_file.  Update callers.

	* collect2.h (dump_file): Rename to dump_ld_file.
	* collect2.c: Likewise.
	* tlink.c: Likewise.

	* alias.c: Do not include output.h.
	* auto-inc-dec.c: Likewise.
	* bt-load.c: Likewise.
	* caller-save.c: Likewise.
	* cfg.c: Likewise.
	* cfgbuild.c: Likewise.
	* cfgcleanup.c: Likewise.
	* cfglayout.c: Likewise.
	* cfgloop.c: Likewise.
	* cfgloopanal.c: Likewise.
	* cfgloopmanip.c: Likewise.
	* cfgrtl.c: Likewise.
	* cgraph.c: Likewise.
	* cgraphclones.c: Likewise.
	* combine-stack-adj.c: Likewise.
	* combine.c: Likewise.
	* cprop.c: Likewise.
	* cse.c: Likewise.
	* cselib.c: Likewise.
	* dbgcnt.c: Likewise.
	* df-problems.c: Likewise.
	* df-scan.c: Likewise.
	* dojump.c: Likewise.
	* fwprop.c: Likewise.
	* gcse.c: Likewise.
	* graph.c: Likewise.
	* haifa-sched.c: Likewise.
	* hw-doloop.c: Likewise.
	* ipa-inline-transform.c: Likewise.
	* ipa-pure-const.c: Likewise.
	* ipa-reference.c: Likewise.
	* ipa-utils.c: Likewise.
	* ira-build.c: Likewise.
	* ira-emit.c: Likewise.
	* lcm.c: Likewise.
	* loop-doloop.c: Likewise.
	* loop-invariant.c: Likewise.
	* loop-iv.c: Likewise.
	* loop-unroll.c: Likewise.
	* loop-unswitch.c: Likewise.
	* lto-cgraph.c: Likewise.
	* lto-section-in.c: Likewise.
	* lto-streamer-in.c: Likewise.
	* mcf.c: Likewise.
	* mode-switching.c: Likewise.
	* postreload-gcse.c: Likewise.
	* postreload.c: Likewise.
	* predict.c: Likewise.
	* profile.c: Likewise.
	* ree.c: Likewise.
	* reg-stack.c: Likewise.
	* regcprop.c: Likewise.
	* regmove.c: Likewise.
	* regstat.c: Likewise.
	* reload1.c: Likewise.
	* sched-ebb.c: Likewise.
	* sel-sched-dump.c: Likewise.
	* simplify-rtx.c: Likewise.
	* stor-layout.c: Likewise.
	* store-motion.c: Likewise.
	* tracer.c: Likewise.
	* tree-affine.c: Likewise.
	* tree-cfg.c: Likewise.
	* tree-cfgcleanup.c: Likewise.
	* tree-dfa.c: Likewise.
	* tree-into-ssa.c: Likewise.
	* tree-nomudflap.c: Likewise.
	* tree-optimize.c: Likewise.
	* tree-pretty-print.c: Likewise.
	* tree-profile.c: Likewise.
	* tree-ssa-address.c: Likewise.
	* tree-ssa-ccp.c: Likewise.
	* tree-ssa-copy.c: Likewise.
	* tree-ssa-dom.c: Likewise.
	* tree-ssa-loop-ch.c: Likewise.
	* tree-ssa-loop-im.c: Likewise.
	* tree-ssa-loop-manip.c: Likewise.
	* tree-ssa-loop-niter.c: Likewise.
	* tree-ssa-loop-prefetch.c: Likewise.
	* tree-ssa-loop-unswitch.c: Likewise.
	* tree-ssa-loop.c: Likewise.
	* tree-ssa-propagate.c: Likewise.
	* tree-ssa-structalias.c: Likewise.
	* tree-ssa-tail-merge.c: Likewise.
	* tree-ssa-threadedge.c: Likewise.
	* tree-ssa-threadupdate.c: Likewise.
	* tree-ssa-uncprop.c: Likewise.
	* tree-ssa-uninit.c: Likewise.
	* tree-ssa.c: Likewise.
	* value-prof.c: Likewise.
	* var-tracking.c: Likewise.
	* web.c: Likewise.

	* config/m32r/m32r.c: Include dbxout.h.
	* config/pa/pa.c: Likewise.
	* config/rs6000/rs6000.c: Likewise.

	* Makefile.in: Fix dependencies.
	* config/rs6000/t-rs5000: Likewise.

c-family/
	* c-ada-spec.c: Do not include output.h.
	* c-semantics.c: Likewise.

cp/
	* call.c: Do not include output.h.
	* class.c: Likewise.
	* except.c: Likewise.
	* friend.c: Likewise.
	* init.c: Likewise.
	* lex.c: Likewise.
	* method.c: Likewise.
	* parser.c: Likewise.
	* pt.c: Likewise.
	* rtti.c: Likewise.
	* search.c: Likewise.

objc/
	* objc-act.c: Do not include output.h.

fortran/
	* trans-common.c: Do not include output.h.
	* trans-decl.c: Likewise.

java/
	* resource.c: Do not include output.h.

From-SVN: r188082
2012-05-31 20:19:00 +00:00
Joseph Myers 073a899888 LANGUAGES: Fix typos.
* LANGUAGES: Fix typos.
	* Makefile.in: Fix typos.
	* alias.c: Fix typos.
	* auto-inc-dec.c: Fix typos.
	* bb-reorder.c: Fix typos.
	* cfgcleanup.c: Fix typos.
	* cgraph.c: Fix typos.
	* cgraph.h: Fix typos.
	* cgraphunit.c: Fix typos.
	* collect2-aix.h: Fix typos.
	* collect2.c: Fix typos.
	* compare-elim.c: Fix typos.
	* config/alpha/vms.h: Fix typos.
	* config/arm/README-interworking: Fix typos.
	* config/arm/arm.c: Fix typos.
	* config/arm/iterators.md: Fix typos.
	* config/arm/vxworks.h: Fix typos.
	* config/avr/avr.c: Fix typos.
	* config/avr/avr.h: Fix typos.
	* config/avr/avr.md: Fix typos.
	* config/avr/builtins.def: Fix typos.
	* config/c6x/c6x.c: Fix typos.
	* config/cr16/cr16.c: Fix typos.
	* config/cr16/cr16.md: Fix typos.
	* config/cris/cris.md: Fix typos.
	* config/darwin.c: Fix typos.
	* config/darwin.opt: Fix typos.
	* config/i386/i386-c.c: Fix typos.
	* config/i386/i386.c: Fix typos.
	* config/ia64/ia64.c: Fix typos.
	* config/m68k/cf.md: Fix typos.
	* config/mep/mep.c: Fix typos.
	* config/microblaze/microblaze.c: Fix typos.
	* config/microblaze/microblaze.h: Fix typos.
	* config/mn10300/mn10300.c: Fix typos.
	* config/mn10300/mn10300.md: Fix typos.
	* config/pa/pa.c: Fix typos.
	* config/picochip/picochip.h: Fix typos.
	* config/rs6000/a2.md: Fix typos.
	* config/rs6000/rs6000.c: Fix typos.
	* config/rs6000/vector.md: Fix typos.
	* config/rx/rx.md: Fix typos.
	* config/rx/rx.opt: Fix typos.
	* config/s390/2097.md: Fix typos.
	* config/s390/s390.c: Fix typos.
	* config/s390/s390.h: Fix typos.
	* config/sh/sh.c: Fix typos.
	* config/sh/sh.md: Fix typos.
	* config/sparc/sync.md: Fix typos.
	* config/spu/spu.c: Fix typos.
	* config/spu/spu.md: Fix typos.
	* config/vms/vms.c: Fix typos.
	* config/vxworks-dummy.h: Fix typos.
	* config/vxworks.h: Fix typos.
	* cselib.c: Fix typos.
	* df-scan.c: Fix typos.
	* df.h: Fix typos.
	* doc/extend.texi: Fix typos.
	* doc/install.texi: Fix typos.
	* doc/invoke.texi: Fix typos.
	* doc/md.texi: Fix typos.
	* doc/plugins.texi: Fix typos.
	* doc/rtl.texi: Fix typos.
	* dse.c: Fix typos.
	* dwarf2asm.c: Fix typos.
	* dwarf2out.c: Fix typos.
	* except.h: Fix typos.
	* expr.c: Fix typos.
	* fold-const.c: Fix typos.
	* gcc.c: Fix typos.
	* gcse.c: Fix typos.
	* genautomata.c: Fix typos.
	* gengtype-state.c: Fix typos.
	* gengtype.c: Fix typos.
	* genhooks.c: Fix typos.
	* gimple-fold.c: Fix typos.
	* gimple-pretty-print.c: Fix typos.
	* gimple.c: Fix typos.
	* gimple.h: Fix typos.
	* gimplify.c: Fix typos.
	* graphite-interchange.c: Fix typos.
	* graphite-sese-to-poly.c: Fix typos.
	* ifcvt.c: Fix typos.
	* input.c: Fix typos.
	* ipa-cp.c: Fix typos.
	* ipa-inline-analysis.c: Fix typos.
	* ipa-inline-transform.c: Fix typos.
	* ipa-inline.c: Fix typos.
	* ipa-pure-const.c: Fix typos.
	* ipa-ref.h: Fix typos.
	* ipa-reference.c: Fix typos.
	* ipa-utils.c: Fix typos.
	* ipa.c: Fix typos.
	* ira-emit.c: Fix typos.
	* ira-lives.c: Fix typos.
	* lto-streamer.c: Fix typos.
	* lto-streamer.h: Fix typos.
	* lto-wrapper.c: Fix typos.
	* mcf.c: Fix typos.
	* mode-switching.c: Fix typos.
	* modulo-sched.c: Fix typos.
	* plugin.c: Fix typos.
	* postreload.c: Fix typos.
	* sched-deps.c: Fix typos.
	* sel-sched-ir.c: Fix typos.
	* sel-sched-ir.h: Fix typos.
	* sel-sched.c: Fix typos.
	* sese.c: Fix typos.
	* stor-layout.c: Fix typos.
	* target-hooks-macros.h: Fix typos.
	* target.def: Fix typos.
	* trans-mem.c: Fix typos.
	* tree-eh.c: Fix typos.
	* tree-predcom.c: Fix typos.
	* tree-sra.c: Fix typos.
	* tree-ssa-address.c: Fix typos.
	* tree-ssa-loop-ivopts.c: Fix typos.
	* tree-ssa-loop-niter.c: Fix typos.
	* tree-ssa-math-opts.c: Fix typos.
	* tree-ssa-pre.c: Fix typos.
	* tree-ssa-propagate.c: Fix typos.
	* tree-ssa-reassoc.c: Fix typos.
	* tree-ssa-sccvn.c: Fix typos.
	* tree-ssa-ter.c: Fix typos.
	* tree-ssa-uninit.c: Fix typos.
	* tree-ssanames.c: Fix typos.
	* tree-vect-generic.c: Fix typos.
	* tree-vect-slp.c: Fix typos.
	* tree.c: Fix typos.
	* tree.h: Fix typos.
	* varasm.c: Fix typos.
	* varpool.c: Fix typos.

From-SVN: r187959
2012-05-29 15:14:06 +01:00
Eric Botcazou 9cbbba287d stor-layout.c (bit_from_pos): Distribute conversion to bitsizetype into a PLUS_EXPR byte offset.
* stor-layout.c (bit_from_pos): Distribute conversion to bitsizetype
	into a PLUS_EXPR byte offset.

	* tree-ssa-pre.c (can_value_number_call): Delete.
	(compute_avail): Skip all statements with side effects.
	<GIMPLE_CALL>: Skip calls to internal functions.

From-SVN: r187450
2012-05-14 08:46:33 +00:00
Richard Guenther 8244f25237 stor-layout.c (byte_from_pos): Amend comment.
2012-05-10  Richard Guenther  <rguenther@suse.de>

	* stor-layout.c (byte_from_pos): Amend comment.

From-SVN: r187367
2012-05-10 10:28:31 +00:00
Richard Guenther 3ac8781c36 cuintp.c (UI_From_gnu): Remove TYPE_IS_SIZETYPE use.
2012-05-10  Richard Guenther  <rguenther@suse.de>

	ada/
	* gcc-interface/cuintp.c (UI_From_gnu): Remove TYPE_IS_SIZETYPE use.

	c-family/
	* c-common.c (c_sizeof_or_alignof_type): Remove assert and
	adjust commentary about TYPE_IS_SIZETYPE types.

	* tree.h (TYPE_IS_SIZETYPE): Remove.
	* fold-const.c (int_const_binop_1): Remove TYPE_IS_SIZETYPE use.
	(extract_muldiv_1): Likewise.
	* gimple.c (gtc_visit): Likewise.
	(gimple_types_compatible_p): Likewise.
	(iterative_hash_canonical_type): Likewise.
	(gimple_canonical_types_compatible_p): Likewise.
	* gimplify.c (gimplify_one_sizepos): Likewise.
	* print-tree.c (print_node): Likewise.
	* stor-layout.c (initialize_sizetypes): Do not set TYPE_IS_SIZETYPE.

From-SVN: r187363
2012-05-10 07:58:27 +00:00
Richard Guenther 2af273018e stor-layout.c (bit_from_pos): Document.
2012-05-09  Richard Guenther  <rguenther@suse.de>

	* stor-layout.c (bit_from_pos): Document.
	(byte_from_pos): Likewise.  Optimize.
	(pos_from_bit): Likewise.
	(normalize_offset): Use pos_from_bit instead of replicating it.

From-SVN: r187317
2012-05-09 08:56:25 +00:00
Richard Guenther 56099f00a5 tree.c (valid_constant_size_p): New function.
2012-05-02  Richard Guenther  <rguenther@suse.de>

	* tree.c (valid_constant_size_p): New function.
	* tree.h (valid_constant_size_p): Declare.
	* cfgexpand.c (expand_one_var): Adjust check for too large
	variables by using valid_constant_size_p.
	* varasm.c (assemble_variable): Likewise.

	c/
	* c-decl.c (grokdeclarator): Properly check for sizes that
	cover more than half of the address-space.

	cp/
	* decl.c (grokdeclarator): Properly check for sizes that
	cover more than half of the address-space.

2012-05-02  Richard Guenther  <rguenther@suse.de>

	* fold-const.c (div_if_zero_remainder): sizetypes no longer
	sign-extend.
	(int_const_binop_1): New worker for int_const_binop with
	overflowable parameter.  Pass it through
	to force_fit_type_double.
	(int_const_binop): Wrap around int_const_binop_1 with overflowable
	equal to one.
	(size_binop_loc): Call int_const_binop_1 with overflowable equal
	to minus one, forcing overflow detection for even unsigned types.
	(extract_muldiv_1): Remove bogus TYPE_IS_SIZETYPE special-casing.
	(fold_binary_loc): Call try_move_mult_to_index with signed offset.
	* stor-layout.c (initialize_sizetypes): sizetypes no longer
	sign-extend.
	(layout_type): For zero-sized arrays ignore overflow on the
	size calculations.
	* tree-ssa-ccp.c (bit_value_unop_1): Likewise.
	(bit_value_binop_1): Likewise.
	* tree.c (double_int_to_tree): Likewise.
	(double_int_fits_to_tree_p): Likewise.
	(force_fit_type_double): Likewise.
	(host_integerp): Likewise.
	(int_fits_type_p): Likewise.
	* varasm.c (output_constructor_regular_field): Sign-extend the
	field-offset to cater for negative offsets produced by the Ada frontend.
	* omp-low.c (extract_omp_for_data): Convert the loop step to
	signed for pointer adjustments.

	* g++.dg/tree-ssa/pr19807.C: Adjust.

From-SVN: r187042
2012-05-02 11:22:31 +00:00
Jakub Jelinek f1cc958978 re PR tree-optimization/52979 (likely wrong code bug w/packed bitfields)
PR middle-end/52979
	* stor-layout.c (get_best_mode): Don't return mode with bitsize
	larger than maxbits.  Don't compute maxbits modulo align.
	Also check that unit bytes long store at bitpos / unit * unit
	doesn't affect bits beyond bitregion_end.
	* expmed.c (store_bit_field_1): Avoid trying insv if OP_MODE MEM
	would not fit into bitregion_start ... bitregion_end + 1 bit
	region.
	(store_split_bit_field): Decrease unit close to end of bitregion_end
	if access is restricted in order to avoid mutual recursion.

	* gcc.c-torture/compile/pr52979-1.c: New test.
	* gcc.c-torture/execute/pr52979-1.c: New test.
	* gcc.c-torture/execute/pr52979-2.c: New test.

From-SVN: r186819
2012-04-25 16:27:08 +02:00
Richard Guenther 7ebf9677e5 stor-layout.c (finish_bitfield_representative): Fallback to conservative maximum size if the padding up to the next field...
2012-03-20  Richard Guenther  <rguenther@suse.de>

	* stor-layout.c (finish_bitfield_representative): Fallback
	to conservative maximum size if the padding up to the next
	field cannot be computed as a constant.
	(finish_bitfield_layout): If we cannot compute the distance
	between the start of the bitfield representative and the
	bitfield member start a new representative.
	* expr.c (get_bit_range): The distance between the start of
	the bitfield representative and the bitfield member is zero
	if the field offsets are not constants.

	* gnat.dg/pack16.adb: New testcase.
	* gnat.dg/pack16_pkg.ads: Likewise.
	* gnat.dg/specs/pack8.ads: Likewise.
	* gnat.dg/specs/pack8_pkg.ads: Likewise.

From-SVN: r185563
2012-03-20 09:31:40 +00:00
Tristan Gingold 18dae0162f tree.h (enum size_type_kind): Add stk_ prefix to constants, convert in lowercase.
2012-03-20  Tristan Gingold  <gingold@adacore.com>

	* tree.h (enum size_type_kind): Add stk_ prefix to constants,
	convert in lowercase.
	(sizetype_tab, sizetype, bitsizetype, ssizetype, sbitsizetype)
	(size_int, ssize_int, bitsize_int, sbitsize_int): Adjust.
	* stor-layout.c (sizetype_tab): Adjust.
	(initialize_sizetypes): Use SIZETYPE instead of SIZE_TYPE.
	* tree-streamer.c (preload_common_nodes): Use stk_type_kind_last
	instead of type_kind_last.
	* tree-scalar-evolution.c (interpret_rhs_expr): Use size_int
	instead of size_int_kind.
	* doc/tm.texi.in (Type Layout): Document SIZETYPE.
	* doc/tm.texi: Regenerate.
	* defaults.h (SIZETYPE): Provide a default value.
	* config/vms/vms.h (SIZE_TYPE): Define as "unsigned int".
	(SIZETYPE): Define.

From-SVN: r185561
2012-03-20 08:47:27 +00:00
Richard Guenther 2447776cc9 stor-layout.c (finish_bitfield_representative): Fall back to the conservative maximum size if...
2012-03-16  Richard Guenther  <rguenther@suse.de>

	* stor-layout.c (finish_bitfield_representative): Fall back
	to the conservative maximum size if we cannot compute the
	size of the tail padding.

	* gnat.dg/specs/pack7.ads: New testcase.

From-SVN: r185464
2012-03-16 11:47:26 +00:00
Richard Guenther 26c71b9368 re PR target/52080 (Stores to bitfields introduce a store-data-race on adjacent data)
2012-03-14  Richard Guenther  <rguenther@suse.de>

	* tree.h (DECL_BIT_FIELD_REPRESENTATIVE): New define.
	* stor-layout.c (start_bitfield_representative): New function.
	(finish_bitfield_representative): Likewise.
	(finish_bitfield_layout): Likewise.
	(finish_record_layout): Call finish_bitfield_layout.
	* tree.c (free_lang_data_in_decl): Only free DECL_QUALIFIER
	for QUAL_UNION_TYPE fields.
	* tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
	Stream DECL_BIT_FIELD_REPRESENTATIVE.
	* tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.

	PR middle-end/52080
	PR middle-end/52097
	PR middle-end/48124
	* expr.c (get_bit_range): Unconditionally extract bitrange
	from DECL_BIT_FIELD_REPRESENTATIVE.
	(expand_assignment): Adjust call to get_bit_range.

	* gcc.dg/torture/pr48124-1.c: New testcase.
	* gcc.dg/torture/pr48124-2.c: Likewise.
	* gcc.dg/torture/pr48124-3.c: Likewise.
	* gcc.dg/torture/pr48124-4.c: Likewise.

From-SVN: r185379
2012-03-14 10:55:09 +00:00
Kai Tietz 9954e17f70 re PR target/52238 (-mms-bitfields: __attribute__ ((aligned (n))) ignored for struct members)
PR target/52238
	* stor-layout.c (place_field): Handle desired_align for
	ms-bitfields, too.

	* gcc.dg/bf-ms-layout-3.c: New testcase.

From-SVN: r184409
2012-02-20 23:05:08 +01:00
Bernd Schmidt 36acc1a242 expr.c (store_field): Avoid a direct store if the mode is larger than the size of the bit field.
gcc/
	* expr.c (store_field): Avoid a direct store if the mode is larger
	than the size of the bit field.
	* stor-layout.c (layout_decl): If flag_strict_volatile_bitfields,
	treat non-volatile bit fields like volatile ones.
	* toplev.c (process_options): Disallow combination of
	-fstrict-volatile-bitfields and ABI versions less than 2.
	* config/arm/arm.c (arm_option_override): Don't enable
	flag_strict_volatile_bitfields if the ABI version is less than 2.
	* config/h8300/h8300.c (h8300_option_override): Likewise.
	* config/rx/rx.c (rx_option_override): Likewise.
	* config/m32c/m32c.c (m32c_option_override): Likewise.
	* config/sh/sh.c (sh_option_override): Likewise.

	gcc/testsuite/
	* gcc.target/arm/volatile-bitfields-4.c: New test.
	* c-c++-common/abi-bf.c: New test.

From-SVN: r182545
2011-12-20 16:46:22 +00:00
Richard Guenther 830c740f17 stor-layout.c (layout_type): Use size_binop for array size calculations.
2011-09-05  Richard Guenther  <rguenther@suse.de>

	* stor-layout.c (layout_type): Use size_binop for array size
	calculations.

	c-family/
	* c-common.c (complete_array_type): Use ssize_int (-1) instead
	of integer_minus_one_node for empty array upper bounds.

From-SVN: r178526
2011-09-05 09:03:08 +00:00
Jakub Jelinek f44157f84b re PR target/50009 (Segmentation fault in tree_nop_conversion)
PR target/50009
	* stor-layout.c (update_alignment_for_field): Don't ICE on
	packed flexible array members if ms_bitfield_layout_p.

	* gcc.c-torture/compile/pr50009.c: New test.

From-SVN: r177860
2011-08-18 16:29:10 +02:00
Richard Guenther e62a2b6e5c stor-layout.c (initialize_sizetypes): Properly sign-extend bitsiztype TYPE_MAX_VALUE.
2011-08-01  Richard Guenther  <rguenther@suse.de>

	* stor-layout.c (initialize_sizetypes): Properly sign-extend
	bitsiztype TYPE_MAX_VALUE.

From-SVN: r177016
2011-08-01 11:51:04 +00:00
Richard Henderson b87ac61522 Handle SIZE_TYPE being unsigned short.
From-SVN: r176995
2011-07-31 18:11:04 -07:00
Aldy Hernandez 1169e45d27 params.h (ALLOW_STORE_DATA_RACES): New.
* params.h (ALLOW_STORE_DATA_RACES): New.
	* params.def (PARAM_ALLOW_STORE_DATA_RACES): New.
	* Makefile.in (expr.o): Depend on PARAMS_H.
	* machmode.h (get_best_mode): Add argument.
	* fold-const.c (optimize_bit_field_compare): Add argument to
	get_best_mode.
	(fold_truthop): Same.
	* ifcvt.c (noce_emit_move_insn): Add argument to store_bit_field.
	* expr.c (emit_group_store): Same.
	(copy_blkmode_from_reg): Same.
	(write_complex_part): Same.
	(optimize_bitfield_assignment_op): Add argument.
	Add argument to get_best_mode.
	(get_bit_range): New.
	(expand_assignment): Calculate maxbits and pass it down
	accordingly.
	(store_field): New argument.
	(expand_expr_real_2): New argument to store_field.
	Include params.h.
	* expr.h (store_bit_field): New argument.
	* stor-layout.c (get_best_mode): Restrict mode expansion by taking
	into account maxbits.
	* calls.c (store_unaligned_arguments_into_pseudos): New argument
	to store_bit_field.
	* expmed.c (store_bit_field_1): New argument.  Use it.
	(store_bit_field): Same.
	(store_fixed_bit_field): Same.
	(store_split_bit_field): Same.
	(extract_bit_field_1): Pass new argument to get_best_mode.
	(extract_bit_field): Same.
	* stmt.c (store_bit_field): Pass new argument to store_bit_field.
	* doc/invoke.texi: Document parameter allow-store-data-races.

From-SVN: r176824
2011-07-27 13:22:09 +00:00
Bernd Schmidt 0d44736e75 optabs.c (expand_binop): Tighten conditions for doubleword expansions.
* optabs.c (expand_binop): Tighten conditions for doubleword
	expansions.
	(widen_bswap): Assert that mode bitsize and precision are the
	same.
	* stor-layout.c (get_best_mode): Skip modes that have lower
	precision than bitsize.
	* recog.c (simplify_while_replacing): Assert that bitsize and
	precision are the same.

From-SVN: r176040
2011-07-08 13:03:38 +00:00
Richard Guenther f93fe5a0e6 stor-layout.c (initialize_sizetypes): Give names to all sizetype kinds.
2011-06-10  Richard Guenther  <rguenther@suse.de>

	* stor-layout.c (initialize_sizetypes): Give names to all
	sizetype kinds.

From-SVN: r174893
2011-06-10 08:38:40 +00:00
Richard Guenther 67b884536d stor-layout.c (initialize_sizetypes): Initialize all sizetypes based on target definitions.
2011-06-07  Richard Guenther  <rguenther@suse.de>

	* stor-layout.c (initialize_sizetypes): Initialize all
	sizetypes based on target definitions.
	(set_sizetype): Remove.
	* tree.c (build_common_tree_nodes): Do not call set_sizetype.
	* tree.h (set_sizetype): Remove.

From-SVN: r174748
2011-06-07 14:37:39 +00:00
Nathan Froyd 515456820e split tree_type
split tree_type
gcc/ada/
	* gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
	(TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
	(TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.

gcc/cp/
	* cp-tree.h (TYPENAME_TYPE_FULLNAME, TYPEOF_TYPE_EXPR): Use
	TYPE_VALUES_RAW.
	(UNDERLYING_TYPE_TYPE, DECLTYPE_TYPE_EXPR): Likewise.
	(DECLTYPE_TYPE_ID_EXPR_OR_MEMBER_ACCESS_P): Likewise.
	(TEMPLATE_TYPE_PARM_INDEX): Likewise.

gcc/
	* ggc-page.c (extra_order_size_table): Use struct
	tree_type_non_common.
	* lto-streamer-in.c (unpack_ts_type_value_fields): Rename to...
	(unpack_ts_type_common_value_fields): ...this.  Update comment.
	(unpack_value_fields): Adjust for renaming.
	(lto_input_ts_type_tree_pointers): Split into...
	(lto_input_ts_type_common_tree_pointer): ...this and...
	(lto_input_ts_type_non_common_tree_pointers): ...this.
	(lto_input_tree_pointers): Adjust for above split.
	* lto-streamer-out.c (pack_ts_type_value_fields): Rename to...
	(pack_ts_type_common_value_fields): ...this.  Update comment.
	(lto_output_ts_type_tree_pointers): Split into...
	(lto_output_ts_type_common_tree_pointers): ...this and...
	(lto_output_ts_type_non_common_tree_pointers): ...this.
	(lto_output_tree_pointers): Adjust for above split.
	* lto-streamer.c (check_handled_ts_structures): Mark TS_TYPE_COMMON,
	TS_TYPE_WITH_LANG_SPECIFIC, and TS_TYPE_NON_COMMON as handled.
	* stor-layout.c (vector_type_mode): Adjust location of mode field.
	* tree.h (MARK_TS_TYPE_COMMON, MARK_TS_TYPE_WITH_LANG_SPECIFIC):
	Define.
	(struct tree_type): Split into...
	(struct tree_type_common: ...this and...
	(struct tree_type_with_lang_specific): ...this and...
	(struct tree_type_non_common): ...this.  Adjust accessor macros
	accordingly.
	(TYPE_VALUES_RAW): Define.
	(union tree_node): Update for above changes.
	* tree.c (tree_node_structure_for_code) [tcc_type]: Return
	TS_TYPE_NON_COMMON.
	(initialize_tree_contains_struct) [TS_TYPE]: Use TS_TYPE_COMMON.
	Add TS_TYPE_WITH_LANG_SPECIFIC and TS_TYPE_NON_COMMON.
	(tree_code_size) [tcc_type]: Use struct tree_type_non_common.
	* treestructu.def (TS_TYPE): Remove.
	(TS_TYPE_COMMON, TS_TYPE_WITH_LANG_SPECIFIC, TS_TYPE_NON_COMMON):
	Define.

gcc/java/
	* java-tree.h (TYPE_ARGUMENT_SIGNATURE): Use TYPE_MINVAL.

gcc/lto/
	* lto.c (lto_ft_type): Use TYPE_MINVAL and TYPE_MAXVAL.  Adjust
	location of binfo field.
	(lto_fixup_prevailing_decls): Likewise.

gcc/objc/
	* objc-act.h (CLASS_NAME, CLASS_SUPER_NAME): Use proper accessors.
	(CLASS_NST_METHODS, CLASS_CLS_METHODS): Likewise.
	(PROTOCOL_NAME, PROTOCOL_NST_METHODS, PROTOCOL_CLS_METHODS): Likewise.

From-SVN: r173658
2011-05-11 13:48:55 +00:00
Eric Botcazou c99c002630 langhooks.h (lang_hooks_for_types): Change global_bindings_p's return type to bool and adjust comment.
2011-05-07  Eric Botcazou  <ebotcazou@adacore.com>

	* langhooks.h (lang_hooks_for_types): Change global_bindings_p's return
	type to bool and adjust comment.
	* fold-const.c (fold_range_test): Adjust call to global_bindings_p.
	(fold_mathfn_compare): Remove calls to global_bindings_p.
	(fold_inf_compare): Likewise.
	* stor-layout.c (variable_size): Adjust call to global_bindings_p.
	* c-tree.h (global_bindings_p): Adjust prototype.
	* c-decl.c (global_bindings_p): Return bool and simplify.
ada/
	* gcc-interface/gigi.h (global_bindings_p): Adjust prototype.
	* gcc-interface/utils.c (global_bindings_p): Return bool and simplify.
cp/
	* name-lookup.h (global_bindings_p): Adjust prototype.
	* name-lookup.c (global_bindings_p): Return bool.
fortran/
	* f95-lang.c (global_bindings_p): Return bool and simplify.
go/
	* go-lang.c (global_bindings_p): Return bool and simplify.
java/
	* java-tree.h (global_bindings_p): Adjust prototype.
	* decl.c (global_bindings_p): Return bool.
lto/
	* lto-lang.c (global_bindings_p): Return bool.

From-SVN: r173535
2011-05-07 19:58:29 +00:00
Jason Merrill deb5046baa re PR c++/40975 (ICE in copy_tree_r on array new)
PR c++/40975
	* tree-inline.c (copy_tree_r): Use copy_statement_list.
	(copy_statement_list): Don't recurse.
	* stor-layout.c (copy_self_referential_tree_r): Don't allow
	STATEMENT_LIST.

From-SVN: r173451
2011-05-05 16:50:57 -04:00
Eric Botcazou 907a08d9b1 tree.h (get_pending_sizes): Remove prototype.
* tree.h (get_pending_sizes): Remove prototype.
	(put_pending_size): Likewise.
	(put_pending_sizes): Likewise.
	* stor-layout.c (pending_sizes): Delete.
	(get_pending_sizes): Likewise.
	(put_pending_size): Likewise.
	(put_pending_sizes): Likewise.
	(variable_size): Do not call put_pending_size and tidy up.
	* function.h (struct function): Remove dont_save_pending_sizes_p.
	* lto-streamer-in.c (input_function): Do not stream it.
	* lto-streamer-out.c (output_function): Likewise.
	* tree-inline.c (initialize_cfun): Do not copy it.
	* c-decl.c (store_parm_decls): Do not set it.
	* omp-low.c (create_task_copyfn): Likewise.
	* tree-optimize.c (tree_rest_of_compilation): Likewise.
cp/
	* decl.c (start_preparsed_function): Likewise.
fortran/
	* trans-decl.c (trans_function_start): Likewise.
ada/
	* gcc-interface/utils.c (begin_subprog_body): Do not call
	get_pending_sizes.
	(end_subprog_body): Likewise.

From-SVN: r173424
2011-05-05 11:49:05 +00:00
Eric Botcazou a2d4293158 * stor-layout.c (variable_size): Do not issue errors.
From-SVN: r173381
2011-05-04 16:48:18 +00:00
Richard Guenther d35936ab70 tree.h (int_const_binop): Remove notrunc argument.
2011-05-04  Richard Guenther  <rguenther@suse.de>

	* tree.h (int_const_binop): Remove notrunc argument.
	* fold-const.c (int_const_binop): Remove notrunc argument.  Always
	create integer constants that are properly truncated.
	(extract_muldiv_1): Expand one notrunc int_const_binop caller.
	(const_binop): Remove zero notrunc argument to int_const_binop.
	(size_binop_loc): Likewise.
	(fold_div_compare): Likewise.
	(maybe_canonicalize_comparison_1): Likewise.
	(fold_comparison): Likewise.
	(fold_binary_loc): Likewise.
	(multiple_of_p): Likewise.
	* expr.c (store_constructor): Likewise.
	* gimple-fold.c (maybe_fold_offset_to_array_ref): Likewise.
	(maybe_fold_stmt_addition): Likewise.
	* ipa-prop.c (ipa_modify_call_arguments): Likewise.
	* stor-layout.c (layout_type): Likewise.
	* tree-data-ref.c (tree_fold_divides_p): Likewise.
	* tree-sra.c (build_ref_for_offset): Likewise.
	(build_user_friendly_ref_for_offset): Likewise.
	* tree-ssa-address.c (maybe_fold_tmr): Likewise.
	* tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Likewise.
	* tree-ssa-loop-niter.c (inverse): Likewise.
	* tree-ssa-pre.c (create_component_ref_by_pieces_1): Likewise.
	* tree-ssa.c (maybe_rewrite_mem_ref_base): Likewise.
	* tree-switch-conversion.c (check_range): Likewise.
	(build_constructors): Likewise.
	* tree-vect-generic.c (expand_vector_piecewise): Likewise.
	* tree-vrp.c (set_and_canonicalize_value_range): Likewise.
	(extract_range_from_assert): Likewise.
	(vrp_int_const_binop): Likewise.
	(extract_range_from_binary_expr): Likewise.
	(extract_range_from_unary_expr): Likewise.
	(check_array_ref): Likewise.
	(find_case_label_range): Likewise.
	(simplify_div_or_mod_using_ranges): Likewise.
	* tree-cfg.c (group_case_labels_stmt): Use double-ints for
	comparing case labels for merging.


	ada/
	* gcc-interface/trans.c (gnat_to_gnu): Remove zero notrunc argument to
	int_const_binop.
	(pos_to_constructor): Likewise.

	fortran/
	* trans-types.c (gfc_get_array_type_bounds): Remove zero notrunc
	argument to int_const_binop.

From-SVN: r173356
2011-05-04 09:04:53 +00:00
Richard Sandiford 0f6d54f720 hooks.h (hook_bool_mode_uhwi_false): Declare.
gcc/
	* hooks.h (hook_bool_mode_uhwi_false): Declare.
	* hooks.c (hook_bool_mode_uhwi_false): New function.
	* target.def (array_mode_supported_p): New hook.
	* doc/tm.texi.in (TARGET_ARRAY_MODE_SUPPORTED_P): Add @hook.
	* doc/tm.texi: Regenerate.
	* stor-layout.c (mode_for_array): New function.
	(layout_type): Use it.
	* config/arm/arm.c (arm_array_mode_supported_p): New function.
	(TARGET_ARRAY_MODE_SUPPORTED_P): Define.

From-SVN: r173290
2011-05-03 07:46:10 +00:00
Richard Guenther e6313a7840 stor-layout.c (layout_type): Compute all array index size operations in the original type.
2011-04-11  Richard Guenther  <rguenther@suse.de>

	* stor-layout.c (layout_type): Compute all array index size operations
	in the original type.
	(initialize_sizetypes): Add comment.
	(set_sizetype): Do not set TREE_TYPE of a TREE_VEC.

	c-family/
	* c-common.c (complete_array_type): Build a range type of
	proper type.

From-SVN: r172261
2011-04-11 15:47:30 +00:00
Eric Botcazou c5911a55ec * stor-layout.c (self_referential_size): Fix 2010-07-13 commit.
From-SVN: r171988
2011-04-05 14:34:28 +00:00
Jason Merrill 18d920539d re PR c++/48029 (ICE in finish_member_declaration() with --param ggc-min-expand=0 --param ggc-min-heapsize=0)
PR c++/48029
	* stor-layout.c (layout_type): Don't set structural equality
	on arrays of incomplete type.
	* tree.c (type_hash_eq): Handle comparing them properly.
	* cp/pt.c (iterative_hash_template_arg): Remove special case for
	ARRAY_TYPE.

From-SVN: r170853
2011-03-10 17:37:22 -05:00
Joseph Myers c59ffc4195 hwint.c: New.
* hwint.c:  New.  Extracted from toplev.c.
	* hwint.h (clz_hwi, ctz_hwi, ffs_hwi, exact_log2, floor_log2):
	Move from toplev.h.
	* toplev.c (clz_hwi, ctz_hwi, ffs_hwi, exact_log2, floor_log2):
	Move to hwint.c.
	* toplev.h (clz_hwi, ctz_hwi, ffs_hwi, exact_log2, floor_log2):
	Move to hwint.h.
	* builtins.c, combine.c, config/i386/winnt.c, double-int.c,
	explow.c, expmed.c, fold-const.c, ggc-page.c, ggc-zone.c, ifcvt.c,
	ipa-struct-reorg.c, ira-color.c, matrix-reorg.c, omp-low.c,
	real.c, recog.c, reload.c, rtlanal.c, simplify-rtx.c,
	stor-layout.c, tree-dfa.c, tree-ssa-alias.c,
	tree-ssa-loop-niter.c, tree-vect-data-refs.c,
	tree-vect-loop-manip.c, tree-vect-loop.c, tree-vect-stmts.c,
	tree-vrp.c: Don't include toplev.h.
	* genattrtab.c, genconditions.c, genemit.c, genextract.c,
	genoutput.c, genpeep.c, genpreds.c, genrecog.c: Don't include
	toplev.h in generated output.
	* Makefile.in (OBJS-common): Add hwint.o.
	Dependencies for above files changed to remove toplev.h.
	(hwint.o): New.
	(insn-attrtab.o, insn-emit.o, insn-extract.o, insn-output.o,
	insn-peep.o, insn-preds.o, insn-recog.o): Don't depend on
	toplev.h.
	* config/i386/t-cygming (winnt.o): Don't depend on toplev.h.
	* config/i386/t-interix (winnt.o): Don't depend on toplev.h.

fortran:
	* trans-common.c: Don't include toplev.h.

java:
	* boehm.c: Don't include toplev.h.
	* Make-lang.in (java/boehm.o): Don't depend on toplev.h.

lto:
	* lto-object.c: Don't include toplev.h.
	* Make-lang.in (lto/lto-object.o): Don't depend on toplev.h.

From-SVN: r167301
2010-11-30 16:36:19 +00:00
Joseph Myers 299404a1ec common.opt (initial_max_fld_align, [...]): New Variable entries.
* common.opt (initial_max_fld_align, flag_debug_asm,
	flag_dump_rtl_in_asm, flag_dump_all_passed, rtl_dump_and_exit,
	flag_print_asm_name, graph_dump_format, help_printed,
	help_columns, flag_opts_finished): New Variable entries.
	(fdbg-cnt-list, fdbg-cnt=, fdebug-prefix-map=, frandom-seed,
	frandom-seed=): Mark deferred.
	(fsched-verbose=): Use UInteger and Var.
	* flags.h (set_struct_debug_option, flag_print_asm_name,
	rtl_dump_and_exit, flag_debug_asm, flag_dump_rtl_in_asm,
	graph_dump_format): Don't declare here.
	* haifa-sched.c (sched_verbose_param, fix_sched_param): Remove.
	* opts-global.c: Include dbgcnt.h and debug.h.
	(decode_options): Pass location to finish_options.
	(handle_common_deferred_options): Check flag_dump_all_passed.
	Handle OPT_fdbg_cnt_, OPT_fdbg_cnt_list, OPT_fdebug_prefix_map_,
	OPT_frandom_seed and OPT_frandom_seed_.  Don't assert on
	OPT_fstack_limit.
	* opts.c: Don't include toplev.h, dbgcnt.h or debug.h.
	(set_struct_debug_option): Add location_t parameter.  Update
	recursive call.  Use error_at.
	(default_options_optimization): Use error_at.
	(finish_options): Add location_t parameter.  Use
	opts->x_flag_opts_finished instead of first_time_p.  Use
	opts->x_optimize instead of optimize.  Use error_at.  Pass
	location to inform.
	(print_filtered_help): Use opts->x_help_printed to track what
	options have been printed.
	(print_specific_help): Use opts->x_help_columns to track number of
	columns.
	(common_handle_option): Pass locations and gcc_options pointers to
	more functions.  Use warning_at instead of fnotice and warning.
	Don't handle OPT_fdbg_cnt_, OPT_fdbg_cnt_list or
	OPT_fdebug_prefix_map_.  Use error_at.  Set
	opts->x_initial_max_fld_align; don't set maximum_field_alignment.
	Don't handle OPT_frandom_seed or OPT_frandom_seed_.  Don't handle
	OPT_fsched_verbose_.
	(handle_param): Add location_r parameter.  Use error_at.
	(set_debug_level): Add location_r parameter.  Use error_at and
	warning_at.
	(setup_core_dumping): Add diagnostic_context parameter.
	(decode_d_option): Add gcc_options, location_t and
	diagnostic_context parameters and use them instead of global
	state.  Use warning_at.
	(enable_warning_as_error): Use error_at.
	* opts.h (finish_options): Update prototype.
	(set_struct_debug_option): Declare here.
	* rtl.h (fix_sched_param): Remove.
	* stor-layout.c (initial_max_fld_align): Remove.
	* toplev.c (rtl_dump_and_exit, flag_print_asm_name,
	graph_dump_format, flag_debug_asm, flag_dump_rtl_in_asm): Remove.
	(process_options): Set maximum_field_alignment.
	* tree.h (initial_max_fld_align) Don't declare here.
	* Makefile.in (opts.o, opts-global.o): Update dependencies.

c-family:
	* c-opts.c (c_common_handle_option): Pass location to
	set_struct_debug_option.

testsuite:
	* gcc.dg/opts-5.c: New test.

From-SVN: r167106
2010-11-24 00:54:26 +00:00
Eric Botcazou 985c87c94e stor-layout.c (place_union_field): Do not put location information on offset expressions.
* stor-layout.c (place_union_field): Do not put location information
	on offset expressions.
	(place_field): Likewise.
	(finalize_record_size): Likewise on size expressions.
	(finalize_type_size): Likewise.
	(layout_type): Likewise.

From-SVN: r166721
2010-11-13 22:38:04 +00:00
Joseph Myers d8a07487de cfgloop.c (verify_loop_structure): Use %' in diagnostics.
* cfgloop.c (verify_loop_structure): Use %' in diagnostics.  Start
	diagnostics with lowercase letters.
	* cgraphunit.c (verify_cgraph_node): Start diagnostics with
	lowercase letters.
	* collect2.c (maybe_run_lto_and_relink): Remove trailing '.' from
	diagnostic.
	* config/alpha/freebsd.h (LINK_SPEC): Avoid '`' in diagnostic.
	* config/arm/arm.c (arm_get_pcs_model): Start diagnostics with
	lowercase letters.
	* config/arm/freebsd.h (LINK_SPEC): Avoid '`' in diagnostic.
	Remove trailing ' ' from diagnostic.
	* config/avr/avr.c (print_operand_address): Start diagnostic with
	a lowercase letter and remove trailing '.'.
	* config/avr/avr.opt (mpmem-wrap-around): Fix typo in help text.
	* config/bfin/bfin.c (bfin_option_override): Start diagnostics
	with lowercase letters.  Use %' in diagnostics.  Remove trailing
	'.' from diagnostics.
	(bfin_handle_longcall_attribute): Use %' in diagnostic.
	* config/cris/cris.c (cris_split_movdx,
	cris_expand_pic_call_address): Start diagnostics with lowercase
	letters.
	(cris_asm_output_label_ref): Use %' in diagnostic.
	* config/cris/cris.h (ASM_SPEC): Start diagnostic with a lowercase
	letter.
	* config/crx/crx.h (FUNCTION_PROFILER): Start diagnostic with a
	lowercase letter.
	* config/darwin-c.c (version_as_macro): Start diagnostic with a
	lowercase letter.
	* config/darwin-driver.c (darwin_default_min_version): Use %' in
	diagnostic.
	* config/host-darwin.c (darwin_gt_pch_use_address): Use %' in
	diagnostic.
	* config/i386/freebsd.h (LINK_SPEC): Avoid '`' in diagnostic.
	* config/i386/host-cygwin.c (cygwin_gt_pch_get_address): Use %' in
	diagnostics.
	* config/i386/i386.c (ix86_option_override_internal): Write
	diagnostic as a single sentence without trailing '.'.  Use %' in
	diagnostics.
	(ix86_function_sseregparm, classify_argument): Start diagnostics
	with lowercase letters.
	(ix86_expand_prologue): Use %' in diagnostic.
	* config/i386/i386.h (CC1_CPU_SPEC_1): Remove trailing '.' from
	diagnostic.
	* config/i386/nwld.h (LINK_SPEC): Start diagnostic with a
	lowercase letter.
	* config/i386/winnt.c (i386_pe_determine_dllimport_p): Use %' in
	diagnostic.
	* config/ia64/freebsd.h (LINK_SPEC): Avoid '`' in diagnostic.
	* config/ia64/ia64.opt (msched-max-memory-insns-hard-limit): Avoid
	'`' in help text.
	* config/lm32/lm32.c (lm32_print_operand): Start diagnostic with a
	lowercase letter.
	* config/mep/mep.c (mep_validate_vliw): Start diagnostics with
	lowercase letters.
	* config/microblaze/microblaze.c (microblaze_handle_option):
	Remove trailing '.' from diagnostic.
	(print_operand): Start diagnostic with a lowercase letter.
	* config/pa/pa-hpux10.h (LINK_SPEC): Start diagnostics with
	lowercase letters.  Avoid '`' in diagnostics.
	* config/pa/pa-hpux11.h (LINK_SPEC): Start diagnostics with
	lowercase letters.  Avoid '`' in diagnostics.
	* config/pa/pa64-hpux.h (LINK_SPEC): Start diagnostics with
	lowercase letters.  Avoid '`' in diagnostics.
	* config/picochip/picochip.c (picochip_option_override,
	picochip_emit_save_register, picochip_function_arg,
	picochip_output_label, picochip_output_internal_label,
	picochip_asm_output_opcode, picochip_output_cbranch,
	picochip_output_compare, picochip_output_branch,
	picochip_get_vliw_alu_id): Remove trailing '.' and '\n' from
	diagnostics. Start diagnostics with lowercase letters.  Use %' in
	diagnostics.
	* config/rs6000/rs6000.c (rs6000_option_override_internal): Use
	"SPE" capitalization.  Start diagnostic with a lowercase letter.
	(rs6000_handle_option): Start diagnostics with lowercase letters.
	(def_builtin): Remove trailing '.' from diagnostic.
	(rs6000_savres_routine_name): Start diagnostic with a lowercase
	letter.
	* config/rs6000/sysv4.h (LINK_OS_FREEBSD_SPEC): Avoid '`' in
	diagnostic.
	* config/rx/rx.c (rx_handle_option): Start diagnostic with a
	lowercase letter.
	* config/s390/s390.c (s390_option_override) Start diagnostics with
	lowercase letters.  Use %' in diagnostic.
	* config/sh/sh.c (sh_output_mi_thunk): Start diagnostics with
	lowercase letters.
	* config/sh/symbian-base.c (sh_symbian_mark_dllimport): Use %' in
	diagnostic.
	* config/sh/symbian-c.c (sh_symbian_is_dllimported): Use %' in
	diagnostic.
	* config/sh/symbian-cxx.c (sh_symbian_is_dllimported): Use %' in
	diagnostic.
	* config/sparc/freebsd.h (LINK_SPEC): Avoid '`' in diagnostic.
	* config/spu/spu.c (spu_option_override): Start diagnostics with
	lowercase letters.  Use %qs for quoting in diagnostics.
	(spu_check_builtin_parm): Remove trailing '.' from diagnostics.
	Use %wd instead of HOST_WIDE_INT_PRINT_DEC in diagnostic .
	* config/v850/v850.c (construct_save_jarl): Remove trailing '\n'
	from diagnostic.
	* convert.c (convert_to_integer, convert_to_vector): Use %' in
	diagnostics.
	* dbgcnt.c (dbg_cnt_process_opt): Start diagnostic with lowercase
	letter and use "cannot" spelling.
	* expmed.c (extract_fixed_bit_field): Start diagnostic with
	lowercase letter and format as a single sentence without '.'.
	* ggc-common.c (write_pch_globals, gt_pch_save, gt_pch_restore):
	Use %' in diagnostics.
	* ggc-page.c (ggc_pch_write_object, ggc_pch_finish, ggc_pch_read):
	Use %' in diagnostics.
	* ggc-zone.c (ggc_pch_write_object, ggc_pch_finish, ggc_pch_read):
	Use %' in diagnostics.
	* graph.c (clean_graph_dump_file): Use %' in diagnostic.
	* graphite-poly.c (graphite_read_scop_file): Start diagnostics
	with lowercase letters and remove tailing '.' and '\n'.
	* lto-cgraph.c (input_profile_summary): Start diagnostic with
	lowercase letter and remove trailing '.'.
	(input_cgraph): Start diagnostics with lowercase letters and
	remove trailing '\n'.
	* opts.c (finish_options, common_handle_option): Start diagnostics
	with lowercase letters and remove trailing '.'.  Fix typo in
	diagnostic.
	* passes.c (position_pass): Start diagnostic with lowercase
	letter.	
	* plugin.c (add_new_plugin, parse_plugin_arg_opt,
	register_callback, try_init_one_plugin): Start diagnostics with
	lowercase letters.
	* reload1.c (spill_failure): Use %' in diagnostic.
	(gen_reload): Start diagnostic with a lowercase letter.
	* stor-layout.c (place_field): Start diagnostic with a lowercase
	letter.
	* toplev.c (open_auxiliary_file): Use %' in diagnostic.
	* tree-cfg.c (verify_expr, verify_types_in_gimple_reference,
	verify_gimple_call, verify_gimple_phi, verify_eh_throw_stmt_node):
	Start diagnostics with lowercase letters, remove trailing '.' and
	use %' in diagnostics.
	* tree-ssa.c (verify_def): Remove trailing '.' from diagnostic.
	(verify_ssa): Don't split diagnostic across two error calls.
	Spell out "number" and use %' in diagnostic.
	* value-prof.c (visit_hist, check_counter): Start diagnostics with
	lowercase letters.

c-family:
	* c-common.c (handle_mode_attribute): Use %' and word "signedness"
	in diagnostic.
	* c-opts.c (c_common_parse_file): Start diagnostics with lowercase
	letter.
	* c-pragma.c (handle_pragma_target, handle_pragma_optimize):
	Remove trailing '.' from diagnostics.
	* c.opt (Wwrite-strings_: Avoid '`' in help text.

cp:
	* cvt.c (cp_convert_to_pointer): Use %' in diagnostic.
	* decl.c (layout_var_decl, maybe_commonize_var, grokdeclarator):
	Use %' in diagnostics.
	* decl2.c (check_classfn): Use %' in diagnostic.
	* init.c (build_java_class_ref): Use %' in diagnostic.
	(build_delete): Remove trailing '.' from diagnostic.
	* method.c (do_build_copy_assign, walk_field_subobs): Use %' in
	diagnostics.
	* name-lookup.c (pushdecl_maybe_friend): Use %' in diagnostic.
	* parser.c (cp_parser_exception_specification_opt): Remove
	trailing '.' from diagnostic.
	(cp_parser_objc_interstitial_code): Use %qs for quoting in
	diagnostic.
	* pt.c (check_valid_ptrmem_cst_expr): Use %< and %> for quoting in
	diagnostic.
	* repo.c (reopen_repo_file_for_write): Use %' in diagnostic.

fortran:
	* trans-array.c (gfc_trans_deferred_array): Use "front-end"
	spelling in diagnostic.
	* trans.c (gfc_allocate_array_with_status): Add missing space in
	diagnostic.

java:
	* expr.c (expand_java_field_op): Use %' in diagnostic.
	* jcf-parse.c (java_parse_file): Use %' in diagnostics.
	* jvspec.c (lang_specific_driver): Use %' in diagnostic.
	* lang.c (java_post_options): Use %' in diagnostics.

lto:
	* lto.c (lto_resolution_read): Start diagnostics with lowercase
	letters and remove trailing '.'.
	(lto_file_finalize): Start diagnostic with a lowercase letter.

objc:
	* objc-act.c (objc_init): Use %' in diagnostic.
	(objc_set_method_opt): Remove trailing '.' from diagnostic.

From-SVN: r166570
2010-11-10 23:23:15 +00:00
Jie Zhang f5c88dbfe7 stor-layout.c (layout_decl): Use the field's type to determine the mode and keep DECL_BIT_FIELD for a...
* stor-layout.c (layout_decl): Use the field's type to
	determine the mode and keep DECL_BIT_FIELD for a volatile
	bit-field.
	* config/arm/arm.c (arm_override_options): Default to
	-fstrict-volatile-bitfields.

	testsuite/
	* gcc.target/arm/volatile-bitfields-1.c: New test.
	* gcc.target/arm/volatile-bitfields-2.c: New test.
	* gcc.target/arm/volatile-bitfields-3.c: New test.

From-SVN: r165934
2010-10-26 03:22:49 +00:00
Eric Botcazou 0d475ac5b4 stor-layout.c (skip_simple_constant_arithmetic): New function.
* stor-layout.c (skip_simple_constant_arithmetic): New function.
	(self_referential_size): Use it instead of skip_simple_arithmetic.

From-SVN: r165716
2010-10-20 11:02:40 +00:00
Richard Guenther bb67d9c7ce machmode.h (mode_for_vector): Declare.
2010-10-07  Richard Guenther  <rguenther@suse.de>

	* machmode.h (mode_for_vector): Declare.
	* stor-layout.c (mode_for_vector): New function, split out from ...
	(layout_type): ... here.
	* tree-vectorizer.h (current_vector_size): Declare.
	* tree-vect-stmts.c (perm_mask_for_reverse): Check if the
	mask vector type is available.
	(get_vectype_for_scalar_type): Rename to ...
	(get_vectype_for_scalar_type_and_size): ... this.  Get a vector
	size argument.
	(get_vectype_for_scalar_type): New wrapper around
	get_vectype_for_scalar_type_and_size using current_vector_size.
	(get_same_sized_vectype): Use get_vectype_for_scalar_type_and_size.
	* tree-vect-loop.c (vect_analyze_loop_2): Split out core part
	of vect_analyze_loop here.
	(vect_analyze_loop): Loop over vector sizes calling vect_analyze_loop_3.
	* tree-vect-slp.c (vect_slp_analyze_bb): Set current_vector_size
	to autodetect.
	* config/i386/i386.c (ix86_vectorize_builtin_conversion): Fix
	V8SF to V8SI conversion builtin.

From-SVN: r165116
2010-10-07 14:36:38 +00:00
Joseph Myers 5de8299cec re PR driver/44076 (-MT <target> behaves different as -MT<target> (w/o space))
PR driver/44076
	* opts.h (struct cl_option): Add alias_arg, neg_alias_arg and
	alias_target fields.
	* opt-functions.awk (opt_sanitized_name): Don't handle
	finline-limit=, Wlarger-than= and ftemplate-depth= specially.
	* optc-gen.awk: Generate alias fields.
	* opth-gen.awk: Explicitly give values for OPT_* enum constants.
	Don't generate such constants for aliases.
	* opts-common.c (generate_canonical_option): New.
	(decode_cmdline_option): Handle aliases.  Use
	generate_canonical_option for known options instead of copying the
	input option text.
	* doc/options.texi (Alias): Document.
	* common.opt (W, Wlarger-than-, aux-info=, finline-limit-,
	fstack-check, specs): Mark as aliases.
	* gcc.c (driver_handle_option): Canonicalize -L options to joined
	arguments.
	(driver_handle_option): Don't handle OPT_specs.
	* opts.c (common_handle_option): Don't handle options marked as
	aliases.
	(enable_warning_as_error): Handle aliases.
	* stor-layout.c (layout_decl): Use OPT_Wlarger_than_ instead of
	OPT_Wlarger_than_eq.
	* tree-optimize.c (tree_rest_of_compilation): Use
	OPT_Wlarger_than_ instead of OPT_Wlarger_than_eq.

c-family:
	* c.opt (Wcomments, Werror-implicit-function-declaration,
	ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
	std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
	aliases.
	* c-common.c (option_codes): Use OPT_Wcomment instead of
	OPT_Wcomments.
	* c-opts.c (warning_as_error_callback, c_common_handle_option):
	Don't handle options marked as aliases.

java:
	* lang.opt (CLASSPATH, bootclasspath, classpath, encoding,
	fCLASSPATH=): Mark as Java options and as aliases.
	* jvspec.c (jvgenmain_spec): Don't handle -fCLASSPATH*.
	(lang_specific_driver): Don't handle options marked as aliases.
	* lang.c (java_handle_option): Don't handle OPT_fCLASSPATH_.

testsuite:
	* gcc.dg/cpp/warn-comments-3.c: New.  Based on warn-comments-2.c
	but using -Werror=comment.
	* gcc.dg/cpp/warn-comments.c, gcc.dg/cpp/warn-comments-2.c: Adjust
	expected error messages.

From-SVN: r163770
2010-09-02 12:41:22 +01:00
Nathan Froyd ac47786e99 vec.h (FOR_EACH_VEC_ELT): Define.
gcc/
	* vec.h (FOR_EACH_VEC_ELT): Define.
	* c-decl.c: Use it.
	* cfgloop.c: Likewise.
	* cfgloopmanip.c: Likewise.
	* cgraph.c: Likewise.
	* cgraphunit.c: Likewise.
	* combine.c: Likewise.
	* config/bfin/bfin.c: Likewise.
	* config/mips/mips.c: Likewise.
	* config/rs6000/rs6000.c: Likewise.
	* dbxout.c: Likewise.
	* df-scan.c: Likewise.
	* dominance.c: Likewise.
	* dse.c: Likewise.
	* dwarf2out.c: Likewise.
	* except.c: Likewise.
	* expr.c: Likewise.
	* function.c: Likewise.
	* gcse.c: Likewise.
	* genattr.c: Likewise.
	* ggc-common.c: Likewise.
	* gimplify.c: Likewise.
	* graphite-blocking.c: Likewise.
	* graphite-clast-to-gimple.c: Likewise.
	* graphite-dependences.c: Likewise.
	* graphite-interchange.c: Likewise.
	* graphite-poly.c: Likewise.
	* graphite-scop-detection.c: Likewise.
	* graphite-sese-to-poly.c: Likewise.
	* graphite.c: Likewise.
	* haifa-sched.c: Likewise.
	* ifcvt.c: Likewise.
	* implicit-zee.c: Likewise.
	* ipa-prop.c: Likewise.
	* ipa-struct-reorg.c: Likewise.
	* ipa.c: Likewise.
	* ira-build.c: Likewise.
	* ira-color.c: Likewise.
	* ira-emit.c: Likewise.
	* lambda-code.c: Likewise.
	* loop-invariant.c: Likewise.
	* loop-unroll.c: Likewise.
	* lower-subreg.c: Likewise.
	* lto-cgraph.c: Likewise.
	* lto-opts.c: Likewise.
	* lto-streamer-in.c: Likewise.
	* lto-streamer-out.c: Likewise.
	* lto-streamer.c: Likewise.
	* lto-symtab.c: Likewise.
	* matrix-reorg.c: Likewise.
	* opts.c: Likewise.
	* predict.c: Likewise.
	* print-tree.c: Likewise.
	* sdbout.c: Likewise.
	* sel-sched-dump.c: Likewise.
	* sel-sched-ir.c: Likewise.
	* sel-sched.c: Likewise.
	* sese.c: Likewise.
	* stor-layout.c: Likewise.
	* tree-cfg.c: Likewise.
	* tree-cfgcleanup.c: Likewise.
	* tree-chrec.c: Likewise.
	* tree-data-ref.c: Likewise.
	* tree-emutls.c: Likewise.
	* tree-inline.c: Likewise.
	* tree-into-ssa.c: Likewise.
	* tree-loop-distribution.c: Likewise.
	* tree-loop-linear.c: Likewise.
	* tree-mudflap.c: Likewise.
	* tree-outof-ssa.c: Likewise.
	* tree-parloops.c: Likewise.
	* tree-predcom.c: Likewise.
	* tree-pretty-print.c: Likewise.
	* tree-scalar-evolution.c: Likewise.
	* tree-ssa-live.c: Likewise.
	* tree-ssa-loop-im.c: Likewise.
	* tree-ssa-loop-ivcanon.c: Likewise.
	* tree-ssa-loop-ivopts.c: Likewise.
	* tree-ssa-loop-manip.c: Likewise.
	* tree-ssa-loop-niter.c: Likewise.
	* tree-ssa-loop-prefetch.c: Likewise.
	* tree-ssa-phiprop.c: Likewise.
	* tree-ssa-pre.c: Likewise.
	* tree-ssa-reassoc.c: Likewise.
	* tree-ssa-sccvn.c: Likewise.
	* tree-ssa-structalias.c: Likewise.
	* tree-ssa.c: Likewise.
	* tree-vect-data-refs.c: Likewise.
	* tree-vect-loop-manip.c: Likewise.
	* tree-vect-loop.c: Likewise.
	* tree-vect-patterns.c: Likewise.
	* tree-vect-slp.c: Likewise.
	* tree-vect-stmts.c: Likewise.
	* tree-vrp.c: Likewise.
	* tree.c: Likewise.
	* value-prof.c: Likewise.
	* var-tracking.c: Likewise.
	* varasm.c: Likewise.
	* vmsdbgout.c: Likewise.

gcc/ada/
	* gcc-interface/decl.c: Use FOR_EACH_VEC_ELT.
	* gcc-interface/trans.c: Likewise.
	* gcc-interface/utils.c: Likewise.

gcc/c-family/
	* c-common.c: Use FOR_EACH_VEC_ELT.
	* c-gimplify.c: Likewise.
	* c-pragma.c: Likewise.

gcc/cp/
	* call.c: Use FOR_EACH_VEC_ELT.
	* class.c: Likewise.
	* decl.c: Likewise.
	* decl2.c: Likewise.
	* error.c: Likewise.
	* except.c: Likewise.
	* mangle.c: Likewise.
	* method.c: Likewise.
	* name-lookup.c: Likewise.
	* parser.c: Likewise.
	* pt.c: Likewise.
	* repo.c: Likewise.
	* semantics.c: Likewise.
	* typeck2.c: Likewise.

gcc/fortran/
	* trans-openmp.c: Use FOR_EACH_VEC_ELT.

gcc/java/
	* class.c: Use FOR_EACH_VEC_ELT.
	* expr.c: Likewise.
	* jcf-parse.c: Likewise.
	* resource.c: Likewise.

gcc/lto/
	* lto.c: Use FOR_EACH_VEC_ELT.

From-SVN: r163401
2010-08-20 12:48:59 +00:00
Nathan Froyd 910ad8dee5 tree.h (DECL_CHAIN): Define.
gcc/
	* tree.h (DECL_CHAIN): Define.
	* alias.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
	* c-decl.c: Likewise.
	* c-parser.c: Likewise.
	* c-typeck.c: Likewise.
	* cfgexpand.c: Likewise.
	* cgraph.c: Likewise.
	* cgraphunit.c: Likewise.
	* combine.c: Likewise.
	* config/alpha/alpha.c: Likewise.
	* config/arm/arm.c: Likewise.
	* config/frv/frv.c: Likewise.
	* config/i386/i386.c: Likewise.
	* config/i386/winnt-cxx.c: Likewise.
	* config/ia64/ia64.c: Likewise.
	* config/iq2000/iq2000.c: Likewise.
	* config/mep/mep.c: Likewise.
	* config/mips/mips.c: Likewise.
	* config/pa/som.h: Likewise.
	* config/rs6000/rs6000.c: Likewise.
	* config/s390/s390.c: Likewise.
	* config/sh/sh.c: Likewise.
	* config/sh/symbian-cxx.c: Likewise.
	* config/sparc/sparc.c: Likewise.
	* config/spu/spu.c: Likewise.
	* config/stormy16/stormy16.c: Likewise.
	* config/vxworks.c: Likewise.
	* config/xtensa/xtensa.c: Likewise.
	* coverage.c: Likewise.
	* dbxout.c: Likewise.
	* dwarf2out.c: Likewise.
	* emit-rtl.c: Likewise.
	* expr.c: Likewise.
	* function.c: Likewise.
	* gimple-low.c: Likewise.
	* gimple-pretty-print.c: Likewise.
	* gimplify.c: Likewise.
	* integrate.c: Likewise.
	* ipa-inline.c: Likewise.
	* ipa-prop.c: Likewise.
	* ipa-split.c: Likewise.
	* ipa-struct-reorg.c: Likewise.
	* ipa-type-escape.c: Likewise.
	* langhooks.c: Likewise.
	* lto-cgraph.c: Likewise.
	* omp-low.c: Likewise.
	* stor-layout.c: Likewise.
	* tree-cfg.c: Likewise.
	* tree-complex.c: Likewise.
	* tree-dfa.c: Likewise.
	* tree-dump.c: Likewise.
	* tree-inline.c: Likewise.
	* tree-mudflap.c: Likewise.
	* tree-nested.c: Likewise.
	* tree-object-size.c: Likewise.
	* tree-pretty-print.c: Likewise.
	* tree-sra.c: Likewise.
	* tree-ssa-live.c: Likewise.
	* tree-ssa-loop-niter.c: Likewise.
	* tree-ssa-math-opts.c: Likewise.
	* tree-ssa-reassoc.c: Likewise.
	* tree-ssa-sccvn.c: Likewise.
	* tree-ssa-structalias.c: Likewise.
	* tree-tailcall.c: Likewise.
	* tree-vrp.c: Likewise.
	* tree.c: Likewise.
	* var-tracking.c: Likewise.
	* varasm.c: Likewise.

gcc/ada/
	* gcc-interface/decl.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
	* gcc-interface/trans.c: Likewise.
	* gcc-interface/utils.c: Likewise.
	* gcc-interface/utils2.c: Likewise.

gcc/c-family/
	* c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
	* c-format.c: Likewise.

gcc/cp/
	* cp-tree.h: Carefully replace TREE_CHAIN with DECL_CHAIN.
	* call.c: Likewise.
	* class.c: Likewise.
	* cp-gimplify.c: Likewise.
	* decl.c: Likewise.
	* decl2.c: Likewise.
	* init.c: Likewise.
	* mangle.c: Likewise.
	* name-lookup.c: Likewise.
	* optimize.c: Likewise.
	* parser.c: Likewise.
	* pt.c: Likewise.
	* rtti.c: Likewise.
	* search.c: Likewise.
	* semantics.c: Likewise.
	* typeck.c: Likewise.
	* typeck2.c: Likewise.

gcc/fortran/
	* f95-lang.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
	* trans-common.c: Likewise.
	* trans-decl.c: Likewise.
	* trans-types.c: Likewise.
	* trans.c: Likewise.

gcc/java/
	* java-tree.h: Carefully replace TREE_CHAIN with DECL_CHAIN.
	* boehm.c: Likewise.
	* class.c: Likewise.
	* decl.c: Likewise.
	* expr.c: Likewise.
	* jcf-parse.c: Likewise.
	* typeck.c: Likewise.
	* verify-glue.c: Likewise.

gcc/objc/
	* objc-act.c: Carefully replace TREE_CHAIN with DECL_CHAIN.

gcc/testsuite/
	* g++.dg/plugin/attribute_plugin.c: Carefully replace TREE_CHAIN
	with DECL_CHAIN.

From-SVN: r162223
2010-07-15 14:31:28 +00:00
Nathan Froyd 3bb06db415 tree.h (build_function_call_expr): Delete.
gcc/
	* tree.h (build_function_call_expr): Delete.
	(build_call_expr_loc_array): New function.
	(build_call_expr_loc_vec): New function.
	* tree-flow.h (struct omp_region): Change type of ws_args field
	to a VEC.
	* builtins.c (build_function_call_expr): Delete.
	(build_call_expr_loc_array): New function.
	(build_call_expr_loc): Call it.  Use XALLOCAVEC.
	(build_call_expr): Likewise.
	(build_call_expr_loc_vec): New function.
	* cgraphunit.c (build_cdtor): Call build_call_expr instead of
	build_function_call_expr.
	* expr.c (emutls_var_address): Likewise.
	* varasm.c (emutls_common_1): Likewise.
	* omp-low.c (expand_omp_atomic_mutex): Likewise.
	(expand_omp_taskreg): Adjust for new type of region->ws_args.
	(get_ws_args_for): Return a VEC instead of a tree.
	(expand_parallel_call): Call build_call_expr_loc_vec instead of
	build_function_call_expr.
	* stor-layout.c (self_referential_size): Likewise.

gcc/fortran/
	* trans-decl.c (build_entry_thunks): Call build_call_expr_loc_vec
	instead of build_function_call_expr.
	* trans-intrinsic.c (gfc_conv_intrinsic_sr_kind): Likewise.

From-SVN: r162148
2010-07-13 18:46:25 +00:00
Manuel López-Ibáñez 718f9c0f87 toplev.h: Do not include diagnostic-core.h.
2010-07-08  Manuel López-Ibáñez  <manu@gcc.gnu.org>

	* toplev.h: Do not include diagnostic-core.h.
	Include diagnostic-core.h in every file that includes toplev.h.
	* c-tree.h: Do not include toplev.h.
	* pretty-print.h: Update comment.
	* Makefile.in: Update dependencies.
	* alias.c: Include diagnostic-core.h in every file that includes
	toplev.h.
	* attribs.c: Likewise.
	* auto-inc-dec.c: Likewise.
	* bb-reorder.c: Likewise.
	* bt-load.c: Likewise.
	* caller-save.c: Likewise.
	* calls.c: Likewise.
	* cfg.c: Likewise.
	* cfganal.c: Likewise.
	* cfgbuild.c: Likewise.
	* cfgcleanup.c: Likewise.
	* cfghooks.c: Likewise.
	* cfgloop.c: Likewise.
	* combine.c: Likewise.
	* config/alpha/alpha.c: Likewise.
	* config/arc/arc.c: Likewise.
	* config/arm/arm.c: Likewise.
	* config/arm/pe.c: Likewise.
	* config/avr/avr.c: Likewise.
	* config/bfin/bfin.c: Likewise.
	* config/cris/cris.c: Likewise.
	* config/crx/crx.c: Likewise.
	* config/darwin-c.c: Likewise.
	* config/darwin.c: Likewise.
	* config/fr30/fr30.c: Likewise.
	* config/frv/frv.c: Likewise.
	* config/h8300/h8300.c: Likewise.
	* config/host-darwin.c: Likewise.
	* config/i386/i386.c: Likewise.
	* config/i386/netware.c: Likewise.
	* config/i386/nwld.c: Likewise.
	* config/i386/winnt-cxx.c: Likewise.
	* config/i386/winnt-stubs.c: Likewise.
	* config/i386/winnt.c: Likewise.
	* config/ia64/ia64-c.c: Likewise.
	* config/ia64/ia64.c: Likewise.
	* config/iq2000/iq2000.c: Likewise.
	* config/lm32/lm32.c: Likewise.
	* config/m32c/m32c-pragma.c: Likewise.
	* config/m32c/m32c.c: Likewise.
	* config/m32r/m32r.c: Likewise.
	* config/m68hc11/m68hc11.c: Likewise.
	* config/m68k/m68k.c: Likewise.
	* config/mcore/mcore.c: Likewise.
	* config/mep/mep-pragma.c: Likewise.
	* config/mep/mep.c: Likewise.
	* config/mmix/mmix.c: Likewise.
	* config/mn10300/mn10300.c: Likewise.
	* config/moxie/moxie.c: Likewise.
	* config/pa/pa.c: Likewise.
	* config/pdp11/pdp11.c: Likewise.
	* config/picochip/picochip.c: Likewise.
	* config/rs6000/rs6000-c.c: Likewise.
	* config/rs6000/rs6000.c: Likewise.
	* config/rx/rx.c: Likewise.
	* config/s390/s390.c: Likewise.
	* config/score/score.c: Likewise.
	* config/score/score3.c: Likewise.
	* config/score/score7.c: Likewise.
	* config/sh/sh.c: Likewise.
	* config/sh/symbian-base.c: Likewise.
	* config/sh/symbian-c.c: Likewise.
	* config/sh/symbian-cxx.c: Likewise.
	* config/sol2-c.c: Likewise.
	* config/sol2.c: Likewise.
	* config/sparc/sparc.c: Likewise.
	* config/spu/spu.c: Likewise.
	* config/stormy16/stormy16.c: Likewise.
	* config/v850/v850-c.c: Likewise.
	* config/v850/v850.c: Likewise.
	* config/vax/vax.c: Likewise.
	* config/vxworks.c: Likewise.
	* config/xtensa/xtensa.c: Likewise.
	* convert.c: Likewise.
	* cse.c: Likewise.
	* cselib.c: Likewise.
	* dbgcnt.c: Likewise.
	* dbxout.c: Likewise.
	* ddg.c: Likewise.
	* dominance.c: Likewise.
	* emit-rtl.c: Likewise.
	* explow.c: Likewise.
	* expmed.c: Likewise.
	* fixed-value.c: Likewise.
	* fold-const.c: Likewise.
	* fwprop.c: Likewise.
	* gcse.c: Likewise.
	* ggc-common.c: Likewise.
	* ggc-page.c: Likewise.
	* ggc-zone.c: Likewise.
	* gimple-low.c: Likewise.
	* gimplify.c: Likewise.
	* graph.c: Likewise.
	* haifa-sched.c: Likewise.
	* ifcvt.c: Likewise.
	* implicit-zee.c: Likewise.
	* integrate.c: Likewise.
	* ira-build.c: Likewise.
	* ira-color.c: Likewise.
	* ira-conflicts.c: Likewise.
	* ira-costs.c: Likewise.
	* ira-lives.c: Likewise.
	* ira.c: Likewise.
	* lists.c: Likewise.
	* loop-doloop.c: Likewise.
	* loop-iv.c: Likewise.
	* lto-opts.c: Likewise.
	* lto-symtab.c: Likewise.
	* main.c: Likewise.
	* modulo-sched.c: Likewise.
	* optabs.c: Likewise.
	* params.c: Likewise.
	* plugin.c: Likewise.
	* postreload-gcse.c: Likewise.
	* postreload.c: Likewise.
	* predict.c: Likewise.
	* profile.c: Likewise.
	* real.c: Likewise.
	* regcprop.c: Likewise.
	* reginfo.c: Likewise.
	* regmove.c: Likewise.
	* reorg.c: Likewise.
	* resource.c: Likewise.
	* rtl.c: Likewise.
	* rtlanal.c: Likewise.
	* sched-deps.c: Likewise.
	* sched-ebb.c: Likewise.
	* sched-rgn.c: Likewise.
	* sdbout.c: Likewise.
	* sel-sched-dump.c: Likewise.
	* sel-sched-ir.c: Likewise.
	* simplify-rtx.c: Likewise.
	* stmt.c: Likewise.
	* stor-layout.c: Likewise.
	* store-motion.c: Likewise.
	* targhooks.c: Likewise.
	* tree-cfg.c: Likewise.
	* tree-cfgcleanup.c: Likewise.
	* tree-dump.c: Likewise.
	* tree-eh.c: Likewise.
	* tree-inline.c: Likewise.
	* tree-nomudflap.c: Likewise.
	* tree-object-size.c: Likewise.
	* tree-optimize.c: Likewise.
	* tree-outof-ssa.c: Likewise.
	* tree-phinodes.c: Likewise.
	* tree-profile.c: Likewise.
	* tree-ssa-ccp.c: Likewise.
	* tree-ssa-coalesce.c: Likewise.
	* tree-ssa-live.c: Likewise.
	* tree-ssa-loop-niter.c: Likewise.
	* tree-ssa-loop-prefetch.c: Likewise.
	* tree-ssa-loop.c: Likewise.
	* tree-ssa-structalias.c: Likewise.
	* tree-ssa-uninit.c: Likewise.
	* tree-ssa.c: Likewise.
	* tree-vect-data-refs.c: Likewise.
	* tree-vect-loop-manip.c: Likewise.
	* tree-vect-loop.c: Likewise.
	* tree-vect-patterns.c: Likewise.
	* tree-vect-stmts.c: Likewise.
	* tree-vrp.c: Likewise.
	* varasm.c: Likewise.
	* vec.c: Likewise.
	* web.c: Likewise.
	* xcoffout.c: Likewise.

c-family/
	* c-common.h: Include diagnostic-core.h. Error if already
	included.
	* c-semantics.c: Do not define GCC_DIAG_STYLE here.
cp/
	* cp-tree.h: Do not include toplev.h.
	
java/
	* boehm.c: Include diagnostic-core.h in every file that includes
	toplev.h.
	* class.c: Likewise.
	* constants.c: Likewise.
	* decl.c: Likewise.
	* except.c: Likewise.
	* expr.c: Likewise.
	* jcf-parse.c: Likewise.
	* mangle.c: Likewise.
	* mangle_name.c: Likewise.
	* resource.c: Likewise.
	* typeck.c: Likewise.
	* verify-glue.c: Likewise.
ada/
	* gcc-interface/utils.c: Include diagnostic-core.h in every file
	that includes toplev.h.
lto/
	* lto-coff.c: Include diagnostic-core.h in every file that
	includes toplev.h.
	* lto-elf.c: Likewise.
	* lto-lang.c: Likewise.
	* lto-macho.c: Likewise.

From-SVN: r161943
2010-07-08 04:22:54 +00:00
H.J. Lu fae76410f4 Remove unused local variables.
2010-06-18  H.J. Lu  <hongjiu.lu@intel.com>

	* stor-layout.c (debug_rli): Remove unused local variables.

From-SVN: r161008
2010-06-18 09:48:47 -07:00
Nathan Froyd 76d971ccfb tree.h (record_layout_info): Change type of pending_statics field to a VEC.
* tree.h (record_layout_info): Change type of pending_statics field
	to a VEC.
	* stor-layout.c (start_record_layout): Store NULL into
	pending_statics.
	(debug_rli): Call debug_vec_tree instead of debug_tree.
	(place_field): Likewise.
	(finish_record_layout): Likewise.

From-SVN: r161000
2010-06-18 15:49:55 +00:00
Eric Botcazou f7b4a38334 stor-layout.c (self_referential_size): Set UNKNOWN_LOCATION on the newly built CALL_EXPR.
* stor-layout.c (self_referential_size): Set UNKNOWN_LOCATION on the
	newly built CALL_EXPR.
	* tree-profile.c (tree_profiling): Return 0 for built-in stuff.

From-SVN: r160344
2010-06-06 15:38:13 +00:00
H.J. Lu 1c314335e7 Check MAX_FIXED_MODE_SIZE on bit-field in C++.
gcc/ada/

2010-06-03  H.J. Lu  <hongjiu.lu@intel.com>

	PR c++/44294
	* gcc-interface/decl.c (MAX_FIXED_MODE_SIZE): Removed.

gcc/cp/

2010-06-03  H.J. Lu  <hongjiu.lu@intel.com>

	PR c++/44294
	* class.c (layout_class_type): Check MAX_FIXED_MODE_SIZE on
	bit-field.

gcc/

2010-06-03  H.J. Lu  <hongjiu.lu@intel.com>

	PR c++/44294
	* defaults.h (MAX_FIXED_MODE_SIZE): New.

	* stor-layout.c (MAX_FIXED_MODE_SIZE): Removed.

From-SVN: r160229
2010-06-03 09:36:22 -07:00
Jan Hubicka 24e47c76ba tree-vrp.c (debug_value_range, [...]): Annotate with DEBUG_FUNCTION.
* tree-vrp.c (debug_value_range, debug_all_value_ranges,
	debug_asserts_for, debug_all_asserts): Annotate with DEBUG_FUNCTION.
	* tree-into-ssa.c (debug_decl_set, debug_defs_stack, debug_currdefs,
	debug_tree_ssa, debug_tree_ssa_stats, debug_def_blocks,
	debug_names_replaced_by, debug_update_ssa): Likewise.	
	* sbitmap.c (debug_sbitmap): Likewise.
	* genrecog.c (debug_decision, debug_decision_list): Likewise.
	* tree-pretty-print.c (debug_generic_expr, debug_generic_stmt,
	debug_tree_chain): Likewise.
	* tree-loop-distribution.c (debug_rdg_partitions): Likewise.
	* cgraph.c (debug_cgraph_node, debug_cgraph): Likewise.
	* optabs.c  (debug_optab_libfuncs): Likewise.
	(verify_loop_closed_ssa): Likewise.
	* value-prof.c (verify_histograms): Likewise.
	* reload.c (debug_reload_to_stream, debug_reload): Likewise.
	* bitmap.c (debug_bitmap_file, debug_bitmap, bitmap_print): Likewise.
	* cfghooks.c (verify_flow_info): Likewise.
	* fold-const.c (debug_fold_checksum): Likewise.
	* omp-low.c (debug_omp_region, debug_all_omp_regions): Likewise.
	* cfg.c (debug_regset, debug_flow_info, debug_bb, debug_bb_n):
	Likewise.
	* omega.c (debug_omega_problem): Likewise.
	* cgraphunit.c (verify_cgraph_node, verify_cgraph): Likewise.
	* tree-ssa-ccp.c (debug_lattice_value): Likewise.
	* dominance.c (verify_dominators, debug_dominance_info,
	debug_dominance_tree): Likewise.
	* df-core.c (df_insn_uid_debug, df_insn_debug, df_insn_debug_regno,
	* df_regno_debug, df_ref_debug,
	debug_df_insn, debug_df_reg, debug_df_regno, debug_df_ref,
	debug_df_defno, debug_df_useno, debug_df_chain): Likewise.
	* tree-ssa-dom.c (debug_dominator_optimization_stats): Likewise.
	* sel-sched.c (debug_state): Likewise.
	* tree-ssa-alias.c (debug_alias_info, debug_points_to_info_for): Likewise.
	* cfganal.c (print_edge_list, verify_edge_list): Likewise.
	* dwarf2out.c (debug_dwarf_die, debug_dwarf): Likewise.
	* tree-eh.c (verify_eh_edges, verify_eh_dispatch_edge): Likewise.
	* gimple-pretty-print.c (debug_gimple_stmt, debug_gimple_seq): Likewise.
	* c-pretty-print.c (debug_c_tree): Likewise.
	* sel-sched-dump.c (debug_insn_rtx, debug_vinsn, debug_expr, debug_insn
	debug_av_set, debug_lv_set, debug_ilist, debug_blist, debug_insn_vector,
	debug_hard_reg_set, debug_mem_addr_value): Likewise.
	* ebitmap.c (debug_ebitmap): Likewise.
	* function.c (debug_find_var_in_block_tree): Likewise.
	* print-rtl.c (debug_rtx): Likewise.
	(debug_rtx_count): Likewise.
	(debug_rtx_list, debug_rtx_range, debug_rtx_find): Likewise.
	* stor-layout.c (debug_rli): Likewise.
	* ipa.c (debug_cgraph_node_set, debug_varpool_node_set): Likewise.
	* tree-data-ref.c (debug_data_references, debug_data_dependence_relations,
	debug_data_reference, debug_data_dependence_relation, debug_rdg_vertex,
	debug_rdg_component, debug_rdg): Likewise.
	* tree-affine.c (debug_aff): Likewise.
	* tree-dfa.c (debug_referenced_vars, debug_variable, debug_dfa_stats): Likewise.
	* except.c (debug_eh_tree, verify_eh_tree): Likewise.
	* emit-rtl.c (verify_rtl_sharing): Likewise.
	* tree-ssa-pre.c (debug_pre_expr, debug_bitmap_set,
	debug_value_expressions): Likewise.
	* tree-ssa-live.c (debug_scope_block, debug_scope_blocks): Likewise.
	* sese.c (debug_rename_map, debug_ivtype_map): Likewise.
	* print-tree.c (debug_tree, debug_vec_tree): Likewise.
	* cfglayout.c (verify_insn_chain): Likewise.
	* graphite-clast-to-gimple.c (debug_clast_name_indexes,
	debug_clast_stmt, debug_generated_program): Likewise.
	* ggc-page.c (debug_print_page_list): Likewise.
	* tree-ssa-ter.c (debug_ter): Likewise.
	* graphite-dependences.c (debug_pddr): Likewise.
	* sched-deps.c (debug_ds): Likewise.
	* tree-ssa.c (verify_ssa): Likewise.
	* graphite-poly.c (debug_scattering_function, debug_iteration_domain,
	debug_scattering_functions, debug_iteration_domains, debug_pdr,
	debug_pdrs, debug_pbb_domain, debug_pbb, debug_scop_context, debug_scop,
	debug_cloog, debug_scop_params, debug_lst): Likewise.
	* tree-inline.c (debug_find_tree): Likewise.
	* graphite-ppl.c (debug_ppl_linear_expr, debug_ppl_polyhedron_matrix,
	debug_ppl_powerset_matrix): Likewise.
	* var-tracking.c (debug_dv): Likewise.
	* system.h (DEBUG_FUNCTION, DEBUG_VARIABLE): Define.
	* cfgloop.c (verify_loop_structure): Likewise.
	* plugin.c (dump_active_plugins, debug_active_plugins): Likewise.
	* c-common.c (verify_sequence_points): Likewise.
	* sched-rgn.c (debug_regions, debug_region, debug_candidate,
	debug_candidates, debug_rgn_dependencies): Likewise.
	* tree-ssa-structalias.c (debug_constraint, debug_constraints,
	* debug_constraint_graph, debug_solution_for_var,
	debug_sa_points_to_info): Likewise.
	* sched-vis.c (debug_insn_slim, debug_bb_slim, debug_bb_n_slim):
	Likewie.
	* tree-cfg.c (debug_cfg_stats, verify_stmts, debug_function,
	debug_loops, debug_loop, debug_loop_num): Likewise.
	* passes.c (debug_pass): Likewise.
	(dump_properties): Likewise; add cfglayout property.
	(debug_properties): Likewise.
	* tree-ssa-reassoc.c (debug_ops_vector): Likewise.
	* varpool.c (debug_varpool): Likewise.
	* regcprop.c (debug_value_data): Likewise.
	* tree-ssa-operands.c (verify_imm_links, debug_immediate_uses,
	debug_immediate_uses_for): Likewise.

From-SVN: r160036
2010-05-29 20:31:45 +00:00
Anatoly Sokolov 1961ffb8cd double-int.h (double_int_ior): New function.
* double-int.h (double_int_ior): New function.
	* tree.h (build_int_cst_wide_type): Remove.
	* tree.c (build_int_cst_wide_type): Remove.
	* fold-const.c (native_interpret_int): Use double_int_to_tree instead
	of build_int_cst_wide_type.
	* stor-layout.c (set_sizetype): (Ditto.).
	* dojump.c (do_jump): Use build_int_cstu instead of
	build_int_cst_wide_type.

/java
	* jcf-parse.c (get_constant): Use double_int_to_tree instead of
	build_int_cst_wide_type.

From-SVN: r159595
2010-05-20 00:09:57 +04:00