Commit Graph

110166 Commits

Author SHA1 Message Date
Richard Henderson 9f2ff8e5c9 ia64: Issue REG_CFA_REGISTER for ar.pfs at alloc insn.
* config/ia64/ia64.c (ia64_expand_prologue): Emit REG_CFA_REGISTER
        for ar.pfs save at alloc insn.

From-SVN: r175871
2011-07-05 10:05:04 -07:00
Richard Henderson ddc6e7d62c arm: Use REG_CFA_REGISTER instead of UNSPEC_STACK_ALIGN.
This requires a bit of extra preparation in arm_unwind_emit, in
order to handle the change for ARM unwinding.

        * config/arm/arm.c (arm_dwarf_handle_frame_unspec): Remove.
        (TARGET_DWARF_HANDLE_FRAME_UNSPEC): Remove.
        (arm_expand_prologue): Use REG_CFA_REGISTER to mark the
        stack pointer save.
        (arm_unwind_emit_set): Don't recognize UNSPEC_STACK_ALIGN.
        (arm_unwind_emit): Walk REG_NOTES for unwinding notes.  Emit
        proper unwind info for a REG_CFA_REGISTER save of stack pointer.
        * config/arm/arm.md (UNSPEC_STACK_ALIGN): Remove.

From-SVN: r175870
2011-07-05 10:03:41 -07:00
Richard Henderson a351560575 vax: Emit prologue as rtl.
Not that there's much rtl to emit, since the CALL instruction
interpreting the procedure entry mask does almost all the work.
However, it means we're no longer emitting dwarf2 via the
text-based entry points.

        * config/vax/vax.md (define_c_enum unspecv): New.  Define the
        VUNSPEC_* constants here instead of via define_constants.
        (VUNSPEC_PEM): New constant.
        (procedure_entry_mask): New insn.
        (prologue): New expander.
        * config/vax/vax.c (vax_add_reg_cfa_offset): New.
        (vax_expand_prologue): Rename from vax_output_function_prologue;
        emit rtl instead of text.
        (TARGET_ASM_FUNCTION_PROLOGUE): Remove.
        (print_operand): Add 'x' prefix.

From-SVN: r175869
2011-07-05 09:58:42 -07:00
Jason Merrill 96241349e9 * g++.dg/rtti/anon-ns1.C: Allow for null-termination.
From-SVN: r175867
2011-07-05 12:36:59 -04:00
H.J. Lu a7adbbcbc3 Promote the function argument before checking non-legitimate constant.
2011-07-05  H.J. Lu  <hongjiu.lu@intel.com>

	PR middle-end/47715
	* calls.c (precompute_register_parameters): Promote the function
	argument before checking non-legitimate constant.

From-SVN: r175864
2011-07-05 08:47:40 -07:00
Sebastian Pop cec11ec414 Fix PR47654: Loop blocking should strip-mine at least two loops.
PR tree-optimization/47654
	* graphite-blocking.c (pbb_strip_mine_time_depth): Do not return bool.
	(lst_do_strip_mine_loop): Return an int.
	(lst_do_strip_mine): Same.
	(scop_do_strip_mine): Same.
	(scop_do_block): Loop blocking should strip-mine at least two loops.
	* graphite-interchange.c (lst_interchange_select_outer): Return an int.
	(scop_do_interchange): Same.
	* graphite-poly.h (scop_do_interchange): Update declaration.
	(scop_do_strip_mine): Same.

	* gcc.dg/graphite/block-pr47654.c: New.

From-SVN: r175861
2011-07-05 14:50:34 +00:00
Sebastian Pop 9b0d314a45 Fix computation of precision.
* graphite-clast-to-gimple.c (precision_for_value): Removed.
	(precision_for_interval): Removed.
	(gcc_type_for_interval): Use mpz_sizeinbase.

From-SVN: r175860
2011-07-05 14:50:27 +00:00
Sebastian Pop 81d6d0802d Correct computation of max.
* graphite-ppl.h (value_max): Correct computation of max.

From-SVN: r175859
2011-07-05 14:50:21 +00:00
Sebastian Pop 369e343060 Correct typo.
* graphite-clast-to-gimple.c (clast_name_to_index): Add missing space.

