Commit Graph

104166 Commits

Author SHA1 Message Date
Jason Merrill
73808ca6a4 * except.c (build_throw): Set EXPR_LOCATION.
From-SVN: r166008
2010-10-27 11:48:26 -04:00
Jason Merrill
236fd18cba * tree.c (build_cplus_new): Handle CONSTRUCTOR.
From-SVN: r166007
2010-10-27 11:48:16 -04:00
Jason Merrill
e02927a11a semantics.c (finish_compound_stmt): Avoid creating an unnecessary BIND_EXPR.
* semantics.c (finish_compound_stmt): Avoid creating an
	unnecessary BIND_EXPR.

From-SVN: r166006
2010-10-27 11:48:09 -04:00
Jason Merrill
bc8a0bd9fc call.c (convert_like_real): Don't check narrowing if the element is also an initializer-list.
* call.c (convert_like_real): Don't check narrowing if the element
	is also an initializer-list.

From-SVN: r166005
2010-10-27 11:48:01 -04:00
Jason Merrill
221925596f gimplify.c (gimplify_decl_expr): Handle anonymous artificial variables sooner.
* gimplify.c (gimplify_decl_expr): Handle anonymous artificial
	variables sooner.

From-SVN: r166004
2010-10-27 11:47:52 -04:00
Jie Zhang
84fabdde09 haifa-sched.c (ISSUE_POINTS): Remove.
* haifa-sched.c (ISSUE_POINTS): Remove.
	(max_issue): Don't issue more than issue_rate instructions.

Co-Authored-By: Maxim Kuvyrkov <maxim@codesourcery.com>

From-SVN: r166002
2010-10-27 14:30:17 +00:00
Ian Lance Taylor
9c042d80ae Replace UNSPEC_STACK_CHECK with UNSPECV_SPLIT_STACK_RETURN.
2010-10-27  Ian Lance Taylor  <iant@google.com>

	PR target/46197
	* config/i386/i386.md (UNSPECV_SPLIT_STACK_RETURN): New.
	(split_stack_return): Replace UNSPEC_STACK_CHECK with
	UNSPECV_SPLIT_STACK_RETURN.

From-SVN: r166001
2010-10-27 06:32:54 -07:00
H.J. Lu
2767a7f210 Add -mvzeroupper to x86.
gcc/

2010-10-27  H.J. Lu  <hongjiu.lu@intel.com>

	* config/i386/i386-protos.h (init_cumulative_args): Add an int.

	* config/i386/i386.c (block_info): New.
	(BLOCK_INFO): Likewise.
	(call_avx256_state): Likewise.
	(check_avx256_stores): Likewise.
	(move_or_delete_vzeroupper_2): Likewise.
	(move_or_delete_vzeroupper_1): Likewise.
	(move_or_delete_vzeroupper): Likewise.
	(use_avx256_p): Likewise.
	(function_pass_avx256_p): Likewise.
	(flag_opts): Add -mvzeroupper.
	(ix86_option_override_internal): Turn on MASK_VZEROUPPER by
	default for TARGET_AVX.  Turn off MASK_VZEROUPPER if TARGET_AVX
	is disabled.
	(ix86_function_ok_for_sibcall): Disable sibcall if we need to
	generate vzeroupper.
	(init_cumulative_args): Add an int to indicate caller.  Set
	use_avx256_p, callee_return_avx256_p and caller_use_avx256_p
	based on return type.
	(ix86_function_arg): Set use_avx256_p, callee_pass_avx256_p and
	caller_pass_avx256_p based on argument type.
	(ix86_expand_epilogue): Emit vzeroupper if 256bit AVX register
	is used, but not returned by caller.
	(ix86_expand_call): Emit vzeroupper if 256bit AVX register is
	used.
	(ix86_local_alignment): Set use_avx256_p if 256bit AVX register
	is used.
	(ix86_minimum_alignment): Likewise.
	(ix86_expand_special_args_builtin): Set target to
	GEN_INT (vzeroupper_intrinsic) for CODE_FOR_avx_vzeroupper.
	(ix86_reorg): Run the vzeroupper optimization if needed.

	* config/i386/i386.h (ix86_args): Add caller.
	(INIT_CUMULATIVE_ARGS): Updated.
	(machine_function): Add use_vzeroupper_p, use_avx256_p,
	caller_pass_avx256_p, caller_return_avx256_p,
	callee_pass_avx256_p and callee_return_avx256_p.

	* config/i386/i386.opt (-mvzeroupper): New.

	* config/i386/predicates.md (vzeroupper_operation): Removed.

	* config/i386/sse.md (avx_vzeroupper): Removed.
	(*avx_vzeroupper): Removed.
	(avx_vzeroupper): New.

	* doc/invoke.texi: Document -mvzeroupper.

