Commit Graph

126185 Commits

Author SHA1 Message Date
Jason Merrill 1c79ebd522 re PR c++/58162 ([C++11] bogus error: use of deleted function 'constexpr A::A(const A&)')
PR c++/58162
	* parser.c (cp_parser_late_parse_one_default_arg): Set
	TARGET_EXPR_DIRECT_INIT_P.

From-SVN: r204263
2013-10-31 10:41:55 -04:00
Jason Merrill 83f31d8d5d class.c (type_build_ctor_call): Return early in C++98 mode.
* class.c (type_build_ctor_call): Return early in C++98 mode.
	(type_build_dtor_call): Likewise.

From-SVN: r204262
2013-10-31 10:13:42 -04:00
Edward Smith-Rowland 5d46aaee73 I forgot to commit this from the C++14 digit-separators commit.
From-SVN: r204261
2013-10-31 14:08:43 +00:00
Edward Smith-Rowland 7057e6452b Implement C++14 digit separators.
libcpp:

2013-10-31  Edward Smith-Rowland  <3dw4rd@verizon.net>

        Implement C++14 digit separators.
	* include/cpplib.h (cpp_options): Add digit_separators flag.
	* internal.h (DIGIT_SEP(c)): New macro.
	* expr.c (cpp_classify_number): Check improper placement of digit sep;
	(cpp_interpret_integer): Skip over digit separators.
	* init.c (lang_flags): Add digit_separators flag; (lang_defaults): Add
	digit separator flags per language; (cpp_set_lang): Set
	digit_separators
	* lex.c (lex_number): Add digits separator to allowable characters for
	C++14.


gcc/c-family:

2013-10-31  Edward Smith-Rowland  <3dw4rd@verizon.net>

        Implement C++14 digit separators.
	* c-lex.c (interpret_float): Remove digit separators from scratch string
	before building real literal.


gcc/testsuite:

2013-10-31  Edward Smith-Rowland  <3dw4rd@verizon.net>

        Implement C++14 digit separators.
	* g++.dg/cpp1y/digit-sep.C: New.
	* g++.dg/cpp1y/digit-sep-neg.C: New.
	* g++.dg/cpp1y/digit-sep-cxx11-neg.C: New.


libstdc++-v3:

2013-10-31  Edward Smith-Rowland  <3dw4rd@verizon.net>

        Implement C++14 digit separators.
	* include/include/bits/parse_numbers.h: Change struct _Digit<_Base, '`'>
	to struct _Digit<_Base, '\''>.

From-SVN: r204260
2013-10-31 14:01:23 +00:00
Jakub Jelinek b63cb15373 * gcc.dg/vect/vect-align-3.c: New test.
From-SVN: r204259
2013-10-31 14:59:07 +01:00
Jakub Jelinek 1e99c6e044 tree-vrp.c (maybe_set_nonzero_bits): New function.
* tree-vrp.c (maybe_set_nonzero_bits): New function.
	(remove_range_assertions): Call it.

From-SVN: r204258
2013-10-31 14:58:29 +01:00
Jakub Jelinek eae76e53d9 tree.c (tree_ctz): New function.
* tree.c (tree_ctz): New function.
	* tree.h (tree_ctz): New prototype.
	* tree-ssanames.h (get_range_info, get_nonzero_bits): Change
	first argument from tree to const_tree.
	* tree-ssanames.c (get_range_info, get_nonzero_bits): Likewise.
	* tree-vectorizer.h (vect_generate_tmps_on_preheader): New prototype.
	* tree-vect-loop-manip.c (vect_generate_tmps_on_preheader): No longer
	static.
	* expr.c (highest_pow2_factor): Reimplemented using tree_ctz.
	* tree-vect-loop.c (vect_analyze_loop_operations,
	vect_transform_loop): Don't force scalar loop for bound just because
	number of iterations is unknown, only do it if it is not known to be
	a multiple of vectorization_factor.
	* builtins.c (get_object_alignment_2): Use tree_ctz on offset.

From-SVN: r204257
2013-10-31 14:57:05 +01:00
Jakub Jelinek c853f62af3 gimple-pretty-print.c (dump_ssaname_info): Print newline also in case of VR_VARYING.
* gimple-pretty-print.c (dump_ssaname_info): Print newline also
	in case of VR_VARYING.  Print get_nonzero_bits if not all ones.
	* tree-ssanames.h (struct range_info_def): Add nonzero_bits field.
	(set_nonzero_bits, get_nonzero_bits): New prototypes.
	* tree-ssa-ccp.c (get_default_value): Use get_range_info to see if
	a default def isn't partially constant.
	(ccp_finalize): If after IPA, set_range_info if integral SSA_NAME
	is known to be partially zero.
	(evaluate_stmt): If we'd return otherwise VARYING, use get_range_info
	to see if a default def isn't partially constant.
	* tree-ssanames.c (set_range_info): Initialize nonzero_bits upon
	creation of a range, if VR_RANGE, try to improve nonzero_bits from
	the range.
	(set_nonzero_bits, get_nonzero_bits): New functions.

	* g++.dg/warn/pr33738.C (main): Initialize a2 again to make sure
	we warn about it already during VRP1 pass.