From-SVN: r175858
2011-07-05 14:50:13 +00:00
Jason Merrill f395f5e2a1 re PR c++/49598 ([C++0x] Ice on lambda with implicit capture by value.)
PR c++/49598
	* semantics.c (finish_id_expression): convert_from_reference.

From-SVN: r175857
2011-07-05 10:47:21 -04:00
Richard Guenther fce5dddd3d c-common.c (c_common_nodes_and_builtins): Build all common tree nodes first.
2011-07-05  Richard Guenther  <rguenther@suse.de>

	c-family/
	* c-common.c (c_common_nodes_and_builtins): Build all common
	tree nodes first.

	* c-decl.c (c_init_decl_processing): Defer building common
	tree nodes to c_common_nodes_and_builtins.

	cp/
	* decl.c (cxx_init_decl_processing): Defer building common
	tree nodes to c_common_nodes_and_builtins.

From-SVN: r175856
2011-07-05 14:39:30 +00:00
Razya Ladelsky 12037899ea 07-05-2011 Razya Ladelsky <razya@il.ibm.com>
* tree-cfg.c (gimple_duplicate_sese_tail): Remove handling of 
        the loop's number of iterations.
        * tree-parloops.c (transform_to_exit_first_loop): Add the 
        handling of the loop's number of iterations before the call 
        to gimple_duplicate_sese_tail.
        Insert the stmt caclculating the new rhs of the loop's
        condition stmt to the preheader instead of iters_bb.
        * testsuite/gcc.dg/autopar/pr49580.c: New test.

From-SVN: r175851
2011-07-05 13:08:01 +00:00
H.J. Lu 509a31f8e5 Don't propagate hard registers in forward_propagate_subreg.
2011-07-05  H.J. Lu  <hongjiu.lu@intel.com>

	PR rtl-optimization/47449
	* fwprop.c (forward_propagate_subreg): Don't propagate hard
	register nor zero/sign extended hard register.

From-SVN: r175849
2011-07-05 05:47:35 -07:00
Richard Guenther 39becbac3d re PR tree-optimization/49518 (ICE in vect_enhance_data_refs_alignment, at tree-vect-data-refs.c:1555)
2011-07-05  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/49518
	PR tree-optimization/49628
	* tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Skip
	irrelevant and invariant data-references.
	(vect_analyze_data_ref_access): For invariant loads clear the
	group association.

	* g++.dg/torture/pr49628.C: New testcase.
	* gcc.dg/torture/pr49518.c: Likewise.

From-SVN: r175847
2011-07-05 11:24:26 +00:00
Rainer Orth 08b3c764e8 run_acats (which): Extract last field from type -p, type output only if command succeeded.
* ada/acats/run_acats (which): Extract last field from type -p,
	type output only if command succeeded.

From-SVN: r175843
2011-07-05 10:22:50 +00:00
GCC Administrator 441e4f5389 Daily bump.
From-SVN: r175840
2011-07-05 00:17:59 +00:00
Jason Merrill a517066db8 cp-demangle.c (d_expression): Handle 'this'.
* cp-demangle.c (d_expression): Handle 'this'.
	(d_print_comp) [DEMANGLE_COMPONENT_FUNCTION_PARAM]: Likewise.

From-SVN: r175836
2011-07-04 17:44:11 -04:00
Jason Merrill f2fe30af83 DR 1207 PR c++/49589
DR 1207
	PR c++/49589
	* mangle.c (write_expression): Handle 'this'.
	* parser.c (cp_parser_postfix_dot_deref_expression): Allow
	incomplete *this.
	* semantics.c (potential_constant_expression_1): Check that
	DECL_CONTEXT is set on 'this'.

From-SVN: r175835
2011-07-04 17:44:04 -04:00
Jason Merrill 21d69a5bb0 error.c (dump_template_bindings): Don't print typenames for a partial instantiation.
* error.c (dump_template_bindings): Don't print typenames
	for a partial instantiation.
	(dump_function_decl): If we aren't printing function arguments,
	print template arguments as <args> rather than [with ...].
	(dump_expr): Don't print return type or template header.
	[BASELINK]: Use BASELINK_FUNCTIONS rather than get_first_fn.
	* pt.c (dependent_template_arg_p): Handle null arg.