gcc/testsuite/

2010-10-27  H.J. Lu  <hongjiu.lu@intel.com>

	* gcc.target/i386/avx-vzeroupper-1.c: Add -mtune=generic.
	* gcc.target/i386/avx-vzeroupper-2.c: Likewise.

	* gcc.target/i386/avx-vzeroupper-3.c: New.
	* gcc.target/i386/avx-vzeroupper-4.c: Likewise.
	* gcc.target/i386/avx-vzeroupper-5.c: Likewise.
	* gcc.target/i386/avx-vzeroupper-6.c: Likewise.
	* gcc.target/i386/avx-vzeroupper-7.c: Likewise.
	* gcc.target/i386/avx-vzeroupper-8.c: Likewise.
	* gcc.target/i386/avx-vzeroupper-9.c: Likewise.
	* gcc.target/i386/avx-vzeroupper-10.c: Likewise.
	* gcc.target/i386/avx-vzeroupper-11.c: Likewise.
	* gcc.target/i386/avx-vzeroupper-12.c: Likewise.
	* gcc.target/i386/avx-vzeroupper-13.c: Likewise.
	* gcc.target/i386/avx-vzeroupper-14.c: Likewise.

From-SVN: r166000
2010-10-27 05:36:15 -07:00
Eric Botcazou
22bc122eca t-mingw32 (SHLIB_LC): Add -lmingwthrd.
* config/i386/t-mingw32 (SHLIB_LC): Add -lmingwthrd.
	* config/i386/t-mingw-w32 (SHLIB_LC): Likewise.
	* config/i386/t-mingw-w64 (SHLIB_LC): Likewise.

From-SVN: r165999
2010-10-27 11:21:00 +00:00
Eric Botcazou
5d0d156482 w32-unwind.h (i386_w32_fallback_frame_state): Fix regnum of EBP.
* config/i386/w32-unwind.h (i386_w32_fallback_frame_state): Fix regnum
	of EBP.  Do not restore reg #9.  Remove +1 adjustment to EIP and set
	fs->signal_frame instead.

Co-Authored-By: Olivier Hainque <hainque@adacore.com>

From-SVN: r165998
2010-10-27 11:18:45 +00:00
Nicola Pero
200290f239 In gcc/: 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
In gcc/:
2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>

        * c-parser.c (c_parser_objc_at_property_declaration): Recognize
        RID_ASSIGN, RID_COPY, RID_RETAIN, RID_READWRITE and RID_NONATOMIC.
        Do not use objc_set_property_attr, but use local variables
        instead.  Detect repeated usage of setter, getter and ivar
        attributes.  Improved error processing when a setter name does not
        end in ':'.  Do not check for CPP_CLOSE_PAREN after we determined
        that the token is a keyword.  Updated call to
        objc_add_property_declaration.

In gcc/cp/:
2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>

        * parser.c (cp_parser_objc_at_property_declaration): Recognize
        RID_ASSIGN, RID_COPY, RID_RETAIN, RID_READWRITE and RID_NONATOMIC.
        Do not use objc_set_property_attr, but use local variables
        instead.  Detect repeated usage of setter, getter and ivar
        attributes.  Improved error processing when a setter name does not
        end in ':'.  Do not check for CPP_CLOSE_PAREN after we determined
        that the token is a keyword.  Updated call to
        objc_add_property_declaration.

In gcc/c-family/:
2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>

        * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
        RID_RETAIN, RID_COPY and RID_NONATOMIC.  Updated RID_FIRST_PATTR
        and RID_LAST_PATTR.
        (objc_add_property_declaration): Added additional arguments.
        (objc_property_attribute_kind): Removed.
        (objc_set_property_attr): Removed.
        * c-common.c (c_common_reswords): Added readwrite, assign, retain,
        copy and nonatomic.
        * stub-objc.c (objc_add_property_declaration): Added additional
        arguments.
        (objc_set_property_attr): Removed.
        
