117785 Commits

Author SHA1 Message Date
Hans-Peter Nilsson
f0df84ab4a re PR rtl-optimization/53908 (csa removes needed memory load)
PR rtl-optimization/53908
	* gcc.dg/torture/pr53908.c: New test.

From-SVN: r189455
2012-07-13 08:58:46 +00:00
Richard Sandiford
b1435931f2 re PR rtl-optimization/53908 (csa removes needed memory load)
PR rtl-optimization/53908
	* df-problems.c (can_move_insns_across): When doing
	memory-reference book-keeping, handle call insns.

Co-Authored-By: Bernd Schmidt <bernds@codesourcery.com>
Co-Authored-By: Steven Bosscher <steven@gcc.gnu.org>

From-SVN: r189454
2012-07-13 08:53:24 +00:00
Richard Guenther
a2faea4bda gimple.c (gimple_types_compatible_p_1): Remove redundant type attribute comparisons.
2012-07-13  Richard Guenther  <rguenther@suse.de>

	* gimple.c (gimple_types_compatible_p_1): Remove redundant
	type attribute comparisons.
	(gimple_canonical_types_compatible_p): Likewise.

From-SVN: r189453
2012-07-13 08:15:10 +00:00
Jonathan Wakely
306620d224 re PR c++/53531 (<,,,,> accepted as template arguments for variadic template)
PR c++/53531
	* testsuite/g++.dg/cpp0x/variadic135.C: New.

From-SVN: r189452
2012-07-13 08:53:12 +01:00
GCC Administrator
4817d854f1 Daily bump.
From-SVN: r189448
2012-07-13 00:16:42 +00:00
Jason Merrill
b52259e162 pt.c (instantiate_decl): Check typedefs access here.
* pt.c (instantiate_decl): Check typedefs access here.
	(instantiate_template_1): Not here.

From-SVN: r189444
2012-07-12 18:57:16 -04:00
Jason Merrill
77a24503cb pt.c (deduction_tsubst_fntype): Just suppress access checking.
* pt.c (deduction_tsubst_fntype): Just suppress access checking.
	(instantiate_template_1): Set DECL_TI_TEMPLATE before access checking.
	(push_deduction_access_scope, pop_deduction_access_scope): Remove.

From-SVN: r189443
2012-07-12 18:57:03 -04:00
Tobias Burnus
0d87d3076f trans-expr.c (conv_isocbinding_procedure): Generate
2012-07-12  Tobias Burnus  <burnus@net-b.de>

        * trans-expr.c (conv_isocbinding_procedure): Generate
        * c_f_pointer code
        inline.

2012-07-12  Tobias Burnus  <burnus@net-b.de>

        * gfortran.dg/c_f_pointer_shape_tests_5.f90: New.
        * gfortran.dg/c_f_pointer_tests_3.f90: Update
        scan-tree-dump-times pattern.

From-SVN: r189442
2012-07-12 23:32:48 +02:00
Hans-Peter Nilsson
e098c16962 re PR rtl-optimization/53176 (gcc.dg/lower-subreg-1.c FAILs)
PR rtl-optimization/53176
	* rtlanal.c (rtx_cost): Adjust default cost for X with a
	UNITS_PER_WORD factor for all X according to the size of
	its mode, not just for SUBREGs with untieable modes.
	Handle SET.  Use factor * factor for MULT, DIV, UDIV,
	MOD, UMOD.

From-SVN: r189441
2012-07-12 21:14:14 +00:00
Uros Bizjak
8c15b4b04f i386.md (QImode and HImode cmove splitters): Merge QImode and HImode splitters.
* config/i386/i386.md (QImode and HImode cmove splitters): Merge
	QImode and HImode splitters.  Use ix86_comparison_operator.
	Explicitly match FLAGS_REG.
	(DFmode cmove splitter): Explicitly match FLAGS_REG.

From-SVN: r189440
2012-07-12 18:18:09 +02:00
Arnaud Charlet
759658521a [multiple changes]
2012-07-12  Vasiliy Fofanov  <fofanov@adacore.com>

	* vms_data.ads: Add VMS qualifiers for -gnatn1/2 switches.

2012-07-12  Thomas Quinot  <quinot@adacore.com>

	* exp_ch5.adb, exp_pakd.adb, rtsfind.ads, freeze.adb, sem_util.adb,
	sem_util.ads, exp_aggr.adb
	(Exp_Aggr.Packed_Array_Aggregate_Handled): Simplify processing
	for reverse storage order aggregate.
	(Exp_Pakd.Byte_Swap): New utility routine used by...
	(Exp_Pakd.Expand_Bit_Packed_Element_Set,
	Expand_Packed_Element_Reference): For the case of a free-standing
	packed array with reverse storage order, perform byte swapping.
	(Rtsfind): Make new entities RE_Bswap_{16,32,64} available.
	(Freeze.Check_Component_Storage_Order): New utility routine
	to enforce legality rules for nested composite types whose
	enclosing composite has an explicitly defined Scalar_Storage_Order
	attribute.
	(Sem_Util.In_Reverse_Storage_Order_Object): Renamed from
	Sem_Util.In_Reverse_Storage_Order_Record, as SSO now applies to
	array types as well.
	(Exp_Ch5.Expand_Assign_Array): Remove now unnecessary kludge
	for change of scalar storage order in assignments. The Lhs and
	Rhs now always have the same scalar storage order.

