]> git.ipfire.org Git - thirdparty/gcc.git/log
thirdparty/gcc.git
8 years agobackport: re PR target/79932 (_mm512_packus_epi32 does not compile under -O0)
Jakub Jelinek [Tue, 30 May 2017 08:08:59 +0000 (10:08 +0200)] 
backport: re PR target/79932 (_mm512_packus_epi32 does not compile under -O0)

Backported from mainline
2017-03-09  Jakub Jelinek  <jakub@redhat.com>

PR target/79932
* config/i386/avx512bwintrin.h (_mm512_packs_epi32,
_mm512_maskz_packs_epi32, _mm512_mask_packs_epi32,
_mm512_packus_epi32, _mm512_maskz_packus_epi32,
_mm512_mask_packus_epi32): Move definitions outside of __OPTIMIZE__
guarded section.

* gcc.target/i386/pr79932-1.c: New test.

From-SVN: r248656

8 years agobackport: re PR rtl-optimization/79901 (ICE in prepare_cmp_insn, at optabs.c:3904)
Jakub Jelinek [Tue, 30 May 2017 08:08:24 +0000 (10:08 +0200)] 
backport: re PR rtl-optimization/79901 (ICE in prepare_cmp_insn, at optabs.c:3904)

Backported from mainline
2017-03-07  Jakub Jelinek  <jakub@redhat.com>

PR rtl-optimization/79901
* config/i386/sse.md (*avx512bw_<code><mode>3<mask_name>): Renamed to
...
(*avx512f_<code><mode>3<mask_name>): ... this.
(<code><mode>3 with maxmin code iterator): Use VI8_AVX2_AVX512F
iterator instead of VI8_AVX2_AVX512BW.

* gcc.target/i386/pr79901.c: New test.

From-SVN: r248655

8 years agobackport: re PR rtl-optimization/79901 (ICE in prepare_cmp_insn, at optabs.c:3904)
Jakub Jelinek [Tue, 30 May 2017 08:07:30 +0000 (10:07 +0200)] 
backport: re PR rtl-optimization/79901 (ICE in prepare_cmp_insn, at optabs.c:3904)

Backported from mainline
2017-03-07  Jakub Jelinek  <jakub@redhat.com>

PR rtl-optimization/79901
* expr.c (expand_expr_real_2): For vector MIN/MAX, if there is no
min/max expander, expand it using expand_vec_cond_expr.

From-SVN: r248654