In gcc/objc/:
2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>

        * objc-act.c (objc_add_property_declaration): Added arguments to
        pass the various property attributes that were parsed with the
        property declaration.  Process arguments to determine the final
        property attributes and produce error messages as appropriate.
        Added temporary code to keep the compiler silent about variables
        set but not used - for new attributes that are only checked but
        have no effect yet.
        (property_readonly): Removed.
        (property_setter): Removed.
        (property_getter): Removed.
        (property_ivar): Removed.
        (property_copies): Removed.     
        (objc_set_property_attr): Removed.
        * objc-act.h (enum property_assign_semantics): New.
        
In gcc/testsuite/:
2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>

        * obj-c.dg/property/at-property-4.m: New.
        * obj-c++.dg/property/at-property-4.mm: New.
        * obj-c++.dg/property/property-neg-5.m: Updated testcase for
        updates in warning.
        * obj-c++.dg/property/property-neg-5.mm: Updated testcase for
        updates in warning.

From-SVN: r165997
2010-10-27 05:23:08 +00:00
Nicola Pero
f614132bc7 In gcc/: 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
In gcc/:
2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>

        * c-parser.c (c_parser_objc_at_property): Renamed to
        c_parser_objc_at_property_declaration.  Updated calls to
        objc_add_property_variable, now objc_add_property_declaration.
        Code rewritten to be much more robust in recovering from syntax
        errors.  Added comments.
        (c_parser_objc_property_attrlist): Removed.
        (c_parser_external_declaration): Updated calls to
        c_parser_objc_at_property, now
        c_parser_objc_at_property_declaration.
        (c_parser_objc_methodprotolist): Same change.

In gcc/c-family/:
2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>

        * c-common.h (objc_add_property_variable): Renamed to
        objc_add_property_declaration.  Added location argument.
        * stub-objc.c (objc_add_property_variable): Same change.

In gcc/cp/:
2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>

        * parser.c (cp_parser_objc_property_decl): Renamed to
        cp_parser_objc_struct_declaration.  Return the parsed trees
        instead of calling objc_add_property_variable directly.  Detect
        missing or invalid declspecs.  Implemented attributes.  Do not eat
        the ';' at the end.  Exit loop whenever a non-comma is parsed, not
        just EOF.
        (cp_parser_objc_at_property): Renamed to
        cp_parser_objc_at_property_declaration.  Updated calls to
        objc_add_property_variable, now objc_add_property_declaration, and
        to cp_parser_objc_property_decl, now
        cp_parser_objc_struct_declaration.  Rewritten all code to be more
        robust in dealing with syntax errors, and almost identical to the
        one in c_parser_objc_at_property_declaration.
        (cp_parser_objc_property_attrlist): Removed.
        (cp_parser_objc_method_prototype_list): Updated call to
        cp_parser_objc_at_property.
        (cp_parser_objc_method_definition_list): Same change.
        (cp_parser_objc_class_ivars): Detect a number of invalid
        declarations of instance variables and produce errors when they
        are found.

In gcc/objc/:
2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>

        * objc-act.c (objc_add_property_variable): Renamed to
        objc_add_property_declaration.  Added location argument.  Updated
        warnings and errors to use it.  Use error, not fatal_error, if a
        property declaration is found outside an interface or
        implementation context.

In gcc/testsuite/:
2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>

        * objc.dg/property/at-property-1.m: New.
        * objc.dg/property/at-property-2.m: New.
        * objc.dg/property/at-property-3.m: New.
        * objc.dg/ivar-invalid-type-1.m: New.
        * obj-c++.dg/property/at-property-1.mm: New.
        * obj-c++.dg/property/at-property-2.mm: New.
        * obj-c++.dg/property/at-property-3.mm: New.
        * obj-c++.dg/ivar-invalid-type-1.mm: New.
        * objc.dg/property/property-neg-6.m: Updated testcase for updates
        in error reporting.

From-SVN: r165996
2010-10-27 04:37:47 +00:00
H.J. Lu
3e1484c9ee Put back unspec_volatile on split_stack_return.
2010-10-26  H.J. Lu  <hongjiu.lu@intel.com>

	* config/i386/i386.md (split_stack_return): Put back
	unspec_volatile.