2012-07-12  Hristian Kirtchev  <kirtchev@adacore.com>

	* g-debpoo.adb (Allocate): Add local constant
	No_Element. Initialize the allocated memory chunk to No_Element.

2012-07-12  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch12.adb (Validate_Derived_Type_Instance): Handle properly
	the case of an instance of a child unit where a formal derived
	type DT is an extension of a type T declared in a parent unit,
	and the actual in the instance of the child is the type T declared
	in the parent instance, and that actual is not a derived type.

2012-07-12  Eric Botcazou  <ebotcazou@adacore.com>
	    Tristan Gingold  <gingold@adacore.com>

	* system-hpux-ia64.ads: Enable ZCX by default.
	* gcc-interface/Makefile.in: Use alternate stack on ia64-hpux.
	Change soext to .so.

From-SVN: r189439
2012-07-12 12:56:02 +02:00
Arnaud Charlet
727e7b1a87 [multiple changes]
2012-07-12  Robert Dewar  <dewar@adacore.com>

	* s-atopri.adb, s-atopri.ads: Minor reformatting.

2012-07-12  Robert Dewar  <dewar@adacore.com>

	* ali.adb: Add circuitry to read new named form of restrictions lines.
	* debug.adb: Add doc for new -gnatd.R switch (used positional
	notation for output of restrictions data in ali file).
	* lib-writ.adb: Implement new named format for restrictions lines.
	* lib-writ.ads: Add documentation for new named format for
	restrictions in ali files.
	* restrict.adb, restrict.ads, sem_prag.adb: Update comments.
	* rident.ads: Go back to withing System.Rident
	* s-rident.ads: Add extensive comment on dealing with consistency
	checking.

2012-07-12  Thomas Quinot  <quinot@adacore.com>

	* par_sco.adb, scos.ads: Emit detailed SCOs for SELECT statements.

From-SVN: r189438
2012-07-12 12:49:10 +02:00
Arnaud Charlet
03459f403e [multiple changes]
2012-07-12  Robert Dewar  <dewar@adacore.com>

	* sem_disp.adb: Minor reformatting
	* s-bytswa.ads: Minor comment update.

2012-07-12  Vincent Pucci  <pucci@adacore.com>

	* exp_ch9.adb (Build_Lock_Free_Unprotected_Subprogram_Body):
	Atomic_Load_N replaced by Lock_Free_Read_N. Atomic_Compare_Exchange_N
	replaced by Lock_Free_Try_Write_N.
	Renaming of several local variables. For
	procedure, Expected_Comp declaration moved to the declaration
	list of the procedure.
	* rtsfind.ads: RE_Atomic_Compare_Exchange_8,
	RE_Atomic_Compare_Exchange_16, RE_Atomic_Compare_Exchange_32,
	RE_Atomic_Compare_Exchange_64, RE_Atomic_Load_8,
	RE_Atomic_Load_16, RE_Atomic_Load_32, RE_Atomic_Load_64,
	RE_Atomic_Synchronize, RE_Relaxed removed.  RE_Lock_Free_Read_8,
	RE_Lock_Free_Read_16, RE_Lock_Free_Read_32, RE_Lock_Free_Read_64,
	RE_Lock_Free_Try_Write_8, RE_Lock_Free_Try_Write_16,
	RE_Lock_Free_Try_Write_32, RE_Lock_Free_Try_Write_64 added.
	* s-atopri.adb: New file.
	* s-atopri.ads (Atomic_Compare_Exchange_8): Renaming of
	parameters.  Import primitive __sync_val_compare_and_swap_1.
	(Atomic_Compare_Exchange_16): Renaming of parameters.
	Import primitive __sync_val_compare_and_swap_2.
	(Atomic_Compare_Exchange_32): Renaming of parameters.
	Import primitive __sync_val_compare_and_swap_4.
	(Atomic_Compare_Exchange_64): Renaming of parameters.  Import
	primitive __sync_val_compare_and_swap_8.
	(Atomic_Load_8): Ptr renames parameter X.
	(Atomic_Load_16): Ptr renames parameter X.
	(Atomic_Load_32): Ptr renames parameter X.
	(Atomic_Load_64): Ptr renames parameter X.
	(Lock_Free_Read_8): New routine.
	(Lock_Free_Read_16): New routine.
	(Lock_Free_Read_32): New routine.
	(Lock_Free_Read_64): New routine.
	(Lock_Free_Try_Write_8): New routine.
	(Lock_Free_Try_Write_16): New routine.
	(Lock_Free_Try_Write_32): New routine.
	(Lock_Free_Try_Write_64): New routine.

