1. 25 Jan, 2017 4 commits
    • [testsuite] Require shared effective target for some lto.exp tests · 9078cd36
      	* gcc.dg/lto/pr54709_0.c: Require 'shared' effective target.
      	* gcc.dg/lto/pr61526_0.c: Likewise.
      	* gcc.dg/lto/pr64415_0.c: Likewise.
      
      From-SVN: r244891
      Kyrylo Tkachov committed
    • re PR lto/79061 ([LTO][ASAN] LTO plus ASAN fails with "AddressSanitizer:… · e5e391d6
      re PR lto/79061 ([LTO][ASAN] LTO plus ASAN fails with "AddressSanitizer: initialization-order-fiasco")
      
      PR lto/79061
      
      gcc/
      
      	* asan.c (get_translation_unit_decl): New function.
      	(asan_add_global): Extract modules file name from globals
      	TRANSLATION_UNIT_DECL name.
      
      gcc/fortran/
      
      	* f95-lang.c (gfc_create_decls): Include stringpool.h.
      	Pass main_input_filename to build_translation_unit_decl.
      
      gcc/ada/
      
      	* gcc-interface/utils.c (get_global_context): Pass main_input_filename
      	to build_translation_unit_decl.
      
      gcc/c/
      
      	* c-decl.c (pop_scope): Pass main_input_filename to
      	build_translation_unit_decl.
      
      gcc/cp/
      
      	* decl.c (cxx_init_decl_processing): Pass main_input_filename
      	to build_translation_unit_decl.
      
      From-SVN: r244890
      Maxim Ostapenko committed
    • compiler: improvements for type alias handling · 98e20758
          
          Give an error for an attempt to define a method on an imported type.
          
          Give an error for each attempt to define a method on a builtin type.
          
          Adjust error messages to be closer to gc error messages.
          
          With these changes gccgo passes current tests on dev.typealias branch.
          
          This changes the errors printed for test/fixedbugs/issue5089.go, but
          the change is an improvement:
          
              Before:
                  fixedbugs/issue5089.go:13:1: error: redefinition of ‘bufio.Buffered’: receiver name changed
                   func (b *bufio.Reader) Buffered() int { // ERROR "non-local|redefinition"
                   ^
                  fixedbugs/issue5089.go:11:13: note: previous definition of ‘bufio.Buffered’ was here
                   import "bufio" // GCCGO_ERROR "previous"
                               ^
          
              Now:
                  fixedbugs/issue5089.go:13:7: error: may not define methods on non-local type
                   func (b *bufio.Reader) Buffered() int { // ERROR "non-local|redefinition"
                         ^
          
          Reviewed-on: https://go-review.googlesource.com/35642
      
      From-SVN: r244889
      Ian Lance Taylor committed
    • Daily bump. · 49d4fa43
      From-SVN: r244888
      GCC Administrator committed
  2. 24 Jan, 2017 28 commits
    • re PR c++/79205 (ICE in create_tmp_var, at gimple-expr.c:473) · 7cfd79d6
      	PR c++/79205
      	* cp-gimplify.c (cp_genericize_r): Add result of
      	convert_from_reference on invisiref parm to p_set.
      
      	* g++.dg/cpp1z/decomp22.C: New test.
      	* g++.dg/cpp1z/decomp23.C: New test.
      
      From-SVN: r244885
      Jakub Jelinek committed
    • op-common.h (_FP_MUL, [...]): Add /* FALLTHRU */ comments. · a8c9ef2a
      	* soft-fp/op-common.h (_FP_MUL, _FP_FMA, _FP_DIV): Add
      	/* FALLTHRU */ comments.
      
      From-SVN: r244884
      Jakub Jelinek committed
    • PR c++/78469 - defaulted ctor and inaccessible dtor · 1d7bc790
      	PR c++/78469 - defaulted ctor and inaccessible dtor
      	* cp-tree.h (tsubst_flags): Add tf_no_cleanup.
      	* init.c (build_new_1): Pass tf_no_cleanup to build_value_init.
      	* tree.c (build_target_expr): Check tf_no_cleanup.
      
      	PR c++/78469
      	* g++.dg/cpp0x/pr78469.C: New.
      
      From-SVN: r244882
      Nathan Sidwell committed
    • PR c++/79118 - anon-members and constexpr · 3e4b91f2
      	PR c++/79118 - anon-members and constexpr
      	* constexpr.c (cx_check_missing_mem_inits): Caller passes type not
      	ctor decl.  Recursively check anonymous members.
      	(register_constexpr_fundef): Adjust cx_check_missing_mem_inits
      	call.
      	(explain_invalid_constexpr_fn): Likewise.
      
      
      	PR c++/79118
      	* g++.dg/cpp0x/pr79118.C: New.
      
      From-SVN: r244881
      Nathan Sidwell committed
    • re PR target/77439 (wrong code for sibcall with longcall, APCS frame and VFP) · b20ba138
      	PR target/77439
      	* config/arm/arm.c (arm_function_ok_for_sibcall): Add back restriction
      	for long calls with APCS frame and VFP.
      
      From-SVN: r244879
      Eric Botcazou committed
    • Add "__RTL" to cc1 · c2e84327
      gcc/c-family/ChangeLog:
      	* c-common.c (c_common_reswords): Add "__RTL".
      	* c-common.h (enum rid): Add RID_RTL.
      
      gcc/c/ChangeLog:
      	* c-parser.c: Include "read-rtl-function.h" and
      	"run-rtl-passes.h".
      	(c_parser_declaration_or_fndef): Rename "gimple-pass-list" in
      	grammar to gimple-or-rtl-pass-list.  Add rtl-function-definition
      	production.  Update for renaming of field "gimple_pass" to
      	"gimple_or_rtl_pass".  If __RTL was seen, call
      	c_parser_parse_rtl_body.  Convert a timevar_push/pop pair
      	to an auto_timevar, to cope with early exit.
      	(c_parser_declspecs): Update RID_GIMPLE handling for renaming of
      	field "gimple_pass" to "gimple_or_rtl_pass", and for renaming of
      	c_parser_gimple_pass_list to c_parser_gimple_or_rtl_pass_list.
      	Handle RID_RTL.
      	(c_parser_parse_rtl_body): New function.
      	* c-tree.h (enum c_declspec_word): Add cdw_rtl.
      	(struct c_declspecs): Rename field "gimple_pass" to
      	"gimple_or_rtl_pass".  Add field "rtl_p".
      	* gimple-parser.c (c_parser_gimple_pass_list): Rename to...
      	(c_parser_gimple_or_rtl_pass_list): ...this, updating accordingly.
      	* gimple-parser.h (c_parser_gimple_pass_list): Rename to...
      	(c_parser_gimple_or_rtl_pass_list): ...this.
      
      gcc/ChangeLog:
      	* cfg.c (original_copy_tables_initialized_p): New function.
      	* cfg.h (original_copy_tables_initialized_p): New decl.
      	* cfgrtl.c (relink_block_chain): Guard the call to
      	free_original_copy_tables with a call to
      	original_copy_tables_initialized_p.
      	* cgraph.h (symtab_node::native_rtl_p): New decl.
      	* cgraphunit.c (symtab_node::native_rtl_p): New function.
      	(symtab_node::needed_p): Don't assert for early assembly output
      	for __RTL functions.
      	(cgraph_node::finalize_function): Set "force_output" for __RTL
      	functions.
      	(cgraph_node::analyze): Bail out early for __RTL functions.
      	(analyze_functions): Update assertion to support __RTL functions.
      	(cgraph_node::expand): Bail out early for __RTL functions.
      	* final.c (rest_of_clean_state): Don't call delete_tree_ssa for
      	__RTL functions.
      	* function.h (struct function): Update comment for field
      	"pass_startwith".
      	* gimple-expr.c: Include "tree-pass.h".
      	(gimple_has_body_p): Return false for __RTL functions.
      	* Makefile.in (OBJS): Add run-rtl-passes.o.
      	* pass_manager.h (gcc::pass_manager::get_rest_of_compilation): New
      	accessor.
      	(gcc::pass_manager::get_clean_slate): New accessor.
      	* passes.c: Include "insn-addr.h".
      	(should_skip_pass_p): Add logging.  Update logic for running
      	"expand" to be compatible with both __GIMPLE and __RTL.  Guard
      	property-provider override so it is only done for gimple passes.
      	Don't skip dfinit.
      	(skip_pass): New function.
      	(execute_one_pass): Call skip_pass when skipping passes.
      	* read-md.c (md_reader::read_char): Support filtering
      	the input to a subset of line numbers.
      	(md_reader::md_reader): Initialize fields
      	m_first_line and m_last_line.
      	(md_reader::read_file_fragment): New function.
      	* read-md.h (md_reader::read_file_fragment): New decl.
      	(md_reader::m_first_line): New field.
      	(md_reader::m_last_line): New field.
      	* read-rtl-function.c (function_reader::create_function): Only
      	create cfun if it doesn't already exist.  Set PROP_rtl on cfun's
      	curr_properties.  Set DECL_INITIAL to a dummy block.
      	(read_rtl_function_body_from_file_range): New function.
      	* read-rtl-function.h (read_rtl_function_body_from_file_range):
      	New decl.
      	* run-rtl-passes.c: New file.
      	* run-rtl-passes.h: New file.
      
      gcc/testsuite/ChangeLog:
      	* gcc.dg/rtl/aarch64/asr_div1.c: New test case.
      	* gcc.dg/rtl/aarch64/pr71779.c: New test case.
      	* gcc.dg/rtl/rtl.exp: New file.
      	* gcc.dg/rtl/test.c: New file.
      	* gcc.dg/rtl/truncated-rtl-file.c: New test case.
      	* gcc.dg/rtl/unknown-rtx-code.c: New test case.
      	* gcc.dg/rtl/x86_64/dfinit.c: New test case.
      	* gcc.dg/rtl/x86_64/different-structs.c: New test case.
      	* gcc.dg/rtl/x86_64/final.c: New test case.
      	* gcc.dg/rtl/x86_64/into-cfglayout.c: New test case.
      	* gcc.dg/rtl/x86_64/ira.c: New test case.
      	* gcc.dg/rtl/x86_64/pro_and_epilogue.c: New test case.
      	* gcc.dg/rtl/x86_64/test-multiple-fns.c: New test case.
      	* gcc.dg/rtl/x86_64/test-return-const.c.after-expand.c: New test case.
      	* gcc.dg/rtl/x86_64/test-return-const.c.before-fwprop.c: New test case.
      	* gcc.dg/rtl/x86_64/test-rtl.c: New test case.
      	* gcc.dg/rtl/x86_64/test_1.h: New file.
      	* gcc.dg/rtl/x86_64/times-two.c.after-expand.c: New test case.
      	* gcc.dg/rtl/x86_64/times-two.c.before-df.c: New test case.
      	* gcc.dg/rtl/x86_64/times-two.h: New file.
      	* gcc.dg/rtl/x86_64/vregs.c: New test case.
      
      From-SVN: r244878
      David Malcolm committed
    • microblaze.h (ASM_FORMAT_PRIVATE_NAME): Increase buffer size. · 82b23905
      	* config/microblaze/microblaze.h (ASM_FORMAT_PRIVATE_NAME): Increase
      	buffer size.
      
      From-SVN: r244877
      Jeff Law committed
    • Fix typo. · 3fbbfbc9
      From-SVN: r244874
      David Edelsohn committed
    • re PR tree-optimization/79159 (spurious array-bounds warning) · cf8d19de
      	PR tree-optimization/79159
      	* tree-ssa-loop-niter.c (get_cst_init_from_scev): New function.
      	(record_nonwrapping_iv): Imporve boundary using above function if no
      	value range information.
      
      	gcc/testsuite
      	PR tree-optimization/79159
      	* g++.dg/tree-ssa/pr79159.C: New test.
      
      From-SVN: r244868
      Bin Cheng committed
    • Brig front-end · 5fd1486c
      2017-01-24  Pekka Jääskeläinen <pekka@parmance.com>
      	    Martin Jambor  <mjambor@suse.cz>
      
      	* Makefile.def (target_modules): Added libhsail-rt.
      	(languages): Added language brig.
      	* Makefile.in: Regenerated.
      	* configure.ac (TOPLEVEL_CONFIGURE_ARGUMENTS): Added
      	tgarget-libhsail-rt.  Make brig unsupported on untested architectures.
      	* configure: Regenerated.
      
      gcc/
      	* brig-builtins.def: New file.
      	* builtins.def (DEF_HSAIL_BUILTIN): New macro.
      	(DEF_HSAIL_ATOMIC_BUILTIN): Likewise.
      	(DEF_HSAIL_SAT_BUILTIN): Likewise.
      	(DEF_HSAIL_INTR_BUILTIN): Likewise.
      	(DEF_HSAIL_CVT_ZEROI_SAT_BUILTIN): Likewise.
      	* builtin-types.def (BT_INT8): New.
      	(BT_INT16): Likewise.
      	(BT_UINT8): Likewise.
      	(BT_UINT16): Likewise.
      	(BT_FN_ULONG): Likewise.
      	(BT_FN_UINT_INT): Likewise.
      	(BT_FN_UINT_ULONG): Likewise.
      	(BT_FN_UINT_LONG): Likewise.
      	(BT_FN_UINT_PTR): Likewise.
      	(BT_FN_ULONG_PTR): Likewise.
      	(BT_FN_INT8_FLOAT): Likewise.
      	(BT_FN_INT16_FLOAT): Likewise.
      	(BT_FN_UINT32_FLOAT): Likewise.
      	(BT_FN_UINT16_FLOAT): Likewise.
      	(BT_FN_UINT8_FLOAT): Likewise.
      	(BT_FN_UINT64_FLOAT): Likewise.
      	(BT_FN_UINT16_UINT32): Likewise.
      	(BT_FN_UINT32_UINT16): Likewise.
      	(BT_FN_UINT16_UINT16_UINT16): Likewise.
      	(BT_FN_INT_PTR_INT): Likewise.
      	(BT_FN_UINT_PTR_UINT): Likewise.
      	(BT_FN_LONG_PTR_LONG): Likewise.
      	(BT_FN_ULONG_PTR_ULONG): Likewise.
      	(BT_FN_VOID_UINT64_UINT64): Likewise.
      	(BT_FN_UINT8_UINT8_UINT8): Likewise.
      	(BT_FN_INT8_INT8_INT8): Likewise.
      	(BT_FN_INT16_INT16_INT16): Likewise.
      	(BT_FN_INT_INT_INT): Likewise.
      	(BT_FN_UINT_FLOAT_UINT): Likewise.
      	(BT_FN_FLOAT_UINT_UINT): Likewise.
      	(BT_FN_ULONG_UINT_UINT): Likewise.
      	(BT_FN_ULONG_UINT_PTR): Likewise.
      	(BT_FN_ULONG_ULONG_ULONG): Likewise.
      	(BT_FN_UINT_UINT_UINT): Likewise.
      	(BT_FN_VOID_UINT_PTR): Likewise.
      	(BT_FN_UINT_UINT_PTR: Likewise.
      	(BT_FN_UINT32_UINT64_PTR): Likewise.
      	(BT_FN_INT_INT_UINT_UINT): Likewise.
      	(BT_FN_UINT_UINT_UINT_UINT): Likewise.
      	(BT_FN_UINT_UINT_UINT_PTR): Likewise.
      	(BT_FN_UINT_ULONG_ULONG_UINT): Likewise.
      	(BT_FN_ULONG_ULONG_ULONG_ULONG): Likewise.
      	(BT_FN_LONG_LONG_UINT_UINT): Likewise.
      	(BT_FN_ULONG_ULONG_UINT_UINT): Likewise.
      	(BT_FN_VOID_UINT32_UINT64_PTR): Likewise.
      	(BT_FN_VOID_UINT32_UINT32_PTR): Likewise.
      	(BT_FN_UINT_UINT_UINT_UINT_UINT): Likewise.
      	(BT_FN_UINT_FLOAT_FLOAT_FLOAT_FLOAT): Likewise.
      	(BT_FN_ULONG_ULONG_ULONG_UINT_UINT): Likewise.
      	* doc/frontends.texi: List BRIG FE.
      	* doc/install.texi (Testing): Add BRIG tesring requirements.
      	* doc/invoke.texi (Overall Options): Mention BRIG.
      	* doc/standards.texi (Standards): Doucment BRIG HSA version.
      
      gcc/brig/
      
      	* Make-lang.in: New file.
      	* brig-builtins.h: Likewise.
      	* brig-c.h: Likewise.
      	* brig-lang.c: Likewise.
      	* brigspec.c: Likewise.
      	* config-lang.in: Likewise.
      	* lang-specs.h: Likewise.
      	* lang.opt: Likewise.
      	* brigfrontend/brig-arg-block-handler.cc: Likewise.
      	* brigfrontend/brig-atomic-inst-handler.cc: Likewise.
      	* brigfrontend/brig-basic-inst-handler.cc: Likewise.
      	* brigfrontend/brig-branch-inst-handler.cc: Likewise.
      	* brigfrontend/brig-cmp-inst-handler.cc: Likewise.
      	* brigfrontend/brig-code-entry-handler.cc: Likewise.
      	* brigfrontend/brig-code-entry-handler.h: Likewise.
      	* brigfrontend/brig-comment-handler.cc: Likewise.
      	* brigfrontend/brig-control-handler.cc: Likewise.
      	* brigfrontend/brig-copy-move-inst-handler.cc: Likewise.
      	* brigfrontend/brig-cvt-inst-handler.cc: Likewise.
      	* brigfrontend/brig-fbarrier-handler.cc: Likewise.
      	* brigfrontend/brig-function-handler.cc: Likewise.
      	* brigfrontend/brig-function.cc: Likewise.
      	* brigfrontend/brig-function.h: Likewise.
      	* brigfrontend/brig-inst-mod-handler.cc: Likewise.
      	* brigfrontend/brig-label-handler.cc: Likewise.
      	* brigfrontend/brig-lane-inst-handler.cc: Likewise.
      	* brigfrontend/brig-machine.c: Likewise.
      	* brigfrontend/brig-machine.h: Likewise.
      	* brigfrontend/brig-mem-inst-handler.cc: Likewise.
      	* brigfrontend/brig-module-handler.cc: Likewise.
      	* brigfrontend/brig-queue-inst-handler.cc: Likewise.
      	* brigfrontend/brig-seg-inst-handler.cc: Likewise.
      	* brigfrontend/brig-signal-inst-handler.cc: Likewise.
      	* brigfrontend/brig-to-generic.cc: Likewise.
      	* brigfrontend/brig-to-generic.h: Likewise.
      	* brigfrontend/brig-util.cc: Likewise.
      	* brigfrontend/brig-util.h: Likewise.
      	* brigfrontend/brig-variable-handler.cc: Likewise.
      	* brigfrontend/phsa.h: Likewise.
      
      
      gcc/testsuite/
      
      	* lib/brig-dg.exp: New file.
      	* lib/brig.exp: Likewise.
      	* brig.dg/README: Likewise.
      	* brig.dg/dg.exp: Likewise.
      	* brig.dg/test/gimple/alloca.hsail: Likewise.
      	* brig.dg/test/gimple/atomics.hsail: Likewise.
      	* brig.dg/test/gimple/branches.hsail: Likewise.
      	* brig.dg/test/gimple/fbarrier.hsail: Likewise.
      	* brig.dg/test/gimple/function_calls.hsail: Likewise.
      	* brig.dg/test/gimple/kernarg.hsail: Likewise.
      	* brig.dg/test/gimple/mem.hsail: Likewise.
      	* brig.dg/test/gimple/mulhi.hsail: Likewise.
      	* brig.dg/test/gimple/packed.hsail: Likewise.
      	* brig.dg/test/gimple/smoke_test.hsail: Likewise.
      	* brig.dg/test/gimple/variables.hsail: Likewise.
      	* brig.dg/test/gimple/vector.hsail: Likewise.
      
      include/
      
      	* hsa.h: Moved here from libgomp/plugin/hsa.h.
      
      libgomp/
      
      	* plugin/hsa.h: Moved to top level include.
      	* plugin/plugin-hsa.c: Chanfgd include of hsa.h accordingly.
      
      libhsail-rt/
      
      	* Makefile.am: New file.
      	* target-config.h.in: Likewise.
      	* configure.ac: Likewise.
      	* configure: Likewise.
      	* config.h.in: Likewise.
      	* aclocal.m4: Likewise.
      	* README: Likewise.
      	* Makefile.in: Likewise.
      	* include/internal/fibers.h: Likewise.
      	* include/internal/phsa-queue-interface.h: Likewise.
      	* include/internal/phsa-rt.h: Likewise.
      	* include/internal/workitems.h: Likewise.
      	* rt/arithmetic.c: Likewise.
      	* rt/atomics.c: Likewise.
      	* rt/bitstring.c: Likewise.
      	* rt/fbarrier.c: Likewise.
      	* rt/fibers.c: Likewise.
      	* rt/fp16.c: Likewise.
      	* rt/misc.c: Likewise.
      	* rt/multimedia.c: Likewise.
      	* rt/queue.c: Likewise.
      	* rt/sat_arithmetic.c: Likewise.
      	* rt/segment.c: Likewise.
      	* rt/workitems.c: Likewise.
      
      
      Co-Authored-By: Martin Jambor <mjambor@suse.cz>
      
      From-SVN: r244867
      Pekka Jääskeläinen committed
    • re PR translation/79208 (Typo in gcc/ipa-devirt.c:1631) · e1e41b6f
      2017-01-24  Richard Biener  <rguenther@suse.de>
      
      	PR translation/79208
      	* ipa-devirt.c (odr_types_equivalent_p): Fix typo in diagnostic.
      
      From-SVN: r244866
      Richard Biener committed
    • PR libstdc++/79206 check string_view sizes in operator== · 8cb7179d
      	PR libstdc++/79206
      	* include/experimental/string_view (operator==): Check sizes first.
      	* include/std/string_view (operator==): Likewise.
      
      From-SVN: r244865
      Jonathan Wakely committed
    • [PR 79198] Call ipa-prop func summary destructor · cf157d80
      2017-01-24  Martin Jambor  <mjambor@suse.cz>
      
      	PR bootstrap/79198
      	* ipa-prop.c (ipa_free_all_node_params): Call summary destructor.
      	* ipa-prop.c (ipa_node_params_t::insert): Initialize fields known_csts
      	and known_contexts.
      
      From-SVN: r244860
      Martin Jambor committed
    • re PR middle-end/79123 (incorrect -Walloca-larger-than: alloca may be too large… · 4cd7b1a9
      re PR middle-end/79123 (incorrect -Walloca-larger-than: alloca may be too large due to conversion from long int to long unsigned int)
      
      	PR middle-end/79123
      	* gimple-ssa-warn-alloca.c (alloca_call_type): Make sure
      	casts from signed to unsigned really don't have a range.
      
      From-SVN: r244859
      Aldy Hernandez committed
    • Fix build failure with MPFR 2.4.x · cf8e20bf
      	* gimple-ssa-sprintf.c (format_floating): Change MPFR_RNDx to
      	GMP_RNDx for compatiblity.
      
      From-SVN: r244858
      Markus Trippelsdorf committed
    • Fix false positive for -Walloc-size-larger-than (PR bootstrap/79132). · ad804024
      2017-01-24  Martin Liska  <mliska@suse.cz>
      
      	PR bootstrap/79132
      	* tree-ssa-reassoc.c (rewrite_expr_tree_parallel): Insert assert
      	that would prevent us to call alloca with -1 as argument.
      
      From-SVN: r244857
      Martin Liska committed
    • asan_test.C: Enable on all *-*-linux* targets that support asan... · c3b3e526
      	* g++.dg/asan/asan_test.C: Enable on all *-*-linux* targets that
      	support asan, only on i?86/x86_64 require sse2_runtime.
      
      From-SVN: r244856
      Jakub Jelinek committed
    • dwarf2out.c (output_compilation_unit_header, [...]): Avoid -Wformat-security warning. · 5d286a68
      	* dwarf2out.c (output_compilation_unit_header, output_file_names):
      	Avoid -Wformat-security warning.
      
      From-SVN: r244855
      Jakub Jelinek committed
    • aarch64.c (thunderx2t99_addrcost_table): Improve cost table. · 5f407e57
      2017-01-23  Andrew Pinski  <apinski@cavium.com>
      
              * config/aarch64/aarch64.c (thunderx2t99_addrcost_table): Improve
              cost table.
      
      From-SVN: r244851
      Andrew Pinski committed
    • re PR rtl-optimization/66669 (FAIL: gcc.dg/loop-8.c) · 75f92127
      gcc/testsuite/ChangeLog:
      
      2017-01-23  Kelvin Nilsen  <kelvin@gcc.gnu.org>
      
      	PR target/66669
      	* gcc.dg/loop-8.c: Modify dg-skip-if directive to exclude this
      	test on powerpc targets.
      
      From-SVN: r244850
      Kelvin Nilsen committed
    • Amend recent entry. · f7864c9f
      From-SVN: r244849
      Martin Sebor committed
    • builtin-sprintf.c: Add test cases. · 1a998fa0
      gcc/testsuite/ChangeLog:
      	* gcc.dg/tree-ssa/builtin-sprintf.c: Add test cases.
      
      From-SVN: r244848
      Martin Sebor committed
    • PR middle-end/78703 - -fprintf-return-value floating point handling incorrect... · 02f1ef40
      PR middle-end/78703 - -fprintf-return-value floating point handling incorrect in locales with a mulltibyte decimal point
      	* gimple-ssa-sprintf.c (warn_level): New global.
      	(format_integer): Use it here and throughout the rest of the file.
      	Use the same switch to compute sign as base.
      	(maybe_warn): New function.
      	(format_directive): Factor out warnings into maybe_warn.
      	Add debugging output.  Use warn_level.
      	(add_bytes): Use warn_level.
      	(pass_sprintf_length::compute_format_length): Add debugging output.
      	(try_substitute_return_value): Same.
      	(pass_sprintf_length::handle_gimple_call): Set and use warn_level.
      
      From-SVN: r244847
      Martin Sebor committed
    • PR middle-end/78703 - -fprintf-return-value floating point handling incorrect... · a151e93b
      PR middle-end/78703 - -fprintf-return-value floating point handling incorrect in locales with a mulltibyte decimal point
      	* gimple-ssa-sprintf.c (struct format_result): Remove constant member.
      	(struct fmtresult, format_integer, format_floating): Adjust.
      	(get_string_length, format_string,format_directive): Same.
      	(pass_sprintf_length::compute_format_length): Same.
      	(try_substitute_return_value): Simplify slightly.
      
      From-SVN: r244846
      Martin Sebor committed
    • PR middle-end/78703 - -fprintf-return-value floating point handling incorrect... · 954b452a
      PR middle-end/78703 - -fprintf-return-value floating point handling incorrect in locales with a mulltibyte decimal point
      	* gimple-ssa-sprintf.c (pass_sprintf_length::gate): Adjust formatting.
      	(fmtresult::operator+=): Outlined.
      	(struct fmtresult): Add ctors.
      	(struct conversion_spec): Rename...
      	(struct directive): ...to this.  Add and remove data members.
      	(directive::set_width, directive::set_precision): New functions.
      	(format_percent): Use fmtresult ctor.
      	(get_width_and_precision): Remove.
      	(format_integer): Make naming changes.  Avoid computing width and
      	precision.
      	(format_floating): Same.  Adjust indentation.
      	(format_character, format_none): New functions.
      	(format_string): Moved character handling to format_character.
      	(format_directive): Remove arguments, change return type.
      	(parse_directive): New function.
      	(pass_sprintf_length::compute_format_length): Move directive
      	parsing to parse_directive.
      
      From-SVN: r244845
      Martin Sebor committed
    • re PR sanitizer/79168 (libtsan fails to link when cross compiling GCC tip for Aarch64 target) · 86b2a558
      	PR sanitizer/79168
      	* merge.sh (change_comment_headers): Don't remove 2nd and 3rd line
      	if the 3rd line doesn't contain 'The LLVM Compiler Infrastructure'
      	text.
      	* sanitizer_common/sanitizer_linux_mips64.S: Regenerated.
      	* sanitizer_common/sanitizer_linux_x86_64.S: Likewise.
      	* tsan/tsan_ppc_regs.h: Likewise.
      	* tsan/tsan_rtl_aarch64.S: Likewise.
      	* tsan/tsan_rtl_mips64.S: Likewise.
      	* tsan/tsan_rtl_ppc64.S: Likewise.
      
      From-SVN: r244844
      Jakub Jelinek committed
    • Daily bump. · 158c139f
      From-SVN: r244843
      GCC Administrator committed
  3. 23 Jan, 2017 8 commits
    • Restore <functional> header to test · 11948d83
      	* testsuite/experimental/array/make_array.cc: Restore <functional>
      	inclusion.
      
      From-SVN: r244840
      Jonathan Wakely committed
    • tree.h (assign_assembler_name_if_neeeded): Rename to ... · 9579db35
      	* tree.h (assign_assembler_name_if_neeeded): Rename to ...
      	(assign_assembler_name_if_needed): ... this.
      	* tree.c (assign_assembler_name_if_neeeded): Rename to ...
      	(assign_assembler_name_if_needed): ... this.
      	(free_lang_data_in_cgraph): Adjust callers.
      	* cgraphunit.c (cgraph_node::analyze): Likewise.
      	* omp-expand.c (expand_omp_taskreg, expand_omp_target):
      	Likewise.
      
      From-SVN: r244839
      Jakub Jelinek committed
    • re PR tree-optimization/79088 (wrong code at -O2 on x86_64-linux-gnu) · 108fdd6d
      2017-01-23  Richard Biener  <rguenther@suse.de>
      
      	PR tree-optimization/79088
      	PR tree-optimization/79188
      	* tree-ssa-threadupdate.c (mark_threaded_blocks): Move code
      	resetting loop bounds after last path deletion.  Reset loop
      	bounds of the target loop, make code match the comments.
      	* tree-ssa-threadbackwards.c (pass_early_thread_jumps::execute):
      	Make sure loops need no fixups.
      
      	* gcc.dg/torture/pr79088.c: New testcase.
      	* gcc.dg/torture/pr79188.c: Likewise.
      
      From-SVN: r244837
      Richard Biener committed
    • * da.po: Update. · 01f26e0e
      From-SVN: r244836
      Joseph Myers committed
    • libgo: update to go1.8rc2 · c25edd44
          
          Fix a bug in the generation of the hash value in reflect.FuncOf.
          
          The merge script missed a bunch of testdata files over the years.
          Copy them over.
          
          Reviewed-on: https://go-review.googlesource.com/35570
      
      From-SVN: r244835
      Ian Lance Taylor committed
    • scalar-insert-exp-3.c: New test. · 28826a66
      gcc/testsuite/ChangeLog:
      
      2017-01-23  Kelvin Nilsen  <kelvin@gcc.gnu.org>
      
      	* gcc.target/powerpc/bfp/scalar-insert-exp-3.c: New test.
      	* gcc.target/powerpc/bfp/scalar-insert-exp-4.c: New test.
      	* gcc.target/powerpc/bfp/scalar-insert-exp-5.c: New test.
      	* gcc.target/powerpc/bfp/scalar-test-data-class-0.c: Adjust return
      	type of test function to reflect change in built-in function's
      	return type.
      	* gcc.target/powerpc/bfp/scalar-test-data-class-1.c: Likewise.
      	* gcc.target/powerpc/bfp/scalar-test-data-class-2.c: Likewise.
      	* gcc.target/powerpc/bfp/scalar-test-data-class-3.c: Likewise.
      	* gcc.target/powerpc/bfp/scalar-test-data-class-4.c: Adjust return
      	type and second argument type to reflect change in built-in
      	function's type signature.
      	* gcc.target/powerpc/bfp/scalar-test-data-class-5.c: Likewise.
      	* gcc.target/powerpc/bfp/scalar-test-data-class-6.c: Adjust return
      	type of test function to reflect change in built-in function's
      	return type.
      	* gcc.target/powerpc/bfp/scalar-test-data-class-7.c: Likewise.
      	* gcc.target/powerpc/bfp/scalar-test-neg-0.c: Likewise.
      	* gcc.target/powerpc/bfp/scalar-test-neg-1.c: Likewise.
      	* gcc.target/powerpc/bfp/scalar-test-neg-2.c: Likewise.
      	* gcc.target/powerpc/bfp/scalar-test-neg-3.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-extract-exp-0.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-extract-exp-1.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-extract-exp-2.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-extract-exp-3.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-extract-sig-0.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-extract-sig-1.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-extract-sig-2.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-extract-sig-3.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-insert-exp-4.c: New test.
      	* gcc.target/powerpc/bfp/vec-insert-exp-5.c: New test.
      	* gcc.target/powerpc/bfp/vec-insert-exp-6.c: New test.
      	* gcc.target/powerpc/bfp/vec-insert-exp-7.c: New test.
      	* gcc.target/powerpc/bfp/vec-test-data-class-0.c: Adjust return
      	type of test function to reflect change in built-in function's
      	return type.
      	* gcc.target/powerpc/bfp/vec-test-data-class-1.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-test-data-class-2.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-test-data-class-3.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-test-data-class-4.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-test-data-class-5.c: Likewise.
      	* gcc.target/powerpc/bfp/vec-test-data-class-6.c: Adjust types of
      	test function's result and second argument to reflect change in
      	built-in function's type signature.
      	* gcc.target/powerpc/bfp/vec-test-data-class-7.c: Likewise.
      
      gcc/ChangeLog:
      
      2017-01-23  Kelvin Nilsen  <kelvin@gcc.gnu.org>
      
      	* config/rs6000/rs6000-builtin.def (VSIEDPF): Add scalar insert
      	exponent support with double type for first argument.
      	* config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Changed
      	type returned by __builtin_vec_extract_sig,
      	__builtin_vec_extract_sig_sp, and __builtin_vec_extract_sig_dp
      	functions from "vector int" to "vector unsigned int" or from
      	"vector long long int" to "vector unsigned long long int".
      	Changed type returned by __builtin_vec_extract_exp,
      	__builtin_vec_extract_exp_sp, and __builtin_vec_extract_exp_dp
      	functions from "vector int" to "vector unsigned int" or from
      	"vector long long int" to "vector unsigned long long int".
      	Changed return type of __builtin_vec_test_data_class,
      	__builtin_vec_test_data_class_sp, and
      	__builtin_vec_test_data_class_dp from "vector int" to
      	"vector bool int" or from "vector long long int" to "vector bool
      	long long int" and changed second argument type from "unsigned
      	int" to "int".  Added new overloaded function forms "vector float
      	__builtin_vec_insert_exp (vector float, vector unsigned int)" and
      	"vector float __builtin_vec_insert_exp_sp (vector float, vector
      	unsigned int)" and "vector double __builtin_vec_insert_exp (vector
      	double, vector unsigned long long int)" and "vector double
      	__builtin_vec_insert_exp_dp (vector double, vector unsigned long
      	long int)".  Changed return type of
      	__builtin_scalar_test_data_class and
      	__builtin_scalar_test_data_class_sp and
      	__builtin_scalar_test_data_class_dp from "unsigned int" to "bool
      	int" and changed second argument from "unsigned int" to "int".
      	Changed type returned by __builtin_scalar_test_neg,
      	__builtin_scalar_test_neg_sp, and __builtin_scalar_test_neg_dp
      	from "int" to "bool int".  Added new overloaded function form
      	"double __builtin_scalar_insert_exp (double, unsigned long long int)".
      	* config/rs6000/vsx.md (xsiexpdpf): New insn for scalar insert
      	exponent double-precision with floating point first argument.
      	* doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
      	documentation of scalar_test_data_class, scalar_test_neg,
      	scalar_extract_sig, scalar_extract_exp, scalar_insert_exp,
      	vector_extract_exp, vec_extract_sig, vec_insert_exp, and
      	vec_test_data_class built-in functions to reflect refinements in
      	their type signatures.
      
      From-SVN: r244834
      Kelvin Nilsen committed
    • PR c++/71710 - template using directive of field · fc7612fd
      	PR c++/71710 - template using directive of field
      	* pt.c (tsubst_copy_and_build [COMPONENT_REF]): Move FIELD_DECL
      	check earlier.
      
      	PR C++/71710
      	* g++.dg/template/pr71710.C: New.
      
      From-SVN: r244833
      Nathan Sidwell committed
    • PR c++/71406 - ICE with scope-ref'd template id exprs · e6b8075c
      	PR c++/71406 - ICE with scope-ref'd template id exprs
      	PR c++/77508
      	* typeck.c (finish_class_member_access_expr): Break up SCOPE_REF
      	before breaking up TEMPLATE_ID_EXPR.
      
      	PR c++/71406
      	PR c++/77508
      	* g++.dg/template/pr71406.C: New.
      
      From-SVN: r244832
      Nathan Sidwell committed