From-SVN: r165995
2010-10-26 19:48:42 -07:00
GCC Administrator
78b9aee5d7 Daily bump.
From-SVN: r165994
2010-10-27 00:18:01 +00:00
Jan Hubicka
ed62e0d9b7 ipa.c (process_references): Enqueue all referenced nodes; mark as reachable only non-external nodes.
* ipa.c (process_references): Enqueue all referenced nodes;
	mark as reachable only non-external nodes.
	(cgraph_remove_unreachable_nodes): All referenced nodes should
	be enqueued; remove bogues node->needed check.

From-SVN: r165990
2010-10-26 22:42:53 +00:00
Jan Hubicka
8c3800373f * cgraphbuild.c (build_cgraph_edges): Use ipa-reference to represent OMP.
From-SVN: r165989
2010-10-26 22:32:47 +00:00
Jan Hubicka
d5fae4575b ipa.c (process_references): Enqueue all referenced nodes; mark as reachable only non-external nodes.
* ipa.c (process_references): Enqueue all referenced nodes;
	mark as reachable only non-external nodes.
	(cgraph_remove_unreachable_nodes): All referenced nodes should
	be enqueued; remove bogues node->needed check.

From-SVN: r165988
2010-10-26 21:33:37 +00:00
H.J. Lu
74288524a6 Replace unspec_volatile with unspec in split_stack_return.
From-SVN: r165987
2010-10-26 14:20:19 -07:00
Jan Hubicka
eac8df5d45 Add missing testcase.
From-SVN: r165986
2010-10-26 21:20:00 +00:00
Jan Hubicka
030cd86c6d lto.c (add_cgraph_node_to_partition, [...]): Add debug info.
* lto.c (add_cgraph_node_to_partition,
	add_varpool_node_to_partition): Add debug info.
	(lto_1_to_1_map, lto_balanced_map): Do not re-add already
	partitioned nodes.
	(do_whole_program_analysis): Set function flags before dumping.

From-SVN: r165984
2010-10-26 20:10:03 +00:00
Jason Merrill
859b9bfa86 revert: pt.c (lookup_template_class): push_tinst_level around call to coerce_template_parms.
Revert
	* pt.c (lookup_template_class): push_tinst_level around call to
	coerce_template_parms.

From-SVN: r165982
2010-10-26 15:45:55 -04:00
Jerry DeLisle
33ede059c0 re PR fortran/46010 (I/O: Namelist-reading bug)
2010-10-26  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

	PR libgfortran/46010
	* gfortran.dg/namelist_66.f90: New test.
	* gfortran.dg/fmt_t_6.f: Fix whitespace.

From-SVN: r165981
2010-10-26 19:34:21 +00:00
Jonathan Wakely
d47abcca6d install.texi: Fix typo in --with-sysroot description.
2010-10-26  Jonathan Wakely  <jwakely.gcc@gmail.com>

	* doc/install.texi: Fix typo in --with-sysroot description.

From-SVN: r165980
2010-10-26 20:07:01 +01:00
Jerry DeLisle
5609699aff re PR fortran/46010 (I/O: Namelist-reading bug)
2010-10-26  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

	PR libgfortran/46010
	* io/list_read.c (nml_parse_qualifier): Add additional conditions for
	setting the end index for loop specification. Fix some whitespace.
	* io/write.c (write_default_char4): Const-ify the source argument.

From-SVN: r165979
2010-10-26 19:05:08 +00:00
Jan Hubicka
892ae21cc7 ipa.c (cgraph_externally_visible_p, [...]): Use info provided by linker plugin.
* ipa.c (cgraph_externally_visible_p, varpool_externally_visible_p):
	Use info provided by linker plugin.

From-SVN: r165978
2010-10-26 18:34:03 +00:00
Ralf Wildenhues
0e0f02ff92 Patch by Ralf Wildenhues.
* aclocal.m4 (AC_LANG_FUNC_LINK_TRY(C)): Delete.
	* configure: Regenerate.

