1. 12 Nov, 2013 16 commits
    • gimple-expr.h (create_tmp_var_name, [...]): Relocate prototypes from gimple.h. · 45b0be94
      
      2013-11-12  Andrew MacLeod  <amacleod@redhat.com>
      
      	* gimple-expr.h (create_tmp_var_name, create_tmp_var_raw,
      	create_tmp_var, create_tmp_reg, mark_addressable, is_gimple_reg_rhs):
      	Relocate prototypes from gimple.h.
      	* gimplify.h: New File.  Relocate some prototypes from gimple.h here.
      	(gimple_predicate, enum fallback, enum gimplify_status): Relocate
      	from gimple.h.
      	* gimple.h: Move some prototypes to gimplify.h.
      	(gimple_predicate, enum fallback, enum gimplify_status): Move to
      	gimplify.h.
      	(gimple_do_not_emit_location_p, gimple_set_do_not_emit_location):
      	Relocate from gimpify.c.
      	* gimple-expr.c (remove_suffix, tmp_var_id_num, create_tmp_var_name,
      	create_tmp_var_raw, create_tmp_var, create_tmp_reg, mark_addressable,
      	is_gimple_reg_rhs) Relocate from gimplify.c.
      	* gimplify.c (mark_addressable): Move to gimple-expr.c.
      	(gimple_seq_add_stmt_without_update): Move to gimple.c.
      	(remove_suffix, tmp_var_id_num, create_tmp_var_name, create_tmp_var_raw,
      	create_tmp_var, create_tmp_reg, is_gimple_reg_rhs): Move to 
      	gimple-expr.c.
      	(should_carry_location_p): Move to gimple.c.
      	(gimple_do_not_emit_location_p, gimple_set_do_not_emit_location): Move
      	to gimple.h.
      	(annotate_one_with_location, annotate_all_with_location_after,
      	annotate_all_with_location): Move to gimple.c.
      	(compare_case_labels, sort_case_labels,
      	preprocess_case_label_vec_for_gimple): Move to gimple.c.
      	(rhs_predicate_for): Make static.
      	(gimplify_assign): Relocate from gimple.c.
      	* gimple.c (gimplify_assign): Move to gimplify.c.
      	(gimple_seq_add_stmt_without_update, should_carry_location_p,
      	annotate_one_with_location, annotate_all_with_location_after,
      	annotate_all_with_location, compare_case_labels, sort_case_labels,
      	preprocess_case_label_vec_for_gimple): Relocate from gimplify.c.
      	* tree.h (unshare_expr, unshare_expr_without_location,
      	mark_addressable): Move prototypes to gimplify.h.
      	* Makefile.in (GTFILES): gimple-expr.c now has the GTY tag for
      	tmp_var_id_num
      	* asan.c: Include gimplify.h rather than gimple.h.
      	* cfgloopmanip.c: Likewise.
      	* cgraphunit.c: Likewise.
      	* cilk-common.c: Likewise.
      	* dwarf2out.c: Dont include gimple.h.
      	* fold-const.c: Include gimplify.h rather than gimple.h.
      	* function.c: Likewise.
      	* gimple-fold.c: Likewise.
      	* gimple-ssa-strength-reduction.c: Likewise.
      	* graphite-clast-to-gimple.c: Likewise.
      	* graphite-sese-to-poly.c: Likewise.
      	* ipa-prop.c: Likewise.
      	* ipa-split.c: Likewise.
      	* ipa.c: Likewise.
      	* langhooks.c: Dont include gimple.h.
      	* loop-init.c: Include gimplify.h rather than gimple.h.
      	* omp-low.c: Likewise.
      	* sese.c: Likewise.
      	* stor-layout.c: Likewise.
      	* targhooks.c: Likewise.
      	* trans-mem.c: Likewise.
      	* tree-affine.c: Likewise.
      	* tree-cfg.c: Likewise.
      	* tree-cfgcleanup.c: Likewise.
      	* tree-complex.c: Likewise.
      	* tree-if-conv.c: Likewise.
      	* tree-inline.c: Likewise.
      	* tree-iterator.c: Likewise.
      	* tree-loop-distribution.c: Likewise.
      	* tree-nested.c: Likewise.
      	* tree-parloops.c: Likewise.
      	* tree-predcom.c: Likewise.
      	* tree-profile.c: Likewise.
      	* tree-scalar-evolution.c: Likewise.
      	* tree-sra.c: Likewise.
      	* tree-ssa-address.c: Likewise.
      	* tree-ssa-ccp.c: Likewise.
      	* tree-ssa-dce.c: Likewise.
      	* tree-ssa-forwprop.c: Likewise.
      	* tree-ssa-ifcombine.c: Likewise.
      	* tree-ssa-loop-im.c: Likewise.
      	* tree-ssa-loop-ivopts.c: Likewise.
      	* tree-ssa-loop-manip.c: Likewise.
      	* tree-ssa-loop-niter.c: Likewise.
      	* tree-ssa-loop-prefetch.c: Likewise.
      	* tree-ssa-loop-unswitch.c: Likewise.
      	* tree-ssa-math-opts.c: Likewise.
      	* tree-ssa-phiopt.c: Likewise.
      	* tree-ssa-phiprop.c: Likewise.
      	* tree-ssa-pre.c: Likewise.
      	* tree-ssa-propagate.c: Likewise.
      	* tree-ssa-reassoc.c: Likewise.
      	* tree-ssa-sccvn.c: Likewise.
      	* tree-ssa-strlen.c: Likewise.
      	* tree-ssa.c: Likewise.
      	* tree-switch-conversio: Likewise.n.c
      	* tree-tailcall.c: Likewise.
      	* tree-vect-data-refs.c: Likewise.
      	* tree-vect-generic.c: Likewise.
      	* tree-vect-loop-manip.c: Likewise.
      	* tree-vect-loop.c: Likewise.
      	* tree-vect-patterns.c: Likewise.
      	* tree-vect-stmts.c: Likewise.
      	* tsan.c: Likewise.
      	* value-prof.c: Likewise.
      	* config/aarch64/aarch64.c: Include gimplify.h instead of gimple.h.
      	* config/alpha/alpha.c: Likewise.
      	* config/darwin.c: Likewise.
      	* config/i386/i386.c: Likewise.
      	* config/ia64/ia64.c: Likewise.
      	* config/mep/mep.c: Likewise.
      	* config/mips/mips.c: Likewise.
      	* config/rs6000/rs6000.c: Likewise.
      	* config/s390/s390.c: Likewise.
      	* config/sh/sh.c: Likewise.
      	* config/sparc/sparc.c: Likewise.
      	* config/spu/spu.c: Likewise.
      	* config/stormy16/stormy16.c: Likewise.
      	* config/tilegx/tilegx.c: Likewise.
      	* config/tilepro/tilepro.c: Likewise.
      	* config/xtensa/xtensa.c: Likewise.
      
      	* ada/gcc-interface/trans.c: Include gimplify.h.
      
      	* c/c-typeck.c: Include gimplify.h.
      
      	* c-family/c-common.c: Include gimplify.h.
      	* c-family/c-gimplify.c: Likewise.
      	* c-family/cilk.c: Likewise.
      	* c-family/c-omp.c: Include gimple-expr.h instead of gimple.h.
      	* c-family/c-ubsan.c: Don't include gimple.h.
      
      	* cp/class.c: Include gimplify.h.
      	* cp/cp-gimplify.c: Likewise.
      	* cp/error.c: Likewise.
      	* cp/init.c: Likewise.
      	* cp/optimize.c: Likewise.
      	* cp/pt.c: Likewise.
      	* cp/semantics.c: Likewise.
      	* cp/tree.c: Likewise.
      	* cp/vtable-class-hierarchy.c: Likewise.
      	* cp/decl2.c: Don't include gimple.h.
      	* cp/except.c: Likewise.
      	* cp/method.c: Include pointer-set.h instead of gimple.h.
      
      	* fortran/f95-lang.c: Don't include gimple.h.
      	* fortran/trans-array.c: Include gimple-expr.h instead of gimple.h.
      	* fortran/trans.c: Likewise.
      	* fortran/trans-decl.c: Likewise.
      	* fortran/trans-expr.c: Include gimplify.h.
      	* fortran/trans-openmp.c: Likewise.
      
      	* go/go-lang.c: Include gimplify.h.
      
      	* java/java-gimplify.c: Include gimplify.h.
      
      	* objc/objc-act.c: Include gimplify.h.
      
      From-SVN: r204717
      Andrew MacLeod committed
    • Add some generic lambda test cases. · c9a584aa
      gcc/testsuite/g++.dg/cpp1y/
      	* lambda-generic.C: New test case.
      	* lambda-generic-cfun.C: New test case.
      	* lambda-generic-dep.C: New test case.
      	* lambda-generic-udt.C: New test case.
      	* lambda-generic-variadic.C: New test case.
      	* lambda-generic-x.C: New test case.
      	* lambda-generic-xcfun.C: New test case.
      	* lambda-generic-xudt.C: New test case.
      	* lambda-generic-mixed.C: New test case.
      
      From-SVN: r204716
      Adam Butcher committed
    • Support implicit parameter packs. · 91f1c208
      	* pt.c (convert_generic_types_to_packs): New function to transform
      	a range of implicitly introduced non-pack template parms to be parameter
      	packs.
      	* cp-tree.h (convert_generic_types_to_packs): Declare.
      	* parser.c (cp_parser_parameter_declaration_list): If a function
      	parameter pack contains generic types, convert them to packs prior to
      	grokdeclarator.
      
      From-SVN: r204715
      Adam Butcher committed
    • Refactor implicit function template implementation and fix 58534, 58536, 58548, 58549 and 58637. · 0dca5025
      gcc/
      	* tree.c (grow_tree_vec_stat): New function ...
      	* tree.h (grow_tree_vec_stat) (grow_tree_vec): ... and its declaration
      	and macro front-end.
      
      gcc/cp/
      	PR c++/58534
      	PR c++/58536
      	PR c++/58548
      	PR c++/58549
      	PR c++/58637
      	* parser.h (struct cp_parser): New members implicit_template_parms,
      	implicit_template_scope and auto_is_implicit_function_template_parm_p.
      	* parser.c (add_implicit_template_parms): Refactor as ...
      	(synthesize_implicit_template_parm): ... this to append a new template
      	type parm to the current template parameter list (introducing a new list
      	if necessary).  Removed push_deferring_access_checks.
      	(finish_fully_implicit_template): Removed pop_deferring_access_checks.
      	(cp_parser_new): Initialize new cp_parser members.
      	(cp_parser_parameter_declaration_clause): Consider auto as implicit
      	template parm when parsing a parameter declaration (unless parsing an
      	explicit specialization).
      	(cp_parser_parameter_declaration_list): Remove local
      	implicit_template_parms counter and reset cp_parser implicit template
      	state when complete.
      	(cp_parser_lambda_expression): Reset implicit template cp_parser members
      	whilst generating lambda class.
      	(cp_parser_function_definition_after_declarator): Reset implicit
      	template cp_parser members whilst parsing function definition.
      	(make_generic_type_name): Respell '<autoN>' as 'auto:N' which works
      	better with template diagnostics.
      	(cp_parser_simple_type_specifier): Synthesize implicit template parm on
      	parsing 'auto' if auto_is_implicit_function_template_parm_p and provide
      	diagnostics ...
      	* decl.c (grokdeclarator): ... that were previously done here.
      
      gcc/testsuite/g++.dg/
      	* cpp1y/pr58534.C: New testcase.
      	* cpp1y/pr58536.C: New testcase.
      	* cpp1y/pr58548.C: New testcase.
      	* cpp1y/pr58549.C: New testcase.
      	* cpp1y/pr58637.C: New testcase.
      
      From-SVN: r204714
      Adam Butcher committed
    • cp-demangle.c (d_copy_templates): Cast result of malloc to (struct d_print_template *). · 27297d2d
      	* cp-demangle.c (d_copy_templates): Cast result of malloc
      	to (struct d_print_template *).
      	(d_print_comp): Cast result of realloc to (struct d_saved scope *).
      
      From-SVN: r204713
      Uros Bizjak committed
    • final.c (update_alignments): Initialize label to NULL_RTX. · 33fd5699
      2013-11-12  Marek Polacek  <polacek@redhat.com>
      
      	* final.c (update_alignments): Initialize label to NULL_RTX.
      
      From-SVN: r204712
      Marek Polacek committed
    • c-common.c (c_common_reswords): Add _Thread_local. · 582d9b50
      c-family:
      	* c-common.c (c_common_reswords): Add _Thread_local.
      
      c:
      	* c-tree.h (struct c_declspecs): Add thread_gnu_p field.
      	* c-parser.c (c_parser_declspecs): Mention _Thread_local in
      	comment.
      	* c-decl.c (shadow_tag_warned, grokdeclarator): Mention __thread
      	or _Thread_local as appropriate in diagnostics.
      	(build_null_declspecs): Initialize ret->thread_gnu_p.
      	(declspecs_add_scspec): Handle either __thread or _Thread_local
      	for RID_THREAD.  Diagnose _Thread_local for pre-C11 standards if
      	pedantic.  Do not disallow _Thread_local extern and _Thread_local
      	static.
      
      testsuite:
      	* gcc.dg/c90-thread-local-1.c, gcc.dg/c99-thread-local-1.c,
      	gcc.dg/c11-thread-local-1.c, gcc.dg/c11-thread-local-2.c: New
      	tests.
      	* gcc.dg/tls/diag-2.c, objc.dg/tls/diag-2.m: Update expected
      	diagnostics.
      
      From-SVN: r204711
      Joseph Myers committed
    • aggr21.adb: New test. · e9dc0547
      	* gnat.dg/aggr21.adb: New test.
      	* gnat.dg/aggr21_pkg.ad[sb]: New helper.
      
      From-SVN: r204710
      Tristan Gingold committed
    • gimple-ssa-isolate-paths.c (check_loadstore): New function. · 6ab7a3d7
      	* gimple-ssa-isolate-paths.c (check_loadstore): New function.
      	(insert_trap_and_remove_trailing_statements): New argument OP which
      	is the NULL pointer.  Emit the trap after the load/store through
      	the NULL pointer.  Simplify the RHS of a store through a NULL pointer
      	when trivial to do so.
      	(isolate_path): Corresponding changes.
      	(gimple_ssa_isolate_erroneous_path): Likewise.
      
      	* gcc.dg/tree-ssa/isolate-1.c: Update expected output.
      	* gcc.dg/tree-ssa/isolate-5.c: New test.
      
      From-SVN: r204708
      Jeff Law committed
    • predict.c (drop_profile): New function. · eb4b92c1
      2013-11-12  Teresa Johnson  <tejohnson@google.com>
      	    Jan Hubicka  <jh@suse.cz>
      
      	* predict.c (drop_profile): New function.
      	(handle_missing_profiles): Ditto.
      	(counts_to_freqs): Don't overwrite estimated frequencies
      	when function has no profile counts.
      	* predict.h (handle_missing_profiles): Declare.
      	* tree-inline.c (freqs_to_counts): New function.
      	(copy_cfg_body): Invoke freqs_to_counts as needed.
      	* tree-profile.c (tree_profiling): Invoke handle_missing_profiles.
      
      Co-Authored-By: Jan Hubicka <jh@suse.cz>
      
      From-SVN: r204704
      Teresa Johnson committed
    • Turn on SEE unaligned load and store for Haswell · a720b48e
      	PR target/59088
      	* config/i386/x86-tune.def (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL):
      	Set for m_HASWELL.
      	(X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Set for m_HASWELL.
      
      From-SVN: r204701
      H.J. Lu committed
    • Properly handle AVX256 unaligned load and store · cd3c1b1c
      	PR target/59084
      	* config/i386/i386.c (ix86_option_override_internal): Check
      	X86_TUNE_AVX256_UNALIGNED_LOAD_OPTIMAL and
      	X86_TUNE_AVX256_UNALIGNED_STORE_OPTIMAL for
      	MASK_AVX256_SPLIT_UNALIGNED_LOAD and
      	MASK_AVX256_SPLIT_UNALIGNED_STORE.
      
      	* config/i386/x86-tune.def (X86_TUNE_AVX256_UNALIGNED_LOAD_OPTIMAL):
      	Clear m_COREI7_AVX and update comments.
      	(X86_TUNE_AVX256_UNALIGNED_STORE_OPTIMAL): Likewise.
      
      From-SVN: r204700
      H.J. Lu committed
    • re PR rtl-optimization/10474 (shrink wrapping for functions) · 732dad8f
      2013-11-12  Martin Jambor  <mjambor@suse.cz>
      
      	PR rtl-optimization/10474
      	* ira.c (interesting_dest_for_shprep): New function.
      	(split_live_ranges_for_shrink_wrap): Likewise.
      	(find_moveable_pseudos): Move calculation of dominance info,
      	df_analysios and the final anlyses to...
      	(ira): ...here, 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: r204698
      Martin Jambor committed
    • re PR c++/57734 (Returning template alias to enum class fails with "invalid declarator") · e4c04ff0
      /cp
      2013-11-12  Paolo Carlini  <paolo.carlini@oracle.com>
      
      	PR c++/57734
      	* pt.c (lookup_template_class_1): Handle alias template declarations
      	of enumeration types.
      
      /testsuite
      2013-11-12  Paolo Carlini  <paolo.carlini@oracle.com>
      
      	PR c++/57734
      	* g++.dg/cpp0x/alias-decl-enum-1.C: New.
      
      From-SVN: r204697
      Paolo Carlini committed
    • tree-ssa-loop-ivopts.c (force_expr_to_var_cost): Refactor the code. · 801a661c
      	* tree-ssa-loop-ivopts.c (force_expr_to_var_cost): Refactor the code.
      	Handle type conversion.
      
      From-SVN: r204695
      Bin Cheng committed
    • Daily bump. · 97a23b74
      From-SVN: r204693
      GCC Administrator committed
  2. 11 Nov, 2013 20 commits
  3. 10 Nov, 2013 4 commits
    • cvt.c (cp_convert_to_pointer): Call build_ptrmemfunc before… · f61af651
      cvt.c (cp_convert_to_pointer): Call build_ptrmemfunc before maybe_warn_zero_as_null_pointer_constant to avoid...
      
      2013-11-10  Paolo Carlini  <paolo.carlini@oracle.com>
      
      	* cvt.c (cp_convert_to_pointer): Call build_ptrmemfunc before
      	maybe_warn_zero_as_null_pointer_constant to avoid duplicate
      	-Wzero-as-null-pointer-constant diagnostics.
      
      	* typeck.c (build_ptrmemfunc): Use cp_build_c_cast.
      
      From-SVN: r204655
      Paolo Carlini committed
    • Set close-on-exec flag when opening files. · c20fdb91
      2013-11-10  Janne Blomqvist  <jb@gcc.gnu.org>
      
      	* configure.ac: Check presence of mkostemp.
      	* io/unix.c (set_close_on_exec): New function.
      	(tempfile_open): Use mkostemp and O_CLOEXEC if available, fallback
      	to calling set_close_on_exec.
      	(regular_file): Add O_CLOEXEC to flags if defined.
      	(open_external): Call set_close_on_exec if O_CLOEXEC is not
      	defined.
      	* config.h.in: Regenerated.
      	* configure: Regenerated.
      	* Makefile.in: Regenerated.
      	* aclocal.m4: Regenerated.
      
      From-SVN: r204654
      Janne Blomqvist committed
    • Fixed typo about bug-number ... · 8d448338
              PR plugin/52872
              * configure.ac: Adding for exported symbols check
              and for rdynamic-check executable-extension.
              * configure: Regenerated.
      
      From-SVN: r204651
      Kai Tietz committed
    • re PR plugins/52872 (--enable-plugin; incorrect test for "exported symbols" and… · 93acd176
      re PR plugins/52872 (--enable-plugin; incorrect test for "exported symbols" and "-rdynamic" in gcc/configure.ac)
      
              PR plugin/52862
              * configure.ac: Adding for exported symbols check
              and for rdynamic-check executable-extension.
              * configure: Regenerated.
      
      Co-Authored-By: Kai Tietz <ktietz@redhat.com>
      
      From-SVN: r204650
      Karlson2k committed