From-SVN: r175834
2011-07-04 17:43:57 -04:00
Jason Merrill 0d3128d6a4 * error.c (type_to_string): Avoid redundant akas.
From-SVN: r175833
2011-07-04 17:43:49 -04:00
Jakub Jelinek bc9475113f re PR fortran/49623 (Segfault of "gfortran -L" if no argument follows the "-L")
PR fortran/49623
	* gfortranspec.c (lang_specific_driver): Ignore options with
	CL_ERR_MISSING_ARG errors.

From-SVN: r175830
2011-07-04 23:12:57 +02:00
Jakub Jelinek af421d9cf0 re PR rtl-optimization/49619 (ICE in simplify_subreg, at simplify-rtx.c:5362)
PR rtl-optimization/49619
	* combine.c (combine_simplify_rtx): In PLUS -> IOR simplification
	pass VOIDmode as op0_mode to recursive call, and return temp even
	when different from tor, just if it is not IOR of the original
	PLUS arguments.

	* gcc.dg/pr49619.c: New test.

From-SVN: r175825
2011-07-04 23:04:54 +02:00
Jakub Jelinek 707f991907 re PR rtl-optimization/49472 (Compiler segfault on valid code)
PR rtl-optimization/49472
	* simplify-rtx.c (simplify_unary_operation_1) <case NEG>: When
	negating MULT, negate the second operand instead of first.
	(simplify_binary_operation_1) <case MULT>: If one operand is
	a NEG and the other is MULT, don't attempt to optimize by
	negation of the MULT operand if it only moves the NEG operation
	around.

	* gfortran.dg/pr49472.f90: New test.

From-SVN: r175821
2011-07-04 20:53:56 +02:00
Jakub Jelinek 15923c25df re PR debug/49602 (verify_ssa failed (definition does not dominate use) with "-O2 -g")
PR debug/49602
	* tree-into-ssa.c (rewrite_debug_stmt_uses): Disregard
	get_current_def return value if it can't be trusted to be
	the current value of the variable in the current bb.

	* gcc.dg/pr49602.c: New test.

From-SVN: r175818
2011-07-04 19:19:52 +02:00
Uros Bizjak 0d5e0c1bf0 re PR target/49600 (Bad SSE2 int->float split in i386.md)
PR target/49600
	* config/i386/i386.md (SSE2 int->float split): Push operand 1 in
	general register to memory for !TARGET_INTER_UNIT_MOVES.

From-SVN: r175817
2011-07-04 18:26:08 +02:00
Georg-Johann Lay a648cfe8b3 re PR target/34734 ([avr] attribute((progmem)) not handled properly in C++)
PR target/34734
	PR target/44643
	* gcc.target/avr/avr.exp: Run over cpp files, too.
	* gcc.target/avr/torture/avr-torture.exp: Ditto.
	* gcc.target/avr/progmem.h: New file.
	* gcc.target/avr/exit-abort.h: New file.
	* gcc.target/avr/progmem-error-1.c: New file.
	* gcc.target/avr/progmem-error-1.cpp: New file.
	* gcc.target/avr/progmem-warning-1.c: New file.
	* gcc.target/avr/torture/progmem-1.c: New file.
	* gcc.target/avr/torture/progmem-1.cpp: New file.

From-SVN: r175811
2011-07-04 12:48:04 +00:00
Georg-Johann Lay db297e2084 re PR target/44643 ([avr] ICE in c-typeck.c)
PR target/44643
	* config/avr/avr.c (avr_insert_attributes): Use TYPE_READONLY
	instead of TREE_READONLY.

From-SVN: r175809
2011-07-04 12:28:02 +00:00
Georg-Johann Lay f451d14dcc extend.texi (AVR Built-in Functions): Update documentation of __builtin_avr_fmul*.
* doc/extend.texi (AVR Built-in Functions): Update documentation
	of __builtin_avr_fmul*.
	* config/avr/avr.c (avr_init_builtins): Don't depend on
	AVR_HAVE_MUL.
	* config/avr/avr-c.c (avr_cpu_cpp_builtins): Ditto.
	* config/avr/avr.md (fmul): Rename to fmul_insn.
	(fmuls): Rename to fmuls_insn.
	(fmulsu): Rename to fmulsu_insn.
	(fmul,fmuls,fmulsu): New expander.
	(*fmul.call,*fmuls.call,*fmulsu.call): New Insn.
	* config/avr/t-avr (LIB1ASMFUNCS): Add _fmul, _fmuls, _fmulsu.
	* config/avr/libgcc.S (__fmul): New function.
	(__fmuls): New function.
	(__fmulsu,__fmulsu_exit): New function.