From-SVN: r165977
2010-10-26 18:29:29 +00:00
Jason Merrill
534ecb1751 tree.c (build_vec_init_expr): Split out from...
* tree.c (build_vec_init_expr): Split out from...
	(build_array_copy): ...here.
	* init.c (perform_member_init): Use it.
	* cp-tree.h: Declare it.
	* cp-gimplify.c (cp_gimplify_init_expr): Don't gimplify the slot for
	VEC_INIT_EXPR and AGGR_INIT_EXPR here.  Drop pre/post parameters.
	(cp_gimplify_expr): Handle array default-initialization via
	VEC_INIT_EXPR.

From-SVN: r165976
2010-10-26 14:10:53 -04:00
Jason Merrill
73c982bc87 varasm.c (constructor_static_from_elts_p): Don't require a CONSTRUCTOR to have elements to be suitable for static...
* varasm.c (constructor_static_from_elts_p): Don't require a
	CONSTRUCTOR to have elements to be suitable for static
	initialization.  Allow ARRAY_TYPE as well.

From-SVN: r165975
2010-10-26 13:57:44 -04:00
Jason Merrill
701c0df13e pt.c (lookup_template_class): push_tinst_level around call to coerce_template_parms.
* pt.c (lookup_template_class): push_tinst_level around call to
	coerce_template_parms.

From-SVN: r165974
2010-10-26 13:57:30 -04:00
Janus Weil
2c80712872 re PR fortran/42647 ([F03] Missed initialization/dealloc of allocatable scalar DT with allocatable component)
2010-10-26  Janus Weil  <janus@gcc.gnu.org>

	PR fortran/42647
	* trans.h (gfc_deallocate_scalar_with_status): New prototype.
	* trans.c (gfc_deallocate_scalar_with_status): New function for
	deallocation of allocatable scalars.
	* trans-array.c (structure_alloc_comps): Call it here ...
	* trans-decl.c (gfc_trans_deferred_vars): ... here ...
	* trans-stmt.c (gfc_trans_deallocate): ... and here.

2010-10-26  Janus Weil  <janus@gcc.gnu.org>

	PR fortran/42647
	* gfortran.dg/allocatable_scalar_9.f90: Extended.
	* gfortran.dg/allocatable_scalar_10.f90: New.
	* gfortran.dg/class_19.f03: Extended.

From-SVN: r165973
2010-10-26 19:38:42 +02:00
Jan Hubicka
530f3a1bf6 re PR lto/45736 (ICE: in cgraph_remove_unreachable_nodes, at ipa.c:245 with -flto and attribute((constructor)))
PR middle-end/45736
	* cgraph.c (cgraph_set_readonly_flag): Rename to...
	(cgraph_set_const_flags) ... this one; get also looping argument;
	clear constructor/destructor flags.
	(cgraph_set_pure_flag): Likewise.
	(cgraph_set_looping_const_or_pure_flag): Remove.
	(cgraph_can_remove_if_no_direct_calls_and_refs): Do not try
	to optimize away static ctors/dtors; it does not work on inline clones;
	external functions can always be rmeoved.
	(cgraph_will_be_removed_from_program_if_no_direct_calls): Assert on inline
	clones; in LTO external functions always can go.
	(cgraph_used_from_object_file_p): Handle EXTERNAL functions correctly.
	(cgraph_mark_address_taken_node): Assert that we are not taking address of
	inline clone.
	(cgraph_can_remove_if_no_direct_calls_p): We always eventually remove
	external functions.
	* ipa-cp.c (ipcp_cloning_candidate_p): Do not clone functions with address taken.
	(ipcp_initialize_node_lattices): Only local functions can be handled without cloning.
	* cgraph.h (cgraph_set_readonly_flag,
	cgraph_set_looping_const_or_pure_flag): Remove.
	(cgraph_set_const_flag): Declare.
	(cgraph_set_pure_flag): Update.
	* ipa-pure-const (propagate_pure_const, local_pure_const): Update
	flags setting code.
	* ipa.c (cgraph_remove_unreachable_nodes): Fix formating; do not look at inline
	clones; fix handling of external definitions.
	(cgraph_postorder): Do not look at inline clones in the first pass.
	(function_and_variable_visibility): Drop constructors/destructor
	flags at pure and const functions.
	* tree-profile.c (tree_profiling): Update.
	* ipa-inline.c (cgraph_clone_inlined_nodes): Always clone functions with
	address taken; external functions do not account to whole program size.
	(cgraph_decide_inlining): Likewise; do not try to inline functions already
	inlined.
	* testsuite/gcc.dg/lto/pr45736_0.c: New function.