From-SVN: r204256
2013-10-31 14:55:31 +01:00
Jakub Jelinek d8202b848c tree-cfg.c (assert_unreachable_fallthru_edge_p): New function.
* tree-cfg.c (assert_unreachable_fallthru_edge_p): New function.
	* tree-cfg.h (assert_unreachable_fallthru_edge_p): New prototype.
	* tree-vrp.c (all_imm_uses_in_stmt_or_feed_cond): New function.
	(remove_range_assertions): If ASSERT_EXPR_VAR has no other immediate
	uses but in the condition and ASSERT_EXPR and the other successor of
	the predecessor bb is __builtin_unreachable (), set_range_info of the
	ASSERT_EXPR_VAR to the range info of the ASSERT_EXPR's lhs.

From-SVN: r204255
2013-10-31 14:51:38 +01:00
Martin Jambor b319f79c92 re PR rtl-optimization/58934 (build fails on cris-elf in reload_cse_simplify_operands for newlib dtoa.c)
2013-10-31  Martin Jambor  <mjambor@suse.cz>

	PR rtl-optimization/58934
	Revert:
	2013-10-30  Martin Jambor  <mjambor@suse.cz>
	PR rtl-optimization/10474
	* ira.c (find_moveable_pseudos): Do not calculate dominance info
	nor df analysis.
	(interesting_dest_for_shprep): New function.
	(split_live_ranges_for_shrink_wrap): Likewise.
	(ira): Calculate dominance info and df analysis. Call
	split_live_ranges_for_shrink_wrap.

testsuite/
	* gcc.dg/pr10474.c: New testcase.
	* gcc.dg/ira-shrinkwrap-prep-1.c: Likewise.
	* gcc.dg/ira-shrinkwrap-prep-2.c: Likewise.

From-SVN: r204254
2013-10-31 14:39:26 +01:00
Paolo Carlini 0a466ec0c7 48631_neg.cc: Tweak dg-prune.
2013-10-31  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/20_util/default_delete/48631_neg.cc: Tweak dg-prune.

From-SVN: r204253
2013-10-31 12:38:02 +00:00
Paolo Carlini 7f1001af7f re PR c++/58932 ([C++11] Deleted functions and SFINAE in partial template specializations)
/cp
2013-10-31  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58932
	Revert:
	2013-10-18  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58466
	* pt.c (most_specialized_class): Bump processing_template_decl for
	get_class_bindings.

/testsuite
2013-10-31  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58932
	Revert:
	2013-10-18  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58466
	* g++.dg/cpp0x/variadic145.C: New.

	* g++.dg/cpp0x/sfinae49.C: New.

From-SVN: r204252
2013-10-31 12:10:20 +00:00
Richard Sandiford 57d4d653e8 re PR sanitizer/58543 (Invalid unpoisoning of stack redzones on ARM)
2013-10-31  Richard Sandiford  <rsandifo@linux.vnet.ibm.com>
	    Yury Gribov  <y.gribov@samsung.com>

	PR sanitizer/58543
	* asan.c (asan_clear_shadow): Allocate a new vreg for temporary
	shadow pointer to avoid clobbering the main one.

Co-Authored-By: Yury Gribov <y.gribov@samsung.com>

From-SVN: r204251
2013-10-31 12:10:01 +00:00
Paolo Carlini 7dccc537ba re PR c++/58932 ([C++11] Deleted functions and SFINAE in partial template specializations)
/cp
2013-10-31  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58932
	Revert:
	2013-10-18  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58466
	* pt.c (most_specialized_class): Bump processing_template_decl for
	get_class_bindings.

/testsuite
2013-10-31  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58932
	Revert:
	2013-10-18  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58466
	* g++.dg/cpp0x/variadic145.C: New.

	* g++.dg/cpp0x/sfinae49.C: New.

From-SVN: r204250
2013-10-31 12:09:17 +00:00
Paolo Carlini 39344c9927 re PR c++/58581 ([c++11] ICE with no-throw specification in deleted function)
/cp
2013-10-30  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58581
	* call.c (build_over_call): Check return value of mark_used.

/testsuite
2013-10-30  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58581
	* g++.dg/cpp0x/deleted1.C: New.

