Commit Graph

106280 Commits

Author SHA1 Message Date
Martin Jambor
05842ff57c common.opt (fdevirtualize): New flag.
2011-01-15  Martin Jambor  <mjambor@suse.cz>

	* common.opt (fdevirtualize): New flag.
	* doc/invoke.texi (Option Summary): Document it.
	* opts.c (default_options_table): Add devirtualize flag.
	* ipa-prop.c (detect_type_change): Return immediately if
	devirtualize flag is not set.
	(detect_type_change_ssa): Likewise.
	(compute_known_type_jump_func): Likewise.
	(ipa_analyze_virtual_call_uses): Likewise.

From-SVN: r168826
2011-01-15 00:19:08 +01:00
Martin Jambor
f65cf2b706 re PR tree-optimization/45934 (g++.old-deja/g++.other/dtor5.C FAILs with -finline-small-functions)
2011-01-14  Martin Jambor  <mjambor@suse.cz>

	PR tree-optimization/45934
	PR tree-optimization/46302
	* ipa-prop.c (type_change_info): New type.
	(stmt_may_be_vtbl_ptr_store): New function.
	(check_stmt_for_type_change): Likewise.
	(detect_type_change): Likewise.
	(detect_type_change_ssa): Likewise.
	(compute_complex_assign_jump_func): Check for dynamic type change.
	(compute_complex_ancestor_jump_func): Likewise.
	(compute_known_type_jump_func): Likewise.
	(compute_scalar_jump_functions): Likewise.
	(ipa_analyze_virtual_call_uses): Likewise.
	(ipa_analyze_node): Push and pop cfun, set current_function_decl.

	* testsuite/g++.dg/ipa/devirt-c-1.C: New test.
	* testsuite/g++.dg/ipa/devirt-c-2.C: Likewise.
	* testsuite/g++.dg/ipa/devirt-c-3.C: Likewise.
	* testsuite/g++.dg/ipa/devirt-c-4.C: Likewise.
	* testsuite/g++.dg/ipa/devirt-c-5.C: Likewise.
	* testsuite/g++.dg/ipa/devirt-c-6.C: Likewise.
	* testsuite/g++.dg/ipa/devirt-6.C: Likewise.
	* testsuite/g++.dg/ipa/devirt-d-1.C: Likewise.
	* testsuite/g++.dg/torture/pr45934.C: Likewise.