From-SVN: r189437
2012-07-12 12:43:18 +02:00
Arnaud Charlet
8926d36939 [multiple changes]
2012-07-12  Robert Dewar  <dewar@adacore.com>

	* exp_attr.adb, exp_ch9.adb, sem_ch9.adb, exp_aggr.adb: Minor
	reformatting.

2012-07-12  Vincent Pucci  <pucci@adacore.com>

	* sem_dim.adb (Analyze_Dimension_Function_Call): Reformatting of error
	msgs for elementary functions.

2012-07-12  Vincent Pucci  <pucci@adacore.com>

	* sem_attr.adb (Eval_Attribute): Minor reformatting.

2012-07-12  Pascal Obry  <obry@adacore.com>

	* prj-nmsc.adb (Check_Library_Attributes): Allow the same library
	project in different project tree (different aggregated projects).

2012-07-12  Thomas Quinot  <quinot@adacore.com>

	* s-bytswa.adb, g-bytswa.adb, g-bytswa.ads, s-bytswa.ads: Further
	reorganization of byte swapping routines.

2012-07-12  Ed Schonberg  <schonberg@adacore.com>

	* sem_disp.adb (Check_Dispatching_Context): Refine legality
	checks on tagg indeterminate calls to abstract operations,
	that appear in the context of other calls.

From-SVN: r189436
2012-07-12 12:37:17 +02:00
Arnaud Charlet
1e4b91fc4f [multiple changes]
2012-07-12  Thomas Quinot  <quinot@adacore.com>

	* s-bytswa.adb (Swapped2.Bswap16): Remove local function,
	no longer needed.

2012-07-12  Javier Miranda  <miranda@adacore.com>

	* exp_attr.adb (Expand_N_Attribute_Reference): For
	attributes 'access, 'unchecked_access and 'unrestricted_access,
	iff the current instance reference is located in a protected
	subprogram or entry then rewrite the access attribute to be the
	name of the "_object" parameter.

2012-07-12  Tristan Gingold  <gingold@adacore.com>

	* raise.h: Revert previous patch: structure is used in init.c
	by vms.

2012-07-12  Vincent Celier  <celier@adacore.com>

	* make.adb (Binding_Phase): If --subdirs was used, but not
	-P, change the working directory to the specified subdirectory
	before invoking gnatbind.
	(Linking_Phase): If --subdirs was used, but not -P, change the working
	directory to the specified subdirectory before invoking gnatlink.

2012-07-12  Vincent Pucci  <pucci@adacore.com>

	* exp_ch9.adb (Build_Lock_Free_Unprotected_Subprogram_Body):
	For a procedure, instead of replacing each Comp reference by a
	reference to Current_Comp, make a renaming Comp of Current_Comp
	that rewrites the original renaming generated by the compiler
	during the analysis. Move the declarations of the procedure
	inside the generated block.
	(Process_Stmts): Moved in the body
	of Build_Lock_Free_Unprotected_Subprogram_Body.
	(Process_Node):
	Moved in the body of Build_Lock_Free_Unprotected_Subprogram_Body.
	* sem_ch9.adb (Allows_Lock_Free_Implementation): Restrict any
	non-elementary out parameters in protected procedures.

2012-07-12  Thomas Quinot  <quinot@adacore.com>

	* sem_ch13.adb (Analyze_Attribute_Definition_Clause, case
	Scalar_Storage_Order): Attribute applies to base type only.

From-SVN: r189435
2012-07-12 12:33:23 +02:00
Arnaud Charlet
d9819bbd70 [multiple changes]
2012-07-12  Ed Schonberg  <schonberg@adacore.com>

	* exp_aggr.adb (Convert_To_Positional): Increase acceptable size
	of static aggregate when Static_Elaboration_Desired is requested.
	Add a warning if the request cannot be satisfied either because
	some components or some array bounds are non-static.

2012-07-12  Thomas Quinot  <quinot@adacore.com>

	* exp_pakd.adb: Minor reformatting.

2012-07-12  Tristan Gingold  <gingold@adacore.com>

	* tracebak.c: Fix warnings.
	* raise-gcc.c (__gnat_adjust_context): New function
	(__gnat_personality_seh0): Call __gnat_adjust_context to adjust
	PC in machine frame for exceptions that occur in the current
	function.

2012-07-12  Thomas Quinot  <quinot@adacore.com>

	* g-bytswa.adb, g-bytswa.ads, s-bytswa.adb, s-bytswa.ads, Makefile.rtl:
	Move GNAT.Byte_Swapping to System (with a renaming under GNAT)
	so that it is usable in expanded code.

2012-07-12  Tristan Gingold  <gingold@adacore.com>

	* s-osinte-hpux.ads: Increase alternate stack size on hpux.

From-SVN: r189434
2012-07-12 12:30:29 +02:00
Arnaud Charlet
2ed5b74848 [multiple changes]
2012-07-12  Javier Miranda  <miranda@adacore.com>

	* exp_ch3.adb (Make_Neq_Body): Fix typo in comment.

2012-07-12  Eric Botcazou  <ebotcazou@adacore.com>

	* tb-gcc.c (trace_callback): On IA-64/HP-UX, use workaround only
	if USE_LIBUNWIND_EXCEPTIONS is defined.
	* init.c: Further tweaks for IA-64/HP-UX.