From-SVN: r165972
2010-10-26 16:40:16 +00:00
Jie Zhang
0d600fce5b invoke.texi: Improve documentation of -fstrict-volatile-bitfields.
* doc/invoke.texi: Improve documentation of
	-fstrict-volatile-bitfields.

From-SVN: r165971
2010-10-26 16:13:04 +00:00
Ira Rosen
75264e61bd re PR tree-optimization/46167 (ICE: SIGSEGV in flow_bb_inside_loop_p (cfgloop.c:776) with -O -ftree-vectorize)
PR tree-optimization/46167
	* tree-vect-patterns.c (vect_recog_dot_prod_pattern): Check that there
	is basic block for the statement.

From-SVN: r165970
2010-10-26 15:53:28 +00:00
Jason Merrill
883fff6cf7 * tree.c (stabilize_expr): Handle xvalues properly.
From-SVN: r165969
2010-10-26 11:02:54 -04:00
Jason Merrill
2dfa30b4c8 * call.c (build_over_call): Use argarray[0] for 'this' argument.
From-SVN: r165968
2010-10-26 11:02:47 -04:00
Jason Merrill
d70a517942 * decl.c (finish_function): Don't look at function_depth.
From-SVN: r165967
2010-10-26 11:02:39 -04:00
Paul Koning
6e2f8c15bc pdp11.c (pdp11_f_format, [...]): Update to current definition of struct_real_format.
* config/pdp11/pdp11.c (pdp11_f_format, pdp11_d_format): Update to
current definition of struct_real_format.

From-SVN: r165966
2010-10-26 11:00:54 -04:00
H.J. Lu
f28e93a8a5 Properly align parameters on stack for x86.
gcc/

2010-10-26  H.J. Lu  <hongjiu.lu@intel.com>

	PR target/44948
	* config/i386/i386.c (ix86_old_function_arg_boundary): New.
	(ix86_function_arg_boundary): Always align parameters on stack
	in 64bit and align parameters with alignment >= 16byte on stack 
	in 32bit.  Warn alignment change.

gcc/testsuite/

2010-10-26  H.J. Lu  <hongjiu.lu@intel.com>

	PR target/44948
	* g++.dg/abi/param2.C: Add -Wno-psabi for ilp32 x86.
	* g++.dg/vect/pr33860a.cc: Likewise.
	* gcc.c-torture/compile/20070522-1.c: Likewise.
	* gcc.dg/compat/struct-align-1_x.c: Likewise.
	* gcc.dg/compat/struct-align-1_y.c: Likewise.
	* gcc.dg/compat/struct-align-2_x.c: Likewise.
	* gcc.dg/compat/struct-align-2_y.c: Likewise.
	* gcc.dg/pr44136.c: Likewise.

	* gcc.c-torture/compile/pr33617.c: Add -Wno-psabi for x86.
	* gcc.dg/compat/vector-1_x.c: Likewise.
	* gcc.dg/compat/vector-1_y.c: Likewise.
	* gcc.dg/compat/vector-2_x.c: Likewise.
	* gcc.dg/compat/vector-2_y.c: Likewise.
	* gcc.dg/pr43300.c: Likewise.

	* gcc.dg/compat/vector-1a_x.c: Add -Wno-psabi.
	* gcc.dg/compat/vector-1a_y.c: Likewise.
	* gcc.dg/compat/vector-1b_x.c: Likewise.
	* gcc.dg/compat/vector-1b_y.c: Likewise.
	* gcc.dg/compat/vector-2a_x.c: Likewise.
	* gcc.dg/compat/vector-2a_y.c: Likewise.
	* gcc.dg/compat/vector-2b_x.c: Likewise.
	* gcc.dg/compat/vector-2b_y.c: Likewise.
	* gcc.target/i386/pr39162.c: Likewise.
	* gcc.target/i386/pr40906-2.c: Likewise.
	* gcc.target/i386/sse-5.c: Likewise.

	* gcc.dg/pr35442.c: Prune ABI change warnings.

	* gcc.c-torture/execute/pr38151.x: New.
	* gcc.target/i386/pr44948-1a.c: Likewise.
	* gcc.target/i386/pr44948-1b.c: Likewise.
	* gcc.target/i386/pr44948-2a.c: Likewise.
	* gcc.target/i386/pr44948-2b.c: Likewise.