From-SVN: r204249
2013-10-31 10:11:49 +00:00
Zhenqiang Chen ce5d49a831 lower-subreg.c (resolve_simple_move): Copy REG_INC note.
gcc/ChangeLog:
2013-10-31  Zhenqiang Chen  <zhenqiang.chen@linaro.org>

	* lower-subreg.c (resolve_simple_move): Copy REG_INC note.

gcc/testsuite/ChangeLog:
2013-10-31  Zhenqiang Chen  <zhenqiang.chen@linaro.org>

	* gcc.target/arm/lp1243022.c: New test.

From-SVN: r204247
2013-10-31 06:20:20 +00:00
Balaji V. Iyer 8c1a9d4d38 configure.ac: Changed a case statement to include i386.
2013-10-30  Balaji V. Iyer  <balaji.v.iyer@intel.com>

       * configure.ac: Changed a case statement to include i386.
       * configure: Regenerated.

From-SVN: r204246
2013-10-30 20:21:02 -07:00
Vladimir Makarov c73ccc80a3 re PR bootstrap/58933 (IRA ICE in update_costs_from_allocno)
2013-10-30  Vladimir Makarov  <vmakarov@redhat.com>

	PR bootstrap/58933
	* ira-color.c (update_costs_from_copies): Add new parameter.  Use
	it for calling update_costs_from_allocno.
	(assign_hard_reg): Call restore_costs_from_copies only for
	!retry_p.  Pass new argument to update_costs_from_copies.
	(color_pass): Pass new argument to update_costs_from_copies.
	(ira_mark_allocation_change): Ditto.

From-SVN: r204245
2013-10-31 03:14:07 +00:00
Sharad Singhai 477e804b72 re PR middle-end/58134 (-ftree-vectorizer-verbose=<n> shows vectorized loops only for N== 1 and N >2 but not for N==2)
2013-10-30  Sharad Singhai  <singhai@google.com>

	PR middle-end/58134
	* opts.c (common_handle_option): Remove deprecated option
	-ftree-vectorizer-verbose.
	* doc/invoke.texi (Debugging Options): Ditto.
	* opts-global.c (handle_common_deferred_options): Ditto.
	(dump_remap_tree_vectorizer_verbose): Delete.
	* common.opt: Set -ftree-vectorizer-verbose as an ignored option.

ada/ChangeLog
	* gnat_ugn.texi: Remove option description for PR middle-end/58134.

From-SVN: r204244
2013-10-31 01:01:40 +00:00
DJ Delorie 4bbd2ea80f rx.c (ADD_RX_BUILTIN0): New macro, used for builtins that take no arguments.
* config/rx/rx.c (ADD_RX_BUILTIN0): New macro, used for builtins
that take no arguments.

From-SVN: r204239
2013-10-30 20:29:49 -04:00
GCC Administrator d36ff35b33 Daily bump.
From-SVN: r204238
2013-10-31 00:17:05 +00:00
Joern Rennecke e27a6430c7 re PR rtl-optimization/58545 (error: unable to find a register to spill in class 'POINTER_REGS')
gcc:
        PR other/58545
        * reload1.c (update_eliminables_and_spill): New function, broken
        out of reload.
        (reload): Use it.  Check for frame size change after frame
        size alignment, and call update_eliminables_and_spill first
        if continue-ing.
gcc/testsuite:
        PR other/58545
        * gcc.target/avr/pr58545.c: New test.

From-SVN: r204234
2013-10-30 23:55:46 +00:00
Balaji V. Iyer fbdec79172 Fix for bug Bootstrap/58918.
+2013-10-30  Balaji V. Iyer  <balaji.v.iyer@intel.com>
+
+       * configure: Reconfigured.
+       * configure.ac: Add AC_FUNC_ALLOCA.
+       * runtime/sysdep-unix.c: Added check for alloca.h before
+       including it.
+       * config/x86/cilk-abi-vla.c: Likewise.
+       * runtime/cilk_fiber-unix.cpp: Likewise.
+

From-SVN: r204232
2013-10-30 15:51:29 -07:00
Jonathan Wakely 2283f03ac9 pointer_partial_void.cc: Fix and enable VERIFY tests.
* testsuite/29_atomics/atomic/operators/pointer_partial_void.cc: Fix
	and enable VERIFY tests.

From-SVN: r204231
2013-10-30 22:05:17 +00:00
Tobias Burnus adffea1e08 revert: cilk-plus.exp: Add the libcilkrts library path to the compile flags.
2013-10-30  Tobias Burnus  <burnus@net-b.de>

        Revert:
        2013-10-30  Tobias Burnus  <burnus@net-b.de>
        * gcc.dg/cilk-plus/cilk-plus.exp: Add the libcilkrts library
        path to the compile flags.