2012-07-12  Tristan Gingold  <gingold@adacore.com>

	* raise-gcc.c: Do not include unwind-dw2-fde.h. Adjust comments.
	(db_region_for): Second argument is ip.  Do not recompute ip.
	(action_kind): Remove typedef, add unhandler enum const.
	(action_descriptor): Adjust type of kind field.
	(db_action_for): Second argument is ip, do not recompute it.
	(get_call_site_action_for): First argument is call_site, do not
	recompute it.  Remove useless return.
	(is_handled_by): Now return enum action_kind.
	Handle GNAT_ALL_OTHERS first.
	Return unhandler for GNAT_UNHANDLED_OTHERS.
	(get_action_description_for): First argument is now ip, do not
	recompute it.  Adjust code for call to is_handled_by.
	(__gnat_notify_unhandled_exception): Add prototype.
	(PERSONALITY_FUNCTION): Call get_ip_from_context.  Adjust calls.
	Handle unhandler case.
	(__gnat_cleanupunwind_handler): Add comments, add
	ATTRIBUTE_UNUSED on arguments.
	(__gnat_Unwind_RaiseException, __gnat_Unwind_ForcedUnwind): Define
	only once.
	* raise.h: Makes struct Exception_Data opaque.

From-SVN: r189433
2012-07-12 12:24:41 +02:00
Arnaud Charlet
cd20e505e7 [multiple changes]
2012-07-12  Robert Dewar  <dewar@adacore.com>

	* make.adb, sem_ch9.adb, prj.adb, s-rident.ads, snames.ads-tmpl: Minor
	reformatting.

2012-07-12  Javier Miranda  <miranda@adacore.com>

	* exp_ch3.adb (Is_User_Defined_Equality): New subprogram.
	(Make_Neq_Body): New subprogram.
	(Make_Predefined_Primitive_Specs): Adding local variable
	Has_Predef_Eq_ Renaming to ensure that we enable the machinery
	which handles renamings of predefined primitive operators.

From-SVN: r189432
2012-07-12 12:19:13 +02:00
GCC Administrator
381ec0f4cd Daily bump.
From-SVN: r189431
2012-07-12 00:16:54 +00:00
Steven Bosscher
53cd1f8025 java-tree.h (force_evaluation_order): Remove prototype.
* java-tree.h (force_evaluation_order): Remove prototype.
	* expr.c (force_evaluation_order): Remove unused function.

From-SVN: r189428
2012-07-11 22:54:34 +00:00
Rainer Orth
b3c90d54a2 Allow for / comments in g++.dg/debug/dwarf2/pubnames-2.C
* g++.dg/debug/dwarf2/pubnames-2.C: Allow for / comments.

From-SVN: r189427
2012-07-11 15:09:41 +00:00
Jason Merrill
45ffb6f743 DR 1402
DR 1402
	* method.c (synthesized_method_walk): Replace uses of msg with diag.
	Correct handling of virtual bases with move operations.
	(process_subob_fn, walk_field_subobs): Replace uses of msg with diag.

From-SVN: r189426
2012-07-11 07:53:23 -04:00
Steven Bosscher
6bdf351944 expr.h (can_move_by_pieces): Move prototype from here ...
gcc/
	* expr.h (can_move_by_pieces): Move prototype from here ...
	* tree.h (can_move_by_pieces): ... to here.
	* optabs.h (set_widening_optab_handler): Use XCNEW.
	* gimplify.c: Do not include expr.h.

	* toplev.c: Do not include dwarf2out.h.
	* config/ia64/ia64.c: Likewise.
	* config/sparc/sparc.c: Likewise.
	* config/sparc/t-sparc (sparc.o): Fix dependencies.

	* Makefile.in (toplev.o): Fix dependencies
	(c-family/c-gimplify.o): Likewise.
	(c-family/c-common.o): Likewise.

c-family/
	* c-gimplify.c: Do not include basic-block.h.
	* c-common.c: Do not include linfuncs.h.

cp/
	* method.c: Do not include tree-pass.h.

fortran/
	* trans.c: Do not include defaults.h.
	* trans-intrinsic.c: Likewise.

java/
	* decl.c: Do not include libfuncs.h.
	* class.c: Do not include defaults.h.
	* jvgenmain.c: Likewise.
	* magnle.c: Likewise.
	* Make-lang.in (decl.o): Fix dependencies.

From-SVN: r189425
2012-07-11 08:58:58 +00:00
Steven Bosscher
b8244d74e1 basic-block.h (struct edge_def): Use basic_block instead of basic_block_def *.
* basic-block.h (struct edge_def): Use basic_block instead of
	basic_block_def *.
	* cfgloop.h (struct loop_exit, struct loop): Likewise.
	* gengenrtl.c (type_from_format): Likewise.  Also for 'tree'
	instead of union tree_node *.
	* rtl.h (union rtunion_def, emit_insn_before_noloc,
	emit_insn_after_noloc, add_insn_before, add_insn_after,
	debug_bb_slim): Likewise.
	* tree-inline.h (struct copy_body_data): Likewise.
	* sched-rgn.c (dump_region_dot): Likewise.
	* gimple.h (struct gimple_statement_base, gimple_set_bb,
	gsi_move_to_bb_end): Likewise.
	* sched-vis.c (debug_bb_slim): Likewise.
	(debug_bb_n_slim): Likewise.
	* config/mn10300/mn10300.c (mn10300_insert_setlb_lcc): Likewise.
	(mn10300_block_contains_call):