8 years agobackport: re PR target/79807 (ICE in extract_insn, at recog.c:2311 (error: unrecogniz...
Jakub Jelinek [Tue, 30 May 2017 08:07:03 +0000 (10:07 +0200)] 
backport: re PR target/79807 (ICE in extract_insn, at recog.c:2311 (error: unrecognizable insn))

Backported from mainline
2017-03-03  Jakub Jelinek  <jakub@redhat.com>

PR target/79807
* config/i386/i386.c (ix86_expand_multi_arg_builtin): If target
is a memory operand, increase num_memory.
(ix86_expand_args_builtin): Likewise.

* gcc.target/i386/pr79807.c: New test.

From-SVN: r248653

8 years agobackport: re PR target/79729 (ICE in ix86_print_operand, at config/i386/i386.c:18231)
Jakub Jelinek [Tue, 30 May 2017 08:06:28 +0000 (10:06 +0200)] 
backport: re PR target/79729 (ICE in ix86_print_operand, at config/i386/i386.c:18231)

Backported from mainline
2017-02-28  Jakub Jelinek  <jakub@redhat.com>

PR target/79729
* config/i386/i386.c (ix86_print_operand) <case 'R'>: Replace
gcc_unreachable with output_operand_lossage.

* gcc.target/i386/pr79729.c: New test.

From-SVN: r248652

8 years agobackport: re PR middle-end/79396 (ICE (verify_flow_info failed) with -fnon-call-excep...
Jakub Jelinek [Tue, 30 May 2017 08:05:47 +0000 (10:05 +0200)] 
backport: re PR middle-end/79396 (ICE (verify_flow_info failed) with -fnon-call-exceptions -O2 -march=haswell)

Backported from mainline
2017-02-25  Jakub Jelinek  <jakub@redhat.com>

PR middle-end/79396
* tree-eh.c (operation_could_trap_p, stmt_could_throw_1_p): Handle
FMA_EXPR like tcc_binary or tcc_unary.

* g++.dg/opt/pr79396.C: New test.

From-SVN: r248651

8 years agobackport: re PR c++/79664 (ICE with #pragma omp parallel in constexpr function)
Jakub Jelinek [Tue, 30 May 2017 08:04:55 +0000 (10:04 +0200)] 
backport: re PR c++/79664 (ICE with #pragma omp parallel in constexpr function)

Backported from mainline
2017-02-22  Jakub Jelinek  <jakub@redhat.com>

PR c++/79664
* parser.c (cp_parser_omp_teams, cp_parser_omp_target): Use
SET_EXPR_LOCATION on OMP_TARGET/OMP_TEAMS tree.
* constexpr.c (potential_constant_expression_1): Handle
OMP_*, OACC_* and CILK_* trees.

* g++.dg/gomp/pr79664.C: New test.

From-SVN: r248650

8 years agobackport: re PR target/79570 (ICE in sel-sched-ir.c:4534 in pr69956.c)
Jakub Jelinek [Tue, 30 May 2017 08:03:03 +0000 (10:03 +0200)] 
backport: re PR target/79570 (ICE in sel-sched-ir.c:4534 in pr69956.c)

Backported from mainline
2017-02-21  Jakub Jelinek  <jakub@redhat.com>

PR target/79570
* sel-sched.c (moveup_expr_cached): Don't call sel_bb_head
on temporarily removed DEBUG_INSNs.

* gcc.dg/pr79570.c: New test.

From-SVN: r248649

8 years agobackport: re PR c++/79641 (ICE with const variable and attribute)
Jakub Jelinek [Tue, 30 May 2017 08:02:18 +0000 (10:02 +0200)] 
backport: re PR c++/79641 (ICE with const variable and attribute)

Backported from mainline
2017-02-21  Jakub Jelinek  <jakub@redhat.com>

PR c++/79641
* c-common.c (handle_mode_attribute): Use build_qualified_type to
preserve quals.

* c-c++-common/pr79641.c: New test.

From-SVN: r248648

8 years agobackport: re PR target/79494 (ICE in maybe_record_trace_start, at dwarf2cfi.c:2330)
Jakub Jelinek [Tue, 30 May 2017 08:01:31 +0000 (10:01 +0200)] 
backport: re PR target/79494 (ICE in maybe_record_trace_start, at dwarf2cfi.c:2330)

Backported from mainline
2017-02-21  Jakub Jelinek  <jakub@redhat.com>

PR target/79494
* config/i386/i386.c (ix86_expand_split_stack_prologue): Call
make_reg_eh_region_note_nothrow_nononlocal on call_insn.

* gcc.dg/pr79494.c: New test.

From-SVN: r248646

8 years agobackport: re PR target/79568 (ICE in extract_insn, at recog.c:2311 for pr70325.c...
Jakub Jelinek [Tue, 30 May 2017 08:00:48 +0000 (10:00 +0200)] 
backport: re PR target/79568 (ICE in extract_insn, at recog.c:2311 for pr70325.c (with -mavx512bw))

Backported from mainline
2017-02-20  Jakub Jelinek  <jakub@redhat.com>

PR target/79568
* config/i386/i386.c (ix86_expand_builtin): Handle
OPTION_MASK_ISA_AVX512VL and OPTION_MASK_ISA_64BIT in
ix86_builtins_isa[fcode].isa as a requirement of those
flags and any other flag in the bitmask.
(ix86_init_mmx_sse_builtins): Use 0 instead of
~OPTION_MASK_ISA_64BIT as mask.
* config/i386/i386-builtin.def (bdesc_special_args,
bdesc_args): Likewise.

* gcc.target/i386/pr79568-1.c: New test.
* gcc.target/i386/pr79568-2.c: New test.
* gcc.target/i386/pr79568-3.c: New test.

From-SVN: r248645

8 years agobackport: re PR target/79559 (ICE in ix86_print_operand, at config/i386/i386.c:18189)
Jakub Jelinek [Tue, 30 May 2017 07:59:29 +0000 (09:59 +0200)] 
backport: re PR target/79559 (ICE in ix86_print_operand, at config/i386/i386.c:18189)

Backported from mainline
2017-02-18  Jakub Jelinek  <jakub@redhat.com>

PR target/79559
* config/i386/i386.c (ix86_print_operand): Use output_operand_lossage
instead of gcc_assert for K, r and R code checks.  Formatting fixes.

* gcc.target/i386/pr79559.c: New test.

From-SVN: r248644

8 years agobackport: re PR c++/79512 (ICE: Segfault in gimple_build_call_1, at gimple.c:218)
Jakub Jelinek [Tue, 30 May 2017 07:58:55 +0000 (09:58 +0200)] 
backport: re PR c++/79512 (ICE: Segfault in gimple_build_call_1, at gimple.c:218)

Backported from mainline
2017-02-16  Jakub Jelinek  <jakub@redhat.com>

PR c++/79512
* c-parser.c (c_parser_omp_target): For -fopenmp-simd
ignore #pragma omp target even when not followed by identifier.

* parser.c (cp_parser_omp_target): For -fopenmp-simd
ignore #pragma omp target even when not followed by identifier.

* c-c++-common/gomp/pr79512.c: New test.

From-SVN: r248643

8 years agobackport: re PR tree-optimization/79411 (ICE: SSA corruption (fail_abnormal_edge_coal...
Jakub Jelinek [Tue, 30 May 2017 07:58:01 +0000 (09:58 +0200)] 
backport: re PR tree-optimization/79411 (ICE: SSA corruption (fail_abnormal_edge_coalesce))

Backported from mainline
2017-02-10  Jakub Jelinek  <jakub@redhat.com>

PR tree-optimization/79411
* tree-ssa-reassoc.c (is_reassociable_op): Return false if
stmt operands are SSA_NAMEs used in abnormal phis.
(can_reassociate_p): Return false if op is SSA_NAME used in abnormal
phis.

* gcc.c-torture/compile/pr79411.c: New test.

From-SVN: r248642

8 years agobackport: re PR middle-end/79399 (GCC fails to compile big source at -O0)
Jakub Jelinek [Tue, 30 May 2017 07:57:10 +0000 (09:57 +0200)] 
backport: re PR middle-end/79399 (GCC fails to compile big source at -O0)

Backported from mainline
2017-02-07  Jakub Jelinek  <jakub@redhat.com>
    Richard Biener  <rguenther@suse.de>

PR middle-end/79399
* ira-int.h (struct target_ira_int): Change x_max_struct_costs_size
type from int to size_t.
* ira-costs.c (struct_costs_size): Change type from int to size_t.

From-SVN: r248641

8 years agobackport: re PR target/79197 (ICE in extract_insn in gcc/recog.c:2311)
Jakub Jelinek [Tue, 30 May 2017 07:56:11 +0000 (09:56 +0200)] 
backport: re PR target/79197 (ICE in extract_insn in gcc/recog.c:2311)

Backported from mainline
2017-02-02  Jakub Jelinek  <jakub@redhat.com>

PR target/79197
* config/rs6000/rs6000.md (*fixuns_trunc<mode>di2_fctiduz): Rename to ...
(fixuns_trunc<mode>di2): ... this, remove previous expander.  Put all
conditions on a single line.

* gcc.target/powerpc/pr79197.c: New test.
* gcc.c-torture/compile/pr79197.c: New test.

From-SVN: r248640

8 years agobackport: re PR c++/78341 (ICE on invalid C++ code on x86_64-linux-gnu (internal...
Jakub Jelinek [Tue, 30 May 2017 07:55:06 +0000 (09:55 +0200)] 
backport: re PR c++/78341 (ICE on invalid C++ code on x86_64-linux-gnu  (internal compiler error: in cp_parser_std_attribute_spec, at cp/parser.c:24597))

Backported from mainline
2017-01-11  Jakub Jelinek  <jakub@redhat.com>

PR c++/78341
* parser.c (cp_parser_std_attribute_spec): Remove over-eager
assertion.  Formatting fix.

* g++.dg/cpp0x/pr78341.C: New test.

From-SVN: r248639

8 years agobackport: re PR middle-end/50199 (wrong code with -flto -fno-merge-constants)
Jakub Jelinek [Tue, 30 May 2017 07:54:21 +0000 (09:54 +0200)] 
backport: re PR middle-end/50199 (wrong code with -flto -fno-merge-constants)

Backported from mainline
2017-01-11  Jakub Jelinek  <jakub@redhat.com>

PR middle-end/50199
* lto-lang.c (lto_post_options): Force flag_merge_constants = 1
if it was 0.

* gcc.dg/lto/pr50199_0.c: New test.

From-SVN: r248638

8 years agobackport: re PR c++/78949 (incorrect "unused variable" warning with SSE2)
Jakub Jelinek [Tue, 30 May 2017 07:53:35 +0000 (09:53 +0200)] 
backport: re PR c++/78949 (incorrect "unused variable" warning with SSE2)

Backported from mainline
2017-01-04  Jakub Jelinek  <jakub@redhat.com>

PR c++/78949
* typeck.c (cp_build_unary_op): Call mark_rvalue_use on arg if it has
vector type.

* c-c++-common/Wunused-var-16.c: New test.

From-SVN: r248637

8 years agobackport: re PR fortran/78866 (ICE in gimplify_adjust_omp_clauses_1, at gimplify...
Jakub Jelinek [Tue, 30 May 2017 07:52:55 +0000 (09:52 +0200)] 
backport: re PR fortran/78866 (ICE in gimplify_adjust_omp_clauses_1, at gimplify.c:8721)

Backported from mainline
2016-12-21  Jakub Jelinek  <jakub@redhat.com>

PR fortran/78866
* openmp.c (resolve_omp_clauses): Diagnose assumed size arrays in
OpenMP map, to and from clauses.
* trans-openmp.c: Include diagnostic-core.h, temporarily redefining
GCC_DIAG_STYLE to __gcc_tdiag__.
(gfc_omp_finish_clause): Diagnose implicitly mapped assumed size
arrays.

* gfortran.dg/gomp/map-1.f90: Add expected error.
* gfortran.dg/gomp/pr78866-1.f90: New test.
* gfortran.dg/gomp/pr78866-2.f90: New test.

From-SVN: r248636

8 years agobackport: re PR c/77767 (Side-effect from VLA array parameters lost)
Jakub Jelinek [Tue, 30 May 2017 07:51:58 +0000 (09:51 +0200)] 
backport: re PR c/77767 (Side-effect from VLA array parameters lost)

Backported from mainline
2016-12-21  Jakub Jelinek  <jakub@redhat.com>

PR c/77767
* c-decl.c (grokdeclarator): If *expr is non-NULL, append expression
to *expr instead of overwriting it.

* gcc.c-torture/execute/pr77767.c: New test.

From-SVN: r248635

8 years agobackport: re PR ipa/77905 (ICE at -Os and above in both 32-bit and 64-bit modes on...
Jakub Jelinek [Tue, 30 May 2017 07:51:12 +0000 (09:51 +0200)] 
backport: re PR ipa/77905 (ICE at -Os and above in both 32-bit and 64-bit modes on x86_64-linux-gnu (internal compiler error: in ipa_comdats, at ipa-comdats.c:352))

Backported from mainline
2016-12-13  Jakub Jelinek  <jakub@redhat.com>

PR ipa/77905
* ipa-pure-const.c (cdtor_p): Return true for
DECL_STATIC_{CON,DE}STRUCTOR even when it is
DECL_LOOPING_CONST_OR_PURE_P.

* g++.dg/ipa/pr77905.C: New test.

From-SVN: r248634

8 years agobackport: re PR target/78796 (TLS fails to link on aarch64 with -mcmodel=large)
Jakub Jelinek [Tue, 30 May 2017 07:48:57 +0000 (09:48 +0200)] 
backport: re PR target/78796 (TLS fails to link on aarch64 with -mcmodel=large)

Backported from mainline
2016-12-14  Wilco Dijkstra  <wdijkstr@arm.com>
    Jakub Jelinek  <jakub@redhat.com>

PR target/78796
* config/aarch64/aarch64.c (aarch64_classify_symbol): Merge large
model checks into switch.

* gcc.dg/tls/pr78796.c: New test.

From-SVN: r248632

8 years agobackport: re PR c++/78761 (C++14, compiler generate mangled name that can not be...
Jakub Jelinek [Tue, 30 May 2017 07:47:05 +0000 (09:47 +0200)] 
backport: re PR c++/78761 (C++14, compiler generate mangled name that can not be demangled)

Backported from mainline
2016-12-13  Jakub Jelinek  <jakub@redhat.com>

PR c++/78761
* cp-demangle.c (cplus_demangle_type): Demangle Dc as decltype(auto).
* testsuite/demangle-expected: Add test for decltype(auto).

From-SVN: r248631

8 years agobackport: re PR c++/78649 (ICE on invalid C++ code on x86_64-linux-gnu (internal...
Jakub Jelinek [Tue, 30 May 2017 07:46:27 +0000 (09:46 +0200)] 
backport: re PR c++/78649 (ICE on invalid C++ code on x86_64-linux-gnu (internal compiler error: tree check: expected class ‘type’, have ‘exceptional’ (error_mark) in build_value_init_noctor, at cp/init.c:380))

Backported from mainline
2016-12-02  Jakub Jelinek  <jakub@redhat.com>

PR c++/78649
* pt.c (tsubst_init): Don't call build_value_init if decl's type
is error_mark_node.

* g++.dg/cpp0x/pr78649.C: New test.

From-SVN: r248630

8 years agobackport: re PR fortran/78298 (ICE in lookup_decl_in_outer_ctx, bei omp-low.c:4115)
Jakub Jelinek [Tue, 30 May 2017 07:45:47 +0000 (09:45 +0200)] 
backport: re PR fortran/78298 (ICE in lookup_decl_in_outer_ctx, bei omp-low.c:4115)

Backported from mainline
2016-11-28  Jakub Jelinek  <jakub@redhat.com>

PR fortran/78298
* tree-nested.c (convert_local_reference_stmt): After adding
shared (FRAME.NN) clause to omp parallel, task or target,
add it also to all outer omp parallel, task or target constructs.

* gfortran.dg/gomp/pr78298.f90: New test.

From-SVN: r248629

8 years agobackport: re PR middle-end/69183 (ICE when using OpenMP PRIVATE keyword in OMP DO...
Jakub Jelinek [Tue, 30 May 2017 07:44:51 +0000 (09:44 +0200)] 
backport: re PR middle-end/69183 (ICE when using OpenMP PRIVATE keyword in OMP DO loop not explicitly encapsulated in OMP PARALLEL region)

Backported from mainline
2016-11-23  Jakub Jelinek  <jakub@redhat.com>

PR middle-end/69183
* omp-low.c (build_outer_var_ref): Change lastprivate argument
to code, pass it recursively, adjust uses.  For OMP_CLAUSE_PRIVATE
on worksharing constructs, treat it like clauses on simd construct.
Formatting fix.
(lower_rec_input_clauses): For OMP_CLAUSE_PRIVATE_OUTER_REF pass
OMP_CLAUSE_PRIVATE as last argument to build_outer_var_ref.
(lower_lastprivate_clauses): Pass OMP_CLAUSE_LASTPRIVATE instead
of true as last argument to build_outer_var_ref.

* gfortran.dg/gomp/pr69183.f90: New test.

From-SVN: r248628

8 years agobackport: re PR c++/77739 (internal compiler error: in create_tmp_var, at gimple...
Jakub Jelinek [Tue, 30 May 2017 07:44:11 +0000 (09:44 +0200)] 
backport: re PR c++/77739 (internal compiler error: in create_tmp_var, at gimple-expr.c:524)

Backported from mainline
2016-11-23  Jakub Jelinek  <jakub@redhat.com>

PR c++/77739
* cp-gimplify.c (cp_gimplify_tree) <case VEC_INIT_EXPR>: Pass
false as handle_invisiref_parm_p to cp_genericize_tree.
(struct cp_genericize_data): Add handle_invisiref_parm_p field.
(cp_genericize_r): Don't wrap is_invisiref_parm into references
if !wtd->handle_invisiref_parm_p.
(cp_genericize_tree): Add handle_invisiref_parm_p argument,
set wtd.handle_invisiref_parm_p to it.
(cp_genericize): Pass true as handle_invisiref_parm_p to
cp_genericize_tree.  Formatting fix.

* g++.dg/cpp1y/pr77739.C: New test.

From-SVN: r248627

8 years agobackport: re PR middle-end/78416 (wrong code for division by (u128)~INT64_MAX at...
Jakub Jelinek [Tue, 30 May 2017 07:43:37 +0000 (09:43 +0200)] 
backport: re PR middle-end/78416 (wrong code for division by (u128)~INT64_MAX at -O0)

Backported from mainline
2016-11-22  Jakub Jelinek  <jakub@redhat.com>

PR middle-end/78416
* expmed.c (expand_divmod): Use wide_int for computation of
op1_is_pow2.  Don't set it if op1 is 0.  Formatting fixes.
Use size <= HOST_BITS_PER_WIDE_INT instead of
HOST_BITS_PER_WIDE_INT >= size.

* gcc.dg/torture/pr78416.c: New test.

From-SVN: r248626

8 years agobackport: re PR middle-end/67335 (ICE in compiling omp simd function with unused...
Jakub Jelinek [Tue, 30 May 2017 07:42:48 +0000 (09:42 +0200)] 
backport: re PR middle-end/67335 (ICE in compiling omp simd function with unused argument)

Backported from mainline
2016-11-21  Jakub Jelinek  <jakub@redhat.com>

PR middle-end/67335
* omp-low.c (simd_clone_adjust_argument_types): Use NULL prefix
for tmp simd array if DECL_NAME (parm) is NULL.

* g++.dg/vect/simd-clone-7.cc: New test.

From-SVN: r248625

8 years agobackport: re PR c++/77285 (extern thread_local linkage)
Jakub Jelinek [Tue, 30 May 2017 07:41:57 +0000 (09:41 +0200)] 
backport: re PR c++/77285 (extern thread_local linkage)

Backported from mainline
2016-11-18  Jakub Jelinek  <jakub@redhat.com>

PR c++/77285
* mangle.c (mangle_tls_init_fn, mangle_tls_wrapper_fn): Call
check_abi_tags.

* g++.dg/tls/pr77285-1.C: New test.
* g++.dg/tls/pr77285-2.C: New test.

From-SVN: r248624

8 years agobackport: re PR rtl-optimization/78378 (wrong code when combining shift + mult +...
Jakub Jelinek [Tue, 30 May 2017 07:40:21 +0000 (09:40 +0200)] 
backport: re PR rtl-optimization/78378 (wrong code when combining shift + mult + zero_extend)

Backported from mainline
2016-11-16  Jakub Jelinek  <jakub@redhat.com>

PR rtl-optimization/78378
* combine.c (make_extraction): Use force_to_mode for non-{REG,MEM}
inner only if pos is 0.  Fix up formatting.

* gcc.c-torture/execute/pr78378.c: New test.

From-SVN: r248623

8 years agobackport: re PR target/78227 (ICE: unrecognizable insn: in extract_insn, at recog...
Jakub Jelinek [Tue, 30 May 2017 07:39:37 +0000 (09:39 +0200)] 
backport: re PR target/78227 (ICE: unrecognizable insn: in extract_insn, at recog.c:2311 with -mavx512bw and vector comare)

Backported from mainline
2016-11-07  Jakub Jelinek  <jakub@redhat.com>

PR target/78227
* config/i386/i386.c (ix86_expand_sse_cmp): Force dest into
cmp_mode argument even for -O0 if cmp_mode != mode and maskcmp.

* gcc.target/i386/pr78227-1.c: New test.
* gcc.target/i386/pr78227-2.c: New test.

From-SVN: r248622

8 years agobackport: hashtab.h: Use standard GPLv3 with runtime exception boilerplate.
Jakub Jelinek [Tue, 30 May 2017 07:38:19 +0000 (09:38 +0200)] 
backport: hashtab.h: Use standard GPLv3 with runtime exception boilerplate.

Backported from mainline
2016-11-01  Jakub Jelinek  <jakub@redhat.com>

* hashtab.h: Use standard GPLv3 with runtime exception
boilerplate.

From-SVN: r248621

8 years agobackport: re PR c++/78089 (__builtin_shuffle parsing bug)
Jakub Jelinek [Tue, 30 May 2017 07:37:39 +0000 (09:37 +0200)] 
backport: re PR c++/78089 (__builtin_shuffle parsing bug)

Backported from mainline
2016-10-31  Jakub Jelinek  <jakub@redhat.com>

PR c++/78089
* parser.c (cp_parser_postfix_expression): Replace return statement in
the first switch with setting postfix_expression to the return
expression and break;.

* c-c++-common/builtin-shuffle-1.c: New test.

From-SVN: r248620

8 years agobackport: re PR rtl-optimization/77919 (ICE converting DC to V2DF mode)
Jakub Jelinek [Tue, 30 May 2017 07:36:52 +0000 (09:36 +0200)] 
backport: re PR rtl-optimization/77919 (ICE converting DC to V2DF mode)

Backported from mainline
2016-10-29  Jakub Jelinek  <jakub@redhat.com>

PR rtl-optimization/77919
* expr.c (expand_expr_real_1) <normal_inner_ref>: Only avoid forcing
into memory if both modes are complex and their inner modes have the
same precision.  If the two modes are different complex modes, convert
each part separately and generate a new CONCAT.

* g++.dg/torture/pr77919-2.C: New test.

From-SVN: r248619

8 years agobackport: re PR rtl-optimization/77919 (ICE converting DC to V2DF mode)
Jakub Jelinek [Tue, 30 May 2017 07:36:13 +0000 (09:36 +0200)] 
backport: re PR rtl-optimization/77919 (ICE converting DC to V2DF mode)

Backported from mainline
2016-10-28  Jakub Jelinek  <jakub@redhat.com>

PR rtl-optimization/77919
* expr.c (expand_expr_real_1) <normal_inner_ref>: Force CONCAT into
MEM if mode1 is not a complex mode.

* g++.dg/torture/pr77919.C: New test.

From-SVN: r248618

8 years agobackport: re PR sanitizer/66343 ("Error: .Lubsan_type3 already defined" with UBSan...
Jakub Jelinek [Tue, 30 May 2017 07:34:46 +0000 (09:34 +0200)] 
backport: re PR sanitizer/66343 ("Error: .Lubsan_type3 already defined" with UBSan and precompiled headers)

Backported from mainline
2016-10-05  Jakub Jelinek  <jakub@redhat.com>

PR sanitizer/66343
* ubsan.c (ubsan_ids): New GTY(()) array.
(ubsan_type_descriptor, ubsan_create_data): Use ubsan_ids
instead of static local counters.

* gcc.dg/pch/pr66343-1.c: New test.
* gcc.dg/pch/pr66343-1.hs: New file.
* gcc.dg/pch/pr66343-2.c: New test.
* gcc.dg/pch/pr66343-2.hs: New file.

From-SVN: r248616

8 years agobackport: re PR c++/77467 (Segmentation fault with switch statement in constexpr...
Jakub Jelinek [Tue, 30 May 2017 07:32:25 +0000 (09:32 +0200)] 
backport: re PR c++/77467 (Segmentation fault with switch statement in constexpr function)

Backported from mainline
2016-09-28  Jakub Jelinek  <jakub@redhat.com>

PR c++/77467
* constexpr.c (enum constexpr_switch_state): New.
(struct constexpr_ctx): Add css_state field.
(label_matches): Add CTX and STMT arguments, remove I and
DEFAULT_LABEL.  For CASE_LABEL_EXPR assert ctx->css_state != NULL,
handle default labels according to css_state.
(cxx_eval_statement_list): Remove statement skipping, label_matches
and default_label handling code.
(cxx_eval_loop_expr): Exit after first iteration even if
switches (jump_target).
(cxx_eval_switch_expr): Set up css_state field in ctx, if default
label has been seen in the body, but no cases matched, evaluate
the body second time.
(cxx_eval_constant_expression): Handle stmt skipping and label_matches
here.  Handle PREDICT_EXPR.  For MODIFY_EXPR or INIT_EXPR, assert
statement is not skipped.  For COND_EXPR during skipping, don't
evaluate condition, just the then block and if still skipping at the
end also the else block.
(cxx_eval_outermost_constant_expr): Adjust constexpr_ctx initializer.
(is_sub_constant_expr): Likewise.

* g++.dg/cpp1y/constexpr-77467.C: New test.

From-SVN: r248615

8 years agobackport: re PR c++/77722 (-fsanitize=undefined doesn't give runtime error in functio...
Jakub Jelinek [Tue, 30 May 2017 07:31:03 +0000 (09:31 +0200)] 
backport: re PR c++/77722 (-fsanitize=undefined doesn't give runtime error in function without return value, unless at least 2 instructions)

Backported from mainline
2016-09-27  Jakub Jelinek  <jakub@redhat.com>

PR c++/77722
* cp-gimplify.c (cp_ubsan_maybe_instrument_return): Instrument also
functions that have just a STATEMENT_LIST instead of BIND_EXPR, or
BIND_EXPR with some statement rather than STATEMENT_LIST as body.

* g++.dg/ubsan/return-4.C: New test.
* g++.dg/ubsan/return-5.C: New test.
* g++.dg/ubsan/return-6.C: New test.

From-SVN: r248614

8 years agobackport: re PR fortran/77666 (ICE in gfc_omp_clause_default_ctor, at fortran/trans...
Jakub Jelinek [Tue, 30 May 2017 07:29:49 +0000 (09:29 +0200)] 
backport: re PR fortran/77666 (ICE in gfc_omp_clause_default_ctor, at fortran/trans-openmp.c:471)

Backported from mainline
2016-09-27  Jakub Jelinek  <jakub@redhat.com>

PR fortran/77666
* trans-openmp.c (gfc_omp_private_outer_ref): Return true even for
references to allocatable arrays.

* gfortran.dg/gomp/pr77666.f90: New test.

From-SVN: r248613

8 years agobackport: re PR tree-optimization/77665 (ICE in expand_GOMP_SIMD_VF, at internal...
Jakub Jelinek [Tue, 30 May 2017 07:28:40 +0000 (09:28 +0200)] 
backport: re PR tree-optimization/77665 (ICE in expand_GOMP_SIMD_VF, at internal-fn.c:172)

Backported from mainline
2016-09-22  Jakub Jelinek  <jakub@redhat.com>

PR fortran/77665
* tree-inline.c (remap_gimple_stmt): Set has_simduid_loops
for all IFN_GOMP_SIMD_* internal fns.

* gfortran.dg/gomp/pr77665.f90: New test.

From-SVN: r248612

8 years agobackport: re PR c++/77637 (ICE on x86_64-linux-gnu (Segmentation fault, tree_check...
Jakub Jelinek [Tue, 30 May 2017 07:27:33 +0000 (09:27 +0200)] 
backport: re PR c++/77637 (ICE on x86_64-linux-gnu (Segmentation fault, tree_check, cp_parser_std_attribute_list...))

Backported from mainline
2016-09-20  Jakub Jelinek  <jakub@redhat.com>

PR c++/77637
* parser.c (cp_parser_std_attribute_list): Reject ... without
preceding attribute.

* g++.dg/cpp0x/gen-attrs-62.C: New test.

From-SVN: r248611

8 years agobackport: re PR middle-end/77624 (ICE on x86_64-linux-gnu (internal compiler error...
Jakub Jelinek [Tue, 30 May 2017 07:26:43 +0000 (09:26 +0200)] 
backport: re PR middle-end/77624 (ICE on x86_64-linux-gnu (internal compiler error: in fold_builtin_atomic_always_lock_free, at builtins.c:5583))

Backported from mainline
2016-09-20  Jakub Jelinek  <jakub@redhat.com>

PR middle-end/77624
* builtins.c (fold_builtin_atomic_always_lock_free): Only look through
cast to void * if the cast is from some other pointer type.

* c-c++-common/pr77624-1.c: New test.
* c-c++-common/pr77624-2.c: New test.

From-SVN: r248610

8 years agobackport: re PR ipa/77587 (C compiler produces incorrect stack alignment with __attri...
Jakub Jelinek [Tue, 30 May 2017 07:26:00 +0000 (09:26 +0200)] 
backport: re PR ipa/77587 (C compiler produces incorrect stack alignment with __attribute__((weak)))

Backported from mainline
2016-09-19  Jakub Jelinek  <jakub@redhat.com>
    Jan Hubicka  <jh@suse.cz>

PR target/77587
* cgraph.c (cgraph_node::rtl_info): Pass &avail to
ultimate_alias_target call, return NULL if avail < AVAIL_AVAILABLE.
Call ultimate_alias_target just once, not up to 4 times.

* gcc.dg/pr77587.c: New test.
* gcc.dg/pr77587a.c: New file.

From-SVN: r248609

8 years agobackport: re PR c++/77375 (constant object with mutable subobject allocated in read...
Jakub Jelinek [Tue, 30 May 2017 07:24:56 +0000 (09:24 +0200)] 
backport: re PR c++/77375 (constant object with mutable subobject allocated in read-only memory)

Backported from mainline
2016-09-16  Jakub Jelinek  <jakub@redhat.com>

PR c++/77375
* class.c (check_bases): Set CLASSTYPE_HAS_MUTABLE if any
TYPE_HAS_MUTABLE_P for any bases.

* g++.dg/cpp0x/mutable1.C: New test.

From-SVN: r248608

8 years agobackport: re PR middle-end/77594 (double computation for __builtin_sub_overflow ...
Jakub Jelinek [Tue, 30 May 2017 07:23:20 +0000 (09:23 +0200)] 
backport: re PR middle-end/77594 (double computation for __builtin_sub_overflow (0, ...))

Backported from mainline
2016-09-16  Jakub Jelinek  <jakub@redhat.com>
    Eric Botcazou  <ebotcazou@adacore.com>

PR middle-end/77594
* internal-fn.c (expand_arith_overflow) <case MINUS_EXPR>: Don't fall
through into expand_addsub_overflow after expand_neg_overflow.

* gcc.target/i386/pr77594.c: New test.

From-SVN: r248607

8 years agobackport: re PR sanitizer/68260 (false positive with tsan)
Jakub Jelinek [Tue, 30 May 2017 07:22:25 +0000 (09:22 +0200)] 
backport: re PR sanitizer/68260 (false positive with tsan)

Backported from mainline
2016-09-14  Jakub Jelinek  <jakub@redhat.com>

PR sanitizer/68260
* tsan.c: Include target.h.
(enum tsan_atomic_action): Add bool_clear and bool_test_and_set.
(BOOL_CLEAR, BOOL_TEST_AND_SET): Define.
(tsan_atomic_table): Add BUILT_IN_ATOMIC_CLEAR and
BUILT_IN_ATOMIC_TEST_AND_SET entries.
(instrument_builtin_call): Handle bool_clear and bool_test_and_set.

* c-c++-common/tsan/pr68260.c: New test.

From-SVN: r248606

8 years agobackport: re PR fortran/77500 (ICE in gfc_trans_omp_atomic, at fortran/trans-openmp...
Jakub Jelinek [Tue, 30 May 2017 07:21:41 +0000 (09:21 +0200)] 
backport: re PR fortran/77500 (ICE in gfc_trans_omp_atomic, at fortran/trans-openmp.c:2822)

Backported from mainline
2016-09-08  Jakub Jelinek  <jakub@redhat.com>

PR fortran/77500
* trans-openmp.c (gfc_trans_omp_atomic): For atomic write or
swap, don't try to look through GFC_ISYM_CONVERSION.  In other cases,
check that value.function.isym is non-NULL before dereferencing it.

* gfortran.dg/gomp/pr77500.f90: New test.

From-SVN: r248605

8 years agobackport: re PR fortran/77516 (ICE in is_gimple_min_invariant, at gimple-expr.c:706)
Jakub Jelinek [Tue, 30 May 2017 07:20:41 +0000 (09:20 +0200)] 
backport: re PR fortran/77516 (ICE in is_gimple_min_invariant, at gimple-expr.c:706)

Backported from mainline
2016-09-08  Jakub Jelinek  <jakub@redhat.com>

PR fortran/77516
* omp-low.c (lower_rec_simd_input_clauses): Use max_vf for non-positive
OMP_CLAUSE_SAFELEN_EXPR.

* gfortran.dg/gomp/pr77516.f90: New test.

From-SVN: r248604

8 years agobackport: re PR sanitizer/77396 (address sanitizer crashes if all static global...
Jakub Jelinek [Tue, 30 May 2017 07:19:49 +0000 (09:19 +0200)] 
backport: re PR sanitizer/77396 (address  sanitizer crashes if all static global variables are optimized)

Backported from mainline
2016-09-05  Jakub Jelinek  <jakub@redhat.com>

PR sanitizer/77396
* asan/asan_globals.cc: Cherry-pick upstream r280657.

2016-09-05  Jakub Jelinek  <jakub@redhat.com>

PR sanitizer/77396
* g++.dg/asan/pr77396-2.C: New test.

2016-09-02  Jakub Jelinek  <jakub@redhat.com>

PR sanitizer/77396
* g++.dg/asan/pr77396.C: New test.

From-SVN: r248603

8 years agobackport: re PR c++/77363 (Missing debug information in DWARF)
Jakub Jelinek [Tue, 30 May 2017 07:18:37 +0000 (09:18 +0200)] 
backport: re PR c++/77363 (Missing debug information in DWARF)

Backported from mainline
2016-08-30  Jakub Jelinek  <jakub@redhat.com>

PR debug/77363
* dwarf2out.c (modified_type_die): Use lookup_type_die (type)
instead of lookup_type_die (type_main_variant (type)) even for array
types.

* g++.dg/debug/dwarf2/pr77363.C: New test.

From-SVN: r248602

8 years agobackport: re PR middle-end/77377 (c-c++-common/pr59037.c ICEs with -fpic -msse on...
Jakub Jelinek [Tue, 30 May 2017 07:17:45 +0000 (09:17 +0200)] 
backport: re PR middle-end/77377 (c-c++-common/pr59037.c ICEs with -fpic -msse on i686)

Backported from mainline
2016-08-30  Jakub Jelinek  <jakub@redhat.com>

PR middle-end/77377
* simplify-rtx.c (avoid_constant_pool_reference): For out of bounds
constant pool reference return x instead of c.

* gcc.target/i386/pr77377.c: New test.

From-SVN: r248601

8 years agobackport: re PR target/71910 (ICE on valid OpenMP code)
Jakub Jelinek [Tue, 30 May 2017 07:15:49 +0000 (09:15 +0200)] 
backport: re PR target/71910 (ICE on valid OpenMP code)

Backported from mainline
2016-08-16  Jakub Jelinek  <jakub@redhat.com>

PR target/71910
* tree-cfg.c (execute_fixup_cfg): Add node variable, use it.  Before inlining,
add cgraph edge for the added __builtin_unreachable call.

* g++.dg/gomp/pr71910.C: New test.

From-SVN: r248598

8 years agobackport: re PR tree-optimization/72824 (Signed floating point zero semantics broken...
Jakub Jelinek [Tue, 30 May 2017 07:13:36 +0000 (09:13 +0200)] 
backport: re PR tree-optimization/72824 (Signed floating point zero semantics broken at optimization level -O3 (tree-loop-distribute-patterns))

Backported from mainline
2016-08-15  Martin Liska  <mliska@suse.cz>
    Jakub Jelinek  <jakub@redhat.com>

PR tree-optimization/72824
* tree-loop-distribution.c (const_with_all_bytes_same)
<case VECTOR_CST>: Fix a typo.

* gcc.c-torture/execute/ieee/pr72824-2.c: New test.

From-SVN: r248597

8 years agobackport: re PR c/67410 (c/c-typeck.c references out of bounds array)
Jakub Jelinek [Tue, 30 May 2017 07:12:08 +0000 (09:12 +0200)] 
backport: re PR c/67410 (c/c-typeck.c references out of bounds array)

Backported from mainline
2016-08-12  Jakub Jelinek  <jakub@redhat.com>
    Martin Liska  <mliska@suse.cz>

PR c/67410
* c-typeck.c (set_nonincremental_init_from_string): Use / instead of
% to determine val element to change.  Assert that
wchar_bytes * charwidth fits into val array.

* gcc.dg/pr67410.c: New test.

From-SVN: r248596

8 years agobackport: re PR c++/72868 (Constexpr expressions mistreat case ranges)
Jakub Jelinek [Tue, 30 May 2017 07:11:09 +0000 (09:11 +0200)] 
backport: re PR c++/72868 (Constexpr expressions mistreat case ranges)

Backported from mainline
2016-08-11  Jakub Jelinek  <jakub@redhat.com>

PR c++/72868
* constexpr.c (label_matches): Handle case range expressions.

* g++.dg/cpp1y/constexpr-switch4.C: New test.

From-SVN: r248595

8 years agobackport: re PR c/72816 (ICE on x86_64-linux-gnu (tree check: expected tree that...
Jakub Jelinek [Tue, 30 May 2017 07:09:01 +0000 (09:09 +0200)] 
backport: re PR c/72816 (ICE on x86_64-linux-gnu (tree check: expected tree that contains ‘decl with RTL’ structure, have ‘field_decl’ in set_decl_rtl, at emit-rtl.c:1282))

Backported from mainline
2016-08-11  Jakub Jelinek  <jakub@redhat.com>

PR c/72816
* c-decl.c (grokdeclarator): When adding TYPE_DOMAIN for flexible
array member through typedef, for orig_qual_indirect == 0 clear
orig_qual_type.

2016-08-11  Jakub Jelinek  <jakub@redhat.com>

PR c/72816
* gcc.dg/pr72816.c: Remove dg-error.

2016-08-07  Jakub Jelinek  <jakub@redhat.com>

PR c/72816
* gcc.dg/pr72816.c: New test.

From-SVN: r248594

8 years agobackport: re PR tree-optimization/72824 (Signed floating point zero semantics broken...
Jakub Jelinek [Tue, 30 May 2017 07:07:25 +0000 (09:07 +0200)] 
backport: re PR tree-optimization/72824 (Signed floating point zero semantics broken at optimization level -O3 (tree-loop-distribute-patterns))

Backported from mainline
2016-08-09  Jakub Jelinek  <jakub@redhat.com>

PR tree-optimization/72824
* tree-loop-distribution.c (const_with_all_bytes_same): Verify
real_zerop is not negative.

* gcc.c-torture/execute/ieee/pr72824.c: New test.

From-SVN: r248593

8 years agobackport: re PR sanitizer/71953 (ICE using address sanitizers with PCH)
Jakub Jelinek [Tue, 30 May 2017 07:06:38 +0000 (09:06 +0200)] 
backport: re PR sanitizer/71953 (ICE using address sanitizers with PCH)

Backported from mainline
2016-07-21  Jakub Jelinek  <jakub@redhat.com>

PR sanitizer/71953
* asan.c (asan_dynamic_init_call): Call asan_init_shadow_ptr_types
before builtin_decl_implicit.

From-SVN: r248592

8 years agoDaily bump.
GCC Administrator [Tue, 30 May 2017 00:16:04 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248588

8 years agoinstall.texi (Options specification): Move entry of --enable-sjlj-exceptions.
Eric Botcazou [Mon, 29 May 2017 21:09:44 +0000 (21:09 +0000)] 
install.texi (Options specification): Move entry of --enable-sjlj-exceptions.

* doc/install.texi (Options specification): Move entry of
--enable-sjlj-exceptions.

From-SVN: r248585

8 years agoBackport r247097
Martin Liska [Mon, 29 May 2017 09:13:50 +0000 (11:13 +0200)] 
Backport r247097

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-24  Jan Hubicka  <hubicka@ucw.cz>

PR middle-end/79931
* ipa-devirt.c (dump_possible_polymorphic_call_targets): Fix ICE.
2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-24  Martin Liska  <mliska@suse.cz>

PR middle-end/79931
* g++.dg/ipa/pr79931.C: New test.

From-SVN: r248569

8 years agoBackport r246996
Martin Liska [Mon, 29 May 2017 09:13:20 +0000 (11:13 +0200)] 
Backport r246996

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-19  Richard Biener  <rguenther@suse.de>

PR ipa/65972
* auto-profile.c (afdo_vpt_for_early_inline): Update SSA
when needed by AutoPGO.

From-SVN: r248568

8 years agoBackport r246995
Martin Liska [Mon, 29 May 2017 09:12:50 +0000 (11:12 +0200)] 
Backport r246995

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-19  Paulo J. Matos  <paulo@matos-sorge.com>

PR lto/50345
* doc/lto.texi: Remove an extra 'that'.

From-SVN: r248567

8 years agoBackport r246961
Martin Liska [Mon, 29 May 2017 09:12:33 +0000 (11:12 +0200)] 
Backport r246961

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-18  Martin Liska  <mliska@suse.cz>

PR gcov-profile/78783
* gcov-tool.c (gcov_output_files): Validate that destination
file is either removed by the tool or by a user.
2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-18  Martin Liska  <mliska@suse.cz>

PR gcov-profile/78783
* libgcov-driver.c (gcov_get_filename): New function.

From-SVN: r248566

8 years agoBackport r246903
Martin Liska [Mon, 29 May 2017 09:12:02 +0000 (11:12 +0200)] 
Backport r246903

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-13  Martin Liska  <mliska@suse.cz>

PR gcov-profile/80413
* gcov-io.c (gcov_write_string): Copy to buffer just when
allocated size is greater than zero.

From-SVN: r248565

8 years agoBackport r246848
Martin Liska [Mon, 29 May 2017 09:11:42 +0000 (11:11 +0200)] 
Backport r246848

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-11  Martin Liska  <mliska@suse.cz>

PR ipa/80212
* cgraph.c (cgraph_node::dump): Dump calls_comdat_local.
* ipa-split.c (split_function): Create a local comdat symbol
if caller is in a comdat group.
2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-11  Martin Liska  <mliska@suse.cz>

PR ipa/80212
* g++.dg/ipa/pr80212.C: New test.

From-SVN: r248564

8 years agoBackport r246847
Martin Liska [Mon, 29 May 2017 09:10:58 +0000 (11:10 +0200)] 
Backport r246847

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-11  Martin Liska  <mliska@suse.cz>

PR ipa/80212
* ipa-cp.c (determine_versionability): Handle calls_comdat_local
flags.

From-SVN: r248563

8 years agoBackport r246837
Martin Liska [Mon, 29 May 2017 09:10:11 +0000 (11:10 +0200)] 
Backport r246837

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-11  Martin Liska  <mliska@suse.cz>

PR sanitizer/70878
* ubsan.c (instrument_object_size): Do not instrument register
variables.
2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-11  Martin Liska  <mliska@suse.cz>

PR sanitizer/70878
* gcc.dg/ubsan/pr70878.c: New test.

From-SVN: r248562

8 years agoBackport r246804
Martin Liska [Mon, 29 May 2017 09:09:27 +0000 (11:09 +0200)] 
Backport r246804

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-10  Martin Liska  <mliska@suse.cz>

PR gcov-profile/80224
* gcov.c (print_usage): Fix usage string.
(get_gcov_intermediate_filename): Remove.
(output_gcov_file): Use both for normal and intermediate format.
(generate_results): Do not initialize special file for
intermediate format.

From-SVN: r248561

8 years agoBackport r246730
Martin Liska [Mon, 29 May 2017 09:09:07 +0000 (11:09 +0200)] 
Backport r246730

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-06  Martin Liska  <mliska@suse.cz>

PR sanitizer/80166
* gcc.dg/asan/pr80166.c: New test.
2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-04-06  Martin Liska  <mliska@suse.cz>

PR sanitizer/80166
* sanitizer_common/sanitizer_common_interceptors.inc (INTERCEPTOR):
Cherry-pick upstream r299036.

From-SVN: r248560

8 years agoBackport r246530
Martin Liska [Mon, 29 May 2017 09:08:48 +0000 (11:08 +0200)] 
Backport r246530

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-03-28  Richard Biener  <rguenther@suse.de>

PR ipa/80205
* tree-inline.c (copy_phis_for_bb): Do not create PHI node
without arguments, generate default definition of a SSA name.
2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-03-28  Martin Liska  <mliska@suse.cz>

PR ipa/80205
* g++.dg/ipa/pr80205.C: New test.

From-SVN: r248559

8 years agoBackport r246525
Martin Liska [Mon, 29 May 2017 09:08:14 +0000 (09:08 +0000)] 
Backport r246525

2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-03-28  Martin Liska  <mliska@suse.cz>

PR ipa/80104
* cgraphunit.c (cgraph_node::expand_thunk): Mark argument of a
thunk call as DECL_GIMPLE_REG_P when vector or complex type.
2017-05-29  Martin Liska  <mliska@suse.cz>

Backport from mainline
2017-03-28  Martin Liska  <mliska@suse.cz>

PR ipa/80104
* gcc.dg/ipa/pr80104.c: New test.

From-SVN: r248558

8 years agoDaily bump.
GCC Administrator [Mon, 29 May 2017 00:16:05 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248549

8 years agoDaily bump.
GCC Administrator [Sun, 28 May 2017 00:16:06 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248541

8 years agoDaily bump.
GCC Administrator [Sat, 27 May 2017 00:16:05 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248529

8 years agoFix a SPARC -mcbcond compare-and-branch out of range failure.
Sheldon Lobo [Fri, 26 May 2017 20:00:58 +0000 (20:00 +0000)] 
Fix a SPARC -mcbcond compare-and-branch out of range failure.

Backported from mainline
2017-05-24  Sheldon Lobo  <smlobo@sheldon.us.oracle.com>

* config/sparc/sparc.md (length): Return the correct value for -mflat
sibcalls to match output_sibcall.

From-SVN: r248527

8 years agoDaily bump.
GCC Administrator [Fri, 26 May 2017 00:16:05 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248476

8 years agoDaily bump.
GCC Administrator [Thu, 25 May 2017 00:16:05 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248438

8 years agoDaily bump.
GCC Administrator [Wed, 24 May 2017 00:16:08 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248395

8 years agoDaily bump.
GCC Administrator [Tue, 23 May 2017 00:16:04 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248353

8 years agoDaily bump.
GCC Administrator [Mon, 22 May 2017 00:16:05 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248314

8 years agoDaily bump.
GCC Administrator [Sun, 21 May 2017 00:16:09 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248309

8 years agoDaily bump.
GCC Administrator [Sat, 20 May 2017 00:16:08 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248304

8 years agobackport: unwind-arm.h: Make _Unwind_GetIP...
Andreas Tobler [Fri, 19 May 2017 18:39:54 +0000 (20:39 +0200)] 
backport: unwind-arm.h: Make _Unwind_GetIP...

2017-05-19  Andreas Tobler  <andreast@gcc.gnu.org>

    Backport from mainline
    2017-05-17  Andreas Tobler  <andreast@gcc.gnu.org>

    * config/arm/unwind-arm.h: Make _Unwind_GetIP, _Unwind_GetIPInfo and
    _Unwind_SetIP available as functions for arm*-*-freebsd*.
    * config/arm/unwind-arm.c: Implement the above.

From-SVN: r248301

8 years agobackport: re PR target/80799 (x86-32 bits generates MMX without EMMS)
Uros Bizjak [Fri, 19 May 2017 18:08:19 +0000 (20:08 +0200)] 
backport: re PR target/80799 (x86-32 bits generates MMX without EMMS)

Backport from mainline
2017-05-18  Uros Bizjak  <ubizjak@gmail.com>

PR target/80799
* config/i386/mmx.md (*mov<mode>_internal): Enable
alternatives 11, 12, 13 and 14 also for 32bit targets.
Remove alternatives 15, 16, 17 and 18.
* config/i386/sse.md (vec_concatv2di): Change
alternative (!x, *y) to (x, ?!*Yn).

testsuite/ChangeLog:

Backport from mainline
2017-05-18  Uros Bizjak  <ubizjak@gmail.com>

PR target/80799
* g++.dg/other/i386-11.C: New test.

From-SVN: r248297

8 years agoDon't assume __secure_getenv is available
Janne Blomqvist [Fri, 19 May 2017 13:30:45 +0000 (16:30 +0300)] 
Don't assume __secure_getenv is available

Glibc 2.17 made __secure_getenv an officially supported function, and
renamed it secure_getenv. The libgfortran configure has checked for
both of these, per
https://sourceware.org/glibc/wiki/Tips_and_Tricks/secure_getenv.

Unfortunately, while the dynamical library (libc.so) retains the
__secure_getenv symbol for backwards compatibility, the static library
(libc.a) does not. This means that a libgfortran.a compiled against an
older glibc will not work if one tries to link against a newer
libc.a. This creates problems for providing gfortran binary
distributions that work on as many target systems as possible.

Thus, retain the support for __secure_getenv but call it only via a
weak reference.

Backported from trunk.

2017-05-19  Janne Blomqvist  <jb@gcc.gnu.org>

* libgfortran.h: HAVE_SECURE_GETENV: Don't check
HAVE___SECURE_GETENV.
* environ/runtime.c (secure_getenv): Use __secure_getenv via a
        weak reference.

From-SVN: r248275

8 years agoDaily bump.
GCC Administrator [Fri, 19 May 2017 00:16:05 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r248257

8 years agoReplace c++11 effective-target with dg-options directive
Jonathan Wakely [Thu, 18 May 2017 15:31:47 +0000 (16:31 +0100)] 
Replace c++11 effective-target with dg-options directive

* testsuite/22_locale/codecvt/codecvt_utf16/79980.cc: Replace
effective-target with dg-options directive.
* testsuite/22_locale/codecvt/codecvt_utf16/80041.cc: Likewise.
* testsuite/22_locale/codecvt/codecvt_utf16/members.cc: Likewise.
* testsuite/22_locale/codecvt/codecvt_utf16/misaligned.cc: Likewise.
* testsuite/22_locale/codecvt/codecvt_utf8/79980.cc: Likewise.
* testsuite/22_locale/codecvt/codecvt_utf8/members.cc: Likewise.
* testsuite/22_locale/codecvt/codecvt_utf8_utf16/79511.cc: Likewise.
* testsuite/22_locale/codecvt/codecvt_utf8_utf16/members.cc: Likewise.

From-SVN: r248239

8 years agoSkip C tests if test flags include C++ options
Jonathan Wakely [Thu, 18 May 2017 15:31:41 +0000 (16:31 +0100)] 
Skip C tests if test flags include C++ options

Backport from mainline
2016-08-02  Jonathan Wakely  <jwakely@redhat.com>

* testsuite/18_support/bad_exception/23591_thread-1.c: Skip test if
options are present that aren't valid for C.
* testsuite/abi/header_cxxabi.c: Likewise.

From-SVN: r248238

8 years agoPR libstdc++/80504 qualify calls to avoid ADL
Jonathan Wakely [Thu, 18 May 2017 15:31:36 +0000 (16:31 +0100)] 
PR libstdc++/80504 qualify calls to avoid ADL

Backport from mainline
2017-04-24  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/80504
* include/std/functional (ref, cref): Qualify calls.
* testsuite/20_util/reference_wrapper/80504.cc: New test.

From-SVN: r248237

8 years agoPR libstdc++/80448 remove noexcept from defaulted functions
Jonathan Wakely [Thu, 18 May 2017 15:31:22 +0000 (16:31 +0100)] 
PR libstdc++/80448 remove noexcept from defaulted functions

Backport from mainline
2017-04-19  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/80448
* include/experimental/bits/fs_dir.h (directory_iterator)
(recursive_directory_iterator): Remove noexcept from defaulted
constructors.

From-SVN: r248236

8 years agoUncomment std::reference_wrapper tests that no longer fail
Jonathan Wakely [Thu, 18 May 2017 15:31:17 +0000 (16:31 +0100)] 
Uncomment std::reference_wrapper tests that no longer fail

Backport from mainline
2017-04-03  Jonathan Wakely  <jwakely@redhat.com>

* testsuite/20_util/reference_wrapper/invoke.cc: Uncomment tests
that no longer fail.

From-SVN: r248235

8 years agoFix comments in libstdc++ header and test
Jonathan Wakely [Thu, 18 May 2017 15:31:13 +0000 (16:31 +0100)] 
Fix comments in libstdc++ header and test

Backport from mainline
2017-04-03  Jonathan Wakely  <jwakely@redhat.com>

* include/bits/ios_base.h: Correct comment.
* testsuite/util/testsuite_hooks.h: Likewise.

From-SVN: r248234

8 years agoPR libstdc++/67440 make pretty printers work with GDB 7.6 again
Jonathan Wakely [Thu, 18 May 2017 15:31:07 +0000 (16:31 +0100)] 
PR libstdc++/67440 make pretty printers work with GDB 7.6 again

Backport from mainline
2017-03-16  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/67440
* python/libstdcxx/v6/printers.py (find_type): Avoid gdb.Type.name
for GDB 7.6 compatibility, use gdb.Type.unqualified instead.

From-SVN: r248233

8 years agoPR69699 document why __GLIBCXX__ macro is useless
Jonathan Wakely [Thu, 18 May 2017 15:31:02 +0000 (16:31 +0100)] 
PR69699 document why __GLIBCXX__ macro is useless

Backport from mainline
2017-01-17  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/69699
* doc/xml/manual/abi.xml (abi.versioning.history): Explain why the
_GLIBCXX__ macro is not useful. Remove redundant date information
and link to the GCC release timeline.
(abi.versioning.active): Move partial sentence into the previous
paragraph.
* doc/html/*: Regenerate.

From-SVN: r248232

8 years agoPR 71444 define more error constants for mingw-w64
Jonathan Wakely [Thu, 18 May 2017 15:30:57 +0000 (16:30 +0100)] 
PR 71444 define more error constants for mingw-w64

Backport from mainline
2016-12-21  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/71444
* config/os/mingw32-w64/error_constants.h
(address_family_not_supported, address_in_use, address_not_available)
(already_connected, connection_aborted, connection_already_in_progress)
connection_refused, connection_reset, cross_device_link)
(destination_address_required, host_unreachable, message_size)
(network_down, network_reset, network_unreachable, no_buffer_space)
(no_protocol_option, not_a_socket, not_connected, operation_canceled)
(operation_in_progress, operation_not_supported, protocol_error)
(protocol_not_supported, too_many_links, too_many_symbolic_link_levels)
(value_too_large, wrong_protocol_type): Define.
(bad_message, identifier_removed, no_link, no_message_available)
(no_message, no_stream_resources, not_a_stream, owner_dead)
(state_not_recoverable, stream_timeout, text_file_busy): Define
conditionally.
* testsuite/19_diagnostics/headers/system_error/errc_std_c++0x.cc:
Guard test for no_message with _GLIBCXX_HAVE_ENOMSG.

From-SVN: r248231

8 years agolibstdc++/78236 fix past-the-end std::regex_iterator
Jonathan Wakely [Thu, 18 May 2017 15:30:42 +0000 (16:30 +0100)] 
libstdc++/78236 fix past-the-end std::regex_iterator

Backport from mainline
2016-11-09  Tim Shen  <timshen@google.com>

PR libstdc++/78236
* libstdc++-v3/include/bits/regex.h (regex_iterator::regex_iterator()):
Define end() as _M_pregex == nullptr.
* libstdc++-v3/include/bits/regex.tcc (regex_iterator::operator==(),
regex_iterator::operator++()): Fix operator==() and operator++() to
look at null-ness of _M_pregex on both sides.
* testsuite/28_regex/regression.cc: New testcase.

From-SVN: r248230

8 years agoPR59170 make pretty printers check for singular iterators
Jonathan Wakely [Thu, 18 May 2017 09:23:43 +0000 (10:23 +0100)] 
PR59170 make pretty printers check for singular iterators

Backport from mainline
2016-12-15  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/59170
* python/libstdcxx/v6/printers.py (StdListIteratorPrinter.to_string)
(StdSlistIteratorPrinter.to_string, StdVectorIteratorPrinter.to_string)
(StdRbtreeIteratorPrinter.to_string)
(StdDequeIteratorPrinter.to_string): Add check for value-initialized
iterators.
* testsuite/libstdc++-prettyprinters/simple.cc: Test them.
* testsuite/libstdc++-prettyprinters/simple11.cc: Likewise.

From-SVN: r248183