From-SVN: r175807
2011-07-04 12:20:35 +00:00
Richard Guenther 30f1e6dea0 re PR tree-optimization/49615 (internal compiler error: verify_stmts failed / LHS in noreturn call with pointer-to-never-returning-member)
2011-07-04  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/49615
	* tree-cfgcleanup.c (split_bbs_on_noreturn_calls): Fix
	basic-block index check.

	* g++.dg/torture/pr49615.C: New testcase.

From-SVN: r175803
2011-07-04 12:06:17 +00:00
Georg-Johann Lay 6dab9931f8 t-avr (intfuncs16): Add _clrsbXX2.
libgcc/
	* config/avr/t-avr (intfuncs16): Add _clrsbXX2.

gcc/
	* longlong.h (count_leading_zeros, count_trailing_zeros,
	COUNT_LEADING_ZEROS_0): Define for target avr if W_TYPE_SIZE is 16
	resp. 64.

From-SVN: r175800
2011-07-04 10:02:34 +00:00
Nicola Pero f027ee7cb0 In gcc/objc/: 2011-07-04 Nicola Pero <nicola.pero@meta-innovation.com>
In gcc/objc/:
2011-07-04  Nicola Pero  <nicola.pero@meta-innovation.com>

	Refactored encoding code into objc-encoding.h and objc-encoding.c.
	* objc-act.c (util_obstack, util_firstobj, encode_type_qualifiers,
	encode_type, generating_instance_variables, objc_method_parm_type,
	objc_encoded_type_size, encode_method_prototype,
	objc_build_encode_expr, pointee_is_readonly, encode_pointer,
	encode_array, encode_vector, encode_aggregate_fields,
	encode_aggregate_within, encode_next_bitfield,
	encode_gnu_bitfield, encode_field_decl,
	objc_v2_encode_property_attr): Moved to objc-encoding.h and
	objc-encoding.c.  No change in the actual code.
	Include objc-encoding.h.
	(objc_init): Added TODO.
	(objc_build_property_setter_name): Made non-static so it can be
	called from objc-encoding.c.
	* objc-act.h (OBJC_ENCODE_INLINE_DEFS,
	OBJC_ENCODE_DONT_INLINE_DEFS): Moved to objc-encoding.h.
	* objc-runtime-shared-support.h (objc_v2_encode_property_attr,
	encode_method_prototype, encode_field_decl,
	generating_instance_variables): Moved to objc-encoding.h.	
	(objc_build_property_setter_name): Declare.
	* objc-encoding.c: New.
	* objc-encoding.h: New.
	* objc-gnu-runtime-abi-01.c: Include objc-encoding.h.
	* objc-next-runtime-abi-01.c: Likewise.
	* objc-next-runtime-abi-02.c: Likewise.	
	* objc-runtime-shared-support.c: Likewise.
	* Make-lang.in (OBJC_OBJS): Added objc-encoding.o.
	(objc/objc-lang.o): Reordered dependencies.
	(objc/objc-runtime-shared-support.o): Reordered dependencies.
	Added dependencies on objc-encoding.h and on $(GGC_H),
	$(DIAGNOSTIC_CORE_H), $(FLAGS_H) and input.h.
	(objc/objc-gnu-runtime-abi-01.o): Likewise.
	(objc/objc-next-runtime-abi-01.o): Likewise.
	(objc/objc-next-runtime-abi-02.o): Likewise.
	(objc/objc-act.o): Reordered dependencies.  Added dependency on
	objc-encoding.h.
	(objc/objc-encoding.o): New rule.

	* objc-encoding.c (encode_type): Use "%<%T%>" format when printing
	warning "unknown type %<%T%> found during Objective-C encoding"
	instead of using gen_type_name.
	