From-SVN: r189424
2012-07-11 08:46:17 +00:00
Greta Yorsh
c48acc4f0a re PR target/53859 (ICE when calculate insn latency for armv7e-m arch in O2 level)
2012-07-10  Greta Yorsh  <Greta.Yorsh@arm.com>

gcc/
	PR target/53859
	* config/arm/arm.c (arm_early_load_addr_dep): Handle new
	epilogue patterns.

gcc/testsuite

	PR target/53859
	* gcc.target/arm/pr53859.c: New test.

From-SVN: r189423
2012-07-11 09:41:37 +01:00
Jonathan Wakely
b0af456aad * doc/extend.texi (Namespace Association): Alter cautionary text.
From-SVN: r189422
2012-07-11 07:51:26 +01:00
GCC Administrator
2ece515aa0 Daily bump.
From-SVN: r189420
2012-07-11 00:19:30 +00:00
Oleg Endo
b6d1033531 re PR target/53886 (Seg fault in sh_insn_length_adjustment)
PR target/53886
	* gcc.c-torture/compile/pr53886.c: New.

From-SVN: r189417
2012-07-10 22:07:29 +00:00
Oleg Endo
c03cfe1eee re PR target/53911 ([SH] Improve displacement addressing)
PR target/53911
	* config/sh/sh.md: Remove displacement addresssing related splits.

From-SVN: r189416
2012-07-10 22:01:44 +00:00
Xinliang David Li
87e2a8fd39 Implement -freuse-stack= option
From-SVN: r189413
2012-07-10 20:26:38 +00:00
Julian Brown
2f01137541 arm.md (movsi): Don't split symbol refs here.
2012-07-10  Julian Brown  <julian@codesourcery.com>

	* config/arm/arm.md (movsi): Don't split symbol refs here.
	(define_split): New.

From-SVN: r189411
2012-07-10 17:15:26 +04:00
Andreas Schwab
175aed0045 re PR bootstrap/53913 (resource.c:1179:5: error: 'current_function_decl' undeclared broke m68k bootstrap)
PR bootstrap/53913
* config/m68k/m68k.c (m68k_epilogue_uses): New.
* config/m68k/m68k.h (EPILOGUE_USES): Use it.
* config/m68k/m68k-protos.h (m68k_epilogue_uses): Add prototype.

From-SVN: r189410
2012-07-10 11:48:00 +00:00
Richard Henderson
30a7bac96d Zap now unused builtin_mul_widen_even/odd target hooks
* target.def (builtin_mul_widen_even, builtin_mul_widen_odd): Remove.
        * system.h (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_EVEN): Poison.
        (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_ODD): Poison.
        * config/i386/i386.c (IX86_BUILTIN_VEC_WIDEN_SMUL_ODD_V4SI): Remove.
        (IX86_BUILTIN_VEC_WIDEN_SMUL_ODD_V8SI): Remove.
        (IX86_BUILTIN_VEC_WIDEN_UMUL_ODD_V4SI): Remove.
        (IX86_BUILTIN_VEC_WIDEN_UMUL_ODD_V8SI): Remove.
        (IX86_BUILTIN_VEC_WIDEN_SMUL_EVEN_V4SI): Remove.
        (IX86_BUILTIN_VEC_WIDEN_UMUL_EVEN_V4SI): Remove.
        (IX86_BUILTIN_VEC_WIDEN_UMUL_EVEN_V8SI): Remove.
        (bdesc_args): Remove entries to match.
        (ix86_builtin_mul_widen_even, ix86_builtin_mul_widen_odd): Remove.
        (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_EVEN): Remove.
        (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_ODD): Remove.
        * config/rs6000/rs6000.c (rs6000_builtin_mul_widen_even): Remove.
        (rs6000_builtin_mul_widen_odd): Remove.
        (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_EVEN): Remove.
        (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_ODD): Remove.
        * config/spu/spu.c (spu_builtin_mul_widen_even): Remove.
        (spu_builtin_mul_widen_odd): Remove.
        (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_EVEN): Remove.
        (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_ODD): Remove.
        * doc/tm.texi.in: Don't document the removed hooks.

From-SVN: r189409
2012-07-10 01:26:00 -07:00
Richard Henderson
6ae6116f19 Use VEC_WIDEN_MULT_EVEN/ODD_EXPR in supportable_widening_operation
* tree-vect-stmts.c (supportable_widening_operation): Expand
        WIDEN_MULT_EXPR via VEC_WIDEN_MULT_EVEN/ODD_EXPR if possible.