From-SVN: r165965
2010-10-26 06:56:42 -07:00
Ian Lance Taylor
76d8a30aaf re PR middle-end/45687 (possible wrong code bug)
gcc/:
	PR middle-end/45687
	* ipa-prop.c (ipa_modify_call_arguments): Correct type of MEM_REF
	offset.
gcc/testsuite:
	* gcc.c-torture/execute/20101025-1.c: New test.

From-SVN: r165964
2010-10-26 13:39:37 +00:00
Arnaud Charlet
7675ad4f6a [multiple changes]
2010-10-26  Robert Dewar  <dewar@adacore.com>

	* exp_ch5.adb, exp_prag.adb, sem_ch3.adb, exp_atag.adb, layout.adb,
	sem_dist.adb, exp_ch7.adb, exp_util.adb, exp_attr.adb, exp_ch9.adb,
	sem_ch10.adb, checks.adb, sem_prag.adb, par-endh.adb, sem_ch12.adb,
	exp_smem.adb, sem_attr.adb, exp_ch4.adb, exp_ch6.adb, exp_ch8.adb,
	sem_ch6.adb, exp_disp.adb, exp_aggr.adb, exp_dist.adb, sem_ch13.adb,
	par-ch3.adb, par-ch5.adb, exp_strm.adb, exp_ch3.adb: Minor reformatting
	* opt.ads: Minor comment fix.

2010-10-26  Vincent Celier  <celier@adacore.com>

	* gnat_ugn.texi: Document option -s for gnatlink.

From-SVN: r165963
2010-10-26 15:20:47 +02:00
Robert Dewar
dc718e52b9 opt.ads: Move documentation on checksum stuff here from prj-nmsc
2010-10-26  Robert Dewar  <dewar@adacore.com>

	* opt.ads: Move documentation on checksum stuff here from prj-nmsc
	* prj-nmsc.adb (Process_Project_Level_Array_Attributes): Move
	documentation on checksum versions to opt.ads.

From-SVN: r165962
2010-10-26 15:17:23 +02:00
Vincent Celier
b251750b22 opt.ads (Checksum_Accumulate_Token_Checksum): New Boolean flag, defaulted to True.
2010-10-26  Vincent Celier  <celier@adacore.com>

	* opt.ads (Checksum_Accumulate_Token_Checksum): New Boolean flag,
	defaulted to True.
	(Checksum_GNAT_6_3): New name of Old_Checksums
	(Checksum_GNAT_5_03): New name of Old_Old_Checksums
	* prj-nmsc.adb (Process_Project_Level_Array_Attributes): Adapt to new
	names of Opt flags.
	Set Checksum_Accumulate_Token_Checksum to False if GNAT version is 5.03
	or before.
	* scng.adb (Accumulate_Token_Checksum_GNAT_6_3): New name of procedure
	Accumulate_Token_Checksum_Old.
	(Accumulate_Token_Checksum_GNAT_5_03): New name of procedure
	Accumulate_Token_Checksum_Old_Old.
	(Nlit): Call Accumulate_Token_Checksum only if
	Opt.Checksum_Accumulate_Token_Checksum is True.
	(Scan): Ditto

From-SVN: r165961
2010-10-26 15:15:05 +02:00
Robert Dewar
f2264ac2cd sem_ch13.adb (Build_Invariant_Procedure): New calling sequence.
2010-10-26  Robert Dewar  <dewar@adacore.com>

	* sem_ch13.adb (Build_Invariant_Procedure): New calling sequence.
	(Build_Invariant_Procedure): Properly handle analysis of invariant
	expression with proper end-of-visible-decls visibility.
	* sem_ch13.ads (Build_Invariant_Procedure): Changed calling sequence.
	* sem_ch3.adb (Process_Full_View): Don't build invariant procedure
	(too late).
	(Analyze_Private_Extension_Declaration): Propagate invariant flags.
	* sem_ch7.adb (Analyze_Package_Specification): Build invariant
	procedures.