In gcc/objcp/:
2011-07-04  Nicola Pero  <nicola.pero@meta-innovation.com>

	* Make-lang.in (OBJCXX_OBJS): Added objc-encoding.o.
	(objcp/objcp-lang.o): Reordered dependencies.  Depend on GGC_H.
	(objcp/objcp-decl.o): Reordered dependencies.
	(objcp/objc-runtime-shared-support.o): Reordered dependencies.
	Updated them to be identical to the corresponding new objc/ ones,
	with the addition of objcp-decl.h.
	(objcp/objc-runtime-shared-support.o): Likewise.
	(objcp/objc-gnu-runtime-abi-01.o): Likewise.
	(objcp/objc-next-runtime-abi-01.o): Likewise.
	(objcp/objc-next-runtime-abi-02.o): Likewise.
	(objcp/objcp-act.o): Reordered dependencies.  Added dependency on
	objc-encoding.h.
	(objcp/objc-encoding.o): New rule.

From-SVN: r175797
2011-07-04 08:02:50 +00:00
GCC Administrator 7e6fd113c9 Daily bump.
From-SVN: r175793
2011-07-04 00:19:16 +00:00
Janne Blomqvist 5e2fda444f PR 49296 Fix wrong PR number in ChangeLog
From-SVN: r175789
2011-07-03 20:37:30 +03:00
Ira Rosen b5066d8b10 re PR tree-optimization/49610 (Segfault with -ftree-vectorize (or -O3))
PR tree-optimization/49610
        * tree-vect-loop.c (vect_is_slp_reduction): Check that DEF_STMT has
        a basic block.

From-SVN: r175786
2011-07-03 10:14:55 +00:00
GCC Administrator a23d1a65ef Daily bump.
From-SVN: r175785
2011-07-03 00:17:52 +00:00
Eric Botcazou bc712852cd tree.h (TYPE_ARTIFICIAL): New flag.
* tree.h (TYPE_ARTIFICIAL): New flag.
	* dwarf2out.c (modified_type_die): Add a DW_AT_artificial attribute to
	the DIE of the type if it is artificial.
	(gen_array_type_die): Likewise.
	(gen_enumeration_type_die): Likewise.
	(gen_struct_or_union_type_die): Likewise.
	* lto-streamer-in.c (unpack_ts_base_value_fields): Use TYPE_ARTIFICIAL.
	* lto-streamer-out.c (pack_ts_base_value_fields): Likewise.
ada/
	* gcc-interface/utils.c (record_builtin_type): Set TYPE_ARTIFICIAL on
	the type according to the ARTIFICIAL_P parameter.
	(create_type_decl): Likewise.
	(create_type_stub_decl): Set TYPE_ARTIFICIAL on the type to 1.

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

From-SVN: r175781
2011-07-02 18:13:47 +00:00
Janus Weil 49860194e2 re PR fortran/49562 ([OOP] assigning value to type-bound function)
2011-07-02  Janus Weil  <janus@gcc.gnu.org>

	PR fortran/49562
	* expr.c (gfc_check_vardef_context): Handle type-bound procedures.


2011-07-02  Janus Weil  <janus@gcc.gnu.org>

	PR fortran/49562
	* gfortran.dg/typebound_proc_23.f90: New.

From-SVN: r175779
2011-07-02 13:08:41 +02:00
GCC Administrator fe8ac8e43d Daily bump.
From-SVN: r175775
2011-07-02 00:17:54 +00:00
Jonathan Wakely e2ab8a0f88 re PR c++/49605 (-Wdelete-non-virtual-dtor is not picky enough)
2011-07-01  Jonathan Wakely  <jwakely.gcc@gmail.com>

	PR c++/49605
	* init.c (build_delete): Only warn for sfk_deleting_destructor.

From-SVN: r175771
2011-07-01 23:24:42 +01:00
Eric Botcazou 2eb2238981 Make-lang.in (gnat1): Prepend '+' to the command.
* gcc-interface/Make-lang.in (gnat1): Prepend '+' to the command.
	(gnatbind): Likewise.

From-SVN: r175769
2011-07-01 21:43:59 +00:00
Jakub Jelinek 8b1bdcc523 tree-object-size.c (pass_through_call): Handle BUILT_IN_ASSUME_ALIGNED.
* tree-object-size.c (pass_through_call): Handle
	BUILT_IN_ASSUME_ALIGNED.