From-SVN: r189408
2012-07-10 01:25:39 -07:00
Richard Henderson
00f07b86e7 Move vector highpart emulation to the optabs layer
* expmed.c (expmed_mult_highpart): Rename from expand_mult_highpart.
        (expmed_mult_highpart_optab): Rename from expand_mult_highpart_optab.
        * optabs.c (can_mult_highpart_p): New.
        (expand_mult_highpart): New.
        * expr.c (expand_expr_real_2) [MULT_HIGHPART_EXPR): Use it.
        * tree-vect-generic.c (expand_vector_operations_1): Don't expand
        by pieces if can_mult_highpart_p.
        (expand_vector_divmod): Use can_mult_highpart_p and always
        generate MULT_HIGHPART_EXPR.
        * tree-vect-patterns.c (vect_recog_divmod_pattern): Likewise.
        * tree-vect-stmts.c (vectorizable_operation): Likewise.

From-SVN: r189407
2012-07-10 01:25:20 -07:00
Richard Henderson
9283726f76 spu: Rename patterns for vec_widen_<s>mult_even/odd_<mode>
* config/spu/spu-builtins.md (spu_mpy): Move to spu.md.
        (spu_mpyu, spu_mpyhhu, spu_mpyhh): Likewise.
        * config/spu/spu.md (vec_widen_smult_odd_v8hi): Rename from spu_mpy.
        (vec_widen_umult_odd_v8hi): Rename from spu_mpyu.
        (vec_widen_smult_even_v8hi): Rename from spu_mpyhh.
        (vec_widen_umult_even_v8hi): Rename from spu_mpyhhu.
        * config/spu/spu-builtins.def: Update pattern names to match.

From-SVN: r189406
2012-07-10 01:24:51 -07:00
Richard Henderson
2371eaecd5 rs6000: Rename patterns for vec_widen_<s>mult_even/odd_<mode>
* config/rs6000/altivec.md (vec_widen_umult_even_v16qi): Rename
        from altivec_vmuleub.
        (vec_widen_smult_even_v16qi): Rename from altivec_vmulesb.
        (vec_widen_umult_even_v8hi): Rename from altivec_vmuleuh.
        (vec_widen_smult_even_v8hi): Rename from altivec_vmulesh.
        (vec_widen_umult_odd_v16qi): Rename from altivec_vmuloub.
        (vec_widen_smult_odd_v16qi): Rename from altivec_vmulosb.
        (vec_widen_umult_odd_v8hi): Rename from altivec_vmulouh.
        (vec_widen_smult_odd_v8hi): Rename from altivec_vmulosh.
        * config/rs6000/rs6000-builtin.def: Update pattern names to match.

From-SVN: r189405
2012-07-10 01:24:28 -07:00
Richard Henderson
c6b37fab7b i386: Rename patterns for vec_widen_<s>mult_even/odd_<mode>
* config/i386/sse.md (vec_widen_umult_even_v8si): Rename from
        avx2_umulv4siv4di3.
        (vec_widen_umult_even_v4si): Rename from sse2_umulv2siv2di3.
        (vec_widen_smult_even_v8si): Rename from avx2_mulv4siv4di3.
        (mulv4si3): Remove XOP test shadowed by SSE4 test.
        * config/i386/i386.c (bdesc_args): Update pattern names.
        (ix86_expand_sse2_mulvxdi3): Likewise.
        (ix86_expand_mul_widen_evenodd): Likewise.  Remove XOP test
        shadowed by SSE4 test.

From-SVN: r189404
2012-07-10 01:24:05 -07:00
Richard Henderson
3f30a9a6aa Add VEC_WIDEN_MULT_EVEN/ODD_EXPR
* tree.def (VEC_WIDEN_MULT_EVEN_EXPR, VEC_WIDEN_MULT_ODD_EXPR): New.
        * cfgexpand.c (expand_debug_expr): Handle them.
        * expr.c (expand_expr_real_2): Likewise.
        * fold-const.c (fold_binary_loc): Likewise.
        * gimple-pretty-print.c (dump_binary_rhs): Likewise.
        * optabs.c (optab_for_tree_code): Likewise.
        * tree-cfg.c (verify_gimple_assign_binary): Likewise.
        * tree-inline.c (estimate_operator_cost): Likewise.
        * tree-pretty-print.c (dump_generic_node): Likewise.
        * tree.c (commutative_tree_code): Likewise.
        * tree-vect-generic.c (expand_vector_operations_1): Likewise.
        Handle type change before looking up optab.
        * optabs.h (OTI_vec_widen_umult_even, OTI_vec_widen_umult_odd): New.
        (OTI_vec_widen_smult_even, OTI_vec_widen_smult_odd): New.
        (vec_widen_umult_even_optab, vec_widen_umult_odd_optab): New.
        (vec_widen_smult_even_optab, vec_widen_smult_odd_optab): New.
        * genopinit.c (optabs): Initialize them.
        * doc/md.texi: Document them.