From-SVN: r168825
2011-01-15 00:00:59 +01:00
Mike Stump
dc0d2dae5a re PR target/19162 (ICE while building libobjc's sendmsg.c)
PR 19162
	* objc-act.c (generate_struct_by_value_array): Do not output a
	definition for struct_forward_array.

From-SVN: r168824
2011-01-14 21:50:11 +00:00
Ben Elliston
2d66a8d3c1 objc-act.c (generate_struct_by_value_array): Do not output a definition for struct_forward_array.
2011-01-14  Ben Elliston  <bje@au.ibm.com>

	* objc-act.c (generate_struct_by_value_array): Do not output a
	definition for struct_forward_array.

From-SVN: r168823
2011-01-14 21:38:17 +00:00
Jason Merrill
aeb459fbd1 re PR c++/47289 ([C++0x] ICE in tsubst_pack_expansion (triggered by decltype))
PR c++/47289
	* pt.c (coerce_template_parms): Fix error recovery.

From-SVN: r168822
2011-01-14 16:26:47 -05:00
Joseph Myers
eb5bb0fd0b i386.h (CC1_CPU_SPEC_1): Don't handle -msse5.
* config/i386/i386.h (CC1_CPU_SPEC_1): Don't handle -msse5.
	* config/i386/i386.opt (msse5): New Alias.

From-SVN: r168821
2011-01-14 21:03:22 +00:00
Joseph Myers
f2060fbe8f linux.h (CC1_SPEC): Remove %{sun4:} %{target:}.
* config/sparc/linux.h (CC1_SPEC): Remove %{sun4:} %{target:}.
	* config/sparc/linux64.h (CC1_SPEC): Likewise.
	* config/sparc/netbsd-elf.h (CC1_SPEC32, CC1_SPEC64): Likewise.
	* config/sparc/sparc.h (CC1_SPEC): Likewise.

From-SVN: r168820
2011-01-14 21:02:06 +00:00
Joseph Myers
3a7b438569 linux.h (CC1_SPEC): Don't handle old equivalents of -mcpu options.
* config/sparc/linux.h (CC1_SPEC): Don't handle old equivalents of
	-mcpu options.
	* config/sparc/linux64.h (CC1_SPEC): Likewise.
	* config/sparc/netbsd-elf.h (CC1_SPEC32, CC1_SPEC64): Likewise.
	* config/sparc/sol2-bi.h (CPP_CPU_SPEC, CC1_SPEC): Likewise.
	* config/sparc/sparc.h (CPP_CPU_SPEC, CC1_SPEC, ASM_CPU_SPEC):
	Likewise.
	* config/sparc/t-elf (MULTILIB_MATCHES): Don't handle -mv8.

From-SVN: r168819
2011-01-14 21:01:18 +00:00
Joseph Myers
a7b778f8a6 vxworks.h (CC1_SPEC): Don't handle -fvec or -fvec-eabi.
* config/rs6000/vxworks.h (CC1_SPEC): Don't handle -fvec or
	-fvec-eabi.

From-SVN: r168818
2011-01-14 20:59:52 +00:00
Mike Stump
a7edae0a63 alpha.md (umk_mismatch_args): Don't put a mode on set.
* config/alpha/alpha.md (umk_mismatch_args): Don't put a mode on set.
	* config/fr30/fr30.md: Likweise
	(movsi_push): Likewise.
	(movsi_pop): Likewise.
	(enter_func): Likewise.
	* config/moxie/moxie.md (movsi_push): Likewise.
	(movsi_pop): Likewise.

From-SVN: r168817
2011-01-14 19:37:16 +00:00
Ian Lance Taylor
ed4ebabc90 libgo: Check whether we need -lrt for sched_yield.
From Rainer Orth.

From-SVN: r168816
2011-01-14 19:18:38 +00:00
Ian Lance Taylor
3ad3790dc0 libgo: Use $(SHELL) to invoke gotest.
From Rainer Orth.

From-SVN: r168815
2011-01-14 19:13:24 +00:00
Ian Lance Taylor
2ab1753476 libgo/syscalls: Finish Solaris code.
Mostly from Rainer Orth.

From-SVN: r168814
2011-01-14 19:10:02 +00:00
Joseph Myers
cbabf03f9a linux64.h (LINK_SPEC): Remove %{bestGnum} %{no_archive} %{exact_version}.
* config/mips/linux64.h (LINK_SPEC): Remove %{bestGnum}
	%{no_archive} %{exact_version}.
	* config/mips/mips.h (LINK_SPEC): Remove %{bestGnum}.
	* config/mips/netbsd.h (LINK_SPEC): Remove %{bestGnum}
	%{no_archive} %{exact_version}.
	* config/mips/openbsd.h (LINK_SPEC): Likewise.
	* config/mips/sde.h (LINK_SPEC): Remove %{bestGnum}.
	* config/mips/vxworks.h: Likewise.

From-SVN: r168813
2011-01-14 18:56:52 +00:00
Joseph Myers
438da41abf microblaze.h (ASM_SPEC): Remove %{microblaze1}.
* config/microblaze/microblaze.h (ASM_SPEC): Remove
	%{microblaze1}.

From-SVN: r168812
2011-01-14 18:55:27 +00:00
Joseph Myers
da290a425c little.h (CPP_ENDIAN_SPEC, [...]): Remove.
* config/m32r/little.h (CPP_ENDIAN_SPEC, CC1_ENDIAN_SPEC,
	ASM_ENDIAN_SPEC, LINK_ENDIAN_SPEC): Remove.

From-SVN: r168810
2011-01-14 18:54:16 +00:00
Joseph Myers
8989d00e96 nwld.h (LINK_SPEC): Check -nodefaultlibs not -nodefaultlib.
* config/i386/nwld.h (LINK_SPEC): Check -nodefaultlibs not
	-nodefaultlib.

From-SVN: r168809
2011-01-14 18:53:16 +00:00
Joseph Myers
a3010a69a8 cris.h (ASM_SPEC, [...]): Check for mcpu not cpu.
* config/cris/cris.h (ASM_SPEC, CRIS_ASM_SUBTARGET_SPEC): Check
	for mcpu not cpu.
	* config/cris/linux.h (CRIS_CPP_SUBTARGET_SPEC,
	CRIS_CC1_SUBTARGET_SPEC, CRIS_ASM_SUBTARGET_SPEC): Check for mcpu
	not cpu.
	(CRIS_LINK_SUBTARGET_SPEC): Don't generate -rpath-link options.
	Don't handle -shlib.

From-SVN: r168808
2011-01-14 18:51:46 +00:00
Joseph Myers
e7f2f53750 avr.h (CPP_SPEC): Don't handle -posix.
* config/avr/avr.h (CPP_SPEC): Don't handle -posix.
	(CC1_SPEC): Don't handle -profile.

From-SVN: r168807
2011-01-14 18:47:52 +00:00
Dominique d'Humieres
5ebe1114f9 re PR objc/45989 (Some objc.dg-struct-layout-encoding-1 tests XPASS)
2011-01-08  Dominique d'Humieres  <dominiq@lps.ens.fr>
	    Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>

	PR objc/45989
	* objc.dg/gnu-encoding/struct-layout-encoding-1_generate.c
	(switchfiles): XFAIL
	objc.dg-struct-layout-encoding-1/t02[57-9]_main.m execution tests
	on i?86-*-*, x86_64-*-*, and powerpc*-apple-darwin* && ilp32.
	XFAIL objc.dg-struct-layout-encoding-1/t03[01]_main.m execution
	tests on i?86-*-* and x86_64-*-*.

Co-Authored-By: Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>

From-SVN: r168806
2011-01-14 18:47:50 +00:00
Joseph Myers
34830bfdfe microblaze.h (CC1_SPEC): Remove -gline spec.
* config/microblaze/microblaze.h (CC1_SPEC): Remove -gline spec.
	* config/mips/mips.h (CC1_SPEC): Likewise.

From-SVN: r168805
2011-01-14 18:47:00 +00:00
Ian Lance Taylor
8c954c529d libgo/Makefile.am: Correct typos in Solaris support.
From Rainer Orth.

From-SVN: r168804
2011-01-14 18:46:42 +00:00
Joseph Myers
b2d36e744e microblaze.h (CC1_SPEC): Remove %{save-temps: }.
* config/microblaze/microblaze.h (CC1_SPEC): Remove %{save-temps: }.
	* config/mips/mips.h (CC1_SPEC): Likewise.

From-SVN: r168803
2011-01-14 18:46:24 +00:00
Joseph Myers
dabadc52a9 linux.h (LINK_SPEC): Don't use %{!ibcs:} conditional.
* config/i386/linux.h (LINK_SPEC): Don't use %{!ibcs:} conditional.
	* config/m32r/linux.h (LINK_SPEC): Likewise.
	* config/mips/linux.h (LINK_SPEC): Likewise.
	* config/mips/linux64.h (LINK_SPEC): Likewise.
	* config/sparc/linux.h (LINK_SPEC): Likewise.
	* config/sparc/linux64.h (LINK_ARCH32_SPEC, LINK_ARCH64_SPEC,
	LINK_SPEC): Likewise.
	* config/xtensa/linux.h (LINK_SPEC): Likewise.

From-SVN: r168802
2011-01-14 18:45:06 +00:00
Joseph Myers
43ee67856a linux-elf.h (LINUX_TARGET_LINK_SPEC): Remove %{version:-v}.
* config/arm/linux-elf.h (LINUX_TARGET_LINK_SPEC): Remove
	%{version:-v}.
	* config/lm32/uclinux-elf.h (LINK_SPEC): Likewise.

From-SVN: r168801
2011-01-14 18:42:32 +00:00
Ian Lance Taylor
8610843513 mksysinfo: Define _pad128_t and _upad128_t if commented out.
From Rainer Orth.

From-SVN: r168800
2011-01-14 18:41:31 +00:00
Joseph Myers
45e79dfd0a sp-elf.h (ASM_SPEC): Remove %{v:-V}.
* config/sparc/sp-elf.h (ASM_SPEC): Remove %{v:-V}.
	* config/sparc/sp64-elf.h (ASM_SPEC): Likewise.

From-SVN: r168799
2011-01-14 18:41:05 +00:00
Joseph Myers
37e9e71d88 * config/arm/linux-elf.h (LINUX_TARGET_LINK_SPEC): Remove %{b}.
From-SVN: r168798
2011-01-14 18:39:49 +00:00
Mike Stump
47524032e0 Fix indentation.
From-SVN: r168797
2011-01-14 18:11:27 +00:00
Paolo Carlini
a5983012cd check_type.cc: Minor tweaks.
2011-01-14  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/25_algorithms/is_permutation/check_type.cc: Minor
	tweaks.
	* testsuite/25_algorithms/is_permutation/1.cc: Cosmetic changes.

From-SVN: r168796
2011-01-14 17:17:32 +00:00
Rainer Orth
bb127cd84b configure.ac (gcc_cv_ld_static_dynamic): Solaris 2 ld always supports -Bstatic/-Bdynamic.
* configure.ac (gcc_cv_ld_static_dynamic): Solaris 2 ld always
	supports -Bstatic/-Bdynamic.
	* configure: Regenerate.

From-SVN: r168795
2011-01-14 17:00:24 +00:00
Jan Hubicka
89a012ea9e re PR target/46037 (--enable-stage1-languages=c,lto --enable-languages=c,lto --with-build-config=bootstrap-lto fails on darwin)
2011-01-14  Jan Hubicka  <jh@suse.cz>
            Jack Howarth <howarth@bromo.med.uc.edu>

	PR target/46037
	* config/darwin.c (darwin_override_options): Honor flag_gtoggle
	when checking debug_info_level. Test write_symbols instead of
	debug_hooks->var_location when setting flag_var_tracking_uninit.

Co-Authored-By: Jack Howarth <howarth@bromo.med.uc.edu>

From-SVN: r168793
2011-01-14 15:42:09 +00:00
Richard Guenther
7352c01332 re PR tree-optimization/47179 (SPU: errno misoptimization around malloc call)
2011-01-14  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/47179
	* target.def (ref_may_alias_errno): New target hook.
	* targhooks.h (default_ref_may_alias_errno): Declare.
	* targhooks.c: Include tree-ssa-alias.h and tree-flow.h.
	(default_ref_may_alias_errno): New function.
	* target.h (struct ao_ref_s): Declare.
	* tree-ssa-alias.c: Include target.h.
	(call_may_clobber_ref_p_1): Use the ref_may_alias_errno target hook.
	* Makefile.in (tree-ssa-alias.o): Adjust dependencies.
	(targhooks.o): Likewise.
	* doc/tm.texi.in (TARGET_REF_MAY_ALIAS_ERRNO): Document.
	* doc/tm.texi (TARGET_REF_MAY_ALIAS_ERRNO): Copy documentation.

From-SVN: r168788
2011-01-14 15:02:20 +00:00
Richard Guenther
9a6c928887 tree-ssa-structalias.c (new_var_info): Use DECL_HARD_REGISTER.
2011-01-14  Richard Guenther  <rguenther@suse.de>

	* tree-ssa-structalias.c  (new_var_info): Use DECL_HARD_REGISTER.

From-SVN: r168787
2011-01-14 14:58:01 +00:00
Eric Botcazou
280d9630d9 Fix formatting issues
From-SVN: r168786
2011-01-14 14:52:44 +00:00
Richard Guenther
0fdb0d27c2 re PR tree-optimization/47280 (ICE: verify_stmts failed: statement marked for throw, but doesn't with -fnon-call-exceptions -ftrapv)
2011-01-14  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/47280
	* tree-ssa-forwprop.c (associate_plusminus): Cleanup EH and
	return CFG changes.
	(tree_ssa_forward_propagate_single_use_vars): Deal with
	CFG changes from associate_plusminus.

	* g++.dg/opt/pr47280.C: New testcase.

From-SVN: r168784
2011-01-14 13:20:22 +00:00
Jason Merrill
35385f991f re PR c++/46903 ([C++0x] ICE unexpected expression of kind template_id_expr)
PR c++/46903
	* typeck2.c (check_narrowing): Only check arithmetic types.

From-SVN: r168783
2011-01-14 08:08:11 -05:00
Jason Merrill
70f961a51e re PR c++/46688 (g++ requires a function declaration when it should not)
PR c++/46688
	* tree.c (build_vec_init_expr): Handle flexible array
	properly.

From-SVN: r168782
2011-01-14 08:08:02 -05:00
Richard Guenther
8f66db3b32 re PR middle-end/47281 (error: non-trivial conversion at assignment)
2011-01-14  Richard Guenther  <rguenther@suse.de>

	PR middle-end/47281
	Revert
	2011-01-11  Richard Guenther  <rguenther@suse.de>

        PR tree-optimization/46076
        * tree-ssa.c (useless_type_conversion_p): Conversions from
        unprototyped to empty argument list function types are useless.

	* gcc.dg/torture/pr47281.c: New testcase.
	* gcc.dg/tree-ssa/pr46076.c: XFAIL.

From-SVN: r168781
2011-01-14 12:39:09 +00:00
Richard Guenther
6c0c92e6b3 re PR tree-optimization/47286 (Invalid code when using register ... asm)
2011-01-14  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/47286
	* tree-ssa-structalias.c (new_var_info): Register variables
	are global.

	* gcc.dg/tree-ssa/pr47286.c: New testcase.

From-SVN: r168779
2011-01-14 12:15:43 +00:00
Martin Jambor
db09f9434d re PR middle-end/46823 (ICE: edge points to wrong declaration)
2011-01-14  Martin Jambor  <mjambor@suse.cz>

	PR middle-end/46823
	* tree-inline.c (expand_call_inline): Get fndecl from call graph edge.

From-SVN: r168778
2011-01-14 12:59:07 +01:00
Tobias Burnus
642d287307 re PR fortran/47182 (libquadmath.texi: undefined flag: BUGURL)
2011-01-14  Tobias Burnus  <burnus@net-b.de>

        PR fortran/47182
        * configure.ac: Use ACX_BUGURL.
        * libquadmath.texi: Include libquadmath-vers.texi for BUGURL.
        * Makefile.am: Create libquadmath-vers.texi.
        * configure.in: Regenerate.
        * Makefile.in: Regenerate.

From-SVN: r168776
2011-01-14 08:18:54 +01:00
Ian Lance Taylor
82afdd42e2 The type of a string slice is the type of the string being sliced.
From-SVN: r168775
2011-01-14 05:37:12 +00:00
Ian Lance Taylor
3dac68b99e Move clearing of flag_strict_aliasing to gcc interface.
From-SVN: r168774
2011-01-14 03:27:32 +00:00
Paolo Carlini
632469d01e [multiple changes]
2011-01-13  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/25_algorithms/is_permutation/check_type.cc: New.
	* testsuite/25_algorithms/is_permutation/requirements/
	explicit_instantiation/2.cc: Likewise.
	* testsuite/25_algorithms/is_permutation/requirements/
	explicit_instantiation/pod.cc: Likewise.
	* testsuite/25_algorithms/is_permutation/1.cc: Likewise.

2011-01-13  John Lakos  <jlakos@bloomberg.net>
	    Pablo Halpern  <phalpern@halpernwightsoftware.com>
	    Paolo Carlini  <paolo.carlini@oracle.com>

	* include/bits/stl_algo.h (is_permutation): Add, per N3068.
	* include/bits/algorithmfwd.h: Add.

From-SVN: r168773
2011-01-14 01:21:51 +00:00
GCC Administrator
57d5062695 Daily bump.
From-SVN: r168770
2011-01-14 00:19:25 +00:00
Tobias Burnus
4975dfd9c9 re PR libfortran/47268 (Documentation: missing (Optional) keyword for parameters of get_command_argument() and get_environment_variable())
2011-01-13  Tobias Burnus  <burnus@net-b.de>

        PR fortran/47268
        * intrinsic.texi (get_command_argument,
        * get_environment_variable):
        Mark arguments as optional in the Arguments section.

From-SVN: r168766
2011-01-13 23:00:50 +01:00
Anatoly Sokolov
dde8a3a47e xtensa.h (XTENSA_LIBCALL_VALUE, [...]): Remove macros.
* config/xtensa/xtensa.h (XTENSA_LIBCALL_VALUE, LIBCALL_VALUE,
	LIBCALL_OUTGOING_VALUE, FUNCTION_VALUE_REGNO_P): Remove macros.
	* config/xtensa/xtensa.c (xtensa_libcall_value,
	xtensa_function_value_regno_p): New functions.
	(TARGET_LIBCALL_VALUE, TARGET_FUNCTION_VALUE_REGNO_P): Define.

From-SVN: r168765
2011-01-13 23:24:19 +03:00
Ian Lance Taylor
389295b785 Don't exit mksysinfo.sh if there is no _user_regs_struct.
From-SVN: r168764
2011-01-13 20:23:19 +00:00
Kai Tietz
a2b63a2001 re PR c++/47213 (ICE: SIGSEGV in determine_visibility (decl2.c:2076) with -fvisibility-ms-compat)
2011-01-13  Kai Tietz  <kai.tietz@onevision.com>

	PR c++/47213
	* g++.dg/ext/pr47213.C: New.

2011-01-13  Kai Tietz  <kai.tietz@onevision.com>

	PR c++/47213
	* cp-tree.h (CLASSTYPE_VISIBILITY): Use
	TYPE_MAIN_DECL instead of TYPE_NAME.
	(CLASSTYPE_VISIBILITY_SPECIFIED): Likewise.
	* decl2.c (determine_visibility): Add check
	of CLASS_TYPE_P for underlying_type.

2011-01-13  Kai Tietz  <kai.tietz@onevision.com>

	PR c++/47213
	* config/i386/cygming.h (TARGET_ASM_ASSEMBLE_VISIBILITY):
	PE specific hook.
	* config/i386/i386-protos.h (i386_pe_assemble_visibility):
	New function prototype.
	* config/i386/winnt.c (i386_pe_assemble_visibility):
	Warn only if attribute was specified by user.

From-SVN: r168763
2011-01-13 21:01:57 +01:00