Ensure that the packages vendored into the standard library do not
have the same pkgpath as the actual packages. If we don't, attempts
to build and test the actual packages will get confused. The specific
error I was seeing was import loops, causing some of the packages to
fail to get initialized, causing an obscure run time crash.
Reviewed-on: https://go-review.googlesource.com/43610
From-SVN: r248168
* c-common.c: Use NULL_TREE instead of 0 where appropriate.
* c-warn.c: Likewise.
* c-decl.c: Use NULL_TREE instead of 0 where appropriate.
* c-typeck.c: Likewise.
From-SVN: r248161
* cp-tree.h (default_hash_traits <lang_identifier *>): New
specialization.
* name-lookup.c (lookup_extern_c_fun_in_all_ns): Delete.
(extern_c_fns): New hash table.
(check_extern_c_conflict): New, broken out of ...
(pushdecl_maybe_friend_1): ... here. Call it.
(c_linkage_bindings): Just look in hash table.
From-SVN: r248159
* doc/md.texi (Canonicalization of Instructions): Describe the
canonical form of instructions that inherently set a condition
code register.
From-SVN: r248156
gcc/
PR middle-end/80775
* tree-cfg.c: Move deletion of unreachable case statements to after
the merging of consecutive case labels.
gcc/testsuite/
PR middle-end/80775
* gcc.dg/pr80775.c: New test.
From-SVN: r248155
* class.c (handle_using_decl): Use OVL_FIRST, ovl_iterator.
(maybe_warn_about_overly_private_class): Use ovl_iterator.
(method_name_cmp, resort_method_name_cmp): Use OVL_NAME.
(resort_type_method_vec, finish_struct_methods): Use OVL_FIRST.
(get_base_fndecls): Use ovl_iterator.
(warn_hidden): Use OVL_NAME, ovl_iterator.
(add_implicitly_declared_members): Use ovl_iterator.
* constraint.cc (normalize_template_id_expression): Use OVL_FIRST,
flatten nested if.
(finish_shorthand_constraint): Simplify, use ovl_make.
* pt.c (make_constrained_auto): Simplify. Use ovl_make.
* search.c (shared_member_p): Use ovl_iterator.
(lookup_field_fuzzy_info::fuzzy_lookup_fn): Use OVL_NAME.
(lookup_conversion_operator): Use OVL_FIRST.
(lookup_fnfiels_idx_nolazy): Use OVL_FIRST, OVL_NAME.
(look_for_overrides_here): Use ovl_iterator.
(lookup_conversions_r): Use OVL_FIRST, OVL_NAME, ovl_iterator.
* typeck.c (build_x_unary_op): Use ovl_make.
From-SVN: r248144
PR sanitizer/80659
* c-decl.c (build_compound_literal): Set DECL_ARTIFICIAL and
DECL_IGNORED_P even for non-static compound literals.
* gcc.dg/asan/pr80659.c: New test.
From-SVN: r248143
2017-05-17 Thomas Preud'homme <thomas.preudhomme@arm.com>
gcc/
* config/arm/arm.c (cmse_nonsecure_call_clear_caller_saved): Refer
readers to __gnu_cmse_nonsecure_call libcall for saving, clearing and
restoring of callee-saved registers.
From-SVN: r248142
The test fails for avr because malloc has been declared to take
an unsigned long, whereas size_t for avr is only unsigned int.
Fixed by typedef'ing __SIZE_TYPE__ to size_t and using it in the
malloc function declaration.
gcc/testsuite/
2017-05-17 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
* gcc.dg/tree-ssa/pr78886.c: Use __SIZE_TYPE__ instead of
unsigned long.
From-SVN: r248138
[gcc]
2017-05-16 James Greenhalgh <james.greenhalgh@arm.com>
Bill Schmidt <wschmidt@linux.vnet.ibm.com>
PR tree-optimization/80457
* tree-vect-stmts.c (vect_model_simple_cost): Model the cost
of all arguments to a statement as scalar_to_vec operations.
(vectorizable_call): Adjust call to vect_model_simple_cost for
new parameter.
(vectorizable_conversion): Likewise.
(vectorizable_assignment): Likewise.
(vectorizable_shift): Likewise.
(vectorizable_operation): Likewise.
(vectorizable_comparison): Likewise.
(vect_is_simple_cond): Record the def types for operands.
(vectorizable_condition): Likewise, call vect_model_simple_cost.
* tree-vectorizer.h (vect_model_simple_cost): Add new parameter
for statement argument count.
[gcc/testsuite]
2017-05-16 James Greenhalgh <james.greenhalgh@arm.com>
Bill Schmidt <wschmidt@linux.vnet.ibm.com>
PR tree-optimization/80457
* gcc.target/powerpc/pr78604.c: Verify that vectorized COND_EXPRs
call vect_model_simple_cost.
Co-Authored-By: Bill Schmidt <wschmidt@linux.vnet.ibm.com>
From-SVN: r248130
2017-05-16 Paul Thomas <pault@gcc.gnu.org>
PR fortran/80554
* decl.c (build_sym): In a submodule allow overriding of host
associated symbols from the ancestor module with a new
declaration.
2017-05-16 Paul Thomas <pault@gcc.gnu.org>
PR fortran/80554
* gfortran.dg/submodule_29.f08: New test.
From-SVN: r248129
gcc/cp/ChangeLog:
* call.c (enforce_access): Add access_failure_info * param and use
it to record access failures.
* cp-tree.h (class access_failure_info): New class.
(enforce_access): Add access_failure_info * param, defaulting to
NULL.
(lookup_member): Likewise.
(locate_field_accessor): New function decl.
(perform_or_defer_access_check): Add access_failure_info * param,
defaulting to NULL.
* search.c (lookup_member): Add access_failure_info * param and
pass it on to call to perform_or_defer_access_check.
(matches_code_and_type_p): New function.
(field_access_p): New function.
(direct_accessor_p): New function.
(reference_accessor_p): New function.
(field_accessor_p): New function.
(struct locate_field_data): New struct.
(dfs_locate_field_accessor_pre): New function.
(locate_field_accessor): New function.
* semantics.c (perform_or_defer_access_check): Add
access_failure_info * param, and pass it on to call to
enforce_access.
* typeck.c (access_failure_info::record_access_failure): New method.
(access_failure_info::maybe_suggest_accessor): New method.
(finish_class_member_access_expr): Pass an access_failure_info
instance to the lookup_member call, and call its
maybe_suggest_accessor method afterwards.
gcc/testsuite/ChangeLog:
* g++.dg/other/accessor-fixits-1.C: New test case.
* g++.dg/other/accessor-fixits-2.C: New test case.
* g++.dg/other/accessor-fixits-3.C: New test case.
* g++.dg/other/accessor-fixits-4.C: New test case.
From-SVN: r248128
gcc/ChangeLog:
2017-05-16 Carl Love <cel@us.ibm.com>
* config/rs6000/rs6000-c: Add support for built-in functions
vector unsigned long long vec_bperm (vector unsigned long long,
vector unsigned char)
vector signed long long vec_mule (vector signed int,
vector signed int)
vector unsigned long long vec_mule (vector unsigned int,
vector unsigned int)
vector signed long long vec_mulo (vector signed int,
vector signed int)
vector unsigned long long vec_mulo (vector unsigned int,
vector unsigned int)
vector signed char vec_sldw (vector signed char,
vector signed char,
const int)
vector unsigned char vec_sldw (vector unsigned char,
vector unsigned char,
const int)
vector signed short vec_sldw (vector signed short,
vector signed short,
const int)
vector unsigned short vec_sldw (vector unsigned short,
vector unsigned short,
const int)
vector signed int vec_sldw (vector signed int,
vector signed int,
const int)
vector unsigned int vec_sldw (vector unsigned int,
vector unsigned int,
const int)
vector signed long long vec_sldw (vector signed long long,
vector signed long long,
const int)
vector unsigned long long vec_sldw (vector unsigned long long,
vector unsigned long long,
const int)
* config/rs6000/rs6000-c: Add support for built-in functions
* config/rs6000/rs6000-builtin.def: Add definition for SLDW.
* config/rs6000/altivec.h: Add defintion for vec_sldw.
* doc/extend.texi: Update the built-in documentation for the
new built-in functions.
gcc/testsuite/ChangeLog:
2017-05-16 Carl Love <cel@us.ibm.com>
* gcc.target/powerpc/builtins-3.c: New vec_mule, vec_mulo test cases.
* gcc.target/powerpc/builtins-3-p8.c: Add tests for the new Power 8
built-ins to the test suite file. Note, support for mradds exists
but no test case exists.
* gcc.target/powerpc/builtins-3-p9.c: Add tests for the new Power 9
built-ins to the test suite file.
From-SVN: r248125
* call.c (build_user_type_conversion_1): Use OVL_FIRST.
(print_error_for_call_faulure): Use OVL_NAME.
(build_op_call_1): Use ovl_iterator.
(add_candidates): Use OVL_FIRST & lkp_iterator.
(build_op_delete_call): Use MAYBE_BASELINK_FUNCTIONS &
lkp_iterator.
* class.c (deduce_noexcept_on_destructors): Use ovl_iterator.
(type_has_user_nondefault_constructor)
in_class_defaulted_default_constructor,
type_has_user_provided_constructor,
type_has_user_provided_or_explicit_constructor,
type_has_non_user_provided_default_constructor,
vbase_has_user_provided_move_assign,
type_has_move_constructor, type_has_move_assign,
type_has_user_declared_move_constructor,
type_has_user_declared_move_assign,
type_build_ctor_call, type_build_dtor_call,
type_requires_array_cookie, explain_non_literal_class): Likewise.
(finish_struct): Use lkp_iterator.
(resolve_address_of_overloaded_function): Use OVL_NAME,
lkp_iterator.
(note_name_declared_in_class): Use OVL_NAME.
* cxx-pretty-print.c (pp_cxx_unqualified_id): Use OVL_FIRST.
(pp_cxx_qualified_id, cxx_pretty_printer::id_expression)
cxx_pretty_printer::expression): Likewise.
* decl2.c (check_classfn): Use ovl_iterator.
* pt.c (retrieve_specialization): Use ovl_iterator.
* tree.c (cp_tree_equal): Use lkp_iterator.
(type_has_nontrivial_copy_init): Use ovl_iterator.
((--This line, and those below, will be ignored--
M cp/ChangeLog
M cp/call.c
M cp/class.c
M cp/pt.c
M cp/decl2.c
M cp/tree.c
M cp/cxx-pretty-print.c
From-SVN: r248120
* config/i386.i386.md (*movsi_internal): Split (?rm,*y) alternative
to (?r,*Yn) and (?m,*y) alternatives, and (?*y,rm) to (?*Ym,r)
and (?*y,m). Update insn attributes.
From-SVN: r248114
* testsuite/experimental/source_location/1.cc: Change expected result
for source_location::current() used in default member initializer.
From-SVN: r248111
2017-05-16 Richard Biener <rguenther@suse.de>
* dwarf2out.c (loc_list_from_tree_1): Do not create
DW_OP_GNU_variable_value for DECL_IGNORED_P decls.
From-SVN: r248094
2017-05-16 Richard Biener <rguenther@suse.de>
* dwarf2out.c (resolve_variable_value_in_expr): Lookup DIE
just generated.
(note_variable_value_in_expr): If we resolved the decl ref
do not push to the stack.
From-SVN: r248093