From-SVN: r204230
2013-10-30 21:29:06 +01:00
Cong Hou 8f24613d02 re PR target/58762 ([missed optimization] Vectorizing abs(int).)
2013-10-30  Cong Hou  <congh@google.com>

    PR target/58762
    * config/i386/i386-protos.h (ix86_expand_sse2_abs): New function.
    * config/i386/i386.c (ix86_expand_sse2_abs): New function.
    * config/i386/sse.md: Add SSE2 support to abs (8/16/32-bit-int).

2013-10-30  Cong Hou  <congh@google.com>

    * gcc.target/i386/vect-abs-s8.c: New test.
    * gcc.target/i386/vect-abs-s16.c: New test.
    * gcc.target/i386/vect-abs-s32.c: New test.

From-SVN: r204229
2013-10-30 16:01:47 -04:00
Jason Merrill afbb631e67 semantics.c (finish_compound_literal): Don't create a static variable inside cp_unevaluated_operand.
* semantics.c (finish_compound_literal): Don't create a static variable
	inside cp_unevaluated_operand.

From-SVN: r204228
2013-10-30 15:51:23 -04:00
Tobias Burnus fc7f44e4c4 cilk-plus.exp: Add the libcilkrts library path to the compile flags.
2013-10-30  Tobias Burnus  <burnus@net-b.de>

        * gcc.dg/cilk-plus/cilk-plus.exp: Add the libcilkrts library
        path to the compile flags.

From-SVN: r204227
2013-10-30 20:51:17 +01:00
Jason Merrill 04056396ec * init.c (push_base_cleanups): Check ANON_AGGR_TYPE_P.
From-SVN: r204226
2013-10-30 15:50:36 -04:00
Jonathan Wakely 8d52ed5c81 shared_ptr (__shared_ptr): Assert non-void pointer.
* include/bits/shared_ptr (__shared_ptr): Assert non-void pointer.
	* include/bits/shared_ptr (default_delete): Likewise.
	* testsuite/20_util/shared_ptr/cons/58839.cc: Do not use
	default_delete<void>.
	* testsuite/20_util/shared_ptr/cons/void_neg.cc: New.
	* testsuite/20_util/default_delete/void_neg.cc: New.
	* testsuite/20_util/shared_ptr/cons/43820_neg.cc: Adjust line numbers.
	* testsuite/20_util/unique_ptr/assign/48635_neg.cc: Likewise.

From-SVN: r204225
2013-10-30 19:48:52 +00:00
Jeff Law 4608893952 re PR rtl-optimization/58369 (ICE in subreg_get_info when compiling boost for m68k-linux)
PR rtl-optimization/58369
	* reload1.c (compute_reload_subreg_offset): New function.
	(choose_reload_regs): Use it to pass endian-correct
	offset to subreg_regno_offset.

	* PR rtl-optimization/58369
	* g++.dg/torture/pr58369.C: New test.