From-SVN: r189403
2012-07-10 01:23:39 -07:00
Dehao Chen
e53a3e778e tree.h (phi_arg_d): New field.
2012-07-10  Dehao Chen  <dehao@google.com>

	* tree.h (phi_arg_d): New field.
	* tree-flow-inline.h (gimple_phi_arg_block): New function.
	(gimple_phi_arg_block_from_edge): New function.
	(gimple_phi_arg_set_block): New function.
	(gimple_phi_arg_has_block): New function.
	(redirect_edge_var_map_block): New function.
	* tree-flow.h (_edge_var_map): New field.
	* tree-ssa-live.c (remove_unused_locals): Mark phi_arg's block
	as used.
	* tree-eh.c (cleanup_empty_eh_merge_phis): Add block debug info for
	redirect_edge_var_map_add.
	* tree-outof-ssa.c (_elim_graph): New field.
	(insert_partition_copy_on_edge): New parameter.
	(insert_value_copy_on_edge): New parameter.
	(insert_rtx_to_part_on_edge): New parameter.
	(insert_part_to_rtx_on_edge): New parameter.
	(elim_graph_add_edge): New parameter.
	(elim_graph_remove_succ_edge): New parameter.
	(FOR_EACH_ELIM_GRAPH_SUCC): New parameter.
	(FOR_EACH_ELIM_GRAPH_PRED): New parameter.
	(new_elim_graph): Add block debug info.
	(clear_elim_graph): Likewise.
	(delete_elim_graph): Likewise.
	(elim_graph_add_node): Likewise.
	(elim_graph_add_edge): Likewise.
	(elim_graph_remove_succ_edge): Likewise.
	(eliminate_build): Likewise.
	(elim_forward): Likewise.
	(elim_unvisited_predecessor): Likewise.
	(elim_backward): Likewise.
	(elim_create): Likewise.
	(eliminate_phi): Likewise.
	(insert_backedge_copies): Likewise.
	* tree-into-ssa.c (insert_phi_nodes_for): Add block debug info for
	add_phi_arg.
	(rewrite_add_phi_arguments): Likewise.
	* tree-ssa-loop-im.c (execute_sm_if_changed): Likewise.
	* tree-ssa-tail-merge.c (replace_block_by): Likewise.
	* tree-ssa-threadupdate.c (copy_phi_args): Likewise.
	* tree-loop-distribution.c (update_phis_for_loop_copy): Likewise.
	* tree-ssa-loop-manip.c (create_iv): Likewise.
	(add_exit_phis_edge): Likewise.
	(split_loop_exit_edge): Likewise.
	(copy_phi_node_args): Likewise.
	(tree_transform_and_unroll_loop): Likewise.
	* value-prof.c (gimple_ic): Likewise.
	(gimple_stringop_fixed_value): Likewise.
	* tree-tailcall.c (add_successor_phi_arg): Likewise.
	(eliminate_tail_call): Likewise.
	(create_tailcall_accumulator): Likewise.
	(tree_optimize_tail_calls_1): Likewise.
	* tree-phinodes.c (add_phi_arg): Likewise.
	(make_phi_node): Likewise.
	(resize_phi_node): Likewise.
	(remove_phi_arg_num): Likewise.
	* omp-low.c (expand_parallel_call): Likewise.
	(expand_omp_for_static_chunk): Likewise.
	* tree-vect-loop-manip.c (slpeel_update_phis_for_duplicate_loop):
	Likewise.
	(slpeel_update_phi_nodes_for_guard1): Likewise.
	(slpeel_update_phi_nodes_for_guard2): Likewise.
	(slpeel_tree_duplicate_loop_to_edge_cfg): Likewise.
	(set_prologue_iterations): Likewise.
	(slpeel_tree_peel_loop_to_edge): Likewise.
	(vect_loop_versioning): Likewise.
	* tree-parloops.c (create_phi_for_local_result): Likewise.
	(transform_to_exit_first_loop): Likewise.
	(create_parallel_loop): Likewise.
	* ipa-split.c (split_function): Likewise.
	* tree-vect-loop.c (get_initial_def_for_induction): Likewise.
	(vect_create_epilog_for_reduction): Likewise.
	* tree-vect-data-refs.c (vect_setup_realignment): Likewise.
	* graphite-scop-detection.c (canonicalize_loop_closed_ssa): Likewise.
	* tree-ssa-phiopt.c (cond_store_replacement): Likewise.
	(cond_if_else_store_replacement_1): Likewise.
	* tree-cfgcleanup.c (remove_forwarder_block): Likewise.
	(remove_forwarder_block_with_phi): Likewise.
	* tree-ssa-pre.c (insert_into_preds_of_block): Likewise.
	* tree-predcom.c (initialize_root_vars): Likewise.
	(initialize_root_vars_lm): Likewise.
	* sese.c (sese_add_exit_phis_edge): Likewise.
	* tree-ssa-dce.c (forward_edge_to_pdom): Likewise.
	* tree-ssa.c (flush_pending_stmts): Likewise.
	(redirect_edge_var_map_add): Likewise.
	(ssa_redirect_edge): Likewise.
	* gimple-streamer-in.c (input_phi): Likewise.
	* tree-vect-stmts.c (vectorizable_load): Likewise.
	* tree-inline.c (copy_phis_for_bb): Likewise.
	* tree-ssa-phiprop.c (phiprop_insert_phi): Likewise.
	* tree-switch-conversion.c (fix_phi_nodes): Likewise.
	* tree-cfg.c (reinstall_phi_args): Likewise.
	(gimple_make_forwarder_block): Likewise.
	(add_phi_args_after_copy_edge): Likewise.
	(gimple_duplicate_sese_tail): Likewise.