From-SVN: r175768
2011-07-01 23:15:05 +02:00
Jakub Jelinek 761da1356b Make-lang.in (cp/decl.o): Depend on pointer-set.h.
* Make-lang.in (cp/decl.o): Depend on pointer-set.h.
	(cp/class.o): Likewise.
	(cp/error.o): Likewise.
	(cp/name-lookup.o): Likewise.
	(cp/decl2.o): Likewise.  Don't depend on $(POINTER_SET_H).

From-SVN: r175767
2011-07-01 23:14:14 +02:00
Jason Merrill 948587e798 re PR c++/48261 (internal compiler error: in lookup_template_function, at cp/pt.c:6227)
PR c++/48261
	* pt.c (lookup_template_function): Handle non-function.

From-SVN: r175766
2011-07-01 16:24:38 -04:00
Jason Merrill d816a3ba71 re PR c++/48593 (Wrong return type when applying address operator to inherited, template dependend member, using a typedef)
PR c++/48593
	* pt.c (tsubst_qualified_id): Check PTRMEM_OK_P.
	* tree.c (build_qualified_name): Set PTRMEM_OK_P.
	* semantics.c (finish_parenthesized_expr): Clear PTRMEM_OK_P on
	SCOPE_REF, too.
	* cp-tree.h (PTRMEM_OK_P): Apply to SCOPE_REF, too.
	(QUALIFIED_NAME_IS_TEMPLATE): Switch to lang flag 1.

From-SVN: r175765
2011-07-01 16:24:25 -04:00
Jason Merrill a771bf1cf6 re PR c++/48883 (?: ternary operator fails in certain contexts - link error)
PR c++/48883
	PR c++/49609
	* pt.c (resolve_nondeduced_context): Call mark_used.

From-SVN: r175764
2011-07-01 16:24:08 -04:00
Joel Brobecker 985b34c77a Darwin has case-insensitive filesystems
HFS+, the FS on Darwin, is case insensitive. So this patch adjusts
filename_cmp.c to ignore the casing when comparing filenames on Darwin.

include/ChangeLog:

        * filenames.h (HAVE_CASE_INSENSITIVE_FILE_SYSTEM): Define
        on Darwin, as well as on the systems that use a DOS-like
        filesystem.

libiberty/ChangeLog:

        * filename_cmp.c (filename_cmp, filename_ncmp): Add handling of
        HAVE_CASE_INSENSITIVE_FILE_SYSTEM.

From-SVN: r175762
2011-07-01 17:51:05 +00:00
Jan Kratochvil cb0ad10428 re PR debug/49408 (member function template id not matching linkage name)
libiberty/
	PR debug/49408
	* cp-demangle.c (d_print_comp): Suppress argument list for function
	references by the '&' unary operator.  Keep also already processed
	variant without the argument list.  Suppress argument list types for
	function call used in an expression.
	* testsuite/demangle-expected: Fix excessive argument list types in
	`test for typed function in decltype'.  New testcase for no argument
	list types printed.  3 new testcases for function references by the
	'&' unary operator..

From-SVN: r175761
2011-07-01 17:16:44 +00:00
Martin Jambor 06e88d7346 tree-sra.c (tree_non_mode_aligned_mem_p): Also ignore MEM_REFs.
2011-07-01  Martin Jambor  <mjambor@suse.cz>

	* tree-sra.c (tree_non_mode_aligned_mem_p): Also ignore MEM_REFs.

From-SVN: r175760
2011-07-01 17:46:17 +02:00
Jason Merrill a174e38c09 re PR c++/49085 (Crash with SIGSEGV during compilation.)
PR c++/49085
	* semantics.c (finish_offsetof): Complain about incomplete type.

From-SVN: r175758
2011-07-01 09:36:17 -04:00
H.J. Lu 6bbec3e156 Use proper mode for stack save area.
2011-07-01  H.J. Lu  <hongjiu.lu@intel.com>

	PR middle-end/48016
	* explow.c (update_nonlocal_goto_save_area): Use proper mode
	for stack save area.
	* function.c (expand_function_start): Likewise.

From-SVN: r175756
2011-07-01 05:57:11 -07:00