From-SVN: r204224
2013-10-30 13:21:27 -06:00
Tobias Burnus c5028d807f re PR other/33426 (Support of #pragma ivdep)
2013-10-30  Tobias Burnus  <burnus@net-b.de>

gcc/cp/
        PR other/33426
        * cp-tree.h (RANGE_FOR_IVDEP): Define.
        (cp_convert_range_for, finish_while_stmt_cond, finish_do_stmt,
        finish_for_cond): Take 'bool ivdep' parameter.
        * cp-array-notation.c (create_an_loop): Update call.
        * init.c (build_vec_init): Ditto.
        * pt.c (tsubst_expr): Ditto.
        * parser.c (cp_parser_iteration_statement, cp_parser_for,
        cp_parser_range_for, cp_convert_range_for): Update calls.
        (cp_parser_pragma): Accept GCC ivdep for 'while' and 'do'.
        * semantics.c (finish_while_stmt_cond, finish_do_stmt,
        finish_for_cond): Optionally build ivdep annotation.

gcc/testsuite/
        PR other/33426
        * g++.dg/vect/pr33426-ivdep-2.cc: New.
        * g++.dg/vect/pr33426-ivdep-3.cc: New.
        * g++.dg/vect/pr33426-ivdep-4.cc: New.

gcc/
        PR other/33426
        * gcc/tree-cfg.c (replace_loop_annotate): Replace warning by
        warning_at.

From-SVN: r204223
2013-10-30 19:53:42 +01:00
Jakub Jelinek 1079f7a198 re PR target/47754 ([missed optimization] AVX allows unaligned memory operands but GCC uses unaligned load and register operand)
PR target/47754
	* config/i386/i386.c (ix86_avx256_split_vector_move_misalign): If
	op1 is misaligned_operand, just use *mov<mode>_internal insn
	rather than UNSPEC_LOADU load.
	(ix86_expand_vector_move_misalign): Likewise (for TARGET_AVX only).
	Avoid gen_lowpart on op0 if it isn't MEM.

	* gcc.target/i386/avx256-unaligned-load-1.c: Adjust scan-assembler
	and scan-assembler-not regexps.
	* gcc.target/i386/avx256-unaligned-load-2.c: Likewise.
	* gcc.target/i386/avx256-unaligned-load-3.c: Likewise.
	* gcc.target/i386/avx256-unaligned-load-4.c: Likewise.
	* gcc.target/i386/l_fma_float_1.c: Use pattern for
	scan-assembler-times instead of just one insn name.
	* gcc.target/i386/l_fma_float_2.c: Likewise.
	* gcc.target/i386/l_fma_float_3.c: Likewise.
	* gcc.target/i386/l_fma_float_4.c: Likewise.
	* gcc.target/i386/l_fma_float_5.c: Likewise.
	* gcc.target/i386/l_fma_float_6.c: Likewise.
	* gcc.target/i386/l_fma_double_1.c: Likewise.
	* gcc.target/i386/l_fma_double_2.c: Likewise.
	* gcc.target/i386/l_fma_double_3.c: Likewise.
	* gcc.target/i386/l_fma_double_4.c: Likewise.
	* gcc.target/i386/l_fma_double_5.c: Likewise.
	* gcc.target/i386/l_fma_double_6.c: Likewise.

From-SVN: r204219
2013-10-30 18:59:44 +01:00
Jason Merrill 3e4403a4c4 * decl.c (cp_finish_decl): Never throw for VLA bound == 0.
From-SVN: r204218
2013-10-30 13:30:10 -04:00
Jason Merrill 1652c6dada Makefile.tpl (STAGE1_CONFIGURE_FLAGS): Pass --disable-build-format-warnings.
/
	* Makefile.tpl (STAGE1_CONFIGURE_FLAGS): Pass
	--disable-build-format-warnings.
gcc/
	* configure.ac (loose_warn): Add -Wno-format if
	--disable-build-format-warnings.

From-SVN: r204217
2013-10-30 13:30:05 -04:00
David Malcolm 378cd6b1e3 Split symtab_node declarations onto multiple lines
gcc/
	* cgraphunit.c (analyze_functions): Split symtab_node
	declarations onto multiple lines to make things easier
	for rename_symtab.py.

	* symtab.c (symtab_dissolve_same_comdat_group_list): Likewise.
	(symtab_semantically_equivalent_p): Likewise.

gcc/lto
	* lto-symtab.c (lto_symtab_merge_decls_2): Split symtab_node
	declarations onto multiple lines to make things easier for
	rename_symtab.py.
	(lto_symtab_merge_decls_1): Likewise.
	(lto_symtab_merge_symbols_1): Likewise.

From-SVN: r204216
2013-10-30 15:58:45 +00:00
Vladimir Makarov a26891f4f5 re PR target/58784 ([ARM] LRA legitimate address issue with misalign neon_store)
2013-10-30  Vladimir Makarov  <vmakarov@redhat.com>

	PR target/58784
	* lra.c (check_rtl): Remove address check before LRA work.

2013-10-30  Vladimir Makarov  <vmakarov@redhat.com>

	PR target/58784
	* gcc.target/arm/pr58784.c: New.

From-SVN: r204215
2013-10-30 15:04:39 +00:00
Marc Glisse 6ecb8b21c8 tree-ssa-alias.c (ao_ref_init_from_ptr_and_size): Look for a POINTER_PLUS_EXPR in the defining statement.
2013-10-30  Marc Glisse  <marc.glisse@inria.fr>

gcc/
	* tree-ssa-alias.c (ao_ref_init_from_ptr_and_size): Look for a
	POINTER_PLUS_EXPR in the defining statement.

gcc/testsuite/
	* gcc.dg/tree-ssa/alias-24.c: New file.

From-SVN: r204213
2013-10-30 14:33:49 +00:00
Vladimir Makarov 3b6d16993b regmove.c: Remove.
2013-10-30  Vladimir Makarov  <vmakarov@redhat.com>

	* regmove.c: Remove.
	* tree-pass.h (make_pass_regmove): Remove.
	* timevar.def (TV_REGMOVE): Remove.
	* passes.def (pass_regmove): Remove.
	* opts.c (default_options_table): Remove entry for regmove.
	* doc/passes.texi: Remove regmove pass description.
	* doc/invoke.texi (-foptimize-register-move, -fregmove): Remove
	options.
	(-fdump-rtl-regmove): Ditto.
	* common.opt (foptimize-register-move, fregmove): Ignore.
	* Makefile.in (OBJS): Remove regmove.o.
	* regmove.c: Remove.
	* ira-int.h (struct ira_allocno_pref, ira_pref_t): New structure
	and type.
	(struct ira_allocno) New member allocno_prefs.
	(ALLOCNO_PREFS): New macro.
	(ira_prefs, ira_prefs_num): New external vars.
	(ira_setup_alts, ira_get_dup_out_num, ira_debug_pref): New
	prototypes.
	(ira_debug_prefs, ira_debug_allocno_prefs, ira_create_pref):
	Ditto.
	(ira_add_allocno_pref, ira_remove_pref, ira_remove_allocno_prefs):
	Ditto.
	(ira_add_allocno_copy_to_list): Remove prototype.
	(ira_swap_allocno_copy_ends_if_necessary): Ditto.
	(ira_pref_iterator): New type.
	(ira_pref_iter_init, ira_pref_iter_cond): New functions.
	(FOR_EACH_PREF): New macro.
	* ira.c (commutative_constraint_p): Move from ira-conflicts.c.
	(ira_get_dup_out_num): Ditto. Rename from get_dup_num.  Modify the
	code.
	(ira_setup_alts): New function.
	(decrease_live_ranges_number): New function.
	(ira): Call the above function.
	* ira-build.c (ira_prefs, ira_prefs_num): New global vars.
	(ira_create_allocno): Initialize allocno prefs.
	(pref_pool, pref_vec): New static vars.
	(initiate_prefs, find_allocno_pref, ira_create_pref): New
	functions.
	(add_allocno_pref_to_list, ira_add_allocno_pref, print_pref): Ditto.
	(ira_debug_pref, print_prefs, ira_debug_prefs): Ditto.
	(print_allocno_prefs, ira_debug_allocno_prefs, finish_pref): Ditto.
	(ira_remove_pref, ira_remove_allocno_prefs, finish_prefs): Ditto.
	(ira_add_allocno_copy_to_list): Make static.  Rename to
	add_allocno_copy_to_list.
	(ira_swap_allocno_copy_ends_if_necessary): Make static.  Rename to
	swap_allocno_copy_ends_if_necessary.
	(remove_unnecessary_allocnos, remove_low_level_allocnos): Call
	ira_remove_allocno_prefs.
	(ira_flattening): Ditto.
	(ira_build): Call initiate_prefs, print_prefs.
	(ira_destroy): Call finish_prefs.
	* ira-color.c (struct update_cost_record): New.
	(struct allocno_color_data): Add new member update_cost_records.
	(update_cost_record_pool): New static var.
	(init_update_cost_records, get_update_cost_record): New functions.
	(free_update_cost_record_list, finish_update_cost_records): Ditto.
	(struct update_cost_queue_elem): Add member from.
	(initiate_cost_update): Call init_update_cost_records.
	(finish_cost_update): Call finish_update_cost_records.
	(queue_update_cost, get_next_update_cost): Add new param from.
	(Update_allocno_cost, update_costs_from_allocno): New functions.
	(update_costs_from_prefs): Ditto.
	(update_copy_costs): Rename to update_costs_from_copies.
	(restore_costs_from_copies): New function.
	(update_conflict_hard_regno_costs): Don't go back.
	(assign_hard_reg): Call restore_costs_from_copies.  Add printing
	more debug info.
	(pop_allocnos): Add priniting more debug info.
	(color_allocnos): Remove prefs for conflicting hard regs.
	Call update_costs_from_prefs.
	* ira-conflicts.c (commutative_constraint_p): Move to ira.c
	(get_dup_num): Rename, modify, and move to ira.c
	(process_regs_for_copy): Add prefs.
	(add_insn_allocno_copies): Put src as first arg of
	process_regs_for_copy.  Remove dead code.  Call ira_setup_alts.
	* ira-costs.c (record_reg_classes): Modify and move code into
	record_operands_costs.
	(find_costs_and_classes): Create prefs for the hard reg of small
	reg class.
	(process_bb_node_for_hard_reg_moves): Add prefs.

2013-10-30  Vladimir Makarov  <vmakarov@redhat.com>

	* gcc.target/i386/fma_double_3.c: Use pattern for
	scan-assembler-times instead of just one insn name.
	* gcc.target/i386/fma_double_5.c: Ditto.
	* gcc.target/i386/fma_float_3.c: Ditto.
	* gcc.target/i386/fma_float_5.c: Ditto.
	* gcc.target/i386/l_fma_double_1.c: Ditto.
	* gcc.target/i386/l_fma_double_2.c: Ditto.
	* gcc.target/i386/l_fma_double_3.c: Ditto.
	* gcc.target/i386/l_fma_double_4.c: Ditto.
	* gcc.target/i386/l_fma_double_5.c: Ditto.
	* gcc.target/i386/l_fma_double_6.c: Ditto.
	* gcc.target/i386/l_fma_float_1.c: Ditto.
	* gcc.target/i386/l_fma_float_2.c: Ditto.
	* gcc.target/i386/l_fma_float_3.c: Ditto.
	* gcc.target/i386/l_fma_float_4.c: Ditto.
	* gcc.target/i386/l_fma_float_5.c: Ditto.
	* gcc.target/i386/l_fma_float_6.c: Ditto.

From-SVN: r204212
2013-10-30 14:27:25 +00:00
Richard Biener 1bef9b2340 re PR rtl-optimization/57100 (ICE: in pre_and_rev_post_order_compute, at cfganal.c:869 with -fdump-rtl-pro_and_epilogue-graph)
2013-10-30  Richard Biener  <rguenther@suse.de>

	PR middle-end/57100
	* basic-block.h (pre_and_rev_post_order_compute_fn): New function.
	* cfganal.c (pre_and_rev_post_order_compute_fn): New function
	as worker for ...
	(pre_and_rev_post_order_compute): ... which now wraps it.
	* graph.c (draw_cfg_nodes_no_loops): Use
	pre_and_rev_post_order_compute_fn to avoid ICEing and dependence
	on cfun.

From-SVN: r204211
2013-10-30 14:22:01 +00:00
Jakub Jelinek 193ea7bc8c * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
From-SVN: r204209
2013-10-30 14:50:25 +01:00
Christian Bruel ca494b8d78 sh-mem.cc (sh_expand_cmpnstr): New function.
2013-10-30  Christian Bruel  <christian.bruel@st.com>

	* gcc/config/sh/sh-mem.cc (sh_expand_cmpnstr): New function.
	(sh_expand_cmpstr): Handle known align and schedule improvements.
	* gcc/config/sh/sh-protos.h (sh_expand_cmpstrn): Declare.
	* gcc/config/sh/sh.md (cmpstrnsi): New pattern.

From-SVN: r204206
2013-10-30 13:35:27 +01:00
Martin Jambor eb1474c1a2 re PR rtl-optimization/10474 (shrink wrapping for functions)
2013-10-30  Martin Jambor  <mjambor@suse.cz>

	PR rtl-optimization/10474
	* ira.c (find_moveable_pseudos): Do not calculate dominance info
	nor df analysis.
	(interesting_dest_for_shprep): New function.
	(split_live_ranges_for_shrink_wrap): Likewise.
	(ira): Calculate dominance info and df analysis. Call
	split_live_ranges_for_shrink_wrap.

testsuite/
	* gcc.dg/pr10474.c: New testcase.
	* gcc.dg/ira-shrinkwrap-prep-1.c: Likewise.
	* gcc.dg/ira-shrinkwrap-prep-2.c: Likewise.

From-SVN: r204205
2013-10-30 13:01:46 +01:00
Ramana Radhakrishnan 55ebf58738 re PR target/58854 ("sub sp, fp, #40" hoisted above frame accesses)
Fix PR target/58854

2013-10-30  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>

	PR target/58854
	* config/arm/arm.c (arm_expand_epilogue_apcs_frame): Emit blockage.

From-SVN: r204203
2013-10-30 10:54:04 +00:00
Eric Botcazou 34a3fb96dc Minor tweaks
From-SVN: r204202
2013-10-30 10:36:49 +00:00
Ilya Enkovich ea9637cdcd tree-core.h (tree_index): Add TI_POINTER_BOUNDS_TYPE.
* tree-core.h (tree_index): Add TI_POINTER_BOUNDS_TYPE.
        * tree.h (POINTER_BOUNDS_P): New.
        (BOUNDED_TYPE_P): New.
        (BOUNDED_P): New.
        (pointer_bounds_type_node): New.
        * tree.c (build_common_tree_nodes): Initialize
        pointer_bounds_type_node.
        * gimple.h (gimple_call_get_nobnd_arg_index): New.
        (gimple_call_num_nobnd_args): New.
        (gimple_call_nobnd_arg): New.
        (gimple_return_retbnd): New.
        (gimple_return_set_retbnd): New
        * gimple.c (gimple_build_return): Increase number of ops
        for return statement.
        (gimple_call_get_nobnd_arg_index): New.
        * gimple-pretty-print.c (dump_gimple_return): Print second op.

From-SVN: r204199
2013-10-30 09:09:44 +00:00
Ilya Enkovich 0038da6695 ipa.c (cgraph_build_static_cdtor_1): Support contructors with "chkp ctor" and "bnd_legacy" attributes.
* ipa.c (cgraph_build_static_cdtor_1): Support contructors
        with "chkp ctor" and "bnd_legacy" attributes.
        * gimplify.c (gimplify_init_constructor): Avoid infinite
        loop during gimplification of bounds initializer.

From-SVN: r204198
2013-10-30 09:08:14 +00:00
Ilya Enkovich 2017035a60 c-common.c (handle_bnd_variable_size_attribute): New.
* c-family/c-common.c (handle_bnd_variable_size_attribute): New.
        (handle_bnd_legacy): New.
        (c_common_attribute_table): Add bnd_variable_size and bnd_legacy.
        * doc/extend.texi: Document bnd_variable_size and bnd_legacy
        attributes.

From-SVN: r204197
2013-10-30 09:07:24 +00:00
Ilya Enkovich 109719ebd4 builtin-types.def (BT_FN_VOID_CONST_PTR): New.
* builtin-types.def (BT_FN_VOID_CONST_PTR): New.
        (BT_FN_PTR_CONST_PTR): New.
        (BT_FN_CONST_PTR_CONST_PTR): New.
        (BT_FN_PTR_CONST_PTR_SIZE): New.
        (BT_FN_PTR_CONST_PTR_CONST_PTR): New.
        (BT_FN_VOID_PTRPTR_CONST_PTR): New.
        (BT_FN_VOID_CONST_PTR_SIZE): New.
        (BT_FN_PTR_CONST_PTR_CONST_PTR_SIZE): New.
        * chkp-builtins.def: New.
        * builtins.def: include chkp-builtins.def.
        (DEF_CHKP_BUILTIN): New.
        * builtins.c (expand_builtin): Support BUILT_IN_CHKP_INIT_PTR_BOUNDS,
        BUILT_IN_CHKP_NULL_PTR_BOUNDS, BUILT_IN_CHKP_COPY_PTR_BOUNDS,
        BUILT_IN_CHKP_CHECK_PTR_LBOUNDS, BUILT_IN_CHKP_CHECK_PTR_UBOUNDS,
        BUILT_IN_CHKP_CHECK_PTR_BOUNDS, BUILT_IN_CHKP_SET_PTR_BOUNDS,
        BUILT_IN_CHKP_NARROW_PTR_BOUNDS, BUILT_IN_CHKP_STORE_PTR_BOUNDS,
        BUILT_IN_CHKP_GET_PTR_LBOUND, BUILT_IN_CHKP_GET_PTR_UBOUND,
        BUILT_IN_CHKP_BNDMK, BUILT_IN_CHKP_BNDSTX, BUILT_IN_CHKP_BNDCL,
        BUILT_IN_CHKP_BNDCU, BUILT_IN_CHKP_BNDLDX, BUILT_IN_CHKP_BNDRET,
        BUILT_IN_CHKP_INTERSECT, BUILT_IN_CHKP_ARG_BND, BUILT_IN_CHKP_NARROW,
        BUILT_IN_CHKP_EXTRACT_LOWER, BUILT_IN_CHKP_EXTRACT_UPPER.
        * common.opt (fcheck-pointer-bounds): New.
        * toplev.c (process_options): Check Pointer Bounds Checker is supported.
        * doc/extend.texi: Document Pointer Bounds Checker built-in functions.

From-SVN: r204196
2013-10-30 09:06:20 +00:00
Ilya Enkovich f481a2ce85 target.def (builtin_chkp_function): New.
* target.def (builtin_chkp_function): New.
        (chkp_bound_type): New.
        (chkp_bound_mode): New.
        (fn_abi_va_list_bounds_size): New.
        (load_bounds_for_arg): New.
        (store_bounds_for_arg): New.
        * targhooks.h (default_load_bounds_for_arg): New.
        (default_store_bounds_for_arg): New.
        (default_fn_abi_va_list_bounds_size): New.
        (default_chkp_bound_type): New.
        (default_chkp_bound_mode): New.
        (default_builtin_chkp_function): New.
        * targhooks.c (default_load_bounds_for_arg): New.
        (default_store_bounds_for_arg): New.
        (default_fn_abi_va_list_bounds_size): New.
        (default_chkp_bound_type): New.
        (default_chkp_bound_mode); New.
        (default_builtin_chkp_function): New.
        * doc/tm.texi.in (TARGET_FN_ABI_VA_LIST_BOUNDS_SIZE): New.
        (TARGET_LOAD_BOUNDS_FOR_ARG): New.
        (TARGET_STORE_BOUNDS_FOR_ARG): New.
        (TARGET_BUILTIN_CHKP_FUNCTION): New.
        (TARGET_CHKP_BOUND_TYPE): New.
        (TARGET_CHKP_BOUND_MODE): New.
        * doc/tm.texi: Regenerated.
        * langhooks.h (lang_hooks): Add chkp_supported field.
        * langhooks-def.h (LANG_HOOKS_CHKP_SUPPORTED): New.
        (LANG_HOOKS_INITIALIZER); Add LANG_HOOKS_CHKP_SUPPORTED.

From-SVN: r204195
2013-10-30 08:57:50 +00:00