From-SVN: r189402
2012-07-10 04:28:32 +00:00
GCC Administrator
1ee4995ff7 Daily bump.
From-SVN: r189401
2012-07-10 00:17:26 +00:00
Jason Merrill
55e5bf2146 DR 1402 PR c++/53733
DR 1402
	PR c++/53733
	* cp-tree.h (FNDECL_SUPPRESS_IMPLICIT_DECL): New.
	(struct lang_decl_fn): Add suppress_implicit_decl field.
	* method.c (implicitly_declare_fn): Check it.
	(process_subob_fn): Add no_implicit_p parm.
	(walk_field_subobs, synthesized_method_walk): Likewise.
	(maybe_explain_implicit_delete): Adjust.
	(explain_implicit_non_constexpr): Adjust.

From-SVN: r189396
2012-07-09 20:03:23 -04:00
Jason Merrill
60b9991b61 method.c (synthesized_method_walk): Avoid changing EH spec based on cleanups in other places, too.
* method.c (synthesized_method_walk): Avoid changing
	EH spec based on cleanups in other places, too.

From-SVN: r189395
2012-07-09 20:03:11 -04:00
Oleg Endo
83d88a6dd1 re PR target/53886 (Seg fault in sh_insn_length_adjustment)
PR target/53886
	* config/sh/sh.c (sequence_insn_p): New function.
	(find_barrier, sh_insn_length_adjustment): Use it.

From-SVN: r189394
2012-07-09 22:39:25 +00:00
Sterling Augustine
924ef62b91 error.c (lang_decl_name): Use TFF_UNQUALIFIED_NAME flag.
gcc/cp/ChangeLog
2012-07-09  Sterling Augustine  <saugustine@google.com>

	* error.c (lang_decl_name): Use TFF_UNQUALIFIED_NAME flag.

gcc/testsuite/ChangeLog
2012-07-09  Sterling Augustine  <saugustine@google.com>

	* g++.dg/debug/dwarf2/pubnames-2.C: New.

From-SVN: r189392
2012-07-09 21:44:57 +00:00
Iain Sandoe
1cd130b046 re PR target/53283 (Many failures on x86_64-apple-darwin10 after revision 186789)
PR target/53283
	* config/i386/i386.c (ix86_fold_builtin): Call SUBTARGET_FOLD_BUILTIN
	if defined.
	* config/darwin.h: Rename TARGET_FOLD_BUILTIN to
	SUBTARGET_FOLD_BUILTIN.
	* config/rs6000/darwin.h: Map TARGET_FOLD_BUILTIN onto
	SUBTARGET_FOLD_BUILTIN.

From-SVN: r189391
2012-07-09 19:21:59 +00:00
Iain Sandoe
f29234dfb1 darwin.h (SUBTARGET_C_COMMON_OVERRIDE_OPTIONS): Move NeXT runtime exceptions model setting from here ...
* config/darwin.h (SUBTARGET_C_COMMON_OVERRIDE_OPTIONS): Move NeXT
	runtime exceptions model setting from here ...
	* config/darwin.c (darwin_override_options): ... to here.

From-SVN: r189390
2012-07-09 19:16:37 +00:00
Steven Bosscher
238065a73b re PR middle-end/53887 (ICE in hoist_edge_and_branch_if_true, at tree-switch-conversion.c:79)
gcc/
	PR tree-optimization/53887
	* tree-cfg.c (group_case_labels_stmt): Make non-static.
	* tree-flow.h (group_case_labels_stmt): Add prototype.
	* tree-switch-conversion.c (process_switch): Use group_case_labels_stmt
	to pre-process every switch.

testsuite/
	PR tree-optimization/53887
	* gcc.dg/pr53887.c: New test.

From-SVN: r189389
2012-07-09 18:53:35 +00:00
Jason Merrill
06e3e32bcd re PR c++/53882 (ICE in type_contains_placeholder_1, at tree.c:3015)
PR c++/53882
	* tree.c (type_contains_placeholder_1): Handle NULLPTR_TYPE.
	(type_hash_eq): Likewise.

From-SVN: r189386
2012-07-09 10:11:01 -04:00
Arnaud Charlet
065dd77587 [multiple changes]
2012-07-09  Pascal Obry  <obry@adacore.com>

	* prj.adb (For_Every_Project_Imported_Context): Make sure we
	callback with the project having sources.
	Minor reformatting.

2012-07-09  Eric Botcazou  <ebotcazou@adacore.com>

	* make.adb: Fix typo.

From-SVN: r189385
2012-07-09 15:29:10 +02:00