From-SVN: r165960
2010-10-26 15:12:34 +02:00
Vincent Celier
1ce9dff334 opt.ads (Old_Checksums, [...]): New Boolean flags, defaulted to False.
2010-10-26  Vincent Celier  <celier@adacore.com>

	* opt.ads (Old_Checksums, Old_Old_Checksums): New Boolean flags,
	defaulted to False.
	* prj-nmsc.adb (Process_Project_Level_Array_Attributes): When
	processing attribute Toolchain_Version ("Ada"), set Opt.Old_Checksums
	and Opt.Old_Old_Checksums depending on the GNAT version.
	* scng.adb (Accumulate_Token_Checksum_Old): New procedure.
	(Accumulate_Token_Checksum_Old_Old): New procedure.
	(Scan): For keywords, when Opt.Old_Checksums is True, call one of the
	alternative procedures Accumulate_Token_Checksum_Old or
	Accumulate_Token_Checksum_Old_Old, instead of Accumulate_Token_Checksum.

From-SVN: r165959
2010-10-26 15:08:59 +02:00
Richard Kenner
39ab2e8fc9 utils2.c (build_compound_expr): New function.
2010-10-26  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>

	* gcc-interface/utils2.c (build_compound_expr): New function.
	* gcc-interface/gigi.h (build_compound_expr): Declare it.
	* gcc-interface/trans.c (Attribute_to_gnu, call_to_gnu): Use it.
	(gnat_to_gnu, case N_Expression_With_Actions): Likewise.

From-SVN: r165958
2010-10-26 15:06:34 +02:00
Arnaud Charlet
0592046e23 [multiple changes]
2010-10-26  Javier Miranda  <miranda@adacore.com>

	* sem_prag.adb (Process_Import_Or_Interface): Skip primitives of
	interface types when processing all the entities in the homonym chain
	that are declared in the same declarative part.

2010-10-26  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch3.adb (Process_Range_In_Decl): If the range is part of a
	quantified expression, the insertion point for range checks will be
	arbitrarily far in the tree.
	* sem_ch5.adb (One_Bound): Use Insert_Actions for the declaration of
	the temporary that holds the value of the bounds.
	* sem_res.adb (Resolve_Quantified_Expressions): Disable expansion of
	condition until the full expression is expanded.

From-SVN: r165957
2010-10-26 15:05:30 +02:00
Arnaud Charlet
880dabb586 [multiple changes]
2010-10-26  Robert Dewar  <dewar@adacore.com>

	* opt.ads: Comment fix.
	* sem_cat.adb: Treat categorization errors as warnings in GNAT Mode.
	* switch-c.adb: GNAT Mode does not set
	Treat_Categorization_Errors_As_Warnings.

2010-10-26  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch8.adb (Analyze_Subprogram_Renaming): Improve warning when an
	operator renames another one with a different name.

2010-10-26  Thomas Quinot  <quinot@adacore.com>

	* exp_ch4.adb, exp_pakd.adb: Minor reformatting.

From-SVN: r165956
2010-10-26 15:00:05 +02:00
Arnaud Charlet
3923140473 [multiple changes]
2010-10-26  Robert Dewar  <dewar@adacore.com>

	* exp_ch3.adb: Fix typo, comment updates.
	* namet.adb: Minor comment additions.
	* einfo.ads: Minor comment update.

2010-10-26  Javier Miranda  <miranda@adacore.com>

	* einfo.adb (Set_Dispatch_Table_Wrappers): Complete the assertion.

2010-10-26  Robert Dewar  <dewar@adacore.com>

	* par.adb, par-ch13.adb (Aspect_Specifications_Present): Add Strict
	parameter.

From-SVN: r165955
2010-10-26 14:56:43 +02:00
Arnaud Charlet
329b9f810d [multiple changes]
2010-10-26  Bob Duff  <duff@adacore.com>

	* namet.adb: Improve hash function.
	Increase the size from 2**12 to 2**16 buckets.

2010-10-26  Thomas Quinot  <quinot@adacore.com>

	* sem_disp.adb: Minor reformatting.

From-SVN: r165954
2010-10-26 14:53:09 +02:00
Robert Dewar
878f708aba sem_ch3.adb, [...]: Minor reformatting.
2010-10-26  Robert Dewar  <dewar@adacore.com>

	* sem_ch3.adb, sem_ch4.adb, sem_disp.adb, switch-c.adb: Minor
	reformatting.
	* gnat_ugn.texi: Document -gnateP switch.

From-SVN: r165953
2010-10-26 14:48:29 +02:00